4 pot=`grep ^potential $1/config | awk '{ print $2 }'`
7 if [ "$pot" = "tersoff" ]; then
13 echo "potential: $pot"
20 file=`ls $1/atomic_conf_* | tail -1`
21 atom_cnt=`grep '# \[P\]' $file | awk '{ print $3 }'`
22 e0=`awk 'NR==2' $1/energy | awk '{ print $3 }'`
23 e1=`tail -n 1 $1/energy | awk '{ print $3 }'`
24 ed0=`awk 'NR==2' $1/energy | awk '{ print $6 }'`
25 ed1=`tail -n 1 $1/energy | awk '{ print $6 }'`
26 si_cnt=`grep ^Si $file | wc -l`
27 c_cnt=`grep ^C $file | wc -l`
29 echo "-------------------------------------------------------------------------"
30 echo " Formation energy [eV]: #Si=$si_cnt, #C=$c_cnt, #tot=$atom_cnt"
31 echo "-------------------------------------------------------------------------"
33 echo "$si_cnt $c_cnt $e1 $e0" | \
34 awk '{ print " Gao: "($3-$4)*($1+$2) }'
35 echo "$si_cnt $c_cnt $musi $muc $e1 $music" | \
36 #awk '{ print " Posselt: "$5*($1+$2)-0.5*($1+$2)*$6-0.5*($1-$2)*($3-$4) }'
37 awk '{ print " Posselt: "$5*($1+$2)-$1*$3-$2*$4 }'
38 echo "$si_cnt $c_cnt $musi $music $e1 $music" | \
39 awk '{ print " Tersoff: "$5*($1+$2)-$1*$3-$2*($4-$3) }'