Inconsistency in the pressure calculation

GROMACS version: 2024
GROMACS modification: No

Hi everyone,

It may be a silly question, but I’ve noticed an inconsistency between the average pressure output on GROMACS and the average pressure calculated with the generated .xvg file. For example, for a certain simulation, the output is:

Energy Average Err.Est. RMSD Tot-Drift

Pressure 1.15318 0.27 308.222 -0.507331 (bar)

However, when calculating the average pressure through the .xvg file on Python, I get -48.23 bar. Is there an explanation? Am I doing something wrong?

Thanks!

As it says in the gmx energy description gmx energy - GROMACS 2024.4 documentation :

“Average, RMSD, and drift are calculated with full precision from the simulation
(see printed manual). Drift is calculated by performing a least-squares fit of the
data to a straight line. The reported total drift is the difference of the fit at the first
and last point. An error estimate of the average is given based on a block
averages over 5 blocks using the full-precision averages. The error estimate can
be performed over multiple block lengths with the options -nbmin and -nbmax.
Note that in most cases the energy files contains averages over all MD steps, or
over many more points than the number of frames in energy file. This makes the
gmx energy statistics output more accurate than the .xvg output. When exact
averages are not present in the energy file, the statistics mentioned above are
simply over the single, per-frame energy values.”