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
31786496
"platforms/vscode:/vscode.git/clone" did not exist on "02825c4632f3379f39dfb93f583631ac2912486f"
Commit
31786496
authored
Sep 10, 2019
by
Chengwen Liu
Browse files
bug fix TestVdw
parent
5dd5e142
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
8 deletions
+14
-8
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaVdwForce.cpp
...ns/amoeba/platforms/cuda/tests/TestCudaAmoebaVdwForce.cpp
+11
-8
plugins/amoeba/platforms/reference/tests/TestReferenceAmoebaVdwForce.cpp
...platforms/reference/tests/TestReferenceAmoebaVdwForce.cpp
+3
-0
No files found.
plugins/amoeba/platforms/cuda/tests/TestCudaAmoebaVdwForce.cpp
View file @
31786496
...
...
@@ -403,13 +403,6 @@ void testVdwAmmoniaCubicMeanWH() {
std
::
string
testName
=
"testVdwAmmoniaCubicMeanWH"
;
// test alchemical VDW
void
testVdwAlchemical
(
int
power
,
double
alpha
,
double
lambda
,
AmoebaVdwForce
::
AlchemicalMethod
method
)
{
std
::
string
testName
=
"testVdwAlchemical"
;
int
numberOfParticles
=
8
;
double
boxDimension
=
-
1.0
;
double
cutoff
=
9000000.0
;
...
...
@@ -431,6 +424,17 @@ void testVdwAlchemical(int power, double alpha, double lambda, AmoebaVdwForce::A
expectedForces
[
6
]
=
Vec3
(
-
1.8544507e+02
,
8.4027272e-03
,
6.0950274e+00
);
expectedForces
[
7
]
=
Vec3
(
1.4159723e+00
,
2.7168386e-01
,
-
1.5376786e-01
);
double
tolerance
=
1.0e-04
;
compareForcesEnergy
(
testName
,
expectedEnergy
,
energy
,
expectedForces
,
forces
,
tolerance
);
}
// test alchemical VDW
void
testVdwAlchemical
(
int
power
,
double
alpha
,
double
lambda
,
AmoebaVdwForce
::
AlchemicalMethod
method
)
{
std
::
string
testName
=
"testVdwAlchemical"
;
setupAndGetForcesEnergyVdwAmmonia2
(
"CUBIC-MEAN"
,
"HHG"
,
cutoff
,
boxDimension
,
forces
,
energy
,
method
,
power
,
alpha
,
lambda
);
std
::
vector
<
Vec3
>
expectedForces
(
numberOfParticles
);
...
...
@@ -451,7 +455,6 @@ void testVdwAlchemical(int power, double alpha, double lambda, AmoebaVdwForce::A
expectedForces
[
i
]
*=
scale
;
}
double
tolerance
=
1.0e-04
;
compareForcesEnergy
(
testName
,
expectedEnergy
,
energy
,
expectedForces
,
forces
,
tolerance
);
}
...
...
plugins/amoeba/platforms/reference/tests/TestReferenceAmoebaVdwForce.cpp
View file @
31786496
...
...
@@ -466,6 +466,9 @@ void testVdwAlchemical(int power, double alpha, double lambda, AmoebaVdwForce::A
for
(
int
i
=
0
;
i
<
8
;
i
++
)
{
expectedForces
[
i
]
*=
scale
;
}
double
tolerance
=
1.0e-04
;
compareForcesEnergy
(
testName
,
expectedEnergy
,
energy
,
expectedForces
,
forces
,
tolerance
);
}
// test VDW w/ sigmaRule=Arithmetic and epsilonRule=Arithmetic
...
...
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