ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE_old/src/mdtools/libmdCode/calc_sticky_pair.F90
(Generate patch)

Comparing trunk/OOPSE_old/src/mdtools/libmdCode/calc_sticky_pair.F90 (file contents):
Revision 322 by gezelter, Wed Mar 12 15:17:52 2003 UTC vs.
Revision 323 by gezelter, Wed Mar 12 15:39:01 2003 UTC

# Line 9 | Line 9
9   !! @author Matthew Meineke
10   !! @author Christopher Fennel
11   !! @author J. Daniel Gezelter
12 < !! @version $Id: calc_sticky_pair.F90,v 1.2 2003-03-12 15:17:52 gezelter Exp $, $Date: 2003-03-12 15:17:52 $, $Name: not supported by cvs2svn $, $Revision: 1.2 $
12 > !! @version $Id: calc_sticky_pair.F90,v 1.3 2003-03-12 15:39:01 gezelter Exp $, $Date: 2003-03-12 15:39:01 $, $Name: not supported by cvs2svn $, $Revision: 1.3 $
13  
14   module sticky_pair
15  
# Line 25 | Line 25 | module sticky_pair
25    PRIVATE
26  
27    logical, save :: sticky_initialized = .false.
28 <  real( kind = dp ), save :: SSD_w0
28 >  real( kind = dp ), save :: SSD_w0
29    real( kind = dp ), save :: SSD_v0
30    real( kind = dp ), save :: SSD_rl
31    real( kind = dp ), save :: SSD_ru
32    real( kind = dp ), save :: SSD_rup
33  
34 <  public :: initialize_sticky
34 >  public :: check_sticky_FF
35 >  public :: set_sticky_params
36    public :: do_sticky_pair
37  
38   contains
39  
40 <  subroutine initialize_sticky(sticky_w0, sticky_v0)
40 >  subroutine check_sticky_FF(status)
41 >    integer :: status = -1
42 >
43 >    if (sticky_initialized) status = 0
44 >    return
45 >  end subroutine check_sticky_FF
46 >
47 >  subroutine set_sticky_params(sticky_w0, sticky_v0)
48      real( kind = dp ), intent(in) :: sticky_w0, sticky_v0
49      
50      ! we could pass all 5 parameters if we felt like it...
51 <
51 >    
52      SSD_w0 = sticky_w0
53      SSD_v0 = sticky_v0
54      SSD_rl = 2.75_DP
55      SSD_ru = 3.35_DP
56      SSD_rup = 4.0_DP
57 <
57 >  
58      sticky_initialized = .true.
59      return
60 <  end subroutine initialize_sticky
60 >  end subroutine set_sticky_params
61  
62 <  subroutine do_sticky_pair(atom1, atom2, d, rij, A, pot, f, t)
62 >  subroutine do_sticky_pair(atom1, atom2, d, rij, r2, A, pot, f, t)
63      
64      !! This routine does only the sticky portion of the SSD potential
65      !! [Chandra and Ichiye, J. Chem. Phys. 111, 2701 (1999)].
# Line 63 | Line 71 | contains
71      !! i and j are pointers to the two SSD atoms
72  
73      integer, intent(in) :: atom1, atom2
74 <    real (kind=dp), intent(inout) :: rij    
74 >    real (kind=dp), intent(inout) :: rij, r2
75      real (kind=dp), dimension(3), intent(in) :: d
76 +    real (kind=dp) :: pot
77      real (kind=dp), dimension(9,getNlocal()) :: A
78      real (kind=dp), dimension(3,getNlocal()) :: f
79      real (kind=dp), dimension(3,getNlocal()) :: t
80  
81      real (kind=dp) :: xi, yi, zi, xj, yj, zj, xi2, yi2, zi2, xj2, yj2, zj2
82 <    real (kind=dp) :: r2, r3, r5, r6, s, sp, dsdr, dspdr
82 >    real (kind=dp) :: r3, r5, r6, s, sp, dsdr, dspdr
83      real (kind=dp) :: wi, wj, w, wip, wjp, wp
84      real (kind=dp) :: dwidx, dwidy, dwidz, dwjdx, dwjdy, dwjdz
85      real (kind=dp) :: dwipdx, dwipdy, dwipdz, dwjpdx, dwjpdy, dwjpdz
# Line 88 | Line 97 | contains
97         return
98      endif
99  
91    r2 = rij*rij
100      r3 = r2*rij
101      r5 = r3*r2
102      

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines