Commit e6696626 authored by Lee-Ping Wang's avatar Lee-Ping Wang
Browse files

Commented out some minor optimizations in AMOEBA that were making the forces...

Commented out some minor optimizations in AMOEBA that were making the forces incorrect.  AMOEBA energies and forces now agree with TINKER to within 1e-9 (fractional energy) 1e-5 (fractional RMS force error) for NPT simulations on rectangular water boxes with PME and direct or mutual polarizability.

parent dabb49a7
......@@ -529,7 +529,8 @@ extern "C" __global__ void computeFixedField(
#endif
#ifdef USE_CUTOFF
unsigned int flags = (numTiles <= maxTiles ? interactionFlags[pos] : 0xFFFFFFFF);
if (!hasExclusions && flags != 0xFFFFFFFF) {
if (!hasExclusions && flags == 0) { // TODO: Why doesn't the flags != 0 block work?
// if (!hasExclusions && flags != 0xFFFFFFFF) {
if (flags == 0) {
// No interactions in this tile.
}
......
......@@ -298,7 +298,8 @@ extern "C" __global__ void computeElectrostatics(
localData[threadIdx.x].torque = make_real3(0);
#ifdef USE_CUTOFF
unsigned int flags = (numTiles <= maxTiles ? interactionFlags[pos] : 0xFFFFFFFF);
if (!hasExclusions && flags != 0xFFFFFFFF) {
if (!hasExclusions && flags == 0) { // TODO: Why doesn't the flags != 0 block work?
// if (!hasExclusions && flags != 0xFFFFFFFF) {
if (flags == 0) {
// No interactions in this tile.
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment