Closed jbisits closed 1 month ago
Thanks @jbisits, and thanks @hdrake for catching this!
Two suggestions:
PotentialEnergy
(with BuoyancyTracer
, Seawater
, etc...) produce the same result for equivalent profiles would be enough. Thoughts?I think we should add a test that would catch this in the future. Maybe just ensuring that all versions of PotentialEnergy (with BuoyancyTracer, Seawater, etc...) produce the same result for equivalent profiles would be enough. Thoughts?
I think something like this is a good idea and will be useful to have to check BackgroundPotentialEnergy
(when it is done..) produces equivalent results.
I added a test to compare the PotentialEnergy
computation in the BuoyancyTracer
and LinearEquationOfState
cases, @tomchor let me know if this is the type of thing you were thinking of.
I am not quite sure how to test against the other method as for BoussinesqEquationOfState
there are several options for the equation of state. There is already a test that for the computation of PotentialEnergy
when there is a BoussinesqEquationOfState
that performs a simple check which may be sufficient. Let me know what you think.
Thanks @hdrake for finding this! The changes are
bz_ccc
->minus_bz_ccc
plus defines $E{p} = \frac{g \rho}{\rho{0}}z = -bz$ in the docstring.Closes #175