Reverse order of conditions.
authorSebastian Kehl <sebastian.kehl@mpcdf.mpg.de>
Mon, 20 Sep 2021 15:00:57 +0000 (17:00 +0200)
committerMagnus Lundborg <magnus.lundborg@scilifelab.se>
Tue, 5 Oct 2021 11:38:46 +0000 (11:38 +0000)
src/gromacs/listed_forces/pairs.cpp

index 217b4ecce269643c99ee1c957e46af2bbc216047..99a4d3dd91e7c19d164bc6197413a7433d918acb 100644 (file)
@@ -230,7 +230,7 @@ static real free_energy_evaluate_single(real
                  * Correct for this by multiplying with (1/12.0)/(1/6.0)=6.0/12.0=0.5.
                  */
                 sigma6[i] = half * c12[i] / c6[i];
-                if ((sigma6[i] < scParams.sigma6Minimum) && softcoreType == SoftcoreType::Beutler) /* for disappearing coul and vdw with soft core at the same time */
+                if (softcoreType == SoftcoreType::Beutler && (sigma6[i] < scParams.sigma6Minimum)) /* for disappearing coul and vdw with soft core at the same time */
                 {
                     sigma6[i] = scParams.sigma6Minimum;
                 }