<?xml version='1.0' encoding='UTF-8' standalone='no'?>
<doxygen xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="compound.xsd" version="1.8.15">
  <compounddef id="General_Coordinate" kind="page">
    <compoundname>General_Coordinate</compoundname>
    <title>General coordinate equations</title>
    <briefdescription>
    </briefdescription>
    <detaileddescription>
<para>Transforming to a vertical coordinate <formula id="146">$r(z,x,y,t)$</formula>, with <formula id="147">$\dot{r} = \frac{\partial r}{\partial t}$</formula> ...</para>
<para>The Boussinesq hydrostatic equations of motion in general-coordinate <formula id="1">$r$</formula> are:</para>
<para>\f{eqnarray} \label{html:r-equations}\notag \ \rho_0 \left( \frac{\partial \mathbf{u}}{\partial t} + ( f + \zeta ) \, \hat{\mathbf{z}} \times \mathbf{u} +<dot caption="{r} \, \frac{\partial \mathbf{u}}{\partial r} + \nabla_r \, K \right) &amp;= -\nabla_r \, p - \rho \nabla_r \, \Phi + \boldsymbol{\mathcal{F}}">
&amp;\mbox{momentum} \label{eq:r-horz-momentum} \\
\rho \, \frac{\partial \Phi}{\partial r} + \frac{\partial p}{\partial r} &amp;= 0
&amp;\mbox{hydrostatic} \label{eq:r-hydrostatic-equation} \\
\frac{\partial z_r }{\partial t} + \nabla_r \cdot \, \left( z_r \, \mathbf{u} \right) + \frac{\partial ( z_r \, \dot{r} ) }{\partial r} &amp;= 0
&amp;\mbox{thickness} \label{eq:r-non-divergence} \\
\frac{\partial ( \theta \, z_r ) }{\partial t} + \nabla_r \cdot \left( \theta z_r \, \mathbf{u} \right) + \frac{\partial ( \theta \, z_r \, \dot{r} )}{\partial r} &amp;= z_r \boldsymbol{\mathcal{N}}_\theta^\gamma - \frac{\partial J_\theta^{(z)}}{\partial r}
&amp;\mbox{potential temp} \label{eq:r-temperature-equation} \\
\frac{\partial ( S \, z_r) }{\partial t} + \nabla_r \cdot \left( S \, z_r \, \mathbf{u} \right) + \frac{\partial ( S \, z_r \, \dot{r} )}{\partial r} &amp;= z_r \boldsymbol{\mathcal{N}}_S^\gamma - \frac{\partial J_S^{(z)}}{\partial r}
&amp;\mbox{salinity} \label{eq:r-salinity-equation} \\
\rho &amp;= \rho\left( S, \theta, -g \rho_0 z(r) \right)
&amp;\mbox{equation of state.}
\f}

The time derivatives are now computed with the generalized vertical
coordinate fixed rather than the geopotential.  We introduced the
specific thickness, \f$z_r = \partial z/\partial r\f$, which measures the
inverse vertical stratification of the vertical coordinate surfaces.

 Similar to \cite bleck2002, MOM6 is discretized in the vertical by
 integrating between surfaces of \f$r\f$ to yield layer equations where the
 layer thickness is \f$h = \int z_r dr\f$ and variables are treated as finite
 volume averages over each layer:

\f{eqnarray}
\label{html:h-equations}\notag \\
\rho_0 \left( \frac{\partial \mathbf{u}}{\partial t} + \frac{( f + \zeta )}{h} \,
\hat{\mathbf{z}} \times h \, \mathbf{u} + \underbrace{ \dot{r} \,
\frac{\partial \mathbf{u}}{\partial r} } + \nabla_r K \right) &amp;= -\nabla_r \, p -
\rho \nabla_r \, \Phi + \boldsymbol{\mathcal{F}}
&amp;\mbox{momentum} \label{eq:h-horz-momentum} \\
\rho \, \delta_r \Phi + \delta_r p &amp;= 0
&amp;\mbox{hydrostatic} \label{eq:h-hydrostatic-equation} \\
\frac{\partial h}{\partial t} + \nabla_r \cdot \left( h \, \mathbf{u} \right) +
\underbrace{ \delta_r ( z_r \dot{r} ) } &amp;= 0
&amp;\mbox{thickness} \label{eq:h-thickness-equation} \\
\frac{\partial ( \theta \, h )}{\partial t} + \nabla_r \cdot \left( \theta h \,
\mathbf{u} \right) + \underbrace{ \delta_r ( \theta \, z_r \dot{r} ) } &amp;=
h \boldsymbol{\mathcal{N}}_\theta^\gamma - \delta_r J_\theta^{(z)}
&amp;\mbox{potential temp} \label{eq:h-temperature-equation} \\
\frac{\partial ( S \, h )}{\partial t} + \nabla_r \cdot \left( S \, h \,
\mathbf{u} \right) + \underbrace{ \delta_r ( S \, z_r \dot{r} ) } &amp;=
h \boldsymbol{\mathcal{N}}_S^\gamma - \delta_r J_S^{(z)}
&amp;\mbox{salinity} \label{eq:h-salinity-equation} \\
\rho &amp;= \rho\left( S, \theta, -g \rho_0 z(r) \right)
&amp;\mbox{equation of state,} \label{eq:h-equation-of-state}
\f}

where \f$\delta_{r} = \mathrm{d}r \, (\partial/\partial r)\f$ is the discrete
vertical difference operator. The pressure gradient accelerations
in the momentum equation \latexonly\ref{eq:h-horz-momentum}\endlatexonly\htmlonly&amp;nbsp;\eqref2{h-equations,momentum}\endhtmlonly\xmlonly \\eqref4{eq:h-horz-momentum}\\eqref2{h-equations,momentum}\endxmlonly are written in
continuous-in-the-vertical form for brevity; the exact discretization
is detailed in \cite adcroft2008. The MOM6 time-stepping algorithm
integrates the above layer-averaged equations forward allowing the
vertical grid to follow the motion, i.e. \f$\dot{r}=0\f$, so that the underbraced
terms are dropped. This approach is generally known as the Lagrangian
method but here the Lagrangian method is used only in the vertical
direction. After each Lagrangian step, a remap step is applied that
generates a new vertical grid of the user&apos;s choosing. The ocean state is
then mapped from the old to the new grid. The physical state is not meant
to change during the remap step, yet truncation errors make remapping
imperfect. We employ high-order accurate reconstructions to minimize
errors introduced during the remap step (\cite white2008, \cite white2009). The
connection between time-stepping and remapping is described in
section \ref ALE_Timestep.
</dot>
</para>
    </detaileddescription>
  </compounddef>
</doxygen>
