Open glwagner opened 3 years ago
Sounds very exciting! As I mentioned, I have a student who would be very interested in working on the sigma-coordinate model, which would hopefully help with the end goal.
A thorny detail is accurate calculate of pressure gradients for strongly warped coordinates.
Looking into the literature a little bit, it appears that the current pressure gradient force formulation may be sufficient for "weak" GVC, which include the "z-star" coordinate introduced by Adcroft and Campin (2004) (rescaling of the vertical coordinate by sea surface displacement) and the "z-tilde" coordinate introduced by Leclair and Madec (2011) (semi-Lagrangian vertical coordinate that follows high-pass filtered fast motions only and is restored to a target grid on a relatively short time scale).
Other formulations, including classical sigma coordinates and quasi-Lagrangian methods that involve grid warping severe enough to require remapping, may fail unless we improve our method for calculating the horizontal pressure gradient force. In particular, the method we use now is essentially finite difference and requires a vertical coordinate that exactly or "almost" coincides with a geopotential surface.
Finite volume treatment of the pressure gradient force is discussed by
Just a detail:sigma coordinate does also moves in time with SSH (when the bottom is flat, sigma and z* are the same).
Ah, that makes sense since the rescaling sets the surface (z=eta) as sigma=0, rather than z=0. Thanks for that clarification @jm-c !
@simone-silvestri here's some description of the GVC problem. There's additional discussion on #1549.
Today, we discussed whether the prognostic variable in a model formulated with a generalized vertical coordinate is thickness weighted velocity hu
, or velocity u
(which has also come up on #2522).
Based on some discussion and consultation with papers it seems that we want both, because we evolve hu
when we use "flux form" or "conservative form" momentum advection, but we evolve u
when we use "vector invariant" advection. This choice has consequences beyond momentum advection though (I think).
Also, whichever momentum variable we prognose, we always prognose the thickness weighted tracer concentration hc
.
Thoughts on this are very welcome @jm-c @jmbeckers !
In the "z-tilde" paper by Leclair and Madec 2011, we find
I think e3
above is our h
.
The equations of motion for most or all major ocean modeling software are implemented using a "Generalized Vertical Coordinate" (GVC). Generalized vertical coordinates contain a "fixed z" coordinate as a limiting case, but generalize to vertical coordinates that
σ
coordinates);A fully general GVC typically also requires a "Lagrangian remapping" step to avoid extreme grid distortions in regions of persistent vertical velocities.
The implementation of GVC is likely a major refactoring of
HydrostaticFreeSurfaceModel
because it will change the equations of motion and could even potentially change the nature of its prognostic variables. For time-dependent GVC, tracer equations must be reformulated in terms of the "thickness-weighted" tracer concentration, which in our case means the tracer concentration normalized by the local grid spacing. This could mean either using the thickness-weighted tracer conservation as a state variable, or it could mean rewriting the time-stepping algorithm so that unweighted tracer conservation can be updated according to the conservation of thickness-weighted tracer.A preliminary roadmap towards GVC in
HydrostaticFreeSurfaceModel
isIntroduce
AbstractVerticalCoordinate
and refactor theHydrostaticFreeSurfaceModel
to integrate thickness-weighted equations. When usingZCoordinate
, the resulting model produces identical results to the current implementation ofHydrostaticFreeSurfaceModel
. I think we will also want a rectilinear grid to use for testing to avoid modifyingRegularRectilinearGrid
, such as a refactored or reimplemented three-dimensionallyStretchedRectilinearGrid
from #1532 which accepts the use of a generalized vertical coordinates.Introduce
ZStarCoordinate
(or maybeFreeSurfaceWeightedVerticalCoordinate
). "z-star" vertical coordinate is a relatively simple GVC, with a small, diagnostic time-dependence. A successful implementation will require integrating thickness-weighted equations, correct vertical derivatives, and ensuring correct horizontal pressure gradients.Implement remapping as an alternative to vertical advection and test using
ZCoordinate
andZStarCoordinate
.Of course, steps 3 might evolve depending on our experience during step 2.
An important choice that's part of step 1. is whether to use thickness-weighted variables as state variables rather than unweighted variables (eg
hu
rather thanu
, andhc
rather thanc
. I suspect it makes sense to use thickness-weighted state variables because this simplifies the underlying implementation (for example, we only needhⁿ
rather than bothhⁿ⁺¹
andhⁿ
to evolve a tracer field, and we can evaluate the prognostic equations in the same order that we do now), and because it is easy to provide abstractions for users to compute, inspect, and output unweighted variablesu = hu / h
. The pros and cons of this important choice should be discussed.The discussion on #1549 is related (I decided to start a new issue because GVC are more general than terrain-following coordinates).
Some references