ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE/libmdtools/calc_dipole_dipole.F90
(Generate patch)

Comparing trunk/OOPSE/libmdtools/calc_dipole_dipole.F90 (file contents):
Revision 1150 by gezelter, Fri May 7 21:35:05 2004 UTC vs.
Revision 1160 by gezelter, Tue May 11 21:31:15 2004 UTC

# Line 12 | Line 12 | module dipole_dipole
12    implicit none
13  
14    PRIVATE
15 <  real(kind=dp), save :: ecr = 0.0
16 <  real(kind=dp), save :: rt  = 0.0
17 <   real(kind=dp), save :: pre = 0.0
18 <  logical, save :: haveCutoffs = .false.
15 >
16 >  real(kind=dp), parameter :: pre = 14.38362_dp
17    logical, save :: haveMomentMap = .false.
18  
21  public::setCutoffsDipole
19    public::do_dipole_pair
20  
21    type :: MomentList
# Line 28 | Line 25 | contains
25    type(MomentList), dimension(:),allocatable :: MomentMap
26  
27   contains
31    
32  subroutine setCutoffsDipole(this_ecr, this_rt)
33    real(kind=dp), intent(in) :: this_ecr, this_rt
34    ecr = this_ecr
35    rt = this_rt    
28  
37      ! pre converts from mu in units of debye to kcal/mol
38    pre = 14.38362_dp
39
40    haveCutoffs = .true.
41    
42    return
43  end subroutine setCutoffsDipole
44
29    subroutine createMomentMap(status)
30      integer :: nAtypes
31      integer :: status
# Line 99 | Line 83 | contains
83      real (kind = dp), dimension(3) :: ul1
84      real (kind = dp), dimension(3) :: ul2
85  
102    if (.not. haveCutoffs) then
103       write(default_error,*) 'Dipole-dipole does not have cutoffs set!'
104       return
105    endif
106
86      if (.not.haveMomentMap) then
87         localError = 0
88         call createMomentMap(localError)
# Line 151 | Line 130 | contains
130      
131      vterm = dip2*((u1dotu2/r3) - 3.0d0*(rdotu1*rdotu2/r5))
132      
133 <    vpair = vpair + vterm*sw
133 >    vpair = vpair + vterm
134      
135      if (do_pot) then
136   #ifdef IS_MPI

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines