Michal P Krompiec
michal.krompiec@gmail.com
to get the final energy from a DFT or RHF calculation (single point or geometry optimization):
grep "FINAL ENERGY" file.out | tail -n1 | awk '{print $4}'
to extract final geometry from a geometry optimization:
csplit file.out '%EQUILIBRIUM%+1' '%-------%+1' '/-------/'
cat xx00 | grep -P "[0-9]"
split PUNCH file in sections:
csplit PUNCH '/[\$]END/+1' '{*}'
get $vec group:
csplit PUNCH '%VEC%' '/[\$]END/+1'
For more complex tasks, I highly recommend cclib: http://cclib.sourceforge.net/wiki/index.php/Main_Page
Best wishes,
Michal