Merge branch release-2019 into release-2020
[alexxy/gromacs.git] / src / gromacs / pulling / pull.cpp
index 4e159aa7606a9e68e05966f421ee30a7586e9fe1..c20deec924102628ce1a33e4c3a6cfa4709c0e39 100644 (file)
@@ -516,7 +516,11 @@ static void get_pull_coord_dr(struct pull_t* pull, int coord_ind, const t_pbc* p
     PullCoordSpatialData& spatialData = pcrd->spatialData;
 
     double md2;
-    if (pcrd->params.eGeom == epullgDIRPBC)
+    /* With AWH pulling we allow for periodic pulling with geometry=direction.
+     * TODO: Store a periodicity flag instead of checking for external pull provider.
+     */
+    if (pcrd->params.eGeom == epullgDIRPBC
+        || (pcrd->params.eGeom == epullgDIR && pcrd->params.eType == epullEXTERNAL))
     {
         md2 = -1;
     }