--- trunk/OOPSE/libmdtools/calc_LJ_FF.F90 2003/03/21 17:42:12 378 +++ trunk/OOPSE/libmdtools/calc_LJ_FF.F90 2003/04/08 22:38:43 482 @@ -2,12 +2,13 @@ !! Corresponds to the force field defined in lj_FF.cpp !! @author Charles F. Vardeman II !! @author Matthew Meineke -!! @version $Id: calc_LJ_FF.F90,v 1.1.1.1 2003-03-21 17:42:12 mmeineke Exp $, $Date: 2003-03-21 17:42:12 $, $Name: not supported by cvs2svn $, $Revision: 1.1.1.1 $ +!! @version $Id: calc_LJ_FF.F90,v 1.3 2003-04-08 22:38:43 chuckv Exp $, $Date: 2003-04-08 22:38:43 $, $Name: not supported by cvs2svn $, $Revision: 1.3 $ module lj use definitions use atype_module use vector_class + use simulation #ifdef IS_MPI use mpiSimulation #endif @@ -180,7 +181,7 @@ contains integer, intent(in) :: atom1, atom2 real( kind = dp ), intent(in) :: rij, r2 real( kind = dp ) :: pot - real( kind = dp ), dimension(:,:) :: f + real( kind = dp ), dimension(3,getNlocal()) :: f real( kind = dp ), intent(in), dimension(3) :: d logical, intent(in) :: do_pot, do_stress @@ -218,9 +219,9 @@ contains dudr = 24.0E0_DP * epsilon * (t6 - 2.0E0_DP*t12) / rij - drdx = -d(1) / rij - drdy = -d(2) / rij - drdz = -d(3) / rij + drdx = d(1) / rij + drdy = d(2) / rij + drdz = d(3) / rij fx = dudr * drdx fy = dudr * drdy