ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE-4/src/UseTheForce/DarkSide/LJ.F90
(Generate patch)

Comparing trunk/OOPSE-4/src/UseTheForce/DarkSide/LJ.F90 (file contents):
Revision 2271 by gezelter, Tue Aug 9 22:33:48 2005 UTC vs.
Revision 2317 by chrisfen, Wed Sep 21 17:20:14 2005 UTC

# Line 43 | Line 43
43   !! Calculates Long Range forces Lennard-Jones interactions.
44   !! @author Charles F. Vardeman II
45   !! @author Matthew Meineke
46 < !! @version $Id: LJ.F90,v 1.13 2005-08-09 22:33:48 gezelter Exp $, $Date: 2005-08-09 22:33:48 $, $Name: not supported by cvs2svn $, $Revision: 1.13 $
46 > !! @version $Id: LJ.F90,v 1.15 2005-09-21 17:20:14 chrisfen Exp $, $Date: 2005-09-21 17:20:14 $, $Name: not supported by cvs2svn $, $Revision: 1.15 $
47  
48  
49   module lj
# Line 157 | Line 157 | contains
157      defaultCutoff = thisRcut
158      defaultShift = shiftedPot
159      haveDefaultCutoff = .true.
160 +    call createMixingMap()
161    end subroutine setLJDefaultCutoff
162  
163    subroutine setLJUniformCutoff(thisRcut, shiftedPot)
# Line 253 | Line 254 | contains
254      integer :: nLJtypes, i, j
255      real ( kind = dp ) :: s1, s2, e1, e2
256      real ( kind = dp ) :: rcut6, tp6, tp12
257 <    logical :: isSoftCore1, isSoftCore2
257 >    logical :: isSoftCore1, isSoftCore2, doShift
258  
259      if (LJMap%currentLJtype == 0) then
260         call handleError("LJ", "No members in LJMap")
# Line 296 | Line 297 | contains
297            else
298               if (haveDefaultCutoff) then
299                  rcut6 = defaultCutoff**6
300 +                doShift = defaultShift
301               else
302                  call handleError("LJ", "No specified or default cutoff value!")
303               endif
# Line 303 | Line 305 | contains
305            
306            tp6    = MixingMap(i,j)%sigma6/rcut6
307            tp12    = tp6**2          
306
308            MixingMap(i,j)%delta =-4.0_DP*MixingMap(i,j)%epsilon*(tp12 - tp6)
309 +          MixingMap(i,j)%shiftedPot = doShift
310 +
311 +          if (i.ne.j) then
312 +             MixingMap(j,i)%sigma      = MixingMap(i,j)%sigma
313 +             MixingMap(j,i)%epsilon    = MixingMap(i,j)%epsilon
314 +             MixingMap(j,i)%sigma6     = MixingMap(i,j)%sigma6
315 +             MixingMap(j,i)%rCut       = MixingMap(i,j)%rCut
316 +             MixingMap(j,i)%delta      = MixingMap(i,j)%delta
317 +             MixingMap(j,i)%rCutWasSet = MixingMap(i,j)%rCutWasSet
318 +             MixingMap(j,i)%shiftedPot = MixingMap(i,j)%shiftedPot
319 +             MixingMap(j,i)%isSoftCore = MixingMap(i,j)%isSoftCore
320 +          endif
321 +
322         enddo
323      enddo
324      
# Line 394 | Line 408 | contains
408      fy = dudr * drdy
409      fz = dudr * drdz
410  
397
411   #ifdef IS_MPI
412      if (do_pot) then
413         pot_Row(atom1) = pot_Row(atom1) + sw*pot_temp*0.5

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines