The combination of using shell particles with a value for
nstcalcenergy that is different from 1 leads to energies
not being communicated around on a parallel machine and hence
a meaningless shell relaxation procedure. This patch will just
bail out with a fatal error if the combination is detected.
Fixes #1376.
Change-Id: Ia54f1480b2358355438acb5de31dfa56b7f8d603
(ir->bContinuation ||
(DOMAINDECOMP(cr) && !MASTER(cr))) ?
NULL : state_global->x);
-
+ if (shellfc && ir->nstcalcenergy != 1)
+ {
+ gmx_fatal(FARGS, "You have nstcalcenergy set to a value (%d) that is different from 1.\nThis is not supported in combinations with shell particles.\nPlease make a new tpr file.", ir->nstcalcenergy);
+ }
if (shellfc && ir->eI == eiNM)
{
/* Currently shells don't work with Normal Modes */