50 |
|
!! @author Matthew Meineke |
51 |
|
!! @author Christopher Fennell |
52 |
|
!! @author J. Daniel Gezelter |
53 |
< |
!! @version $Id: sticky.F90,v 1.13 2005-05-29 21:16:25 chrisfen Exp $, $Date: 2005-05-29 21:16:25 $, $Name: not supported by cvs2svn $, $Revision: 1.13 $ |
53 |
> |
!! @version $Id: sticky.F90,v 1.15 2005-10-12 18:59:16 chuckv Exp $, $Date: 2005-10-12 18:59:16 $, $Name: not supported by cvs2svn $, $Revision: 1.15 $ |
54 |
|
|
55 |
|
module sticky |
56 |
|
|
66 |
|
implicit none |
67 |
|
|
68 |
|
PRIVATE |
69 |
+ |
#define __FORTRAN90 |
70 |
+ |
#include "UseTheForce/DarkSide/fInteractionMap.h" |
71 |
|
|
72 |
|
public :: newStickyType |
73 |
|
public :: do_sticky_pair |
74 |
|
public :: destroyStickyTypes |
75 |
|
public :: do_sticky_power_pair |
76 |
+ |
public :: getStickyCut |
77 |
+ |
public :: getStickyPowerCut |
78 |
|
|
75 |
– |
|
79 |
|
type :: StickyList |
80 |
|
integer :: c_ident |
81 |
|
real( kind = dp ) :: w0 = 0.0_dp |
151 |
|
return |
152 |
|
end subroutine newStickyType |
153 |
|
|
154 |
+ |
function getStickyCut(atomID) result(cutValue) |
155 |
+ |
integer, intent(in) :: atomID |
156 |
+ |
real(kind=dp) :: cutValue |
157 |
+ |
|
158 |
+ |
cutValue = StickyMap(atomID)%rbig |
159 |
+ |
end function getStickyCut |
160 |
+ |
|
161 |
+ |
function getStickyPowerCut(atomID) result(cutValue) |
162 |
+ |
integer, intent(in) :: atomID |
163 |
+ |
real(kind=dp) :: cutValue |
164 |
+ |
|
165 |
+ |
cutValue = StickyMap(atomID)%rbig |
166 |
+ |
end function getStickyPowerCut |
167 |
+ |
|
168 |
|
subroutine do_sticky_pair(atom1, atom2, d, rij, r2, sw, vpair, fpair, & |
169 |
|
pot, A, f, t, do_pot) |
170 |
|
|
308 |
|
vpair = vpair + 0.5d0*(v0*s*w + v0p*sp*wp) |
309 |
|
if (do_pot) then |
310 |
|
#ifdef IS_MPI |
311 |
< |
pot_row(atom1) = pot_row(atom1) + 0.25d0*(v0*s*w + v0p*sp*wp)*sw |
312 |
< |
pot_col(atom2) = pot_col(atom2) + 0.25d0*(v0*s*w + v0p*sp*wp)*sw |
311 |
> |
pot_row(STICKY_POT,atom1) = pot_row(STICKY_POT,atom1) + 0.25d0*(v0*s*w + v0p*sp*wp)*sw |
312 |
> |
pot_col(STICKY_POT,atom2) = pot_col(STICKY_POT,atom2) + 0.25d0*(v0*s*w + v0p*sp*wp)*sw |
313 |
|
#else |
314 |
|
pot = pot + 0.5d0*(v0*s*w + v0p*sp*wp)*sw |
315 |
|
#endif |