Commit 3e47d824 authored by peastman's avatar peastman
Browse files

Reversed a change that didn't help

parent 4b5b08af
......@@ -19,7 +19,7 @@ if ((!isExcluded && r2 < CUTOFF_SQUARED) || needCorrection) {
if (needCorrection) {
// Subtract off the part of this interaction that was included in the reciprocal space contribution.
if (1.0f-erfcAlphaR > 1e-6f) {
if (1-erfcAlphaR > 1e-6) {
real erfAlphaR = ERF(alphaR); // Our erfc approximation is not accurate enough when r is very small, which happens with Drude particles.
tempForce = -prefactor*(erfAlphaR-alphaR*expAlphaRSqr*TWO_OVER_SQRT_PI);
tempEnergy += -prefactor*erfAlphaR;
......
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