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
9f4bd981
"devtools/packaging/vscode:/vscode.git/clone" did not exist on "1ebe88ba70e77c08dec11b9e81972acd978653aa"
Commit
9f4bd981
authored
Sep 01, 2010
by
Peter Eastman
Browse files
Cuda platform was updating velocities incorrectly on the first time step
parent
7c1846a8
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
platforms/cuda/src/kernels/gpu.cpp
platforms/cuda/src/kernels/gpu.cpp
+6
-1
No files found.
platforms/cuda/src/kernels/gpu.cpp
View file @
9f4bd981
...
...
@@ -1912,7 +1912,6 @@ void* gpuInit(int numAtoms, unsigned int device, bool useBlockingSync)
gpu
->
sim
.
alphaOBC
=
alphaOBC
;
gpu
->
sim
.
betaOBC
=
betaOBC
;
gpu
->
sim
.
gammaOBC
=
gammaOBC
;
gpuSetLangevinIntegrationParameters
(
gpu
,
1.0
f
,
2.0e-3
f
,
300.0
f
,
0.0
f
);
gpu
->
sim
.
maxShakeIterations
=
15
;
gpu
->
sim
.
shakeTolerance
=
1.0e-04
f
*
2.0
f
;
gpu
->
sim
.
InvMassJ
=
9.920635e-001
f
;
...
...
@@ -2021,6 +2020,8 @@ void gpuSetLangevinIntegrationParameters(gpuContext gpu, float tau, float deltaT
(
*
gpu
->
psLangevinParameters
)[
2
]
=
(
float
)
noisescale
;
gpu
->
psLangevinParameters
->
Upload
();
gpu
->
psStepSize
->
Download
();
if
((
*
gpu
->
psStepSize
)[
0
].
x
==
0
)
(
*
gpu
->
psStepSize
)[
0
].
x
=
deltaT
;
(
*
gpu
->
psStepSize
)[
0
].
y
=
deltaT
;
gpu
->
psStepSize
->
Upload
();
}
...
...
@@ -2031,6 +2032,8 @@ void gpuSetVerletIntegrationParameters(gpuContext gpu, float deltaT, float error
gpu
->
sim
.
oneOverDeltaT
=
1.0
f
/
deltaT
;
gpu
->
sim
.
errorTol
=
errorTol
;
gpu
->
psStepSize
->
Download
();
if
((
*
gpu
->
psStepSize
)[
0
].
x
==
0
)
(
*
gpu
->
psStepSize
)[
0
].
x
=
deltaT
;
(
*
gpu
->
psStepSize
)[
0
].
y
=
deltaT
;
gpu
->
psStepSize
->
Upload
();
}
...
...
@@ -2045,6 +2048,8 @@ void gpuSetBrownianIntegrationParameters(gpuContext gpu, float tau, float deltaT
gpu
->
sim
.
kT
=
BOLTZ
*
gpu
->
sim
.
T
;
gpu
->
sim
.
noiseAmplitude
=
sqrt
(
2.0
f
*
gpu
->
sim
.
kT
*
deltaT
*
tau
);
gpu
->
psStepSize
->
Download
();
if
((
*
gpu
->
psStepSize
)[
0
].
x
==
0
)
(
*
gpu
->
psStepSize
)[
0
].
x
=
deltaT
;
(
*
gpu
->
psStepSize
)[
0
].
y
=
deltaT
;
gpu
->
psStepSize
->
Upload
();
}
...
...
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