The energy result produced by gmx mdrun can't be reproduced by gmx mdrun -rerun.
Summary
After I ran the program, gmx mdrun -nsteps 0 with GPU, I ran the other program gmx mdrun -rerun md.trr with CPU. I found that the energy results were very different between these two runnings. To find the reason for this difference, I conducted preliminary debugging. The emergence of diff could be due to the implementation of -rerun ignoring certain logic.
GROMACS version
2025-dev-20240410-d8dd4866-dirty
Steps to reproduce
By decompressing rerun_diff.tar and running run.sh, there will be two file, potential_md.xvg and potential_rerun.xvg, which include the results about gmx mdrun and gmx mdrun -rerun, respectively. rerun_diff.tar
The possible results are as follow:
In potential_md.xvg
What did you expect the correct behavior to be?
The energy results in potential_md.xvg and potential_rerun.xvg should be same.
Possible fixes