New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 2282 for branches/nemo_v3_3_beta/DOC/TexFiles/Chapters/Annex_C.tex – NEMO

Ignore:
Timestamp:
2010-10-15T16:42:00+02:00 (14 years ago)
Author:
gm
Message:

ticket:#658 merge DOC of all the branches that form the v3.3 beta

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/nemo_v3_3_beta/DOC/TexFiles/Chapters/Annex_C.tex

    r1223 r2282  
    77 
    88%%%  Appendix put in gmcomment as it has not been updated for z* and s coordinate 
    9 I'm writting this appendix. It will be available in a forthcoming release of the documentation 
     9%I'm writting this appendix. It will be available in a forthcoming release of the documentation 
    1010 
    1111%\gmcomment{ 
    1212 
    13 % ================================================================ 
    14 % Conservation Properties on Ocean Dynamics 
    15 % ================================================================ 
    16 \section{Conservation Properties on Ocean Dynamics} 
     13\newpage 
     14$\ $\newline    % force a new ligne 
     15 
     16% ================================================================ 
     17% Introduction / Notations 
     18% ================================================================ 
     19\section{Introduction / Notations} 
     20\label{Apdx_C.0} 
     21 
     22Notation used in this appendix in the demonstations : 
     23 
     24fluxes at the faces of a $T$-box: 
     25\begin{equation*} 
     26U = e_{2u}\,e_{3u}\; u  \qquad  V = e_{1v}\,e_{3v}\; v  \qquad W = e_{1w}\,e_{2w}\; \omega     \\ 
     27\end{equation*} 
     28 
     29volume of cells at $u$-, $v$-, and $T$-points: 
     30\begin{equation*} 
     31b_u = e_{1u}\,e_{2u}\,e_{3u}  \qquad  b_v = e_{1v}\,e_{2v}\,e_{3v}  \qquad b_t = e_{1t}\,e_{2t}\,e_{3t}     \\ 
     32\end{equation*} 
     33 
     34partial derivative notation: $\partial_\bullet = \frac{\partial}{\partial \bullet}$ 
     35 
     36$dv=e_1\,e_2\,e_3 \,di\,dj\,dk$  is the volume element, with only $e_3$ that depends on time. 
     37$D$ and $S$ are the ocean domain volume and surface, respectively.  
     38No wetting/drying is allow ($i.e.$ $\frac{\partial S}{\partial t} = 0$)  
     39Let $k_s$ and $k_b$ be the ocean surface and bottom, resp.  
     40($i.e.$ $s(k_s) = \eta$ and $s(k_b)=-H$, where $H$ is the bottom depth). 
     41\begin{flalign*} 
     42 z(k) = \eta - \int\limits_{\tilde{k}=k}^{\tilde{k}=k_s}  e_3(\tilde{k}) \;d\tilde{k} 
     43        = \eta - \int\limits_k^{k_s}  e_3 \;d\tilde{k}  
     44\end{flalign*} 
     45 
     46Continuity equation with the above notation: 
     47\begin{equation*} 
     48\frac{1}{e_{3t}} \partial_t (e_{3t})+ \frac{1}{b_t}  \biggl\{  \delta_i [U] + \delta_j [V] + \delta_k [W] \biggr\} = 0 
     49\end{equation*} 
     50 
     51A quantity, $Q$ is conserved when its domain averaged time change is zero, that is when: 
     52\begin{equation*} 
     53\partial_t \left( \int_D{ Q\;dv } \right) =0 
     54\end{equation*} 
     55Noting that the coordinate system used ....  blah blah 
     56\begin{equation*} 
     57\partial_t \left( \int_D {Q\;dv} \right) =  \int_D { \partial_t \left( e_3 \, Q \right) e_1e_2\;di\,dj\,dk } 
     58                                                       =  \int_D { \frac{1}{e_3} \partial_t \left( e_3 \, Q \right) dv } =0 
     59\end{equation*} 
     60equation of evolution of $Q$ written as the time evolution of the vertical content of $Q$ 
     61like for tracers, or momentum in flux form, the quadratic quantity $\frac{1}{2}Q^2$ is conserved when : 
     62\begin{flalign*} 
     63\partial_t \left(   \int_D{ \frac{1}{2} \,Q^2\;dv }   \right) 
     64=&  \int_D{ \frac{1}{2} \partial_t \left( \frac{1}{e_3}\left( e_3 \, Q \right)^2 \right) e_1e_2\;di\,dj\,dk } \\ 
     65=&  \int_D {         Q   \;\partial_t\left( e_3 \, Q \right) e_1e_2\;di\,dj\,dk }   
     66-  \int_D { \frac{1}{2} Q^2 \,\partial_t  (e_3) \;e_1e_2\;di\,dj\,dk } \\ 
     67\end{flalign*} 
     68that is in a more compact form : 
     69\begin{flalign} \label{Eq_Q2_flux} 
     70\partial_t \left( \int_D {\frac{1}{2} Q^2\;dv} \right) 
     71=&                   \int_D { \frac{Q}{e_3}  \partial_t \left( e_3 \, Q \right) dv }   
     72  -   \frac{1}{2} \int_D {  \frac{Q^2}{e_3} \partial_t (e_3) \;dv } 
     73\end{flalign} 
     74equation of evolution of $Q$ written as the time evolution of $Q$ 
     75like for momentum in vector invariant form, the quadratic quantity $\frac{1}{2}Q^2$ is conserved when : 
     76\begin{flalign*} 
     77\partial_t \left( \int_D {\frac{1}{2} Q^2\;dv} \right) 
     78=&  \int_D { \frac{1}{2} \partial_t \left( e_3 \, Q^2 \right) \;e_1e_2\;di\,dj\,dk } \\ 
     79=& \int_D {         Q      \partial_t Q  \;e_1e_2e_3\;di\,dj\,dk }   
     80+  \int_D { \frac{1}{2} Q^2 \, \partial_t e_3  \;e_1e_2\;di\,dj\,dk } \\ 
     81\end{flalign*} 
     82that is in a more compact form : 
     83\begin{flalign} \label{Eq_Q2_vect} 
     84\partial_t \left( \int_D {\frac{1}{2} Q^2\;dv} \right) 
     85=& \int_D {         Q   \,\partial_t Q  \;dv }   
     86+   \frac{1}{2} \int_D { \frac{1}{e_3} Q^2 \partial_t e_3 \;dv } 
     87\end{flalign} 
     88 
     89 
     90% ================================================================ 
     91% Continuous Total energy Conservation 
     92% ================================================================ 
     93\section{Continuous conservation} 
    1794\label{Apdx_C.1} 
    1895 
    19 First, the boundary condition on the vertical velocity (no flux through the surface  
    20 and the bottom) is established for the discrete set of momentum equations.  
    21 Then, it is shown that the non-linear terms of the momentum equation are written  
    22 such that the potential enstrophy of a horizontally non-divergent flow is preserved  
    23 while all the other non-diffusive terms preserve the kinetic energy; in practice the  
    24 energy is also preserved. In addition, an option is also offered for the vorticity term  
    25 discretization which provides a total kinetic energy conserving discretization for  
    26 that term.  
    27  
    28 Nota Bene: these properties are established here in the rigid-lid case and for the  
    29 2nd order centered scheme. A forthcoming update will be their generalisation to  
    30 the free surface case and higher order scheme. 
    31  
    32 % ------------------------------------------------------------------------------------------------------------- 
    33 %       Bottom Boundary Condition on Vertical Velocity Field 
    34 % ------------------------------------------------------------------------------------------------------------- 
    35 \subsection{Bottom Boundary Condition on Vertical Velocity Field} 
    36 \label{Apdx_C.1.1} 
    37  
    38  
    39 The discrete set of momentum equations used in the rigid-lid approximation  
    40 automatically satisfies the surface and bottom boundary conditions  
    41 (no flux through the surface and the bottom: $w_{surface} =w_{bottom} =~0$).  
    42 Indeed, taking the discrete horizontal divergence of the vertical sum of the  
    43 horizontal momentum equations (!!!Eqs. (II.2.1) and (II.2.2)!!!) weighted by the  
    44 vertical scale factors, it becomes: 
    45 \begin{flalign*} 
    46 \frac{\partial } {\partial t}  \left( \sum\limits_k    \chi    \right) 
    47 \equiv  
    48 \frac{\partial } {\partial t}  \left(  w_{surface} -w_{bottom}     \right)&&&\\ 
    49 \end{flalign*} 
    50 \begin{flalign*} 
    51 \equiv \frac{1} {e_{1T}\,e_{2T}\,e_{3T}}  
    52    \biggl\{ \quad 
    53    \delta_i  
    54       &\left[  
    55       e_{2u}\,H_u  
    56          \left(  
    57          M_u - M_u - \frac{1} {H_u\,e_{2u}} \delta_j  
    58             \left[ \partial_t\, \psi \right]  
    59          \right)  
    60       \right] && 
    61    \biggr. \\ 
    62    \biggl.  
    63    + \delta_j  
    64       &\left[  
    65       e_{1v}\,H_v  
    66          \left( M_v - M_v - \frac{1} {H_v\,e_{1v}} \delta_i  
    67             \left[ \partial_i\, \psi \right]  
    68          \right)  
    69       \right]  
    70    \biggr\}&& \\ 
    71 \end{flalign*} 
    72 \begin{flalign*} 
    73 \equiv \frac{1} {e_{1T} \,e_{2T} \,e_{3T}} \; 
    74    \biggl\{  
    75    - \delta_i  
    76       \Bigl[  
    77       \delta_j  
    78          \left[ \partial_t \psi  \right]  
    79       \Bigr] 
    80    + \delta_j  
    81       \Bigl[  
    82       \delta_i  
    83          \left[ \partial_t \psi  \right]  
    84       \Bigr]\;  
    85    \biggr\}\; 
    86    \equiv 0 
    87    &&&\\ 
    88 \end{flalign*} 
    89  
    90  
    91 The surface boundary condition associated with the rigid lid approximation  
    92 ($w_{surface} =0)$ is imposed in the computation of the vertical velocity (!!! II.2.5!!!!).  
    93 Therefore, it turns out to be: 
     96 
     97The discretization of pimitive equation in $s$-coordinate ($i.e.$ time and space varying  
     98vertical coordinate) must be chosen so that the discrete equation of the model satisfy  
     99integral constrains on energy and enstrophy.  
     100 
     101 
     102Let us first establish those constraint in the continuous world. 
     103The total energy ($i.e.$ kinetic plus potential energies) is conserved : 
     104\begin{flalign} \label{Eq_Tot_Energy} 
     105  \partial_t \left( \int_D \left( \frac{1}{2} {\textbf{U}_h}^2 +  \rho \, g \, z \right) \;dv \right)  = & 0 
     106\end{flalign} 
     107under the following assumptions: no dissipation, no forcing  
     108(wind, buoyancy flux, atmospheric pressure variations), mass  
     109conservation, and closed domain.  
     110 
     111This equation can be transformed to obtain several sub-equalities.  
     112The transformation for the advection term depends on whether  
     113the vector invariant form or the flux form is used for the momentum equation. 
     114Using \eqref{Eq_Q2_vect} and introducing \eqref{Apdx_A_dyn_vect} in \eqref{Eq_Tot_Energy}  
     115for the former form and 
     116Using \eqref{Eq_Q2_flux} and introducing \eqref{Apdx_A_dyn_flux} in \eqref{Eq_Tot_Energy}  
     117for the latter form  leads to: 
     118 
     119\begin{subequations} \label{E_tot} 
     120 
     121advection term (vector invariant form): 
     122\begin{equation} \label{E_tot_vect_vor} 
     123\int\limits_D  \zeta \; \left( \textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv   = 0   \\ 
     124\end{equation} 
     125% 
     126\begin{equation} \label{E_tot_vect_adv} 
     127   \int\limits_D  \textbf{U}_h \cdot \nabla_h \left( \frac{{\textbf{U}_h}^2}{2} \right)     dv  
     128+ \int\limits_D  \textbf{U}_h \cdot \nabla_z \textbf{U}_h  \;dv     
     129-  \int\limits_D { \frac{{\textbf{U}_h}^2}{2} \frac{1}{e_3} \partial_t e_3 \;dv }   = 0   \\ 
     130\end{equation} 
     131 
     132advection term (flux form): 
     133\begin{equation} \label{E_tot_flux_metric} 
     134\int\limits_D  \frac{1} {e_1 e_2 } \left( v \,\partial_i e_2 - u \,\partial_j e_1  \right)\;  
     135 \left(  \textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv   = 0   \\ 
     136\end{equation} 
     137 
     138\begin{equation} \label{E_tot_flux_adv} 
     139   \int\limits_D \textbf{U}_h \cdot     \left(                 {{\begin{array} {*{20}c} 
     140\nabla \cdot \left( \textbf{U}\,u \right) \hfill \\ 
     141\nabla \cdot \left( \textbf{U}\,v \right) \hfill \\       \end{array}} }           \right)   \;dv  
     142+   \frac{1}{2} \int\limits_D {  {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t e_3 \;dv } =\;0  \\ 
     143\end{equation} 
     144 
     145coriolis term 
     146\begin{equation} \label{E_tot_cor} 
     147\int\limits_D  f   \; \left( \textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv   = 0   \\ 
     148\end{equation} 
     149 
     150pressure gradient: 
     151\begin{equation} \label{E_tot_pg} 
     152   - \int\limits_D  \left. \nabla p \right|_z \cdot \textbf{U}_h \;dv  
     153= - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
     154   + \int\limits_D g\, \rho \; \partial_t z  \;dv   \\ 
     155\end{equation} 
     156\end{subequations} 
     157 
     158where $\nabla_h = \left. \nabla \right|_k$ is the gradient along the $s$-surfaces. 
     159 
     160blah blah.... 
     161$\ $\newline    % force a new ligne 
     162The prognostic ocean dynamics equation can be summarized as follows: 
    94163\begin{equation*} 
    95 \frac{\partial } {\partial t}w_{bottom} \equiv 0 
     164\text{NXT} = \dbinom {\text{VOR} + \text{KEG} + \text {ZAD} } 
     165                  {\text{COR} + \text{ADV}                       } 
     166         + \text{HPG} + \text{SPG} + \text{LDF} + \text{ZDF} 
    96167\end{equation*} 
    97 As the bottom velocity is initially set to zero, it remains zero all the time.  
    98 Symmetrically, if $w_{bottom} =0$ is used in the computation of the vertical  
    99 velocity (upward integral of the horizontal divergence), the same computation  
    100 leads to $w_{surface} =0$ as soon as the surface vertical velocity is initially  
    101 set to zero. 
    102  
    103 % ------------------------------------------------------------------------------------------------------------- 
    104 %       Coriolis and advection terms: vector invariant form 
    105 % ------------------------------------------------------------------------------------------------------------- 
    106 \subsection{Coriolis and advection terms: vector invariant form} 
    107 \label{Apdx_C_vor_zad} 
    108  
    109 % ------------------------------------------------------------------------------------------------------------- 
    110 %       Vorticity Term 
    111 % ------------------------------------------------------------------------------------------------------------- 
    112 \subsubsection{Vorticity Term} 
    113 \label{Apdx_C_vor}  
    114  
    115 Potential vorticity is located at $f$-points and defined as: $\zeta / e_{3f}$.  
    116 The standard discrete formulation of the relative vorticity term obviously  
    117 conserves potential vorticity (ENS scheme). It also conserves the potential  
    118 enstrophy for a horizontally non-divergent flow (i.e. $\chi $=0) but not the  
    119 total kinetic energy. Indeed, using the symmetry or skew symmetry properties  
    120 of the operators (Eqs \eqref{DOM_mi_adj} and \eqref{DOM_di_adj}), it can  
    121 be shown that: 
    122 \begin{equation} \label{Apdx_C_1.1} 
    123 \int_D {\zeta / e_3\,\;{\textbf{k}}\cdot \frac{1} {e_3} \nabla \times \left( {\zeta \;{\textbf{k}}\times {\textbf{U}}_h } \right)\;dv} \equiv 0 
     168$\ $\newline    % force a new ligne 
     169 
     170Vector invariant form: 
     171\begin{subequations} \label{E_tot_vect} 
     172\begin{equation} \label{E_tot_vect_vor} 
     173\int\limits_D   \textbf{U}_h \cdot \text{VOR} \;dv   = 0   \\ 
    124174\end{equation} 
    125 where $dv=e_1\,e_2\,e_3 \; di\,dj\,dk$ is the volume element. Indeed, using  
    126 \eqref{Eq_dynvor_ens}, the discrete form of the right hand side of \eqref{Apdx_C_1.1}  
    127 can be transformed as follow: 
    128 \begin{flalign*}  
    129 &\int_D \zeta / e_3\,\; \textbf{k} \cdot \frac{1} {e_3 } \nabla \times  
    130    \left(  
    131    \zeta \; \textbf{k} \times  \textbf{U}_h   
    132    \right)\; 
    133    dv 
    134    &&& \displaybreak[0] \\ 
    135 % 
    136 \equiv& \sum\limits_{i,j,k}  
    137 \frac{\zeta / e_{3f}} {e_{1f}\,e_{2f}\,e_{3f}}  
    138    \biggl\{ \quad 
    139    \delta_{i+1/2}  
    140       \left[  
    141          - \overline {\left( {\zeta / e_{3f}} \right)}^{\,i}\; 
    142             \overline{\overline {\left( e_{2u}\,e_{3u}\,u \right)}}^{\,i,j+1/ 2}  
    143        \right]   
    144    &&  \\ & \qquad \qquad \qquad \;\; 
    145    - \delta_{j+1/2}  
    146       \left[   \;\;\; 
    147            \overline {\left( \zeta / e_{3f} \right)}^{\,j}\; 
    148            \overline{\overline {\left( e_{1v}\,e_{3v}\,v \right)}}^{\,i+1/2,j}  
    149       \right]  
    150    \;\;\biggr\} \;  e_{1f}\,e_{2f}\,e_{3f}       && \displaybreak[0] \\  
    151 % 
    152 \equiv& \sum\limits_{i,j,k}  
    153    \biggl\{   \delta_i     \left[   \frac{\zeta} {e_{3f}}   \right] \; 
    154            \overline{  \left(   \frac{\zeta} {e_{3f}}   \right)  }^{\,i}\;  
    155            \overline{  \overline{   \left( e_{1u}\,e_{3u}\,u \right)  }  }^{\,i,j+1/2}  
    156          + \delta_j   \left[   \frac{\zeta} {e_{3f}}   \right] \; 
    157             \overline{   \left(  \frac{\zeta} {e_{3f}}    \right)  }^{\,j} \;  
    158       \overline{\overline {\left( e_{2v}\,e_{3v}\,v \right)}}^{\,i+1/2,j}         \biggr\}  
    159       &&&& \displaybreak[0] \\  
    160 % 
    161 \equiv& \frac{1} {2} \sum\limits_{i,j,k}   
    162    \biggl\{ \delta_i    \Bigl[    \left(  \frac{\zeta} {e_{3f}} \right)^2   \Bigr]\; 
    163          \overline{\overline {\left( e_{2u}\,e_{3u}\,u \right)}}^{\,i,j+1/2}  
    164             + \delta_j  \Bigl[    \left( \zeta / e_{3f} \right)^2     \Bigr]\;  
    165          \overline{\overline {\left( e_{1v}\,e_{3v}\,v \right)}}^{\,i+1/2,j}  
    166    \biggr\}  
    167    && \displaybreak[0] \\  
    168 % 
    169 \equiv& - \frac{1} {2} \sum\limits_{i,j,k}   \left(  \frac{\zeta} {e_{3f}} \right)^2\; 
    170    \biggl\{    \delta_{i+1/2}  
    171          \left[   \overline{\overline {\left( e_{2u}\,e_{3u}\,u \right)}}^{\,i,j+1/2}    \right]   
    172                + \delta_{j+1/2} 
    173       \left[   \overline{\overline {\left( e_{1v}\,e_{3v}\,v \right)}}^{\,i+1/2,j}     \right]   
    174    \biggr\}    && \\  
    175 \end{flalign*} 
    176 Since $\overline {\;\cdot \;} $ and $\delta $ operators commute: $\delta_{i+1/2}  
    177 \left[ {\overline a^{\,i}} \right] = \overline {\delta_i \left[ a \right]}^{\,i+1/2}$,  
    178 and introducing the horizontal divergence $\chi $, it becomes: 
    179 \begin{align*} 
    180 \equiv& \sum\limits_{i,j,k} - \frac{1} {2} \left(  \frac{\zeta} {e_{3f}} \right)^2 \; \overline{\overline{ e_{1T}\,e_{2T}\,e_{3T}\, \chi}}^{\,i+1/2,j+1/2} \;\;\equiv 0  
    181 \qquad \qquad \qquad \qquad \qquad \qquad \qquad &&&&\\ 
    182 \end{align*} 
    183  
    184 Note that the derivation is demonstrated here for the relative potential  
    185 vorticity but it applies also to the planetary ($f/e_3$) and the total  
    186 potential vorticity $((\zeta +f) /e_3 )$. Another formulation of the two  
    187 components of the vorticity term is optionally offered (ENE scheme) : 
     175\begin{equation} \label{E_tot_vect_adv} 
     176   \int\limits_D  \textbf{U}_h \cdot \text{KEG}  \;dv  
     177+ \int\limits_D  \textbf{U}_h \cdot \text{ZAD}  \;dv     
     178-  \int\limits_D { \frac{{\textbf{U}_h}^2}{2} \frac{1}{e_3} \partial_t e_3 \;dv }   = 0   \\ 
     179\end{equation} 
     180\begin{equation} \label{E_tot_pg} 
     181   - \int\limits_D  \textbf{U}_h \cdot (\text{HPG}+ \text{SPG}) \;dv  
     182= - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
     183   + \int\limits_D g\, \rho \; \partial_t z  \;dv   \\ 
     184\end{equation} 
     185\end{subequations} 
     186 
     187Flux form: 
     188\begin{subequations} \label{E_tot_flux} 
     189\begin{equation} \label{E_tot_flux_metric} 
     190\int\limits_D  \textbf{U}_h \cdot \text {COR} \;  dv   = 0   \\ 
     191\end{equation} 
     192\begin{equation} \label{E_tot_flux_adv} 
     193   \int\limits_D \textbf{U}_h \cdot \text{ADV}   \;dv  
     194+   \frac{1}{2} \int\limits_D {  {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t e_3  \;dv } =\;0  \\ 
     195\end{equation} 
     196\begin{equation} \label{E_tot_pg} 
     197   - \int\limits_D  \textbf{U}_h \cdot (\text{HPG}+ \text{SPG}) \;dv  
     198= - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
     199   + \int\limits_D g\, \rho \; \partial_t  z  \;dv   \\ 
     200\end{equation} 
     201\end{subequations} 
     202 
     203 
     204$\ $\newline    % force a new ligne 
     205 
     206 
     207\eqref{E_tot_pg} is the balance between the conversion KE to PE and PE to KE.  
     208Indeed the left hand side of \eqref{E_tot_pg} can be transformed as follows: 
     209\begin{flalign*} 
     210\partial_t  \left( \int\limits_D { \rho \, g \, z  \;dv} \right)  
     211&= + \int\limits_D \frac{1}{e_3} \partial_t (e_3\,\rho) \;g\;z\;\;dv 
     212     +  \int\limits_D g\, \rho \; \partial_t z  \;dv   &&&\\ 
     213&= - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
     214     + \int\limits_D g\, \rho \; \partial_t z \;dv   &&&\\ 
     215&= + \int\limits_D  \rho \,g \left( \textbf {U}_h \cdot \nabla_h z + \omega \frac{1}{e_3} \partial_k z \right)  \;dv 
     216     + \int\limits_D g\, \rho \; \partial_t z \;dv   &&&\\ 
     217&= + \int\limits_D  \rho \,g \left( \omega + \partial_t z + \textbf {U}_h \cdot \nabla_h z  \right)  \;dv  &&&\\ 
     218&=+  \int\limits_D g\, \rho \; w \; dv   &&&\\ 
     219\end{flalign*} 
     220where the last equality is obtained by noting that the brackets is exactly the expression of $w$,  
     221the vertical velocity referenced to the fixe $z$-coordinate system (see \eqref{Apdx_A_w_s}).  
     222  
     223The left hand side of \eqref{E_tot_pg} can be transformed as follows: 
     224\begin{flalign*} 
     225- \int\limits_D  \left. \nabla p \right|_z & \cdot \textbf{U}_h \;dv   
     226= - \int\limits_D  \left( \nabla_h p + \rho \, g \nabla_h z \right) \cdot \textbf{U}_h \;dv   &&&\\ 
     227\allowdisplaybreaks 
     228&= - \int\limits_D  \nabla_h  p \cdot \textbf{U}_h \;dv   - \int\limits_D  \rho \, g \, \nabla_h z \cdot \textbf{U}_h \;dv   &&&\\ 
     229\allowdisplaybreaks 
     230&= +\int\limits_D p \,\nabla_h \cdot \textbf{U}_h \;dv   + \int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
     231\allowdisplaybreaks 
     232&= -\int\limits_D p \left( \frac{1}{e_3} \partial_t e_3 + \frac{1}{e_3} \partial_k \omega  \right) \;dv 
     233    +\int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
     234\allowdisplaybreaks 
     235&= -\int\limits_D \frac{p}{e_3} \partial_t e_3  \;dv     
     236     +\int\limits_D \frac{1}{e_3} \partial_k p\; \omega \;dv 
     237    +\int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
     238&= -\int\limits_D \frac{p}{e_3} \partial_t e_3  \;dv     
     239     -\int\limits_D \rho \, g \, \omega \;dv 
     240    +\int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
     241&= - \int\limits_D \frac{p}{e_3} \partial_t e_3 \; \;dv     
     242     - \int\limits_D  \rho \, g \, w \;dv  
     243     + \int\limits_D   \rho \, g \, \partial_t z \;dv   &&&\\ 
     244\allowdisplaybreaks 
     245\intertext{introducing the hydrostatic balance $\partial_k p=-\rho \,g\,e_3$ in the last term, 
     246it becomes:} 
     247&= - \int\limits_D \frac{p}{e_3} \partial_t e_3 \;dv     
     248     - \int\limits_D  \rho \, g \, w \;dv  
     249     - \int\limits_D  \frac{1}{e_3} \partial_k p\, \partial_t z \;dv   &&&\\ 
     250&= - \int\limits_D \frac{p}{e_3} \partial_t e_3 \;dv     
     251     - \int\limits_D  \rho \, g \, w \;dv  
     252     + \int\limits_D \,\frac{p}{e_3}\partial_t ( \partial_k z )  dv   &&&\\ 
     253%  
     254&= - \int\limits_D  \rho \, g \, w \;dv   &&&\\ 
     255\end{flalign*} 
     256 
     257 
     258%gm comment 
     259\gmcomment{ 
     260% 
     261The last equality comes from the following equation, 
     262\begin{flalign*} 
     263\int\limits_D p \frac{1}{e_3} \frac{\partial e_3}{\partial t}\; \;dv     
     264     = \int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv \quad,  \\  
     265\end{flalign*} 
     266that can be demonstrated as follows: 
     267 
     268\begin{flalign*} 
     269\int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv    
     270&= \int\limits_D    \rho \, g \, \frac{\partial \eta}{\partial t} \;dv    
     271  -  \int\limits_D    \rho \, g \, \frac{\partial}{\partial t} \left(  \int\limits_k^{k_s}  e_3 \;d\tilde{k} \right) \;dv   &&&\\ 
     272&= \int\limits_D    \rho \, g \, \frac{\partial \eta}{\partial t} \;dv    
     273  -  \int\limits_D    \rho \, g    \left(  \int\limits_k^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k} \right) \;dv   &&&\\ 
     274% 
     275\allowdisplaybreaks 
     276\intertext{The second term of the right hand side can be transformed by applying the integration by part rule:  
     277$\left[ a\,b \right]_{k_b}^{k_s} = \int_{k_b}^{k_s}  a\,\frac{\partial b}{\partial k}       \;dk 
     278                                               + \int_{k_b}^{k_s}      \frac{\partial a}{\partial k} \,b \;dk $ 
     279to the following function: $a=  \int_k^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k}$  
     280and $b=  \int_k^{k_s}  \rho \, e_3 \;d\tilde{k}$ 
     281(note that $\frac{\partial}{\partial k} \left(  \int_k^{k_s}  a \;d\tilde{k}  \right) = - a$ as $k$ is the lower bound of the integral). 
     282This leads to:  } 
     283\end{flalign*} 
     284\begin{flalign*} 
     285&\left[ \int\limits_{k}^{k_s}  \frac{\partial e_3}{\partial t} \,dk \cdot \int\limits_{k}^{k_s}  \rho \, e_3 \,dk   \right]_{k_b}^{k_s} 
     286=-\int\limits_{k_b}^{k_s} \left(  \int\limits_k^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k} \right)  \rho \,e_3 \;dk 
     287  -\int\limits_{k_b}^{k_s}  \frac{\partial e_3}{\partial t}  \left(  \int\limits_k^{k_s}  \rho \, e_3 \;d\tilde{k} \right)   dk 
     288&&&\\ 
     289\allowdisplaybreaks 
     290\intertext{Noting that $\frac{\partial \eta}{\partial t}  
     291      = \frac{\partial}{\partial t}  \left( \int_{k_b}^{k_s}   e_3  \;d\tilde{k}  \right) 
     292      = \int_{k_b}^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k}$ 
     293and  
     294      $p(k) = \int_k^{k_s}  \rho \,g \, e_3 \;d\tilde{k} $,  
     295but also that $\frac{\partial \eta}{\partial t}$ does not depends on $k$, it comes: 
     296} 
     297& - \int\limits_{k_b}^{k_s}  \rho \, \frac{\partial \eta}{\partial t} \, e_3 \;dk 
     298= - \int\limits_{k_b}^{k_s} \left(  \int\limits_k^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k} \right)   \, \rho \, g   e_3\;dk 
     299   - \int\limits_{k_b}^{k_s}  \frac{\partial e_3}{\partial t} \frac{p}{g}         \;dk       &&&\\ 
     300\end{flalign*} 
     301Mutliplying by $g$ and integrating over the $(i,j)$ domain it becomes: 
     302\begin{flalign*} 
     303\int\limits_D  \rho \, g \, \left(  \int\limits_k^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k} \right)    \;dv 
     304=  \int\limits_D  \rho \, g \, \frac{\partial \eta}{\partial t} dv 
     305  - \int\limits_D  \frac{p}{e_3}\frac{\partial e_3}{\partial t}         \;dv 
     306\end{flalign*} 
     307Using this property, we therefore have: 
     308\begin{flalign*} 
     309\int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv    
     310&= \int\limits_D    \rho \, g \, \frac{\partial \eta}{\partial t}   \;dv    
     311  - \left(  \int\limits_D  \rho \, g \, \frac{\partial \eta}{\partial t} dv 
     312           - \int\limits_D  \frac{p}{e_3}\frac{\partial e_3}{\partial t}   \;dv  \right)    &&&\\ 
     313% 
     314&=\int\limits_D \frac{p}{e_3} \frac{\partial (e_3\,\rho)}{\partial t}\; \;dv      
     315\end{flalign*} 
     316% end gm comment 
     317} 
     318% 
     319 
     320 
     321% ================================================================ 
     322% Discrete Total energy Conservation : vector invariant form 
     323% ================================================================ 
     324\section{Discrete total energy conservation : vector invariant form} 
     325\label{Apdx_C.1} 
     326 
     327% ------------------------------------------------------------------------------------------------------------- 
     328%       Total energy conservation 
     329% ------------------------------------------------------------------------------------------------------------- 
     330\subsection{Total energy conservation} 
     331\label{Apdx_C_KE+PE} 
     332 
     333The discrete form of the total energy conservation, \eqref{Eq_Tot_Energy}, is given by: 
     334\begin{flalign*} 
     335\partial_t  \left(  \sum\limits_{i,j,k} \biggl\{ \frac{u^2}{2} \,b_u + \frac{v^2}{2}\, b_v +  \rho \, g \, z_t \,b_t  \biggr\} \right) &=0  \\ 
     336\end{flalign*} 
     337which in vector invariant forms, it leads to: 
     338\begin{equation} \label{KE+PE_vect_discrete}   \begin{split} 
     339                        \sum\limits_{i,j,k} \biggl\{   u\,                        \partial_t u         \;b_u  
     340                                                              + v\,                        \partial_t v          \;b_v  \biggr\} 
     341  + \frac{1}{2} \sum\limits_{i,j,k} \biggl\{  \frac{u^2}{e_{3u}}\partial_t e_{3u} \;b_u  
     342                                                             +  \frac{v^2}{e_{3v}}\partial_t e_{3v} \;b_v   \biggr\}      \\ 
     343= - \sum\limits_{i,j,k} \biggl\{ \frac{1}{e_{3t}}\partial_t (e_{3t} \rho) \, g \, z_t \;b_t  \biggr\}  
     344     - \sum\limits_{i,j,k} \biggl\{ \rho \,g\,\partial_t (z_t) \,b_t  \biggr\}                                 
     345\end{split} \end{equation} 
     346 
     347Substituting the discrete expression of the time derivative of the velocity either in vector invariant, 
     348leads to the discrete equivalent of the four equations \eqref{E_tot_flux}.  
     349 
     350% ------------------------------------------------------------------------------------------------------------- 
     351%       Vorticity term (coriolis + vorticity part of the advection) 
     352% ------------------------------------------------------------------------------------------------------------- 
     353\subsection{Vorticity term (coriolis + vorticity part of the advection)} 
     354\label{Apdx_C_vor} 
     355 
     356Let $q$, located at $f$-points, be either the relative ($q=\zeta / e_{3f}$), or   
     357the planetary ($q=f/e_{3f}$), or the total potential vorticity ($q=(\zeta +f) /e_{3f}$).  
     358Two discretisation of the vorticity term (ENE and EEN) allows the conservation of  
     359the kinetic energy. 
     360% ------------------------------------------------------------------------------------------------------------- 
     361%       Vorticity Term with ENE scheme 
     362% ------------------------------------------------------------------------------------------------------------- 
     363\subsubsection{Vorticity Term with ENE scheme (\np{ln\_dynvor\_ene}=.true.)} 
     364\label{Apdx_C_vorENE}  
     365 
     366For the ENE scheme, the two components of the vorticity term are given by : 
    188367\begin{equation*} 
    189    - \zeta \;{\textbf{k}}\times {\textbf {U}}_h  
    190 \equiv  
    191    \left( {{ 
    192    \begin{array} {*{20}c} 
     368- e_3 \, q \;{\textbf{k}}\times {\textbf {U}}_h    \equiv  
     369   \left( {{  \begin{array} {*{20}c} 
    193370      + \frac{1} {e_{1u}} \;  
    194       \overline {\left( \zeta / e_{3f}      \right)    
    195       \overline {\left( e_{1v}\,e_{3v}\,v \right)}^{\,i+1/2}} ^{\,j}  
    196       \hfill \\ 
     371      \overline {\, q \ \overline {\left( e_{1v}\,e_{3v}\,v \right)}^{\,i+1/2}} ^{\,j}        \hfill \\ 
    197372      - \frac{1} {e_{2v}} \;  
    198       \overline {\left( \zeta / e_{3f}      \right) 
    199       \overline {\left( e_{2u}\,e_{3u}\,u \right)}^{\,j+1/2}} ^{\,i}  
    200       \hfill \\ 
    201    \end{array}} }  
    202    \right) 
     373      \overline {\, q \ \overline {\left( e_{2u}\,e_{3u}\,u \right)}^{\,j+1/2}} ^{\,i}       \hfill \\ 
     374   \end{array}} }    \right) 
    203375\end{equation*} 
    204376 
    205377This formulation does not conserve the enstrophy but it does conserve the  
    206 total kinetic energy. It is also possible to mix the two formulations in order  
    207 to conserve enstrophy on the relative vorticity term and energy on the  
    208 Coriolis term. 
     378total kinetic energy. Indeed, the kinetic energy tendency associated to the  
     379vorticity term and averaged over the ocean domain can be transformed as 
     380follows: 
     381\begin{flalign*} 
     382&\int\limits_D -  \left(  e_3 \, q \;\textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv &&  \\ 
     383& \qquad \qquad {\begin{array}{*{20}l}  
     384&\equiv \sum\limits_{i,j,k}   \biggl\{     
     385     \frac{1} {e_{1u}} \overline { \,q\ \overline{ V }^{\,i+1/2}} ^{\,j} \, u \; b_u  
     386   - \frac{1} {e_{2v}}\overline { \, q\ \overline{ U }^{\,j+1/2}} ^{\,i} \, v \; b_v \; \biggr\}    \\  
     387&\equiv  \sum\limits_{i,j,k}  \biggl\{     
     388     \overline { \,q\ \overline{ V }^{\,i+1/2}}^{\,j} \; U  
     389   - \overline { \,q\ \overline{ U }^{\,j+1/2}}^{\,i} \; V  \; \biggr\}     \\ 
     390&\equiv \sum\limits_{i,j,k} q \  \biggl\{  \overline{ V }^{\,i+1/2}\; \overline{ U }^{\,j+1/2}         
     391                                              - \overline{ U }^{\,j+1/2}\; \overline{ V }^{\,i+1/2}         \biggr\}  \quad  \equiv 0 
     392\end{array} }      
     393\end{flalign*} 
     394In other words, the domain averaged kinetic energy does not change due to the vorticity term. 
     395 
     396 
     397% ------------------------------------------------------------------------------------------------------------- 
     398%       Vorticity Term with EEN scheme 
     399% ------------------------------------------------------------------------------------------------------------- 
     400\subsubsection{Vorticity Term with EEN scheme (\np{ln\_dynvor\_een}=.true.)} 
     401\label{Apdx_C_vorEEN}  
     402 
     403With the EEN scheme, the vorticity terms are represented as:  
     404\begin{equation} \label{Eq_dynvor_een} 
     405\left\{ {    \begin{aligned} 
     406 +q\,e_3 \, v  &\equiv +\frac{1}{e_{1u} }   \sum_{\substack{i_p,\,k_p}}  
     407                         {^{i+1/2-i_p}_j}  \mathbb{Q}^{i_p}_{j_p}  \left( e_{1v} e_{3v} \ v  \right)^{i+i_p-1/2}_{j+j_p}   \\ 
     408 - q\,e_3 \, u     &\equiv -\frac{1}{e_{2v} }    \sum_{\substack{i_p,\,k_p}}  
     409                         {^i_{j+1/2-j_p}}  \mathbb{Q}^{i_p}_{j_p}  \left( e_{2u} e_{3u} \ u  \right)^{i+i_p}_{j+j_p-1/2}   \\ 
     410\end{aligned}   } \right. 
     411\end{equation}  
     412where the indices $i_p$ and $k_p$ take the following value:  
     413$i_p = -1/2$ or $1/2$ and $j_p = -1/2$ or $1/2$, 
     414and the vorticity triads, ${^i_j}\mathbb{Q}^{i_p}_{j_p}$, defined at $T$-point, are given by:  
     415\begin{equation} \label{Q_triads} 
     416_i^j \mathbb{Q}^{i_p}_{j_p} 
     417= \frac{1}{12} \ \left(   q^{i-i_p}_{j+j_p} + q^{i+j_p}_{j+i_p} + q^{i+i_p}_{j-j_p}  \right) 
     418\end{equation} 
     419 
     420This formulation does conserve the total kinetic energy. Indeed, 
    209421\begin{flalign*} 
    210422&\int\limits_D - \textbf{U}_h \cdot   \left(  \zeta \;\textbf{k} \times \textbf{U}_h  \right)  \;  dv &&  \\ 
    211 \equiv& \sum\limits_{i,j,k}   \biggl\{     
    212       \overline {\left(  \frac{\zeta} {e_{3f}}      \right)  
    213         \overline {\left( e_{1v}e_{3v}v \right)}^{\,i+1/2}} ^{\,j} \, e_{2u}e_{3u}u  
    214    - \overline {\left(  \frac{\zeta} {e_{3f}}       \right)  
    215        \overline {\left( e_{2u}e_{3u}u \right)}^{\,j+1/2}} ^{\,i} \, e_{1v}e_{3v}v \; 
    216                                    \biggr\}      
     423\equiv \sum\limits_{i,j,k} &  \biggl\{  
     424       \left[  \sum_{\substack{i_p,\,k_p}}  
     425                         {^{i+1/2-i_p}_j}\mathbb{Q}^{i_p}_{j_p} \; V^{i+1/2-i_p}_{j+j_p} \right] U^{i+1/2}_{j}    %   &&\\ 
     426     - \left[  \sum_{\substack{i_p,\,k_p}}  
     427                         {^i_{j+1/2-j_p}}\mathbb{Q}^{i_p}_{j_p} \; U^{i+i_p}_{j+1/2-j_p}  \right] V^{i}_{j+1/2}    \biggr\}     && \\ 
    217428\\ 
    218 \equiv& \sum\limits_{i,j,k}  \frac{\zeta} {e_{3f}} 
    219    \biggl\{  \overline {\left( e_{1v}e_{3v} v \right)}^{\,i+1/2}\; 
    220              \overline {\left( e_{2u}e_{3u} u \right)}^{\,j+1/2}         
    221         - \overline {\left( e_{2u}e_{3u} u \right)}^{\,j+1/2}\; 
    222                \overline {\left( e_{1v}e_{3v} v \right)}^{\,i+1/2} 
    223    \biggr\} 
    224    \equiv 0 
     429\equiv \sum\limits_{i,j,k} &  \sum_{\substack{i_p,\,k_p}} \biggl\{  \ \   
     430                         {^{i+1/2-i_p}_j}\mathbb{Q}^{i_p}_{j_p} \; V^{i+1/2-i_p}_{j+j_p}  \, U^{i+1/2}_{j}     %  &&\\ 
     431                       - {^i_{j+1/2-j_p}}\mathbb{Q}^{i_p}_{j_p} \; U^{i+i_p}_{j+1/2-j_p} \, V^{i}_{j+1/2}     \ \;     \biggr\}     &&  \\ 
     432% 
     433\allowdisplaybreaks 
     434\intertext{ Expending the summation on $i_p$ and $k_p$, it becomes:} 
     435% 
     436\equiv \sum\limits_{i,j,k} & \biggl\{  \ \   
     437                    {^{i+1}_j     }\mathbb{Q}^{-1/2}_{+1/2} \;V^{i+1}_{j+1/2} \; U^{\,i+1/2}_{j}       
     438                -  {^i_{j}\quad}\mathbb{Q}^{-1/2}_{+1/2} \; U^{i-1/2}_{j}    \; V^{\,i}_{j+1/2}         &&  \\ 
     439        &       + {^{i+1}_j     }\mathbb{Q}^{-1/2}_{-1/2} \; V^{i+1}_{j-1/2} \; U^{\,i+1/2}_{j}         
     440                  - {^i_{j+1}     }\mathbb{Q}^{-1/2}_{-1/2} \; U^{i-1/2}_{j+1} \; V^{\,i}_{j+1/2}        \biggr.     &&  \\ 
     441        &       + {^{i}_j\quad}\mathbb{Q}^{+1/2}_{+1/2} \; V^{i}_{j+1/2}   \; U^{\,i+1/2}_{j}       
     442                  - {^i_{j}\quad}\mathbb{Q}^{+1/2}_{+1/2} \; U^{i+1/2}_{j}   \; V^{\,i}_{j+1/2}          \biggr.        &&  \\ 
     443        &       + {^{i}_j\quad}\mathbb{Q}^{+1/2}_{-1/2} \; V^{i}_{j-1/2}     \; U^{\,i+1/2}_{j}        
     444                 -  {^i_{j+1}     }\mathbb{Q}^{+1/2}_{-1/2} \; U^{i+1/2}_{j+1}\; V^{\,i}_{j+1/2}  \ \;     \biggr\}     &&  \\ 
     445% 
     446\allowdisplaybreaks 
     447\intertext{The summation is done over all $i$ and $j$ indices, it is therefore possible to introduce  
     448a shift of $-1$ either in $i$ or $j$ direction in some of the term of the summation (first term of the  
     449first and second lines, second term of the second and fourth lines). By doning so, we can regroup  
     450all the terms of the summation by triad at a ($i$,$j$) point. In other words, we regroup all the terms  
     451in the neighbourhood  that contain a triad at the same ($i$,$j$) indices. It becomes: } 
     452\allowdisplaybreaks 
     453% 
     454\equiv \sum\limits_{i,j,k} & \biggl\{  \ \   
     455             {^{i}_j}\mathbb{Q}^{-1/2}_{+1/2}  \left[  V^{i}_{j+1/2}\, U^{\,i-1/2}_{j}     
     456                                                                       -  U^{i-1/2}_{j} \, V^{\,i}_{j+1/2}      \right]    &&  \\ 
     457 &       + {^{i}_j}\mathbb{Q}^{-1/2}_{-1/2}  \left[  V^{i}_{j-1/2} \, U^{\,i-1/2}_{j}         
     458                                                                     -    U^{i-1/2}_{j} \, V^{\,i}_{j-1/2}      \right]    \biggr.   &&  \\ 
     459 &      + {^{i}_j}\mathbb{Q}^{+1/2}_{+1/2}  \left[  V^{i}_{j+1/2} \, U^{\,i+1/2}_{j}       
     460                                                                     -    U^{i+1/2}_{j} \, V^{\,i}_{j+1/2}     \right]  \biggr.  &&  \\ 
     461 &     + {^{i}_j}\mathbb{Q}^{+1/2}_{-1/2}  \left[   V^{i}_{j-1/2} \, U^{\,i+1/2}_{j}                                                                      
     462                                                                    -    U^{i+1/2}_{j-1} \, V^{\,i}_{j-1/2}  \right]  \ \;   \biggr\}   \qquad 
     463\equiv \ 0   && 
    225464\end{flalign*} 
    226465 
     
    235474balanced by the change of KE due to the horizontal gradient of KE~: 
    236475\begin{equation*} 
    237       \int_D \textbf{U}_h \cdot \nabla_h \left( \frac{1}{2}\;{\textbf{U}_h}^2 \right)\;dv 
    238  = - \int_D \textbf{U}_h \cdot w \frac{\partial \textbf{U}_h} {\partial k}\;dv 
     476    \int_D \textbf{U}_h \cdot \frac{1}{e_3 } \omega \partial_k \textbf{U}_h \;dv 
     477=  -   \int_D \textbf{U}_h \cdot \nabla_h \left( \frac{1}{2}\;{\textbf{U}_h}^2 \right)\;dv 
     478   +   \frac{1}{2} \int_D {  \frac{{\textbf{U}_h}^2}{e_3} \partial_t ( e_3) \;dv }  \\ 
    239479\end{equation*} 
    240480Indeed, using successively \eqref{DOM_di_adj} ($i.e.$ the skew symmetry  
    241 property of the $\delta$ operator) and the incompressibility, then  
     481property of the $\delta$ operator) and the continuity equation, then  
    242482\eqref{DOM_di_adj} again, then the commutativity of operators  
    243483$\overline {\,\cdot \,}$ and $\delta$, and finally \eqref{DOM_mi_adj}  
     
    245485applied in the horizontal and vertical directions, it becomes: 
    246486\begin{flalign*} 
    247 &\int_D \textbf{U}_h \cdot \nabla_h \left( \frac{1}{2}\;{\textbf{U}_h}^2 \right)\;dv   &&&\\ 
    248 \equiv& \frac{1}{2} \sum\limits_{i,j,k}  
    249    \biggl\{  
    250    \frac{1} {e_{1u}}  \delta_{i+1/2}  
    251    \left[   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}    \right]  u\,e_{1u}e_{2u}e_{3u}   
    252      + \frac{1} {e_{2v}}  \delta_{j+1/2}  
    253    \left[   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right]  v\,e_{1v}e_{2v}e_{3v}  
    254    \biggr\}  
    255    &&& \displaybreak[0] \\  
    256 % 
    257 \equiv&  \frac{1}{2} \sum\limits_{i,j,k}  
    258    \left(   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right)\; 
    259    \delta_k \left[  e_{1T}\,e_{2T} \,w   \right] 
    260 % 
    261 \;\; \equiv -\frac{1}{2} \sum\limits_{i,j,k}  \delta_{k+1/2}  
    262    \left[  
    263       \overline{ u^2}^{\,i}  
    264    + \overline{ v^2}^{\,j}  
    265    \right] \; 
    266    e_{1v}\,e_{2v}\,w  
    267    &&& \displaybreak[0]\\ 
    268 % 
    269 \equiv &\frac{1} {2} \sum\limits_{i,j,k}  
    270    \left(    \overline {\delta_{k+1/2} \left[ u^2 \right]}^{\,i}  
    271       + \overline {\delta_{k+1/2} \left[ v^2 \right]}^{\,j}    \right) \; e_{1T}\,e_{2T} \,w  
    272    && \displaybreak[0] \\ 
     487& - \int_D \textbf{U}_h \cdot \text{KEG}\;dv     
     488= - \int_D \textbf{U}_h \cdot \nabla_h \left( \frac{1}{2}\;{\textbf{U}_h}^2 \right)\;dv    &&&\\ 
     489% 
     490\equiv  & -  \sum\limits_{i,j,k} \frac{1}{2}  \biggl\{    
     491   \frac{1} {e_{1u}}  \delta_{i+1/2}   \left[   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right]  u \ b_u  
     492     + \frac{1} {e_{2v}}  \delta_{j+1/2}   \left[   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right]  v \ b_v   \biggr\}     &&&  \\  
     493% 
     494\equiv & + \sum\limits_{i,j,k} \frac{1}{2}  \left(   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right)\; 
     495                                                              \biggl\{ \delta_{i} \left[  U   \right] +  \delta_{j} \left[  V  \right]    \biggr\}       &&&  \\  
     496\allowdisplaybreaks 
     497% 
     498\equiv   & - \sum\limits_{i,j,k}  \frac{1}{2} 
     499   \left(       \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right)  \;   
     500   \biggl\{   \frac{b_t}{e_{3t}} \partial_t (e_{3t})  +  \delta_k \left[  W   \right]    \biggr\}    &&&\\ 
     501\allowdisplaybreaks 
     502% 
     503\equiv & +  \sum\limits_{i,j,k} \frac{1}{2} \delta_{k+1/2}   \left[ \overline{ u^2}^{\,i} + \overline{ v^2}^{\,j}   \right] \;  W  
     504          -  \sum\limits_{i,j,k} \frac{1}{2} \left(   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right) \;\partial_t b_t   &&& \\ 
     505\allowdisplaybreaks 
     506% 
     507\equiv   & + \sum\limits_{i,j,k} \frac{1} {2} \left(    \overline{\delta_{k+1/2} \left[ u^2 \right]}^{\,i}  
     508                                                                   + \overline{\delta_{k+1/2} \left[ v^2 \right]}^{\,j}    \right) \; W      
     509          -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t \overline{b_t}^{\,{i+1/2}} 
     510                                                 + \frac{v^2}{2}\,\partial_t \overline{b_t}^{\,{j+1/2}}   \right)    &&& \\ 
     511\allowdisplaybreaks 
     512\intertext{Assuming that $b_u= \overline{b_t}^{\,i+1/2}$ and $b_v= \overline{b_t}^{\,j+1/2}$, or at least that the time 
     513derivative of these two equations is satisfied, it becomes:} 
     514% 
     515\equiv &     \sum\limits_{i,j,k} \frac{1} {2} 
     516   \biggl\{ \; \overline{W}^{\,i+1/2}\;\delta_{k+1/2} \left[ u^2 \right]     
     517               + \overline{W}^{\,j+1/2}\;\delta_{k+1/2} \left[ v^2 \right]  \;  \biggr\}    
     518          -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t b_u 
     519                                                + \frac{v^2}{2}\,\partial_t b_v   \right)    &&& \\ 
     520\allowdisplaybreaks 
    273521 
    274 \equiv &\frac{1} {2} \sum\limits_{i,j,k}  
    275    \biggl\{  \overline {e_{1T}\,e_{2T} \,w}^{\,i+1/2}\;2     
    276          \overline {u}^{\,k+1/2}\; \delta_{k+1/2}         \left[ u \right]     %&&&  \\ 
    277     + \overline {e_{1T}\,e_{2T} \,w}^{\,j+1/2}\;2  \overline {v}^{\,k+1/2}\; \delta_{k+1/2}  \left[ v \right]  \; 
    278    \biggr\}  
    279    &&\displaybreak[0] \\  
    280 % 
    281 \equiv& -\sum\limits_{i,j,k}   
    282    \biggl\{ 
    283    \quad \frac{1} {b_u } \; 
    284    \overline {\Bigl\{ \overline {e_{1T}\,e_{2T} \,w}^{\,i+1/2}\,\delta_{k+1/2} 
    285       \left[ u \right]  
    286              \Bigr\} }^{\,k} \;u\;e_{1u}\,e_{2u}\,e_{3u}   
    287    && \\ 
    288    &\qquad \quad\; + \frac{1} {b_v } \; 
    289    \overline {\Bigl\{ \overline {e_{1T}\,e_{2T} \,w}^{\,j+1/2} \delta_{k+1/2} 
    290        \left[ v \right]  
    291          \Bigr\} }^{\,k} \;v\;e_{1v}\,e_{2v}\,e_{3v}  \; 
    292    \biggr\}  
    293    && \\  
    294 \equiv& -\int\limits_D \textbf{U}_h \cdot w \frac{\partial \textbf{U}_h} {\partial k}\;dv &&&\\ 
    295 \end{flalign*} 
    296  
    297 The main point here is that the satisfaction of this property links the choice of  
     522\equiv &     \sum\limits_{i,j,k}  
     523   \biggl\{ \; \overline{W}^{\,i+1/2}\; \overline {u}^{\,k+1/2}\; \delta_{k+1/2}[ u ]     
     524               + \overline{W}^{\,j+1/2}\; \overline {v}^{\,k+1/2}\; \delta_{k+1/2}[ v ]  \;  \biggr\}  
     525          -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t b_u 
     526                                                + \frac{v^2}{2}\,\partial_t b_v   \right)    &&& \\ 
     527% 
     528\allowdisplaybreaks 
     529\equiv  &  \sum\limits_{i,j,k}   
     530   \biggl\{ \; \frac{1} {b_u } \; \overline { \overline{W}^{\,i+1/2}\,\delta_{k+1/2}  \left[ u \right] }^{\,k} \;u\;b_u   
     531                    + \frac{1} {b_v } \; \overline { \overline{W}^{\,j+1/2} \delta_{k+1/2}  \left[ v \right]  }^{\,k} \;v\;b_v  \; \biggr\}   
     532          -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t b_u 
     533                                                + \frac{v^2}{2}\,\partial_t b_v   \right)    &&& \\ 
     534% 
     535\intertext{The first term provides the discrete expression for the vertical advection of momentum (ZAD),  
     536while the second term corresponds exactly to \eqref{KE+PE_vect_discrete}, therefore:} 
     537\equiv&                   \int\limits_D \textbf{U}_h \cdot \text{ZAD} \;dv   
     538           + \frac{1}{2} \int_D { {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t  (e_3)  \;dv }    &&&\\ 
     539\equiv&                   \int\limits_D \textbf{U}_h \cdot w \partial_k \textbf{U}_h \;dv   
     540           + \frac{1}{2} \int_D { {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t  (e_3)  \;dv }    &&&\\ 
     541\end{flalign*} 
     542 
     543There is two main points here. First, the satisfaction of this property links the choice of  
    298544the discrete formulation of the vertical advection and of the horizontal gradient  
    299545of KE. Choosing one imposes the other. For example KE can also be discretized  
     
    301547expression for the vertical advection: 
    302548\begin{equation*} 
    303 \frac{1} {e_3 }\; w\; \frac{\partial \textbf{U}_h } {\partial k} 
     549\frac{1} {e_3 }\; \omega\; \partial_k \textbf{U}_h 
    304550\equiv \left( {{\begin{array} {*{20}c} 
    305 \frac{1} {e_{1u}\,e_{2u}\,e_{3u}} \; 
    306 \overline{\overline {e_{1T}\,e_{2T} \,w\;\delta_{k+1/2}  
     551\frac{1} {e_{1u}\,e_{2u}\,e_{3u}} \;  \overline{\overline {e_{1t}\,e_{2t} \,\omega\;\delta_{k+1/2}  
    307552\left[ \overline u^{\,i+1/2} \right]}}^{\,i+1/2,k}  \hfill \\ 
    308 \frac{1} {e_{1v}\,e_{2v}\,e_{3v}} \; 
    309 \overline{\overline {e_{1T}\,e_{2T} \,w\;\delta_{k+1/2} 
     553\frac{1} {e_{1v}\,e_{2v}\,e_{3v}} \;   \overline{\overline {e_{1t}\,e_{2t} \,\omega \;\delta_{k+1/2} 
    310554\left[ \overline v^{\,j+1/2} \right]}}^{\,j+1/2,k} \hfill \\ 
    311555\end{array}} } \right) 
     
    315559This is the reason why it has not been chosen. 
    316560 
     561Second, as soon as the chosen $s$-coordinate depends on time, an extra constraint 
     562arises on the time derivative of the volume at $u$- and $v$-points: 
     563\begin{flalign*} 
     564e_{1u}\,e_{2u}\,\partial_t (e_{3u}) =\overline{ e_{1t}\,e_{2t}\;\partial_t (e_{3t}) }^{\,i+1/2}    \\ 
     565e_{1v}\,e_{2v}\,\partial_t (e_{3v})  =\overline{ e_{1t}\,e_{2t}\;\partial_t (e_{3t}) }^{\,j+1/2} 
     566\end{flalign*} 
     567which is (over-)satified by defining the vertical scale factor as follows: 
     568\begin{flalign} \label{e3u-e3v} 
     569e_{3u} = \frac{1}{e_{1u}\,e_{2u}}\;\overline{ e_{1t}^{ }\,e_{2t}^{ }\,e_{3t}^{ } }^{\,i+1/2}    \\ 
     570e_{3v} = \frac{1}{e_{1v}\,e_{2v}}\;\overline{ e_{1t}^{ }\,e_{2t}^{ }\,e_{3t}^{ } }^{\,j+1/2}  
     571\end{flalign} 
     572 
     573Blah blah required on the the step representation of bottom topography..... 
     574 
     575 
     576% ------------------------------------------------------------------------------------------------------------- 
     577%       Pressure Gradient Term 
     578% ------------------------------------------------------------------------------------------------------------- 
     579\subsection{Pressure Gradient Term} 
     580\label{Apdx_C.1.4} 
     581 
     582\gmcomment{ 
     583A pressure gradient has no contribution to the evolution of the vorticity as the  
     584curl of a gradient is zero. In the $z$-coordinate, this property is satisfied locally  
     585on a C-grid with 2nd order finite differences (property \eqref{Eq_DOM_curl_grad}).  
     586} 
     587 
     588When the equation of state is linear ($i.e.$ when an advection-diffusion equation  
     589for density can be derived from those of temperature and salinity) the change of  
     590KE due to the work of pressure forces is balanced by the change of potential  
     591energy due to buoyancy forces:  
     592\begin{equation*} 
     593- \int_D  \left. \nabla p \right|_z \cdot \textbf{U}_h \;dv  
     594= - \int_D \nabla \cdot \left( \rho \,\textbf {U} \right) \,g\,z \;dv 
     595  + \int_D g\, \rho \; \partial_t (z)  \;dv 
     596\end{equation*} 
     597 
     598This property can be satisfied in a discrete sense for both $z$- and $s$-coordinates.  
     599Indeed, defining the depth of a $T$-point, $z_t$, as the sum of the vertical scale  
     600factors at $w$-points starting from the surface, the work of pressure forces can be  
     601written as: 
     602\begin{flalign*} 
     603&- \int_D  \left. \nabla p \right|_z \cdot \textbf{U}_h \;dv    
     604\equiv \sum\limits_{i,j,k} \biggl\{ \;  - \frac{1} {e_{1u}}   \Bigl(  
     605\delta_{i+1/2} [p_t] - g\;\overline \rho^{\,i+1/2}\;\delta_{i+1/2} [z_t]     \Bigr)  \; u\;b_u   
     606   &&  \\ & \qquad \qquad  \qquad \qquad  \qquad \quad \ \, 
     607                        - \frac{1} {e_{2v}}    \Bigl(  
     608\delta_{j+1/2} [p_t] - g\;\overline \rho^{\,j+1/2}\delta_{j+1/2} [z_t]      \Bigr)  \; v\;b_v \;  \biggr\}   && \\  
     609% 
     610\allowdisplaybreaks 
     611\intertext{Using successively  \eqref{DOM_di_adj}, $i.e.$ the skew symmetry property of  
     612the $\delta$ operator, \eqref{Eq_wzv}, the continuity equation, \eqref{Eq_dynhpg_sco},  
     613the hydrostatic equation in the $s$-coordinate, and $\delta_{k+1/2} \left[ z_t \right] \equiv e_{3w} $, 
     614which comes from the definition of $z_t$, it becomes: } 
     615\allowdisplaybreaks 
     616% 
     617\equiv& +  \sum\limits_{i,j,k}   g  \biggl\{  
     618      \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t]     
     619   +     \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t]      
     620   +\Bigl(  \delta_i[U] + \delta_j [V]  \Bigr)\;\frac{p_t}{g} \biggr\}  &&\\ 
     621% 
     622\equiv& +  \sum\limits_{i,j,k}   g   \biggl\{  
     623      \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t]     
     624   +     \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t]      
     625    -       \left(   \frac{b_t}{e_{3t}} \partial_t (e_{3t})  +  \delta_k \left[ W \right]    \right) \frac{p_t}{g}    \biggr\}   &&&\\  
     626% 
     627\equiv& +  \sum\limits_{i,j,k}  g   \biggl\{  
     628      \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t]     
     629   +     \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t]      
     630   +  \frac{W}{g}\;\delta_{k+1/2} [p_t]  
     631    -        \frac{p_t}{g}\,\partial_t b_t    \biggr\}    &&&\\ 
     632% 
     633\equiv& +  \sum\limits_{i,j,k}  g   \biggl\{  
     634      \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t]     
     635   +     \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t]      
     636   -  W\;e_{3w} \overline \rho^{\,k+1/2}          
     637    -        \frac{p_t}{g}\,\partial_t b_t    \biggr\}    &&&\\ 
     638% 
     639\equiv& +  \sum\limits_{i,j,k}    g   \biggl\{  
     640      \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t]     
     641   +     \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t]      
     642   +  W\; \overline \rho^{\,k+1/2}\;\delta_{k+1/2} [z_t]    
     643    -        \frac{p_t}{g}\,\partial_t b_t    \biggr\}    &&&\\ 
     644% 
     645\allowdisplaybreaks 
     646% 
     647\equiv& - \sum\limits_{i,j,k}   g \; z_t      \biggl\{  
     648      \delta_i    \left[ U\;  \overline \rho^{\,i+1/2}   \right] 
     649   +  \delta_j    \left[ V\;  \overline \rho^{\,j+1/2}   \right] 
     650   +  \delta_k    \left[ W\;  \overline \rho^{\,k+1/2}   \right]       \biggr\}     
     651             - \sum\limits_{i,j,k}       \biggl\{ p_t\;\partial_t b_t    \biggr\}   &&&\\  
     652% 
     653\equiv& + \sum\limits_{i,j,k}   g \; z_t    \biggl\{      \partial_t ( e_{3t} \,\rho)    \biggr\}  \; b_t     
     654             -  \sum\limits_{i,j,k}                 \biggl\{  p_t\;\partial_t b_t                     \biggr\}              &&&\\    
     655% 
     656\end{flalign*} 
     657The first term is exactly the first term of the right-hand-side of \eqref{KE+PE_vect_discrete}. 
     658It remains to demonstrate that the last term, which is obviously a discrete analogue of  
     659$\int_D \frac{p}{e_3} \partial_t (e_3)\;dv$ is equal to the last term of \eqref{KE+PE_vect_discrete}. 
     660In other words, the following property must be satisfied: 
     661\begin{flalign*} 
     662           \sum\limits_{i,j,k}  \biggl\{  p_t\;\partial_t b_t                  \biggr\}         
     663\equiv  \sum\limits_{i,j,k}  \biggl\{ \rho \,g\,\partial_t (z_t) \,b_t  \biggr\}                                 
     664\end{flalign*} 
     665 
     666Let introduce $p_w$ the pressure at $w$-point such that $\delta_k [p_w] = - \rho \,g\,e_{3t}$.  
     667The right-hand-side of the above equation can be transformed as follows: 
     668 
     669\begin{flalign*} 
     670               \sum\limits_{i,j,k}  \biggl\{ \rho \,g\,\partial_t (z_t) \,b_t  \biggr\}   
     671&\equiv   - \sum\limits_{i,j,k}  \biggl\{ \delta_k [p_w]\,\partial_t (z_t) \,e_{1t}\,e_{2t}  \biggr\}        &&&\\ 
     672% 
     673&\equiv  + \sum\limits_{i,j,k}  \biggl\{  p_w\, \delta_{k+1/2} [\partial_t (z_t)] \,e_{1t}\,e_{2t}  \biggr\}   
     674  \equiv  + \sum\limits_{i,j,k}  \biggl\{  p_w\, \partial_t (e_{3w}) \,e_{1t}\,e_{2t}  \biggr\}        &&&\\ 
     675&\equiv  + \sum\limits_{i,j,k}  \biggl\{  p_w\, \partial_t (b_w) \biggr\}   
     676 % 
     677% & \equiv     \sum\limits_{i,j,k} \biggl\{  \frac{1}{e_{3t}} \delta_k [p_w]\;\partial_t (z_t) \,b_w   \right)   \biggr\}           &&&\\ 
     678% & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t \left(    \delta_k [z_t]   \right)  e_{1w}\,e_{2w}   \biggr\}           &&&\\ 
     679% & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t b_w   \biggr\}           
     680\end{flalign*} 
     681therefore, the balance to be satisfied is: 
     682\begin{flalign*} 
     683           \sum\limits_{i,j,k}  \biggl\{  p_t\;\partial_t (b_t) \biggr\}  \equiv  \sum\limits_{i,j,k}  \biggl\{  p_w\, \partial_t (b_w) \biggr\}   
     684\end{flalign*} 
     685which is a purely vertical balance: 
     686\begin{flalign*} 
     687           \sum\limits_{k}  \biggl\{  p_t\;\partial_t (e_{3t}) \biggr\}  \equiv  \sum\limits_{k}  \biggl\{  p_w\, \partial_t (e_{3w}) \biggr\}   
     688\end{flalign*} 
     689Defining $p_w = \overline{p_t}^{\,k+1/2}$ 
     690 
     691%gm comment 
     692\gmcomment{ 
     693\begin{flalign*} 
     694 \sum\limits_{i,j,k} \biggl\{   p_t\;\partial_t b_t   \biggr\}                                &&&\\ 
     695 % 
     696 & \equiv     \sum\limits_{i,j,k} \biggl\{  \frac{1}{e_{3t}} \delta_k [p_w]\;\partial_t (z_t) \,b_w    \biggr\}           &&&\\ 
     697 & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t \left(    \delta_{k+1/2} [z_t]   \right)  e_{1w}\,e_{2w}   \biggr\}           &&&\\ 
     698 & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t b_w   \biggr\}           
     699\end{flalign*} 
     700 
     701 
     702\begin{flalign*} 
     703\int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv 
     704\equiv&  \sum\limits_{i,j,k}   \biggl\{  \frac{1}{e_{3t}} \frac{\partial e_{3t}}{\partial t} p   \biggr\} \; b_t   &&&\\ 
     705\equiv&  \sum\limits_{i,j,k}   \biggl\{      \biggr\} \; b_t   &&&\\ 
     706\end{flalign*} 
     707 
     708% 
     709\begin{flalign*} 
     710\equiv& - \int_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
     711   + \int\limits_D g\, \rho \; \frac{\partial z}{\partial t}  \;dv     &&& \\ 
     712\end{flalign*} 
     713% 
     714} 
     715%end gm comment 
     716 
     717 
     718Note that this property strongly constrains the discrete expression of both  
     719the depth of $T-$points and of the term added to the pressure gradient in the 
     720$s$-coordinate. Nevertheless, it is almost never satisfied since a linear equation  
     721of state is rarely used. 
     722 
     723 
     724 
     725 
     726 
     727 
     728 
     729% ================================================================ 
     730% Discrete Total energy Conservation : flux form 
     731% ================================================================ 
     732\section{Discrete total energy conservation : flux form} 
     733\label{Apdx_C.1} 
     734 
     735% ------------------------------------------------------------------------------------------------------------- 
     736%       Total energy conservation 
     737% ------------------------------------------------------------------------------------------------------------- 
     738\subsection{Total energy conservation} 
     739\label{Apdx_C_KE+PE} 
     740 
     741The discrete form of the total energy conservation, \eqref{Eq_Tot_Energy}, is given by: 
     742\begin{flalign*} 
     743\partial_t \left(  \sum\limits_{i,j,k} \biggl\{ \frac{u^2}{2} \,b_u + \frac{v^2}{2}\, b_v +  \rho \, g \, z_t \,b_t  \biggr\} \right) &=0  \\ 
     744\end{flalign*} 
     745which in flux form, it leads to: 
     746\begin{flalign*} 
     747                        \sum\limits_{i,j,k} \biggl\{  \frac{u    }{e_{3u}}\,\frac{\partial (e_{3u}u)}{\partial t} \,b_u  
     748                                                             +  \frac{v    }{e_{3v}}\,\frac{\partial (e_{3v}v)}{\partial t} \,b_v  \biggr\} 
     749&  -  \frac{1}{2} \sum\limits_{i,j,k} \biggl\{  \frac{u^2}{e_{3u}}\frac{\partial    e_{3u}    }{\partial t} \,b_u  
     750                                                             +  \frac{v^2}{e_{3v}}\frac{\partial    e_{3v}    }{\partial t} \,b_v   \biggr\}      \\ 
     751&= - \sum\limits_{i,j,k} \biggl\{ \frac{1}{e_3t}\frac{\partial e_{3t} \rho}{\partial t} \, g \, z_t \,b_t  \biggr\}  
     752     - \sum\limits_{i,j,k} \biggl\{ \rho \,g\,\frac{\partial z_t}{\partial t} \,b_t  \biggr\}                                     \\ 
     753\end{flalign*} 
     754 
     755Substituting the discrete expression of the time derivative of the velocity either in vector invariant or in flux form, 
     756leads to the discrete equivalent of the  
     757 
     758 
    317759% ------------------------------------------------------------------------------------------------------------- 
    318760%       Coriolis and advection terms: flux form 
     
    331773Coriolis parameter is discretised at an f-point. It is given by:  
    332774\begin{equation*} 
    333 f+\frac{1} {e_1 e_2 }  
    334 \left( v \frac{\partial e_2 } {\partial i} - u \frac{\partial e_1 } {\partial j}\right)\; 
     775f+\frac{1} {e_1 e_2 } \left( v \frac{\partial e_2 } {\partial i} - u \frac{\partial e_1 } {\partial j}\right)\; 
    335776\equiv \; 
    336 f+\frac{1} {e_{1f}\,e_{2f}}  
    337 \left( \overline v^{\,i+1/2} \delta_{i+1/2} \left[ e_{2u} \right]  
    338 -\overline u^{\,j+1/2} \delta_{j+1/2} \left[ e_{1u}  \right] \right) 
     777f+\frac{1} {e_{1f}\,e_{2f}} \left( \overline v^{\,i+1/2} \delta_{i+1/2} \left[ e_{2u} \right]  
     778                                               -\overline u^{\,j+1/2} \delta_{j+1/2} \left[ e_{1u}  \right] \right) 
    339779\end{equation*} 
    340780 
    341 The ENE scheme is then applied to obtain the vorticity term in flux form.  
     781Either the ENE or EEN scheme is then applied to obtain the vorticity term in flux form.  
    342782It therefore conserves the total KE. The derivation is the same as for the  
    343783vorticity term in the vector invariant form (\S\ref{Apdx_C_vor}). 
     
    355795the horizontal kinetic energy, that is : 
    356796 
    357 \begin{equation} \label{Apdx_C_I.3.10} 
    358 \int_D \textbf{U}_h \cdot  
    359 \left( {{\begin{array} {*{20}c} 
     797\begin{equation} \label{Apdx_C_ADV_KE_flux} 
     798 -  \int_D \textbf{U}_h \cdot     \left(                 {{\begin{array} {*{20}c} 
    360799\nabla \cdot \left( \textbf{U}\,u \right) \hfill \\ 
    361 \nabla \cdot \left( \textbf{U}\,v \right) \hfill \\ 
    362 \end{array}} } \right)\;dv =\;0 
     800\nabla \cdot \left( \textbf{U}\,v \right) \hfill \\       \end{array}} }           \right)   \;dv  
     801-   \frac{1}{2} \int_D {  {\textbf{U}_h}^2 \frac{1}{e_3} \frac{\partial  e_3 }{\partial t} \;dv } =\;0 
    363802\end{equation} 
    364803 
    365 Let us demonstrate this property for the first term of the scalar product  
    366 ($i.e.$ considering just the the terms associated with the i-component of  
    367 the advection): 
    368 \begin{flalign*} 
    369 &\int_D u \cdot \nabla \cdot \left(   \textbf{U}\,u   \right) \; dv    &&&\\ 
    370 % 
    371 \equiv& \sum\limits_{i,j,k}  
    372 \biggl\{    \frac{1} {e_{1u}\, e_{2u}\,e_{3u}}    \biggl(    
    373       \delta_{i+1/2}  \left[   \overline {e_{2u}\,e_{3u}\,u}^{\,i}      \;\overline u^{\,i}          \right]    
    374    + \delta_j           \left[   \overline {e_{1u}\,e_{3u}\,v}^{\,i+1/2}\;\overline u^{\,j+1/2}   \right]  
    375       &&& \\ & \qquad \qquad \qquad \qquad \qquad \qquad 
    376    + \delta_k          \left[   \overline {e_{1w}\,e_{2w}\,w}^{\,i+1/2}\;\overline u^{\,k+1/2} \right] 
    377          \biggr)   \;   \biggr\} \, e_{1u}\,e_{2u}\,e_{3u} \;u  
    378       &&& \displaybreak[0] \\  
    379 % 
    380 \equiv& \sum\limits_{i,j,k}  
     804Let us first consider the first term of the scalar product ($i.e.$ just the the terms  
     805associated with the i-component of the advection) : 
     806\begin{flalign*} 
     807&  - \int_D u \cdot \nabla \cdot \left(   \textbf{U}\,u   \right) \; dv   \\ 
     808% 
     809\equiv& - \sum\limits_{i,j,k} \biggl\{    \frac{1} {b_u}    \biggl(    
     810      \delta_{i+1/2}  \left[   \overline {U}^{\,i}      \;\overline u^{\,i}          \right]    
     811   + \delta_j           \left[   \overline {V}^{\,i+1/2}\;\overline u^{\,j+1/2}   \right]    
     812   + \delta_k          \left[   \overline {W}^{\,i+1/2}\;\overline u^{\,k+1/2} \right]  \biggr)   \;   \biggr\} \, b_u \;u &&&  \\  
     813% 
     814\equiv& - \sum\limits_{i,j,k}  
    381815   \biggl\{  
    382       \delta_{i+1/2} \left[   \overline {e_{2u}\,e_{3u}\,u}^{\,i}\;  \overline u^{\,i}  \right] 
    383    + \delta_j          \left[   \overline {e_{1u}\,e_{3u}\,v}^{\,i+1/2}\;\overline u^{\,j+1/2}   \right] 
    384       &&& \\ & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad 
    385    + \delta_k         \left[   \overline {e_{1w}\,e_{2w}\,w}^{\,i+12}\;\overline u^{\,k+1/2}  \right] 
    386       \; \biggr\} \; u    &&& \displaybreak[0] \\ 
    387 % 
    388 \equiv& - \sum\limits_{i,j,k} 
     816      \delta_{i+1/2} \left[   \overline {U}^{\,i}\;  \overline u^{\,i}  \right] 
     817   + \delta_j          \left[   \overline {V}^{\,i+1/2}\;\overline u^{\,j+1/2}   \right] 
     818   + \delta_k         \left[   \overline {W}^{\,i+12}\;\overline u^{\,k+1/2}  \right] 
     819      \; \biggr\} \; u     \\ 
     820% 
     821\equiv& + \sum\limits_{i,j,k} 
    389822   \biggl\{  
    390       \overline {e_{2u}\,e_{3u}\,u}^{\,i}\;        \overline u^{\,i}       \delta_i  
    391       \left[ u \right]  
    392         + \overline {e_{1u}\,e_{3u}\,v}^{\,i+1/2}\;   \overline u^{\,j+1/2}   \delta_{j+1/2}  
    393       \left[ u \right]  
    394       &&& \\ & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad 
    395        + \overline {e_{1w}\,e_{2w}\,w}^{\,i+1/2}\; \overline u^{\,k+1/2}   \delta_{k+1/2}    \left[ u \right]     \biggr\}     && \displaybreak[0] \\ 
    396 % 
    397 \equiv& - \sum\limits_{i,j,k} 
    398    \biggl\{  
    399         \overline {e_{2u}\,e_{3u}\,u}^{\,i}        \delta_i       \left[ u^2 \right]  
    400     + \overline {e_{1u}\,e_{3u}\,v}^{\,i+1/2}      \delta_{j+/2}  \left[ u^2 \right] 
    401     + \overline {e_{1w}\,e_{2w}\,w}^{\,i+1/2}   \delta_{k+1/2}    \left[ u^2 \right]  
    402    \biggr\}  
    403    && \displaybreak[0] \\ 
    404 % 
    405 \equiv& \sum\limits_{i,j,k} 
    406    \bigg\{  
    407       e_{2u}\,e_{3u}\,u\;     \delta_{i+1/2}       \left[ \overline {u^2}^{\,i} \right] 
    408         + e_{1u}\,e_{3u}\,v\; \delta_{j+1/2}    \; \left[ \overline {u^2}^{\,i} \right] 
    409     + e_{1w}\,e_{2w}\,w\;  \delta_{k+1/2}       \left[ \overline {u^2}^{\,i} \right]  
    410    \biggr\}  
    411    && \displaybreak[0] \\ 
    412 % 
    413 \equiv& \sum\limits_{i,j,k} 
    414 \overline {u^2}^{\,i}  
    415    \biggl\{  
    416       \delta_{i+1/2}    \left[ e_{2u}\,e_{3u}\,u  \right] 
    417    + \delta_{j+1/2}  \left[ e_{1u}\,e_{3u}\,v  \right] 
    418    + \delta_{k+1/2}  \left[ e_{1w}\,e_{2w}\,w \right]  
    419    \biggr\}  \;\;  \equiv 0 
    420    &&& \\ 
    421 \end{flalign*} 
     823      \overline {U}^{\,i}\;   \overline u^{\,i}    \delta_i \left[ u \right]  
     824        + \overline {V}^{\,i+1/2}\; \overline u^{\,j+1/2}   \delta_{j+1/2} \left[ u \right]  
     825        + \overline {W}^{\,i+1/2}\; \overline u^{\,k+1/2}   \delta_{k+1/2}    \left[ u \right]     \biggr\}     && \\ 
     826% 
     827\equiv& + \frac{1}{2} \sum\limits_{i,j,k}    \biggl\{  
     828       \overline{U}^{\,i}     \delta_i       \left[ u^2 \right]  
     829    + \overline{V}^{\,i+1/2}  \delta_{j+/2}  \left[ u^2 \right] 
     830    + \overline{W}^{\,i+1/2}  \delta_{k+1/2}    \left[ u^2 \right]      \biggr\} && \\ 
     831% 
     832\equiv& -  \sum\limits_{i,j,k}    \frac{1}{2}   \bigg\{  
     833       U  \; \delta_{i+1/2}    \left[ \overline {u^2}^{\,i} \right] 
     834         + V  \; \delta_{j+1/2}    \left[ \overline {u^2}^{\,i} \right] 
     835    + W \; \delta_{k+1/2}   \left[ \overline {u^2}^{\,i} \right]     \biggr\}    &&& \\ 
     836% 
     837\equiv& - \sum\limits_{i,j,k}  \frac{1}{2}  \overline {u^2}^{\,i}     \biggl\{  
     838      \delta_{i+1/2}    \left[ U  \right] 
     839   + \delta_{j+1/2}  \left[ V  \right] 
     840   + \delta_{k+1/2}  \left[ W \right]     \biggr\}    &&& \\ 
     841% 
     842\equiv& + \sum\limits_{i,j,k}  \frac{1}{2}  \overline {u^2}^{\,i}  
     843   \biggl\{     \left(   \frac{1}{e_{3t}} \frac{\partial e_{3t}}{\partial t}   \right) \; b_t     \biggr\}    &&& \\ 
     844\end{flalign*} 
     845Applying similar manipulation applied to the second term of the scalar product  
     846leads to : 
     847\begin{equation*} 
     848 -  \int_D \textbf{U}_h \cdot     \left(                 {{\begin{array} {*{20}c} 
     849\nabla \cdot \left( \textbf{U}\,u \right) \hfill \\ 
     850\nabla \cdot \left( \textbf{U}\,v \right) \hfill \\       \end{array}} }           \right)   \;dv      
     851\equiv + \sum\limits_{i,j,k}  \frac{1}{2}  \left( \overline {u^2}^{\,i} + \overline {v^2}^{\,j} \right) 
     852   \biggl\{     \left(   \frac{1}{e_{3t}} \frac{\partial e_{3t}}{\partial t}   \right) \; b_t     \biggr\}     
     853\end{equation*} 
     854which is the discrete form of  
     855$ \frac{1}{2} \int_D u \cdot \nabla \cdot \left(   \textbf{U}\,u   \right) \; dv $.  
     856\eqref{Apdx_C_ADV_KE_flux} is thus satisfied. 
     857 
    422858 
    423859When the UBS scheme is used to evaluate the flux form momentum advection,  
     
    426862($i.e.$ the scheme is diffusive).  
    427863 
    428 % ------------------------------------------------------------------------------------------------------------- 
    429 %       Hydrostatic Pressure Gradient Term 
    430 % ------------------------------------------------------------------------------------------------------------- 
    431 \subsection{Hydrostatic Pressure Gradient Term} 
    432 \label{Apdx_C.1.4} 
    433  
    434  
    435 A pressure gradient has no contribution to the evolution of the vorticity as the  
    436 curl of a gradient is zero. In the $z$-coordinate, this property is satisfied locally  
    437 on a C-grid with 2nd order finite differences (property \eqref{Eq_DOM_curl_grad}).  
    438 When the equation of state is linear ($i.e.$ when an advection-diffusion equation  
    439 for density can be derived from those of temperature and salinity) the change of  
    440 KE due to the work of pressure forces is balanced by the change of potential  
    441 energy due to buoyancy forces:  
    442 \begin{equation*} 
    443 \int_D - \frac{1} {\rho_o} \left. \nabla p^h \right|_z \cdot \textbf{U}_h \;dv  
    444 = \int_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
    445 \end{equation*} 
    446  
    447 This property can be satisfied in a discrete sense for both $z$- and $s$-coordinates.  
    448 Indeed, defining the depth of a $T$-point, $z_T$, as the sum of the vertical scale  
    449 factors at $w$-points starting from the surface, the work of pressure forces can be  
    450 written as: 
    451 \begin{flalign*} 
    452 &\int_D - \frac{1} {\rho_o} \left. \nabla p^h \right|_z \cdot \textbf{U}_h \;dv   &&& \\ 
    453 \equiv& \sum\limits_{i,j,k} \biggl\{ \;  - \frac{1} {\rho_o e_{1u}}   \Bigl(  
    454 \delta_{i+1/2} \left[ p^h \right] - g\;\overline \rho^{\,i+1/2}\;\delta_{i+1/2} \left[ z_T \right]  
    455                \Bigr)  \; u\;e_{1u}\,e_{2u}\,e_{3u}   
    456    &&  \\ & \qquad \qquad 
    457                                  - \frac{1} {\rho_o e_{2v}}    \Bigl(  
    458 \delta_{j+1/2} \left[ p^h \right] - g\;\overline \rho^{\,j+1/2}\delta_{j+1/2}  \left[ z_T \right]  
    459                \Bigr)  \; v\;e_{1v}\,e_{2v}\,e_{3v} \; 
    460    \biggr\}   && \\  
    461 \end{flalign*} 
    462  
    463 Using  \eqref{DOM_di_adj}, $i.e.$ the skew symmetry property of the $\delta$  
    464 operator, \eqref{Eq_wzv}, the continuity equation), and \eqref{Eq_dynhpg_sco},  
    465 the hydrostatic equation in the $s$-coordinate, it becomes:  
     864 
     865 
     866 
     867 
     868 
     869 
     870 
     871 
     872 
     873% ================================================================ 
     874% Discrete Enstrophy Conservation 
     875% ================================================================ 
     876\section{Discrete enstrophy conservation} 
     877\label{Apdx_C.1} 
     878 
     879 
     880% ------------------------------------------------------------------------------------------------------------- 
     881%       Vorticity Term with ENS scheme 
     882% ------------------------------------------------------------------------------------------------------------- 
     883\subsubsection{Vorticity Term with ENS scheme  (\np{ln\_dynvor\_ens}=.true.)} 
     884\label{Apdx_C_vorENS}  
     885 
     886In the ENS scheme, the vorticity term is descretized as follows: 
     887\begin{equation} \label{Eq_dynvor_ens} 
     888\left\{   \begin{aligned} 
     889+\frac{1}{e_{1u}} & \overline{q}^{\,i}  & {\overline{ \overline{\left( e_{1v}\,e_{3v}\;  v \right) } } }^{\,i, j+1/2}    \\ 
     890- \frac{1}{e_{2v}} & \overline{q}^{\,j}  & {\overline{ \overline{\left( e_{2u}\,e_{3u}\; u \right) } } }^{\,i+1/2, j}   
     891\end{aligned}  \right. 
     892\end{equation}  
     893 
     894The scheme does not allow but the conservation of the total kinetic energy but the conservation  
     895of $q^2$, the potential enstrophy for a horizontally non-divergent flow ($i.e.$ when $\chi$=$0$).  
     896Indeed, using the symmetry or skew symmetry properties of the operators (Eqs \eqref{DOM_mi_adj}  
     897and \eqref{DOM_di_adj}), it can be shown that: 
     898\begin{equation} \label{Apdx_C_1.1} 
     899\int_D {q\,\;{\textbf{k}}\cdot \frac{1} {e_3} \nabla \times \left( {e_3 \, q \;{\textbf{k}}\times {\textbf{U}}_h } \right)\;dv} \equiv 0 
     900\end{equation} 
     901where $dv=e_1\,e_2\,e_3 \; di\,dj\,dk$ is the volume element. Indeed, using  
     902\eqref{Eq_dynvor_ens}, the discrete form of the right hand side of \eqref{Apdx_C_1.1}  
     903can be transformed as follow: 
    466904\begin{flalign*}  
    467 \equiv& \frac{1} {\rho_o} \sum\limits_{i,j,k}    \biggl\{  
    468       e_{2u}\,e_{3u} \;u\;g\; \overline \rho^{\,i+1/2}\;\delta_{i+1/2}[ z_T]     
    469    +  e_{1v}\,e_{3v} \;v\;g\; \overline \rho^{\,j+1/2}\;\delta_{j+1/2}[ z_T]      
    470 && \\  & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \;\;\, 
    471    +\Bigl(  \delta_i[ e_{2u}\,e_{3u}\,u] + \delta_j [ e_{1v}\,e_{3v}\,v]  \Bigr)\;p^h \biggr\}  &&\\ 
    472 % 
    473 \equiv& \frac{1} {\rho_o } \sum\limits_{i,j,k} 
    474    \biggl\{  
    475        e_{2u}\,e_{3u} \;u\;g\;   \overline \rho^{\,i+1/2} \delta_{i+1/2} \left[ z_T \right] 
    476    +  e_{1v}\,e_{3v} \;v\;g\; \overline \rho^{\,j+1/2} \delta_{j+1/2} \left[ z_T \right]  
    477    &&&\\ & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \;\;\, 
    478     - \delta_k \left[ e_{1w} e_{2w}\,w \right]\;p^h   \biggr\}   &&&\\  
    479 % 
    480 \equiv& \frac{1} {\rho_o } \sum\limits_{i,j,k} 
    481    \biggl\{  
    482       e_{2u}\,e_{3u} \;u\;g\; \overline \rho^{\,i+1/2}\;\delta_{i+1/2} \left[ z_T \right] 
    483    +  e_{1v}\,e_{3v} \;v\;g\; \overline \rho^{\,j+1/2} \;\delta_{j+1/2} \left[ z_T \right]  
    484    &&& \\ & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \;\;\, 
    485    +   e_{1w} e_{2w} \;w\;\delta_{k+1/2} \left[ p_h \right]  
    486    \biggr\}  &&&\\  
    487 % 
    488 \equiv& \frac{g} {\rho_o}  \sum\limits_{i,j,k} 
    489    \biggl\{  
    490       e_{2u}\,e_{3u} \;u\; \overline \rho^{\,i+1/2}\;\delta_{i+1/2} \left[ z_T \right] 
    491    +  e_{1v}\,e_{3v} \;v\; \overline \rho^{\,j+1/2}\;\delta_{j+1/2} \left[ z_T \right]     
    492    &&& \\ & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \;\;\, 
    493    -  e_{1w} e_{2w} \;w\;e_{3w} \overline \rho^{\,k+1/2}  
    494    \biggr\}   &&&\\  
    495 \end{flalign*} 
    496 noting that by definition of $z_T$, $\delta_{k+1/2} \left[ z_T \right] \equiv - e_{3w} $, thus: 
    497 \begin{multline*} 
    498 \equiv \frac{g} {\rho_o}  \sum\limits_{i,j,k} 
    499    \biggl\{  
    500       e_{2u}\,e_{3u} \;u\; \overline \rho^{\,i+1/2}\;\delta_{i+1/2} \left[ z_T \right] 
    501    +  e_{1v}\,e_{3v} \;v\; \overline \rho^{\,j+1/2} \delta_{j+1/2} \left[ z_T \right] 
    502    \biggr. \\  
    503 \shoveright{ 
    504    \biggl.  
    505    +  e_{1w} e_{2w} \;w\;  \overline \rho^{\,k+1/2}\;\delta_{k+1/2} \left[ z_T \right]  
    506    \biggr\} } \\  
    507 \end{multline*} 
    508 Using \eqref{DOM_di_adj}, it becomes: 
    509 \begin{flalign*} 
    510 \equiv& - \frac{g} {\rho_o} \sum\limits_{i,j,k} z_T  
    511    \biggl\{  
    512       \delta_i    \left[ e_{2u}\,e_{3u}\,u\; \overline \rho^{\,i+1/2}   \right] 
    513    +  \delta_j    \left[ e_{1v}\,e_{3v}\,v\; \overline \rho^{\,j+1/2}   \right] 
    514    +  \delta_k    \left[ e_{1w} e_{2w}\,w\;  \overline \rho^{\,k+1/2}   \right]  
     905&\int_D q \,\; \textbf{k} \cdot \frac{1} {e_3 } \nabla \times  
     906   \left(  e_3 \, q \; \textbf{k} \times  \textbf{U}_h   \right)\;   dv       \\ 
     907% 
     908& \qquad {\begin{array}{*{20}l}  
     909&\equiv \sum\limits_{i,j,k}  
     910q \ \left\{  \delta_{i+1/2}  \left[ - \,\overline {q}^{\,i}\;  \overline{\overline  U }^{\,i,j+1/ 2} \right]   
     911             - \delta_{j+1/2} \left[    \overline {q}^{\,j}\;  \overline{\overline  V }^{\,i+1/2, j} \right]     \right\}    \\  
     912% 
     913&\equiv \sum\limits_{i,j,k}  
     914   \left\{   \delta_i [q] \; \overline{q}^{\,i} \; \overline{  \overline U  }^{\,i,j+1/2}  
     915      + \delta_j [q] \; \overline{q}^{\,j} \; \overline{\overline V }^{\,i+1/2,j}        \right\}       &&  \\  
     916% 
     917&\equiv \,\frac{1} {2} \sum\limits_{i,j,k}   
     918   \left\{         \delta_i  \left[ q^2 \right] \; \overline{\overline U }^{\,i,j+1/2}  
     919            + \delta_j  \left[ q^2 \right] \; \overline{\overline V }^{\,i+1/2,j}      \right\}    &&  \\  
     920% 
     921&\equiv - \frac{1} {2} \sum\limits_{i,j,k}   q^2 \; 
     922   \left\{    \delta_{i+1/2}   \left[   \overline{\overline{ U }}^{\,i,j+1/2}    \right]   
     923            + \delta_{j+1/2}  \left[   \overline{\overline{ V }}^{\,i+1/2,j}     \right]    \right\}    && \\  
     924\end{array} }      
     925% 
     926\allowdisplaybreaks 
     927\intertext{ Since $\overline {\;\cdot \;} $ and $\delta $ operators commute: $\delta_{i+1/2}  
     928\left[ {\overline a^{\,i}} \right] = \overline {\delta_i \left[ a \right]}^{\,i+1/2}$,  
     929and introducing the horizontal divergence $\chi $, it becomes: } 
     930\allowdisplaybreaks 
     931% 
     932& \qquad {\begin{array}{*{20}l}  
     933&\equiv \sum\limits_{i,j,k} - \frac{1} {2} q^2 \; \overline{\overline{ e_{1t}\,e_{2t}\,e_{3t}^{}\, \chi}}^{\,i+1/2,j+1/2}  
     934\quad \equiv 0 && 
     935\end{array} }      
     936\end{flalign*} 
     937The later equality is obtain only when the flow is horizontally non-divergent, $i.e.$ $\chi$=$0$.  
     938 
     939 
     940% ------------------------------------------------------------------------------------------------------------- 
     941%       Vorticity Term with EEN scheme 
     942% ------------------------------------------------------------------------------------------------------------- 
     943\subsubsection{Vorticity Term with EEN scheme (\np{ln\_dynvor\_een}=.true.)} 
     944\label{Apdx_C_vorEEN}  
     945 
     946With the EEN scheme, the vorticity terms are represented as:  
     947\begin{equation} \label{Eq_dynvor_een} 
     948\left\{ {    \begin{aligned} 
     949 +q\,e_3 \, v  &\equiv +\frac{1}{e_{1u} }   \sum_{\substack{i_p,\,k_p}}  
     950                         {^{i+1/2-i_p}_j}  \mathbb{Q}^{i_p}_{j_p}  \left( e_{1v} e_{3v} \ v  \right)^{i+i_p-1/2}_{j+j_p}   \\ 
     951 - q\,e_3 \, u     &\equiv -\frac{1}{e_{2v} }    \sum_{\substack{i_p,\,k_p}}  
     952                         {^i_{j+1/2-j_p}}  \mathbb{Q}^{i_p}_{j_p}  \left( e_{2u} e_{3u} \ u  \right)^{i+i_p}_{j+j_p-1/2}   \\ 
     953\end{aligned}   } \right. 
     954\end{equation}  
     955where the indices $i_p$ and $k_p$ take the following value:  
     956$i_p = -1/2$ or $1/2$ and $j_p = -1/2$ or $1/2$, 
     957and the vorticity triads, ${^i_j}\mathbb{Q}^{i_p}_{j_p}$, defined at $T$-point, are given by:  
     958\begin{equation} \label{Q_triads} 
     959_i^j \mathbb{Q}^{i_p}_{j_p} 
     960= \frac{1}{12} \ \left(   q^{i-i_p}_{j+j_p} + q^{i+j_p}_{j+i_p} + q^{i+i_p}_{j-j_p}  \right) 
     961\end{equation} 
     962 
     963 
     964This formulation does conserve the potential enstrophy for a horizontally non-divergent flow ($i.e.$ $\chi=0$).  
     965 
     966Let consider one of the vorticity triad, for example ${^{i}_j}\mathbb{Q}^{+1/2}_{+1/2} $,  
     967similar manipulation can be done for the 3 others. The discrete form of the right hand  
     968side of \eqref{Apdx_C_1.1} applied to this triad only can be transformed as follow: 
     969 
     970\begin{flalign*}  
     971&\int_D {q\,\;{\textbf{k}}\cdot \frac{1} {e_3} \nabla \times \left( {e_3 \, q \;{\textbf{k}}\times {\textbf{U}}_h } \right)\;dv} \\ 
     972% 
     973\equiv& \sum\limits_{i,j,k}  
     974 {q} \    \biggl\{ \;\; 
     975   \delta_{i+1/2} \left[   -\, {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; U^{i+1/2}_{j}}    \right]   
     976      - \delta_{j+1/2} \left[       {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; V^{i}_{j+1/2}}    \right]  
     977   \;\;\biggr\}        &&  \\  
     978% 
     979\equiv& \sum\limits_{i,j,k}  
     980   \biggl\{   \delta_i [q] \  {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; U^{i+1/2}_{j}} 
     981         + \delta_j [q] \  {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; V^{i}_{j+1/2}}   \biggr\} 
     982      && \\  
     983% 
     984... & &&\\ 
     985&Demonstation \ to \ be \ done... &&\\ 
     986... & &&\\ 
     987% 
     988\equiv& \frac{1} {2} \sum\limits_{i,j,k}   
     989   \biggl\{ \delta_i    \Bigl[    \left(  {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2   \Bigr]\; 
     990         \overline{\overline {U}}^{\,i,j+1/2}  
     991            + \delta_j  \Bigl[    \left( {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2     \Bigr]\;  
     992         \overline{\overline {V}}^{\,i+1/2,j}  
    515993   \biggr\}  
    516    &&& \\ 
    517 % 
    518 \equiv& -\int_D \nabla \cdot \left( \rho \, \textbf{U} \right)\;g\;z\;\;dv    &&& \\ 
    519 \end{flalign*} 
    520  
    521 Note that this property strongly constrains the discrete expression of both  
    522 the depth of $T-$points and of the term added to the pressure gradient in the 
    523 $s$-coordinate. Nevertheless, it is almost never satisfied since a linear equation  
    524 of state is rarely used. 
    525  
    526 % ------------------------------------------------------------------------------------------------------------- 
    527 %       Surface Pressure Gradient Term 
    528 % ------------------------------------------------------------------------------------------------------------- 
    529 \subsection{Surface Pressure Gradient Term} 
    530 \label{Apdx_C.1.5} 
    531  
    532  
    533 The surface pressure gradient has no contribution to the evolution of the vorticity.  
    534 This property is trivially satisfied locally since the equation verified by $\psi$ has  
    535 been derived from the discrete formulation of the momentum equation and of the curl.  
    536 But it has to be noted that since the elliptic equation satisfied by $\psi$ is solved  
    537 numerically by an iterative solver (preconditioned conjugate gradient or successive  
    538 over relaxation), the property is only satisfied at the precision requested for the  
    539 solver used. 
    540  
    541 With the rigid-lid approximation, the change of KE due to the work of surface  
    542 pressure forces is exactly zero. This is satisfied in discrete form, at the precision  
    543 requested for the elliptic solver used to solve this equation. This can be  
    544 demonstrated as follows: 
    545 \begin{flalign*} 
    546 \int\limits_D  - \frac{1} {\rho_o} \nabla_h \left( p_s \right) \cdot \textbf{U}_h \;dv%   &&& \\ 
    547 % 
    548 &\equiv \sum\limits_{i,j,k}   \biggl\{    \; 
    549     \left(  - M_u - \frac{1} {H_u \,e_{2u}}  \delta_j    \left[ \partial_t \psi  \right]   \right)\; 
    550     u\;e_{1u}\,e_{2u}\,e_{3u}   
    551 &&&\\&  \qquad \;\;\, 
    552       + \left(  - M_v + \frac{1} {H_v \,e_{1v}}  \delta_i \left[ \partial_t \psi \right]     \right)\; 
    553      v\;e_{1v}\,e_{2v}\,e_{3v}   \; \biggr\}       
    554 &&&\\ 
    555 \\ 
    556 % 
    557 &\equiv \sum\limits_{i,j}  \Biggl\{   \; 
    558    \biggl( - M_u - \frac{1} {H_u \,e_{2u}}  \delta_j \left[ \partial_t \psi  \right]   \biggr) 
    559    \biggl( \sum\limits_k  u\;e_{3u}   \biggr)\;  e_{1u}\,e_{2u}  
    560 &&&\\&  \qquad \;\;\, 
    561    + \biggl( - M_v + \frac{1} {H_v \,e_{1v}}  \delta_i \left[ \partial_t \psi  \right]   \biggr) 
    562       \biggl(   \sum\limits_k   v\;e_{3v}   \biggr)\;   e_{1v}\,e_{2v} \;   \Biggr\}  
    563    && \\  
    564 % 
    565 \intertext{using the relation between \textit{$\psi $} and the vertical sum of the velocity, it becomes:} 
    566 % 
    567 &\equiv \sum\limits_{i,j}  
    568    \biggl\{  \;    
    569       \left( \;\;\, 
    570       M_u + \frac{1} {H_u \,e_{2u}}  \delta_j \left[ \partial_t \psi \right]  
    571       \right)\; 
    572       e_{1u} \,\delta_j  
    573          \left[ \partial_t \psi  \right]  
    574    && \\ &  \qquad \;\;\, 
    575       + \left(  
    576       - M_v + \frac{1} {H_v \,e_{1v}}  \delta_i \left[ \partial_t \psi \right]  
    577       \right)\; 
    578       e_{2v} \,\delta_i \left[ \partial_t \psi \right]   \; 
    579    \biggr\}  
    580    && \\  
    581 % 
    582 \intertext{applying the adjoint of the $\delta$ operator, it is now:} 
    583 % 
    584 &\equiv \sum\limits_{i,j}  - \partial_t \psi \; 
    585    \biggl\{    \; 
    586      \delta_{j+1/2} \left[ e_{1u} M_u \right]  
    587      - \delta_{i+1/2} \left[ e_{1v} M_v \right]  
    588    && \\ &  \qquad \;\;\, 
    589    + \delta_{i+1/2}  
    590       \left[ \frac{e_{2v}} {H_v \,e_{2v}}  \delta_i \left[ \partial_t \psi \right]  
    591       \right]  
    592    + \delta_{j+1/2}  
    593        \left[ \frac{e_{1u}} {H_u \,e_{2u}}  \delta_j \left[ \partial_t \psi \right]  
    594        \right]   
    595    \biggr\}   &&&\\ 
    596    &\equiv 0                   && \\  
    597 \end{flalign*} 
    598  
    599 The last equality is obtained using \eqref{Eq_dynspg_rl}, the discrete barotropic  
    600 streamfunction time evolution equation. By the way, this shows that  
    601 \eqref{Eq_dynspg_rl} is the only way to compute the streamfunction,  
    602 otherwise the surface pressure forces will do work. Nevertheless, since  
    603 the elliptic equation satisfied by $\psi $ is solved numerically by an iterative  
    604 solver, the property is only satisfied at the precision requested for the solver. 
     994   &&  \\  
     995% 
     996\equiv& - \frac{1} {2} \sum\limits_{i,j,k}   \left( {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2\; 
     997   \biggl\{    \delta_{i+1/2}  
     998         \left[   \overline{\overline {U}}^{\,i,j+1/2}    \right]   
     999               + \delta_{j+1/2} 
     1000      \left[   \overline{\overline {V}}^{\,i+1/2,j}     \right]   
     1001   \biggr\}    && \\  
     1002% 
     1003\equiv& \sum\limits_{i,j,k} - \frac{1} {2} \left( {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2 
     1004                                                            \; \overline{\overline{ b_t^{}\, \chi}}^{\,i+1/2,\,j+1/2}  &&\\ 
     1005% 
     1006\ \ \equiv& \ 0     &&\\ 
     1007\end{flalign*} 
     1008 
     1009 
     1010 
     1011 
    6051012 
    6061013% ================================================================ 
     
    6261033\label{Apdx_C.2.1} 
    6271034 
     1035conservation of a tracer, $T$: 
     1036\begin{equation*} 
     1037\frac{\partial }{\partial t} \left(   \int_D {T\;dv}   \right)  
     1038=  \int_D { \frac{1}{e_3}\frac{\partial \left( e_3 \, T \right)}{\partial t} \;dv }=0 
     1039\end{equation*} 
     1040 
     1041conservation of its variance: 
     1042\begin{flalign*}  
     1043\frac{\partial }{\partial t} \left( \int_D {\frac{1}{2} T^2\;dv} \right) 
     1044=&  \int_D { \frac{1}{e_3} Q      \frac{\partial \left( e_3 \, T \right) }{\partial t} \;dv }   
     1045-   \frac{1}{2} \int_D {  T^2 \frac{1}{e_3} \frac{\partial  e_3 }{\partial t} \;dv } 
     1046\end{flalign*} 
     1047 
     1048 
    6281049Whatever the advection scheme considered it conserves of the tracer content as all  
    629 the scheme are written in flux form. Let $\tau$ be the tracer interpolated at velocity point  
    630 (whatever the interpolation is). The conservation of the tracer content is obtained as follows:  
    631 \begin{flalign*} 
    632 &\int_D \nabla \cdot \left( T \textbf{U} \right)\;dv    &&&\\ 
    633 &\equiv  \sum\limits_{i,j,k}    \biggl\{ 
    634     \frac{1} {e_{1T}\,e_{2T}\,e_{3T}}  
    635     \left(  \delta_i    \left[   e_{2u}\,e_{3u}\; u \;\tau_u   \right] 
    636            + \delta_j    \left[   e_{1v}\,e_{3v}\; v  \;\tau_v   \right] \right)  
    637 &&&\\& \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad 
    638    + \frac{1} {e_{3T}} \delta_k \left[ w\;\tau \right]    \biggl\}  e_{1T}\,e_{2T}\,e_{3T} &&&\\ 
    639 % 
    640 &\equiv  \sum\limits_{i,j,k}     \left\{ 
    641       \delta_i  \left[ e_{2u}\,e_{3u}  \,\overline T^{\,i+1/2}\,u \right] 
    642          + \delta_j  \left[ e_{1v}\,e_{3v}  \,\overline T^{\,j+1/2}\,v \right]  
    643    + \delta_k \left[ e_{1T}\,e_{2T} \,\overline T^{\,k+1/2}\,w \right] \right\}  
    644     && \\ 
     1050the scheme are written in flux form. Indeed,  let $T$ be the tracer and $\tau_u$, $\tau_v$,  
     1051and $\tau_w$ its interpolated values at velocity point (whatever the interpolation is),  
     1052the conservation of the tracer content due to the advection tendency is obtained as follows:  
     1053\begin{flalign*} 
     1054&\int_D { \frac{1}{e_3}\frac{\partial \left( e_3 \, T \right)}{\partial t} \;dv } = - \int_D \nabla \cdot \left( T \textbf{U} \right)\;dv    &&&\\ 
     1055&\equiv - \sum\limits_{i,j,k}    \biggl\{ 
     1056    \frac{1} {b_t}  \left(  \delta_i    \left[   U \;\tau_u   \right] 
     1057                                + \delta_j    \left[   V  \;\tau_v   \right] \right)  
     1058   + \frac{1} {e_{3t}} \delta_k \left[ w\;\tau_w \right]    \biggl\}  b_t   &&&\\ 
     1059% 
     1060&\equiv - \sum\limits_{i,j,k}     \left\{ 
     1061       \delta_i  \left[   U \;\tau_u   \right] 
     1062         + \delta_j  \left[   V  \;\tau_v   \right] 
     1063    + \delta_k \left[ W \;\tau_w \right] \right\}   && \\ 
    6451064&\equiv 0 &&& 
    6461065\end{flalign*} 
    6471066 
    648 The conservation of the variance of tracer can be achieved only with the CEN2 scheme.  
     1067The conservation of the variance of tracer due to the advection tendency  
     1068can be achieved only with the CEN2 scheme, $i.e.$ when  
     1069$\tau_u= \overline T^{\,i+1/2}$, $\tau_v= \overline T^{\,j+1/2}$, and $\tau_w= \overline T^{\,k+1/2}$.  
    6491070It can be demonstarted as follows: 
    6501071\begin{flalign*} 
    651 &\int\limits_D T\;\nabla \cdot \left( T\; \textbf{U} \right)\;dv &&&\\ 
    652 \equiv& \sum\limits_{i,j,k} T\; 
     1072&\int_D { \frac{1}{e_3} Q      \frac{\partial \left( e_3 \, T \right) }{\partial t} \;dv } 
     1073= - \int\limits_D \tau\;\nabla \cdot \left( T\; \textbf{U} \right)\;dv &&&\\ 
     1074\equiv& - \sum\limits_{i,j,k} T\; 
    6531075   \left\{ 
    654       \delta_i  \left[ e_{2u}\,e_{3u} \overline T^{\,i+1/2}\,u \right] 
    655    + \delta_j  \left[ e_{1v}\,e_{3v} \overline T^{\,j+1/2}\,v \right] 
    656    + \delta_k \left[ e_{1T}\,e_{2T} \overline T^{\,k+1/2}w \right] 
    657    \right\}  
    658    && \\ 
    659 \equiv& \sum\limits_{i,j,k}  
    660    \left\{ 
    661    -           e_{2u}\,e_{3u} \overline T^{\,i+1/2}\,u\,\delta_{i+1/2}  \left[ T \right] \right. 
    662    -           e_{1v}\,e_{3v}  \overline T^{\,j+1/2}\,v\;\delta_{j+1/2}  \left[ T \right] 
    663 &&&\\& \qquad \qquad \qquad \qquad \qquad \qquad \quad \; 
    664    - \left. e_{1T}\,e_{2T} \overline T^{\,k+1/2}w\;\delta_{k+1/2} \left[ T \right] 
    665    \right\}  
    666    &&\\ 
    667 \equiv&  -\frac{1} {2}  \sum\limits_{i,j,k} 
    668    \Bigl\{ 
    669       e_{2u}\,e_{3u} \;  u\;\delta_{i+1/2} \left[ T^2 \right] 
    670    + e_{1v}\,e_{3v} \;  v\;\delta_{j+1/2}  \left[ T^2 \right] 
    671    + e_{1T}\,e_{2T} \;w\;\delta_{k+1/2} \left[ T^2 \right] 
    672    \Bigr\}  
    673    && \\  
    674 \equiv& \frac{1} {2}  \sum\limits_{i,j,k} T^2 
    675    \Bigl\{ 
    676       \delta_i  \left[ e_{2u}\,e_{3u}\,u \right] 
    677    + \delta_j  \left[ e_{1v}\,e_{3v}\,v \right] 
    678    + \delta_k \left[ e_{1T}\,e_{2T}\,w \right] 
    679    \Bigr\}  
    680 \quad \equiv 0 &&& 
    681 \end{flalign*} 
    682  
     1076      \delta_i  \left[ U  \overline T^{\,i+1/2}  \right] 
     1077   + \delta_j  \left[ V  \overline T^{\,j+1/2}  \right] 
     1078   + \delta_k \left[ W \overline T^{\,k+1/2} \right]          \right\} && \\ 
     1079\equiv& + \sum\limits_{i,j,k}  
     1080   \left\{     U  \overline T^{\,i+1/2} \,\delta_{i+1/2}  \left[ T \right]  
     1081                 +  V  \overline T^{\,j+1/2} \;\delta_{j+1/2}  \left[ T \right] 
     1082                 +  W \overline T^{\,k+1/2}\;\delta_{k+1/2} \left[ T \right]     \right\}      &&\\ 
     1083\equiv&  + \frac{1} {2}  \sum\limits_{i,j,k} 
     1084   \Bigl\{   U  \;\delta_{i+1/2} \left[ T^2 \right] 
     1085                 + V  \;\delta_{j+1/2}  \left[ T^2 \right] 
     1086                 + W \;\delta_{k+1/2} \left[ T^2 \right]   \Bigr\}     && \\  
     1087\equiv& - \frac{1} {2}  \sum\limits_{i,j,k} T^2 
     1088   \Bigl\{    \delta_i  \left[ U  \right] 
     1089                  + \delta_j  \left[ V  \right] 
     1090                  + \delta_k \left[ W \right]     \Bigr\}      &&&  \\ 
     1091\equiv& + \frac{1} {2}  \sum\limits_{i,j,k} T^2 
     1092   \Bigl\{   \frac{1}{e_{3t}} \frac{\partial e_{3t}\,T }{\partial t}     \Bigr\}      &&& \\ 
     1093\end{flalign*} 
     1094which is the discrete form of $ \frac{1}{2} \int_D {  T^2 \frac{1}{e_3} \frac{\partial  e_3 }{\partial t} \;dv }$. 
    6831095 
    6841096% ================================================================ 
     
    7141126\begin{flalign*} 
    7151127&\int \limits_D \frac{1} {e_3 } \textbf{k} \cdot \nabla \times  
    716    \Bigl[ \nabla_h  
    717       \left( A^{\,lm}\;\chi  \right) 
    718    - \nabla_h \times 
    719       \left( A^{\,lm}\;\zeta \; \textbf{k} \right) 
    720    \Bigr]\;dv  = 0 
     1128   \Bigl[    \nabla_h  \left( A^{\,lm}\;\chi  \right) 
     1129             - \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)    \Bigr]\;dv  = 0 
    7211130\end{flalign*} 
    7221131%%%%%%%%%%  recheck here....  (gm) 
    7231132\begin{flalign*} 
    7241133= \int \limits_D  -\frac{1} {e_3 } \textbf{k} \cdot \nabla \times  
    725    \Bigl[ \nabla_h \times  
    726       \left( A^{\,lm}\;\zeta \; \textbf{k} \right)  
    727    \Bigr]\;dv &&& \\  
     1134   \Bigl[ \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)  \Bigr]\;dv &&& \\  
    7281135\end{flalign*} 
    7291136\begin{flalign*} 
     
    8021209\\  %%% 
    8031210\equiv& \sum\limits_{i,j,k}  
    804    - A_T^{\,lm}  \,\chi^2   \;e_{1T}\,e_{2T}\,e_{3T} 
     1211   - A_T^{\,lm}  \,\chi^2   \;e_{1t}\,e_{2t}\,e_{3t} 
    8051212   - A_f ^{\,lm}  \,\zeta^2 \;e_{1f }\,e_{2f }\,e_{3f}   
    8061213\quad \leq 0       \\ 
     
    8191226\begin{flalign*} 
    8201227&\int\limits_D  \zeta \; \textbf{k} \cdot \nabla \times  
    821    \left[  
    822      \nabla_h  
    823       \left( A^{\,lm}\;\chi  \right) 
    824    -\nabla_h \times  
    825       \left( A^{\,lm}\;\zeta \; \textbf{k} \right) 
    826    \right]\;dv &&&\\ 
     1228   \left[   \nabla_h \left( A^{\,lm}\;\chi  \right) 
     1229          - \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)   \right]\;dv &&&\\ 
    8271230&= A^{\,lm} \int \limits_D \zeta \textbf{k} \cdot \nabla \times  
    828    \left[  
    829    \nabla_h \times  
    830       \left( \zeta \; \textbf{k} \right) 
    831    \right]\;dv &&&\displaybreak[0]\\ 
     1231   \left[    \nabla_h \times \left( \zeta \; \textbf{k} \right)   \right]\;dv &&&\\ 
    8321232&\equiv A^{\,lm} \sum\limits_{i,j,k}  \zeta \;e_{3f}  
    833    \left\{ 
    834      \delta_{i+1/2}  
    835    \left[  
    836    \frac{e_{2v}} {e_{1v}\,e_{3v}} \delta_i  
    837       \left[ e_{3f} \zeta  \right] 
    838    \right] 
    839    + \delta_{j+1/2}  
    840    \left[ 
    841    \frac{e_{1u}} {e_{2u}\,e_{3u}} \delta_j  
    842       \left[ e_{3f} \zeta  \right] 
    843    \right] 
    844    \right\}  
    845    &&&\\  
     1233   \left\{     \delta_{i+1/2} \left[  \frac{e_{2v}} {e_{1v}\,e_{3v}} \delta_i \left[ e_{3f} \zeta  \right]   \right] 
     1234             + \delta_{j+1/2} \left[  \frac{e_{1u}} {e_{2u}\,e_{3u}} \delta_j \left[ e_{3f} \zeta  \right]   \right]      \right\}   &&&\\  
    8461235% 
    8471236\intertext{Using \eqref{DOM_di_adj}, it follows:} 
    8481237% 
    8491238&\equiv  - A^{\,lm} \sum\limits_{i,j,k}  
    850    \left\{ 
    851      \left(  
    852      \frac{1} {e_{1v}\,e_{3v}}  \delta_i  
    853       \left[ e_{3f} \zeta  \right]  
    854      \right)^2   e_{1v}\,e_{2v}\,e_{3v} 
    855    + \left( 
    856      \frac{1} {e_{2u}\,e_{3u}}  \delta_j  
    857       \left[ e_{3f} \zeta  \right] 
    858      \right)^2   e_{1u}\,e_{2u}\,e_{3u} 
    859      \right\}      &&&\\ 
     1239   \left\{    \left(  \frac{1} {e_{1v}\,e_{3v}}  \delta_i \left[ e_{3f} \zeta  \right]  \right)^2   b_v 
     1240            + \left(  \frac{1} {e_{2u}\,e_{3u}}  \delta_j \left[ e_{3f} \zeta  \right] \right)^2   b_u  \right\}      &&&\\ 
    8601241& \leq \;0       &&&\\  
    8611242\end{flalign*} 
     
    8741255\begin{flalign*} 
    8751256& \int\limits_D  \nabla_h \cdot  
    876    \Bigl[  
    877      \nabla_h  
    878       \left( A^{\,lm}\;\chi \right) 
    879    - \nabla_h \times  
    880       \left( A^{\,lm}\;\zeta \;\textbf{k} \right) 
    881    \Bigr] 
    882    dv 
    883 = \int\limits_D  \nabla_h \cdot \nabla_h  
    884    \left( A^{\,lm}\;\chi  \right) 
    885    dv  
    886 &&&\\ 
     1257   \Bigl[     \nabla_h \left( A^{\,lm}\;\chi \right) 
     1258             - \nabla_h \times \left( A^{\,lm}\;\zeta \;\textbf{k} \right)    \Bigr]  dv 
     1259= \int\limits_D  \nabla_h \cdot \nabla_h \left( A^{\,lm}\;\chi  \right)   dv   &&&\\ 
     1260% 
    8871261&\equiv \sum\limits_{i,j,k}  
    888    \left\{  
    889      \delta_i 
    890       \left[  
    891       A_u^{\,lm} \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2}  
    892          \left[ \chi \right]  
    893       \right] 
    894    + \delta_j  
    895       \left[  
    896       A_v^{\,lm} \frac{e_{1v}\,e_{3v}} {e_{2v}}  \delta_{j+1/2}  
    897          \left[ \chi \right]  
    898       \right]  
    899    \right\} 
    900    &&&\\  
     1262   \left\{   \delta_i \left[ A_u^{\,lm} \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2} \left[ \chi \right]  \right] 
     1263           + \delta_j \left[ A_v^{\,lm} \frac{e_{1v}\,e_{3v}} {e_{2v}}  \delta_{j+1/2} \left[ \chi \right]  \right]    \right\}    &&&\\  
    9011264% 
    9021265\intertext{Using \eqref{DOM_di_adj}, it follows:} 
    9031266% 
    9041267&\equiv \sum\limits_{i,j,k}  
    905    - \left\{ 
    906    \frac{e_{2u}\,e_{3u}} {e_{1u}}  A_u^{\,lm} \delta_{i+1/2}  
    907       \left[ \chi \right] 
    908    \delta_{i+1/2}  
    909       \left[ 1 \right]  
    910    + \frac{e_{1v}\,e_{3v}} {e_{2v}}  A_v^{\,lm} \delta_{j+1/2}  
    911       \left[ \chi \right] 
    912    \delta_{j+1/2}  
    913       \left[ 1 \right] 
    914    \right\} \; 
    915    \equiv 0  
    916    &&& \\  
     1268   - \left\{   \frac{e_{2u}\,e_{3u}} {e_{1u}}  A_u^{\,lm} \delta_{i+1/2} \left[ \chi \right] \delta_{i+1/2} \left[ 1 \right]  
     1269             + \frac{e_{1v}\,e_{3v}}  {e_{2v}}  A_v^{\,lm} \delta_{j+1/2} \left[ \chi \right] \delta_{j+1/2} \left[ 1 \right]    \right\}  
     1270   \qquad \equiv 0     &&& \\  
    9171271\end{flalign*} 
    9181272 
     
    9291283 = A^{\,lm}   \int\limits_D \chi \;\nabla_h \cdot \nabla_h \left( \chi \right)\;  dv    &&&\\  
    9301284% 
    931 &\equiv A^{\,lm}  \sum\limits_{i,j,k}  \frac{1} {e_{1T}\,e_{2T}\,e_{3T}}  \chi  
     1285&\equiv A^{\,lm}  \sum\limits_{i,j,k}  \frac{1} {e_{1t}\,e_{2t}\,e_{3t}}  \chi  
    9321286   \left\{ 
    9331287      \delta_i  \left[   \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2} \left[ \chi \right]   \right] 
    9341288   + \delta_j  \left[   \frac{e_{1v}\,e_{3v}} {e_{2v}}   \delta_{j+1/2} \left[ \chi \right]   \right] 
    935    \right\} \;   e_{1T}\,e_{2T}\,e_{3T}    &&&\\  
     1289   \right\} \;   e_{1t}\,e_{2t}\,e_{3t}    &&&\\  
    9361290% 
    9371291\intertext{Using \eqref{DOM_di_adj}, it turns out to be:} 
    9381292% 
    9391293&\equiv - A^{\,lm} \sum\limits_{i,j,k} 
    940    \left\{  
    941    \left(  \frac{1} {e_{1u}}  \delta_{i+1/2}  \left[ \chi \right]  \right)^2  e_{1u}\,e_{2u}\,e_{3u} 
    942 + \left(  \frac{1} {e_{2v}}  \delta_{j+1/2}  \left[ \chi \right]  \right)^2  e_{1v}\,e_{2v}\,e_{3v} 
    943    \right\} \;    &&&\\ 
     1294   \left\{    \left(  \frac{1} {e_{1u}}  \delta_{i+1/2}  \left[ \chi \right]  \right)^2  b_u 
     1295                 + \left(  \frac{1} {e_{2v}}  \delta_{j+1/2}  \left[ \chi \right]  \right)^2  b_v    \right\} \;    &&&\\ 
     1296% 
    9441297&\leq 0              &&&\\ 
    9451298\end{flalign*} 
     
    9561309with the conservation of momentum and the dissipation of horizontal kinetic energy: 
    9571310\begin{align*} 
    958  \int\limits_D   
    959     \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    960    \left(  
    961    \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} 
    962    \right)\; 
    963    dv \qquad \quad &= \vec{\textbf{0}} 
    964    \\ 
     1311 \int\limits_D   \frac{1} {e_3 }\; \frac{\partial } {\partial k}  
     1312       \left(   \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)\;  dv  
     1313   \qquad \quad &= \vec{\textbf{0}}    \\ 
    9651314% 
    9661315\intertext{and} 
    9671316% 
    9681317\int\limits_D  
    969    \textbf{U}_h \cdot  
    970    \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    971    \left( 
    972    \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} 
    973    \right)\; 
    974    dv \quad &\leq 0 
    975    \\ 
     1318   \textbf{U}_h \cdot   \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1319   \left(   \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)\; dv    \quad &\leq 0     \\ 
    9761320\end{align*} 
    9771321The first property is obvious. The second results from: 
     
    9791323\begin{flalign*} 
    9801324\int\limits_D  
    981    \textbf{U}_h \cdot  
    982    \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    983    \left(  
    984    \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  
    985    \right)\;dv 
    986    &&&\\ 
     1325   \textbf{U}_h \cdot   \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1326   \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)\;dv    &&&\\ 
    9871327\end{flalign*} 
    9881328\begin{flalign*} 
    9891329&\equiv \sum\limits_{i,j,k}  
    9901330   \left(  
    991      u\; \delta_k  
    992       \left[  
    993       \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2}  
    994          \left[ u \right]  
    995       \right]\; 
    996       e_{1u}\,e_{2u}  
    997    + v\;\delta_k  
    998       \left[ 
    999       \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2}  
    1000          \left[ v \right]  
    1001       \right]\; 
    1002       e_{1v}\,e_{2v}  
    1003    \right) 
    1004    &&&\\  
     1331      u\; \delta_k \left[ \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2}  \left[ u \right]  \right]\;  e_{1u}\,e_{2u}  
     1332   + v\; \delta_k \left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2}   \left[ v \right]  \right]\;  e_{1v}\,e_{2v} \right)   &&&\\  
    10051333% 
    10061334\intertext{since the horizontal scale factor does not depend on $k$, it follows:} 
    10071335% 
    10081336&\equiv - \sum\limits_{i,j,k}  
    1009    \left(  
    1010       \frac{A_u^{\,vm}} {e_{3uw}} 
    1011       \left(  
    1012       \delta_{k+1/2}  
    1013          \left[ u \right]  
    1014       \right)^2\; 
    1015       e_{1u}\,e_{2u}  
    1016    + \frac{A_v^{\,vm}} {e_{3vw}}  
    1017       \left( \delta_{k+1/2}  
    1018          \left[ v \right]  
    1019       \right)^2\; 
    1020       e_{1v}\,e_{2v} 
    1021    \right) 
    1022     \quad \leq 0 
    1023     &&&\\ 
     1337   \left(  \frac{A_u^{\,vm}} {e_{3uw}} \left( \delta_{k+1/2} \left[ u \right] \right)^2\; e_{1u}\,e_{2u}  
     1338         + \frac{A_v^{\,vm}} {e_{3vw}}  \left( \delta_{k+1/2} \left[ v \right] \right)^2\; e_{1v}\,e_{2v}  \right) 
     1339\quad \leq 0   &&&\\ 
    10241340\end{flalign*} 
    10251341 
     
    10281344\int \limits_D  
    10291345   \frac{1} {e_3 } \textbf{k} \cdot \nabla \times  
    1030       \left(  
    1031       \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    1032          \left(  
    1033          \frac{A^{\,vm}} {e_3}\; \frac{\partial \textbf{U}_h } {\partial k}  
    1034          \right) 
    1035       \right)\; 
    1036       dv 
    1037       &&&\\  
     1346      \left( \frac{1} {e_3 }\; \frac{\partial } {\partial k}  \left(  
     1347              \frac{A^{\,vm}} {e_3}\; \frac{\partial \textbf{U}_h } {\partial k}   
     1348        \right)  \right)\; dv   &&&\\  
    10381349\end{flalign*} 
    10391350\begin{flalign*} 
     
    10411352   \bigg\{    \biggr.   \quad 
    10421353   \delta_{i+1/2}  
    1043       &\left( 
    1044       \frac{e_{2v}} {e_{3v}} \delta_k  
    1045          \left[ 
    1046          \frac{1} {e_{3vw}} \delta_{k+1/2}  
    1047             \left[ v \right]  
    1048          \right] 
    1049       \right) 
    1050     &&\\ 
     1354      &\left(   \frac{e_{2v}} {e_{3v}} \delta_k  \left[  \frac{1} {e_{3vw}} \delta_{k+1/2} \left[ v \right]  \right]  \right)   &&\\ 
    10511355   \biggl.  
    10521356   - \delta_{j+1/2}  
    1053       &\left( 
    1054       \frac{e_{1u}} {e_{3u}} \delta_k  
    1055          \left[ 
    1056          \frac{1} {e_{3uw}}\delta_{k+1/2}  
    1057             \left[ u \right] 
    1058          \right] 
    1059       \right) 
     1357      &\left(   \frac{e_{1u}} {e_{3u}} \delta_k \left[  \frac{1} {e_{3uw}}\delta_{k+1/2} \left[ u \right]  \right]   \right) 
    10601358   \biggr\} \; 
    1061    e_{1f}\,e_{2f}\,e_{3f} \; \equiv 0 
    1062    && \\ 
     1359   e_{1f}\,e_{2f}\,e_{3f} \; \equiv 0   && \\ 
    10631360\end{flalign*} 
    10641361If the vertical diffusion coefficient is uniform over the whole domain, the  
     
    10661363\begin{flalign*} 
    10671364\int\limits_D \zeta \, \textbf{k} \cdot \nabla \times  
    1068    \left(  
    1069    \frac{1} {e_3}\; \frac{\partial } {\partial k} 
    1070       \left(  
    1071       \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  
    1072       \right)  
    1073    \right)\; 
    1074    dv = 0 
    1075    &&&\\ 
     1365   \left(   \frac{1} {e_3}\; \frac{\partial } {\partial k} 
     1366      \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)   \right)\; dv = 0   &&&\\ 
    10761367\end{flalign*} 
    10771368This property is only satisfied in $z$-coordinates: 
     
    10791370\begin{flalign*} 
    10801371\int\limits_D \zeta \, \textbf{k} \cdot \nabla \times  
    1081    \left(  
    1082    \frac{1} {e_3}\; \frac{\partial } {\partial k} 
    1083       \left(  
    1084       \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  
    1085       \right) 
    1086    \right)\; 
    1087    dv 
    1088    &&& \\  
     1372   \left(  \frac{1} {e_3}\; \frac{\partial } {\partial k} 
     1373      \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  \right)   \right)\; dv   &&& \\  
    10891374\end{flalign*} 
    10901375\begin{flalign*} 
     
    10921377   \biggl\{    \biggr.  \quad 
    10931378   \delta_{i+1/2}  
    1094       &\left(  
    1095          \frac{e_{2v}} {e_{3v}} \delta_k  
    1096          \left[  
    1097          \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2}  
    1098             \left[ v \right]  
    1099          \right] 
    1100          \right) 
    1101          &&\\ 
     1379      &\left(   \frac{e_{2v}} {e_{3v}} \delta_k \left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2}[v]  \right]   \right)   &&\\ 
    11021380   - \delta_{j+1/2}  
    11031381      &\biggl. 
    1104       \left(    
    1105          \frac{e_{1u}} {e_{3u}} \delta_k  
    1106          \left[  
    1107          \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2}  
    1108             \left[ u \right] 
    1109           \right]  
    1110          \right)  
    1111    \biggr\}  
    1112    &&\\  
     1382      \left(   \frac{e_{1u}} {e_{3u}} \delta_k \left[ \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} [u]  \right]    \right) \biggr\}   &&\\  
    11131383\end{flalign*} 
    11141384\begin{flalign*} 
     
    11161386   \biggl\{    \biggr.  \quad 
    11171387   \frac{1} {e_{3v}} \delta_k  
    1118       &\left[  
    1119       \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2}  
    1120          \left[ \delta_{i+1/2}  
    1121             \left[ e_{2v}\,v \right] 
    1122           \right] 
    1123       \right] 
    1124       &&\\  
     1388      &\left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2} \left[ \delta_{i+1/2} \left[ e_{2v}\,v \right] \right]   \right]    &&\\  
    11251389    \biggl.  
    11261390   - \frac{1} {e_{3u}} \delta_k  
    1127       &\left[  
    1128       \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2}  
    1129          \left[ \delta_{j+1/2}  
    1130             \left[ e_{1u}\,u \right] 
    1131           \right] 
    1132       \right] 
    1133    \biggr\}  
    1134    &&\\  
     1391      &\left[  \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} \left[ \delta_{j+1/2} \left[ e_{1u}\,u \right] \right]  \right]  \biggr\}  &&\\  
    11351392\end{flalign*} 
    11361393Using the fact that the vertical diffusion coefficients are uniform, and that in  
    11371394$z$-coordinate, the vertical scale factors do not depend on $i$ and $j$ so  
    1138 that: $e_{3f} =e_{3u} =e_{3v} =e_{3T} $ and $e_{3w} =e_{3uw} =e_{3vw} $,  
     1395that: $e_{3f} =e_{3u} =e_{3v} =e_{3t} $ and $e_{3w} =e_{3uw} =e_{3vw} $,  
    11391396it follows: 
    11401397\begin{flalign*} 
    11411398\equiv A^{\,vm} \sum\limits_{i,j,k} \zeta \;\delta_k  
    1142    \left[  
    1143    \frac{1} {e_{3w}} \delta_{k+1/2}  
    1144       \Bigl[  
    1145       \delta_{i+1/2}  
    1146          \left[ e_{2v}\,v \right] 
    1147       - \delta_{j+1/ 2}  
    1148          \left[ e_{1u}\,u \right] 
    1149        \Bigr]  
    1150    \right]  
    1151    &&&\\ 
     1399   \left[   \frac{1} {e_{3w}} \delta_{k+1/2} \Bigl[   \delta_{i+1/2} \left[ e_{2v}\,v \right] 
     1400                                - \delta_{j+1/ 2} \left[ e_{1u}\,u \right]   \Bigr]    \right]    &&&\\ 
    11521401\end{flalign*} 
    11531402\begin{flalign*} 
    11541403\equiv - A^{\,vm} \sum\limits_{i,j,k} \frac{1} {e_{3w}} 
    1155    \left(  
    1156    \delta_{k+1/2}  
    1157       \left[ \zeta  \right] 
    1158     \right)^2 \; 
    1159     e_{1f}\,e_{2f}  
    1160     \; \leq 0 
    1161     &&&\\ 
     1404   \left( \delta_{k+1/2} \left[ \zeta  \right] \right)^2 \; e_{1f}\,e_{2f}  \; \leq 0    &&&\\ 
    11621405\end{flalign*} 
    11631406Similarly, the horizontal divergence is obviously conserved: 
     
    11651408\begin{flalign*} 
    11661409\int\limits_D \nabla \cdot  
    1167    \left(  
    1168    \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    1169       \left(  
    1170       \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  
    1171       \right)  
    1172    \right)\; 
    1173    dv = 0 
    1174    &&&\\ 
     1410\left( \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1411      \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} \right) \right)\; dv = 0    &&&\\ 
    11751412\end{flalign*} 
    11761413and the square of the horizontal divergence decreases ($i.e.$ the horizontal  
     
    11801417\begin{flalign*} 
    11811418\int\limits_D \chi \;\nabla \cdot  
    1182    \left(  
    1183    \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    1184       \left(  
    1185       \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  
    1186       \right)  
    1187    \right)\; 
    1188    dv = 0 
    1189    &&&\\ 
     1419\left( \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1420      \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  \right) \right)\;  dv = 0  &&&\\ 
    11901421\end{flalign*} 
    11911422This property is only satisfied in the $z$-coordinate: 
    11921423\begin{flalign*} 
    11931424\int\limits_D \chi \;\nabla \cdot  
    1194    \left(  
    1195    \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    1196       \left(  
    1197       \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  
    1198       \right)  
    1199    \right)\; 
    1200    dv 
    1201    &&&\\ 
    1202 \end{flalign*} 
    1203 \begin{flalign*} 
    1204 \equiv \sum\limits_{i,j,k} \frac{\chi } {e_{1T}\,e_{2T}} 
     1425\left( \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1426      \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} \right)  \right)\; dv    &&&\\ 
     1427\end{flalign*} 
     1428\begin{flalign*} 
     1429\equiv \sum\limits_{i,j,k} \frac{\chi } {e_{1t}\,e_{2t}} 
    12051430   \biggl\{    \Biggr.  \quad 
    12061431   \delta_{i+1/2}  
    1207       &\left(  
    1208          \frac{e_{2u}} {e_{3u}} \delta_k  
    1209             \left[  
    1210          \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2}  
    1211             \left[ u \right]  
    1212          \right] 
    1213        \right) 
    1214        &&\\  
     1432      &\left(   \frac{e_{2u}} {e_{3u}} \delta_k  
     1433            \left[ \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} [u] \right] \right)    &&\\  
    12151434   \Biggl.  
    12161435   + \delta_{j+1/2}  
    1217       &\left(  
    1218       \frac{e_{1v}} {e_{3v}} \delta_k  
    1219          \left[  
    1220          \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2}  
    1221             \left[ v \right] 
    1222           \right] 
    1223       \right) 
    1224    \Biggr\} \; 
    1225    e_{1T}\,e_{2T}\,e_{3T}  
    1226    &&\\  
     1436      &\left( \frac{e_{1v}} {e_{3v}} \delta_k  
     1437         \left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2} [v] \right]   \right) 
     1438   \Biggr\} \;  e_{1t}\,e_{2t}\,e_{3t}   &&\\  
    12271439\end{flalign*} 
    12281440 
     
    12321444   \delta_{i+1/2} 
    12331445      &\left(  
    1234          \delta_k  
    1235          \left[  
    1236          \frac{1} {e_{3uw}} \delta_{k+1/2}  
    1237             \left[ e_{2u}\,u \right] 
    1238           \right] 
    1239          \right)  
    1240          && \\  
     1446         \delta_k \left[  
     1447         \frac{1} {e_{3uw}} \delta_{k+1/2} \left[ e_{2u}\,u \right] \right]   \right)    && \\  
    12411448   \biggl.  
    12421449   + \delta_{j+1/2}  
    1243       &\left(  
    1244          \delta_k  
    1245          \left[  
    1246          \frac{1} {e_{3vw}} \delta_{k+1/2}  
    1247             \left[ e_{1v}\,v \right] 
    1248           \right]  
    1249          \right) 
    1250    \biggr\}  
    1251    && \\  
     1450      &\left(    \delta_k \left[  
     1451         \frac{1} {e_{3vw}} \delta_{k+1/2} \left[ e_{1v}\,v \right] \right]   \right)   \biggr\}    && \\  
    12521452\end{flalign*} 
    12531453 
    12541454\begin{flalign*} 
    12551455\equiv -A^{\,vm} \sum\limits_{i,j,k}  
    1256 \frac{\delta_{k+1/2} \left[ \chi \right]} {e_{3w}}\; 
    1257    \biggl\{  
    1258    \delta_{k+1/2}  
    1259       \Bigl[ 
    1260          \delta_{i+1/2}  
    1261          \left[ e_{2u}\,u \right] 
    1262       + \delta_{j+1/2}  
    1263          \left[ e_{1v}\,v \right] 
    1264       \Bigr] 
    1265    \biggr\}  
    1266    &&&\\ 
     1456\frac{\delta_{k+1/2} \left[ \chi \right]} {e_{3w}}\; \biggl\{  
     1457   \delta_{k+1/2} \Bigl[ 
     1458         \delta_{i+1/2} \left[ e_{2u}\,u \right] 
     1459      + \delta_{j+1/2} \left[ e_{1v}\,v \right]  \Bigr]    \biggr\}    &&&\\ 
    12671460\end{flalign*} 
    12681461 
    12691462\begin{flalign*} 
    12701463\equiv -A^{\,vm} \sum\limits_{i,j,k} 
    1271  \frac{1} {e_{3w}}  
    1272 \delta_{k+1/2}  
    1273    \left[ \chi \right]\; 
    1274 \delta_{k+1/2}  
    1275    \left[ e_{1T}\,e_{2T} \;\chi \right] 
    1276 &&&\\ 
     1464 \frac{1} {e_{3w}} \delta_{k+1/2} \left[ \chi \right]\; \delta_{k+1/2} \left[ e_{1t}\,e_{2t} \;\chi \right]   &&&\\ 
    12771465\end{flalign*} 
    12781466 
    12791467\begin{flalign*} 
    12801468\equiv -A^{\,vm} \sum\limits_{i,j,k}  
    1281 \frac{e_{1T}\,e_{2T}} {e_{3w}}\; 
    1282    \left(  
    1283    \delta_{k+1/2}  
    1284       \left[ \chi \right] 
    1285    \right)^2 
    1286    \quad  \equiv 0 
    1287 &&&\\ 
     1469\frac{e_{1t}\,e_{2t}} {e_{3w}}\; \left( \delta_{k+1/2} \left[ \chi \right]  \right)^2     \quad  \equiv 0    &&&\\ 
    12881470\end{flalign*} 
    12891471 
     
    13271509   + \delta_k  
    13281510      \left[  
    1329       A_w^{\,vT} \frac{e_{1T}\,e_{2T}} {e_{3T}} \delta_{k+1/2}  
     1511      A_w^{\,vT} \frac{e_{1t}\,e_{2t}} {e_{3t}} \delta_{k+1/2}  
    13301512         \left[ T \right]  
    13311513      \right] 
     
    13511533      \quad&& \\  
    13521534 \biggl.  
    1353 &&+ \delta_k \left[A_w^{\,vT}\frac{e_{1T}\,e_{2T}} {e_{3T}}\delta_{k+1/2}\left[T\right]\right] 
     1535&&+ \delta_k \left[A_w^{\,vT}\frac{e_{1t}\,e_{2t}} {e_{3t}}\delta_{k+1/2}\left[T\right]\right] 
    13541536\biggr\} &&  
    13551537\end{flalign*} 
     
    13571539\equiv - \sum\limits_{i,j,k}  
    13581540   \biggl\{    \biggr.  \quad 
    1359    & A_u^{\,lT}  
    1360       \left(  
    1361       \frac{1} {e_{1u}} \delta_{i+1/2}  
    1362          \left[ T \right] 
    1363       \right)^2 
    1364       e_{1u}\,e_{2u}\,e_{3u} 
    1365    && \\ 
    1366    & + A_v^{\,lT}  
    1367       \left(  
    1368       \frac{1} {e_{2v}} \delta_{j+1/2}  
    1369          \left[ T \right]  
    1370       \right)^2 
    1371       e_{1v}\,e_{2v}\,e_{3v} 
    1372    && \\  
    1373    \biggl.  
    1374    & + A_w^{\,vT}  
    1375       \left(  
    1376       \frac{1} {e_{3w}} \delta_{k+1/2}  
    1377          \left[ T \right]  
    1378       \right)^2 
    1379       e_{1w}\,e_{2w}\,e_{3w}  
    1380    \biggr\}  
    1381    \quad \leq 0  
    1382    && \\  
     1541   &    A_u^{\,lT} \left( \frac{1} {e_{1u}} \delta_{i+1/2} \left[ T \right]  \right)^2   e_{1u}\,e_{2u}\,e_{3u}    && \\ 
     1542   & + A_v^{\,lT} \left( \frac{1} {e_{2v}} \delta_{j+1/2} \left[ T \right]  \right)^2   e_{1v}\,e_{2v}\,e_{3v}     && \\ \biggl.  
     1543   & + A_w^{\,vT} \left( \frac{1} {e_{3w}} \delta_{k+1/2} \left[ T \right]   \right)^2    e_{1w}\,e_{2w}\,e_{3w}   \biggr\}  
     1544   \quad      \leq 0      && \\  
    13831545\end{flalign*} 
    13841546 
Note: See TracChangeset for help on using the changeset viewer.