Skip to content

Fixed incorrect cosmology factors for pressure and internal energy in the i/o

Josh Borrow requested to merge fix-internal-energy-cosmo into master

Previously we were writing that the internal energy transformed as a^{3(\gamma-1)}, which is incorrect. The pressures were also written to transform as a^{3\gamma}. In this MR I have rectified this to be correct, as

image

As we store P' and want the conversion factor to physical, we need it to be a^{-3\gamma}.

As for the internal energy, we can have a similar argument

image

where we need the factor for u to be a^{-3(\gamma - 1)}.

Merge request reports