Pull code (umbrella, distance): Fatal error "Pull reference distance … needs to be non-negative"

GROMACS version: 2025.1
GROMACS modification: No

I’m using the pull option in GROMACS to bring together two backbone portions (see image below). I monitored the distance between the centers of mass (COM) of both backbone groups versus time:

In the plot above, the vertical lines indicate where the simulation stopped due to the error shown in the following table. After each crash I restarted the simulation (lowering as well the pulling rate):

Pull rate (nm/ps) Time (this run) Error / note in .log Time (cumulative)
-0.005 1.276 ns Fatal error:
Pull reference distance for coordinate 1 (-0.000009) needs to be non-negative
-0.0005 2.276 ns No fatal error. Simulation runs cleanly for the 1 ns we asked for. 2.276 ns
-0.0005 2.832 ns Fatal error:
Pull reference distance for coordinate 1 (-0.000000) needs to be non-negative
5.108 ns
-0.0005 2.178 ns Fatal error:
Pull reference distance for coordinate 1 (-0.000000) needs to be non-negative
7.286 ns

Visualization suggests both backbones can come even closer than 9.86 Ang (the distance of the last snapshot of the last run, before crash).

Is there a way to overcome this “Fatal error” and bring them closer?

Here the full .mdp of the last run:

integrator              = md
dt                      = 0.002

nsteps                  =  4500000
nstxout-compressed      = 5000
nstxout                 = 0
nstvout                 = 0
nstfout                 = 0
nstcalcenergy           = 100
nstenergy               = 1000
nstlog                  = 1000
;

cutoff-scheme           = Verlet
nstlist                 = 20
vdwtype                 = Cut-off
vdw-modifier            = Force-switch
rvdw_switch             = 1.0
rvdw                    = 1.2
rlist                   = 1.2
rcoulomb                = 1.2
coulombtype             = PME
;

tcoupl                  = v-rescale
tc_grps                 = SOLU SOLV
tau_t                   = 1.0 1.0
ref_t                   = 303.15 303.15
;

pcoupl                  = C-rescale
pcoupltype              = isotropic
tau_p                   = 5.0
compressibility         = 4.5e-5
ref_p                   = 1.0
;

constraints             = h-bonds
constraint_algorithm    = LINCS
continuation            = yes
;

nstcomm                 = 100
comm_mode               = linear
comm_grps               = SOLU SOLV
;

; -------------------
; Pull code additions
; -------------------
pull                        = yes
pull-ngroups                = 2
pull-ncoords                = 1

pull-group1-name            = backbone_a_patch_5
pull-group2-name            = backbone_c_patch

pull-coord1-type            = umbrella
pull-coord1-geometry        = distance
pull-coord1-groups          = 1 2
pull-coord1-dim             = Y Y Y

; Start from the current distance (recommended)
pull-coord1-start       = yes

; Spring constant (kJ/mol/nm^2)
pull-coord1-k           = 1000

; Pull rate (nm/ps). Negative means decreasing distance.
pull-coord1-rate        = -0.0005  

pull-pbc-ref-prev-step-com  = yes

pull-nstxout                = 1000 

The fatal error is not on the actual distance, but on the reference distance. You can not require a negative distance. If you want the distance to get smaller, you can try a large force constant. But obstacles can prevent the distance from getting shorter.