# Discrete Pressure Gradient Term¶

## Pressure Gradient Term¶

Following [3], the horizontal momentum equation in the general coordinate \(r\) can be written as:

where the vector \(\cal{F}\) represents all the forcing terms other than the pressure gradient. Here, \(\vec{u}\) is the horizontal component of the velocity, \(\Phi\) is the geopotential:

\(\alpha = 1/\rho\) is the specific volume and \(p\) is the pressure. The gradient operator is a gradient along the coordinate surface \(r\).

MOM6 offers two options, an older one using a Montgomery potential as described in [25] and [61]. However, it can have the instability described in [28]. The version described here is that in [3] and is the recommended option (ANALYTIC_FV_PGF = True). The paper describes the Boussinesq form while the code supports that and also a non-Boussinesq form.

In two dimensions ( \(x\) and \(p\)), we can integrate the zonal component of the momentum equation above over a finite volume:

We convert to line integrals thanks to the Leibniz rule. See the figure for the location of the line integral ranges:

The only approximations made are (i) that the potential temperature \(\theta\) and the salinity \(s\) can be represented continuously in the vertical within each layer although discontinuities between layers are allowed and (ii) that \(\theta\) and \(s\) can be represented continuously along each layer. MOM6 has options for piecewise constant (PCM), piecewise linear (PLM), and piecewise parabolic (PPM) in the vertical.

If we use the Wright equation of state ([69]), we can integrate the above integrals analytically. This equation of state can be written as:

where \(A, \lambda\) and \(P\) are functions only of \(s\) and \(\theta\). The integral form of hydrostatic balance is:

Assuming piecewise constant values for \(\theta\) and \(s\) and the above equation of state, we get:

which is the exact solution for the continuum only if \(\theta\) and \(s\) are uniform in the interval \(p_t\) to \(p_b\). Here, we have introduced the variables:

and

We will show later that \(\epsilon \ll 1\). Note the series expansion:

Typical values for the deep ocean with 100 m layer thickness are \(6 \times 10^8\) Pa and \(10^6\) Pa, respectively, yielding \(\epsilon \sim 8 \times 10^{-4}\) and a corresponding accuracy in the geopotential height calculation of \(\frac{\lambda \epsilon^3}{g} \sim 10^{-5}\) m. For this value of \(\epsilon\), the series converges with just three terms. In MOM6, we use series rather than the intrinsic log function , since the log is machine dependent and insufficiently accurate. In extreme circumstances, \(\Delta p \sim 6 \times 10^7\) Pa (limited by the depth of the ocean) for which \(\epsilon \sim 0.04\) with geopotential height errors of order 1 m. In this case, the series converges to machine precision with six terms.

The finite volume acceleration is expression terms of four integrals around the volume, \(\int \Phi dp\). The side integrals can be calculated by direct integration of (6), which gives:

where \(\Phi, \Delta p, P, A\) and \(\lambda\) are each evaluated on the left or right side of the volume.

The top and bottom integrals in (5) must allow for the effect of varying \(\theta\) and \(s\) on \(A, \lambda\) and \(P\). We evaluate these integrals numerically using sixth-order quadrature; Boole’s rule requires evaluating the coefficients in the equation of state at five points, two of which have already been evaluated for the side integrals. For efficiency, we linearly interpolate the coefficients \(A, P\) and \(\lambda\) between the end points, which seems to make very little difference to the solution. We also verified that tenth-order quadrature makes little difference to the solution. The values of the top and bottom integrals are carried upward in a hydrostatic-like integration, obtained as follows:

The first integral is either known from the top integral of the layer below or the boundary condition at the ocean bottom. The second integral is evaluated numerically.

All the above definite integrals are specific to the Wright equation of state; the use of a different equation of state requires analytic integration of the appropriate equations. We have found, however, that high-order numerical integration appears to be sufficient. Although the numerical implementation is more general (allowing the use of arbitrary equations of state), it is significantly more expensive and so we advocate the analytic implementation for efficiency.