From: Berk Hess Date: Fri, 20 Jun 2014 05:33:57 +0000 (+0200) Subject: Fixed shells with particle decomposition X-Git-Url: http://biod.pnpi.spb.ru/gitweb/?a=commitdiff_plain;h=0b396d5fccc6f838f95db4ceba5d54dea8e97374;p=alexxy%2Fgromacs.git Fixed shells with particle decomposition In the spirit of version 5.0, the recent Verlet scheme fix for shells, commit debd482d, removed the support for PD. Now it's back. Refs #1429. Change-Id: I686d4287ec8946e418aa98e739a1a81a0b7f7055 --- diff --git a/src/mdlib/shellfc.c b/src/mdlib/shellfc.c index 0acd975302..c5cb07e290 100644 --- a/src/mdlib/shellfc.c +++ b/src/mdlib/shellfc.c @@ -1013,8 +1013,15 @@ int relax_shell_flexcon(FILE *fplog, t_commrec *cr, gmx_bool bVerbose, } else { - cg0 = 0; - cg1 = top->cgs.nr; + if (PARTDECOMP(cr)) + { + pd_cg_range(cr, &cg0, &cg1); + } + else + { + cg0 = 0; + cg1 = top->cgs.nr; + } put_charge_groups_in_box(fplog, cg0, cg1, fr->ePBC, state->box, &(top->cgs), state->x, fr->cg_cm); }