X-Git-Url: https://hackdaworld.org/gitweb/?a=blobdiff_plain;f=potentials%2Ftersoff.c;fp=potentials%2Ftersoff.c;h=da92ea5982a86790b8382ecea7220d6bf6deeeb8;hb=acdd9a6aa72f3692ccd03cc0df20e3d60555f555;hp=a4a87e34d38a574e4e1dcb181d27f80eb7fe09e8;hpb=57847266c05bc38218bf162efdb08e8dd40894d7;p=physik%2Fposic.git diff --git a/potentials/tersoff.c b/potentials/tersoff.c index a4a87e3..da92ea5 100644 --- a/potentials/tersoff.c +++ b/potentials/tersoff.c @@ -418,7 +418,8 @@ int tersoff_mult_3bp_j2(t_moldyn *moldyn,t_atom *ai,t_atom *aj,u8 bc) { #endif /* virial */ - virial_calc(ai,&force,&(exchange->dist_ij)); + if(ajdist_ij)); /* dzeta prefactor = - 0.5 f_c f_a db */ exchange->pre_dzeta=-0.5*f_a*f_c*db; @@ -544,7 +545,8 @@ int tersoff_mult_3bp_k2(t_moldyn *moldyn, /* virial */ //v3_scale(&force,&force,-1.0); - virial_calc(ai,&force,&dist_ij); + if(ajkcount++;