grompp no longer modifies nstcomm
authorBerk Hess <hess@kth.se>
Tue, 29 Jun 2021 09:43:07 +0000 (11:43 +0200)
committerMark Abraham <mark.j.abraham@gmail.com>
Mon, 16 Aug 2021 14:33:15 +0000 (14:33 +0000)
docs/release-notes/2022/major/miscellaneous.rst
src/gromacs/gmxpreprocess/readir.cpp

index 1a242e34466312319a3223974f3e5250c526dd6b..1f050b2921ffff921008ad6211431a2c8d7885ce 100644 (file)
@@ -7,3 +7,9 @@ Miscellaneous
    Also, please use the syntax :issue:`number` to reference issues on GitLab, without the
    a space between the colon and number!
 
+grompp no longer modifies nstcomm
+"""""""""""""""""""""""""""""""""
+
+grompp will no longer set nstcomm, the interval for center of mass motion
+removal, equal to nstcalcenergy when nstcomm < nstcalcenergy.
+A note is still printed in that case.
index 4ca4390d1484e9e065dda659a7d7d510c094bc13..adba76ef7d5e90266a5fa4acb3fa88eef5f6b993 100644 (file)
@@ -1059,12 +1059,12 @@ void check_ir(const char*                    mdparin,
             ir->nstcomm = abs(ir->nstcomm);
         }
 
-        if (ir->nstcalcenergy > 0 && ir->nstcomm < ir->nstcalcenergy)
+        if (ir->nstcalcenergy > 0 && ir->nstcomm < ir->nstcalcenergy
+            && ir->comm_mode != ComRemovalAlgorithm::LinearAccelerationCorrection)
         {
             warning_note(wi,
-                         "nstcomm < nstcalcenergy defeats the purpose of nstcalcenergy, setting "
-                         "nstcomm to nstcalcenergy");
-            ir->nstcomm = ir->nstcalcenergy;
+                         "nstcomm < nstcalcenergy defeats the purpose of nstcalcenergy, consider "
+                         "setting nstcomm equal to nstcalcenergy for less overhead");
         }
 
         if (ir->comm_mode == ComRemovalAlgorithm::Angular)