#!/bin/tcsh

grep "      1      " single.mdout > ene.dat
grep " BOND    =" single.mdout > bond-ang-dihed.dat
grep " VDWAALS =" single.mdout > vdw-eel.dat
grep " 1-4 VDW =" single.mdout > 1-4vdw-eel.dat

perl ~/scripts/stdcalc.perl ene.dat > avg-ene.dat
perl ~/scripts/stdcalc.perl bond-ang-dihed.dat > avg-bond-ang-dihed.dat
perl ~/scripts/stdcalc.perl vdw-eel.dat > avg-vdw-eel.dat
perl ~/scripts/stdcalc.perl 1-4vdw-eel.dat > avg-1-4vdw-eel.dat

rm ene.dat bond-ang-dihed.dat vdw-eel.dat 1-4vdw-eel.dat
