Remove TODO regarding AWH cover threshold along lambda axis.
authorMagnus Lundborg <magnus.lundborg@scilifelab.se>
Mon, 2 Nov 2020 15:53:15 +0000 (16:53 +0100)
committerMark Abraham <mark.j.abraham@gmail.com>
Tue, 3 Nov 2020 09:05:58 +0000 (09:05 +0000)
The 1.0 factor should be OK for a FEP lambda axis. It should be OK
in theory and tests show it works.

Change-Id: Iafe39ab0663ec227e96e40f1b2073818610e93ae
Closes: #3634

src/gromacs/applied_forces/awh/biasstate.cpp

index c248699916bce5910114656c06fad4e8407cdb31..3713c0bbce8164e8a69054aff8edaad38126a617 100644 (file)
@@ -1003,13 +1003,16 @@ bool BiasState::isSamplingRegionCovered(const BiasParams&             params,
     {
         if (grid.axis(d).isFepLambdaAxis())
         {
-            /* TODO: Verify that a threshold of 1.0 is OK. With a very high sample weight 1.0 can be
-             * reached quickly even in regions with low probability. Should the sample weight be
-             * taken into account here? */
+            /* Do not modify the weight threshold based on a FEP lambda axis. The spread
+             * of the sampling weights is not depending on a Gaussian distribution (like
+             * below). */
             weightThreshold *= 1.0;
         }
         else
         {
+            /* The spacing is proportional to 1/sqrt(betak). The weight threshold will be
+             * approximately (given that the spacing can be modified if the dimension is periodic)
+             * proportional to sqrt(1/(2*pi)). */
             weightThreshold *= grid.axis(d).spacing()
                                * std::sqrt(dimParams[d].pullDimParams().betak * 0.5 * M_1_PI);
         }