1 2 subroutine smd_leapf(natms,tstep,ekin,mass,fff,vvv,ccc) 3 4 implicit none 5 6 integer natms 7 double precision tstep 8 double precision ekin 9 double precision mass(natms) 10 double precision fff(natms,3) 11 double precision vvv(natms,3) 12 double precision ccc(natms,3) 13c 14 integer i,iatm 15 16 double precision tmpvx,tmpvy,tmpvz 17 18 ekin=0.0 19 20 do i=1,natms 21 tmpvx=vvv(i,1) 22 tmpvy=vvv(i,2) 23 tmpvz=vvv(i,3) 24 25 vvv(i,1)=vvv(i,1)+fff(i,1)*tstep/mass(i) 26 vvv(i,2)=vvv(i,2)+fff(i,2)*tstep/mass(i) 27 vvv(i,3)=vvv(i,3)+fff(i,3)*tstep/mass(i) 28 29 tmpvx=0.5*(tmpvx+vvv(i,1)) 30 tmpvy=0.5*(tmpvy+vvv(i,2)) 31 tmpvz=0.5*(tmpvz+vvv(i,3)) 32 33 ekin=ekin+mass(i)*(tmpvx**2+tmpvy**2+tmpvz**2) 34 35 ccc(i,1)=ccc(i,1)+tstep*vvv(i,1) 36 ccc(i,2)=ccc(i,2)+tstep*vvv(i,2) 37 ccc(i,3)=ccc(i,3)+tstep*vvv(i,3) 38 39 enddo 40 41 ekin=0.5*ekin 42 43 return 44 45 end 46 47c $Id$ 48