title: Replacement of values in a data file
body: <p>I'm trying to replace existing data values in a file. The file is intended for calculation of kinematic material hardening by a FEM-code. The text look like this for each element. I have a couple 100,000 of elements to modify:</p>
  
  <hr>
  
  <pre><code>13499         8        10         1         1                   0         0
  1.500360e+08    1.451964e+07    3.728601e+08   -49529.937500   -1.930966e+07
  4.499323e+06    4.427284e-03    2.107339e+06   -5.031084e+06    2.923746e+06
  15250.131836   -1.833509e+06    1.992212e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
  1.377865e+08    2.413883e+07    3.754904e+08    7.427730e+05   -2.500246e+07
  2.964798e+06    4.422367e-03    1.855410e+06   -4.713138e+06    2.857730e+06
  13224.164062   -2.054056e+06    1.624522e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
  1.373486e+08    2.433924e+07    3.757281e+08   -4.595526e+06   -2.536434e+07
  1.499050e+06    4.435852e-03    1.867437e+06   -4.746126e+06    2.878688e+06
  -1.195839e+05   -2.081042e+06    1.472030e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
  1.495412e+08    1.476622e+07    3.731083e+08   -5.636892e+06   -1.967031e+07
  3.060086e+06    4.440636e-03    2.109059e+06   -5.047602e+06    2.938542e+06
  -1.202835e+05   -1.849329e+06    1.847072e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
  1.586573e+08    1.004740e+07    3.687111e+08   -6.710480e+05   -2.547207e+07
  6.056666e+06    3.514634e-03    1.647607e+06   -3.689882e+06    2.042273e+06
    417.019592   -1.201436e+06    1.671364e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
  1.461364e+08    2.007670e+07    3.712027e+08    66494.984375   -3.248405e+07
  4.652704e+06    3.476992e-03    1.358743e+06   -3.303262e+06    1.944519e+06
   1658.200684   -1.316609e+06    1.339788e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
  1.457837e+08    2.024077e+07    3.713914e+08   -5.707908e+06   -3.274767e+07
  3.163598e+06    3.490632e-03    1.395223e+06   -3.361252e+06    1.966029e+06
  -1.027537e+05   -1.351428e+06    1.227283e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
  1.581765e+08    1.031220e+07    3.689273e+08   -6.650824e+06   -2.571731e+07
  4.596290e+06    3.530744e-03    1.661256e+06   -3.721140e+06    2.059885e+06
  -1.082121e+05   -1.219397e+06    1.555895e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
  </code></pre>
  
  <hr>
  
  <p>I want to change the text to this for all elements by the use of some smart commands, script etc. I'm using Linux but Windows 7 or Mac OS X can also be used if recommended.  I know the basics of FORTRAN, Scilab and Octave, but solutions outside of these environments are welcome.</p>
  
  <hr>
  
  <pre><code>13499         8        10         1         1                   0         0
         0.000           0.000           0.000           0.000           0.000
         0.000           0.000    2.107339e+06   -5.031084e+06    2.923746e+06
  15250.131836   -1.833509e+06    1.992212e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
         0.000           0.000           0.000           0.000           0.000
         0.000           0.000    1.855410e+06   -4.713138e+06    2.857730e+06
  13224.164062   -2.054056e+06    1.624522e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
         0.000           0.000           0.000           0.000           0.000
         0.000           0.000    1.867437e+06   -4.746126e+06    2.878688e+06
  -1.195839e+05   -2.081042e+06    1.472030e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
         0.000           0.000           0.000           0.000           0.000
         0.000           0.000   2.109059e+06   -5.047602e+06    2.938542e+06
  -1.202835e+05   -1.849329e+06    1.847072e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
         0.000           0.000           0.000           0.000           0.000
         0.000           0.000   1.647607e+06   -3.689882e+06    2.042273e+06
    417.019592   -1.201436e+06    1.671364e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
         0.000           0.000           0.000           0.000           0.000
         0.000           0.000    1.358743e+06   -3.303262e+06    1.944519e+06
   1658.200684   -1.316609e+06    1.339788e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
         0.000           0.000           0.000           0.000           0.000
         0.000           0.000    1.395223e+06   -3.361252e+06    1.966029e+06
  -1.027537e+05   -1.351428e+06    1.227283e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
         0.000           0.000           0.000           0.000           0.000
         0.000           0.000    1.661256e+06   -3.721140e+06    2.059885e+06
  -1.082121e+05   -1.219397e+06    1.555895e+05       20.000000           0.000
      1.000000    1.009244e-10           0.000           0.000           0.000
  </code></pre>
  
  <hr>
  
  <p>Please advise.</p>