Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
tsoc
openmm
Commits
a919f305
Commit
a919f305
authored
Sep 27, 2012
by
Peter Eastman
Browse files
Bug fix to using AmoebaVdwForce without a cutoff
parent
01269257
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
plugins/amoeba/platforms/cuda2/src/kernels/amoebaVdwForce2.cu
...ins/amoeba/platforms/cuda2/src/kernels/amoebaVdwForce2.cu
+2
-0
No files found.
plugins/amoeba/platforms/cuda2/src/kernels/amoebaVdwForce2.cu
View file @
a919f305
...
@@ -38,6 +38,7 @@
...
@@ -38,6 +38,7 @@
real
gTau
=
epsilon
*
tau7
*
r6
*
1.12
f
*
tmp
*
tmp
;
real
gTau
=
epsilon
*
tau7
*
r6
*
1.12
f
*
tmp
*
tmp
;
real
termEnergy
=
epsilon
*
sigma7
*
tau7
*
((
sigma7
*
1.12
f
*
invRho
)
-
2.0
f
);
real
termEnergy
=
epsilon
*
sigma7
*
tau7
*
((
sigma7
*
1.12
f
*
invRho
)
-
2.0
f
);
real
deltaE
=
-
7.0
f
*
(
dTau
*
termEnergy
+
gTau
);
real
deltaE
=
-
7.0
f
*
(
dTau
*
termEnergy
+
gTau
);
#ifdef USE_CUTOFF
if
(
r
>
TAPER_CUTOFF
)
{
if
(
r
>
TAPER_CUTOFF
)
{
real
x
=
r
-
TAPER_CUTOFF
;
real
x
=
r
-
TAPER_CUTOFF
;
real
taper
=
1
+
x
*
x
*
x
*
(
TAPER_C3
+
x
*
(
TAPER_C4
+
x
*
TAPER_C5
));
real
taper
=
1
+
x
*
x
*
x
*
(
TAPER_C3
+
x
*
(
TAPER_C4
+
x
*
TAPER_C5
));
...
@@ -45,6 +46,7 @@
...
@@ -45,6 +46,7 @@
deltaE
=
termEnergy
*
dtaper
+
deltaE
*
taper
;
deltaE
=
termEnergy
*
dtaper
+
deltaE
*
taper
;
termEnergy
*=
taper
;
termEnergy
*=
taper
;
}
}
#endif
tempEnergy
+=
(
includeInteraction
?
termEnergy
:
0
);
tempEnergy
+=
(
includeInteraction
?
termEnergy
:
0
);
dEdR
-=
(
includeInteraction
?
deltaE
*
invR
:
0
);
dEdR
-=
(
includeInteraction
?
deltaE
*
invR
:
0
);
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment