I came across this issue, which states that assigning values to preprocessor variables (e.g., -DPOSRES_FC= ) in the .mdp file was no longer supported in GROMACS 2018.
Previously, this method allowed easy modification of position restraint force constants (POSRES_FC) during different equilibration stages:
define = -DPOSRES -DPOSRES_FC=
And in the .itp file:
#define POSRES_FC 1000.0
#endif
[ position_restraints ]
; atom type fx fy fz
1 1 POSRES_FC POSRES_FC POSRES_FC
4 1 POSRES_FC POSRES_FC POSRES_FC
7 1 POSRES_FC POSRES_FC POSRES_FC
I am using GROMACS 2024.4. Has this behavior changed in newer versions?
If not, what is the recommended approach for gradually reducing position restraints across equilibration stages?
Yes but if grompp compiles it should mean that the formalism of the ifdef statement is correct and then you risk define parameters that you did not want to use. If you do not need constants and definition as they come from other systems/tutorials I’d rather remove those definitions!