[Python Glasgow] (no subject)
Hedieh Ebrahimi
hedieh.ebrahimi at amphos21.com
Thu Mar 21 15:54:29 CET 2013
Thanks guys for help with previous question. its working now.
I have another question. I need to extract information. so i now have a
file like this :
TRAN 1 Time= 3.17098E-08 Dt= 3.17098E-08 [y] snes_conv_reason: 3
newton = 36 [ 36] linear = 36 [ 36] cuts = 0 [ 0]
--> max chng: dcmx= 5.0315E-08 dc/dt= 5.0315E-08 [mol/s]
TRAN 2 Time= 6.34196E-08 Dt= 3.17098E-08 [y] snes_conv_reason: 3
newton = 4 [ 40] linear = 4 [ 40] cuts = 0 [ 0]
--> max chng: dcmx= 3.0785E-08 dc/dt= 3.0785E-08 [mol/s]
TRAN 3 Time= 1.26839E-07 Dt= 6.34196E-08 [y] snes_conv_reason: 3
newton = 4 [ 44] linear = 4 [ 44] cuts = 0 [ 0]
--> max chng: dcmx= 3.5161E-08 dc/dt= 1.7580E-08 [mol/s]
--------------------------------------------------------------------------------------
TRAN 1 Time= 3.17098E-08 Dt= 3.17098E-08 [y] snes_conv_reason: 3
newton = 36 [ 36] linear = 36 [ 36] cuts = 0 [ 0]
--> max chng: dcmx= 5.0315E-08 dc/dt= 5.0315E-08 [mol/s]
In this file i need the following information to be extracted in each
consequetive 3 lines. Could you please let me know how I can do this.
At the end i want to have a text file at the output producing this:
1 Time 3.17098E-08 Dt 3.17098E-08 newton 36 linear 36 cuts 0
Id appreciate any hints,
ive just started python 2 days ago )))
thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/glasgow/attachments/20130321/4486a1ae/attachment.html>
More information about the Glasgow
mailing list