From: hackbard Date: Thu, 20 Aug 2009 11:02:22 +0000 (+0200) Subject: more easy ... X-Git-Url: https://hackdaworld.org/gitweb/?a=commitdiff_plain;h=7b97b630ab3bee5cc967142d1a4bfedd29005179;p=physik%2Fposic.git more easy ... --- diff --git a/vasp_tools/poscar2moldyn b/vasp_tools/poscar2moldyn index 29a527e..b0ad584 100755 --- a/vasp_tools/poscar2moldyn +++ b/vasp_tools/poscar2moldyn @@ -50,15 +50,12 @@ tail -${total} $file | \ type="C" color="Gray" fi - ((X=0)) - ((Y=0)) - ((Z=0)) - X=`echo $X $x $y $z $x1 $y1 $z1 | \ - awk '{ print $1+($2*$5)+($3*$6)+($4*$7) }'` - Y=`echo $Y $x $y $z $x2 $y2 $z2 | \ - awk '{ print $1+($2*$5)+($3*$6)+($4*$7) }'` - Z=`echo $Z $x $y $z $x3 $y3 $z3 | \ - awk '{ print $1+($2*$5)+($3*$6)+($4*$7) }'` + X=`echo $x $y $z $x1 $y1 $z1 | \ + awk '{ print $1*$4+$2*$5+$3*$6 }'` + Y=`echo $x $y $z $x2 $y2 $z2 | \ + awk '{ print $1*$4+$2*$5+$3*$6 }'` + Z=`echo $x $y $z $x3 $y3 $z3 | \ + awk '{ print $1*$4+$2*$5+$3*$6 }'` X=`echo $lc $X | awk '{ print $1*$2 }'` Y=`echo $lc $Y | awk '{ print $1*$2 }'` Z=`echo $lc $Z | awk '{ print $1*$2 }'`