From f3c4bd6b911505085e9b397b358a6b1336feeff1 Mon Sep 17 00:00:00 2001 From: Erik Lindahl Date: Mon, 23 Jun 2014 00:01:47 +0200 Subject: [PATCH] Warn if using nsteps=0 without continuation=yes To achieve true single-point energy evaluations for a structure we should not constrain the initial conformation. This is typically done by settings nsteps=0, so grompp now warns if this is used while keeping continuation = no (the default). Fixes #1231. Change-Id: I4e65b66f6535da4206e7dbd5f7769a33c94ec12d --- src/gromacs/gmxpreprocess/readir.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/gromacs/gmxpreprocess/readir.c b/src/gromacs/gmxpreprocess/readir.c index 3c3b99f172..4dbdf75e3e 100644 --- a/src/gromacs/gmxpreprocess/readir.c +++ b/src/gromacs/gmxpreprocess/readir.c @@ -552,6 +552,11 @@ void check_ir(const char *mdparin, t_inputrec *ir, t_gromppopts *opts, } } + if (ir->nsteps == 0 && !ir->bContinuation) + { + warning_note(wi, "For a correct single-point energy evaluation with nsteps = 0, use continuation = yes to avoid constraining the input coordinates."); + } + /* LD STUFF */ if ((EI_SD(ir->eI) || ir->eI == eiBD) && ir->bContinuation && ir->ld_seed != -1) -- 2.22.0