Ignore:
Timestamp:
2018-12-19T20:46:30+01:00 (22 months ago)
Author:
smasson
Message:

dev_r10164_HPC09_ESIWACE_PREP_MERGE: merge with trunk@10418, see #2133

Location:
NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex
Files:
1 deleted
30 edited
1 copied

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex

    • Property svn:ignore set to
      *.aux
      *.bbl
      *.blg
      *.dvi
      *.fdb*
      *.fls
      *.idx
      *.ilg
      *.ind
      *.log
      *.maf
      *.mtc*
      *.out
      *.pdf
      *.toc
      _minted-*
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex/NEMO

    • Property svn:ignore set to
      *.aux
      *.bbl
      *.blg
      *.dvi
      *.fdb*
      *.fls
      *.idx
      *.ilg
      *.ind
      *.log
      *.maf
      *.mtc*
      *.out
      *.pdf
      *.toc
      _minted-*
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex/NEMO/main

    • Property svn:ignore
      •  

        old new  
        33*.blg 
        44*.dvi 
         5*.fdb* 
         6*.fls 
        57*.idx 
        68*.ilg 
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex/NEMO/main/NEMO_manual.tex

    r10146 r10419  
    2525%% ============================================================================== 
    2626 
     27%% Trick to include biblio in subfile compilation 
     28\newcommand{\biblio}{ 
     29  \bibliographystyle{../main/ametsoc} 
     30  \bibliography{../main/NEMO_manual} 
     31} 
     32 
    2733\begin{document} 
     34 
     35%% Trick to include biblio in subfile compilation 
     36\def\biblio{} 
    2837 
    2938 
     
    3443 
    3544\title{ 
    36 \vspace{-6.0cm}\includegraphics[width=1.1\textwidth]{logo_ALL}          \\ 
    37 \vspace{ 5.1cm}\includegraphics[width=0.9\textwidth]{NEMO_logo_Black}   \\ 
     45%\vspace{-6.0cm}\includegraphics[width=1.1\textwidth]{logo_ALL}            \\ 
     46%\vspace{ 5.1cm}\includegraphics[width=0.9\textwidth]{NEMO_logo_Black}  \\ 
    3847\vspace{ 1.4cm}\rule{345pt}{1.5pt}                                      \\ 
    3948\vspace{0.45cm}{\Huge NEMO ocean engine}                                \\ 
     
    7180 
    7281 
    73 %% Abstract - Foreword 
     82%% Foreword 
    7483 
    75 \subfile{../subfiles/abstract_foreword} 
     84\subfile{../subfiles/foreword} 
    7685 
    7786 
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex/NEMO/subfiles

    • Property svn:ignore set to
      *.aux
      *.bbl
      *.blg
      *.dvi
      *.fdb*
      *.fls
      *.idx
      *.ilg
      *.ind
      *.log
      *.maf
      *.mtc*
      *.out
      *.pdf
      *.toc
      _minted-*
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex/NEMO/subfiles/annex_A.tex

    r10368 r10419  
    1 \documentclass[../tex_main/NEMO_manual]{subfiles} 
     1\documentclass[../main/NEMO_manual]{subfiles} 
     2 
    23\begin{document} 
    34 
    45% ================================================================ 
    5 % Chapter Ñ Appendix A : Curvilinear s-Coordinate Equations 
     6% Chapter Appendix A : Curvilinear s-Coordinate Equations 
    67% ================================================================ 
    78\chapter{Curvilinear $s-$Coordinate Equations} 
    89\label{apdx:A} 
     10 
    911\minitoc 
    1012 
    1113\newpage 
    12 $\ $\newline    % force a new ligne 
    1314 
    1415% ================================================================ 
     
    2627Let us define a new vertical scale factor by $e_3 = \partial z / \partial s$ (which now depends on $(i,j,z,t)$) and 
    2728the horizontal slope of $s-$surfaces by: 
    28 \begin{equation} \label{apdx:A_s_slope} 
    29 \sigma _1 =\frac{1}{e_1 }\;\left. {\frac{\partial z}{\partial i}} \right|_s  
    30 \quad \text{and} \quad  
    31 \sigma _2 =\frac{1}{e_2 }\;\left. {\frac{\partial z}{\partial j}} \right|_s  
     29\begin{equation} 
     30  \label{apdx:A_s_slope} 
     31  \sigma_1 =\frac{1}{e_1 }\;\left. {\frac{\partial z}{\partial i}} \right|_s 
     32  \quad \text{and} \quad 
     33  \sigma_2 =\frac{1}{e_2 }\;\left. {\frac{\partial z}{\partial j}} \right|_s 
    3234\end{equation} 
    3335 
    3436The chain rule to establish the model equations in the curvilinear $s-$coordinate system is: 
    35 \begin{equation} \label{apdx:A_s_chain_rule} 
    36 \begin{aligned} 
    37 &\left. {\frac{\partial \bullet }{\partial t}} \right|_z  = 
    38 \left. {\frac{\partial \bullet }{\partial t}} \right|_s  
     37\begin{equation} 
     38  \label{apdx:A_s_chain_rule} 
     39  \begin{aligned} 
     40    &\left. {\frac{\partial \bullet }{\partial t}} \right|_z  = 
     41    \left. {\frac{\partial \bullet }{\partial t}} \right|_s 
    3942    -\frac{\partial \bullet }{\partial s}\;\frac{\partial s}{\partial t} \\ 
    40 &\left. {\frac{\partial \bullet }{\partial i}} \right|_z  = 
    41   \left. {\frac{\partial \bullet }{\partial i}} \right|_s  
    42      -\frac{\partial \bullet }{\partial s}\;\frac{\partial s}{\partial i}= 
    43      \left. {\frac{\partial \bullet }{\partial i}} \right|_s  
    44      -\frac{e_1 }{e_3 }\sigma _1 \frac{\partial \bullet }{\partial s} \\ 
    45 &\left. {\frac{\partial \bullet }{\partial j}} \right|_z  = 
    46 \left. {\frac{\partial \bullet }{\partial j}} \right|_s  
    47    - \frac{\partial \bullet }{\partial s}\;\frac{\partial s}{\partial j}= 
    48 \left. {\frac{\partial \bullet }{\partial j}} \right|_s  
    49    - \frac{e_2 }{e_3 }\sigma _2 \frac{\partial \bullet }{\partial s} \\ 
    50 &\;\frac{\partial \bullet }{\partial z}  \;\; = \frac{1}{e_3 }\frac{\partial \bullet }{\partial s} \\ 
    51 \end{aligned} 
     43    &\left. {\frac{\partial \bullet }{\partial i}} \right|_z  = 
     44    \left. {\frac{\partial \bullet }{\partial i}} \right|_s 
     45    -\frac{\partial \bullet }{\partial s}\;\frac{\partial s}{\partial i}= 
     46    \left. {\frac{\partial \bullet }{\partial i}} \right|_s 
     47    -\frac{e_1 }{e_3 }\sigma_1 \frac{\partial \bullet }{\partial s} \\ 
     48    &\left. {\frac{\partial \bullet }{\partial j}} \right|_z  = 
     49    \left. {\frac{\partial \bullet }{\partial j}} \right|_s 
     50    - \frac{\partial \bullet }{\partial s}\;\frac{\partial s}{\partial j}= 
     51    \left. {\frac{\partial \bullet }{\partial j}} \right|_s 
     52    - \frac{e_2 }{e_3 }\sigma_2 \frac{\partial \bullet }{\partial s} \\ 
     53    &\;\frac{\partial \bullet }{\partial z}  \;\; = \frac{1}{e_3 }\frac{\partial \bullet }{\partial s} 
     54  \end{aligned} 
    5255\end{equation} 
    5356 
    5457In particular applying the time derivative chain rule to $z$ provides the expression for $w_s$, 
    5558the vertical velocity of the $s-$surfaces referenced to a fix z-coordinate: 
    56 \begin{equation} \label{apdx:A_w_in_s} 
    57 w_s   =  \left.   \frac{\partial z }{\partial t}   \right|_s  
    58             = \frac{\partial z}{\partial s} \; \frac{\partial s}{\partial t}  
    59              = e_3 \, \frac{\partial s}{\partial t}  
    60 \end{equation} 
    61  
     59\begin{equation} 
     60  \label{apdx:A_w_in_s} 
     61  w_s   =  \left.   \frac{\partial z }{\partial t}   \right|_s 
     62  = \frac{\partial z}{\partial s} \; \frac{\partial s}{\partial t} 
     63  = e_3 \, \frac{\partial s}{\partial t} 
     64\end{equation} 
    6265 
    6366% ================================================================ 
     
    7275obtain its expression in the curvilinear $s-$coordinate system: 
    7376 
    74 \begin{subequations}  
    75 \begin{align*} {\begin{array}{*{20}l}  
    76 \nabla \cdot {\rm {\bf U}}  
    77 &= \frac{1}{e_1 \,e_2 }  \left[ \left. {\frac{\partial (e_2 \,u)}{\partial i}} \right|_z  
    78                   +\left. {\frac{\partial(e_1 \,v)}{\partial j}} \right|_z  \right] 
    79 + \frac{\partial w}{\partial z}     \\ 
    80 \\ 
    81 &     = \frac{1}{e_1 \,e_2 }  \left[  
    82         \left.   \frac{\partial (e_2 \,u)}{\partial i}    \right|_s        
    83         - \frac{e_1 }{e_3 } \sigma _1 \frac{\partial (e_2 \,u)}{\partial s} 
    84       + \left.   \frac{\partial (e_1 \,v)}{\partial j}    \right|_s        
    85         - \frac{e_2 }{e_3 } \sigma _2 \frac{\partial (e_1 \,v)}{\partial s}   \right] 
    86    + \frac{\partial w}{\partial s} \; \frac{\partial s}{\partial z}                        \\ 
    87 \\ 
    88 &     = \frac{1}{e_1 \,e_2 }   \left[  
    89         \left.   \frac{\partial (e_2 \,u)}{\partial i}    \right|_s        
    90       + \left.   \frac{\partial (e_1 \,v)}{\partial j}    \right|_s        \right] 
    91    + \frac{1}{e_3 }\left[        \frac{\partial w}{\partial s} 
    92                   -  \sigma _1 \frac{\partial u}{\partial s} 
    93                   -  \sigma _2 \frac{\partial v}{\partial s}      \right]          \\ 
    94 \\ 
    95 &     = \frac{1}{e_1 \,e_2 \,e_3 }   \left[  
    96         \left.   \frac{\partial (e_2 \,e_3 \,u)}{\partial i}    \right|_s   
    97         -\left.    e_2 \,u    \frac{\partial e_3 }{\partial i}     \right|_s       
    98       + \left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j}    \right|_s 
    99         - \left.    e_1 v      \frac{\partial e_3 }{\partial j}    \right|_s   \right]          \\ 
    100 & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad 
    101    + \frac{1}{e_3 } \left[        \frac{\partial w}{\partial s} 
    102                   -  \sigma _1 \frac{\partial u}{\partial s} 
    103                   -  \sigma _2 \frac{\partial v}{\partial s}      \right]      \\ 
    104 % 
    105 \intertext{Noting that $ 
    106   \frac{1}{e_1} \left.{ \frac{\partial e_3}{\partial i}} \right|_s  
    107 =\frac{1}{e_1} \left.{ \frac{\partial^2 z}{\partial i\,\partial s}} \right|_s  
    108 =\frac{\partial}{\partial s} \left( {\frac{1}{e_1 } \left.{ \frac{\partial z}{\partial i} }\right|_s } \right) 
    109 =\frac{\partial \sigma _1}{\partial s} 
    110 $ and $ 
    111 \frac{1}{e_2 }\left. {\frac{\partial e_3 }{\partial j}} \right|_s  
    112 =\frac{\partial \sigma _2}{\partial s} 
    113 $, it becomes:} 
    114 % 
    115 \nabla \cdot {\rm {\bf U}}  
    116 & = \frac{1}{e_1 \,e_2 \,e_3 }  \left[    
    117         \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s  
    118       +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right]        \\  
    119 & \qquad \qquad \qquad \qquad \quad 
    120  +\frac{1}{e_3 }\left[ {\frac{\partial w}{\partial s}-u\frac{\partial \sigma _1 }{\partial s}-v\frac{\partial \sigma _2 }{\partial s}-\sigma _1 \frac{\partial u}{\partial s}-\sigma _2 \frac{\partial v}{\partial s}} \right] \\  
    121 \\ 
    122 & = \frac{1}{e_1 \,e_2 \,e_3 }  \left[    
    123         \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s  
    124       +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right]       
    125    + \frac{1}{e_3 } \; \frac{\partial}{\partial s}   \left[  w -  u\;\sigma _1  - v\;\sigma _2  \right] 
    126 \end{array} }      
    127 \end{align*} 
     77\begin{subequations} 
     78  \begin{align*} 
     79    { 
     80    \begin{array}{*{20}l} 
     81      \nabla \cdot {\rm {\bf U}} 
     82      &= \frac{1}{e_1 \,e_2 }  \left[ \left. {\frac{\partial (e_2 \,u)}{\partial i}} \right|_z 
     83        +\left. {\frac{\partial(e_1 \,v)}{\partial j}} \right|_z  \right] 
     84        + \frac{\partial w}{\partial z} \\ \\ 
     85      &     = \frac{1}{e_1 \,e_2 }  \left[ 
     86        \left.   \frac{\partial (e_2 \,u)}{\partial i}    \right|_s 
     87        - \frac{e_1 }{e_3 } \sigma_1 \frac{\partial (e_2 \,u)}{\partial s} 
     88        + \left.   \frac{\partial (e_1 \,v)}{\partial j}    \right|_s 
     89        - \frac{e_2 }{e_3 } \sigma_2 \frac{\partial (e_1 \,v)}{\partial s} \right] 
     90        + \frac{\partial w}{\partial s} \; \frac{\partial s}{\partial z} \\ \\ 
     91      &     = \frac{1}{e_1 \,e_2 }   \left[ 
     92        \left.   \frac{\partial (e_2 \,u)}{\partial i}    \right|_s 
     93        + \left.   \frac{\partial (e_1 \,v)}{\partial j}    \right|_s         \right] 
     94        + \frac{1}{e_3 }\left[        \frac{\partial w}{\partial s} 
     95        -  \sigma_1 \frac{\partial u}{\partial s} 
     96        -  \sigma_2 \frac{\partial v}{\partial s}      \right] \\ \\ 
     97      &     = \frac{1}{e_1 \,e_2 \,e_3 }   \left[ 
     98        \left.   \frac{\partial (e_2 \,e_3 \,u)}{\partial i}    \right|_s 
     99        -\left.    e_2 \,u    \frac{\partial e_3 }{\partial i}     \right|_s 
     100        + \left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j}    \right|_s 
     101        - \left.    e_1 v      \frac{\partial e_3 }{\partial j}    \right|_s   \right] \\ 
     102      & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad 
     103        + \frac{1}{e_3 } \left[        \frac{\partial w}{\partial s} 
     104        -  \sigma_1 \frac{\partial u}{\partial s} 
     105        -  \sigma_2 \frac{\partial v}{\partial s}      \right]      \\ 
     106      % 
     107      \intertext{Noting that $ 
     108      \frac{1}{e_1} \left.{ \frac{\partial e_3}{\partial i}} \right|_s 
     109      =\frac{1}{e_1} \left.{ \frac{\partial^2 z}{\partial i\,\partial s}} \right|_s 
     110      =\frac{\partial}{\partial s} \left( {\frac{1}{e_1 } \left.{ \frac{\partial z}{\partial i} }\right|_s } \right) 
     111      =\frac{\partial \sigma_1}{\partial s} 
     112      $ and $ 
     113      \frac{1}{e_2 }\left. {\frac{\partial e_3 }{\partial j}} \right|_s 
     114      =\frac{\partial \sigma_2}{\partial s} 
     115      $, it becomes:} 
     116    % 
     117      \nabla \cdot {\rm {\bf U}} 
     118      & = \frac{1}{e_1 \,e_2 \,e_3 }  \left[ 
     119        \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s 
     120        +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right] \\ 
     121      & \qquad \qquad \qquad \qquad \quad 
     122        +\frac{1}{e_3 }\left[ {\frac{\partial w}{\partial s}-u\frac{\partial \sigma_1 }{\partial s}-v\frac{\partial \sigma_2 }{\partial s}-\sigma_1 \frac{\partial u}{\partial s}-\sigma_2 \frac{\partial v}{\partial s}} \right] \\ 
     123      \\ 
     124      & = \frac{1}{e_1 \,e_2 \,e_3 }  \left[ 
     125        \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s 
     126        +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right] 
     127        + \frac{1}{e_3 } \; \frac{\partial}{\partial s}   \left[  w -  u\;\sigma_1  - v\;\sigma_2  \right] 
     128    \end{array} 
     129        } 
     130  \end{align*} 
    128131\end{subequations} 
    129132 
     
    131134Introducing the dia-surface velocity component, 
    132135$\omega $, defined as the volume flux across the moving $s$-surfaces per unit horizontal area: 
    133 \begin{equation} \label{apdx:A_w_s} 
    134 \omega  = w - w_s - \sigma _1 \,u - \sigma _2 \,v    \\ 
     136\begin{equation} 
     137  \label{apdx:A_w_s} 
     138  \omega  = w - w_s - \sigma_1 \,u - \sigma_2 \,v    \\ 
    135139\end{equation} 
    136140with $w_s$ given by \autoref{apdx:A_w_in_s}, 
    137141we obtain the expression for the divergence of the velocity in the curvilinear $s-$coordinate system: 
    138 \begin{subequations}  
    139 \begin{align*} {\begin{array}{*{20}l}  
    140 \nabla \cdot {\rm {\bf U}}  
    141 &= \frac{1}{e_1 \,e_2 \,e_3 }    \left[  
    142         \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s  
    143       +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right]       
    144 + \frac{1}{e_3 } \frac{\partial \omega }{\partial s}  
    145 + \frac{1}{e_3 } \frac{\partial w_s       }{\partial s}    \\ 
    146 \\ 
    147 &= \frac{1}{e_1 \,e_2 \,e_3 }    \left[  
    148         \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s  
    149       +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right]       
    150 + \frac{1}{e_3 } \frac{\partial \omega }{\partial s}  
    151 + \frac{1}{e_3 } \frac{\partial}{\partial s}  \left(  e_3 \; \frac{\partial s}{\partial t}   \right)   \\ 
    152 \\ 
    153 &= \frac{1}{e_1 \,e_2 \,e_3 }    \left[  
    154         \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s  
    155       +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right]       
    156 + \frac{1}{e_3 } \frac{\partial \omega }{\partial s}  
    157 + \frac{\partial}{\partial s} \frac{\partial s}{\partial t} 
    158 + \frac{1}{e_3 } \frac{\partial s}{\partial t} \frac{\partial e_3}{\partial s}    \\ 
    159 \\ 
    160 &= \frac{1}{e_1 \,e_2 \,e_3 }    \left[  
    161         \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s  
    162       +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right]       
    163 + \frac{1}{e_3 } \frac{\partial \omega }{\partial s}  
    164 + \frac{1}{e_3 } \frac{\partial e_3}{\partial t}     \\ 
    165 \end{array} }      
    166 \end{align*} 
     142\begin{subequations} 
     143  \begin{align*} 
     144    { 
     145    \begin{array}{*{20}l} 
     146      \nabla \cdot {\rm {\bf U}} 
     147      &= \frac{1}{e_1 \,e_2 \,e_3 }    \left[ 
     148        \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s 
     149        +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right] 
     150        + \frac{1}{e_3 } \frac{\partial \omega }{\partial s} 
     151        + \frac{1}{e_3 } \frac{\partial w_s       }{\partial s} \\ \\ 
     152      &= \frac{1}{e_1 \,e_2 \,e_3 }    \left[ 
     153        \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s 
     154        +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right] 
     155        + \frac{1}{e_3 } \frac{\partial \omega }{\partial s} 
     156        + \frac{1}{e_3 } \frac{\partial}{\partial s}  \left(  e_3 \; \frac{\partial s}{\partial t}   \right) \\ \\ 
     157      &= \frac{1}{e_1 \,e_2 \,e_3 }    \left[ 
     158        \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s 
     159        +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right] 
     160        + \frac{1}{e_3 } \frac{\partial \omega }{\partial s} 
     161        + \frac{\partial}{\partial s} \frac{\partial s}{\partial t} 
     162        + \frac{1}{e_3 } \frac{\partial s}{\partial t} \frac{\partial e_3}{\partial s} \\ \\ 
     163      &= \frac{1}{e_1 \,e_2 \,e_3 }    \left[ 
     164        \left.  \frac{\partial (e_2 \,e_3 \,u)}{\partial i} \right|_s 
     165        +\left.  \frac{\partial (e_1 \,e_3 \,v)}{\partial j} \right|_s        \right] 
     166        + \frac{1}{e_3 } \frac{\partial \omega }{\partial s} 
     167        + \frac{1}{e_3 } \frac{\partial e_3}{\partial t} 
     168    \end{array} 
     169        } 
     170  \end{align*} 
    167171\end{subequations} 
    168172 
    169173As a result, the continuity equation \autoref{eq:PE_continuity} in the $s-$coordinates is: 
    170 \begin{equation} \label{apdx:A_sco_Continuity} 
    171 \frac{1}{e_3 } \frac{\partial e_3}{\partial t}  
    172 + \frac{1}{e_1 \,e_2 \,e_3 }\left[  
    173          {\left. {\frac{\partial (e_2 \,e_3 \,u)}{\partial i}} \right|_s  
    174           +  \left. {\frac{\partial (e_1 \,e_3 \,v)}{\partial j}} \right|_s } \right] 
    175  +\frac{1}{e_3 }\frac{\partial \omega }{\partial s} = 0    
     174\begin{equation} 
     175  \label{apdx:A_sco_Continuity} 
     176  \frac{1}{e_3 } \frac{\partial e_3}{\partial t} 
     177  + \frac{1}{e_1 \,e_2 \,e_3 }\left[ 
     178    {\left. {\frac{\partial (e_2 \,e_3 \,u)}{\partial i}} \right|_s 
     179      +  \left. {\frac{\partial (e_1 \,e_3 \,v)}{\partial j}} \right|_s } \right] 
     180  +\frac{1}{e_3 }\frac{\partial \omega }{\partial s} = 0 
    176181\end{equation} 
    177182A additional term has appeared that take into account 
     
    187192Here we only consider the first component of the momentum equation, 
    188193the generalization to the second one being straightforward. 
    189  
    190 $\ $\newline    % force a new ligne 
    191194 
    192195$\bullet$ \textbf{Total derivative in vector invariant form} 
     
    197200its expression in the curvilinear $s-$coordinate system: 
    198201 
    199 \begin{subequations}  
    200 \begin{align*} {\begin{array}{*{20}l}  
    201 \left. \frac{D u}{D t} \right|_z  
    202 &= \left. {\frac{\partial u }{\partial t}} \right|_z  
    203    - \left. \zeta \right|_z v  
    204   + \frac{1}{2e_1} \left.{ \frac{\partial (u^2+v^2)}{\partial i}} \right|_z  
    205   + w \;\frac{\partial u}{\partial z} \\ 
    206 \\ 
    207 &= \left. {\frac{\partial u }{\partial t}} \right|_z  
    208    - \left. \zeta \right|_z v  
    209   +  \frac{1}{e_1 \,e_2 }\left[ { \left.{ \frac{\partial (e_2 \,v)}{\partial i} }\right|_z  
    210                                              -\left.{ \frac{\partial (e_1 \,u)}{\partial j} }\right|_z } \right] \; v      
    211   +  \frac{1}{2e_1} \left.{ \frac{\partial (u^2+v^2)}{\partial i} } \right|_z  
    212   +  w \;\frac{\partial u}{\partial z}      \\ 
    213 % 
    214 \intertext{introducing the chain rule (\autoref{apdx:A_s_chain_rule}) } 
    215 % 
    216 &= \left. {\frac{\partial u }{\partial t}} \right|_z        
    217    - \frac{1}{e_1\,e_2}\left[ { \left.{ \frac{\partial (e_2 \,v)}{\partial i} } \right|_s  
    218                                           -\left.{ \frac{\partial (e_1 \,u)}{\partial j} } \right|_s } \right. 
    219                                           \left. {-\frac{e_1}{e_3}\sigma _1 \frac{\partial (e_2 \,v)}{\partial s} 
    220                                                    +\frac{e_2}{e_3}\sigma _2 \frac{\partial (e_1 \,u)}{\partial s}} \right] \; v  \\  
    221 & \qquad \qquad \qquad \qquad 
    222  { + \frac{1}{2e_1} \left(                                  \left.  \frac{\partial (u^2+v^2)}{\partial i} \right|_s  
    223                                     - \frac{e_1}{e_3}\sigma _1 \frac{\partial (u^2+v^2)}{\partial s}               \right) 
    224    + \frac{w}{e_3 } \;\frac{\partial u}{\partial s} }    \\ 
    225 \\ 
    226 &= \left. {\frac{\partial u }{\partial t}} \right|_z        
    227   + \left. \zeta \right|_s \;v 
    228   + \frac{1}{2\,e_1}\left. {\frac{\partial (u^2+v^2)}{\partial i}} \right|_s      \\ 
    229 &\qquad \qquad \qquad \quad 
    230   + \frac{w}{e_3 } \;\frac{\partial u}{\partial s} 
    231    - \left[   {\frac{\sigma _1 }{e_3 }\frac{\partial v}{\partial s} 
    232                - \frac{\sigma_2 }{e_3 }\frac{\partial u}{\partial s}}   \right]\;v       
    233    - \frac{\sigma _1 }{2e_3 }\frac{\partial (u^2+v^2)}{\partial s}      \\ 
    234 \\ 
    235 &= \left. {\frac{\partial u }{\partial t}} \right|_z        
    236   + \left. \zeta \right|_s \;v 
    237   + \frac{1}{2\,e_1}\left. {\frac{\partial (u^2+v^2)}{\partial i}} \right|_s      \\ 
    238 &\qquad \qquad \qquad \quad 
    239  + \frac{1}{e_3} \left[    {w\frac{\partial u}{\partial s} 
    240                            +\sigma _1 v\frac{\partial v}{\partial s} - \sigma _2 v\frac{\partial u}{\partial s} 
    241                            - \sigma _1 u\frac{\partial u}{\partial s} - \sigma _1 v\frac{\partial v}{\partial s}} \right] \\ 
    242 \\ 
    243 &= \left. {\frac{\partial u }{\partial t}} \right|_z        
    244   + \left. \zeta \right|_s \;v 
    245   + \frac{1}{2\,e_1}\left. {\frac{\partial (u^2+v^2)}{\partial i}} \right|_s   
    246   + \frac{1}{e_3} \left[  w - \sigma _2 v - \sigma _1 u  \right]  
    247                 \; \frac{\partial u}{\partial s}   \\ 
    248 % 
    249 \intertext{Introducing $\omega$, the dia-a-surface velocity given by (\autoref{apdx:A_w_s}) } 
    250 % 
    251 &= \left. {\frac{\partial u }{\partial t}} \right|_z        
    252   + \left. \zeta \right|_s \;v 
    253   + \frac{1}{2\,e_1}\left. {\frac{\partial (u^2+v^2)}{\partial i}} \right|_s   
    254   + \frac{1}{e_3 } \left( \omega - w_s \right) \frac{\partial u}{\partial s}   \\ 
    255 \end{array} }      
    256 \end{align*} 
     202\begin{subequations} 
     203  \begin{align*} 
     204    { 
     205    \begin{array}{*{20}l} 
     206      \left. \frac{D u}{D t} \right|_z 
     207      &= \left. {\frac{\partial u }{\partial t}} \right|_z 
     208        - \left. \zeta \right|_z v 
     209        + \frac{1}{2e_1} \left.{ \frac{\partial (u^2+v^2)}{\partial i}} \right|_z 
     210        + w \;\frac{\partial u}{\partial z} \\ \\ 
     211      &= \left. {\frac{\partial u }{\partial t}} \right|_z 
     212        - \left. \zeta \right|_z v 
     213        +  \frac{1}{e_1 \,e_2 }\left[ { \left.{ \frac{\partial (e_2 \,v)}{\partial i} }\right|_z 
     214        -\left.{ \frac{\partial (e_1 \,u)}{\partial j} }\right|_z } \right] \; v 
     215        +  \frac{1}{2e_1} \left.{ \frac{\partial (u^2+v^2)}{\partial i} } \right|_z 
     216        +  w \;\frac{\partial u}{\partial z}      \\ 
     217        % 
     218      \intertext{introducing the chain rule (\autoref{apdx:A_s_chain_rule}) } 
     219      % 
     220      &= \left. {\frac{\partial u }{\partial t}} \right|_z 
     221        - \frac{1}{e_1\,e_2}\left[ { \left.{ \frac{\partial (e_2 \,v)}{\partial i} } \right|_s 
     222        -\left.{ \frac{\partial (e_1 \,u)}{\partial j} } \right|_s } \right. 
     223        \left. {-\frac{e_1}{e_3}\sigma_1 \frac{\partial (e_2 \,v)}{\partial s} 
     224        +\frac{e_2}{e_3}\sigma_2 \frac{\partial (e_1 \,u)}{\partial s}} \right] \; v  \\ 
     225      & \qquad \qquad \qquad \qquad 
     226        { 
     227        + \frac{1}{2e_1} \left(                                  \left.  \frac{\partial (u^2+v^2)}{\partial i} \right|_s 
     228        - \frac{e_1}{e_3}\sigma_1 \frac{\partial (u^2+v^2)}{\partial s}               \right) 
     229        + \frac{w}{e_3 } \;\frac{\partial u}{\partial s} 
     230        } \\ \\ 
     231      &= \left. {\frac{\partial u }{\partial t}} \right|_z 
     232        + \left. \zeta \right|_s \;v 
     233        + \frac{1}{2\,e_1}\left. {\frac{\partial (u^2+v^2)}{\partial i}} \right|_s \\ 
     234      &\qquad \qquad \qquad \quad 
     235        + \frac{w}{e_3 } \;\frac{\partial u}{\partial s} 
     236        - \left[   {\frac{\sigma_1 }{e_3 }\frac{\partial v}{\partial s} 
     237        - \frac{\sigma_2 }{e_3 }\frac{\partial u}{\partial s}}   \right]\;v 
     238        - \frac{\sigma_1 }{2e_3 }\frac{\partial (u^2+v^2)}{\partial s} \\ \\ 
     239      &= \left. {\frac{\partial u }{\partial t}} \right|_z 
     240        + \left. \zeta \right|_s \;v 
     241        + \frac{1}{2\,e_1}\left. {\frac{\partial (u^2+v^2)}{\partial i}} \right|_s \\ 
     242      &\qquad \qquad \qquad \quad 
     243        + \frac{1}{e_3} \left[    {w\frac{\partial u}{\partial s} 
     244        +\sigma_1 v\frac{\partial v}{\partial s} - \sigma_2 v\frac{\partial u}{\partial s} 
     245        - \sigma_1 u\frac{\partial u}{\partial s} - \sigma_1 v\frac{\partial v}{\partial s}} \right] \\ \\ 
     246      &= \left. {\frac{\partial u }{\partial t}} \right|_z 
     247        + \left. \zeta \right|_s \;v 
     248        + \frac{1}{2\,e_1}\left. {\frac{\partial (u^2+v^2)}{\partial i}} \right|_s 
     249        + \frac{1}{e_3} \left[  w - \sigma_2 v - \sigma_1 u  \right] 
     250        \; \frac{\partial u}{\partial s}   \\ 
     251        % 
     252      \intertext{Introducing $\omega$, the dia-a-surface velocity given by (\autoref{apdx:A_w_s}) } 
     253      % 
     254      &= \left. {\frac{\partial u }{\partial t}} \right|_z 
     255        + \left. \zeta \right|_s \;v 
     256        + \frac{1}{2\,e_1}\left. {\frac{\partial (u^2+v^2)}{\partial i}} \right|_s 
     257        + \frac{1}{e_3 } \left( \omega - w_s \right) \frac{\partial u}{\partial s}   \\ 
     258    \end{array} 
     259    } 
     260  \end{align*} 
    257261\end{subequations} 
    258262% 
    259263Applying the time derivative chain rule (first equation of (\autoref{apdx:A_s_chain_rule})) to $u$ and 
    260264using (\autoref{apdx:A_w_in_s}) provides the expression of the last term of the right hand side, 
    261 \begin{equation*} {\begin{array}{*{20}l}  
    262 w_s  \;\frac{\partial u}{\partial s}  
    263    = \frac{\partial s}{\partial t} \;  \frac{\partial u }{\partial s} 
    264    = \left. {\frac{\partial u }{\partial t}} \right|_s  - \left. {\frac{\partial u }{\partial t}} \right|_z \quad ,  
    265 \end{array} }      
    266 \end{equation*} 
     265\[ 
     266  { 
     267    \begin{array}{*{20}l} 
     268      w_s  \;\frac{\partial u}{\partial s} 
     269      = \frac{\partial s}{\partial t} \;  \frac{\partial u }{\partial s} 
     270      = \left. {\frac{\partial u }{\partial t}} \right|_s  - \left. {\frac{\partial u }{\partial t}} \right|_z \quad , 
     271    \end{array} 
     272  } 
     273\] 
    267274leads to the $s-$coordinate formulation of the total $z-$coordinate time derivative, 
    268275$i.e.$ the total $s-$coordinate time derivative : 
    269 \begin{align} \label{apdx:A_sco_Dt_vect} 
    270 \left. \frac{D u}{D t} \right|_s  
    271   = \left. {\frac{\partial u }{\partial t}} \right|_s        
     276\begin{align} 
     277  \label{apdx:A_sco_Dt_vect} 
     278  \left. \frac{D u}{D t} \right|_s 
     279  = \left. {\frac{\partial u }{\partial t}} \right|_s 
    272280  + \left. \zeta \right|_s \;v 
    273   + \frac{1}{2\,e_1}\left. {\frac{\partial (u^2+v^2)}{\partial i}} \right|_s   
    274   + \frac{1}{e_3 } \omega \;\frac{\partial u}{\partial s}    
     281  + \frac{1}{2\,e_1}\left. {\frac{\partial (u^2+v^2)}{\partial i}} \right|_s 
     282  + \frac{1}{e_3 } \omega \;\frac{\partial u}{\partial s} 
    275283\end{align} 
    276284Therefore, the vector invariant form of the total time derivative has exactly the same mathematical form in 
     
    278286This is not the case for the flux form as shown in next paragraph. 
    279287 
    280 $\ $\newline    % force a new ligne 
    281  
    282288$\bullet$ \textbf{Total derivative in flux form} 
    283289 
    284290Let us start from the total time derivative in the curvilinear $s-$coordinate system we have just establish. 
    285291Following the procedure used to establish (\autoref{eq:PE_flux_form}), it can be transformed into : 
    286 %\begin{subequations}  
    287 \begin{align*} {\begin{array}{*{20}l}  
    288 \left. \frac{D u}{D t} \right|_s  &= \left. {\frac{\partial u }{\partial t}} \right|_s   
    289                             & -  \zeta \;v  
    290                         + \frac{1}{2\;e_1 } \frac{\partial \left( {u^2+v^2} \right)}{\partial i} 
    291                                                  + \frac{1}{e_3} \omega \;\frac{\partial u}{\partial s}          \\ 
    292 \\ 
    293   &= \left. {\frac{\partial u }{\partial t}} \right|_s   
    294           &+\frac{1}{e_1\;e_2}  \left(    \frac{\partial \left( {e_2 \,u\,u } \right)}{\partial i} 
    295                                           + \frac{\partial \left( {e_1 \,u\,v } \right)}{\partial j}     \right) 
    296             + \frac{1}{e_3 } \frac{\partial \left( {\omega\,u} \right)}{\partial s}                                \\  
    297 \\ 
    298         &&- \,u \left[     \frac{1}{e_1 e_2 } \left(    \frac{\partial(e_2 u)}{\partial i} 
    299                                    + \frac{\partial(e_1 v)}{\partial j}    \right) 
    300                           + \frac{1}{e_3}        \frac{\partial \omega}{\partial s}                       \right]      \\ 
    301 \\ 
    302         &&- \frac{v}{e_1 e_2 }\left(    v \;\frac{\partial e_2 }{\partial i} 
    303                           -u  \;\frac{\partial e_1 }{\partial j}  \right)                             \\ 
    304 \end{array} }      
     292% \begin{subequations} 
     293\begin{align*} 
     294  { 
     295  \begin{array}{*{20}l} 
     296    \left. \frac{D u}{D t} \right|_s  &= \left. {\frac{\partial u }{\partial t}} \right|_s 
     297    & -  \zeta \;v 
     298      + \frac{1}{2\;e_1 } \frac{\partial \left( {u^2+v^2} \right)}{\partial i} 
     299      + \frac{1}{e_3} \omega \;\frac{\partial u}{\partial s} \\ \\ 
     300                                      &= \left. {\frac{\partial u }{\partial t}} \right|_s 
     301    &+\frac{1}{e_1\;e_2}  \left(    \frac{\partial \left( {e_2 \,u\,u } \right)}{\partial i} 
     302      + \frac{\partial \left( {e_1 \,u\,v } \right)}{\partial j}     \right) 
     303      + \frac{1}{e_3 } \frac{\partial \left( {\omega\,u} \right)}{\partial s} \\ \\ 
     304                                      &&- \,u \left[     \frac{1}{e_1 e_2 } \left(    \frac{\partial(e_2 u)}{\partial i} 
     305                                         + \frac{\partial(e_1 v)}{\partial j}    \right) 
     306                                         + \frac{1}{e_3}        \frac{\partial \omega}{\partial s}                       \right] \\ \\ 
     307                                      &&- \frac{v}{e_1 e_2 }\left(    v \;\frac{\partial e_2 }{\partial i} 
     308                                         -u  \;\frac{\partial e_1 }{\partial j}  \right) \\ 
     309  \end{array} 
     310  } 
    305311\end{align*} 
    306312% 
    307313Introducing the vertical scale factor inside the horizontal derivative of the first two terms  
    308314($i.e.$ the horizontal divergence), it becomes : 
    309 \begin{subequations}  
    310 \begin{align*} {\begin{array}{*{20}l}  
    311 %\begin{align*} {\begin{array}{*{20}l}  
    312 %{\begin{array}{*{20}l}  
    313 \left. \frac{D u}{D t} \right|_s   
    314    &= \left. {\frac{\partial u }{\partial t}} \right|_s   
    315    &+ \frac{1}{e_1\,e_2\,e_3}  \left(  \frac{\partial( e_2 e_3 \,u^2 )}{\partial i} 
    316                                    + \frac{\partial( e_1 e_3 \,u v )}{\partial j}      
    317                               -  e_2 u u \frac{\partial e_3}{\partial i} 
    318                        -  e_1 u v \frac{\partial e_3 }{\partial j}    \right) 
    319        + \frac{1}{e_3} \frac{\partial \left( {\omega\,u} \right)}{\partial s}                                  \\ 
    320 \\ 
    321            && - \,u \left[  \frac{1}{e_1 e_2 e_3} \left(   \frac{\partial(e_2 e_3 \, u)}{\partial i}  
    322                                   + \frac{\partial(e_1 e_3 \, v)}{\partial j}   
    323                                         -  e_2 u \;\frac{\partial e_3 }{\partial i} 
    324                                         -  e_1 v \;\frac{\partial e_3 }{\partial j}   \right) 
    325              -\frac{1}{e_3}        \frac{\partial \omega}{\partial s}                       \right]                      \\ 
    326 \\ 
    327             && - \frac{v}{e_1 e_2 }\left(    v  \;\frac{\partial e_2 }{\partial i} 
    328                                 -u  \;\frac{\partial e_1 }{\partial j}  \right)                      \\ 
    329 \\ 
    330    &= \left. {\frac{\partial u }{\partial t}} \right|_s   
    331    &+ \frac{1}{e_1\,e_2\,e_3}  \left(  \frac{\partial( e_2 e_3 \,u\,u )}{\partial i} 
    332                                    + \frac{\partial( e_1 e_3 \,u\,v )}{\partial j}    \right) 
    333      + \frac{1}{e_3 } \frac{\partial \left( {\omega\,u} \right)}{\partial s}                               \\ 
    334 \\ 
    335 && - \,u \left[  \frac{1}{e_1 e_2 e_3} \left(   \frac{\partial(e_2 e_3 \, u)}{\partial i}  
    336                            + \frac{\partial(e_1 e_3 \, v)}{\partial j}  \right) 
    337         -\frac{1}{e_3}        \frac{\partial \omega}{\partial s}                       \right]                   
    338      - \frac{v}{e_1 e_2 }\left(  v   \;\frac{\partial e_2 }{\partial i} 
    339                                  -u   \;\frac{\partial e_1 }{\partial j}   \right)                  \\ 
    340 % 
    341 \intertext {Introducing a more compact form for the divergence of the momentum fluxes,  
    342 and using (\autoref{apdx:A_sco_Continuity}), the $s-$coordinate continuity equation,  
    343 it becomes : } 
    344 % 
    345    &= \left. {\frac{\partial u }{\partial t}} \right|_s   
    346    &+ \left.  \nabla \cdot \left(   {{\rm {\bf U}}\,u}   \right)    \right|_s 
    347      + \,u \frac{1}{e_3 } \frac{\partial e_3}{\partial t}     
     315\begin{align*} 
     316  { 
     317  \begin{array}{*{20}l} 
     318    % \begin{align*} {\begin{array}{*{20}l} 
     319    %     {\begin{array}{*{20}l} \left. \frac{D u}{D t} \right|_s   
     320    &= \left. {\frac{\partial u }{\partial t}} \right|_s 
     321    &+ \frac{1}{e_1\,e_2\,e_3}  \left(  \frac{\partial( e_2 e_3 \,u^2 )}{\partial i} 
     322      + \frac{\partial( e_1 e_3 \,u v )}{\partial j} 
     323      -  e_2 u u \frac{\partial e_3}{\partial i} 
     324      -  e_1 u v \frac{\partial e_3 }{\partial j}    \right) 
     325      + \frac{1}{e_3} \frac{\partial \left( {\omega\,u} \right)}{\partial s} \\ \\ 
     326    && - \,u \left[  \frac{1}{e_1 e_2 e_3} \left(   \frac{\partial(e_2 e_3 \, u)}{\partial i} 
     327       + \frac{\partial(e_1 e_3 \, v)}{\partial j} 
     328       -  e_2 u \;\frac{\partial e_3 }{\partial i} 
     329       -  e_1 v \;\frac{\partial e_3 }{\partial j}   \right) 
     330       -\frac{1}{e_3}        \frac{\partial \omega}{\partial s}                       \right] \\ \\ 
     331    && - \frac{v}{e_1 e_2 }\left(   v  \;\frac{\partial e_2 }{\partial i} 
     332       -u  \;\frac{\partial e_1 }{\partial j}   \right) \\ \\ 
     333    &= \left. {\frac{\partial u }{\partial t}} \right|_s 
     334    &+ \frac{1}{e_1\,e_2\,e_3}  \left(  \frac{\partial( e_2 e_3 \,u\,u )}{\partial i} 
     335      + \frac{\partial( e_1 e_3 \,u\,v )}{\partial j}    \right) 
     336      + \frac{1}{e_3 } \frac{\partial \left( {\omega\,u} \right)}{\partial s} \\ \\ 
     337    && - \,u \left[  \frac{1}{e_1 e_2 e_3} \left(   \frac{\partial(e_2 e_3 \, u)}{\partial i} 
     338       + \frac{\partial(e_1 e_3 \, v)}{\partial j}  \right) 
     339       -\frac{1}{e_3}        \frac{\partial \omega}{\partial s}                       \right] 
     340       - \frac{v}{e_1 e_2 }\left(   v   \;\frac{\partial e_2 }{\partial i} 
     341       -u   \;\frac{\partial e_1 }{\partial j}  \right)                  \\ 
     342     % 
     343    \intertext {Introducing a more compact form for the divergence of the momentum fluxes, 
     344    and using (\autoref{apdx:A_sco_Continuity}), the $s-$coordinate continuity equation, 
     345    it becomes : } 
     346  % 
     347    &= \left. {\frac{\partial u }{\partial t}} \right|_s 
     348    &+ \left.  \nabla \cdot \left(   {{\rm {\bf U}}\,u}   \right)    \right|_s 
     349      + \,u \frac{1}{e_3 } \frac{\partial e_3}{\partial t} 
    348350      - \frac{v}{e_1 e_2 }\left(    v  \;\frac{\partial e_2 }{\partial i} 
    349                          -u  \;\frac{\partial e_1 }{\partial j}   \right) \\ 
    350 \end{array} }      
     351      -u  \;\frac{\partial e_1 }{\partial j}    \right) 
     352    \\ 
     353  \end{array} 
     354  } 
    351355\end{align*} 
    352 \end{subequations} 
    353356which leads to the $s-$coordinate flux formulation of the total $s-$coordinate time derivative,  
    354357$i.e.$ the total $s-$coordinate time derivative in flux form: 
    355 \begin{flalign}\label{apdx:A_sco_Dt_flux} 
    356 \left. \frac{D u}{D t} \right|_s   = \frac{1}{e_3}  \left. \frac{\partial ( e_3\,u)}{\partial t} \right|_s   
    357            + \left.  \nabla \cdot \left(   {{\rm {\bf U}}\,u}   \right)    \right|_s 
    358            - \frac{v}{e_1 e_2 }\left(    v  \;\frac{\partial e_2 }{\partial i} 
    359                          -u  \;\frac{\partial e_1 }{\partial j}            \right) 
     358\begin{flalign} 
     359  \label{apdx:A_sco_Dt_flux} 
     360  \left. \frac{D u}{D t} \right|_s   = \frac{1}{e_3}  \left. \frac{\partial ( e_3\,u)}{\partial t} \right|_s 
     361  + \left.  \nabla \cdot \left(   {{\rm {\bf U}}\,u}   \right)    \right|_s 
     362  - \frac{v}{e_1 e_2 }\left(    v  \;\frac{\partial e_2 }{\partial i} 
     363    -u  \;\frac{\partial e_1 }{\partial j}            \right) 
    360364\end{flalign} 
    361365which is the total time derivative expressed in the curvilinear $s-$coordinate system. 
     
    365369the continuity equation. 
    366370 
    367 $\ $\newline    % force a new ligne 
    368  
    369371$\bullet$ \textbf{horizontal pressure gradient} 
    370372 
    371373The horizontal pressure gradient term can be transformed as follows: 
    372 \begin{equation*} 
    373 \begin{split} 
    374  -\frac{1}{\rho _o \, e_1 }\left. {\frac{\partial p}{\partial i}} \right|_z 
    375  & =-\frac{1}{\rho _o e_1 }\left[ {\left. {\frac{\partial p}{\partial i}} \right|_s -\frac{e_1 }{e_3 }\sigma _1 \frac{\partial p}{\partial s}} \right] \\ 
    376 & =-\frac{1}{\rho _o \,e_1 }\left. {\frac{\partial p}{\partial i}} \right|_s +\frac{\sigma _1 }{\rho _o \,e_3 }\left( {-g\;\rho \;e_3 } \right) \\ 
    377 &=-\frac{1}{\rho _o \,e_1 }\left. {\frac{\partial p}{\partial i}} \right|_s -\frac{g\;\rho }{\rho _o }\sigma _1 
    378 \end{split} 
    379 \end{equation*} 
     374\[ 
     375  \begin{split} 
     376    -\frac{1}{\rho_o \, e_1 }\left. {\frac{\partial p}{\partial i}} \right|_z 
     377    & =-\frac{1}{\rho_o e_1 }\left[ {\left. {\frac{\partial p}{\partial i}} \right|_s -\frac{e_1 }{e_3 }\sigma_1 \frac{\partial p}{\partial s}} \right] \\ 
     378    & =-\frac{1}{\rho_o \,e_1 }\left. {\frac{\partial p}{\partial i}} \right|_s +\frac{\sigma_1 }{\rho_o \,e_3 }\left( {-g\;\rho \;e_3 } \right) \\ 
     379    &=-\frac{1}{\rho_o \,e_1 }\left. {\frac{\partial p}{\partial i}} \right|_s -\frac{g\;\rho }{\rho_o }\sigma_1 
     380  \end{split} 
     381\] 
    380382Applying similar manipulation to the second component and 
    381 replacing $\sigma _1$ and $\sigma _2$ by their expression \autoref{apdx:A_s_slope}, it comes: 
    382 \begin{equation} \label{apdx:A_grad_p_1} 
    383 \begin{split} 
    384  -\frac{1}{\rho _o \, e_1 } \left. {\frac{\partial p}{\partial i}} \right|_z 
    385 &=-\frac{1}{\rho _o \,e_1 } \left(     \left.              {\frac{\partial p}{\partial i}} \right|_s  
    386                                                   + g\;\rho  \;\left. {\frac{\partial z}{\partial i}} \right|_s    \right) \\ 
    387 % 
    388  -\frac{1}{\rho _o \, e_2 }\left. {\frac{\partial p}{\partial j}} \right|_z 
    389 &=-\frac{1}{\rho _o \,e_2 } \left(    \left.               {\frac{\partial p}{\partial j}} \right|_s  
    390                                                    + g\;\rho \;\left. {\frac{\partial z}{\partial j}} \right|_s   \right) \\ 
    391 \end{split} 
     383replacing $\sigma_1$ and $\sigma_2$ by their expression \autoref{apdx:A_s_slope}, it comes: 
     384\begin{equation} 
     385  \label{apdx:A_grad_p_1} 
     386  \begin{split} 
     387    -\frac{1}{\rho_o \, e_1 } \left. {\frac{\partial p}{\partial i}} \right|_z 
     388    &=-\frac{1}{\rho_o \,e_1 } \left(     \left.              {\frac{\partial p}{\partial i}} \right|_s 
     389      + g\;\rho  \;\left. {\frac{\partial z}{\partial i}} \right|_s    \right) \\ 
     390             % 
     391    -\frac{1}{\rho_o \, e_2 }\left. {\frac{\partial p}{\partial j}} \right|_z 
     392    &=-\frac{1}{\rho_o \,e_2 } \left(    \left.               {\frac{\partial p}{\partial j}} \right|_s 
     393      + g\;\rho \;\left. {\frac{\partial z}{\partial j}} \right|_s   \right) \\ 
     394  \end{split} 
    392395\end{equation} 
    393396 
     
    400403and a hydrostatic pressure anomaly, $p_h'$, by $p_h'= g \; \int_z^\eta d \; e_3 \; dk$. 
    401404The pressure is then given by: 
    402 \begin{equation*}  
    403 \begin{split} 
    404 p &= g\; \int_z^\eta \rho \; e_3 \; dk = g\; \int_z^\eta \left(  \rho_o \, d + 1 \right) \; e_3 \; dk   \\ 
    405    &= g \, \rho_o \; \int_z^\eta d \; e_3 \; dk + g \, \int_z^\eta e_3 \; dk     
    406 \end{split} 
    407 \end{equation*} 
     405\[ 
     406  \begin{split} 
     407    p &= g\; \int_z^\eta \rho \; e_3 \; dk = g\; \int_z^\eta \left(  \rho_o \, d + 1 \right) \; e_3 \; dk   \\ 
     408    &= g \, \rho_o \; \int_z^\eta d \; e_3 \; dk + g \, \int_z^\eta e_3 \; dk 
     409  \end{split} 
     410\] 
    408411Therefore, $p$ and $p_h'$ are linked through: 
    409 \begin{equation} \label{apdx:A_pressure} 
    410    p = \rho_o \; p_h' + g \, ( z + \eta ) 
     412\begin{equation} 
     413  \label{apdx:A_pressure} 
     414  p = \rho_o \; p_h' + g \, ( z + \eta ) 
    411415\end{equation} 
    412416and the hydrostatic pressure balance expressed in terms of $p_h'$ and $d$ is: 
    413 \begin{equation*}  
    414 \frac{\partial p_h'}{\partial k} = - d \, g \, e_3 
    415 \end{equation*} 
     417\[ 
     418  \frac{\partial p_h'}{\partial k} = - d \, g \, e_3 
     419\] 
    416420 
    417421Substituing \autoref{apdx:A_pressure} in \autoref{apdx:A_grad_p_1} and 
    418422using the definition of the density anomaly it comes the expression in two parts: 
    419 \begin{equation} \label{apdx:A_grad_p_2} 
    420 \begin{split} 
    421  -\frac{1}{\rho _o \, e_1 } \left. {\frac{\partial p}{\partial i}} \right|_z 
    422 &=-\frac{1}{e_1 } \left(     \left.              {\frac{\partial p_h'}{\partial i}} \right|_s  
    423                                        + g\; d  \;\left. {\frac{\partial z}{\partial i}} \right|_s    \right)  - \frac{g}{e_1 } \frac{\partial \eta}{\partial i} \\ 
    424 % 
    425  -\frac{1}{\rho _o \, e_2 }\left. {\frac{\partial p}{\partial j}} \right|_z 
    426 &=-\frac{1}{e_2 } \left(    \left.               {\frac{\partial p_h'}{\partial j}} \right|_s  
    427                                         + g\; d \;\left. {\frac{\partial z}{\partial j}} \right|_s   \right)  - \frac{g}{e_2 } \frac{\partial \eta}{\partial j}\\ 
    428 \end{split} 
     423\begin{equation} 
     424  \label{apdx:A_grad_p_2} 
     425  \begin{split} 
     426    -\frac{1}{\rho_o \, e_1 } \left. {\frac{\partial p}{\partial i}} \right|_z 
     427    &=-\frac{1}{e_1 } \left(     \left.              {\frac{\partial p_h'}{\partial i}} \right|_s 
     428      + g\; d  \;\left. {\frac{\partial z}{\partial i}} \right|_s    \right)  - \frac{g}{e_1 } \frac{\partial \eta}{\partial i} \\ 
     429             % 
     430    -\frac{1}{\rho_o \, e_2 }\left. {\frac{\partial p}{\partial j}} \right|_z 
     431    &=-\frac{1}{e_2 } \left(    \left.               {\frac{\partial p_h'}{\partial j}} \right|_s 
     432      + g\; d \;\left. {\frac{\partial z}{\partial j}} \right|_s   \right)  - \frac{g}{e_2 } \frac{\partial \eta}{\partial j}\\ 
     433  \end{split} 
    429434\end{equation} 
    430435This formulation of the pressure gradient is characterised by the appearance of 
     
    437442and $\eta$ is implicitly included in the computation of $p_h'$ through the upper bound of the vertical integration. 
    438443 
    439  
    440 $\ $\newline    % force a new ligne 
    441  
    442444$\bullet$ \textbf{The other terms of the momentum equation} 
    443445 
     
    446448The form of the lateral physics is discussed in \autoref{apdx:B}. 
    447449 
    448  
    449 $\ $\newline    % force a new ligne 
    450  
    451450$\bullet$ \textbf{Full momentum equation} 
    452451 
     
    454453the vector invariant momentum equation solved by the model has the same mathematical expression as 
    455454the one in a curvilinear $z-$coordinate, except for the pressure gradient term: 
    456 \begin{subequations} \label{apdx:A_dyn_vect} 
    457 \begin{multline} \label{apdx:A_PE_dyn_vect_u} 
    458  \frac{\partial u}{\partial t}= 
    459    +   \left( {\zeta +f} \right)\,v                                     
    460    -   \frac{1}{2\,e_1} \frac{\partial}{\partial i} \left(  u^2+v^2   \right)  
    461    -   \frac{1}{e_3} \omega \frac{\partial u}{\partial k}       \\ 
    462         -   \frac{1}{e_1 } \left(    \frac{\partial p_h'}{\partial i} + g\; d  \; \frac{\partial z}{\partial i}    \right)   
    463         -   \frac{g}{e_1 } \frac{\partial \eta}{\partial i} 
    464    +   D_u^{\vect{U}}  +   F_u^{\vect{U}} 
    465 \end{multline} 
    466 \begin{multline} \label{apdx:A_dyn_vect_v} 
    467 \frac{\partial v}{\partial t}= 
    468    -   \left( {\zeta +f} \right)\,u    
    469    -   \frac{1}{2\,e_2 }\frac{\partial }{\partial j}\left(  u^2+v^2  \right)         
    470    -   \frac{1}{e_3 } \omega \frac{\partial v}{\partial k}         \\ 
    471         -   \frac{1}{e_2 } \left(    \frac{\partial p_h'}{\partial j} + g\; d  \; \frac{\partial z}{\partial j}    \right)   
    472         -   \frac{g}{e_2 } \frac{\partial \eta}{\partial j} 
    473    +  D_v^{\vect{U}}  +   F_v^{\vect{U}} 
    474 \end{multline} 
     455\begin{subequations} 
     456  \label{apdx:A_dyn_vect} 
     457  \begin{multline} 
     458    \label{apdx:A_PE_dyn_vect_u} 
     459    \frac{\partial u}{\partial t}= 
     460    +   \left( {\zeta +f} \right)\,v 
     461    -   \frac{1}{2\,e_1} \frac{\partial}{\partial i} \left(  u^2+v^2   \right) 
     462    -   \frac{1}{e_3} \omega \frac{\partial u}{\partial k}       \\ 
     463    -   \frac{1}{e_1 } \left(    \frac{\partial p_h'}{\partial i} + g\; d  \; \frac{\partial z}{\partial i}    \right) 
     464    -   \frac{g}{e_1 } \frac{\partial \eta}{\partial i} 
     465    +   D_u^{\vect{U}}  +   F_u^{\vect{U}} 
     466  \end{multline} 
     467  \begin{multline} 
     468    \label{apdx:A_dyn_vect_v} 
     469    \frac{\partial v}{\partial t}= 
     470    -   \left( {\zeta +f} \right)\,u 
     471    -   \frac{1}{2\,e_2 }\frac{\partial }{\partial j}\left(  u^2+v^2  \right) 
     472    -   \frac{1}{e_3 } \omega \frac{\partial v}{\partial k}         \\ 
     473    -   \frac{1}{e_2 } \left(    \frac{\partial p_h'}{\partial j} + g\; d  \; \frac{\partial z}{\partial j}    \right) 
     474    -   \frac{g}{e_2 } \frac{\partial \eta}{\partial j} 
     475    +  D_v^{\vect{U}}  +   F_v^{\vect{U}} 
     476  \end{multline} 
    475477\end{subequations} 
    476478whereas the flux form momentum equation differs from it by 
    477479the formulation of both the time derivative and the pressure gradient term: 
    478 \begin{subequations} \label{apdx:A_dyn_flux} 
    479 \begin{multline} \label{apdx:A_PE_dyn_flux_u} 
    480  \frac{1}{e_3} \frac{\partial \left(  e_3\,u  \right) }{\partial t} = 
    481    \nabla \cdot \left(   {{\rm {\bf U}}\,u}   \right)  
    482    +   \left\{ {f + \frac{1}{e_1 e_2 }\left(    v  \;\frac{\partial e_2 }{\partial i} 
    483                                        -u  \;\frac{\partial e_1 }{\partial j}            \right)} \right\} \,v     \\                                
    484         -   \frac{1}{e_1 } \left(    \frac{\partial p_h'}{\partial i} + g\; d  \; \frac{\partial z}{\partial i}    \right)   
    485         -   \frac{g}{e_1 } \frac{\partial \eta}{\partial i} 
    486    +   D_u^{\vect{U}}  +   F_u^{\vect{U}} 
    487 \end{multline} 
    488 \begin{multline} \label{apdx:A_dyn_flux_v} 
    489  \frac{1}{e_3}\frac{\partial \left(  e_3\,v  \right) }{\partial t}= 
    490    -  \nabla \cdot \left(   {{\rm {\bf U}}\,v}   \right)  
    491    +   \left\{ {f + \frac{1}{e_1 e_2 }\left(    v  \;\frac{\partial e_2 }{\partial i} 
    492                                         -u  \;\frac{\partial e_1 }{\partial j}            \right)} \right\} \,u     \\                                
    493         -   \frac{1}{e_2 } \left(    \frac{\partial p_h'}{\partial j} + g\; d  \; \frac{\partial z}{\partial j}    \right)   
    494         -   \frac{g}{e_2 } \frac{\partial \eta}{\partial j} 
    495    +  D_v^{\vect{U}}  +   F_v^{\vect{U}} 
    496 \end{multline} 
     480\begin{subequations} 
     481  \label{apdx:A_dyn_flux} 
     482  \begin{multline} 
     483    \label{apdx:A_PE_dyn_flux_u} 
     484    \frac{1}{e_3} \frac{\partial \left(  e_3\,u  \right) }{\partial t} = 
     485    \nabla \cdot \left(   {{\rm {\bf U}}\,u}   \right) 
     486    +   \left\{ {f + \frac{1}{e_1 e_2 }\left(    v  \;\frac{\partial e_2 }{\partial i} 
     487          -u  \;\frac{\partial e_1 }{\partial j}            \right)} \right\} \,v     \\ 
     488    -   \frac{1}{e_1 } \left(    \frac{\partial p_h'}{\partial i} + g\; d  \; \frac{\partial z}{\partial i}    \right) 
     489    -   \frac{g}{e_1 } \frac{\partial \eta}{\partial i} 
     490    +   D_u^{\vect{U}}  +   F_u^{\vect{U}} 
     491  \end{multline} 
     492  \begin{multline} 
     493    \label{apdx:A_dyn_flux_v} 
     494    \frac{1}{e_3}\frac{\partial \left(  e_3\,v  \right) }{\partial t}= 
     495    -  \nabla \cdot \left(   {{\rm {\bf U}}\,v}   \right) 
     496    +   \left\{ {f + \frac{1}{e_1 e_2 }\left(    v  \;\frac{\partial e_2 }{\partial i} 
     497          -u  \;\frac{\partial e_1 }{\partial j}            \right)} \right\} \,u     \\ 
     498    -   \frac{1}{e_2 } \left(    \frac{\partial p_h'}{\partial j} + g\; d  \; \frac{\partial z}{\partial j}    \right) 
     499    -   \frac{g}{e_2 } \frac{\partial \eta}{\partial j} 
     500    +  D_v^{\vect{U}}  +   F_v^{\vect{U}} 
     501  \end{multline} 
    497502\end{subequations} 
    498503Both formulation share the same hydrostatic pressure balance expressed in terms of 
    499504hydrostatic pressure and density anomalies, $p_h'$ and $d=( \frac{\rho}{\rho_o}-1 )$: 
    500 \begin{equation} \label{apdx:A_dyn_zph} 
    501 \frac{\partial p_h'}{\partial k} = - d \, g \, e_3 
     505\begin{equation} 
     506  \label{apdx:A_dyn_zph} 
     507  \frac{\partial p_h'}{\partial k} = - d \, g \, e_3 
    502508\end{equation} 
    503509 
     
    519525regrouping the time derivative terms in the left hand side : 
    520526 
    521 \begin{multline} \label{apdx:A_tracer} 
    522  \frac{1}{e_3} \frac{\partial \left(  e_3 T  \right)}{\partial t}  
    523    = -\frac{1}{e_1 \,e_2 \,e_3}  
    524       \left[           \frac{\partial }{\partial i} \left( {e_2 \,e_3 \;Tu} \right)  
    525                    +   \frac{\partial }{\partial j} \left( {e_1 \,e_3 \;Tv} \right)               \right]       \\ 
    526    +  \frac{1}{e_3}  \frac{\partial }{\partial k} \left(                   Tw  \right)   
    527     +  D^{T} +F^{T} 
     527\begin{multline} 
     528  \label{apdx:A_tracer} 
     529  \frac{1}{e_3} \frac{\partial \left(  e_3 T  \right)}{\partial t} 
     530  = -\frac{1}{e_1 \,e_2 \,e_3} 
     531  \left[           \frac{\partial }{\partial i} \left( {e_2 \,e_3 \;Tu} \right) 
     532    +   \frac{\partial }{\partial j} \left( {e_1 \,e_3 \;Tv} \right)               \right]       \\ 
     533  +  \frac{1}{e_3}  \frac{\partial }{\partial k} \left(                   Tw  \right) 
     534  +  D^{T} +F^{T} 
    528535\end{multline} 
    529  
    530536 
    531537The expression for the advection term is a straight consequence of (A.4), 
    532538the expression of the 3D divergence in the $s-$coordinates established above.  
    533539 
     540\biblio 
     541 
    534542\end{document} 
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex/NEMO/subfiles/annex_B.tex

    r10368 r10419  
    1 \documentclass[../tex_main/NEMO_manual]{subfiles} 
     1\documentclass[../main/NEMO_manual]{subfiles} 
     2 
    23\begin{document} 
    34% ================================================================ 
    4 % Chapter Ñ Appendix B : Diffusive Operators 
     5% Chapter Appendix B : Diffusive Operators 
    56% ================================================================ 
    67\chapter{Appendix B : Diffusive Operators} 
    78\label{apdx:B} 
     9 
    810\minitoc 
    911 
    10  
    1112\newpage 
    12 $\ $\newline    % force a new ligne 
    1313 
    1414% ================================================================ 
     
    1919 
    2020\subsubsection*{In z-coordinates} 
     21 
    2122In $z$-coordinates, the horizontal/vertical second order tracer diffusion operator is given by: 
    22 \begin{eqnarray} \label{apdx:B1} 
    23  &D^T = \frac{1}{e_1 \, e_2}      \left[ 
    24   \left. \frac{\partial}{\partial i} \left(  \frac{e_2}{e_1}A^{lT} \;\left. \frac{\partial T}{\partial i} \right|_z   \right)   \right|_z      \right. 
    25                        \left. 
    26 + \left. \frac{\partial}{\partial j} \left(  \frac{e_1}{e_2}A^{lT} \;\left. \frac{\partial T}{\partial j} \right|_z   \right)   \right|_z      \right] 
    27 + \frac{\partial }{\partial z}\left( {A^{vT} \;\frac{\partial T}{\partial z}} \right) 
    28 \end{eqnarray} 
     23\begin{align} 
     24  \label{apdx:B1} 
     25  &D^T = \frac{1}{e_1 \, e_2}      \left[ 
     26    \left. \frac{\partial}{\partial i} \left(   \frac{e_2}{e_1}A^{lT} \;\left. \frac{\partial T}{\partial i} \right|_z   \right)   \right|_z      \right. 
     27    \left. 
     28    + \left. \frac{\partial}{\partial j} \left(  \frac{e_1}{e_2}A^{lT} \;\left. \frac{\partial T}{\partial j} \right|_z   \right)   \right|_z      \right] 
     29    + \frac{\partial }{\partial z}\left( {A^{vT} \;\frac{\partial T}{\partial z}} \right) 
     30\end{align} 
    2931 
    3032\subsubsection*{In generalized vertical coordinates} 
     33 
    3134In $s$-coordinates, we defined the slopes of $s$-surfaces, $\sigma_1$ and $\sigma_2$ by \autoref{apdx:A_s_slope} and 
    3235the vertical/horizontal ratio of diffusion coefficient by $\epsilon = A^{vT} / A^{lT}$. 
    3336The diffusion operator is given by: 
    3437 
    35 \begin{equation} \label{apdx:B2} 
    36 D^T = \left. \nabla \right|_s \cdot 
    37            \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_s T  \right] \\ 
    38 \;\;\text{where} \;\Re =\left( {{\begin{array}{*{20}c} 
    39  1 \hfill & 0 \hfill & {-\sigma _1 } \hfill \\ 
    40  0 \hfill & 1 \hfill & {-\sigma _2 } \hfill \\ 
    41  {-\sigma _1 } \hfill & {-\sigma _2 } \hfill & {\varepsilon +\sigma _1 
    42 ^2+\sigma _2 ^2} \hfill \\ 
    43 \end{array} }} \right) 
     38\begin{equation} 
     39  \label{apdx:B2} 
     40  D^T = \left. \nabla \right|_s \cdot 
     41  \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_s T  \right] \\ 
     42  \;\;\text{where} \;\Re =\left( {{ 
     43        \begin{array}{*{20}c} 
     44          1 \hfill & 0 \hfill & {-\sigma_1 } \hfill \\ 
     45          0 \hfill & 1 \hfill & {-\sigma_2 } \hfill \\ 
     46          {-\sigma_1 } \hfill & {-\sigma_2 } \hfill & {\varepsilon +\sigma_1 
     47                                                      ^2+\sigma_2 ^2} \hfill \\ 
     48        \end{array} 
     49      }} \right) 
    4450\end{equation} 
    4551or in expanded form: 
    46 \begin{subequations} 
    47 \begin{align*} {\begin{array}{*{20}l} 
    48 D^T=& \frac{1}{e_1\,e_2\,e_3 }\;\left[ {\ \ \ \ e_2\,e_3\,A^{lT} \;\left. 
    49 {\frac{\partial }{\partial i}\left( {\frac{1}{e_1}\;\left. {\frac{\partial T}{\partial i}} \right|_s -\frac{\sigma _1 }{e_3 }\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right.  \\ 
    50 &\qquad \quad \ \ \ +e_1\,e_3\,A^{lT} \;\left. {\frac{\partial }{\partial j}\left( {\frac{1}{e_2 }\;\left. {\frac{\partial T}{\partial j}} \right|_s -\frac{\sigma _2 }{e_3 }\;\frac{\partial T}{\partial s}} \right)} \right|_s \\ 
    51 &\qquad \quad \ \ \ + e_1\,e_2\,A^{lT} \;\frac{\partial }{\partial s}\left( {-\frac{\sigma _1 }{e_1 }\;\left. {\frac{\partial T}{\partial i}} \right|_s -\frac{\sigma _2 }{e_2 }\;\left. {\frac{\partial T}{\partial j}} \right|_s } \right. 
    52  \left. {\left. {+\left( {\varepsilon +\sigma _1^2+\sigma _2 ^2} \right)\;\frac{1}{e_3 }\;\frac{\partial T}{\partial s}} \right)\;\;} \right] 
    53 \end{array} } 
     52\begin{align*} 
     53  { 
     54  \begin{array}{*{20}l} 
     55    D^T=& \frac{1}{e_1\,e_2\,e_3 }\;\left[ {\ \ \ \ e_2\,e_3\,A^{lT} \;\left. 
     56          {\frac{\partial }{\partial i}\left( {\frac{1}{e_1}\;\left. {\frac{\partial T}{\partial i}} \right|_s -\frac{\sigma_1 }{e_3 }\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right.  \\ 
     57        &\qquad \quad \ \ \ +e_1\,e_3\,A^{lT} \;\left. {\frac{\partial }{\partial j}\left( {\frac{1}{e_2 }\;\left. {\frac{\partial T}{\partial j}} \right|_s -\frac{\sigma_2 }{e_3 }\;\frac{\partial T}{\partial s}} \right)} \right|_s \\ 
     58        &\qquad \quad \ \ \ + e_1\,e_2\,A^{lT} \;\frac{\partial }{\partial s}\left( {-\frac{\sigma_1 }{e_1 }\;\left. {\frac{\partial T}{\partial i}} \right|_s -\frac{\sigma_2 }{e_2 }\;\left. {\frac{\partial T}{\partial j}} \right|_s } \right. 
     59          \left. {\left. {+\left( {\varepsilon +\sigma_1^2+\sigma_2 ^2} \right)\;\frac{1}{e_3 }\;\frac{\partial T}{\partial s}} \right)\;\;} \right] 
     60  \end{array} 
     61          } 
    5462\end{align*} 
    55 \end{subequations} 
    5663 
    5764Equation \autoref{apdx:B2} is obtained from \autoref{apdx:B1} without any additional assumption. 
     
    6471any loss of generality: 
    6572 
    66 \begin{subequations} 
    67 \begin{align*} {\begin{array}{*{20}l} 
    68 D^T&=\frac{1}{e_1\,e_2} \left. {\frac{\partial }{\partial i}\left( {\frac{e_2}{e_1}A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_z } \right)} \right|_z 
    69                      +\frac{\partial }{\partial z}\left( {A^{vT}\;\frac{\partial T}{\partial z}} \right)     \\ 
    70  \\ 
    71 % 
    72 &=\frac{1}{e_1\,e_2 }\left[ {\left. {\;\frac{\partial }{\partial i}\left( {\frac{e_2}{e_1}A^{lT}\;\left( {\left. {\frac{\partial T}{\partial i}} \right|_s 
    73                                                     -\frac{e_1\,\sigma _1 }{e_3 }\frac{\partial T}{\partial s}} \right)} \right)} \right|_s } \right. \\ 
    74 & \qquad \qquad \left. { -\frac{e_1\,\sigma _1 }{e_3 }\frac{\partial }{\partial s}\left( {\frac{e_2 }{e_1 }A^{lT}\;\left. {\left( {\left. {\frac{\partial T}{\partial i}} \right|_s -\frac{e_1 \,\sigma _1 }{e_3 }\frac{\partial T}{\partial s}} \right)} \right|_s } \right)\;} \right] 
    75 \shoveright{ +\frac{1}{e_3 }\frac{\partial }{\partial s}\left[ {\frac{A^{vT}}{e_3 }\;\frac{\partial T}{\partial s}} \right]}  \qquad \qquad \qquad \\ 
    76  \\ 
    77 % 
    78 &=\frac{1}{e_1 \,e_2 \,e_3 }\left[ {\left. {\;\;\frac{\partial }{\partial i}\left( {\frac{e_2 \,e_3 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right)} \right|_s -\left. {\frac{e_2 }{e_1}A^{lT}\;\frac{\partial e_3 }{\partial i}} \right|_s \left. {\frac{\partial T}{\partial i}} \right|_s } \right. \\ 
    79 &  \qquad \qquad \quad \left. {-e_3 \frac{\partial }{\partial i}\left( {\frac{e_2 \,\sigma _1 }{e_3 }A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s -e_1 \,\sigma _1 \frac{\partial }{\partial s}\left( {\frac{e_2 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right) \\ 
    80 &  \qquad \qquad \quad \shoveright{ -e_1 \,\sigma _1 \frac{\partial }{\partial s}\left( {-\frac{e_2 \,\sigma _1 }{e_3 }A^{lT}\;\frac{\partial T}{\partial s}} \right)\;\,\left. {+\frac{\partial }{\partial s}\left( {\frac{e_1 \,e_2 }{e_3 }A^{vT}\;\frac{\partial T}{\partial s}} \right)\quad} \right] }\\ 
    81 \end{array} }     \\ 
    82 % 
    83  {\begin{array}{*{20}l} 
    84 \intertext{Noting that $\frac{1}{e_1} \left. \frac{\partial e_3 }{\partial i} \right|_s = \frac{\partial \sigma _1 }{\partial s}$, it becomes:} 
    85 % 
    86 & =\frac{1}{e_1\,e_2\,e_3 }\left[ {\left. {\;\;\;\frac{\partial }{\partial i}\left( {\frac{e_2\,e_3 }{e_1}\,A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right)} \right|_s \left. -\, {e_3 \frac{\partial }{\partial i}\left( {\frac{e_2 \,\sigma _1 }{e_3 }A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right. \\ 
    87 & \qquad \qquad \quad -e_2 A^{lT}\;\frac{\partial \sigma _1 }{\partial s}\left. {\frac{\partial T}{\partial i}} \right|_s -e_1 \,\sigma_1 \frac{\partial }{\partial s}\left( {\frac{e_2 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right) \\ 
    88 & \qquad \qquad \quad\shoveright{ \left. { +e_1 \,\sigma _1 \frac{\partial }{\partial s}\left( {\frac{e_2 \,\sigma _1 }{e_3 }A^{lT}\;\frac{\partial T}{\partial s}} \right)+\frac{\partial }{\partial s}\left( {\frac{e_1 \,e_2 }{e_3 }A^{vT}\;\frac{\partial T}{\partial z}} \right)\;\;\;} \right] }\\ 
    89 \\ 
    90 &=\frac{1}{e_1 \,e_2 \,e_3 } \left[ {\left. {\;\;\;\frac{\partial }{\partial i} \left( {\frac{e_2 \,e_3 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right)} \right|_s \left. {-\frac{\partial }{\partial i}\left( {e_2 \,\sigma _1 A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right. \\ 
    91 & \qquad \qquad \quad \left. {+\frac{e_2 \,\sigma _1 }{e_3}A^{lT}\;\frac{\partial T}{\partial s} \;\frac{\partial e_3 }{\partial i}}  \right|_s -e_2 A^{lT}\;\frac{\partial \sigma _1 }{\partial s}\left. {\frac{\partial T}{\partial i}} \right|_s \\ 
    92 & \qquad \qquad \quad-e_2 \,\sigma _1 \frac{\partial}{\partial s}\left( {A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right)+\frac{\partial }{\partial s}\left( {\frac{e_1 \,e_2 \,\sigma _1 ^2}{e_3 }A^{lT}\;\frac{\partial T}{\partial s}} \right) \\ 
    93 & \qquad \qquad \quad\shoveright{ \left. {-\frac{\partial \left( {e_1 \,e_2 \,\sigma _1 } \right)}{\partial s} \left( {\frac{\sigma _1 }{e_3}A^{lT}\;\frac{\partial T}{\partial s}} \right) + \frac{\partial }{\partial s}\left( {\frac{e_1 \,e_2 }{e_3 }A^{vT}\;\frac{\partial T}{\partial s}} \right)\;\;\;} \right]} 
    94 \end{array} } \\ 
    95 {\begin{array}{*{20}l} 
    96 % 
    97 \intertext{using the same remark as just above, it becomes:} 
    98 % 
    99 &= \frac{1}{e_1 \,e_2 \,e_3 } \left[ {\left. {\;\;\;\frac{\partial }{\partial i} \left( {\frac{e_2 \,e_3 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s -e_2 \,\sigma _1 A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right.\;\;\; \\ 
    100 & \qquad \qquad \quad+\frac{e_1 \,e_2 \,\sigma _1 }{e_3 }A^{lT}\;\frac{\partial T}{\partial s}\;\frac{\partial \sigma _1 }{\partial s} - \frac {\sigma _1 }{e_3} A^{lT} \;\frac{\partial \left( {e_1 \,e_2 \,\sigma _1 } \right)}{\partial s}\;\frac{\partial T}{\partial s} \\ 
    101 & \qquad \qquad \quad-e_2 \left( {A^{lT}\;\frac{\partial \sigma _1 }{\partial s}\left. {\frac{\partial T}{\partial i}} \right|_s +\frac{\partial }{\partial s}\left( {\sigma _1 A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right)-\frac{\partial \sigma _1 }{\partial s}\;A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right) \\ 
    102 & \qquad \qquad \quad\shoveright{\left. {+\frac{\partial }{\partial s}\left( {\frac{e_1 \,e_2 \,\sigma _1 ^2}{e_3 }A^{lT}\;\frac{\partial T}{\partial s}+\frac{e_1 \,e_2}{e_3 }A^{vT}\;\frac{\partial T}{\partial s}} \right)\;\;\;} \right] } 
    103  \end{array} } \\ 
    104 {\begin{array}{*{20}l} 
    105 % 
    106 \intertext{Since the horizontal scale factors do not depend on the vertical coordinate, 
    107 the last term of the first line and the first term of the last line cancel, while 
    108 the second line reduces to a single vertical derivative, so it becomes:} 
    109 % 
    110 & =\frac{1}{e_1 \,e_2 \,e_3 }\left[ {\left. {\;\;\;\frac{\partial }{\partial i}\left( {\frac{e_2 \,e_3 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s -e_2 \,\sigma _1 \,A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right. \\ 
    111 & \qquad \qquad \quad \shoveright{ \left. {+\frac{\partial }{\partial s}\left( {-e_2 \,\sigma _1 \,A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s +A^{lT}\frac{e_1 \,e_2 }{e_3 }\;\left( {\varepsilon +\sigma _1 ^2} \right)\frac{\partial T}{\partial s}} \right)\;\;\;} \right]} 
    112  \\ 
    113 % 
    114 \intertext{in other words, the horizontal/vertical Laplacian operator in the ($i$,$s$) plane takes the following form:} 
    115 \end{array} } \\ 
    116 % 
    117 {\frac{1}{e_1\,e_2\,e_3}} 
    118 \left( {{\begin{array}{*{30}c} 
    119 {\left. {\frac{\partial \left( {e_2 e_3 \bullet } \right)}{\partial i}} \right|_s } \hfill \\ 
    120 {\frac{\partial \left( {e_1 e_2 \bullet } \right)}{\partial s}} \hfill \\ 
    121 \end{array}}}\right) 
    122 \cdot \left[ {A^{lT} 
    123 \left( {{\begin{array}{*{30}c} 
    124  {1} \hfill & {-\sigma_1 } \hfill \\ 
    125  {-\sigma_1} \hfill & {\varepsilon + \sigma_1^2} \hfill \\ 
    126 \end{array} }} \right) 
    127 \cdot 
    128 \left( {{\begin{array}{*{30}c} 
    129 {\frac{1}{e_1 }\;\left. {\frac{\partial \bullet }{\partial i}} \right|_s } \hfill \\ 
    130 {\frac{1}{e_3 }\;\frac{\partial \bullet }{\partial s}} \hfill \\ 
    131 \end{array}}}       \right) \left( T \right)} \right] 
     73\begin{align*} 
     74  { 
     75  \begin{array}{*{20}l} 
     76    D^T&=\frac{1}{e_1\,e_2} \left. {\frac{\partial }{\partial i}\left( {\frac{e_2}{e_1}A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_z } \right)} \right|_z 
     77         +\frac{\partial }{\partial z}\left( {A^{vT}\;\frac{\partial T}{\partial z}} \right) \\ \\ 
     78         % 
     79       &=\frac{1}{e_1\,e_2 }\left[ {\left. {\;\frac{\partial }{\partial i}\left( {\frac{e_2}{e_1}A^{lT}\;\left( {\left. {\frac{\partial T}{\partial i}} \right|_s 
     80         -\frac{e_1\,\sigma_1 }{e_3 }\frac{\partial T}{\partial s}} \right)} \right)} \right|_s } \right. \\ 
     81       & \qquad \qquad \left. { -\frac{e_1\,\sigma_1 }{e_3 }\frac{\partial }{\partial s}\left( {\frac{e_2 }{e_1 }A^{lT}\;\left. {\left( {\left. {\frac{\partial T}{\partial i}} \right|_s -\frac{e_1 \,\sigma_1 }{e_3 }\frac{\partial T}{\partial s}} \right)} \right|_s } \right)\;} \right] 
     82         \shoveright{ +\frac{1}{e_3 }\frac{\partial }{\partial s}\left[ {\frac{A^{vT}}{e_3 }\;\frac{\partial T}{\partial s}} \right]}  \qquad \qquad \qquad \\ \\ 
     83         % 
     84       &=\frac{1}{e_1 \,e_2 \,e_3 }\left[ {\left. {\;\;\frac{\partial }{\partial i}\left( {\frac{e_2 \,e_3 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right)} \right|_s -\left. {\frac{e_2 }{e_1}A^{lT}\;\frac{\partial e_3 }{\partial i}} \right|_s \left. {\frac{\partial T}{\partial i}} \right|_s } \right. \\ 
     85       &  \qquad \qquad \quad \left. {-e_3 \frac{\partial }{\partial i}\left( {\frac{e_2 \,\sigma_1 }{e_3 }A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s -e_1 \,\sigma_1 \frac{\partial }{\partial s}\left( {\frac{e_2 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right) \\ 
     86       &  \qquad \qquad \quad \shoveright{ -e_1 \,\sigma_1 \frac{\partial }{\partial s}\left( {-\frac{e_2 \,\sigma_1 }{e_3 }A^{lT}\;\frac{\partial T}{\partial s}} \right)\;\,\left. {+\frac{\partial }{\partial s}\left( {\frac{e_1 \,e_2 }{e_3 }A^{vT}\;\frac{\partial T}{\partial s}} \right)\quad} \right] }\\ 
     87  \end{array} 
     88  }      \\ 
     89  % 
     90  { 
     91  \begin{array}{*{20}l} 
     92    \intertext{Noting that $\frac{1}{e_1} \left. \frac{\partial e_3 }{\partial i} \right|_s = \frac{\partial \sigma_1 }{\partial s}$, it becomes:} 
     93    % 
     94    & =\frac{1}{e_1\,e_2\,e_3 }\left[ {\left. {\;\;\;\frac{\partial }{\partial i}\left( {\frac{e_2\,e_3 }{e_1}\,A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right)} \right|_s \left. -\, {e_3 \frac{\partial }{\partial i}\left( {\frac{e_2 \,\sigma_1 }{e_3 }A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right. \\ 
     95    & \qquad \qquad \quad -e_2 A^{lT}\;\frac{\partial \sigma_1 }{\partial s}\left. {\frac{\partial T}{\partial i}} \right|_s -e_1 \,\sigma_1 \frac{\partial }{\partial s}\left( {\frac{e_2 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right) \\ 
     96    & \qquad \qquad \quad\shoveright{ \left. { +e_1 \,\sigma_1 \frac{\partial }{\partial s}\left( {\frac{e_2 \,\sigma_1 }{e_3 }A^{lT}\;\frac{\partial T}{\partial s}} \right)+\frac{\partial }{\partial s}\left( {\frac{e_1 \,e_2 }{e_3 }A^{vT}\;\frac{\partial T}{\partial z}} \right)\;\;\;} \right] }\\ 
     97    \\ 
     98    &=\frac{1}{e_1 \,e_2 \,e_3 } \left[ {\left. {\;\;\;\frac{\partial }{\partial i} \left( {\frac{e_2 \,e_3 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right)} \right|_s \left. {-\frac{\partial }{\partial i}\left( {e_2 \,\sigma_1 A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right. \\ 
     99    & \qquad \qquad \quad \left. {+\frac{e_2 \,\sigma_1 }{e_3}A^{lT}\;\frac{\partial T}{\partial s} \;\frac{\partial e_3 }{\partial i}}  \right|_s -e_2 A^{lT}\;\frac{\partial \sigma_1 }{\partial s}\left. {\frac{\partial T}{\partial i}} \right|_s \\ 
     100    & \qquad \qquad \quad-e_2 \,\sigma_1 \frac{\partial}{\partial s}\left( {A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right)+\frac{\partial }{\partial s}\left( {\frac{e_1 \,e_2 \,\sigma_1 ^2}{e_3 }A^{lT}\;\frac{\partial T}{\partial s}} \right) \\ 
     101    & \qquad \qquad \quad\shoveright{ \left. {-\frac{\partial \left( {e_1 \,e_2 \,\sigma_1 } \right)}{\partial s} \left( {\frac{\sigma_1 }{e_3}A^{lT}\;\frac{\partial T}{\partial s}} \right) + \frac{\partial }{\partial s}\left( {\frac{e_1 \,e_2 }{e_3 }A^{vT}\;\frac{\partial T}{\partial s}} \right)\;\;\;} \right]} 
     102  \end{array} 
     103      } \\ 
     104  { 
     105  \begin{array}{*{20}l} 
     106    % 
     107    \intertext{using the same remark as just above, it becomes:} 
     108    % 
     109    &= \frac{1}{e_1 \,e_2 \,e_3 } \left[ {\left. {\;\;\;\frac{\partial }{\partial i} \left( {\frac{e_2 \,e_3 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s -e_2 \,\sigma_1 A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right.\;\;\; \\ 
     110    & \qquad \qquad \quad+\frac{e_1 \,e_2 \,\sigma_1 }{e_3 }A^{lT}\;\frac{\partial T}{\partial s}\;\frac{\partial \sigma_1 }{\partial s} - \frac {\sigma_1 }{e_3} A^{lT} \;\frac{\partial \left( {e_1 \,e_2 \,\sigma_1 } \right)}{\partial s}\;\frac{\partial T}{\partial s} \\ 
     111    & \qquad \qquad \quad-e_2 \left( {A^{lT}\;\frac{\partial \sigma_1 }{\partial s}\left. {\frac{\partial T}{\partial i}} \right|_s +\frac{\partial }{\partial s}\left( {\sigma_1 A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right)-\frac{\partial \sigma_1 }{\partial s}\;A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s } \right) \\ 
     112    & \qquad \qquad \quad\shoveright{\left. {+\frac{\partial }{\partial s}\left( {\frac{e_1 \,e_2 \,\sigma_1 ^2}{e_3 }A^{lT}\;\frac{\partial T}{\partial s}+\frac{e_1 \,e_2}{e_3 }A^{vT}\;\frac{\partial T}{\partial s}} \right)\;\;\;} \right] } 
     113  \end{array} 
     114      } \\ 
     115  { 
     116  \begin{array}{*{20}l} 
     117    % 
     118    \intertext{Since the horizontal scale factors do not depend on the vertical coordinate, 
     119    the last term of the first line and the first term of the last line cancel, while 
     120    the second line reduces to a single vertical derivative, so it becomes:} 
     121  % 
     122    & =\frac{1}{e_1 \,e_2 \,e_3 }\left[ {\left. {\;\;\;\frac{\partial }{\partial i}\left( {\frac{e_2 \,e_3 }{e_1 }A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s -e_2 \,\sigma_1 \,A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right. \\ 
     123    & \qquad \qquad \quad \shoveright{ \left. {+\frac{\partial }{\partial s}\left( {-e_2 \,\sigma_1 \,A^{lT}\;\left. {\frac{\partial T}{\partial i}} \right|_s +A^{lT}\frac{e_1 \,e_2 }{e_3 }\;\left( {\varepsilon +\sigma_1 ^2} \right)\frac{\partial T}{\partial s}} \right)\;\;\;} \right]} \\ 
     124    % 
     125    \intertext{in other words, the horizontal/vertical Laplacian operator in the ($i$,$s$) plane takes the following form:} 
     126  \end{array} 
     127  } \\ 
     128  % 
     129  {\frac{1}{e_1\,e_2\,e_3}} 
     130  \left( {{ 
     131  \begin{array}{*{30}c} 
     132    {\left. {\frac{\partial \left( {e_2 e_3 \bullet } \right)}{\partial i}} \right|_s } \hfill \\ 
     133    {\frac{\partial \left( {e_1 e_2 \bullet } \right)}{\partial s}} \hfill \\ 
     134  \end{array}}} 
     135  \right) 
     136  \cdot \left[ {A^{lT} 
     137  \left( {{ 
     138  \begin{array}{*{30}c} 
     139    {1} \hfill & {-\sigma_1 } \hfill \\ 
     140    {-\sigma_1} \hfill & {\varepsilon + \sigma_1^2} \hfill \\ 
     141  \end{array} 
     142  }} \right) 
     143  \cdot 
     144  \left( {{ 
     145  \begin{array}{*{30}c} 
     146    {\frac{1}{e_1 }\;\left. {\frac{\partial \bullet }{\partial i}} \right|_s } \hfill \\ 
     147    {\frac{1}{e_3 }\;\frac{\partial \bullet }{\partial s}} \hfill \\ 
     148  \end{array} 
     149  }}       \right) \left( T \right)} \right] 
    132150\end{align*} 
    133 \end{subequations} 
    134 \addtocounter{equation}{-2} 
     151%\addtocounter{equation}{-2} 
    135152 
    136153% ================================================================ 
     
    147164takes the following form \citep{Redi_JPO82}: 
    148165 
    149 \begin{equation} \label{apdx:B3} 
    150 \textbf {A}_{\textbf I} = \frac{A^{lT}}{\left( {1+a_1 ^2+a_2 ^2} \right)} 
    151 \left[ {{\begin{array}{*{20}c} 
    152  {1+a_1 ^2} \hfill & {-a_1 a_2 } \hfill & {-a_1 } \hfill \\ 
    153  {-a_1 a_2 } \hfill & {1+a_2 ^2} \hfill & {-a_2 } \hfill \\ 
    154  {-a_1 } \hfill & {-a_2 } \hfill & {\varepsilon +a_1 ^2+a_2 ^2} \hfill \\ 
    155 \end{array} }} \right] 
     166\begin{equation} 
     167  \label{apdx:B3} 
     168  \textbf {A}_{\textbf I} = \frac{A^{lT}}{\left( {1+a_1 ^2+a_2 ^2} \right)} 
     169  \left[ {{ 
     170        \begin{array}{*{20}c} 
     171          {1+a_1 ^2} \hfill & {-a_1 a_2 } \hfill & {-a_1 } \hfill \\ 
     172          {-a_1 a_2 } \hfill & {1+a_2 ^2} \hfill & {-a_2 } \hfill \\ 
     173          {-a_1 } \hfill & {-a_2 } \hfill & {\varepsilon +a_1 ^2+a_2 ^2} \hfill \\ 
     174        \end{array} 
     175      }} \right] 
    156176\end{equation} 
    157177where ($a_1$, $a_2$) are the isopycnal slopes in ($\textbf{i}$, $\textbf{j}$) directions, relative to geopotentials: 
    158 \begin{equation*} 
    159 a_1 =\frac{e_3 }{e_1 }\left( {\frac{\partial \rho }{\partial i}} \right)\left( {\frac{\partial \rho }{\partial k}} \right)^{-1} 
    160 \qquad , \qquad 
    161 a_2 =\frac{e_3 }{e_2 }\left( {\frac{\partial \rho }{\partial j}} 
    162 \right)\left( {\frac{\partial \rho }{\partial k}} \right)^{-1} 
    163 \end{equation*} 
     178\[ 
     179  a_1 =\frac{e_3 }{e_1 }\left( {\frac{\partial \rho }{\partial i}} \right)\left( {\frac{\partial \rho }{\partial k}} \right)^{-1} 
     180  \qquad , \qquad 
     181  a_2 =\frac{e_3 }{e_2 }\left( {\frac{\partial \rho }{\partial j}} 
     182  \right)\left( {\frac{\partial \rho }{\partial k}} \right)^{-1} 
     183\] 
    164184 
    165185In practice, isopycnal slopes are generally less than $10^{-2}$ in the ocean, 
    166186so $\textbf {A}_{\textbf I}$ can be simplified appreciably \citep{Cox1987}: 
    167 \begin{subequations} \label{apdx:B4} 
    168 \begin{equation} \label{apdx:B4a} 
    169 {\textbf{A}_{\textbf{I}}} \approx A^{lT}\;\Re\;\text{where} \;\Re = 
    170 \left[ {{\begin{array}{*{20}c} 
    171  1 \hfill & 0 \hfill & {-a_1 } \hfill \\ 
    172  0 \hfill & 1 \hfill & {-a_2 } \hfill \\ 
    173  {-a_1 } \hfill & {-a_2 } \hfill & {\varepsilon +a_1 ^2+a_2 ^2} \hfill \\ 
    174 \end{array} }} \right], 
    175 \end{equation} 
    176 and the iso/dianeutral diffusive operator in $z$-coordinates is then 
    177 \begin{equation}\label{apdx:B4b} 
    178  D^T = \left. \nabla \right|_z \cdot 
    179            \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_z T  \right]. \\ 
    180 \end{equation} 
     187\begin{subequations} 
     188  \label{apdx:B4} 
     189  \begin{equation} 
     190    \label{apdx:B4a} 
     191    {\textbf{A}_{\textbf{I}}} \approx A^{lT}\;\Re\;\text{where} \;\Re = 
     192    \left[ {{ 
     193          \begin{array}{*{20}c} 
     194            1 \hfill & 0 \hfill & {-a_1 } \hfill \\ 
     195            0 \hfill & 1 \hfill & {-a_2 } \hfill \\ 
     196            {-a_1 } \hfill & {-a_2 } \hfill & {\varepsilon +a_1 ^2+a_2 ^2} \hfill \\ 
     197          \end{array} 
     198        }} \right], 
     199  \end{equation} 
     200  and the iso/dianeutral diffusive operator in $z$-coordinates is then 
     201  \begin{equation} 
     202    \label{apdx:B4b} 
     203    D^T = \left. \nabla \right|_z \cdot 
     204    \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_z T  \right]. \\ 
     205  \end{equation} 
    181206\end{subequations} 
    182  
    183207 
    184208Physically, the full tensor \autoref{apdx:B3} represents strong isoneutral diffusion on a plane parallel to 
     
    192216Written out explicitly, 
    193217 
    194 \begin{multline} \label{apdx:B_ldfiso} 
    195  D^T=\frac{1}{e_1 e_2 }\left\{ 
    196  {\;\frac{\partial }{\partial i}\left[ {A_h \left( {\frac{e_2}{e_1}\frac{\partial T}{\partial i}-a_1 \frac{e_2}{e_3}\frac{\partial T}{\partial k}} \right)} \right]} 
    197  {+\frac{\partial}{\partial j}\left[ {A_h \left( {\frac{e_1}{e_2}\frac{\partial T}{\partial j}-a_2 \frac{e_1}{e_3}\frac{\partial T}{\partial k}} \right)} \right]\;} \right\} \\ 
    198 \shoveright{+\frac{1}{e_3 }\frac{\partial }{\partial k}\left[ {A_h \left( {-\frac{a_1 }{e_1 }\frac{\partial T}{\partial i}-\frac{a_2 }{e_2 }\frac{\partial T}{\partial j}+\frac{\left( {a_1 ^2+a_2 ^2+\varepsilon} \right)}{e_3 }\frac{\partial T}{\partial k}} \right)} \right]}. \\ 
     218\begin{multline} 
     219  \label{apdx:B_ldfiso} 
     220  D^T=\frac{1}{e_1 e_2 }\left\{ 
     221    {\;\frac{\partial }{\partial i}\left[ {A_h \left( {\frac{e_2}{e_1}\frac{\partial T}{\partial i}-a_1 \frac{e_2}{e_3}\frac{\partial T}{\partial k}} \right)} \right]} 
     222    {+\frac{\partial}{\partial j}\left[ {A_h \left( {\frac{e_1}{e_2}\frac{\partial T}{\partial j}-a_2 \frac{e_1}{e_3}\frac{\partial T}{\partial k}} \right)} \right]\;} \right\} \\ 
     223  \shoveright{+\frac{1}{e_3 }\frac{\partial }{\partial k}\left[ {A_h \left( {-\frac{a_1 }{e_1 }\frac{\partial T}{\partial i}-\frac{a_2 }{e_2 }\frac{\partial T}{\partial j}+\frac{\left( {a_1 ^2+a_2 ^2+\varepsilon} \right)}{e_3 }\frac{\partial T}{\partial k}} \right)} \right]}. \\ 
    199224\end{multline} 
    200  
    201225 
    202226The isopycnal diffusion operator \autoref{apdx:B4}, 
     
    204228The demonstration of the first property is trivial as \autoref{apdx:B4} is the divergence of fluxes. 
    205229Let us demonstrate the second one: 
    206 \begin{equation*} 
    207 \iiint\limits_D T\;\nabla .\left( {\textbf{A}}_{\textbf{I}} \nabla T \right)\,dv 
    208           = -\iiint\limits_D \nabla T\;.\left( {\textbf{A}}_{\textbf{I}} \nabla T \right)\,dv, 
    209 \end{equation*} 
     230\[ 
     231  \iiint\limits_D T\;\nabla .\left( {\textbf{A}}_{\textbf{I}} \nabla T \right)\,dv 
     232  = -\iiint\limits_D \nabla T\;.\left( {\textbf{A}}_{\textbf{I}} \nabla T \right)\,dv, 
     233\] 
    210234and since 
    211 \begin{subequations} 
    212 \begin{align*} {\begin{array}{*{20}l} 
    213 \nabla T\;.\left( {{\rm {\bf A}}_{\rm {\bf I}} \nabla T} 
    214 \right)&=A^{lT}\left[ {\left( {\frac{\partial T}{\partial i}} \right)^2-2a_1 
    215 \frac{\partial T}{\partial i}\frac{\partial T}{\partial k}+\left( 
    216 {\frac{\partial T}{\partial j}} \right)^2} \right. \\ 
    217 &\qquad \qquad \qquad 
    218 { \left. -\,{2a_2 \frac{\partial T}{\partial j}\frac{\partial T}{\partial k}+\left( {a_1 ^2+a_2 ^2+\varepsilon} \right)\left( {\frac{\partial T}{\partial k}} \right)^2} \right]} \\ 
    219 &=A_h \left[ {\left( {\frac{\partial T}{\partial i}-a_1 \frac{\partial 
    220           T}{\partial k}} \right)^2+\left( {\frac{\partial T}{\partial 
    221           j}-a_2 \frac{\partial T}{\partial k}} \right)^2} 
    222   +\varepsilon \left(\frac{\partial T}{\partial k}\right) ^2\right]      \\ 
    223 & \geq 0 
    224 \end{array} } 
     235\begin{align*} 
     236  { 
     237  \begin{array}{*{20}l} 
     238    \nabla T\;.\left( {{\rm {\bf A}}_{\rm {\bf I}} \nabla T} 
     239    \right)&=A^{lT}\left[ {\left( {\frac{\partial T}{\partial i}} \right)^2-2a_1 
     240             \frac{\partial T}{\partial i}\frac{\partial T}{\partial k}+\left( 
     241             {\frac{\partial T}{\partial j}} \right)^2} \right. \\ 
     242           &\qquad \qquad \qquad 
     243             { \left. -\,{2a_2 \frac{\partial T}{\partial j}\frac{\partial T}{\partial k}+\left( {a_1 ^2+a_2 ^2+\varepsilon} \right)\left( {\frac{\partial T}{\partial k}} \right)^2} \right]} \\ 
     244           &=A_h \left[ {\left( {\frac{\partial T}{\partial i}-a_1 \frac{\partial 
     245             T}{\partial k}} \right)^2+\left( {\frac{\partial T}{\partial 
     246             j}-a_2 \frac{\partial T}{\partial k}} \right)^2} 
     247             +\varepsilon \left(\frac{\partial T}{\partial k}\right) ^2\right]      \\ 
     248           & \geq 0 
     249  \end{array} 
     250             } 
    225251\end{align*} 
    226 \end{subequations} 
    227 \addtocounter{equation}{-1} 
     252%\addtocounter{equation}{-1} 
    228253the property becomes obvious. 
    229254 
     
    236261The resulting operator then takes the simple form 
    237262 
    238 \begin{equation} \label{apdx:B_ldfiso_s} 
    239 D^T = \left. \nabla \right|_s \cdot 
    240            \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_s T  \right] \\ 
    241 \;\;\text{where} \;\Re =\left( {{\begin{array}{*{20}c} 
    242  1 \hfill & 0 \hfill & {-r _1 } \hfill \\ 
    243  0 \hfill & 1 \hfill & {-r _2 } \hfill \\ 
    244  {-r _1 } \hfill & {-r _2 } \hfill & {\varepsilon +r _1 
    245 ^2+r _2 ^2} \hfill \\ 
    246 \end{array} }} \right), 
     263\begin{equation} 
     264  \label{apdx:B_ldfiso_s} 
     265  D^T = \left. \nabla \right|_s \cdot 
     266  \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_s T  \right] \\ 
     267  \;\;\text{where} \;\Re =\left( {{ 
     268        \begin{array}{*{20}c} 
     269          1 \hfill & 0 \hfill & {-r _1 } \hfill \\ 
     270          0 \hfill & 1 \hfill & {-r _2 } \hfill \\ 
     271          {-r _1 } \hfill & {-r _2 } \hfill & {\varepsilon +r _1 
     272                                              ^2+r _2 ^2} \hfill \\ 
     273        \end{array} 
     274      }} \right), 
    247275\end{equation} 
    248276 
    249277where ($r_1$, $r_2$) are the isopycnal slopes in ($\textbf{i}$, $\textbf{j}$) directions, 
    250278relative to $s$-coordinate surfaces: 
    251 \begin{equation*} 
    252 r_1 =\frac{e_3 }{e_1 }\left( {\frac{\partial \rho }{\partial i}} \right)\left( {\frac{\partial \rho }{\partial s}} \right)^{-1} 
    253 \qquad , \qquad 
    254 r_2 =\frac{e_3 }{e_2 }\left( {\frac{\partial \rho }{\partial j}} 
    255 \right)\left( {\frac{\partial \rho }{\partial s}} \right)^{-1}. 
    256 \end{equation*} 
     279\[ 
     280  r_1 =\frac{e_3 }{e_1 }\left( {\frac{\partial \rho }{\partial i}} \right)\left( {\frac{\partial \rho }{\partial s}} \right)^{-1} 
     281  \qquad , \qquad 
     282  r_2 =\frac{e_3 }{e_2 }\left( {\frac{\partial \rho }{\partial j}} 
     283  \right)\left( {\frac{\partial \rho }{\partial s}} \right)^{-1}. 
     284\] 
    257285 
    258286To prove \autoref{apdx:B5} by direct re-expression of \autoref{apdx:B_ldfiso} is straightforward, but laborious. 
     
    260288the weak-slope operator may be \emph{exactly} reexpressed in non-orthogonal $i,j,\rho$-coordinates as 
    261289 
    262 \begin{equation} \label{apdx:B5} 
    263 D^T = \left. \nabla \right|_\rho \cdot 
    264            \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_\rho T  \right] \\ 
    265 \;\;\text{where} \;\Re =\left( {{\begin{array}{*{20}c} 
    266  1 \hfill & 0 \hfill &0 \hfill \\ 
    267  0 \hfill & 1 \hfill & 0 \hfill \\ 
    268 0 \hfill & 0 \hfill & \varepsilon \hfill \\ 
    269 \end{array} }} \right). 
     290\begin{equation} 
     291  \label{apdx:B5} 
     292  D^T = \left. \nabla \right|_\rho \cdot 
     293  \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_\rho T  \right] \\ 
     294  \;\;\text{where} \;\Re =\left( {{ 
     295        \begin{array}{*{20}c} 
     296          1 \hfill & 0 \hfill &0 \hfill \\ 
     297          0 \hfill & 1 \hfill & 0 \hfill \\ 
     298          0 \hfill & 0 \hfill & \varepsilon \hfill \\ 
     299        \end{array} 
     300      }} \right). 
    270301\end{equation} 
    271302Then direct transformation from $i,j,\rho$-coordinates to $i,j,s$-coordinates gives 
     
    289320to the horizontal velocity vector: 
    290321\begin{align*} 
    291 \Delta {\textbf{U}}_h 
    292 &=\nabla \left( {\nabla \cdot {\textbf{U}}_h } \right)- 
    293 \nabla \times \left( {\nabla \times {\textbf{U}}_h } \right)    \\ 
    294 \\ 
    295 &=\left( {{\begin{array}{*{20}c} 
    296  {\frac{1}{e_1 }\frac{\partial \chi }{\partial i}} \hfill \\ 
    297  {\frac{1}{e_2 }\frac{\partial \chi }{\partial j}} \hfill \\ 
    298  {\frac{1}{e_3 }\frac{\partial \chi }{\partial k}} \hfill \\ 
    299 \end{array} }} \right)-\left( {{\begin{array}{*{20}c} 
    300  {\frac{1}{e_2 }\frac{\partial \zeta }{\partial j}-\frac{1}{e_3 
    301 }\frac{\partial }{\partial k}\left( {\frac{1}{e_3 }\frac{\partial 
    302 u}{\partial k}} \right)} \hfill \\ 
    303  {\frac{1}{e_3 }\frac{\partial }{\partial k}\left( {-\frac{1}{e_3 
    304 }\frac{\partial v}{\partial k}} \right)-\frac{1}{e_1 }\frac{\partial \zeta 
    305 }{\partial i}} \hfill \\ 
    306  {\frac{1}{e_1 e_2 }\left[ {\frac{\partial }{\partial i}\left( {\frac{e_2 
    307 }{e_3 }\frac{\partial u}{\partial k}} \right)-\frac{\partial }{\partial 
    308 j}\left( {-\frac{e_1 }{e_3 }\frac{\partial v}{\partial k}} \right)} \right]} 
    309 \hfill \\ 
    310 \end{array} }} \right) 
    311 \\ 
    312 \\ 
    313 &=\left( {{\begin{array}{*{20}c} 
    314 {\frac{1}{e_1 }\frac{\partial \chi }{\partial i}-\frac{1}{e_2 }\frac{\partial \zeta }{\partial j}} \\ 
    315 {\frac{1}{e_2 }\frac{\partial \chi }{\partial j}+\frac{1}{e_1 }\frac{\partial \zeta }{\partial i}} \\ 
    316 0 \\ 
    317 \end{array} }} \right) 
    318 +\frac{1}{e_3 } 
    319 \left( {{\begin{array}{*{20}c} 
    320 {\frac{\partial }{\partial k}\left( {\frac{1}{e_3 }\frac{\partial u}{\partial k}} \right)} \\ 
    321 {\frac{\partial }{\partial k}\left( {\frac{1}{e_3 }\frac{\partial v}{\partial k}} \right)} \\ 
    322 {\frac{\partial \chi }{\partial k}-\frac{1}{e_1 e_2 }\left( {\frac{\partial ^2\left( {e_2 \,u} \right)}{\partial i\partial k}+\frac{\partial ^2\left( {e_1 \,v} \right)}{\partial j\partial k}} \right)} \\ 
    323 \end{array} }} \right) 
     322  \Delta {\textbf{U}}_h 
     323  &=\nabla \left( {\nabla \cdot {\textbf{U}}_h } \right)- 
     324    \nabla \times \left( {\nabla \times {\textbf{U}}_h } \right) \\ \\ 
     325  &=\left( {{ 
     326    \begin{array}{*{20}c} 
     327      {\frac{1}{e_1 }\frac{\partial \chi }{\partial i}} \hfill \\ 
     328      {\frac{1}{e_2 }\frac{\partial \chi }{\partial j}} \hfill \\ 
     329      {\frac{1}{e_3 }\frac{\partial \chi }{\partial k}} \hfill \\ 
     330    \end{array} 
     331  }} \right) 
     332  -\left( {{ 
     333  \begin{array}{*{20}c} 
     334    {\frac{1}{e_2 }\frac{\partial \zeta }{\partial j}-\frac{1}{e_3 
     335    }\frac{\partial }{\partial k}\left( {\frac{1}{e_3 }\frac{\partial 
     336    u}{\partial k}} \right)} \hfill \\ 
     337    {\frac{1}{e_3 }\frac{\partial }{\partial k}\left( {-\frac{1}{e_3 
     338    }\frac{\partial v}{\partial k}} \right)-\frac{1}{e_1 }\frac{\partial \zeta 
     339    }{\partial i}} \hfill \\ 
     340    {\frac{1}{e_1 e_2 }\left[ {\frac{\partial }{\partial i}\left( {\frac{e_2 
     341    }{e_3 }\frac{\partial u}{\partial k}} \right)-\frac{\partial }{\partial 
     342    j}\left( {-\frac{e_1 }{e_3 }\frac{\partial v}{\partial k}} \right)} \right]} 
     343    \hfill \\ 
     344  \end{array} 
     345  }} \right) \\ \\ 
     346  &=\left( {{ 
     347    \begin{array}{*{20}c} 
     348      {\frac{1}{e_1 }\frac{\partial \chi }{\partial i}-\frac{1}{e_2 }\frac{\partial \zeta }{\partial j}} \\ 
     349      {\frac{1}{e_2 }\frac{\partial \chi }{\partial j}+\frac{1}{e_1 }\frac{\partial \zeta }{\partial i}} \\ 
     350      0 \\ 
     351    \end{array} 
     352  }} \right) 
     353  +\frac{1}{e_3 } 
     354  \left( {{ 
     355  \begin{array}{*{20}c} 
     356    {\frac{\partial }{\partial k}\left( {\frac{1}{e_3 }\frac{\partial u}{\partial k}} \right)} \\ 
     357    {\frac{\partial }{\partial k}\left( {\frac{1}{e_3 }\frac{\partial v}{\partial k}} \right)} \\ 
     358    {\frac{\partial \chi }{\partial k}-\frac{1}{e_1 e_2 }\left( {\frac{\partial ^2\left( {e_2 \,u} \right)}{\partial i\partial k}+\frac{\partial ^2\left( {e_1 \,v} \right)}{\partial j\partial k}} \right)} \\ 
     359  \end{array} 
     360  }} \right) 
    324361\end{align*} 
    325362Using \autoref{eq:PE_div}, the definition of the horizontal divergence, 
    326363the third componant of the second vector is obviously zero and thus : 
    327 \begin{equation*} 
    328 \Delta {\textbf{U}}_h = \nabla _h \left( \chi \right) - \nabla _h \times \left( \zeta \right) + \frac {1}{e_3 } \frac {\partial }{\partial k} \left( {\frac {1}{e_3 } \frac{\partial {\textbf{ U}}_h }{\partial k}} \right) 
    329 \end{equation*} 
     364\[ 
     365  \Delta {\textbf{U}}_h = \nabla _h \left( \chi \right) - \nabla _h \times \left( \zeta \right) + \frac {1}{e_3 } \frac {\partial }{\partial k} \left( {\frac {1}{e_3 } \frac{\partial {\textbf{ U}}_h }{\partial k}} \right) 
     366\] 
    330367 
    331368Note that this operator ensures a full separation between 
     
    335372The horizontal/vertical second order (Laplacian type) operator used to diffuse horizontal momentum in 
    336373the $z$-coordinate therefore takes the following form: 
    337 \begin{equation} \label{apdx:B_Lap_U} 
    338  {\textbf{D}}^{\textbf{U}} = 
    339      \nabla _h \left( {A^{lm}\;\chi } \right) 
    340    - \nabla _h \times \left( {A^{lm}\;\zeta \;{\textbf{k}}} \right) 
    341    + \frac{1}{e_3 }\frac{\partial }{\partial k}\left( {\frac{A^{vm}\;}{e_3 } 
    342             \frac{\partial {\rm {\bf U}}_h }{\partial k}} \right) \\ 
     374\begin{equation} 
     375  \label{apdx:B_Lap_U} 
     376  { 
     377    \textbf{D}}^{\textbf{U}} = 
     378  \nabla _h \left( {A^{lm}\;\chi } \right) 
     379  - \nabla _h \times \left( {A^{lm}\;\zeta \;{\textbf{k}}} \right) 
     380  + \frac{1}{e_3 }\frac{\partial }{\partial k}\left( {\frac{A^{vm}\;}{e_3 } 
     381      \frac{\partial {\rm {\bf U}}_h }{\partial k}} \right) \\ 
    343382\end{equation} 
    344383that is, in expanded form: 
    345384\begin{align*} 
    346 D^{\textbf{U}}_u 
    347 & = \frac{1}{e_1} \frac{\partial \left( {A^{lm}\chi   } \right)}{\partial i} 
    348      -\frac{1}{e_2} \frac{\partial \left( {A^{lm}\zeta } \right)}{\partial j} 
    349      +\frac{1}{e_3} \frac{\partial u}{\partial k}      \\ 
    350 D^{\textbf{U}}_v 
    351 & = \frac{1}{e_2 }\frac{\partial \left( {A^{lm}\chi   } \right)}{\partial j} 
    352      +\frac{1}{e_1 }\frac{\partial \left( {A^{lm}\zeta } \right)}{\partial i} 
    353      +\frac{1}{e_3} \frac{\partial v}{\partial k} 
     385  D^{\textbf{U}}_u 
     386  & = \frac{1}{e_1} \frac{\partial \left( {A^{lm}\chi   } \right)}{\partial i} 
     387    -\frac{1}{e_2} \frac{\partial \left( {A^{lm}\zeta } \right)}{\partial j} 
     388    +\frac{1}{e_3} \frac{\partial u}{\partial k}      \\ 
     389  D^{\textbf{U}}_v 
     390  & = \frac{1}{e_2 }\frac{\partial \left( {A^{lm}\chi   } \right)}{\partial j} 
     391    +\frac{1}{e_1 }\frac{\partial \left( {A^{lm}\zeta } \right)}{\partial i} 
     392    +\frac{1}{e_3} \frac{\partial v}{\partial k} 
    354393\end{align*} 
    355394 
     
    360399Generally, \autoref{apdx:B_Lap_U} is used in both $z$- and $s$-coordinate systems, 
    361400that is a Laplacian diffusion is applied on momentum along the coordinate directions. 
     401 
     402\biblio 
     403 
    362404\end{document} 
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex/NEMO/subfiles/annex_C.tex

    r10368 r10419  
    1 \documentclass[../tex_main/NEMO_manual]{subfiles} 
     1\documentclass[../main/NEMO_manual]{subfiles} 
     2 
    23\begin{document} 
    34% ================================================================ 
     
    67\chapter{Discrete Invariants of the Equations} 
    78\label{apdx:C} 
     9 
    810\minitoc 
    911 
     
    1416 
    1517\newpage 
    16 $\ $\newline    % force a new ligne 
    1718 
    1819% ================================================================ 
     
    2526 
    2627fluxes at the faces of a $T$-box: 
    27 \begin{equation*} 
    28 U = e_{2u}\,e_{3u}\; u  \qquad  V = e_{1v}\,e_{3v}\; v  \qquad W = e_{1w}\,e_{2w}\; \omega     \\ 
    29 \end{equation*} 
     28\[ 
     29  U = e_{2u}\,e_{3u}\; u  \qquad  V = e_{1v}\,e_{3v}\; v  \qquad W = e_{1w}\,e_{2w}\; \omega 
     30\] 
    3031 
    3132volume of cells at $u$-, $v$-, and $T$-points: 
    32 \begin{equation*} 
    33 b_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}     \\ 
    34 \end{equation*} 
     33\[ 
     34  b_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} 
     35\] 
    3536 
    3637partial derivative notation: $\partial_\bullet = \frac{\partial}{\partial \bullet}$ 
     
    4243($i.e.$ $s(k_s) = \eta$ and $s(k_b)=-H$, where $H$ is the bottom depth). 
    4344\begin{flalign*} 
    44  z(k) = \eta - \int\limits_{\tilde{k}=k}^{\tilde{k}=k_s}  e_3(\tilde{k}) \;d\tilde{k} 
    45         = \eta - \int\limits_k^{k_s}  e_3 \;d\tilde{k}  
     45  z(k) = \eta - \int\limits_{\tilde{k}=k}^{\tilde{k}=k_s}  e_3(\tilde{k}) \;d\tilde{k} 
     46  = \eta - \int\limits_k^{k_s}  e_3 \;d\tilde{k} 
    4647\end{flalign*} 
    4748 
    4849Continuity equation with the above notation: 
    49 \begin{equation*} 
    50 \frac{1}{e_{3t}} \partial_t (e_{3t})+ \frac{1}{b_t}  \biggl\{  \delta_i [U] + \delta_j [V] + \delta_k [W] \biggr\} = 0 
    51 \end{equation*} 
     50\[ 
     51  \frac{1}{e_{3t}} \partial_t (e_{3t})+ \frac{1}{b_t}  \biggl\{  \delta_i [U] + \delta_j [V] + \delta_k [W] \biggr\} = 0 
     52\] 
    5253 
    5354A quantity, $Q$ is conserved when its domain averaged time change is zero, that is when: 
    54 \begin{equation*} 
    55 \partial_t \left( \int_D{ Q\;dv } \right) =0 
    56 \end{equation*} 
     55\[ 
     56  \partial_t \left( \int_D{ Q\;dv } \right) =0 
     57\] 
    5758Noting that the coordinate system used ....  blah blah 
    58 \begin{equation*} 
    59 \partial_t \left( \int_D {Q\;dv} \right) =  \int_D { \partial_t \left( e_3 \, Q \right) e_1e_2\;di\,dj\,dk } 
    60                                                        =  \int_D { \frac{1}{e_3} \partial_t \left( e_3 \, Q \right) dv } =0 
    61 \end{equation*} 
     59\[ 
     60  \partial_t \left( \int_D {Q\;dv} \right) =  \int_D { \partial_t \left( e_3 \, Q \right) e_1e_2\;di\,dj\,dk } 
     61  =  \int_D { \frac{1}{e_3} \partial_t \left( e_3 \, Q \right) dv } =0 
     62\] 
    6263equation of evolution of $Q$ written as 
    6364the time evolution of the vertical content of $Q$ like for tracers, or momentum in flux form, 
    6465the quadratic quantity $\frac{1}{2}Q^2$ is conserved when: 
    6566\begin{flalign*} 
    66 \partial_t \left(   \int_D{ \frac{1}{2} \,Q^2\;dv }   \right) 
    67 =&  \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 } \\ 
    68 =&  \int_D {         Q   \;\partial_t\left( e_3 \, Q \right) e_1e_2\;di\,dj\,dk }   
    69 -  \int_D { \frac{1}{2} Q^2 \,\partial_t  (e_3) \;e_1e_2\;di\,dj\,dk } \\ 
     67  \partial_t \left(   \int_D{ \frac{1}{2} \,Q^2\;dv }   \right) 
     68  =&  \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 } \\ 
     69  =&  \int_D {         Q   \;\partial_t\left( e_3 \, Q \right) e_1e_2\;di\,dj\,dk } 
     70  -  \int_D { \frac{1}{2} Q^2 \,\partial_t  (e_3) \;e_1e_2\;di\,dj\,dk } \\ 
    7071\end{flalign*} 
    7172that is in a more compact form : 
    72 \begin{flalign} \label{eq:Q2_flux} 
    73 \partial_t \left( \int_D {\frac{1}{2} Q^2\;dv} \right) 
    74 =&                   \int_D { \frac{Q}{e_3}  \partial_t \left( e_3 \, Q \right) dv }   
     73\begin{flalign} 
     74  \label{eq:Q2_flux} 
     75  \partial_t \left( \int_D {\frac{1}{2} Q^2\;dv} \right) 
     76  =&                   \int_D { \frac{Q}{e_3}  \partial_t \left( e_3 \, Q \right) dv } 
    7577  -   \frac{1}{2} \int_D {  \frac{Q^2}{e_3} \partial_t (e_3) \;dv } 
    7678\end{flalign} 
     
    7880the quadratic quantity $\frac{1}{2}Q^2$ is conserved when: 
    7981\begin{flalign*} 
    80 \partial_t \left( \int_D {\frac{1}{2} Q^2\;dv} \right) 
    81 =&  \int_D { \frac{1}{2} \partial_t \left( e_3 \, Q^2 \right) \;e_1e_2\;di\,dj\,dk } \\ 
    82 =& \int_D {         Q      \partial_t Q  \;e_1e_2e_3\;di\,dj\,dk }   
    83 +  \int_D { \frac{1}{2} Q^2 \, \partial_t e_3  \;e_1e_2\;di\,dj\,dk } \\ 
     82  \partial_t \left( \int_D {\frac{1}{2} Q^2\;dv} \right) 
     83  =&  \int_D { \frac{1}{2} \partial_t \left( e_3 \, Q^2 \right) \;e_1e_2\;di\,dj\,dk } \\ 
     84  =& \int_D {         Q      \partial_t Q  \;e_1e_2e_3\;di\,dj\,dk } 
     85  +  \int_D { \frac{1}{2} Q^2 \, \partial_t e_3  \;e_1e_2\;di\,dj\,dk } \\ 
    8486\end{flalign*} 
    8587that is in a more compact form: 
    86 \begin{flalign} \label{eq:Q2_vect} 
    87 \partial_t \left( \int_D {\frac{1}{2} Q^2\;dv} \right) 
    88 =& \int_D {         Q   \,\partial_t Q  \;dv }   
    89 +   \frac{1}{2} \int_D { \frac{1}{e_3} Q^2 \partial_t e_3 \;dv } 
     88\begin{flalign} 
     89  \label{eq:Q2_vect} 
     90  \partial_t \left( \int_D {\frac{1}{2} Q^2\;dv} \right) 
     91  =& \int_D {         Q   \,\partial_t Q  \;dv } 
     92  +   \frac{1}{2} \int_D { \frac{1}{e_3} Q^2 \partial_t e_3 \;dv } 
    9093\end{flalign} 
    91  
    9294 
    9395% ================================================================ 
     
    9799\label{sec:C.1} 
    98100 
    99  
    100101The discretization of pimitive equation in $s$-coordinate ($i.e.$ time and space varying vertical coordinate) 
    101102must be chosen so that the discrete equation of the model satisfy integral constrains on energy and enstrophy.  
    102103 
    103  
    104104Let us first establish those constraint in the continuous world. 
    105105The total energy ($i.e.$ kinetic plus potential energies) is conserved: 
    106 \begin{flalign} \label{eq:Tot_Energy} 
     106\begin{flalign} 
     107  \label{eq:Tot_Energy} 
    107108  \partial_t \left( \int_D \left( \frac{1}{2} {\textbf{U}_h}^2 +  \rho \, g \, z \right) \;dv \right)  = & 0 
    108109\end{flalign} 
     
    118119\autoref{eq:Tot_Energy} for the latter form leads to: 
    119120 
    120 \begin{subequations} \label{eq:E_tot} 
    121  
     121% \label{eq:E_tot} 
    122122advection term (vector invariant form): 
    123 \begin{equation} \label{eq:E_tot_vect_vor_1} 
    124 \int\limits_D  \zeta \; \left( \textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv   = 0   \\ 
    125 \end{equation} 
     123\[ 
     124  % \label{eq:E_tot_vect_vor_1} 
     125  \int\limits_D  \zeta \; \left( \textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv   = 0   \\ 
     126\] 
    126127% 
    127 \begin{equation} \label{eq:E_tot_vect_adv_1} 
    128    \int\limits_D  \textbf{U}_h \cdot \nabla_h \left( \frac{{\textbf{U}_h}^2}{2} \right)     dv  
    129 + \int\limits_D  \textbf{U}_h \cdot \nabla_z \textbf{U}_h  \;dv     
    130 -  \int\limits_D { \frac{{\textbf{U}_h}^2}{2} \frac{1}{e_3} \partial_t e_3 \;dv }   = 0   \\ 
    131 \end{equation} 
    132  
     128\[ 
     129  % \label{eq:E_tot_vect_adv_1} 
     130  \int\limits_D  \textbf{U}_h \cdot \nabla_h \left( \frac{{\textbf{U}_h}^2}{2} \right)     dv 
     131  + \int\limits_D  \textbf{U}_h \cdot \nabla_z \textbf{U}_h  \;dv 
     132  -  \int\limits_D { \frac{{\textbf{U}_h}^2}{2} \frac{1}{e_3} \partial_t e_3 \;dv }   = 0 
     133\] 
    133134advection term (flux form): 
    134 \begin{equation} \label{eq:E_tot_flux_metric} 
    135 \int\limits_D  \frac{1} {e_1 e_2 } \left( v \,\partial_i e_2 - u \,\partial_j e_1  \right)\;  
    136  \left(  \textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv   = 0   \\ 
    137 \end{equation} 
    138  
    139 \begin{equation} \label{eq:E_tot_flux_adv} 
    140    \int\limits_D \textbf{U}_h \cdot     \left(                 {{\begin{array} {*{20}c} 
    141 \nabla \cdot \left( \textbf{U}\,u \right) \hfill \\ 
    142 \nabla \cdot \left( \textbf{U}\,v \right) \hfill \\       \end{array}} }           \right)   \;dv  
    143 +   \frac{1}{2} \int\limits_D {  {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t e_3 \;dv } =\;0  \\ 
    144 \end{equation} 
    145  
     135\[ 
     136  % \label{eq:E_tot_flux_metric} 
     137  \int\limits_D  \frac{1} {e_1 e_2 } \left( v \,\partial_i e_2 - u \,\partial_j e_1  \right)\; 
     138  \left(  \textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv   = 0 
     139\] 
     140\[ 
     141  % \label{eq:E_tot_flux_adv} 
     142  \int\limits_D \textbf{U}_h \cdot     \left(                 {{ 
     143        \begin{array} {*{20}c} 
     144          \nabla \cdot \left( \textbf{U}\,u \right) \hfill \\ 
     145          \nabla \cdot \left( \textbf{U}\,v \right) \hfill 
     146        \end{array}} 
     147    }           \right)   \;dv 
     148  +   \frac{1}{2} \int\limits_D {  {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t e_3 \;dv } =\;0 
     149\] 
    146150coriolis term 
    147 \begin{equation} \label{eq:E_tot_cor} 
    148 \int\limits_D  f   \; \left( \textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv   = 0   \\ 
    149 \end{equation} 
    150  
     151\[ 
     152  % \label{eq:E_tot_cor} 
     153  \int\limits_D  f   \; \left( \textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv   = 0 
     154\] 
    151155pressure gradient: 
    152 \begin{equation} \label{eq:E_tot_pg_1} 
    153    - \int\limits_D  \left. \nabla p \right|_z \cdot \textbf{U}_h \;dv  
    154 = - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
    155    + \int\limits_D g\, \rho \; \partial_t z  \;dv   \\ 
    156 \end{equation} 
     156\[ 
     157  % \label{eq:E_tot_pg_1} 
     158  - \int\limits_D  \left. \nabla p \right|_z \cdot \textbf{U}_h \;dv 
     159  = - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
     160  + \int\limits_D g\, \rho \; \partial_t z  \;dv 
     161\] 
     162 
     163where $\nabla_h = \left. \nabla \right|_k$ is the gradient along the $s$-surfaces. 
     164 
     165blah blah.... 
     166 
     167The prognostic ocean dynamics equation can be summarized as follows: 
     168\[ 
     169  \text{NXT} = \dbinom  {\text{VOR} + \text{KEG} + \text {ZAD} } 
     170  {\text{COR} + \text{ADV}                       } 
     171  + \text{HPG} + \text{SPG} + \text{LDF} + \text{ZDF} 
     172\] 
     173 
     174Vector invariant form: 
     175% \label{eq:E_tot_vect} 
     176\[ 
     177  % \label{eq:E_tot_vect_vor_2} 
     178  \int\limits_D   \textbf{U}_h \cdot \text{VOR} \;dv   = 0 
     179\] 
     180\[ 
     181  % \label{eq:E_tot_vect_adv_2} 
     182  \int\limits_D  \textbf{U}_h \cdot \text{KEG}  \;dv 
     183  + \int\limits_D  \textbf{U}_h \cdot \text{ZAD}  \;dv 
     184  -  \int\limits_D { \frac{{\textbf{U}_h}^2}{2} \frac{1}{e_3} \partial_t e_3 \;dv }   = 0 
     185\] 
     186\[ 
     187  % \label{eq:E_tot_pg_2} 
     188  - \int\limits_D  \textbf{U}_h \cdot (\text{HPG}+ \text{SPG}) \;dv 
     189  = - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
     190  + \int\limits_D g\, \rho \; \partial_t z  \;dv 
     191\] 
     192 
     193Flux form: 
     194\begin{subequations} 
     195  \label{eq:E_tot_flux} 
     196  \[ 
     197    % \label{eq:E_tot_flux_metric_2} 
     198    \int\limits_D  \textbf{U}_h \cdot \text {COR} \;  dv   = 0 
     199  \] 
     200  \[ 
     201    % \label{eq:E_tot_flux_adv_2} 
     202    \int\limits_D \textbf{U}_h \cdot \text{ADV}   \;dv 
     203    +   \frac{1}{2} \int\limits_D {  {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t e_3  \;dv } =\;0 
     204  \] 
     205  \begin{equation} 
     206    \label{eq:E_tot_pg_3} 
     207    - \int\limits_D  \textbf{U}_h \cdot (\text{HPG}+ \text{SPG}) \;dv 
     208    = - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
     209    + \int\limits_D g\, \rho \; \partial_t  z  \;dv 
     210  \end{equation} 
    157211\end{subequations} 
    158  
    159 where $\nabla_h = \left. \nabla \right|_k$ is the gradient along the $s$-surfaces. 
    160  
    161 blah blah.... 
    162 $\ $\newline    % force a new ligne 
    163 The prognostic ocean dynamics equation can be summarized as follows: 
    164 \begin{equation*} 
    165 \text{NXT} = \dbinom {\text{VOR} + \text{KEG} + \text {ZAD} } 
    166                   {\text{COR} + \text{ADV}                       } 
    167          + \text{HPG} + \text{SPG} + \text{LDF} + \text{ZDF} 
    168 \end{equation*} 
    169 $\ $\newline    % force a new ligne 
    170  
    171 Vector invariant form: 
    172 \begin{subequations} \label{eq:E_tot_vect} 
    173 \begin{equation} \label{eq:E_tot_vect_vor_2} 
    174 \int\limits_D   \textbf{U}_h \cdot \text{VOR} \;dv   = 0   \\ 
    175 \end{equation} 
    176 \begin{equation} \label{eq:E_tot_vect_adv_2} 
    177    \int\limits_D  \textbf{U}_h \cdot \text{KEG}  \;dv  
    178 + \int\limits_D  \textbf{U}_h \cdot \text{ZAD}  \;dv     
    179 -  \int\limits_D { \frac{{\textbf{U}_h}^2}{2} \frac{1}{e_3} \partial_t e_3 \;dv }   = 0   \\ 
    180 \end{equation} 
    181 \begin{equation} \label{eq:E_tot_pg_2} 
    182    - \int\limits_D  \textbf{U}_h \cdot (\text{HPG}+ \text{SPG}) \;dv  
    183 = - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
    184    + \int\limits_D g\, \rho \; \partial_t z  \;dv   \\ 
    185 \end{equation} 
    186 \end{subequations} 
    187  
    188 Flux form: 
    189 \begin{subequations} \label{eq:E_tot_flux} 
    190 \begin{equation} \label{eq:E_tot_flux_metric_2} 
    191 \int\limits_D  \textbf{U}_h \cdot \text {COR} \;  dv   = 0   \\ 
    192 \end{equation} 
    193 \begin{equation} \label{eq:E_tot_flux_adv_2} 
    194    \int\limits_D \textbf{U}_h \cdot \text{ADV}   \;dv  
    195 +   \frac{1}{2} \int\limits_D {  {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t e_3  \;dv } =\;0  \\ 
    196 \end{equation} 
    197 \begin{equation} \label{eq:E_tot_pg_3} 
    198    - \int\limits_D  \textbf{U}_h \cdot (\text{HPG}+ \text{SPG}) \;dv  
    199 = - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
    200    + \int\limits_D g\, \rho \; \partial_t  z  \;dv   \\ 
    201 \end{equation} 
    202 \end{subequations} 
    203  
    204  
    205 $\ $\newline    % force a new ligne 
    206  
    207212 
    208213\autoref{eq:E_tot_pg_3} is the balance between the conversion KE to PE and PE to KE.  
    209214Indeed the left hand side of \autoref{eq:E_tot_pg_3} can be transformed as follows: 
    210215\begin{flalign*} 
    211 \partial_t  \left( \int\limits_D { \rho \, g \, z  \;dv} \right)  
    212 &= + \int\limits_D \frac{1}{e_3} \partial_t (e_3\,\rho) \;g\;z\;\;dv 
    213      +  \int\limits_D g\, \rho \; \partial_t z  \;dv   &&&\\ 
    214 &= - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
    215      + \int\limits_D g\, \rho \; \partial_t z \;dv   &&&\\ 
    216 &= + \int\limits_D  \rho \,g \left( \textbf {U}_h \cdot \nabla_h z + \omega \frac{1}{e_3} \partial_k z \right)  \;dv 
    217      + \int\limits_D g\, \rho \; \partial_t z \;dv   &&&\\ 
    218 &= + \int\limits_D  \rho \,g \left( \omega + \partial_t z + \textbf {U}_h \cdot \nabla_h z  \right)  \;dv  &&&\\ 
    219 &=+  \int\limits_D g\, \rho \; w \; dv   &&&\\ 
     216  \partial_t  \left( \int\limits_D { \rho \, g \, z  \;dv} \right) 
     217  &= + \int\limits_D \frac{1}{e_3} \partial_t (e_3\,\rho) \;g\;z\;\;dv 
     218  +  \int\limits_D g\, \rho \; \partial_t z  \;dv   &&&\\ 
     219  &= - \int\limits_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
     220  + \int\limits_D g\, \rho \; \partial_t z \;dv   &&&\\ 
     221  &= + \int\limits_D  \rho \,g \left( \textbf {U}_h \cdot \nabla_h z + \omega \frac{1}{e_3} \partial_k z \right)  \;dv 
     222  + \int\limits_D g\, \rho \; \partial_t z \;dv   &&&\\ 
     223  &= + \int\limits_D  \rho \,g \left( \omega + \partial_t z + \textbf {U}_h \cdot \nabla_h z  \right)  \;dv  &&&\\ 
     224  &=+  \int\limits_D g\, \rho \; w \; dv   &&&\\ 
    220225\end{flalign*} 
    221226where the last equality is obtained by noting that the brackets is exactly the expression of $w$,  
     
    224229The left hand side of \autoref{eq:E_tot_pg_3} can be transformed as follows: 
    225230\begin{flalign*} 
    226 - \int\limits_D  \left. \nabla p \right|_z & \cdot \textbf{U}_h \;dv   
    227 = - \int\limits_D  \left( \nabla_h p + \rho \, g \nabla_h z \right) \cdot \textbf{U}_h \;dv   &&&\\ 
    228 \allowdisplaybreaks 
    229 &= - \int\limits_D  \nabla_h  p \cdot \textbf{U}_h \;dv   - \int\limits_D  \rho \, g \, \nabla_h z \cdot \textbf{U}_h \;dv   &&&\\ 
    230 \allowdisplaybreaks 
    231 &= +\int\limits_D p \,\nabla_h \cdot \textbf{U}_h \;dv   + \int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
    232 \allowdisplaybreaks 
    233 &= -\int\limits_D p \left( \frac{1}{e_3} \partial_t e_3 + \frac{1}{e_3} \partial_k \omega  \right) \;dv 
    234     +\int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
    235 \allowdisplaybreaks 
    236 &= -\int\limits_D \frac{p}{e_3} \partial_t e_3  \;dv     
    237      +\int\limits_D \frac{1}{e_3} \partial_k p\; \omega \;dv 
    238     +\int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
    239 &= -\int\limits_D \frac{p}{e_3} \partial_t e_3  \;dv     
    240      -\int\limits_D \rho \, g \, \omega \;dv 
    241     +\int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
    242 &= - \int\limits_D \frac{p}{e_3} \partial_t e_3 \; \;dv     
    243      - \int\limits_D  \rho \, g \, w \;dv  
    244      + \int\limits_D   \rho \, g \, \partial_t z \;dv   &&&\\ 
    245 \allowdisplaybreaks 
    246 \intertext{introducing the hydrostatic balance $\partial_k p=-\rho \,g\,e_3$ in the last term, 
    247 it becomes:} 
    248 &= - \int\limits_D \frac{p}{e_3} \partial_t e_3 \;dv     
    249      - \int\limits_D  \rho \, g \, w \;dv  
    250      - \int\limits_D  \frac{1}{e_3} \partial_k p\, \partial_t z \;dv   &&&\\ 
    251 &= - \int\limits_D \frac{p}{e_3} \partial_t e_3 \;dv     
    252      - \int\limits_D  \rho \, g \, w \;dv  
    253      + \int\limits_D \,\frac{p}{e_3}\partial_t ( \partial_k z )  dv   &&&\\ 
    254 %  
    255 &= - \int\limits_D  \rho \, g \, w \;dv   &&&\\ 
    256 \end{flalign*} 
    257  
     231  - \int\limits_D  \left. \nabla p \right|_z & \cdot \textbf{U}_h \;dv 
     232  = - \int\limits_D  \left( \nabla_h p + \rho \, g \nabla_h z \right) \cdot \textbf{U}_h \;dv   &&&\\ 
     233  \allowdisplaybreaks 
     234  &= - \int\limits_D  \nabla_h  p \cdot \textbf{U}_h \;dv   - \int\limits_D  \rho \, g \, \nabla_h z \cdot \textbf{U}_h \;dv   &&&\\ 
     235  \allowdisplaybreaks 
     236  &= +\int\limits_D p \,\nabla_h \cdot \textbf{U}_h \;dv   + \int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
     237  \allowdisplaybreaks 
     238  &= -\int\limits_D p \left( \frac{1}{e_3} \partial_t e_3 + \frac{1}{e_3} \partial_k \omega  \right) \;dv 
     239  +\int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
     240  \allowdisplaybreaks 
     241  &= -\int\limits_D \frac{p}{e_3} \partial_t e_3  \;dv 
     242  +\int\limits_D \frac{1}{e_3} \partial_k p\; \omega \;dv 
     243  +\int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
     244  &= -\int\limits_D \frac{p}{e_3} \partial_t e_3  \;dv 
     245  -\int\limits_D \rho \, g \, \omega \;dv 
     246  +\int\limits_D  \rho \, g \left( \omega - w + \partial_t z \right) \;dv   &&&\\ 
     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   \rho \, g \, \partial_t z \;dv   &&&\\ 
     250  \allowdisplaybreaks 
     251  \intertext{introducing the hydrostatic balance $\partial_k p=-\rho \,g\,e_3$ in the last term, 
     252    it becomes:} 
     253  &= - \int\limits_D \frac{p}{e_3} \partial_t e_3 \;dv 
     254  - \int\limits_D  \rho \, g \, w \;dv 
     255  - \int\limits_D  \frac{1}{e_3} \partial_k p\, \partial_t z \;dv   &&&\\ 
     256  &= - \int\limits_D \frac{p}{e_3} \partial_t e_3 \;dv 
     257  - \int\limits_D  \rho \, g \, w \;dv 
     258  + \int\limits_D \,\frac{p}{e_3}\partial_t ( \partial_k z )  dv   &&&\\ 
     259  % 
     260  &= - \int\limits_D  \rho \, g \, w \;dv   &&&\\ 
     261\end{flalign*} 
    258262 
    259263%gm comment 
     
    262266The last equality comes from the following equation, 
    263267\begin{flalign*} 
    264 \int\limits_D p \frac{1}{e_3} \frac{\partial e_3}{\partial t}\; \;dv     
    265      = \int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv \quad,  \\  
     268  \int\limits_D p \frac{1}{e_3} \frac{\partial e_3}{\partial t}\; \;dv 
     269  = \int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv \quad, 
    266270\end{flalign*} 
    267271that can be demonstrated as follows: 
    268272 
    269273\begin{flalign*} 
    270 \int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv    
    271 &= \int\limits_D    \rho \, g \, \frac{\partial \eta}{\partial t} \;dv    
     274  \int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv 
     275  &= \int\limits_D    \rho \, g \, \frac{\partial \eta}{\partial t} \;dv 
    272276  -  \int\limits_D    \rho \, g \, \frac{\partial}{\partial t} \left(  \int\limits_k^{k_s}  e_3 \;d\tilde{k} \right) \;dv   &&&\\ 
    273 &= \int\limits_D    \rho \, g \, \frac{\partial \eta}{\partial t} \;dv    
     277  &= \int\limits_D    \rho \, g \, \frac{\partial \eta}{\partial t} \;dv 
    274278  -  \int\limits_D    \rho \, g    \left(  \int\limits_k^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k} \right) \;dv   &&&\\ 
    275 % 
    276 \allowdisplaybreaks 
    277 \intertext{The second term of the right hand side can be transformed by applying the integration by part rule:  
    278 $\left[ a\,b \right]_{k_b}^{k_s} = \int_{k_b}^{k_s}  a\,\frac{\partial b}{\partial k}       \;dk 
    279                                                + \int_{k_b}^{k_s}      \frac{\partial a}{\partial k} \,b \;dk $ 
    280 to the following function: $a=  \int_k^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k}$  
    281 and $b=  \int_k^{k_s}  \rho \, e_3 \;d\tilde{k}$ 
    282 (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). 
    283 This leads to:  } 
    284 \end{flalign*} 
    285 \begin{flalign*} 
    286 &\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} 
    287 =-\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 
    288   -\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 
    289 &&&\\ 
    290 \allowdisplaybreaks 
    291 \intertext{Noting that $\frac{\partial \eta}{\partial t}  
    292       = \frac{\partial}{\partial t}  \left( \int_{k_b}^{k_s}   e_3  \;d\tilde{k}  \right) 
    293       = \int_{k_b}^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k}$ 
    294 and  
    295       $p(k) = \int_k^{k_s}  \rho \,g \, e_3 \;d\tilde{k} $,  
    296 but also that $\frac{\partial \eta}{\partial t}$ does not depends on $k$, it comes: 
    297 } 
    298 & - \int\limits_{k_b}^{k_s}  \rho \, \frac{\partial \eta}{\partial t} \, e_3 \;dk 
    299 = - \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 
    300    - \int\limits_{k_b}^{k_s}  \frac{\partial e_3}{\partial t} \frac{p}{g}         \;dk       &&&\\ 
     279  % 
     280  \allowdisplaybreaks 
     281  \intertext{The second term of the right hand side can be transformed by applying the integration by part rule: 
     282    $\left[ a\,b \right]_{k_b}^{k_s} = \int_{k_b}^{k_s}  a\,\frac{\partial b}{\partial k}       \;dk 
     283    + \int_{k_b}^{k_s}      \frac{\partial a}{\partial k} \,b \;dk $ 
     284    to the following function: $a=  \int_k^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k}$ 
     285    and $b=  \int_k^{k_s}  \rho \, e_3 \;d\tilde{k}$ 
     286    (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). 
     287    This leads to:  } 
     288\end{flalign*} 
     289\begin{flalign*} 
     290  &\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} 
     291  =-\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 
     292  -\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  &&&\\ 
     293  \allowdisplaybreaks 
     294  \intertext{Noting that $\frac{\partial \eta}{\partial t} 
     295    = \frac{\partial}{\partial t}  \left( \int_{k_b}^{k_s}   e_3  \;d\tilde{k}  \right) 
     296    = \int_{k_b}^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k}$ 
     297    and 
     298    $p(k) = \int_k^{k_s}  \rho \,g \, e_3 \;d\tilde{k} $, 
     299    but also that $\frac{\partial \eta}{\partial t}$ does not depends on $k$, it comes: 
     300  } 
     301  & - \int\limits_{k_b}^{k_s}  \rho \, \frac{\partial \eta}{\partial t} \, e_3 \;dk 
     302  = - \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 
     303  - \int\limits_{k_b}^{k_s}  \frac{\partial e_3}{\partial t} \frac{p}{g}         \;dk       &&&\\ 
    301304\end{flalign*} 
    302305Mutliplying by $g$ and integrating over the $(i,j)$ domain it becomes: 
    303306\begin{flalign*} 
    304 \int\limits_D  \rho \, g \, \left(  \int\limits_k^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k} \right)    \;dv 
    305 =  \int\limits_D  \rho \, g \, \frac{\partial \eta}{\partial t} dv 
     307  \int\limits_D  \rho \, g \, \left(  \int\limits_k^{k_s}  \frac{\partial e_3}{\partial t} \;d\tilde{k} \right)    \;dv 
     308  =  \int\limits_D  \rho \, g \, \frac{\partial \eta}{\partial t} dv 
    306309  - \int\limits_D  \frac{p}{e_3}\frac{\partial e_3}{\partial t}         \;dv 
    307310\end{flalign*} 
    308311Using this property, we therefore have: 
    309312\begin{flalign*} 
    310 \int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv    
    311 &= \int\limits_D    \rho \, g \, \frac{\partial \eta}{\partial t}   \;dv    
     313  \int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv 
     314  &= \int\limits_D    \rho \, g \, \frac{\partial \eta}{\partial t}   \;dv 
    312315  - \left(  \int\limits_D  \rho \, g \, \frac{\partial \eta}{\partial t} dv 
    313            - \int\limits_D  \frac{p}{e_3}\frac{\partial e_3}{\partial t}   \;dv  \right)    &&&\\ 
    314 % 
    315 &=\int\limits_D \frac{p}{e_3} \frac{\partial (e_3\,\rho)}{\partial t}\; \;dv      
     316    - \int\limits_D  \frac{p}{e_3}\frac{\partial e_3}{\partial t}   \;dv  \right)    &&&\\ 
     317  % 
     318  &=\int\limits_D \frac{p}{e_3} \frac{\partial (e_3\,\rho)}{\partial t}\; \;dv 
    316319\end{flalign*} 
    317320% end gm comment 
     
    319322% 
    320323 
    321  
    322324% ================================================================ 
    323325% Discrete Total energy Conservation : vector invariant form 
     
    334336The discrete form of the total energy conservation, \autoref{eq:Tot_Energy}, is given by: 
    335337\begin{flalign*} 
    336 \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  \\ 
     338  \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 
    337339\end{flalign*} 
    338340which in vector invariant forms, it leads to: 
    339 \begin{equation} \label{eq:KE+PE_vect_discrete}   \begin{split} 
    340                         \sum\limits_{i,j,k} \biggl\{   u\,                        \partial_t u         \;b_u  
    341                                                               + v\,                        \partial_t v          \;b_v  \biggr\} 
    342   + \frac{1}{2} \sum\limits_{i,j,k} \biggl\{  \frac{u^2}{e_{3u}}\partial_t e_{3u} \;b_u  
    343                                                              +  \frac{v^2}{e_{3v}}\partial_t e_{3v} \;b_v   \biggr\}      \\ 
    344 = - \sum\limits_{i,j,k} \biggl\{ \frac{1}{e_{3t}}\partial_t (e_{3t} \rho) \, g \, z_t \;b_t  \biggr\}  
    345      - \sum\limits_{i,j,k} \biggl\{ \rho \,g\,\partial_t (z_t) \,b_t  \biggr\}                                 
    346 \end{split} \end{equation} 
     341\begin{equation} 
     342  \label{eq:KE+PE_vect_discrete} 
     343  \begin{split} 
     344    \sum\limits_{i,j,k} \biggl\{   u\,                        \partial_t u         \;b_u 
     345    + v\,                        \partial_t v          \;b_v  \biggr\} 
     346    + \frac{1}{2} \sum\limits_{i,j,k} \biggl\{  \frac{u^2}{e_{3u}}\partial_t e_{3u} \;b_u 
     347    +  \frac{v^2}{e_{3v}}\partial_t e_{3v} \;b_v   \biggr\}      \\ 
     348    = - \sum\limits_{i,j,k} \biggl\{ \frac{1}{e_{3t}}\partial_t (e_{3t} \rho) \, g \, z_t \;b_t  \biggr\} 
     349    - \sum\limits_{i,j,k} \biggl\{ \rho \,g\,\partial_t (z_t) \,b_t  \biggr\} 
     350  \end{split} 
     351\end{equation} 
    347352 
    348353Substituting the discrete expression of the time derivative of the velocity either in vector invariant, 
     
    365370 
    366371For the ENE scheme, the two components of the vorticity term are given by: 
    367 \begin{equation*} 
    368 - e_3 \, q \;{\textbf{k}}\times {\textbf {U}}_h    \equiv  
    369    \left( {{  \begin{array} {*{20}c} 
    370       + \frac{1} {e_{1u}} \;  
    371       \overline {\, q \ \overline {\left( e_{1v}\,e_{3v}\,v \right)}^{\,i+1/2}} ^{\,j}        \hfill \\ 
    372       - \frac{1} {e_{2v}} \;  
    373       \overline {\, q \ \overline {\left( e_{2u}\,e_{3u}\,u \right)}^{\,j+1/2}} ^{\,i}       \hfill \\ 
    374    \end{array}} }    \right) 
    375 \end{equation*} 
     372\[ 
     373  - e_3 \, q \;{\textbf{k}}\times {\textbf {U}}_h    \equiv 
     374  \left( {{ 
     375        \begin{array} {*{20}c} 
     376          + \frac{1} {e_{1u}} \; 
     377          \overline {\, q \ \overline {\left( e_{1v}\,e_{3v}\,v \right)}^{\,i+1/2}} ^{\,j}        \hfill \\ 
     378          - \frac{1} {e_{2v}} \; 
     379          \overline {\, q \ \overline {\left( e_{2u}\,e_{3u}\,u \right)}^{\,j+1/2}} ^{\,i}       \hfill 
     380        \end{array} 
     381      } }    \right) 
     382\] 
    376383 
    377384This formulation does not conserve the enstrophy but it does conserve the total kinetic energy. 
     
    379386averaged over the ocean domain can be transformed as follows: 
    380387\begin{flalign*} 
    381 &\int\limits_D -  \left(  e_3 \, q \;\textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv &&  \\ 
    382 & \qquad \qquad {\begin{array}{*{20}l}  
    383 &\equiv \sum\limits_{i,j,k}   \biggl\{     
    384      \frac{1} {e_{1u}} \overline { \,q\ \overline{ V }^{\,i+1/2}} ^{\,j} \, u \; b_u  
    385    - \frac{1} {e_{2v}}\overline { \, q\ \overline{ U }^{\,j+1/2}} ^{\,i} \, v \; b_v \; \biggr\}    \\  
    386 &\equiv  \sum\limits_{i,j,k}  \biggl\{     
    387      \overline { \,q\ \overline{ V }^{\,i+1/2}}^{\,j} \; U  
    388    - \overline { \,q\ \overline{ U }^{\,j+1/2}}^{\,i} \; V  \; \biggr\}     \\ 
    389 &\equiv \sum\limits_{i,j,k} q \  \biggl\{  \overline{ V }^{\,i+1/2}\; \overline{ U }^{\,j+1/2}         
    390                                               - \overline{ U }^{\,j+1/2}\; \overline{ V }^{\,i+1/2}         \biggr\}  \quad  \equiv 0 
    391 \end{array} }      
     388  &\int\limits_D -  \left(  e_3 \, q \;\textbf{k} \times \textbf{U}_h  \right) \cdot \textbf{U}_h  \;  dv &&  \\ 
     389  & \qquad \qquad 
     390  { 
     391    \begin{array}{*{20}l} 
     392      &\equiv \sum\limits_{i,j,k}   \biggl\{ 
     393        \frac{1} {e_{1u}} \overline { \,q\ \overline{ V }^{\,i+1/2}} ^{\,j} \, u \; b_u 
     394        - \frac{1} {e_{2v}}\overline { \, q\ \overline{ U }^{\,j+1/2}} ^{\,i} \, v \; b_v \; \biggr\}    \\ 
     395      &\equiv  \sum\limits_{i,j,k}  \biggl\{ 
     396        \overline { \,q\ \overline{ V }^{\,i+1/2}}^{\,j} \; U 
     397        - \overline { \,q\ \overline{ U }^{\,j+1/2}}^{\,i} \; V  \; \biggr\}     \\ 
     398      &\equiv \sum\limits_{i,j,k} q \  \biggl\{  \overline{ V }^{\,i+1/2}\; \overline{ U }^{\,j+1/2} 
     399        - \overline{ U }^{\,j+1/2}\; \overline{ V }^{\,i+1/2}         \biggr\}  \quad  \equiv 0 
     400    \end{array} 
     401  }       
    392402\end{flalign*} 
    393403In other words, the domain averaged kinetic energy does not change due to the vorticity term. 
    394  
    395404 
    396405% ------------------------------------------------------------------------------------------------------------- 
     
    401410 
    402411With the EEN scheme, the vorticity terms are represented as:  
    403 \begin{equation} \tag{\ref{eq:dynvor_een}} 
    404 \left\{ {    \begin{aligned} 
    405  +q\,e_3 \, v  &\equiv +\frac{1}{e_{1u} }   \sum_{\substack{i_p,\,k_p}}  
    406                          {^{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}   \\ 
    407  - q\,e_3 \, u     &\equiv -\frac{1}{e_{2v} }    \sum_{\substack{i_p,\,k_p}}  
    408                          {^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}   \\ 
    409 \end{aligned}   } \right. 
     412\begin{equation} 
     413  \tag{\ref{eq:dynvor_een}} 
     414  \left\{ { 
     415      \begin{aligned} 
     416        +q\,e_3 \, v    &\equiv +\frac{1}{e_{1u} }   \sum_{\substack{i_p,\,k_p}} 
     417        {^{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}   \\ 
     418        - q\,e_3 \, u     &\equiv -\frac{1}{e_{2v} }    \sum_{\substack{i_p,\,k_p}} 
     419        {^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} 
     420      \end{aligned} 
     421    } \right. 
    410422\end{equation}  
    411423where the indices $i_p$ and $j_p$ take the following value: $i_p = -1/2$ or $1/2$ and $j_p = -1/2$ or $1/2$, 
    412424and the vorticity triads, ${^i_j}\mathbb{Q}^{i_p}_{j_p}$, defined at $T$-point, are given by:  
    413 \begin{equation} \tag{\ref{eq:Q_triads}} 
    414 _i^j \mathbb{Q}^{i_p}_{j_p} 
    415 = \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) 
     425\begin{equation} 
     426  \tag{\ref{eq:Q_triads}} 
     427  _i^j \mathbb{Q}^{i_p}_{j_p} 
     428  = \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) 
    416429\end{equation} 
    417430 
     
    419432Indeed, 
    420433\begin{flalign*} 
    421 &\int\limits_D - \textbf{U}_h \cdot   \left(  \zeta \;\textbf{k} \times \textbf{U}_h  \right)  \;  dv &&  \\ 
    422 \equiv \sum\limits_{i,j,k} &  \biggl\{  
    423        \left[  \sum_{\substack{i_p,\,k_p}}  
    424                          {^{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}    %   &&\\ 
    425      - \left[  \sum_{\substack{i_p,\,k_p}}  
    426                          {^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\}     && \\ 
    427 \\ 
    428 \equiv \sum\limits_{i,j,k} &  \sum_{\substack{i_p,\,k_p}} \biggl\{  \ \   
    429                          {^{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}     %  &&\\ 
    430                        - {^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\}     &&  \\ 
    431 % 
    432 \allowdisplaybreaks 
    433 \intertext{ Expending the summation on $i_p$ and $k_p$, it becomes:} 
    434 % 
    435 \equiv \sum\limits_{i,j,k} & \biggl\{  \ \   
    436                     {^{i+1}_j     }\mathbb{Q}^{-1/2}_{+1/2} \;V^{i+1}_{j+1/2} \; U^{\,i+1/2}_{j}       
    437                 -  {^i_{j}\quad}\mathbb{Q}^{-1/2}_{+1/2} \; U^{i-1/2}_{j}    \; V^{\,i}_{j+1/2}         &&  \\ 
    438         &       + {^{i+1}_j     }\mathbb{Q}^{-1/2}_{-1/2} \; V^{i+1}_{j-1/2} \; U^{\,i+1/2}_{j}         
    439                   - {^i_{j+1}     }\mathbb{Q}^{-1/2}_{-1/2} \; U^{i-1/2}_{j+1} \; V^{\,i}_{j+1/2}        \biggr.     &&  \\ 
    440         &       + {^{i}_j\quad}\mathbb{Q}^{+1/2}_{+1/2} \; V^{i}_{j+1/2}   \; U^{\,i+1/2}_{j}       
    441                   - {^i_{j}\quad}\mathbb{Q}^{+1/2}_{+1/2} \; U^{i+1/2}_{j}   \; V^{\,i}_{j+1/2}          \biggr.        &&  \\ 
    442         &       + {^{i}_j\quad}\mathbb{Q}^{+1/2}_{-1/2} \; V^{i}_{j-1/2}     \; U^{\,i+1/2}_{j}        
    443                  -  {^i_{j+1}     }\mathbb{Q}^{+1/2}_{-1/2} \; U^{i+1/2}_{j+1}\; V^{\,i}_{j+1/2}  \ \;     \biggr\}     &&  \\ 
    444 % 
    445 \allowdisplaybreaks 
    446 \intertext{The summation is done over all $i$ and $j$ indices, it is therefore possible to introduce  
    447 a shift of $-1$ either in $i$ or $j$ direction in some of the term of the summation (first term of the  
    448 first and second lines, second term of the second and fourth lines). By doning so, we can regroup  
    449 all the terms of the summation by triad at a ($i$,$j$) point. In other words, we regroup all the terms  
    450 in the neighbourhood  that contain a triad at the same ($i$,$j$) indices. It becomes: } 
    451 \allowdisplaybreaks 
    452 % 
    453 \equiv \sum\limits_{i,j,k} & \biggl\{  \ \   
    454              {^{i}_j}\mathbb{Q}^{-1/2}_{+1/2}  \left[  V^{i}_{j+1/2}\, U^{\,i-1/2}_{j}     
    455                                                                        -  U^{i-1/2}_{j} \, V^{\,i}_{j+1/2}      \right]    &&  \\ 
    456  &       + {^{i}_j}\mathbb{Q}^{-1/2}_{-1/2}  \left[  V^{i}_{j-1/2} \, U^{\,i-1/2}_{j}         
    457                                                                      -    U^{i-1/2}_{j} \, V^{\,i}_{j-1/2}      \right]    \biggr.   &&  \\ 
    458  &      + {^{i}_j}\mathbb{Q}^{+1/2}_{+1/2}  \left[  V^{i}_{j+1/2} \, U^{\,i+1/2}_{j}       
    459                                                                      -    U^{i+1/2}_{j} \, V^{\,i}_{j+1/2}     \right]  \biggr.  &&  \\ 
    460  &     + {^{i}_j}\mathbb{Q}^{+1/2}_{-1/2}  \left[   V^{i}_{j-1/2} \, U^{\,i+1/2}_{j}                                                                      
    461                                                                     -    U^{i+1/2}_{j-1} \, V^{\,i}_{j-1/2}  \right]  \ \;   \biggr\}   \qquad 
    462 \equiv \ 0   && 
    463 \end{flalign*} 
    464  
     434  &\int\limits_D - \textbf{U}_h \cdot   \left(  \zeta \;\textbf{k} \times \textbf{U}_h  \right)  \;  dv &&  \\ 
     435  \equiv \sum\limits_{i,j,k} &   \biggl\{ 
     436  \left[  \sum_{\substack{i_p,\,k_p}} 
     437    {^{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}    %   &&\\ 
     438  - \left[  \sum_{\substack{i_p,\,k_p}} 
     439    {^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\}     && \\ \\ 
     440  \equiv \sum\limits_{i,j,k} &  \sum_{\substack{i_p,\,k_p}} \biggl\{  \ \ 
     441  {^{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}     %  &&\\ 
     442  - {^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\}     &&  \\ 
     443  % 
     444  \allowdisplaybreaks 
     445  \intertext{ Expending the summation on $i_p$ and $k_p$, it becomes:} 
     446  % 
     447  \equiv \sum\limits_{i,j,k} & \biggl\{  \ \ 
     448  {^{i+1}_j     }\mathbb{Q}^{-1/2}_{+1/2} \;V^{i+1}_{j+1/2} \; U^{\,i+1/2}_{j} 
     449  -  {^i_{j}\quad}\mathbb{Q}^{-1/2}_{+1/2} \; U^{i-1/2}_{j}    \; V^{\,i}_{j+1/2}         &&  \\ 
     450  &       + {^{i+1}_j     }\mathbb{Q}^{-1/2}_{-1/2} \; V^{i+1}_{j-1/2} \; U^{\,i+1/2}_{j} 
     451  - {^i_{j+1}     }\mathbb{Q}^{-1/2}_{-1/2} \; U^{i-1/2}_{j+1} \; V^{\,i}_{j+1/2}        \biggr.     &&  \\ 
     452  &       + {^{i}_j\quad}\mathbb{Q}^{+1/2}_{+1/2} \; V^{i}_{j+1/2}   \; U^{\,i+1/2}_{j} 
     453  - {^i_{j}\quad}\mathbb{Q}^{+1/2}_{+1/2} \; U^{i+1/2}_{j}   \; V^{\,i}_{j+1/2}          \biggr.        &&  \\ 
     454  &       + {^{i}_j\quad}\mathbb{Q}^{+1/2}_{-1/2} \; V^{i}_{j-1/2}     \; U^{\,i+1/2}_{j} 
     455  -  {^i_{j+1}     }\mathbb{Q}^{+1/2}_{-1/2} \; U^{i+1/2}_{j+1}\; V^{\,i}_{j+1/2}  \ \;     \biggr\}     &&  \\ 
     456  % 
     457  \allowdisplaybreaks 
     458  \intertext{The summation is done over all $i$ and $j$ indices, it is therefore possible to introduce 
     459    a shift of $-1$ either in $i$ or $j$ direction in some of the term of the summation (first term of the 
     460    first and second lines, second term of the second and fourth lines). By doning so, we can regroup 
     461    all the terms of the summation by triad at a ($i$,$j$) point. In other words, we regroup all the terms 
     462    in the neighbourhood  that contain a triad at the same ($i$,$j$) indices. It becomes: } 
     463  \allowdisplaybreaks 
     464  % 
     465  \equiv \sum\limits_{i,j,k} & \biggl\{  \ \ 
     466  {^{i}_j}\mathbb{Q}^{-1/2}_{+1/2}  \left[  V^{i}_{j+1/2}\, U^{\,i-1/2}_{j} 
     467    -  U^{i-1/2}_{j} \, V^{\,i}_{j+1/2}      \right]    &&  \\ 
     468  &       + {^{i}_j}\mathbb{Q}^{-1/2}_{-1/2}  \left[  V^{i}_{j-1/2} \, U^{\,i-1/2}_{j} 
     469    -    U^{i-1/2}_{j} \, V^{\,i}_{j-1/2}      \right]    \biggr.   &&  \\ 
     470  &      + {^{i}_j}\mathbb{Q}^{+1/2}_{+1/2}  \left[  V^{i}_{j+1/2} \, U^{\,i+1/2}_{j} 
     471    -    U^{i+1/2}_{j} \, V^{\,i}_{j+1/2}     \right]  \biggr.  &&  \\ 
     472  &     + {^{i}_j}\mathbb{Q}^{+1/2}_{-1/2}  \left[   V^{i}_{j-1/2} \, U^{\,i+1/2}_{j} 
     473    -    U^{i+1/2}_{j-1} \, V^{\,i}_{j-1/2}  \right]  \ \;   \biggr\}   \qquad 
     474  \equiv \ 0   && 
     475\end{flalign*} 
    465476 
    466477% ------------------------------------------------------------------------------------------------------------- 
     
    471482 
    472483The change of Kinetic Energy (KE) due to the vertical advection is exactly balanced by the change of KE due to the horizontal gradient of KE~: 
    473 \begin{equation*} 
    474     \int_D \textbf{U}_h \cdot \frac{1}{e_3 } \omega \partial_k \textbf{U}_h \;dv 
    475 =  -   \int_D \textbf{U}_h \cdot \nabla_h \left( \frac{1}{2}\;{\textbf{U}_h}^2 \right)\;dv 
    476    +   \frac{1}{2} \int_D {  \frac{{\textbf{U}_h}^2}{e_3} \partial_t ( e_3) \;dv }  \\ 
    477 \end{equation*} 
     484\[ 
     485  \int_D \textbf{U}_h \cdot \frac{1}{e_3 } \omega \partial_k \textbf{U}_h \;dv 
     486  =  -   \int_D \textbf{U}_h \cdot \nabla_h \left( \frac{1}{2}\;{\textbf{U}_h}^2 \right)\;dv 
     487  +   \frac{1}{2} \int_D {  \frac{{\textbf{U}_h}^2}{e_3} \partial_t ( e_3) \;dv } 
     488\] 
    478489Indeed, using successively \autoref{eq:DOM_di_adj} ($i.e.$ the skew symmetry property of the $\delta$ operator) 
    479490and the continuity equation, then \autoref{eq:DOM_di_adj} again, 
     
    482493applied in the horizontal and vertical directions, it becomes: 
    483494\begin{flalign*} 
    484 & - \int_D \textbf{U}_h \cdot \text{KEG}\;dv     
    485 = - \int_D \textbf{U}_h \cdot \nabla_h \left( \frac{1}{2}\;{\textbf{U}_h}^2 \right)\;dv    &&&\\ 
    486 % 
    487 \equiv  & -  \sum\limits_{i,j,k} \frac{1}{2}  \biggl\{    
    488    \frac{1} {e_{1u}}  \delta_{i+1/2}   \left[   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right]  u \ b_u  
    489      + \frac{1} {e_{2v}}  \delta_{j+1/2}   \left[   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right]  v \ b_v   \biggr\}     &&&  \\  
    490 % 
    491 \equiv & + \sum\limits_{i,j,k} \frac{1}{2}  \left(   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right)\; 
    492                                                               \biggl\{ \delta_{i} \left[  U   \right] +  \delta_{j} \left[  V  \right]    \biggr\}       &&&  \\  
    493 \allowdisplaybreaks 
    494 % 
    495 \equiv   & - \sum\limits_{i,j,k}  \frac{1}{2} 
    496    \left(       \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right)  \;   
    497    \biggl\{   \frac{b_t}{e_{3t}} \partial_t (e_{3t})  +  \delta_k \left[  W   \right]    \biggr\}    &&&\\ 
    498 \allowdisplaybreaks 
    499 % 
    500 \equiv & +  \sum\limits_{i,j,k} \frac{1}{2} \delta_{k+1/2}   \left[ \overline{ u^2}^{\,i} + \overline{ v^2}^{\,j}   \right] \;  W  
    501           -  \sum\limits_{i,j,k} \frac{1}{2} \left(   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right) \;\partial_t b_t   &&& \\ 
    502 \allowdisplaybreaks 
    503 % 
    504 \equiv   & + \sum\limits_{i,j,k} \frac{1} {2} \left(    \overline{\delta_{k+1/2} \left[ u^2 \right]}^{\,i}  
    505                                                                    + \overline{\delta_{k+1/2} \left[ v^2 \right]}^{\,j}    \right) \; W      
    506           -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t \overline{b_t}^{\,{i+1/2}} 
    507                                                  + \frac{v^2}{2}\,\partial_t \overline{b_t}^{\,{j+1/2}}   \right)    &&& \\ 
    508 \allowdisplaybreaks 
    509 \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 
    510 derivative of these two equations is satisfied, it becomes:} 
    511 % 
    512 \equiv &     \sum\limits_{i,j,k} \frac{1} {2} 
    513    \biggl\{ \; \overline{W}^{\,i+1/2}\;\delta_{k+1/2} \left[ u^2 \right]     
    514                + \overline{W}^{\,j+1/2}\;\delta_{k+1/2} \left[ v^2 \right]  \;  \biggr\}    
    515           -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t b_u 
    516                                                 + \frac{v^2}{2}\,\partial_t b_v   \right)    &&& \\ 
    517 \allowdisplaybreaks 
    518  
    519 \equiv &     \sum\limits_{i,j,k}  
    520    \biggl\{ \; \overline{W}^{\,i+1/2}\; \overline {u}^{\,k+1/2}\; \delta_{k+1/2}[ u ]     
    521                + \overline{W}^{\,j+1/2}\; \overline {v}^{\,k+1/2}\; \delta_{k+1/2}[ v ]  \;  \biggr\}  
    522           -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t b_u 
    523                                                 + \frac{v^2}{2}\,\partial_t b_v   \right)    &&& \\ 
    524 % 
    525 \allowdisplaybreaks 
    526 \equiv  &  \sum\limits_{i,j,k}   
    527    \biggl\{ \; \frac{1} {b_u } \; \overline { \overline{W}^{\,i+1/2}\,\delta_{k+1/2}  \left[ u \right] }^{\,k} \;u\;b_u   
    528                     + \frac{1} {b_v } \; \overline { \overline{W}^{\,j+1/2} \delta_{k+1/2}  \left[ v \right]  }^{\,k} \;v\;b_v  \; \biggr\}   
    529           -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t b_u 
    530                                                 + \frac{v^2}{2}\,\partial_t b_v   \right)    &&& \\ 
    531 % 
    532 \intertext{The first term provides the discrete expression for the vertical advection of momentum (ZAD),  
    533 while the second term corresponds exactly to \autoref{eq:KE+PE_vect_discrete}, therefore:} 
    534 \equiv&                   \int\limits_D \textbf{U}_h \cdot \text{ZAD} \;dv   
    535            + \frac{1}{2} \int_D { {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t  (e_3)  \;dv }    &&&\\ 
    536 \equiv&                   \int\limits_D \textbf{U}_h \cdot w \partial_k \textbf{U}_h \;dv   
    537            + \frac{1}{2} \int_D { {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t  (e_3)  \;dv }    &&&\\ 
     495  & - \int_D \textbf{U}_h \cdot \text{KEG}\;dv 
     496  = - \int_D \textbf{U}_h \cdot \nabla_h \left( \frac{1}{2}\;{\textbf{U}_h}^2 \right)\;dv    &&&\\ 
     497  % 
     498  \equiv  & -  \sum\limits_{i,j,k} \frac{1}{2}  \biggl\{ 
     499  \frac{1} {e_{1u}}  \delta_{i+1/2}   \left[   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right]  u \ b_u 
     500  + \frac{1} {e_{2v}}  \delta_{j+1/2}   \left[   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right]  v \ b_v   \biggr\}     &&&  \\ 
     501  % 
     502  \equiv & + \sum\limits_{i,j,k} \frac{1}{2}  \left(   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right)\; 
     503  \biggl\{ \delta_{i} \left[  U   \right] +  \delta_{j} \left[  V  \right]    \biggr\}       &&&  \\ 
     504  \allowdisplaybreaks 
     505  % 
     506  \equiv   & - \sum\limits_{i,j,k}  \frac{1}{2} 
     507  \left(       \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right)  \; 
     508  \biggl\{   \frac{b_t}{e_{3t}} \partial_t (e_{3t})  +  \delta_k \left[  W   \right]    \biggr\}    &&&\\ 
     509  \allowdisplaybreaks 
     510  % 
     511  \equiv & +  \sum\limits_{i,j,k} \frac{1}{2} \delta_{k+1/2}   \left[ \overline{ u^2}^{\,i} + \overline{ v^2}^{\,j}   \right] \;  W 
     512  -  \sum\limits_{i,j,k} \frac{1}{2} \left(   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right) \;\partial_t b_t   &&& \\ 
     513  \allowdisplaybreaks 
     514  % 
     515  \equiv   & + \sum\limits_{i,j,k} \frac{1} {2} \left(    \overline{\delta_{k+1/2} \left[ u^2 \right]}^{\,i} 
     516    + \overline{\delta_{k+1/2} \left[ v^2 \right]}^{\,j}    \right) \; W 
     517  -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t \overline{b_t}^{\,{i+1/2}} 
     518    + \frac{v^2}{2}\,\partial_t \overline{b_t}^{\,{j+1/2}}   \right)    &&& \\ 
     519  \allowdisplaybreaks 
     520  \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 
     521    derivative of these two equations is satisfied, it becomes:} 
     522  % 
     523  \equiv &     \sum\limits_{i,j,k} \frac{1} {2} 
     524  \biggl\{ \; \overline{W}^{\,i+1/2}\;\delta_{k+1/2} \left[ u^2 \right] 
     525  + \overline{W}^{\,j+1/2}\;\delta_{k+1/2} \left[ v^2 \right]  \;  \biggr\} 
     526  -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t b_u 
     527    + \frac{v^2}{2}\,\partial_t b_v   \right)    &&& \\ 
     528  \allowdisplaybreaks 
     529  % 
     530  \equiv &     \sum\limits_{i,j,k} 
     531  \biggl\{ \; \overline{W}^{\,i+1/2}\; \overline {u}^{\,k+1/2}\; \delta_{k+1/2}[ u ] 
     532  + \overline{W}^{\,j+1/2}\; \overline {v}^{\,k+1/2}\; \delta_{k+1/2}[ v ]  \;  \biggr\} 
     533  -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t b_u 
     534    + \frac{v^2}{2}\,\partial_t b_v   \right)    &&& \\ 
     535  % 
     536  \allowdisplaybreaks 
     537  \equiv  &  \sum\limits_{i,j,k} 
     538  \biggl\{ \; \frac{1} {b_u } \; \overline { \overline{W}^{\,i+1/2}\,\delta_{k+1/2}  \left[ u \right] }^{\,k} \;u\;b_u 
     539  + \frac{1} {b_v } \; \overline { \overline{W}^{\,j+1/2} \delta_{k+1/2}  \left[ v \right]  }^{\,k} \;v\;b_v  \; \biggr\} 
     540  -  \sum\limits_{i,j,k}  \left(  \frac{u^2}{2}\,\partial_t b_u 
     541    + \frac{v^2}{2}\,\partial_t b_v   \right)    &&& \\ 
     542  % 
     543  \intertext{The first term provides the discrete expression for the vertical advection of momentum (ZAD), 
     544    while the second term corresponds exactly to \autoref{eq:KE+PE_vect_discrete}, therefore:} 
     545  \equiv&                   \int\limits_D \textbf{U}_h \cdot \text{ZAD} \;dv 
     546  + \frac{1}{2} \int_D { {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t  (e_3)  \;dv }    &&&\\ 
     547  \equiv&                   \int\limits_D \textbf{U}_h \cdot w \partial_k \textbf{U}_h \;dv 
     548  + \frac{1}{2} \int_D { {\textbf{U}_h}^2 \frac{1}{e_3} \partial_t  (e_3)  \;dv }    &&&\\ 
    538549\end{flalign*} 
    539550 
     
    544555For example KE can also be discretized as $1/2\,({\overline u^{\,i}}^2 + {\overline v^{\,j}}^2)$. 
    545556This leads to the following expression for the vertical advection: 
    546 \begin{equation*} 
    547 \frac{1} {e_3 }\; \omega\; \partial_k \textbf{U}_h 
    548 \equiv \left( {{\begin{array} {*{20}c} 
    549 \frac{1} {e_{1u}\,e_{2u}\,e_{3u}} \;  \overline{\overline {e_{1t}\,e_{2t} \,\omega\;\delta_{k+1/2}  
    550 \left[ \overline u^{\,i+1/2} \right]}}^{\,i+1/2,k}  \hfill \\ 
    551 \frac{1} {e_{1v}\,e_{2v}\,e_{3v}} \;   \overline{\overline {e_{1t}\,e_{2t} \,\omega \;\delta_{k+1/2} 
    552 \left[ \overline v^{\,j+1/2} \right]}}^{\,j+1/2,k} \hfill \\ 
    553 \end{array}} } \right) 
    554 \end{equation*} 
     557\[ 
     558  \frac{1} {e_3 }\; \omega\; \partial_k \textbf{U}_h 
     559  \equiv \left( {{ 
     560        \begin{array} {*{20}c} 
     561          \frac{1} {e_{1u}\,e_{2u}\,e_{3u}} \;  \overline{\overline {e_{1t}\,e_{2t} \,\omega\;\delta_{k+1/2} 
     562          \left[ \overline u^{\,i+1/2} \right]}}^{\,i+1/2,k}  \hfill \\ 
     563          \frac{1} {e_{1v}\,e_{2v}\,e_{3v}} \;   \overline{\overline {e_{1t}\,e_{2t} \,\omega \;\delta_{k+1/2} 
     564          \left[ \overline v^{\,j+1/2} \right]}}^{\,j+1/2,k} \hfill 
     565        \end{array} 
     566      } } \right) 
     567\] 
    555568a formulation that requires an additional horizontal mean in contrast with the one used in NEMO. 
    556569Nine velocity points have to be used instead of 3. 
     
    560573an extra constraint arises on the time derivative of the volume at $u$- and $v$-points: 
    561574\begin{flalign*} 
    562 e_{1u}\,e_{2u}\,\partial_t (e_{3u}) =\overline{ e_{1t}\,e_{2t}\;\partial_t (e_{3t}) }^{\,i+1/2}    \\ 
    563 e_{1v}\,e_{2v}\,\partial_t (e_{3v})  =\overline{ e_{1t}\,e_{2t}\;\partial_t (e_{3t}) }^{\,j+1/2} 
     575  e_{1u}\,e_{2u}\,\partial_t (e_{3u}) =\overline{ e_{1t}\,e_{2t}\;\partial_t (e_{3t}) }^{\,i+1/2}    \\ 
     576  e_{1v}\,e_{2v}\,\partial_t (e_{3v})  =\overline{ e_{1t}\,e_{2t}\;\partial_t (e_{3t}) }^{\,j+1/2} 
    564577\end{flalign*} 
    565578which is (over-)satified by defining the vertical scale factor as follows: 
    566 \begin{flalign} \label{eq:e3u-e3v} 
    567 e_{3u} = \frac{1}{e_{1u}\,e_{2u}}\;\overline{ e_{1t}^{ }\,e_{2t}^{ }\,e_{3t}^{ } }^{\,i+1/2}    \\ 
    568 e_{3v} = \frac{1}{e_{1v}\,e_{2v}}\;\overline{ e_{1t}^{ }\,e_{2t}^{ }\,e_{3t}^{ } }^{\,j+1/2}  
    569 \end{flalign} 
     579\begin{flalign*} 
     580  % \label{eq:e3u-e3v} 
     581  e_{3u} = \frac{1}{e_{1u}\,e_{2u}}\;\overline{ e_{1t}^{ }\,e_{2t}^{ }\,e_{3t}^{ } }^{\,i+1/2}    \\ 
     582  e_{3v} = \frac{1}{e_{1v}\,e_{2v}}\;\overline{ e_{1t}^{ }\,e_{2t}^{ }\,e_{3t}^{ } }^{\,j+1/2} 
     583\end{flalign*} 
    570584 
    571585Blah blah required on the the step representation of bottom topography..... 
     
    588602the change of KE due to the work of pressure forces is balanced by 
    589603the change of potential energy due to buoyancy forces:  
    590 \begin{equation*} 
    591 - \int_D  \left. \nabla p \right|_z \cdot \textbf{U}_h \;dv  
    592 = - \int_D \nabla \cdot \left( \rho \,\textbf {U} \right) \,g\,z \;dv 
     604\[ 
     605  - \int_D  \left. \nabla p \right|_z \cdot \textbf{U}_h \;dv 
     606  = - \int_D \nabla \cdot \left( \rho \,\textbf {U} \right) \,g\,z \;dv 
    593607  + \int_D g\, \rho \; \partial_t (z)  \;dv 
    594 \end{equation*} 
     608\] 
    595609 
    596610This property can be satisfied in a discrete sense for both $z$- and $s$-coordinates. 
     
    599613the work of pressure forces can be written as: 
    600614\begin{flalign*} 
    601 &- \int_D  \left. \nabla p \right|_z \cdot \textbf{U}_h \;dv    
    602 \equiv \sum\limits_{i,j,k} \biggl\{ \;  - \frac{1} {e_{1u}}   \Bigl(  
    603 \delta_{i+1/2} [p_t] - g\;\overline \rho^{\,i+1/2}\;\delta_{i+1/2} [z_t]     \Bigr)  \; u\;b_u   
    604    &&  \\ & \qquad \qquad  \qquad \qquad  \qquad \quad \ \, 
    605                         - \frac{1} {e_{2v}}    \Bigl(  
    606 \delta_{j+1/2} [p_t] - g\;\overline \rho^{\,j+1/2}\delta_{j+1/2} [z_t]      \Bigr)  \; v\;b_v \;  \biggr\}   && \\  
    607 % 
    608 \allowdisplaybreaks 
    609 \intertext{Using successively \autoref{eq:DOM_di_adj}, $i.e.$ the skew symmetry property of  
    610 the $\delta$ operator, \autoref{eq:wzv}, the continuity equation, \autoref{eq:dynhpg_sco},  
    611 the hydrostatic equation in the $s$-coordinate, and $\delta_{k+1/2} \left[ z_t \right] \equiv e_{3w} $, 
    612 which comes from the definition of $z_t$, it becomes: } 
    613 \allowdisplaybreaks 
    614 % 
    615 \equiv& +  \sum\limits_{i,j,k}   g  \biggl\{  
    616       \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t]     
    617    +     \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t]      
    618    +\Bigl(  \delta_i[U] + \delta_j [V]  \Bigr)\;\frac{p_t}{g} \biggr\}  &&\\ 
    619 % 
    620 \equiv& +  \sum\limits_{i,j,k}   g   \biggl\{  
    621       \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t]     
    622    +     \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t]      
    623     -       \left(   \frac{b_t}{e_{3t}} \partial_t (e_{3t})  +  \delta_k \left[ W \right]    \right) \frac{p_t}{g}    \biggr\}   &&&\\  
    624 % 
    625 \equiv& +  \sum\limits_{i,j,k}  g   \biggl\{  
    626       \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t]     
    627    +     \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t]      
    628    +  \frac{W}{g}\;\delta_{k+1/2} [p_t]  
    629     -        \frac{p_t}{g}\,\partial_t b_t    \biggr\}    &&&\\ 
    630 % 
    631 \equiv& +  \sum\limits_{i,j,k}  g   \biggl\{  
    632       \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t]     
    633    +     \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t]      
    634    -  W\;e_{3w} \overline \rho^{\,k+1/2}          
    635     -        \frac{p_t}{g}\,\partial_t b_t    \biggr\}    &&&\\ 
    636 % 
    637 \equiv& +  \sum\limits_{i,j,k}    g   \biggl\{  
    638       \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t]     
    639    +     \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t]      
    640    +  W\; \overline \rho^{\,k+1/2}\;\delta_{k+1/2} [z_t]    
    641     -        \frac{p_t}{g}\,\partial_t b_t    \biggr\}    &&&\\ 
    642 % 
    643 \allowdisplaybreaks 
    644 % 
    645 \equiv& - \sum\limits_{i,j,k}   g \; z_t      \biggl\{  
    646       \delta_i    \left[ U\;  \overline \rho^{\,i+1/2}   \right] 
    647    +  \delta_j    \left[ V\;  \overline \rho^{\,j+1/2}   \right] 
    648    +  \delta_k    \left[ W\;  \overline \rho^{\,k+1/2}   \right]       \biggr\}     
    649              - \sum\limits_{i,j,k}       \biggl\{ p_t\;\partial_t b_t    \biggr\}   &&&\\  
    650 % 
    651 \equiv& + \sum\limits_{i,j,k}   g \; z_t    \biggl\{      \partial_t ( e_{3t} \,\rho)    \biggr\}  \; b_t     
    652              -  \sum\limits_{i,j,k}                 \biggl\{  p_t\;\partial_t b_t                     \biggr\}              &&&\\    
    653 % 
     615  &- \int_D  \left. \nabla p \right|_z \cdot \textbf{U}_h \;dv 
     616  \equiv \sum\limits_{i,j,k} \biggl\{ \;  - \frac{1} {e_{1u}}   \Bigl( 
     617  \delta_{i+1/2} [p_t] - g\;\overline \rho^{\,i+1/2}\;\delta_{i+1/2} [z_t]     \Bigr)  \; u\;b_u && \\ 
     618  & \qquad \qquad  \qquad \qquad  \qquad \quad \ \, 
     619  - \frac{1} {e_{2v}}    \Bigl( 
     620  \delta_{j+1/2} [p_t] - g\;\overline \rho^{\,j+1/2}\delta_{j+1/2} [z_t]      \Bigr)  \; v\;b_v \;  \biggr\}   && \\ 
     621  % 
     622  \allowdisplaybreaks 
     623  \intertext{Using successively \autoref{eq:DOM_di_adj}, $i.e.$ the skew symmetry property of 
     624    the $\delta$ operator, \autoref{eq:wzv}, the continuity equation, \autoref{eq:dynhpg_sco}, 
     625    the hydrostatic equation in the $s$-coordinate, and $\delta_{k+1/2} \left[ z_t \right] \equiv e_{3w} $, 
     626    which comes from the definition of $z_t$, it becomes: } 
     627  \allowdisplaybreaks 
     628  % 
     629  \equiv& +  \sum\limits_{i,j,k}   g  \biggl\{ 
     630  \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t] 
     631  +   \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t] 
     632  +\Bigl(  \delta_i[U] + \delta_j [V]  \Bigr)\;\frac{p_t}{g} \biggr\}  &&\\ 
     633  % 
     634  \equiv& +  \sum\limits_{i,j,k}   g   \biggl\{ 
     635  \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t] 
     636  +   \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t] 
     637  -       \left(   \frac{b_t}{e_{3t}} \partial_t (e_{3t})  +  \delta_k \left[ W \right]    \right) \frac{p_t}{g}    \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  +   \frac{W}{g}\;\delta_{k+1/2} [p_t] 
     643  -        \frac{p_t}{g}\,\partial_t b_t    \biggr\}    &&&\\ 
     644  % 
     645  \equiv& +  \sum\limits_{i,j,k}  g   \biggl\{ 
     646  \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t] 
     647  +   \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t] 
     648  -   W\;e_{3w} \overline \rho^{\,k+1/2} 
     649  -        \frac{p_t}{g}\,\partial_t b_t    \biggr\}    &&&\\ 
     650  % 
     651  \equiv& +  \sum\limits_{i,j,k}    g   \biggl\{ 
     652  \overline\rho^{\,i+1/2}\,U\,\delta_{i+1/2}[z_t] 
     653  +   \overline\rho^{\,j+1/2}\,V\,\delta_{j+1/2}[z_t] 
     654  +   W\; \overline \rho^{\,k+1/2}\;\delta_{k+1/2} [z_t] 
     655  -        \frac{p_t}{g}\,\partial_t b_t    \biggr\}    &&&\\ 
     656  % 
     657  \allowdisplaybreaks 
     658  % 
     659  \equiv& - \sum\limits_{i,j,k}   g \; z_t      \biggl\{ 
     660  \delta_i  \left[ U\;  \overline \rho^{\,i+1/2}   \right] 
     661  +   \delta_j    \left[ V\;  \overline \rho^{\,j+1/2}   \right] 
     662  +   \delta_k    \left[ W\;  \overline \rho^{\,k+1/2}   \right]       \biggr\} 
     663  - \sum\limits_{i,j,k}       \biggl\{ p_t\;\partial_t b_t    \biggr\}   &&&\\ 
     664  % 
     665  \equiv& + \sum\limits_{i,j,k}   g \; z_t    \biggl\{      \partial_t ( e_{3t} \,\rho)    \biggr\}  \; b_t 
     666  -  \sum\limits_{i,j,k}                 \biggl\{  p_t\;\partial_t b_t                     \biggr\}              &&&\\ 
     667  % 
    654668\end{flalign*} 
    655669The first term is exactly the first term of the right-hand-side of \autoref{eq:KE+PE_vect_discrete}. 
     
    659673In other words, the following property must be satisfied: 
    660674\begin{flalign*} 
    661            \sum\limits_{i,j,k}  \biggl\{  p_t\;\partial_t b_t                  \biggr\}         
    662 \equiv  \sum\limits_{i,j,k}  \biggl\{ \rho \,g\,\partial_t (z_t) \,b_t  \biggr\}                                 
     675  \sum\limits_{i,j,k}  \biggl\{  p_t\;\partial_t b_t                  \biggr\} 
     676  \equiv  \sum\limits_{i,j,k}  \biggl\{ \rho \,g\,\partial_t (z_t) \,b_t  \biggr\} 
    663677\end{flalign*} 
    664678 
     
    667681 
    668682\begin{flalign*} 
    669                \sum\limits_{i,j,k}  \biggl\{ \rho \,g\,\partial_t (z_t) \,b_t  \biggr\}   
    670 &\equiv   - \sum\limits_{i,j,k}  \biggl\{ \delta_k [p_w]\,\partial_t (z_t) \,e_{1t}\,e_{2t}  \biggr\}        &&&\\ 
    671 % 
    672 &\equiv  + \sum\limits_{i,j,k}  \biggl\{  p_w\, \delta_{k+1/2} [\partial_t (z_t)] \,e_{1t}\,e_{2t}  \biggr\}   
     683  \sum\limits_{i,j,k}  \biggl\{ \rho \,g\,\partial_t (z_t) \,b_t  \biggr\} 
     684  &\equiv   - \sum\limits_{i,j,k}  \biggl\{ \delta_k [p_w]\,\partial_t (z_t) \,e_{1t}\,e_{2t}  \biggr\}        &&&\\ 
     685  % 
     686  &\equiv  + \sum\limits_{i,j,k}  \biggl\{  p_w\, \delta_{k+1/2} [\partial_t (z_t)] \,e_{1t}\,e_{2t}  \biggr\} 
    673687  \equiv  + \sum\limits_{i,j,k}  \biggl\{  p_w\, \partial_t (e_{3w}) \,e_{1t}\,e_{2t}  \biggr\}        &&&\\ 
    674 &\equiv  + \sum\limits_{i,j,k}  \biggl\{  p_w\, \partial_t (b_w) \biggr\}   
    675  % 
    676 % & \equiv     \sum\limits_{i,j,k} \biggl\{  \frac{1}{e_{3t}} \delta_k [p_w]\;\partial_t (z_t) \,b_w   \right)   \biggr\}           &&&\\ 
    677 % & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t \left(    \delta_k [z_t]   \right)  e_{1w}\,e_{2w}   \biggr\}           &&&\\ 
    678 % & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t b_w   \biggr\}           
     688  &\equiv  + \sum\limits_{i,j,k}  \biggl\{  p_w\, \partial_t (b_w) \biggr\} 
     689  % 
     690  % & \equiv     \sum\limits_{i,j,k} \biggl\{  \frac{1}{e_{3t}} \delta_k [p_w]\;\partial_t (z_t) \,b_w   \right)   \biggr\}           &&&\\ 
     691  % & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t \left(    \delta_k [z_t]   \right)  e_{1w}\,e_{2w}   \biggr\}           &&&\\ 
     692  % & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t b_w   \biggr\} 
    679693\end{flalign*} 
    680694therefore, the balance to be satisfied is: 
    681695\begin{flalign*} 
    682            \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\}   
     696  \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\} 
    683697\end{flalign*} 
    684698which is a purely vertical balance: 
    685699\begin{flalign*} 
    686            \sum\limits_{k}  \biggl\{  p_t\;\partial_t (e_{3t}) \biggr\}  \equiv  \sum\limits_{k}  \biggl\{  p_w\, \partial_t (e_{3w}) \biggr\}   
     700  \sum\limits_{k}  \biggl\{  p_t\;\partial_t (e_{3t}) \biggr\}  \equiv  \sum\limits_{k}  \biggl\{  p_w\, \partial_t (e_{3w}) \biggr\} 
    687701\end{flalign*} 
    688702Defining $p_w = \overline{p_t}^{\,k+1/2}$ 
     
    690704%gm comment 
    691705\gmcomment{ 
    692 \begin{flalign*} 
    693  \sum\limits_{i,j,k} \biggl\{   p_t\;\partial_t b_t   \biggr\}                                &&&\\ 
    694  % 
    695  & \equiv     \sum\limits_{i,j,k} \biggl\{  \frac{1}{e_{3t}} \delta_k [p_w]\;\partial_t (z_t) \,b_w    \biggr\}           &&&\\ 
    696  & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t \left(    \delta_{k+1/2} [z_t]   \right)  e_{1w}\,e_{2w}   \biggr\}           &&&\\ 
    697  & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t b_w   \biggr\}           
    698 \end{flalign*} 
    699  
    700  
    701 \begin{flalign*} 
    702 \int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv 
    703 \equiv&  \sum\limits_{i,j,k}   \biggl\{  \frac{1}{e_{3t}} \frac{\partial e_{3t}}{\partial t} p   \biggr\} \; b_t   &&&\\ 
    704 \equiv&  \sum\limits_{i,j,k}   \biggl\{      \biggr\} \; b_t   &&&\\ 
    705 \end{flalign*} 
    706  
    707 % 
    708 \begin{flalign*} 
    709 \equiv& - \int_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
    710    + \int\limits_D g\, \rho \; \frac{\partial z}{\partial t}  \;dv     &&& \\ 
    711 \end{flalign*} 
    712 % 
     706  \begin{flalign*} 
     707    \sum\limits_{i,j,k} \biggl\{   p_t\;\partial_t b_t   \biggr\}                                &&&\\ 
     708    % 
     709    & \equiv     \sum\limits_{i,j,k} \biggl\{  \frac{1}{e_{3t}} \delta_k [p_w]\;\partial_t (z_t) \,b_w    \biggr\}           &&&\\ 
     710    & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t \left(    \delta_{k+1/2} [z_t]   \right)  e_{1w}\,e_{2w}   \biggr\}           &&&\\ 
     711    & \equiv     \sum\limits_{i,j,k} \biggl\{   p_w\;\partial_t b_w   \biggr\} 
     712  \end{flalign*} 
     713 
     714  \begin{flalign*} 
     715    \int\limits_D   \rho \, g \, \frac{\partial z }{\partial t} \;dv 
     716    \equiv&  \sum\limits_{i,j,k}   \biggl\{  \frac{1}{e_{3t}} \frac{\partial e_{3t}}{\partial t} p   \biggr\} \; b_t   &&&\\ 
     717    \equiv&  \sum\limits_{i,j,k}   \biggl\{      \biggr\} \; b_t   &&&\\ 
     718  \end{flalign*} 
     719 
     720  % 
     721  \begin{flalign*} 
     722    \equiv& - \int_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv 
     723    + \int\limits_D g\, \rho \; \frac{\partial z}{\partial t}  \;dv     &&& \\ 
     724  \end{flalign*} 
     725  % 
    713726} 
    714727%end gm comment 
    715  
    716728 
    717729Note that this property strongly constrains the discrete expression of both the depth of $T-$points and 
     
    719731Nevertheless, it is almost never satisfied since a linear equation of state is rarely used. 
    720732 
    721  
    722  
    723  
    724  
    725  
    726  
    727733% ================================================================ 
    728734% Discrete Total energy Conservation : flux form 
     
    739745The discrete form of the total energy conservation, \autoref{eq:Tot_Energy}, is given by: 
    740746\begin{flalign*} 
    741 \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  \\ 
     747  \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  \\ 
    742748\end{flalign*} 
    743749which in flux form, it leads to: 
    744750\begin{flalign*} 
    745                         \sum\limits_{i,j,k} \biggl\{  \frac{u    }{e_{3u}}\,\frac{\partial (e_{3u}u)}{\partial t} \,b_u  
    746                                                              +  \frac{v    }{e_{3v}}\,\frac{\partial (e_{3v}v)}{\partial t} \,b_v  \biggr\} 
    747 &  -  \frac{1}{2} \sum\limits_{i,j,k} \biggl\{  \frac{u^2}{e_{3u}}\frac{\partial    e_{3u}    }{\partial t} \,b_u  
    748                                                              +  \frac{v^2}{e_{3v}}\frac{\partial    e_{3v}    }{\partial t} \,b_v   \biggr\}      \\ 
    749 &= - \sum\limits_{i,j,k} \biggl\{ \frac{1}{e_3t}\frac{\partial e_{3t} \rho}{\partial t} \, g \, z_t \,b_t  \biggr\}  
    750      - \sum\limits_{i,j,k} \biggl\{ \rho \,g\,\frac{\partial z_t}{\partial t} \,b_t  \biggr\}                                    \\ 
     751  \sum\limits_{i,j,k} \biggl\{  \frac{u    }{e_{3u}}\,\frac{\partial (e_{3u}u)}{\partial t} \,b_u 
     752  +  \frac{v    }{e_{3v}}\,\frac{\partial (e_{3v}v)}{\partial t} \,b_v  \biggr\} 
     753  &  -  \frac{1}{2} \sum\limits_{i,j,k} \biggl\{  \frac{u^2}{e_{3u}}\frac{\partial    e_{3u}    }{\partial t} \,b_u 
     754  +  \frac{v^2}{e_{3v}}\frac{\partial    e_{3v}    }{\partial t} \,b_v   \biggr\} \\ 
     755  &= - \sum\limits_{i,j,k} \biggl\{ \frac{1}{e_3t}\frac{\partial e_{3t} \rho}{\partial t} \, g \, z_t \,b_t  \biggr\} 
     756  - \sum\limits_{i,j,k} \biggl\{ \rho \,g\,\frac{\partial z_t}{\partial t} \,b_t  \biggr\} \\ 
    751757\end{flalign*} 
    752758 
     
    771777This altered Coriolis parameter is discretised at an f-point. 
    772778It is given by: 
    773 \begin{equation*} 
    774 f+\frac{1} {e_1 e_2 } \left( v \frac{\partial e_2 } {\partial i} - u \frac{\partial e_1 } {\partial j}\right)\; 
    775 \equiv \; 
    776 f+\frac{1} {e_{1f}\,e_{2f}} \left( \overline v^{\,i+1/2} \delta_{i+1/2} \left[ e_{2u} \right]  
    777                                                -\overline u^{\,j+1/2} \delta_{j+1/2} \left[ e_{1u}  \right] \right) 
    778 \end{equation*} 
     779\[ 
     780  f+\frac{1} {e_1 e_2 } \left( v \frac{\partial e_2 } {\partial i} - u \frac{\partial e_1 } {\partial j}\right)\; 
     781  \equiv \; 
     782  f+\frac{1} {e_{1f}\,e_{2f}} \left( \overline v^{\,i+1/2} \delta_{i+1/2} \left[ e_{2u} \right] 
     783    -\overline u^{\,j+1/2} \delta_{j+1/2} \left[ e_{1u}  \right] \right) 
     784\] 
    779785 
    780786Either the ENE or EEN scheme is then applied to obtain the vorticity term in flux form. 
     
    793799Because of the centered second order scheme, it conserves the horizontal kinetic energy, that is: 
    794800 
    795 \begin{equation} \label{eq:C_ADV_KE_flux} 
    796  -  \int_D \textbf{U}_h \cdot     \left(                 {{\begin{array} {*{20}c} 
    797 \nabla \cdot \left( \textbf{U}\,u \right) \hfill \\ 
    798 \nabla \cdot \left( \textbf{U}\,v \right) \hfill \\       \end{array}} }           \right)   \;dv  
    799 -   \frac{1}{2} \int_D {  {\textbf{U}_h}^2 \frac{1}{e_3} \frac{\partial  e_3 }{\partial t} \;dv } =\;0 
     801\begin{equation} 
     802  \label{eq:C_ADV_KE_flux} 
     803  -  \int_D \textbf{U}_h \cdot     \left(                 {{ 
     804        \begin{array} {*{20}c} 
     805          \nabla \cdot \left( \textbf{U}\,u \right) \hfill \\ 
     806          \nabla \cdot \left( \textbf{U}\,v \right) \hfill \\ 
     807        \end{array} 
     808      } }           \right)   \;dv 
     809  -   \frac{1}{2} \int_D {  {\textbf{U}_h}^2 \frac{1}{e_3} \frac{\partial  e_3 }{\partial t} \;dv } =\;0 
    800810\end{equation} 
    801811 
     
    803813($i.e.$ just the the terms associated with the i-component of the advection): 
    804814\begin{flalign*} 
    805 &  - \int_D u \cdot \nabla \cdot \left(   \textbf{U}\,u   \right) \; dv   \\ 
    806 % 
    807 \equiv& - \sum\limits_{i,j,k} \biggl\{    \frac{1} {b_u}    \biggl(    
    808       \delta_{i+1/2}  \left[   \overline {U}^{\,i}      \;\overline u^{\,i}          \right]    
    809    + \delta_j           \left[   \overline {V}^{\,i+1/2}\;\overline u^{\,j+1/2}   \right]    
    810    + \delta_k          \left[   \overline {W}^{\,i+1/2}\;\overline u^{\,k+1/2} \right]  \biggr)   \;   \biggr\} \, b_u \;u &&&  \\  
    811 % 
    812 \equiv& - \sum\limits_{i,j,k}  
    813    \biggl\{  
    814       \delta_{i+1/2} \left[   \overline {U}^{\,i}\;  \overline u^{\,i}  \right] 
    815    + \delta_j          \left[   \overline {V}^{\,i+1/2}\;\overline u^{\,j+1/2}   \right] 
    816    + \delta_k         \left[   \overline {W}^{\,i+12}\;\overline u^{\,k+1/2}  \right] 
    817       \; \biggr\} \; u     \\ 
    818 % 
    819 \equiv& + \sum\limits_{i,j,k} 
    820    \biggl\{  
    821       \overline {U}^{\,i}\;   \overline u^{\,i}    \delta_i \left[ u \right]  
    822         + \overline {V}^{\,i+1/2}\; \overline u^{\,j+1/2}   \delta_{j+1/2} \left[ u \right]  
    823         + \overline {W}^{\,i+1/2}\; \overline u^{\,k+1/2}   \delta_{k+1/2}    \left[ u \right]     \biggr\}     && \\ 
    824 % 
    825 \equiv& + \frac{1}{2} \sum\limits_{i,j,k}    \biggl\{  
    826        \overline{U}^{\,i}     \delta_i       \left[ u^2 \right]  
    827     + \overline{V}^{\,i+1/2}  \delta_{j+/2}  \left[ u^2 \right] 
    828     + \overline{W}^{\,i+1/2}  \delta_{k+1/2}    \left[ u^2 \right]      \biggr\} && \\ 
    829 % 
    830 \equiv& -  \sum\limits_{i,j,k}    \frac{1}{2}   \bigg\{  
    831        U  \; \delta_{i+1/2}    \left[ \overline {u^2}^{\,i} \right] 
    832          + V  \; \delta_{j+1/2}    \left[ \overline {u^2}^{\,i} \right] 
    833     + W \; \delta_{k+1/2}   \left[ \overline {u^2}^{\,i} \right]     \biggr\}    &&& \\ 
    834 % 
    835 \equiv& - \sum\limits_{i,j,k}  \frac{1}{2}  \overline {u^2}^{\,i}     \biggl\{  
    836       \delta_{i+1/2}    \left[ U  \right] 
    837    + \delta_{j+1/2}  \left[ V  \right] 
    838    + \delta_{k+1/2}  \left[ W \right]     \biggr\}    &&& \\ 
    839 % 
    840 \equiv& + \sum\limits_{i,j,k}  \frac{1}{2}  \overline {u^2}^{\,i}  
    841    \biggl\{     \left(   \frac{1}{e_{3t}} \frac{\partial e_{3t}}{\partial t}   \right) \; b_t     \biggr\}    &&& \\ 
     815  &  - \int_D u \cdot \nabla \cdot \left(   \textbf{U}\,u   \right) \; dv   \\ 
     816  % 
     817  \equiv& - \sum\limits_{i,j,k} \biggl\{    \frac{1} {b_u}    \biggl( 
     818  \delta_{i+1/2}  \left[   \overline {U}^{\,i}      \;\overline u^{\,i}          \right] 
     819  + \delta_j           \left[   \overline {V}^{\,i+1/2}\;\overline u^{\,j+1/2}   \right] 
     820  + \delta_k          \left[   \overline {W}^{\,i+1/2}\;\overline u^{\,k+1/2} \right]  \biggr)   \;   \biggr\} \, b_u \;u &&&  \\ 
     821  % 
     822  \equiv& - \sum\limits_{i,j,k} 
     823  \biggl\{ 
     824  \delta_{i+1/2} \left[   \overline {U}^{\,i}\;  \overline u^{\,i}  \right] 
     825  + \delta_j          \left[   \overline {V}^{\,i+1/2}\;\overline u^{\,j+1/2}   \right] 
     826  + \delta_k         \left[   \overline {W}^{\,i+12}\;\overline u^{\,k+1/2}  \right] 
     827  \; \biggr\} \; u     \\ 
     828  % 
     829  \equiv& + \sum\limits_{i,j,k} 
     830  \biggl\{ 
     831  \overline {U}^{\,i}\; \overline u^{\,i}    \delta_i \left[ u \right] 
     832  + \overline {V}^{\,i+1/2}\; \overline u^{\,j+1/2}   \delta_{j+1/2} \left[ u \right] 
     833  + \overline {W}^{\,i+1/2}\; \overline u^{\,k+1/2}   \delta_{k+1/2}    \left[ u \right]     \biggr\}     && \\ 
     834  % 
     835  \equiv& + \frac{1}{2} \sum\limits_{i,j,k}    \biggl\{ 
     836  \overline{U}^{\,i}       \delta_i       \left[ u^2 \right] 
     837  + \overline{V}^{\,i+1/2}    \delta_{j+/2}  \left[ u^2 \right] 
     838  + \overline{W}^{\,i+1/2}    \delta_{k+1/2}    \left[ u^2 \right]      \biggr\} && \\ 
     839  % 
     840  \equiv& -  \sum\limits_{i,j,k}    \frac{1}{2}   \bigg\{ 
     841  U  \; \delta_{i+1/2}    \left[ \overline {u^2}^{\,i} \right] 
     842  + V  \; \delta_{j+1/2}    \left[ \overline {u^2}^{\,i} \right] 
     843  + W \; \delta_{k+1/2}   \left[ \overline {u^2}^{\,i} \right]     \biggr\}    &&& \\ 
     844  % 
     845  \equiv& - \sum\limits_{i,j,k}  \frac{1}{2}  \overline {u^2}^{\,i}     \biggl\{ 
     846  \delta_{i+1/2}  \left[ U  \right] 
     847  + \delta_{j+1/2}   \left[ V  \right] 
     848  + \delta_{k+1/2}   \left[ W \right]     \biggr\}    &&& \\ 
     849  % 
     850  \equiv& + \sum\limits_{i,j,k}  \frac{1}{2}  \overline {u^2}^{\,i} 
     851  \biggl\{     \left(   \frac{1}{e_{3t}} \frac{\partial e_{3t}}{\partial t}   \right) \; b_t     \biggr\}    &&& \\ 
    842852\end{flalign*} 
    843853Applying similar manipulation applied to the second term of the scalar product leads to: 
    844 \begin{equation*} 
    845  -  \int_D \textbf{U}_h \cdot     \left(                 {{\begin{array} {*{20}c} 
    846 \nabla \cdot \left( \textbf{U}\,u \right) \hfill \\ 
    847 \nabla \cdot \left( \textbf{U}\,v \right) \hfill \\       \end{array}} }           \right)   \;dv      
    848 \equiv + \sum\limits_{i,j,k}  \frac{1}{2}  \left( \overline {u^2}^{\,i} + \overline {v^2}^{\,j} \right) 
    849    \biggl\{     \left(   \frac{1}{e_{3t}} \frac{\partial e_{3t}}{\partial t}   \right) \; b_t     \biggr\}     
    850 \end{equation*} 
     854\[ 
     855  -  \int_D \textbf{U}_h \cdot     \left(                 {{ 
     856        \begin{array} {*{20}c} 
     857          \nabla \cdot \left( \textbf{U}\,u \right) \hfill \\ 
     858          \nabla \cdot \left( \textbf{U}\,v \right) \hfill \\ 
     859        \end{array} 
     860      } }           \right)   \;dv 
     861  \equiv + \sum\limits_{i,j,k}  \frac{1}{2}  \left( \overline {u^2}^{\,i} + \overline {v^2}^{\,j} \right) 
     862  \biggl\{     \left(   \frac{1}{e_{3t}} \frac{\partial e_{3t}}{\partial t}   \right) \; b_t     \biggr\} 
     863\] 
    851864which is the discrete form of $ \frac{1}{2} \int_D u \cdot \nabla \cdot \left(   \textbf{U}\,u   \right) \; dv $. 
    852865\autoref{eq:C_ADV_KE_flux} is thus satisfied. 
    853  
    854866 
    855867When the UBS scheme is used to evaluate the flux form momentum advection, 
     
    857869The horizontal kinetic energy is not conserved, but forced to decay ($i.e.$ the scheme is diffusive).  
    858870 
    859  
    860  
    861  
    862  
    863  
    864  
    865  
    866  
    867  
    868871% ================================================================ 
    869872% Discrete Enstrophy Conservation 
     
    872875\label{sec:C.4} 
    873876 
    874  
    875877% ------------------------------------------------------------------------------------------------------------- 
    876878%       Vorticity Term with ENS scheme 
     
    880882 
    881883In the ENS scheme, the vorticity term is descretized as follows: 
    882 \begin{equation} \tag{\ref{eq:dynvor_ens}} 
    883 \left\{   \begin{aligned} 
    884 +\frac{1}{e_{1u}} & \overline{q}^{\,i}  & {\overline{ \overline{\left( e_{1v}\,e_{3v}\;  v \right) } } }^{\,i, j+1/2}    \\ 
    885 - \frac{1}{e_{2v}} & \overline{q}^{\,j}  & {\overline{ \overline{\left( e_{2u}\,e_{3u}\; u \right) } } }^{\,i+1/2, j}   
    886 \end{aligned}  \right. 
     884\begin{equation} 
     885  \tag{\ref{eq:dynvor_ens}} 
     886  \left\{ 
     887    \begin{aligned} 
     888      +\frac{1}{e_{1u}} & \overline{q}^{\,i}  & {\overline{ \overline{\left( e_{1v}\,e_{3v}\;  v \right) } } }^{\,i, j+1/2}    \\ 
     889      - \frac{1}{e_{2v}} & \overline{q}^{\,j}  & {\overline{ \overline{\left( e_{2u}\,e_{3u}\; u \right) } } }^{\,i+1/2, j} 
     890    \end{aligned} 
     891  \right. 
    887892\end{equation}  
    888893 
     
    892897( \autoref{eq:DOM_mi_adj} and \autoref{eq:DOM_di_adj}), 
    893898it can be shown that: 
    894 \begin{equation} \label{eq:C_1.1} 
    895 \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 
     899\begin{equation} 
     900  \label{eq:C_1.1} 
     901  \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 
    896902\end{equation} 
    897903where $dv=e_1\,e_2\,e_3 \; di\,dj\,dk$ is the volume element. 
    898904Indeed, using \autoref{eq:dynvor_ens}, 
    899905the discrete form of the right hand side of \autoref{eq:C_1.1} can be transformed as follow: 
    900 \begin{flalign*}  
    901 &\int_D q \,\; \textbf{k} \cdot \frac{1} {e_3 } \nabla \times  
    902    \left(  e_3 \, q \; \textbf{k} \times  \textbf{U}_h   \right)\;   dv       \\ 
    903 % 
    904 & \qquad {\begin{array}{*{20}l}  
    905 &\equiv \sum\limits_{i,j,k}  
    906 q \ \left\{  \delta_{i+1/2}  \left[ - \,\overline {q}^{\,i}\;  \overline{\overline  U }^{\,i,j+1/ 2} \right]   
    907              - \delta_{j+1/2} \left[    \overline {q}^{\,j}\;  \overline{\overline  V }^{\,i+1/2, j} \right]     \right\}    \\  
    908 % 
    909 &\equiv \sum\limits_{i,j,k}  
    910    \left\{   \delta_i [q] \; \overline{q}^{\,i} \; \overline{  \overline U  }^{\,i,j+1/2}  
    911       + \delta_j [q] \; \overline{q}^{\,j} \; \overline{\overline V }^{\,i+1/2,j}        \right\}       &&  \\  
    912 % 
    913 &\equiv \,\frac{1} {2} \sum\limits_{i,j,k}   
    914    \left\{         \delta_i  \left[ q^2 \right] \; \overline{\overline U }^{\,i,j+1/2}  
    915             + \delta_j  \left[ q^2 \right] \; \overline{\overline V }^{\,i+1/2,j}      \right\}    &&  \\  
    916 % 
    917 &\equiv - \frac{1} {2} \sum\limits_{i,j,k}   q^2 \; 
    918    \left\{    \delta_{i+1/2}   \left[   \overline{\overline{ U }}^{\,i,j+1/2}    \right]   
    919             + \delta_{j+1/2}  \left[   \overline{\overline{ V }}^{\,i+1/2,j}     \right]    \right\}    && \\  
    920 \end{array} }      
    921 % 
    922 \allowdisplaybreaks 
    923 \intertext{ Since $\overline {\;\cdot \;} $ and $\delta $ operators commute: $\delta_{i+1/2}  
    924 \left[ {\overline a^{\,i}} \right] = \overline {\delta_i \left[ a \right]}^{\,i+1/2}$,  
    925 and introducing the horizontal divergence $\chi $, it becomes: } 
    926 \allowdisplaybreaks 
    927 % 
    928 & \qquad {\begin{array}{*{20}l}  
    929 &\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}  
    930 \quad \equiv 0 && 
    931 \end{array} }      
     906\begin{flalign*} 
     907  &\int_D q \,\; \textbf{k} \cdot \frac{1} {e_3 } \nabla \times 
     908  \left(  e_3 \, q \; \textbf{k} \times  \textbf{U}_h   \right)\;   dv \\ 
     909  % 
     910  & \qquad 
     911  { 
     912    \begin{array}{*{20}l} 
     913      &\equiv \sum\limits_{i,j,k} 
     914        q \ \left\{  \delta_{i+1/2}  \left[ - \,\overline {q}^{\,i}\;  \overline{\overline  U }^{\,i,j+1/ 2} \right] 
     915        - \delta_{j+1/2} \left[   \overline {q}^{\,j}\;  \overline{\overline  V }^{\,i+1/2, j} \right]     \right\}    \\ 
     916      % 
     917      &\equiv \sum\limits_{i,j,k} 
     918        \left\{   \delta_i [q] \; \overline{q}^{\,i} \; \overline{  \overline U  }^{\,i,j+1/2} 
     919        + \delta_j [q] \; \overline{q}^{\,j} \; \overline{\overline V }^{\,i+1/2,j}        \right\}       &&  \\ 
     920      % 
     921      &\equiv \,\frac{1} {2} \sum\limits_{i,j,k} 
     922        \left\{         \delta_i  \left[ q^2 \right] \; \overline{\overline U }^{\,i,j+1/2} 
     923        + \delta_j  \left[ q^2 \right] \; \overline{\overline V }^{\,i+1/2,j}      \right\}    &&  \\ 
     924      % 
     925      &\equiv - \frac{1} {2} \sum\limits_{i,j,k}   q^2 \; 
     926        \left\{    \delta_{i+1/2}   \left[   \overline{\overline{ U }}^{\,i,j+1/2}    \right] 
     927        + \delta_{j+1/2}  \left[   \overline{\overline{ V }}^{\,i+1/2,j}     \right]    \right\}    && \\ 
     928    \end{array} 
     929  } 
     930  % 
     931  \allowdisplaybreaks 
     932  \intertext{ Since $\overline {\;\cdot \;} $ and $\delta $ operators commute: $\delta_{i+1/2} 
     933    \left[ {\overline a^{\,i}} \right] = \overline {\delta_i \left[ a \right]}^{\,i+1/2}$, 
     934    and introducing the horizontal divergence $\chi $, it becomes: } 
     935  \allowdisplaybreaks 
     936  % 
     937  & \qquad { 
     938    \begin{array}{*{20}l} 
     939      &\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} 
     940        \quad \equiv 0 && 
     941    \end{array} 
     942  } 
    932943\end{flalign*} 
    933944The later equality is obtain only when the flow is horizontally non-divergent, $i.e.$ $\chi$=$0$.  
    934  
    935945 
    936946% ------------------------------------------------------------------------------------------------------------- 
     
    941951 
    942952With the EEN scheme, the vorticity terms are represented as:  
    943 \begin{equation} \tag{\ref{eq:dynvor_een}} 
    944 \left\{ {    \begin{aligned} 
    945  +q\,e_3 \, v  &\equiv +\frac{1}{e_{1u} }   \sum_{\substack{i_p,\,k_p}}  
    946                          {^{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}   \\ 
    947  - q\,e_3 \, u     &\equiv -\frac{1}{e_{2v} }    \sum_{\substack{i_p,\,k_p}}  
    948                          {^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}   \\ 
    949 \end{aligned}   } \right. 
     953\begin{equation} 
     954  \tag{\ref{eq:dynvor_een}} 
     955  \left\{ { 
     956      \begin{aligned} 
     957        +q\,e_3 \, v    &\equiv +\frac{1}{e_{1u} }   \sum_{\substack{i_p,\,k_p}} 
     958        {^{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}   \\ 
     959        - q\,e_3 \, u     &\equiv -\frac{1}{e_{2v} }    \sum_{\substack{i_p,\,k_p}} 
     960        {^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}   \\ 
     961      \end{aligned} 
     962    } \right. 
    950963\end{equation}  
    951964where the indices $i_p$ and $k_p$ take the following values:  
    952965$i_p = -1/2$ or $1/2$ and $j_p = -1/2$ or $1/2$, 
    953966and the vorticity triads, ${^i_j}\mathbb{Q}^{i_p}_{j_p}$, defined at $T$-point, are given by:  
    954 \begin{equation} \tag{\ref{eq:Q_triads}} 
    955 _i^j \mathbb{Q}^{i_p}_{j_p} 
    956 = \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) 
     967\begin{equation} 
     968  \tag{\ref{eq:Q_triads}} 
     969  _i^j \mathbb{Q}^{i_p}_{j_p} 
     970  = \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) 
    957971\end{equation} 
    958  
    959972 
    960973This formulation does conserve the potential enstrophy for a horizontally non-divergent flow ($i.e.$ $\chi=0$).  
     
    965978this triad only can be transformed as follow: 
    966979 
    967 \begin{flalign*}  
    968 &\int_D {q\,\;{\textbf{k}}\cdot \frac{1} {e_3} \nabla \times \left( {e_3 \, q \;{\textbf{k}}\times {\textbf{U}}_h } \right)\;dv} \\ 
    969 % 
    970 \equiv& \sum\limits_{i,j,k}  
    971  {q} \    \biggl\{ \;\; 
    972    \delta_{i+1/2} \left[   -\, {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; U^{i+1/2}_{j}}    \right]   
    973       - \delta_{j+1/2} \left[       {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; V^{i}_{j+1/2}}    \right]  
    974    \;\;\biggr\}        &&  \\  
    975 % 
    976 \equiv& \sum\limits_{i,j,k}  
    977    \biggl\{   \delta_i [q] \  {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; U^{i+1/2}_{j}} 
    978          + \delta_j [q] \  {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; V^{i}_{j+1/2}}   \biggr\} 
    979       && \\  
    980 % 
    981 ... & &&\\ 
    982 &Demonstation \ to \ be \ done... &&\\ 
    983 ... & &&\\ 
    984 % 
    985 \equiv& \frac{1} {2} \sum\limits_{i,j,k}   
    986    \biggl\{ \delta_i    \Bigl[    \left(  {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2   \Bigr]\; 
    987          \overline{\overline {U}}^{\,i,j+1/2}  
    988             + \delta_j  \Bigl[    \left( {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2     \Bigr]\;  
    989          \overline{\overline {V}}^{\,i+1/2,j}  
    990    \biggr\}  
    991    &&  \\  
    992 % 
    993 \equiv& - \frac{1} {2} \sum\limits_{i,j,k}   \left( {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2\; 
    994    \biggl\{    \delta_{i+1/2}  
    995          \left[   \overline{\overline {U}}^{\,i,j+1/2}    \right]   
    996                + \delta_{j+1/2} 
    997       \left[   \overline{\overline {V}}^{\,i+1/2,j}     \right]   
    998    \biggr\}    && \\  
    999 % 
    1000 \equiv& \sum\limits_{i,j,k} - \frac{1} {2} \left( {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2 
    1001                                                             \; \overline{\overline{ b_t^{}\, \chi}}^{\,i+1/2,\,j+1/2}  &&\\ 
    1002 % 
    1003 \ \ \equiv& \ 0     &&\\ 
    1004 \end{flalign*} 
    1005  
    1006  
    1007  
    1008  
     980\begin{flalign*} 
     981  &\int_D {q\,\;{\textbf{k}}\cdot \frac{1} {e_3} \nabla \times \left( {e_3 \, q \;{\textbf{k}}\times {\textbf{U}}_h } \right)\;dv} \\ 
     982  % 
     983  \equiv& \sum\limits_{i,j,k} 
     984  {q} \    \biggl\{ \;\; 
     985  \delta_{i+1/2} \left[   -\, {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; U^{i+1/2}_{j}}    \right] 
     986  - \delta_{j+1/2} \left[       {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; V^{i}_{j+1/2}}    \right] 
     987  \;\;\biggr\}        &&  \\ 
     988  % 
     989  \equiv& \sum\limits_{i,j,k} 
     990  \biggl\{   \delta_i [q] \  {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; U^{i+1/2}_{j}} 
     991  + \delta_j [q] \  {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}  \; V^{i}_{j+1/2}}   \biggr\} 
     992  && \\ 
     993  % 
     994  ... & &&\\ 
     995  &Demonstation \ to \ be \ done... &&\\ 
     996  ... & &&\\ 
     997  % 
     998  \equiv& \frac{1} {2} \sum\limits_{i,j,k} 
     999  \biggl\{  \delta_i    \Bigl[    \left(  {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2   \Bigr]\; 
     1000  \overline{\overline {U}}^{\,i,j+1/2} 
     1001  + \delta_j   \Bigl[    \left( {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2     \Bigr]\; 
     1002  \overline{\overline {V}}^{\,i+1/2,j} 
     1003  \biggr\} 
     1004  &&  \\ 
     1005  % 
     1006  \equiv& - \frac{1} {2} \sum\limits_{i,j,k}    \left( {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2\; 
     1007  \biggl\{    \delta_{i+1/2} 
     1008  \left[   \overline{\overline {U}}^{\,i,j+1/2}    \right] 
     1009  + \delta_{j+1/2} 
     1010  \left[   \overline{\overline {V}}^{\,i+1/2,j}     \right] 
     1011  \biggr\}    && \\ 
     1012  % 
     1013  \equiv& \sum\limits_{i,j,k} - \frac{1} {2} \left( {{^i_j}\mathbb{Q}^{+1/2}_{+1/2}} \right)^2 
     1014  \; \overline{\overline{ b_t^{}\, \chi}}^{\,i+1/2,\,j+1/2}  &&\\ 
     1015  % 
     1016  \ \ \equiv& \ 0     &&\\ 
     1017\end{flalign*} 
    10091018 
    10101019% ================================================================ 
     
    10131022\section{Conservation properties on tracers} 
    10141023\label{sec:C.5} 
    1015  
    10161024 
    10171025All the numerical schemes used in NEMO are written such that the tracer content is conserved by 
     
    10321040 
    10331041conservation of a tracer, $T$: 
    1034 \begin{equation*} 
    1035 \frac{\partial }{\partial t} \left(   \int_D {T\;dv}   \right)  
    1036 =  \int_D { \frac{1}{e_3}\frac{\partial \left( e_3 \, T \right)}{\partial t} \;dv }=0 
    1037 \end{equation*} 
     1042\[ 
     1043  \frac{\partial }{\partial t} \left(   \int_D {T\;dv}   \right) 
     1044  =  \int_D { \frac{1}{e_3}\frac{\partial \left( e_3 \, T \right)}{\partial t} \;dv }=0 
     1045\] 
    10381046 
    10391047conservation of its variance: 
    1040 \begin{flalign*}  
    1041 \frac{\partial }{\partial t} \left( \int_D {\frac{1}{2} T^2\;dv} \right) 
    1042 =&  \int_D { \frac{1}{e_3} Q      \frac{\partial \left( e_3 \, T \right) }{\partial t} \;dv }   
    1043 -   \frac{1}{2} \int_D {  T^2 \frac{1}{e_3} \frac{\partial  e_3 }{\partial t} \;dv } 
    1044 \end{flalign*} 
    1045  
     1048\begin{flalign*} 
     1049  \frac{\partial }{\partial t} \left( \int_D {\frac{1}{2} T^2\;dv} \right) 
     1050  =&  \int_D { \frac{1}{e_3} Q      \frac{\partial \left( e_3 \, T \right) }{\partial t} \;dv } 
     1051  -   \frac{1}{2} \int_D {  T^2 \frac{1}{e_3} \frac{\partial  e_3 }{\partial t} \;dv } 
     1052\end{flalign*} 
    10461053 
    10471054Whatever the advection scheme considered it conserves of the tracer content as 
     
    10511058the conservation of the tracer content due to the advection tendency is obtained as follows:  
    10521059\begin{flalign*} 
    1053 &\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    &&&\\ 
    1054 &\equiv - \sum\limits_{i,j,k}    \biggl\{ 
    1055     \frac{1} {b_t}  \left(  \delta_i    \left[   U \;\tau_u   \right] 
    1056                                 + \delta_j    \left[   V  \;\tau_v   \right] \right)  
    1057    + \frac{1} {e_{3t}} \delta_k \left[ w\;\tau_w \right]    \biggl\}  b_t   &&&\\ 
    1058 % 
    1059 &\equiv - \sum\limits_{i,j,k}     \left\{ 
    1060        \delta_i  \left[   U \;\tau_u   \right] 
    1061          + \delta_j  \left[   V  \;\tau_v   \right] 
     1060  &\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    &&&\\ 
     1061  &\equiv - \sum\limits_{i,j,k}    \biggl\{ 
     1062  \frac{1} {b_t}  \left(  \delta_i    \left[   U \;\tau_u   \right] 
     1063    + \delta_j    \left[   V  \;\tau_v   \right] \right) 
     1064  + \frac{1} {e_{3t}} \delta_k \left[ w\;\tau_w \right]    \biggl\}  b_t   &&&\\ 
     1065  % 
     1066  &\equiv - \sum\limits_{i,j,k}     \left\{ 
     1067    \delta_i  \left[   U \;\tau_u   \right] 
     1068    + \delta_j  \left[   V  \;\tau_v   \right] 
    10621069    + \delta_k \left[ W \;\tau_w \right] \right\}   && \\ 
    1063 &\equiv 0 &&& 
     1070  &\equiv 0 &&& 
    10641071\end{flalign*} 
    10651072 
     
    10681075It can be demonstarted as follows: 
    10691076\begin{flalign*} 
    1070 &\int_D { \frac{1}{e_3} Q      \frac{\partial \left( e_3 \, T \right) }{\partial t} \;dv } 
    1071 = - \int\limits_D \tau\;\nabla \cdot \left( T\; \textbf{U} \right)\;dv &&&\\ 
    1072 \equiv& - \sum\limits_{i,j,k} T\; 
    1073    \left\{ 
    1074       \delta_i  \left[ U  \overline T^{\,i+1/2}  \right] 
    1075    + \delta_j  \left[ V  \overline T^{\,j+1/2}  \right] 
    1076    + \delta_k \left[ W \overline T^{\,k+1/2} \right]          \right\} && \\ 
    1077 \equiv& + \sum\limits_{i,j,k}  
    1078    \left\{     U  \overline T^{\,i+1/2} \,\delta_{i+1/2}  \left[ T \right]  
    1079                  +  V  \overline T^{\,j+1/2} \;\delta_{j+1/2}  \left[ T \right] 
    1080                  +  W \overline T^{\,k+1/2}\;\delta_{k+1/2} \left[ T \right]     \right\}      &&\\ 
    1081 \equiv&  + \frac{1} {2}  \sum\limits_{i,j,k} 
    1082    \Bigl\{   U  \;\delta_{i+1/2} \left[ T^2 \right] 
    1083                  + V  \;\delta_{j+1/2}  \left[ T^2 \right] 
    1084                  + W \;\delta_{k+1/2} \left[ T^2 \right]   \Bigr\}     && \\  
    1085 \equiv& - \frac{1} {2}  \sum\limits_{i,j,k} T^2 
    1086    \Bigl\{    \delta_i  \left[ U  \right] 
    1087                   + \delta_j  \left[ V  \right] 
    1088                   + \delta_k \left[ W \right]     \Bigr\}      &&&  \\ 
    1089 \equiv& + \frac{1} {2}  \sum\limits_{i,j,k} T^2 
    1090    \Bigl\{   \frac{1}{e_{3t}} \frac{\partial e_{3t}\,T }{\partial t}     \Bigr\}      &&& \\ 
     1077  &\int_D { \frac{1}{e_3} Q      \frac{\partial \left( e_3 \, T \right) }{\partial t} \;dv } 
     1078  = - \int\limits_D \tau\;\nabla \cdot \left( T\; \textbf{U} \right)\;dv &&&\\ 
     1079  \equiv& - \sum\limits_{i,j,k} T\; 
     1080  \left\{ 
     1081    \delta_i  \left[ U  \overline T^{\,i+1/2}  \right] 
     1082    + \delta_j  \left[ V  \overline T^{\,j+1/2}  \right] 
     1083    + \delta_k \left[ W \overline T^{\,k+1/2} \right]          \right\} && \\ 
     1084  \equiv& + \sum\limits_{i,j,k} 
     1085  \left\{     U  \overline T^{\,i+1/2} \,\delta_{i+1/2}  \left[ T \right] 
     1086    +  V  \overline T^{\,j+1/2} \;\delta_{j+1/2}  \left[ T \right] 
     1087    +  W \overline T^{\,k+1/2}\;\delta_{k+1/2} \left[ T \right]     \right\}      &&\\ 
     1088  \equiv&  + \frac{1} {2}  \sum\limits_{i,j,k} 
     1089  \Bigl\{   U  \;\delta_{i+1/2} \left[ T^2 \right] 
     1090  + V  \;\delta_{j+1/2}  \left[ T^2 \right] 
     1091  + W \;\delta_{k+1/2} \left[ T^2 \right]   \Bigr\}     && \\ 
     1092  \equiv& - \frac{1} {2}  \sum\limits_{i,j,k} T^2 
     1093  \Bigl\{    \delta_i  \left[ U  \right] 
     1094  + \delta_j  \left[ V  \right] 
     1095  + \delta_k \left[ W \right]     \Bigr\}      &&&  \\ 
     1096  \equiv& + \frac{1} {2}  \sum\limits_{i,j,k} T^2 
     1097  \Bigl\{   \frac{1}{e_{3t}} \frac{\partial e_{3t}\,T }{\partial t}     \Bigr\}      &&& \\ 
    10911098\end{flalign*} 
    10921099which is the discrete form of $ \frac{1}{2} \int_D {  T^2 \frac{1}{e_3} \frac{\partial  e_3 }{\partial t} \;dv }$. 
     
    10971104\section{Conservation properties on lateral momentum physics} 
    10981105\label{sec:dynldf_properties} 
    1099  
    11001106 
    11011107The discrete formulation of the horizontal diffusion of momentum ensures 
     
    11221128The lateral momentum diffusion term conserves the potential vorticity: 
    11231129\begin{flalign*} 
    1124 &\int \limits_D \frac{1} {e_3 } \textbf{k} \cdot \nabla \times  
    1125    \Bigl[    \nabla_h  \left( A^{\,lm}\;\chi  \right) 
    1126            - \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)    \Bigr]\;dv   \\  
    1127 %\end{flalign*} 
    1128 %%%%%%%%%% recheck here....  (gm) 
    1129 %\begin{flalign*} 
    1130 =& \int \limits_D  -\frac{1} {e_3 } \textbf{k} \cdot \nabla \times  
    1131    \Bigl[ \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)  \Bigr]\;dv  \\  
    1132 %\end{flalign*} 
    1133 %\begin{flalign*} 
    1134 \equiv& \sum\limits_{i,j} 
    1135    \left\{ 
    1136      \delta_{i+1/2} \left[  \frac {e_{2v}} {e_{1v}\,e_{3v}}  \delta_i \left[ A_f^{\,lm} e_{3f} \zeta  \right]  \right] 
    1137    + \delta_{j+1/2} \left[  \frac {e_{1u}} {e_{2u}\,e_{3u}}  \delta_j \left[ A_f^{\,lm} e_{3f} \zeta  \right]  \right] 
    1138    \right\}     \\  
    1139 % 
    1140 \intertext{Using \autoref{eq:DOM_di_adj}, it follows:} 
    1141 % 
    1142 \equiv& \sum\limits_{i,j,k}  
    1143    -\,\left\{ 
    1144       \frac{e_{2v}} {e_{1v}\,e_{3v}}  \delta_i  \left[ A_f^{\,lm} e_{3f} \zeta  \right]\;\delta_i \left[ 1\right] 
     1130  &\int \limits_D \frac{1} {e_3 } \textbf{k} \cdot \nabla \times 
     1131  \Bigl[    \nabla_h  \left( A^{\,lm}\;\chi  \right) 
     1132  - \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)    \Bigr]\;dv   \\ 
     1133  % \end{flalign*} 
     1134  %%%%%%%%%% recheck here....  (gm) 
     1135  % \begin{flalign*} 
     1136  =& \int \limits_D  -\frac{1} {e_3 } \textbf{k} \cdot \nabla \times 
     1137  \Bigl[ \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)  \Bigr]\;dv  \\ 
     1138  % \end{flalign*} 
     1139  % \begin{flalign*} 
     1140  \equiv& \sum\limits_{i,j} 
     1141  \left\{ 
     1142    \delta_{i+1/2} \left[  \frac {e_{2v}} {e_{1v}\,e_{3v}}  \delta_i \left[ A_f^{\,lm} e_{3f} \zeta  \right]  \right] 
     1143    + \delta_{j+1/2} \left[  \frac {e_{1u}} {e_{2u}\,e_{3u}}  \delta_j \left[ A_f^{\,lm} e_{3f} \zeta  \right]  \right] 
     1144  \right\}   \\ 
     1145  % 
     1146  \intertext{Using \autoref{eq:DOM_di_adj}, it follows:} 
     1147  % 
     1148  \equiv& \sum\limits_{i,j,k} 
     1149  -\,\left\{ 
     1150    \frac{e_{2v}} {e_{1v}\,e_{3v}}  \delta_i \left[ A_f^{\,lm} e_{3f} \zeta  \right]\;\delta_i \left[ 1\right] 
    11451151    + \frac{e_{1u}} {e_{2u}\,e_{3u}}  \delta_j  \left[ A_f^{\,lm} e_{3f} \zeta  \right]\;\delta_j \left[ 1\right] 
    1146    \right\} \quad \equiv 0  
    1147     \\  
     1152  \right\} \quad \equiv 0 
     1153  \\ 
    11481154\end{flalign*} 
    11491155 
     
    11561162The lateral momentum diffusion term dissipates the horizontal kinetic energy: 
    11571163%\begin{flalign*} 
    1158 \begin{equation*} 
    1159 \begin{split} 
    1160 \int_D \textbf{U}_h \cdot  
    1161    \left[ \nabla_h      \right.   &     \left.       \left( A^{\,lm}\;\chi \right)       
    1162    - \nabla_h \times  \left( A^{\,lm}\;\zeta \;\textbf{k} \right)     \right] \; dv    \\ 
    1163 \\  %%% 
    1164 \equiv& \sum\limits_{i,j,k}  
    1165    \left\{ 
    1166      \frac{1} {e_{1u}}               \delta_{i+1/2} \left[  A_T^{\,lm}          \chi     \right] 
    1167    - \frac{1} {e_{2u}\,e_{3u}}  \delta_j           \left[ A_f^{\,lm} e_{3f} \zeta   \right] 
    1168    \right\} \; e_{1u}\,e_{2u}\,e_{3u} \;u     \\ 
    1169 &\;\; +  \left\{ 
    1170       \frac{1} {e_{2u}}             \delta_{j+1/2} \left[ A_T^{\,lm}          \chi    \right]  
    1171    + \frac{1} {e_{1v}\,e_{3v}} \delta_i            \left[ A_f^{\,lm} e_{3f} \zeta  \right]  
    1172    \right\} \; e_{1v}\,e_{2u}\,e_{3v} \;v     \qquad \\  
    1173 \\  %%% 
    1174 \equiv& \sum\limits_{i,j,k}  
    1175    \Bigl\{ 
    1176      e_{2u}\,e_{3u} \;u\;  \delta_{i+1/2} \left[ A_T^{\,lm}           \chi    \right] 
    1177    - e_{1u}             \;u\;  \delta_j           \left[ A_f^{\,lm} e_{3f} \zeta  \right] 
    1178     \Bigl\}  
    1179     \\  
    1180 &\;\; + \Bigl\{ 
    1181       e_{1v}\,e_{3v} \;v\;  \delta_{j+1/2}  \left[ A_T^{\,lm}           \chi    \right] 
    1182    + e_{2v}             \;v\;  \delta_i            \left[ A_f^{\,lm} e_{3f} \zeta  \right] 
    1183    \Bigl\}      \\  
    1184 \\  %%% 
    1185 \equiv& \sum\limits_{i,j,k}  
    1186    - \Bigl( 
    1187      \delta_i   \left[  e_{2u}\,e_{3u} \;u  \right] 
    1188    + \delta_j  \left[  e_{1v}\,e_{3v}  \;v  \right]  
    1189         \Bigr) \;  A_T^{\,lm} \chi   \\  
    1190 &\;\; - \Bigl( 
    1191      \delta_{i+1/2}  \left[  e_{2v}  \;v  \right] 
    1192    - \delta_{j+1/2}  \left[  e_{1u} \;u  \right]  
    1193         \Bigr)\;  A_f^{\,lm} e_{3f} \zeta      \\  
    1194 \\  %%% 
    1195 \equiv& \sum\limits_{i,j,k}  
    1196    - A_T^{\,lm}  \,\chi^2   \;e_{1t}\,e_{2t}\,e_{3t} 
    1197    - A_f ^{\,lm}  \,\zeta^2 \;e_{1f }\,e_{2f }\,e_{3f}   
    1198 \quad \leq 0       \\ 
    1199 \end{split} 
    1200 \end{equation*} 
     1164\[ 
     1165  \begin{split} 
     1166    \int_D \textbf{U}_h \cdot 
     1167    \left[ \nabla_h     \right.   &     \left.       \left( A^{\,lm}\;\chi \right) 
     1168      - \nabla_h \times  \left( A^{\,lm}\;\zeta \;\textbf{k} \right)     \right] \; dv    \\ 
     1169    \\  %%% 
     1170    \equiv& \sum\limits_{i,j,k} 
     1171    \left\{ 
     1172      \frac{1} {e_{1u}}               \delta_{i+1/2} \left[  A_T^{\,lm}          \chi     \right] 
     1173      - \frac{1} {e_{2u}\,e_{3u}}  \delta_j           \left[ A_f^{\,lm} e_{3f} \zeta   \right] 
     1174    \right\} \; e_{1u}\,e_{2u}\,e_{3u} \;u     \\ 
     1175    &\;\; +    \left\{ 
     1176      \frac{1} {e_{2u}}             \delta_{j+1/2} \left[ A_T^{\,lm}          \chi    \right] 
     1177      + \frac{1} {e_{1v}\,e_{3v}} \delta_i            \left[ A_f^{\,lm} e_{3f} \zeta  \right] 
     1178    \right\} \; e_{1v}\,e_{2u}\,e_{3v} \;v     \qquad \\ 
     1179    \\  %%% 
     1180    \equiv& \sum\limits_{i,j,k} 
     1181    \Bigl\{ 
     1182    e_{2u}\,e_{3u} \;u\;  \delta_{i+1/2} \left[ A_T^{\,lm}           \chi    \right] 
     1183    - e_{1u}             \;u\;  \delta_j           \left[ A_f^{\,lm} e_{3f} \zeta  \right] 
     1184    \Bigl\} 
     1185    \\ 
     1186    &\;\; + \Bigl\{ 
     1187    e_{1v}\,e_{3v} \;v\;  \delta_{j+1/2}  \left[ A_T^{\,lm}           \chi    \right] 
     1188    + e_{2v}             \;v\;  \delta_i            \left[ A_f^{\,lm} e_{3f} \zeta  \right] 
     1189    \Bigl\}      \\ 
     1190    \\  %%% 
     1191    \equiv& \sum\limits_{i,j,k} 
     1192    - \Bigl( 
     1193    \delta_i   \left[  e_{2u}\,e_{3u} \;u  \right] 
     1194    + \delta_j  \left[  e_{1v}\,e_{3v}  \;v  \right] 
     1195    \Bigr) \;  A_T^{\,lm} \chi   \\ 
     1196    &\;\; - \Bigl( 
     1197    \delta_{i+1/2}  \left[  e_{2v}  \;v  \right] 
     1198    - \delta_{j+1/2}  \left[  e_{1u} \;u  \right] 
     1199    \Bigr)\;  A_f^{\,lm} e_{3f} \zeta      \\ 
     1200    \\  %%% 
     1201    \equiv& \sum\limits_{i,j,k} 
     1202    - A_T^{\,lm}  \,\chi^2   \;e_{1t}\,e_{2t}\,e_{3t} 
     1203    - A_f ^{\,lm}  \,\zeta^2 \;e_{1f }\,e_{2f }\,e_{3f} 
     1204    \quad \leq 0       \\ 
     1205  \end{split} 
     1206\] 
    12011207 
    12021208% ------------------------------------------------------------------------------------------------------------- 
     
    12081214The lateral momentum diffusion term dissipates the enstrophy when the eddy coefficients are horizontally uniform: 
    12091215\begin{flalign*} 
    1210 &\int\limits_D  \zeta \; \textbf{k} \cdot \nabla \times  
    1211    \left[   \nabla_h \left( A^{\,lm}\;\chi  \right) 
    1212           - \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)   \right]\;dv &&&\\ 
    1213 &\quad = A^{\,lm} \int \limits_D \zeta \textbf{k} \cdot \nabla \times  
    1214    \left[    \nabla_h \times \left( \zeta \; \textbf{k} \right)   \right]\;dv &&&\\ 
    1215 &\quad \equiv A^{\,lm} \sum\limits_{i,j,k}  \zeta \;e_{3f}  
    1216    \left\{     \delta_{i+1/2} \left[  \frac{e_{2v}} {e_{1v}\,e_{3v}} \delta_i \left[ e_{3f} \zeta  \right]   \right] 
    1217              + \delta_{j+1/2} \left[  \frac{e_{1u}} {e_{2u}\,e_{3u}} \delta_j \left[ e_{3f} \zeta  \right]   \right]      \right\}   &&&\\  
    1218 % 
    1219 \intertext{Using \autoref{eq:DOM_di_adj}, it follows:} 
    1220 % 
    1221 &\quad \equiv  - A^{\,lm} \sum\limits_{i,j,k}  
    1222    \left\{    \left(  \frac{1} {e_{1v}\,e_{3v}}  \delta_i \left[ e_{3f} \zeta  \right]  \right)^2   b_v 
    1223             + \left(  \frac{1} {e_{2u}\,e_{3u}}  \delta_j \left[ e_{3f} \zeta  \right] \right)^2   b_u  \right\}  \quad \leq \;0    &&&\\ 
     1216  &\int\limits_D  \zeta \; \textbf{k} \cdot \nabla \times 
     1217  \left[   \nabla_h \left( A^{\,lm}\;\chi  \right) 
     1218    - \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)   \right]\;dv &&&\\ 
     1219  &\quad = A^{\,lm} \int \limits_D \zeta \textbf{k} \cdot \nabla \times 
     1220  \left[    \nabla_h \times \left( \zeta \; \textbf{k} \right)   \right]\;dv &&&\\ 
     1221  &\quad \equiv A^{\,lm} \sum\limits_{i,j,k}  \zeta \;e_{3f} 
     1222  \left\{     \delta_{i+1/2} \left[  \frac{e_{2v}} {e_{1v}\,e_{3v}} \delta_i \left[ e_{3f} \zeta  \right]   \right] 
     1223    + \delta_{j+1/2} \left[  \frac{e_{1u}} {e_{2u}\,e_{3u}} \delta_j \left[ e_{3f} \zeta  \right]   \right]      \right\}   &&&\\ 
     1224  % 
     1225  \intertext{Using \autoref{eq:DOM_di_adj}, it follows:} 
     1226  % 
     1227  &\quad \equiv  - A^{\,lm} \sum\limits_{i,j,k} 
     1228  \left\{    \left(  \frac{1} {e_{1v}\,e_{3v}}  \delta_i \left[ e_{3f} \zeta  \right]  \right)^2   b_v 
     1229    + \left(  \frac{1} {e_{2u}\,e_{3u}}  \delta_j \left[ e_{3f} \zeta  \right] \right)^2   b_u  \right\}  \quad \leq \;0    &&&\\ 
    12241230\end{flalign*} 
    12251231 
     
    12341240The resulting term conserves the $\chi$ and dissipates $\chi^2$ when the eddy coefficients are horizontally uniform. 
    12351241\begin{flalign*} 
    1236 & \int\limits_D  \nabla_h \cdot  
    1237    \Bigl[     \nabla_h \left( A^{\,lm}\;\chi \right) 
    1238              - \nabla_h \times \left( A^{\,lm}\;\zeta \;\textbf{k} \right)    \Bigr]  dv 
    1239 = \int\limits_D  \nabla_h \cdot \nabla_h \left( A^{\,lm}\;\chi  \right)   dv   \\ 
    1240 % 
    1241 &\equiv \sum\limits_{i,j,k}  
    1242    \left\{   \delta_i \left[ A_u^{\,lm} \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2} \left[ \chi \right]  \right] 
    1243            + \delta_j \left[ A_v^{\,lm} \frac{e_{1v}\,e_{3v}} {e_{2v}}  \delta_{j+1/2} \left[ \chi \right]  \right]    \right\}    \\  
    1244 % 
    1245 \intertext{Using \autoref{eq:DOM_di_adj}, it follows:} 
    1246 % 
    1247 &\equiv \sum\limits_{i,j,k}  
    1248    - \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]  
    1249              + \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\}  
    1250    \quad \equiv 0      \\  
     1242  & \int\limits_D  \nabla_h \cdot 
     1243  \Bigl[     \nabla_h \left( A^{\,lm}\;\chi \right) 
     1244  - \nabla_h \times \left( A^{\,lm}\;\zeta \;\textbf{k} \right)    \Bigr]  dv 
     1245  = \int\limits_D  \nabla_h \cdot \nabla_h \left( A^{\,lm}\;\chi  \right)   dv   \\ 
     1246  % 
     1247  &\equiv \sum\limits_{i,j,k} 
     1248  \left\{   \delta_i \left[ A_u^{\,lm} \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2} \left[ \chi \right]  \right] 
     1249    + \delta_j \left[ A_v^{\,lm} \frac{e_{1v}\,e_{3v}} {e_{2v}}  \delta_{j+1/2} \left[ \chi \right]  \right]    \right\}    \\ 
     1250  % 
     1251  \intertext{Using \autoref{eq:DOM_di_adj}, it follows:} 
     1252  % 
     1253  &\equiv \sum\limits_{i,j,k} 
     1254  - \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] 
     1255    + \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\} 
     1256  \quad \equiv 0 
    12511257\end{flalign*} 
    12521258 
     
    12581264 
    12591265\begin{flalign*} 
    1260 &\int\limits_D \chi \;\nabla_h \cdot  
    1261    \left[    \nabla_h              \left( A^{\,lm}\;\chi                    \right) 
    1262            - \nabla_h   \times  \left( A^{\,lm}\;\zeta \;\textbf{k} \right)    \right]\;  dv 
    1263  = A^{\,lm}   \int\limits_D \chi \;\nabla_h \cdot \nabla_h \left( \chi \right)\;  dv    \\  
    1264 % 
    1265 &\equiv A^{\,lm}  \sum\limits_{i,j,k}  \frac{1} {e_{1t}\,e_{2t}\,e_{3t}}  \chi  
    1266    \left\{ 
    1267       \delta_i  \left[   \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2} \left[ \chi \right]   \right] 
    1268    + \delta_j  \left[   \frac{e_{1v}\,e_{3v}} {e_{2v}}   \delta_{j+1/2} \left[ \chi \right]   \right] 
    1269    \right\} \;   e_{1t}\,e_{2t}\,e_{3t}    \\  
    1270 % 
    1271 \intertext{Using \autoref{eq:DOM_di_adj}, it turns out to be:} 
    1272 % 
    1273 &\equiv - A^{\,lm} \sum\limits_{i,j,k} 
    1274    \left\{    \left(  \frac{1} {e_{1u}}  \delta_{i+1/2}  \left[ \chi \right]  \right)^2  b_u 
    1275             + \left(  \frac{1} {e_{2v}}  \delta_{j+1/2}  \left[ \chi \right]  \right)^2  b_v    \right\}     
    1276 \quad \leq 0             \\ 
     1266  &\int\limits_D \chi \;\nabla_h \cdot 
     1267  \left[    \nabla_h              \left( A^{\,lm}\;\chi                    \right) 
     1268    - \nabla_h   \times  \left( A^{\,lm}\;\zeta \;\textbf{k} \right)    \right]\;  dv 
     1269  = A^{\,lm}   \int\limits_D \chi \;\nabla_h \cdot \nabla_h \left( \chi \right)\;  dv    \\ 
     1270  % 
     1271  &\equiv A^{\,lm}  \sum\limits_{i,j,k}  \frac{1} {e_{1t}\,e_{2t}\,e_{3t}}  \chi 
     1272  \left\{ 
     1273    \delta_i  \left[   \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2} \left[ \chi \right]   \right] 
     1274    + \delta_j  \left[   \frac{e_{1v}\,e_{3v}} {e_{2v}}   \delta_{j+1/2} \left[ \chi \right]   \right] 
     1275  \right\} \;   e_{1t}\,e_{2t}\,e_{3t}    \\ 
     1276  % 
     1277  \intertext{Using \autoref{eq:DOM_di_adj}, it turns out to be:} 
     1278  % 
     1279  &\equiv - A^{\,lm} \sum\limits_{i,j,k} 
     1280  \left\{    \left(  \frac{1} {e_{1u}}  \delta_{i+1/2}  \left[ \chi \right]  \right)^2  b_u 
     1281    + \left(  \frac{1} {e_{2v}}  \delta_{j+1/2}  \left[ \chi \right]  \right)^2  b_v    \right\} 
     1282  \quad \leq 0 
    12771283\end{flalign*} 
    12781284 
     
    12871293The first two are associated with the conservation of momentum and the dissipation of horizontal kinetic energy: 
    12881294\begin{align*} 
    1289  \int\limits_D   \frac{1} {e_3 }\; \frac{\partial } {\partial k}  
    1290        \left(   \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)\;  dv  
    1291    \qquad \quad &= \vec{\textbf{0}}    \\ 
    1292 % 
    1293 \intertext{and} 
    1294 % 
    1295 \int\limits_D  
    1296    \textbf{U}_h \cdot   \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    1297    \left(   \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)\; dv    \quad &\leq 0     \\ 
     1295  \int\limits_D   \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1296  \left(   \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)\;  dv 
     1297  \qquad \quad &= \vec{\textbf{0}} 
     1298  % 
     1299  \intertext{and} 
     1300  % 
     1301                 \int\limits_D 
     1302                 \textbf{U}_h \cdot   \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1303                 \left(   \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)\; dv    \quad &\leq 0 
    12981304\end{align*} 
    12991305 
     
    13011307The second results from: 
    13021308\begin{flalign*} 
    1303 \int\limits_D  
    1304    \textbf{U}_h \cdot   \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    1305    \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)\;dv    &&&\\ 
    1306 \end{flalign*} 
    1307 \begin{flalign*} 
    1308 &\equiv \sum\limits_{i,j,k}  
    1309    \left(  
    1310       u\; \delta_k \left[ \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2}  \left[ u \right]  \right]\;  e_{1u}\,e_{2u}  
    1311    + v\; \delta_k \left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2}   \left[ v \right]  \right]\;  e_{1v}\,e_{2v} \right)   &&&\\  
    1312 % 
    1313 \intertext{since the horizontal scale factor does not depend on $k$, it follows:} 
    1314 % 
    1315 &\equiv - \sum\limits_{i,j,k}  
    1316    \left(  \frac{A_u^{\,vm}} {e_{3uw}} \left( \delta_{k+1/2} \left[ u \right] \right)^2\; e_{1u}\,e_{2u}  
    1317          + \frac{A_v^{\,vm}} {e_{3vw}}  \left( \delta_{k+1/2} \left[ v \right] \right)^2\; e_{1v}\,e_{2v}  \right) 
    1318 \quad \leq 0   &&&\\ 
     1309  \int\limits_D 
     1310  \textbf{U}_h \cdot   \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1311  \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)\;dv    &&&\\ 
     1312\end{flalign*} 
     1313\begin{flalign*} 
     1314  &\equiv \sum\limits_{i,j,k} 
     1315  \left( 
     1316    u\; \delta_k \left[ \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2}  \left[ u \right]  \right]\;  e_{1u}\,e_{2u} 
     1317    + v\; \delta_k \left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2}   \left[ v \right]  \right]\;  e_{1v}\,e_{2v} \right)   &&& 
     1318  % 
     1319  \intertext{since the horizontal scale factor does not depend on $k$, it follows:} 
     1320  % 
     1321  &\equiv - \sum\limits_{i,j,k} 
     1322  \left(  \frac{A_u^{\,vm}} {e_{3uw}} \left( \delta_{k+1/2} \left[ u \right] \right)^2\; e_{1u}\,e_{2u} 
     1323    + \frac{A_v^{\,vm}} {e_{3vw}}  \left( \delta_{k+1/2} \left[ v \right] \right)^2\; e_{1v}\,e_{2v}  \right) 
     1324  \quad \leq 0   &&& 
    13191325\end{flalign*} 
    13201326 
     
    13221328Indeed: 
    13231329\begin{flalign*} 
    1324 \int \limits_D  
    1325    \frac{1} {e_3 } \textbf{k} \cdot \nabla \times  
    1326       \left( \frac{1} {e_3 }\; \frac{\partial } {\partial k}  \left(  
    1327               \frac{A^{\,vm}} {e_3}\; \frac{\partial \textbf{U}_h } {\partial k}   
    1328         \right)  \right)\; dv   &&&\\  
    1329 \end{flalign*} 
    1330 \begin{flalign*} 
    1331 \equiv \sum\limits_{i,j,k}  \frac{1} {e_{3f}}\; \frac{1} {e_{1f}\,e_{2f}} 
    1332    \bigg\{    \biggr.   \quad 
    1333    \delta_{i+1/2}  
    1334       &\left(   \frac{e_{2v}} {e_{3v}} \delta_k  \left[  \frac{1} {e_{3vw}} \delta_{k+1/2} \left[ v \right]  \right]  \right)   &&\\ 
    1335    \biggl.  
    1336    - \delta_{j+1/2}  
    1337       &\left(   \frac{e_{1u}} {e_{3u}} \delta_k \left[  \frac{1} {e_{3uw}}\delta_{k+1/2} \left[ u \right]  \right]   \right) 
    1338    \biggr\} \; 
    1339    e_{1f}\,e_{2f}\,e_{3f} \; \equiv 0   && \\ 
     1330  \int \limits_D 
     1331  \frac{1} {e_3 } \textbf{k} \cdot \nabla \times 
     1332  \left( \frac{1} {e_3 }\; \frac{\partial } {\partial k}  \left( 
     1333      \frac{A^{\,vm}} {e_3}\; \frac{\partial \textbf{U}_h } {\partial k} 
     1334    \right)  \right)\; dv   &&& 
     1335\end{flalign*} 
     1336\begin{flalign*} 
     1337  \equiv \sum\limits_{i,j,k}  \frac{1} {e_{3f}}\; \frac{1} {e_{1f}\,e_{2f}} 
     1338  \bigg\{    \biggr.   \quad 
     1339  \delta_{i+1/2} 
     1340  &\left(   \frac{e_{2v}} {e_{3v}} \delta_k  \left[  \frac{1} {e_{3vw}} \delta_{k+1/2} \left[ v \right]  \right]  \right)   &&\\ 
     1341  \biggl. 
     1342  - \delta_{j+1/2} 
     1343  &\left(   \frac{e_{1u}} {e_{3u}} \delta_k \left[  \frac{1} {e_{3uw}}\delta_{k+1/2} \left[ u \right]  \right]   \right) 
     1344  \biggr\} \; 
     1345  e_{1f}\,e_{2f}\,e_{3f} \; \equiv 0   && 
    13401346\end{flalign*} 
    13411347 
    13421348If the vertical diffusion coefficient is uniform over the whole domain, the enstrophy is dissipated, $i.e.$ 
    13431349\begin{flalign*} 
    1344 \int\limits_D \zeta \, \textbf{k} \cdot \nabla \times  
    1345    \left(   \frac{1} {e_3}\; \frac{\partial } {\partial k} 
    1346       \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)   \right)\; dv = 0   &&&\\ 
     1350  \int\limits_D \zeta \, \textbf{k} \cdot \nabla \times 
     1351  \left(   \frac{1} {e_3}\; \frac{\partial } {\partial k} 
     1352    \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)   \right)\; dv = 0   &&& 
    13471353\end{flalign*} 
    13481354 
    13491355This property is only satisfied in $z$-coordinates: 
    13501356\begin{flalign*} 
    1351 \int\limits_D \zeta \, \textbf{k} \cdot \nabla \times  
    1352    \left(  \frac{1} {e_3}\; \frac{\partial } {\partial k} 
    1353       \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  \right)   \right)\; dv   &&& \\  
    1354 \end{flalign*} 
    1355 \begin{flalign*} 
    1356 \equiv \sum\limits_{i,j,k} \zeta \;e_{3f} \; 
    1357    \biggl\{    \biggr.  \quad 
    1358    \delta_{i+1/2}  
    1359       &\left(   \frac{e_{2v}} {e_{3v}} \delta_k \left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2}[v]  \right]   \right)   &&\\ 
    1360    - \delta_{j+1/2}  
    1361       &\biggl. 
    1362       \left(   \frac{e_{1u}} {e_{3u}} \delta_k \left[ \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} [u]  \right]    \right) \biggr\}   &&\\  
    1363 \end{flalign*} 
    1364 \begin{flalign*} 
    1365 \equiv \sum\limits_{i,j,k} \zeta \;e_{3f}  
    1366    \biggl\{    \biggr.  \quad 
    1367    \frac{1} {e_{3v}} \delta_k  
    1368       &\left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2} \left[ \delta_{i+1/2} \left[ e_{2v}\,v \right] \right]   \right]    &&\\  
    1369     \biggl.  
    1370    - \frac{1} {e_{3u}} \delta_k  
    1371       &\left[  \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} \left[ \delta_{j+1/2} \left[ e_{1u}\,u \right] \right]  \right]  \biggr\}  &&\\  
     1357  \int\limits_D \zeta \, \textbf{k} \cdot \nabla \times 
     1358  \left(  \frac{1} {e_3}\; \frac{\partial } {\partial k} 
     1359    \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  \right)   \right)\; dv   &&& 
     1360\end{flalign*} 
     1361\begin{flalign*} 
     1362  \equiv \sum\limits_{i,j,k} \zeta \;e_{3f} \; 
     1363  \biggl\{  \biggr.  \quad 
     1364  \delta_{i+1/2} 
     1365  &\left(   \frac{e_{2v}} {e_{3v}} \delta_k \left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2}[v]  \right]   \right)   &&\\ 
     1366  - \delta_{j+1/2} 
     1367  &\biggl. 
     1368  \left(   \frac{e_{1u}} {e_{3u}} \delta_k \left[ \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} [u]  \right]    \right) \biggr\}   && 
     1369\end{flalign*} 
     1370\begin{flalign*} 
     1371  \equiv \sum\limits_{i,j,k} \zeta \;e_{3f} 
     1372  \biggl\{     \biggr.  \quad 
     1373  \frac{1} {e_{3v}} \delta_k 
     1374  &\left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2} \left[ \delta_{i+1/2} \left[ e_{2v}\,v \right] \right]   \right]    &&\\ 
     1375  \biggl. 
     1376  - \frac{1} {e_{3u}} \delta_k 
     1377  &\left[  \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} \left[ \delta_{j+1/2} \left[ e_{1u}\,u \right] \right]  \right]  \biggr\}  && 
    13721378\end{flalign*} 
    13731379Using the fact that the vertical diffusion coefficients are uniform, 
     
    13751381$e_{3f} =e_{3u} =e_{3v} =e_{3t} $ and $e_{3w} =e_{3uw} =e_{3vw} $, it follows: 
    13761382\begin{flalign*} 
    1377 \equiv A^{\,vm} \sum\limits_{i,j,k} \zeta \;\delta_k  
    1378    \left[   \frac{1} {e_{3w}} \delta_{k+1/2} \Bigl[   \delta_{i+1/2} \left[ e_{2v}\,v \right] 
    1379                                 - \delta_{j+1/ 2} \left[ e_{1u}\,u \right]   \Bigr]    \right]    &&&\\ 
    1380 \end{flalign*} 
    1381 \begin{flalign*} 
    1382 \equiv - A^{\,vm} \sum\limits_{i,j,k} \frac{1} {e_{3w}} 
    1383    \left( \delta_{k+1/2} \left[ \zeta  \right] \right)^2 \; e_{1f}\,e_{2f}  \; \leq 0    &&&\\ 
     1383  \equiv A^{\,vm} \sum\limits_{i,j,k} \zeta \;\delta_k 
     1384  \left[   \frac{1} {e_{3w}} \delta_{k+1/2} \Bigl[   \delta_{i+1/2} \left[ e_{2v}\,v \right] 
     1385    - \delta_{j+1/ 2} \left[ e_{1u}\,u \right]   \Bigr]    \right]    &&& 
     1386\end{flalign*} 
     1387\begin{flalign*} 
     1388  \equiv - A^{\,vm} \sum\limits_{i,j,k} \frac{1} {e_{3w}} 
     1389  \left( \delta_{k+1/2} \left[ \zeta  \right] \right)^2 \; e_{1f}\,e_{2f}  \; \leq 0    &&& 
    13841390\end{flalign*} 
    13851391Similarly, the horizontal divergence is obviously conserved: 
    13861392 
    13871393\begin{flalign*} 
    1388 \int\limits_D \nabla \cdot  
    1389 \left( \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    1390       \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} \right) \right)\; dv = 0    &&&\\ 
     1394  \int\limits_D \nabla \cdot 
     1395  \left( \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1396    \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} \right) \right)\; dv = 0    &&& 
    13911397\end{flalign*} 
    13921398and the square of the horizontal divergence decreases ($i.e.$ the horizontal divergence is dissipated) if 
     
    13941400 
    13951401\begin{flalign*} 
    1396 \int\limits_D \chi \;\nabla \cdot  
    1397 \left( \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    1398       \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  \right) \right)\;  dv = 0  &&&\\ 
     1402  \int\limits_D \chi \;\nabla \cdot 
     1403  \left( \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1404    \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}  \right) \right)\;  dv = 0  &&& 
    13991405\end{flalign*} 
    14001406This property is only satisfied in the $z$-coordinate: 
    14011407\begin{flalign*} 
    1402 \int\limits_D \chi \;\nabla \cdot  
    1403 \left( \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
    1404       \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} \right)  \right)\; dv    &&&\\ 
    1405 \end{flalign*} 
    1406 \begin{flalign*} 
    1407 \equiv \sum\limits_{i,j,k} \frac{\chi } {e_{1t}\,e_{2t}} 
    1408    \biggl\{    \Biggr.  \quad 
    1409    \delta_{i+1/2}  
    1410       &\left(   \frac{e_{2u}} {e_{3u}} \delta_k  
    1411             \left[ \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} [u] \right] \right)    &&\\  
    1412    \Biggl.  
    1413    + \delta_{j+1/2}  
    1414       &\left( \frac{e_{1v}} {e_{3v}} \delta_k  
    1415          \left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2} [v] \right]   \right) 
    1416    \Biggr\} \;  e_{1t}\,e_{2t}\,e_{3t}   &&\\  
    1417 \end{flalign*} 
    1418  
    1419 \begin{flalign*} 
    1420 \equiv A^{\,vm} \sum\limits_{i,j,k}  \chi \, 
    1421    \biggl\{ \biggr.  \quad 
    1422    \delta_{i+1/2} 
    1423       &\left(  
    1424          \delta_k \left[  
    1425          \frac{1} {e_{3uw}} \delta_{k+1/2} \left[ e_{2u}\,u \right] \right]   \right)    && \\  
    1426    \biggl.  
    1427    + \delta_{j+1/2}  
    1428       &\left(    \delta_k \left[  
    1429          \frac{1} {e_{3vw}} \delta_{k+1/2} \left[ e_{1v}\,v \right] \right]   \right)   \biggr\}    && \\  
    1430 \end{flalign*} 
    1431  
    1432 \begin{flalign*} 
    1433 \equiv -A^{\,vm} \sum\limits_{i,j,k}  
    1434 \frac{\delta_{k+1/2} \left[ \chi \right]} {e_{3w}}\; \biggl\{  
    1435    \delta_{k+1/2} \Bigl[ 
    1436          \delta_{i+1/2} \left[ e_{2u}\,u \right] 
    1437       + \delta_{j+1/2} \left[ e_{1v}\,v \right]  \Bigr]    \biggr\}    &&&\\ 
    1438 \end{flalign*} 
    1439  
    1440 \begin{flalign*} 
    1441 \equiv -A^{\,vm} \sum\limits_{i,j,k} 
    1442  \frac{1} {e_{3w}} \delta_{k+1/2} \left[ \chi \right]\; \delta_{k+1/2} \left[ e_{1t}\,e_{2t} \;\chi \right]   &&&\\ 
    1443 \end{flalign*} 
    1444  
    1445 \begin{flalign*} 
    1446 \equiv -A^{\,vm} \sum\limits_{i,j,k}  
    1447 \frac{e_{1t}\,e_{2t}} {e_{3w}}\; \left( \delta_{k+1/2} \left[ \chi \right]  \right)^2     \quad  \equiv 0    &&&\\ 
     1408  \int\limits_D \chi \;\nabla \cdot 
     1409  \left( \frac{1} {e_3 }\; \frac{\partial } {\partial k} 
     1410    \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} \right)  \right)\; dv    &&& 
     1411\end{flalign*} 
     1412\begin{flalign*} 
     1413  \equiv \sum\limits_{i,j,k} \frac{\chi } {e_{1t}\,e_{2t}} 
     1414  \biggl\{  \Biggr.  \quad 
     1415  \delta_{i+1/2} 
     1416  &\left(   \frac{e_{2u}} {e_{3u}} \delta_k 
     1417    \left[ \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} [u] \right] \right)    &&\\ 
     1418  \Biggl. 
     1419  + \delta_{j+1/2} 
     1420  &\left( \frac{e_{1v}} {e_{3v}} \delta_k 
     1421    \left[ \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2} [v] \right]   \right) 
     1422  \Biggr\} \;  e_{1t}\,e_{2t}\,e_{3t}   && 
     1423\end{flalign*} 
     1424 
     1425\begin{flalign*} 
     1426  \equiv A^{\,vm} \sum\limits_{i,j,k}  \chi \, 
     1427  \biggl\{  \biggr.  \quad 
     1428  \delta_{i+1/2} 
     1429  &\left( 
     1430    \delta_k \left[ 
     1431      \frac{1} {e_{3uw}} \delta_{k+1/2} \left[ e_{2u}\,u \right] \right]   \right)    && \\ 
     1432  \biggl. 
     1433  + \delta_{j+1/2} 
     1434  &\left(    \delta_k \left[ 
     1435      \frac{1} {e_{3vw}} \delta_{k+1/2} \left[ e_{1v}\,v \right] \right]   \right)   \biggr\}    && 
     1436\end{flalign*} 
     1437 
     1438\begin{flalign*} 
     1439  \equiv -A^{\,vm} \sum\limits_{i,j,k} 
     1440  \frac{\delta_{k+1/2} \left[ \chi \right]} {e_{3w}}\; \biggl\{ 
     1441  \delta_{k+1/2} \Bigl[ 
     1442  \delta_{i+1/2} \left[ e_{2u}\,u \right] 
     1443  + \delta_{j+1/2} \left[ e_{1v}\,v \right]  \Bigr]    \biggr\}    &&& 
     1444\end{flalign*} 
     1445 
     1446\begin{flalign*} 
     1447  \equiv -A^{\,vm} \sum\limits_{i,j,k} 
     1448  \frac{1} {e_{3w}} \delta_{k+1/2} \left[ \chi \right]\; \delta_{k+1/2} \left[ e_{1t}\,e_{2t} \;\chi \right]   &&& 
     1449\end{flalign*} 
     1450 
     1451\begin{flalign*} 
     1452  \equiv -A^{\,vm} \sum\limits_{i,j,k} 
     1453  \frac{e_{1t}\,e_{2t}} {e_{3w}}\; \left( \delta_{k+1/2} \left[ \chi \right]  \right)^2     \quad  \equiv 0    &&& 
    14481454\end{flalign*} 
    14491455 
     
    14681474constraint of conservation of tracers: 
    14691475\begin{flalign*} 
    1470 &\int\limits_D  \nabla  \cdot \left( A\;\nabla T \right)\;dv  &&&\\  
    1471 \\ 
    1472 &\equiv \sum\limits_{i,j,k}  
    1473    \biggl\{    \biggr. 
    1474    \delta_i  
    1475       \left[  
    1476       A_u^{\,lT} \frac{e_{2u}\,e_{3u}} {e_{1u}} \delta_{i+1/2}  
    1477          \left[ T \right] 
    1478       \right] 
    1479    + \delta_j  
    1480       \left[  
    1481       A_v^{\,lT} \frac{e_{1v}\,e_{3v}} {e_{2v}} \delta_{j+1/2}  
    1482          \left[ T \right]  
    1483       \right] 
    1484    &&\\  & \qquad \qquad \qquad \qquad \qquad \qquad \quad \;\;\; 
    1485    + \delta_k  
    1486       \left[  
    1487       A_w^{\,vT} \frac{e_{1t}\,e_{2t}} {e_{3t}} \delta_{k+1/2}  
    1488          \left[ T \right]  
    1489       \right] 
    1490    \biggr\}   \quad  \equiv 0 
    1491    &&\\  
     1476  &\int\limits_D  \nabla  \cdot \left( A\;\nabla T \right)\;dv  &&& \\ \\ 
     1477  &\equiv \sum\limits_{i,j,k} 
     1478  \biggl\{  \biggr. 
     1479  \delta_i 
     1480  \left[ 
     1481    A_u^{\,lT} \frac{e_{2u}\,e_{3u}} {e_{1u}} \delta_{i+1/2} 
     1482    \left[ T \right] 
     1483  \right] 
     1484  + \delta_j 
     1485  \left[ 
     1486    A_v^{\,lT} \frac{e_{1v}\,e_{3v}} {e_{2v}} \delta_{j+1/2} 
     1487    \left[ T \right] 
     1488  \right] && \\ 
     1489  & \qquad \qquad \qquad \qquad \qquad \qquad \quad \;\;\; 
     1490  + \delta_k 
     1491  \left[ 
     1492    A_w^{\,vT} \frac{e_{1t}\,e_{2t}} {e_{3t}} \delta_{k+1/2} 
     1493    \left[ T \right] 
     1494  \right] 
     1495  \biggr\}   \quad  \equiv 0 
     1496  && 
    14921497\end{flalign*} 
    14931498 
     
    15021507constraint on the dissipation of tracer variance: 
    15031508\begin{flalign*} 
    1504 \int\limits_D T\;\nabla & \cdot \left( A\;\nabla T \right)\;dv &&&\\  
    1505 &\equiv   \sum\limits_{i,j,k} \; T 
    1506 \biggl\{  \biggr. 
    1507      \delta_i \left[ A_u^{\,lT} \frac{e_{2u}\,e_{3u}} {e_{1u}} \delta_{i+1/2} \left[T\right] \right] 
    1508 & + \delta_j \left[ A_v^{\,lT} \frac{e_{1v} \,e_{3v}} {e_{2v}} \delta_{j+1/2} \left[T\right] \right]  
    1509       \quad&& \\  
    1510  \biggl.  
    1511 &&+ \delta_k \left[A_w^{\,vT}\frac{e_{1t}\,e_{2t}} {e_{3t}}\delta_{k+1/2}\left[T\right]\right] 
    1512 \biggr\} &&  
    1513 \end{flalign*} 
    1514 \begin{flalign*} 
    1515 \equiv - \sum\limits_{i,j,k}  
    1516    \biggl\{    \biggr.  \quad 
    1517    &    A_u^{\,lT} \left( \frac{1} {e_{1u}} \delta_{i+1/2} \left[ T \right]  \right)^2   e_{1u}\,e_{2u}\,e_{3u}    && \\ 
    1518    & + A_v^{\,lT} \left( \frac{1} {e_{2v}} \delta_{j+1/2} \left[ T \right]  \right)^2   e_{1v}\,e_{2v}\,e_{3v}     && \\ \biggl.  
    1519    & + A_w^{\,vT} \left( \frac{1} {e_{3w}} \delta_{k+1/2} \left[ T \right]   \right)^2    e_{1w}\,e_{2w}\,e_{3w}   \biggr\}  
    1520    \quad      \leq 0      && \\  
    1521 \end{flalign*} 
    1522  
     1509  \int\limits_D T\;\nabla & \cdot \left( A\;\nabla T \right)\;dv  &&&\\ 
     1510  &\equiv   \sum\limits_{i,j,k} \; T 
     1511  \biggl\{  \biggr. 
     1512  \delta_i \left[ A_u^{\,lT} \frac{e_{2u}\,e_{3u}} {e_{1u}} \delta_{i+1/2} \left[T\right] \right] 
     1513  & + \delta_j \left[ A_v^{\,lT} \frac{e_{1v} \,e_{3v}} {e_{2v}} \delta_{j+1/2} \left[T\right] \right] 
     1514  \quad&& \\ 
     1515  \biggl. 
     1516  &&+ \delta_k \left[A_w^{\,vT}\frac{e_{1t}\,e_{2t}} {e_{3t}}\delta_{k+1/2}\left[T\right]\right] 
     1517  \biggr\} && 
     1518\end{flalign*} 
     1519\begin{flalign*} 
     1520  \equiv - \sum\limits_{i,j,k} 
     1521  \biggl\{  \biggr.  \quad 
     1522  &    A_u^{\,lT} \left( \frac{1} {e_{1u}} \delta_{i+1/2} \left[ T \right]  \right)^2   e_{1u}\,e_{2u}\,e_{3u}    && \\ 
     1523  & + A_v^{\,lT} \left( \frac{1} {e_{2v}} \delta_{j+1/2} \left[ T \right]  \right)^2   e_{1v}\,e_{2v}\,e_{3v}     && \\ \biggl. 
     1524  & + A_w^{\,vT} \left( \frac{1} {e_{3w}} \delta_{k+1/2} \left[ T \right]   \right)^2    e_{1w}\,e_{2w}\,e_{3w}   \biggr\} 
     1525  \quad      \leq 0      && 
     1526\end{flalign*} 
    15231527 
    15241528%%%%  end of appendix in gm comment 
    15251529%} 
     1530\biblio 
     1531 
    15261532\end{document} 
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex/NEMO/subfiles/annex_D.tex

    r10368 r10419  
    1 \documentclass[../tex_main/NEMO_manual]{subfiles} 
     1\documentclass[../main/NEMO_manual]{subfiles} 
     2 
    23\begin{document} 
    34% ================================================================ 
    4 % Appendix D Ñ Coding Rules 
     5% Appendix D Coding Rules 
    56% ================================================================ 
    67\chapter{Coding Rules} 
    78\label{apdx:D} 
     9 
    810\minitoc 
    911 
    1012\newpage 
    11 $\ $\newline    % force a new ligne 
    12 $\ $\newline    % force a new ligne 
    13  
    1413 
    1514A "model life" is more than ten years. 
     
    102101- use call to ctl\_stop routine instead of just a STOP. 
    103102 
    104  
    105103\newpage 
     104 
    106105% ================================================================ 
    107106% Naming Conventions 
     
    116115 
    117116%--------------------------------------------------TABLE-------------------------------------------------- 
    118 \begin{table}[htbp]  \label{tab:VarName} 
    119 \begin{center} 
    120 \begin{tabular}{|p{45pt}|p{35pt}|p{45pt}|p{40pt}|p{40pt}|p{40pt}|p{40pt}|p{40pt}|} 
    121 \hline  Type \par / Status &   integer&   real&   logical &   character  & structure &   double \par precision&   complex \\   
    122 \hline 
    123 public  \par or  \par module variable&  
    124 \textbf{m n} \par \textit{but not} \par \textbf{nn\_ np\_}&  
    125 \textbf{a b e f g h o q r} \par \textbf{t} \textit{to} \textbf{x} \par but not \par \textbf{fs rn\_}&  
    126 \textbf{l} \par \textit{but not} \par \textbf{lp ld} \par \textbf{ ll ln\_}&  
    127 \textbf{c} \par \textit{but not} \par \textbf{cp cd} \par \textbf{cl cn\_}&  
    128 \textbf{s} \par \textit{but not} \par \textbf{sd sd} \par \textbf{sl sn\_}&  
    129 \textbf{d} \par \textit{but not} \par \textbf{dp dd} \par \textbf{dl dn\_}&  
    130 \textbf{y} \par \textit{but not} \par \textbf{yp yd} \par \textbf{yl yn} \\ 
    131 \hline 
    132 dummy \par argument&  
    133 \textbf{k} \par \textit{but not} \par \textbf{kf}&  
    134 \textbf{p} \par \textit{but not} \par \textbf{pp pf}&  
    135 \textbf{ld}&  
    136 \textbf{cd}&  
    137 \textbf{sd}&  
    138 \textbf{dd}&  
    139 \textbf{yd} \\ 
    140 \hline 
    141 local \par variable&  
    142 \textbf{i}&  
    143 \textbf{z}&  
    144 \textbf{ll}&  
    145 \textbf{cl}&  
    146 \textbf{sl}&  
    147 \textbf{dl}&  
    148 \textbf{yl} \\ 
    149 \hline 
    150 loop \par control&  
    151 \textbf{j} \par \textit{but not} \par \textbf{jp}&  
    152 &  
    153 &  
    154 & 
    155 &  
    156 &  
    157  \\ 
    158 \hline 
    159 parameter&  
    160 \textbf{jp np\_}&  
    161 \textbf{pp}&  
    162 \textbf{lp}&  
    163 \textbf{cp}&  
    164 \textbf{sp}&  
    165 \textbf{dp}&  
    166 \textbf{yp} \\ 
    167 \hline 
    168  
    169 namelist& 
    170 \textbf{nn\_}&  
    171 \textbf{rn\_}&  
    172 \textbf{ln\_}&  
    173 \textbf{cn\_}&  
    174 \textbf{sn\_}&  
    175 \textbf{dn\_}&  
    176 \textbf{yn\_} 
    177 \\ 
    178 \hline 
    179 CPP \par macro&  
    180 \textbf{kf}&  
    181 \textbf{fs} \par &  
    182 &  
    183 & 
    184 &  
    185 &  
    186  \\ 
    187 \hline 
    188 \end{tabular} 
    189 \label{tab:tab1} 
    190 \end{center} 
     117\begin{table}[htbp] 
     118  \label{tab:VarName} 
     119  \begin{center} 
     120    \begin{tabular}{|p{45pt}|p{35pt}|p{45pt}|p{40pt}|p{40pt}|p{40pt}|p{40pt}|p{40pt}|} 
     121      \hline 
     122      Type \par / Status 
     123      & integer 
     124      & real 
     125      & logical 
     126      & character 
     127      & structure 
     128      & double \par precision 
     129      & complex \\ 
     130      \hline 
     131      public  \par or  \par module variable 
     132      & \textbf{m n} \par \textit{but not} \par \textbf{nn\_ np\_} 
     133      & \textbf{a b e f g h o q r} \par \textbf{t} \textit{to} \textbf{x} \par but not \par \textbf{fs rn\_} 
     134      & \textbf{l} \par \textit{but not} \par \textbf{lp ld} \par \textbf{ ll ln\_} 
     135      & \textbf{c} \par \textit{but not} \par \textbf{cp cd} \par \textbf{cl cn\_} 
     136      & \textbf{s} \par \textit{but not} \par \textbf{sd sd} \par \textbf{sl sn\_} 
     137      & \textbf{d} \par \textit{but not} \par \textbf{dp dd} \par \textbf{dl dn\_} 
     138      & \textbf{y} \par \textit{but not} \par \textbf{yp yd} \par \textbf{yl yn} \\ 
     139      \hline 
     140      dummy \par argument 
     141      & \textbf{k} \par \textit{but not} \par \textbf{kf} 
     142      & \textbf{p} \par \textit{but not} \par \textbf{pp pf} 
     143      & \textbf{ld} 
     144      & \textbf{cd} 
     145      & \textbf{sd} 
     146      & \textbf{dd} 
     147      & \textbf{yd} \\ 
     148      \hline 
     149      local \par variable 
     150      & \textbf{i} 
     151      & \textbf{z} 
     152      & \textbf{ll} 
     153      & \textbf{cl} 
     154      & \textbf{sl} 
     155      & \textbf{dl} 
     156      & \textbf{yl} \\ 
     157      \hline 
     158      loop \par control 
     159      & \textbf{j} \par \textit{but not} \par \textbf{jp} &&&&&& \\ 
     160      \hline 
     161      parameter 
     162      & \textbf{jp np\_} 
     163      & \textbf{pp} 
     164      & \textbf{lp} 
     165      & \textbf{cp} 
     166      & \textbf{sp} 
     167      & \textbf{dp} 
     168      & \textbf{yp} \\ 
     169      \hline 
     170      namelist 
     171      & \textbf{nn\_} 
     172      & \textbf{rn\_} 
     173      & \textbf{ln\_} 
     174      & \textbf{cn\_} 
     175      & \textbf{sn\_} 
     176      & \textbf{dn\_} 
     177      & \textbf{yn\_} 
     178      \\ 
     179      \hline 
     180      CPP \par macro 
     181      & \textbf{kf} 
     182      & \textbf{fs} \par &&&&& \\ 
     183      \hline 
     184    \end{tabular} 
     185    \label{tab:tab1} 
     186  \end{center} 
    191187\end{table} 
    192188%-------------------------------------------------------------------------------------------------------------- 
     
    197193 
    198194\newpage 
     195 
    199196% ================================================================ 
    200197% The program structure 
    201198% ================================================================ 
    202199%\section{Program structure} 
    203 %abel{sec:Apdx_D_structure} 
     200%\label{sec:Apdx_D_structure} 
    204201 
    205202%To be done.... 
     203\biblio 
     204 
    206205\end{document} 
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex/NEMO/subfiles/annex_E.tex

    r10368 r10419  
    1 \documentclass[../tex_main/NEMO_manual]{subfiles} 
     1\documentclass[../main/NEMO_manual]{subfiles} 
     2 
    23\begin{document} 
    34% ================================================================ 
     
    67\chapter{Note on some algorithms} 
    78\label{apdx:E} 
     9 
    810\minitoc 
    911 
    1012\newpage 
    11 $\ $\newline    % force a new ligne 
    1213 
    1314This appendix some on going consideration on algorithms used or planned to be used in \NEMO.  
    14  
    15 $\ $\newline    % force a new ligne 
    1615 
    1716% ------------------------------------------------------------------------------------------------------------- 
     
    2524It is also known as Cell Averaged QUICK scheme (Quadratic Upstream Interpolation for Convective Kinematics). 
    2625For example, in the $i$-direction: 
    27 \begin{equation} \label{eq:tra_adv_ubs2} 
    28 \tau _u^{ubs} = \left\{  \begin{aligned} 
    29   & \tau _u^{cen4} + \frac{1}{12} \,\tau"_i     & \quad \text{if }\ u_{i+1/2} \geqslant 0 \\ 
    30   & \tau _u^{cen4} - \frac{1}{12} \,\tau"_{i+1} & \quad \text{if }\ u_{i+1/2}       <       0 
    31                    \end{aligned}    \right. 
     26\begin{equation} 
     27  \label{eq:tra_adv_ubs2} 
     28  \tau_u^{ubs} = \left\{ 
     29    \begin{aligned} 
     30      & \tau_u^{cen4} + \frac{1}{12} \,\tau"_i     & \quad \text{if }\ u_{i+1/2} \geqslant 0 \\ 
     31      & \tau_u^{cen4} - \frac{1}{12} \,\tau"_{i+1} & \quad \text{if }\ u_{i+1/2}       <       0 
     32    \end{aligned} 
     33  \right. 
    3234\end{equation} 
    3335or equivalently, the advective flux is 
    34 \begin{equation} \label{eq:tra_adv_ubs2} 
    35 U_{i+1/2} \ \tau _u^{ubs}  
    36 =U_{i+1/2} \ \overline{ T_i - \frac{1}{6}\,\tau"_i }^{\,i+1/2} 
    37 - \frac{1}{2}\, |U|_{i+1/2} \;\frac{1}{6} \;\delta_{i+1/2}[\tau"_i] 
     36\begin{equation} 
     37  \label{eq:tra_adv_ubs2} 
     38  U_{i+1/2} \ \tau_u^{ubs} 
     39  =U_{i+1/2} \ \overline{ T_i - \frac{1}{6}\,\tau"_i }^{\,i+1/2} 
     40  - \frac{1}{2}\, |U|_{i+1/2} \;\frac{1}{6} \;\delta_{i+1/2}[\tau"_i] 
    3841\end{equation} 
    3942where $U_{i+1/2} = e_{1u}\,e_{3u}\,u_{i+1/2}$ and 
    40 $\tau "_i =\delta _i \left[ {\delta _{i+1/2} \left[ \tau \right]} \right]$. 
     43$\tau "_i =\delta_i \left[ {\delta_{i+1/2} \left[ \tau \right]} \right]$. 
    4144By choosing this expression for $\tau "$ we consider a fourth order approximation of $\partial_i^2$ with 
    4245a constant i-grid spacing ($\Delta i=1$). 
    4346 
    4447Alternative choice: introduce the scale factors:   
    45 $\tau "_i =\frac{e_{1T}}{e_{2T}\,e_{3T}}\delta _i \left[ \frac{e_{2u} e_{3u} }{e_{1u} }\delta _{i+1/2}[\tau] \right]$. 
    46  
     48$\tau "_i =\frac{e_{1T}}{e_{2T}\,e_{3T}}\delta_i \left[ \frac{e_{2u} e_{3u} }{e_{1u} }\delta_{i+1/2}[\tau] \right]$. 
    4749 
    4850This results in a dissipatively dominant (i.e. hyper-diffusive) truncation error 
     
    7678 
    7779NB 2: In a forthcoming release four options will be proposed for the vertical component used in the UBS scheme. 
    78 $\tau _w^{ubs}$ will be evaluated using either \textit{(a)} a centered $2^{nd}$ order scheme, 
     80$\tau_w^{ubs}$ will be evaluated using either \textit{(a)} a centered $2^{nd}$ order scheme, 
    7981or \textit{(b)} a TVD scheme, or \textit{(c)} an interpolation based on conservative parabolic splines following 
    8082\citet{Shchepetkin_McWilliams_OM05} implementation of UBS in ROMS, or \textit{(d)} an UBS. 
     
    8284 
    8385NB 3: It is straight forward to rewrite \autoref{eq:tra_adv_ubs} as follows: 
    84 \begin{equation} \label{eq:tra_adv_ubs2} 
    85 \tau _u^{ubs} = \left\{  \begin{aligned} 
    86    & \tau _u^{cen4} + \frac{1}{12} \tau"_i      & \quad \text{if }\ u_{i+1/2} \geqslant 0 \\ 
    87    & \tau _u^{cen4} - \frac{1}{12} \tau"_{i+1}  & \quad \text{if }\ u_{i+1/2}       <       0 
    88                    \end{aligned}    \right. 
     86\begin{equation} 
     87  \label{eq:tra_adv_ubs2} 
     88  \tau_u^{ubs} = \left\{ 
     89    \begin{aligned} 
     90      & \tau_u^{cen4} + \frac{1}{12} \tau"_i    & \quad \text{if }\ u_{i+1/2} \geqslant 0 \\ 
     91      & \tau_u^{cen4} - \frac{1}{12} \tau"_{i+1}   & \quad \text{if }\ u_{i+1/2}       <       0 
     92    \end{aligned} 
     93  \right. 
    8994\end{equation} 
    9095or equivalently  
    91 \begin{equation} \label{eq:tra_adv_ubs2} 
    92 \begin{split} 
    93 e_{2u} e_{3u}\,u_{i+1/2} \ \tau _u^{ubs}  
    94 &= e_{2u} e_{3u}\,u_{i+1/2} \ \overline{ T - \frac{1}{6}\,\tau"_i }^{\,i+1/2} \\ 
    95 & - \frac{1}{2} e_{2u} e_{3u}\,|u|_{i+1/2} \;\frac{1}{6} \;\delta_{i+1/2}[\tau"_i] 
    96 \end{split} 
     96\begin{equation} 
     97  \label{eq:tra_adv_ubs2} 
     98  \begin{split} 
     99    e_{2u} e_{3u}\,u_{i+1/2} \ \tau_u^{ubs} 
     100    &= e_{2u} e_{3u}\,u_{i+1/2} \ \overline{ T - \frac{1}{6}\,\tau"_i }^{\,i+1/2} \\ 
     101    & - \frac{1}{2} e_{2u} e_{3u}\,|u|_{i+1/2} \;\frac{1}{6} \;\delta_{i+1/2}[\tau"_i] 
     102  \end{split} 
    97103\end{equation} 
    98104\autoref{eq:tra_adv_ubs2} has several advantages. 
     
    105111 
    106112laplacian diffusion: 
    107 \begin{equation} \label{eq:tra_ldf_lap} 
    108 \begin{split} 
    109 D_T^{lT} =\frac{1}{e_{1T} \; e_{2T}\;  e_{3T} } &\left[ {\quad \delta _i  
    110 \left[ {A_u^{lT} \frac{e_{2u} e_{3u} }{e_{1u} }\;\delta _{i+1/2}  
    111 \left[ T \right]} \right]} \right. 
    112 \\ 
    113 &\ \left. {+\; \delta _j \left[  
    114 {A_v^{lT} \left( {\frac{e_{1v} e_{3v} }{e_{2v} }\;\delta _{j+1/2} \left[ T  
    115 \right]} \right)} \right]\quad } \right] 
    116 \end{split} 
     113\begin{equation} 
     114  \label{eq:tra_ldf_lap} 
     115  \begin{split} 
     116    D_T^{lT} =\frac{1}{e_{1T} \; e_{2T}\;  e_{3T} } &\left[ {\quad \delta_i 
     117        \left[ {A_u^{lT} \frac{e_{2u} e_{3u} }{e_{1u} }\;\delta_{i+1/2} 
     118            \left[ T \right]} \right]} \right. \\ 
     119    &\ \left. {+\; \delta_j \left[ 
     120          {A_v^{lT} \left( {\frac{e_{1v} e_{3v} }{e_{2v} }\;\delta_{j+1/2} \left[ T 
     121                \right]} \right)} \right]\quad } \right] 
     122  \end{split} 
    117123\end{equation} 
    118124 
    119125bilaplacian: 
    120 \begin{equation} \label{eq:tra_ldf_lap} 
    121 \begin{split} 
    122 D_T^{lT} =&-\frac{1}{e_{1T} \; e_{2T}\;  e_{3T}} \\ 
    123 & \delta _i \left[  \sqrt{A_u^{lT}}\ \frac{e_{2u}\,e_{3u}}{e_{1u}}\;\delta _{i+1/2}  
    124         \left[ \frac{1}{e_{1T}\,e_{2T}\, e_{3T}} 
    125     \delta _i \left[ \sqrt{A_u^{lT}}\ \frac{e_{2u}\,e_{3u}}{e_{1u}}\;\delta _{i+1/2}  
    126            [T] \right] \right] \right] 
    127 \end{split} 
     126\begin{equation} 
     127  \label{eq:tra_ldf_lap} 
     128  \begin{split} 
     129    D_T^{lT} =&-\frac{1}{e_{1T} \; e_{2T}\;  e_{3T}} \\ 
     130    & \delta_i \left[  \sqrt{A_u^{lT}}\ \frac{e_{2u}\,e_{3u}}{e_{1u}}\;\delta_{i+1/2} 
     131      \left[ \frac{1}{e_{1T}\,e_{2T}\, e_{3T}} 
     132        \delta_i \left[ \sqrt{A_u^{lT}}\ \frac{e_{2u}\,e_{3u}}{e_{1u}}\;\delta_{i+1/2} 
     133          [T] \right] \right] \right] 
     134  \end{split} 
    128135\end{equation} 
    129136with ${A_u^{lT}}^2 = \frac{1}{12} {e_{1u}}^3\ |u|$,  
    130137$i.e.$ $A_u^{lT} = \frac{1}{\sqrt{12}} \,e_{1u}\ \sqrt{ e_{1u}\,|u|\,}$ 
    131138it comes: 
    132 \begin{equation} \label{eq:tra_ldf_lap} 
    133 \begin{split} 
    134 D_T^{lT} =&-\frac{1}{12}\,\frac{1}{e_{1T} \; e_{2T}\;  e_{3T}} \\ 
    135 & \delta _i \left[ e_{2u}\,e_{3u}\,\sqrt{ e_{1u}\,|u|\,}\;\delta _{i+1/2}  
    136        \left[ \frac{1}{e_{1T}\,e_{2T}\, e_{3T}}  
    137     \delta _i \left[ e_{2u}\,e_{3u}\,\sqrt{ e_{1u}\,|u|\,}\;\delta _{i+1/2}  
    138          [T] \right] \right] \right] 
    139 \end{split} 
     139\begin{equation} 
     140  \label{eq:tra_ldf_lap} 
     141  \begin{split} 
     142    D_T^{lT} =&-\frac{1}{12}\,\frac{1}{e_{1T} \; e_{2T}\;  e_{3T}} \\ 
     143    & \delta_i \left[ e_{2u}\,e_{3u}\,\sqrt{ e_{1u}\,|u|\,}\;\delta_{i+1/2} 
     144      \left[ \frac{1}{e_{1T}\,e_{2T}\, e_{3T}} 
     145        \delta_i \left[ e_{2u}\,e_{3u}\,\sqrt{ e_{1u}\,|u|\,}\;\delta_{i+1/2} 
     146          [T] \right] \right] \right] 
     147  \end{split} 
    140148\end{equation} 
    141149if the velocity is uniform ($i.e.$ $|u|=cst$) then the diffusive flux is 
    142 \begin{equation} \label{eq:tra_ldf_lap} 
    143 \begin{split} 
    144 F_u^{lT} = - \frac{1}{12} 
    145  e_{2u}\,e_{3u}\,|u| \;\sqrt{ e_{1u}}\,\delta _{i+1/2}  
    146        \left[ \frac{1}{e_{1T}\,e_{2T}\, e_{3T}}  
    147     \delta _i \left[ e_{2u}\,e_{3u}\,\sqrt{ e_{1u}}\:\delta _{i+1/2}  
    148          [T] \right] \right] 
    149 \end{split} 
     150\begin{equation} 
     151  \label{eq:tra_ldf_lap} 
     152  \begin{split} 
     153    F_u^{lT} = - \frac{1}{12} 
     154    e_{2u}\,e_{3u}\,|u| \;\sqrt{ e_{1u}}\,\delta_{i+1/2} 
     155    \left[ \frac{1}{e_{1T}\,e_{2T}\, e_{3T}} 
     156      \delta_i \left[ e_{2u}\,e_{3u}\,\sqrt{ e_{1u}}\:\delta_{i+1/2} 
     157        [T] \right] \right] 
     158  \end{split} 
    150159\end{equation} 
    151160beurk....  reverte the logic: starting from the diffusive part of the advective flux it comes: 
    152161 
    153 \begin{equation} \label{eq:tra_adv_ubs2} 
    154 \begin{split} 
    155 F_u^{lT} 
    156 &= - \frac{1}{2} e_{2u} e_{3u}\,|u|_{i+1/2} \;\frac{1}{6} \;\delta_{i+1/2}[\tau"_i] 
    157 \end{split} 
     162\begin{equation} 
     163  \label{eq:tra_adv_ubs2} 
     164  \begin{split} 
     165    F_u^{lT} &= - \frac{1}{2} e_{2u} e_{3u}\,|u|_{i+1/2} \;\frac{1}{6} \;\delta_{i+1/2}[\tau"_i] 
     166  \end{split} 
    158167\end{equation} 
    159168if the velocity is uniform ($i.e.$ $|u|=cst$) and 
    160 choosing $\tau "_i =\frac{e_{1T}}{e_{2T}\,e_{3T}}\delta _i \left[ \frac{e_{2u} e_{3u} }{e_{1u} } \delta _{i+1/2}[\tau] \right]$ 
     169choosing $\tau "_i =\frac{e_{1T}}{e_{2T}\,e_{3T}}\delta_i \left[ \frac{e_{2u} e_{3u} }{e_{1u} } \delta_{i+1/2}[\tau] \right]$ 
    161170 
    162171sol 1 coefficient at T-point ( add $e_{1u}$ and $e_{1T}$ on both side of first $\delta$): 
    163 \begin{equation} \label{eq:tra_adv_ubs2} 
    164 \begin{split} 
    165 F_u^{lT} 
    166 &= - \frac{1}{12} \frac{e_{2u} e_{3u}}{e_{1u}}\;\delta_{i+1/2}\left[ \frac{e_{1T}^3\,|u|}{e_{1T}e_{2T}\,e_{3T}}\,\delta _i \left[ \frac{e_{2u} e_{3u} }{e_{1u} } \delta _{i+1/2}[\tau] \right] \right] 
    167 \end{split} 
     172\begin{equation} 
     173  \label{eq:tra_adv_ubs2} 
     174  \begin{split} 
     175    F_u^{lT} &= - \frac{1}{12} \frac{e_{2u} e_{3u}}{e_{1u}}\;\delta_{i+1/2}\left[ \frac{e_{1T}^3\,|u|}{e_{1T}e_{2T}\,e_{3T}}\,\delta_i \left[ \frac{e_{2u} e_{3u} }{e_{1u} } \delta_{i+1/2}[\tau] \right] \right] 
     176  \end{split} 
    168177\end{equation} 
    169178which leads to ${A_T^{lT}}^2 = \frac{1}{12} {e_{1T}}^3\ \overline{|u|}^{\,i+1/2}$ 
    170179 
    171180sol 2 coefficient at u-point: split $|u|$ into $\sqrt{|u|}$ and $e_{1T}$ into $\sqrt{e_{1u}}$ 
    172 \begin{equation} \label{eq:tra_adv_ubs2} 
    173 \begin{split} 
    174 F_u^{lT} 
    175 &= - \frac{1}{12} {e_{1u}}^1 \sqrt{e_{1u}|u|} \frac{e_{2u} e_{3u}}{e_{1u}}\;\delta_{i+1/2}\left[ \frac{1}{e_{2T}\,e_{3T}}\,\delta _i \left[ \sqrt{e_{1u}|u|} \frac{e_{2u} e_{3u} }{e_{1u} } \delta _{i+1/2}[\tau] \right] \right] \\ 
    176 &= - \frac{1}{12} e_{1u} \sqrt{e_{1u}|u|\,} \frac{e_{2u} e_{3u}}{e_{1u}}\;\delta_{i+1/2}\left[ \frac{1}{e_{1T}\,e_{2T}\,e_{3T}}\,\delta _i \left[ e_{1u} \sqrt{e_{1u}|u|\,} \frac{e_{2u} e_{3u} }{e_{1u}} \delta _{i+1/2}[\tau] \right] \right] 
    177 \end{split} 
     181\begin{equation} 
     182  \label{eq:tra_adv_ubs2} 
     183  \begin{split} 
     184    F_u^{lT} &= - \frac{1}{12} {e_{1u}}^1 \sqrt{e_{1u}|u|} \frac{e_{2u} e_{3u}}{e_{1u}}\;\delta_{i+1/2}\left[ \frac{1}{e_{2T}\,e_{3T}}\,\delta_i \left[ \sqrt{e_{1u}|u|} \frac{e_{2u} e_{3u} }{e_{1u} } \delta_{i+1/2}[\tau] \right] \right] \\ 
     185    &= - \frac{1}{12} e_{1u} \sqrt{e_{1u}|u|\,} \frac{e_{2u} e_{3u}}{e_{1u}}\;\delta_{i+1/2}\left[ \frac{1}{e_{1T}\,e_{2T}\,e_{3T}}\,\delta_i \left[ e_{1u} \sqrt{e_{1u}|u|\,} \frac{e_{2u} e_{3u} }{e_{1u}} \delta_{i+1/2}[\tau] \right] \right] 
     186  \end{split} 
    178187\end{equation} 
    179188which leads to ${A_u^{lT}} = \frac{1}{12} {e_{1u}}^3\ |u|$ 
    180  
    181189 
    182190% ------------------------------------------------------------------------------------------------------------- 
     
    189197Given the values of a variable $q$ at successive time step, 
    190198the time derivation and averaging operators at the mid time step are: 
    191 \begin{subequations} \label{eq:dt_mt} 
    192 \begin{align} 
    193  \delta _{t+\rdt/2} [q]     &=  \  \ \,   q^{t+\rdt}  - q^{t}     \\ 
    194  \overline q^{\,t+\rdt/2} &= \left\{ q^{t+\rdt} + q^{t} \right\} \; / \; 2 
    195 \end{align} 
    196 \end{subequations} 
     199\[ 
     200  % \label{eq:dt_mt} 
     201  \begin{split} 
     202    \delta_{t+\rdt/2} [q]     &=  \  \ \,   q^{t+\rdt}  - q^{t}      \\ 
     203    \overline q^{\,t+\rdt/2} &= \left\{ q^{t+\rdt} + q^{t} \right\} \; / \; 2 
     204  \end{split} 
     205\] 
    197206As for space operator, 
    198207the adjoint of the derivation and averaging time operators are $\delta_t^*=\delta_{t+\rdt/2}$ and 
     
    200209 
    201210The Leap-frog time stepping given by \autoref{eq:DOM_nxt} can be defined as: 
    202 \begin{equation} \label{eq:LF} 
    203    \frac{\partial q}{\partial t}  
    204          \equiv \frac{1}{\rdt} \overline{ \delta _{t+\rdt/2}[q]}^{\,t}  
    205       =         \frac{q^{t+\rdt}-q^{t-\rdt}}{2\rdt} 
    206 \end{equation}  
     211\[ 
     212  % \label{eq:LF} 
     213  \frac{\partial q}{\partial t} 
     214  \equiv \frac{1}{\rdt} \overline{ \delta_{t+\rdt/2}[q]}^{\,t} 
     215  =         \frac{q^{t+\rdt}-q^{t-\rdt}}{2\rdt} 
     216\]  
    207217Note that \autoref{chap:LF} shows that the leapfrog time step is $\rdt$, 
    208218not $2\rdt$ as it can be found sometimes in literature. 
    209219The leap-Frog time stepping is a second order centered scheme. 
    210220As such it respects the quadratic invariant in integral forms, $i.e.$ the following continuous property, 
    211 \begin{equation} \label{eq:Energy} 
    212 \int_{t_0}^{t_1} {q\, \frac{\partial q}{\partial t} \;dt}  
    213    =\int_{t_0}^{t_1} {\frac{1}{2}\, \frac{\partial q^2}{\partial t} \;dt}  
    214    =  \frac{1}{2} \left( {q_{t_1}}^2 - {q_{t_0}}^2 \right) , 
    215 \end{equation} 
     221\[ 
     222  % \label{eq:Energy} 
     223  \int_{t_0}^{t_1} {q\, \frac{\partial q}{\partial t} \;dt} 
     224  =\int_{t_0}^{t_1} {\frac{1}{2}\, \frac{\partial q^2}{\partial t} \;dt} 
     225  =  \frac{1}{2} \left( {q_{t_1}}^2 - {q_{t_0}}^2 \right) , 
     226\] 
    216227is satisfied in discrete form. 
    217228Indeed,  
    218 \begin{equation} \begin{split} 
    219 \int_{t_0}^{t_1} {q\, \frac{\partial q}{\partial t} \;dt}  
    220    &\equiv \sum\limits_{0}^{N}  
    221          {\frac{1}{\rdt} q^t \ \overline{ \delta _{t+\rdt/2}[q]}^{\,t} \ \rdt}  
    222       \equiv \sum\limits_{0}^{N}  { q^t \ \overline{ \delta _{t+\rdt/2}[q]}^{\,t} } \\ 
    223    &\equiv \sum\limits_{0}^{N}  { \overline{q}^{\,t+\Delta/2}{ \delta _{t+\rdt/2}[q]}} 
    224       \equiv \sum\limits_{0}^{N}  { \frac{1}{2} \delta _{t+\rdt/2}[q^2] }\\ 
    225    &\equiv \sum\limits_{0}^{N}  { \frac{1}{2} \delta _{t+\rdt/2}[q^2] } 
    226       \equiv \frac{1}{2} \left( {q_{t_1}}^2 - {q_{t_0}}^2 \right) 
    227 \end{split} \end{equation} 
     229\[ 
     230  \begin{split} 
     231    \int_{t_0}^{t_1} {q\, \frac{\partial q}{\partial t} \;dt} 
     232    &\equiv \sum\limits_{0}^{N} 
     233    {\frac{1}{\rdt} q^t \ \overline{ \delta_{t+\rdt/2}[q]}^{\,t} \ \rdt} 
     234    \equiv \sum\limits_{0}^{N}  { q^t \ \overline{ \delta_{t+\rdt/2}[q]}^{\,t} } \\ 
     235    &\equiv \sum\limits_{0}^{N}  { \overline{q}^{\,t+\Delta/2}{ \delta_{t+\rdt/2}[q]}} 
     236    \equiv \sum\limits_{0}^{N}  { \frac{1}{2} \delta_{t+\rdt/2}[q^2] }\\ 
     237    &\equiv \sum\limits_{0}^{N}  { \frac{1}{2} \delta_{t+\rdt/2}[q^2] } 
     238    \equiv \frac{1}{2} \left( {q_{t_1}}^2 - {q_{t_0}}^2 \right) 
     239  \end{split} 
     240\] 
    228241NB here pb of boundary condition when applying the adjoint! 
    229242In space, setting to 0 the quantity in land area is sufficient to get rid of the boundary condition  
    230243(equivalently of the boundary value of the integration by part). 
    231244In time this boundary condition is not physical and \textbf{add something here!!!} 
    232  
    233  
    234  
    235  
    236  
    237245 
    238246% ================================================================ 
     
    269277a derivative in the same direction by considering triads. 
    270278For example in the (\textbf{i},\textbf{k}) plane, the four triads are defined at the $(i,k)$ $T$-point as follows: 
    271 \begin{equation} \label{eq:Gf_triads} 
    272 _i^k \mathbb{T}_{i_p}^{k_p} (T) 
    273 = \frac{1}{4} \ {b_u}_{\,i+i_p}^{\,k}  \  A_i^k    \left(   
    274                                                      \frac{ \delta_{i + i_p}[T^k] }{ {e_{1u}}_{\,i + i_p}^{\,k} }  
    275 -\ {_i^k \mathbb{R}_{i_p}^{k_p}} \ \frac{ \delta_{k+k_p} [T^i] }{ {e_{3w}}_{\,i}^{\,k+k_p} }  
    276                              \right) 
     279\begin{equation} 
     280  \label{eq:Gf_triads} 
     281  _i^k \mathbb{T}_{i_p}^{k_p} (T) 
     282  = \frac{1}{4} \ {b_u}_{\,i+i_p}^{\,k}  \  A_i^k     \left( 
     283    \frac{ \delta_{i + i_p}[T^k] }{ {e_{1u}}_{\,i + i_p}^{\,k} } 
     284    -\ {_i^k \mathbb{R}_{i_p}^{k_p}} \ \frac{ \delta_{k+k_p} [T^i] }{ {e_{3w}}_{\,i}^{\,k+k_p} } 
     285  \right) 
    277286\end{equation} 
    278287where the indices $i_p$ and $k_p$ define the four triads and take the following value: 
     
    281290$A_i^k$ is the lateral eddy diffusivity coefficient defined at $T$-point, 
    282291and $_i^k \mathbb{R}_{i_p}^{k_p}$ is the slope associated with each triad: 
    283 \begin{equation} \label{eq:Gf_slopes} 
    284 _i^k \mathbb{R}_{i_p}^{k_p}  
    285 =\frac{ {e_{3w}}_{\,i}^{\,k+k_p}} { {e_{1u}}_{\,i+i_p}^{\,k}} \ \frac  
    286 {\left(\alpha / \beta \right)_i^k  \ \delta_{i + i_p}[T^k] - \delta_{i + i_p}[S^k] } 
    287 {\left(\alpha / \beta \right)_i^k  \ \delta_{k+k_p}[T^i ] - \delta_{k+k_p}[S^i ] } 
     292\begin{equation} 
     293  \label{eq:Gf_slopes} 
     294  _i^k \mathbb{R}_{i_p}^{k_p} 
     295  =\frac{ {e_{3w}}_{\,i}^{\,k+k_p}} { {e_{1u}}_{\,i+i_p}^{\,k}} \ \frac 
     296  {\left(\alpha / \beta \right)_i^k  \ \delta_{i + i_p}[T^k] - \delta_{i + i_p}[S^k] } 
     297  {\left(\alpha / \beta \right)_i^k  \ \delta_{k+k_p}[T^i ] - \delta_{k+k_p}[S^i ] } 
    288298\end{equation} 
    289299Note that in \autoref{eq:Gf_slopes} we use the ratio $\alpha / \beta$ instead of 
     
    296306 
    297307%>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    298 \begin{figure}[!ht] \begin{center} 
    299 \includegraphics[width=0.70\textwidth]{Fig_ISO_triad} 
    300 \caption{  \protect\label{fig:ISO_triad} 
    301   Triads used in the Griffies's like iso-neutral diffision scheme for 
    302   $u$-component (upper panel) and $w$-component (lower panel).} 
    303 \end{center} 
     308\begin{figure}[!ht] 
     309  \begin{center} 
     310    \includegraphics[width=0.70\textwidth]{Fig_ISO_triad} 
     311    \caption{ 
     312      \protect\label{fig:ISO_triad} 
     313      Triads used in the Griffies's like iso-neutral diffision scheme for 
     314      $u$-component (upper panel) and $w$-component (lower panel). 
     315    } 
     316  \end{center} 
    304317\end{figure} 
    305318%>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     
    307320The four iso-neutral fluxes associated with the triads are defined at $T$-point.  
    308321They take the following expression: 
    309 \begin{flalign} \label{eq:Gf_fluxes} 
    310 \begin{split} 
    311 {_i^k {\mathbb{F}_u}_{i_p}^{k_p} } (T)  
    312    &= \ \; \qquad  \quad    { _i^k \mathbb{T}_{i_p}^{k_p} }(T) \;\ / \ { {e_{1u}}_{\,i+i_p}^{\,k}}    \\ 
    313 {_i^k {\mathbb{F}_w}_{i_p}^{k_p} } (T) 
    314    &=  -\; { _i^k \mathbb{R}_{i_p}^{k_p} } 
    315              \ \; { _i^k \mathbb{T}_{i_p}^{k_p} }(T) \;\ / \ { {e_{3w}}_{\,i}^{\,k+k_p}} 
    316 \end{split} 
    317 \end{flalign} 
     322\begin{flalign*} 
     323  % \label{eq:Gf_fluxes} 
     324  \begin{split} 
     325    {_i^k {\mathbb{F}_u}_{i_p}^{k_p} } (T) 
     326    &= \ \; \qquad  \quad    { _i^k \mathbb{T}_{i_p}^{k_p} }(T) \;\ / \ { {e_{1u}}_{\,i+i_p}^{\,k}}    \\ 
     327    {_i^k {\mathbb{F}_w}_{i_p}^{k_p} } (T) 
     328    &=  -\; { _i^k \mathbb{R}_{i_p}^{k_p} } 
     329    \ \; { _i^k \mathbb{T}_{i_p}^{k_p} }(T) \;\ / \ { {e_{3w}}_{\,i}^{\,k+k_p}} 
     330  \end{split} 
     331\end{flalign*} 
    318332 
    319333The resulting iso-neutral fluxes at $u$- and $w$-points are then given by 
    320334the sum of the fluxes that cross the $u$- and $w$-face (\autoref{fig:ISO_triad}): 
    321 \begin{flalign} \label{eq:iso_flux}  
    322 \textbf{F}_{iso}(T)  
    323 &\equiv  \sum_{\substack{i_p,\,k_p}}  
    324    \begin{pmatrix}  
    325       {_{i+1/2-i_p}^k {\mathbb{F}_u}_{i_p}^{k_p} } (T)      \\ 
    326       \\ 
    327       {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p} } (T)      \\    
    328    \end{pmatrix}    \notag \\ 
    329 &  \notag \\ 
    330 &\equiv  \sum_{\substack{i_p,\,k_p}}  
    331    \begin{pmatrix}  
    332       && { _{i+1/2-i_p}^k \mathbb{T}_{i_p}^{k_p} }(T) \;\ / \ { {e_{1u}}_{\,i+1/2}^{\,k} }    \\ 
    333       \\ 
    334       & -\; { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} } 
    335         & {_i^{k+1/2-k_p} \mathbb{T}_{i_p}^{k_p} }(T) \;\ / \ { {e_{3w}}_{\,i}^{\,k+1/2} }   \\    
    336    \end{pmatrix}      % \\ 
    337 % &\\ 
    338 % &\equiv  \sum_{\substack{i_p,\,k_p}}  
    339 %    \begin{pmatrix}  
    340 %       \qquad  \qquad  \qquad  
    341 %       \frac{1}{ {e_{1u}}_{\,i+1/2}^{\,k} }  \ \;   
    342 %        { _{i+1/2-i_p}^k \mathbb{T}_{i_p}^{k_p} }(T)\\ 
    343 %       \\ 
    344 %       -\frac{1}{ {e_{3w}}_{\,i}^{\,k+1/2} }  \ \;  
    345 %        { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} } \ \;   
    346 %                  {_i^{k+1/2-k_p} \mathbb{T}_{i_p}^{k_p} }(T)\\    
    347 %    \end{pmatrix}       
     335\begin{flalign} 
     336  \label{eq:iso_flux} 
     337  \textbf{F}_{iso}(T) 
     338  &\equiv  \sum_{\substack{i_p,\,k_p}} 
     339  \begin{pmatrix} 
     340    {_{i+1/2-i_p}^k {\mathbb{F}_u}_{i_p}^{k_p} } (T) \\ \\ 
     341    {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p} } (T) 
     342  \end{pmatrix} 
     343  \notag \\ 
     344  &  \notag \\ 
     345  &\equiv  \sum_{\substack{i_p,\,k_p}} 
     346  \begin{pmatrix} 
     347    && { _{i+1/2-i_p}^k \mathbb{T}_{i_p}^{k_p} }(T) \;\ / \ { {e_{1u}}_{\,i+1/2}^{\,k} } \\ \\ 
     348    & -\; { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} } 
     349    & {_i^{k+1/2-k_p} \mathbb{T}_{i_p}^{k_p} }(T) \;\ / \ { {e_{3w}}_{\,i}^{\,k+1/2} } 
     350  \end{pmatrix}      % \\ 
     351  % &\\ 
     352  % &\equiv  \sum_{\substack{i_p,\,k_p}} 
     353  % \begin{pmatrix} 
     354  %   \qquad  \qquad  \qquad 
     355  %   \frac{1}{ {e_{1u}}_{\,i+1/2}^{\,k} }  \ \; 
     356  %   { _{i+1/2-i_p}^k \mathbb{T}_{i_p}^{k_p} }(T)\\ 
     357  %   \\ 
     358  %   -\frac{1}{ {e_{3w}}_{\,i}^{\,k+1/2} }  \ \; 
     359  %   { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} } \ \; 
     360  %   {_i^{k+1/2-k_p} \mathbb{T}_{i_p}^{k_p} }(T)\\ 
     361  % \end{pmatrix} 
    348362\end{flalign} 
    349363resulting in a iso-neutral diffusion tendency on temperature given by 
    350364the divergence of the sum of all the four triad fluxes: 
    351 \begin{equation} \label{eq:Gf_operator} 
    352 D_l^T = \frac{1}{b_T}  \sum_{\substack{i_p,\,k_p}} \left\{   
    353        \delta_{i} \left[{_{i+1/2-i_p}^k {\mathbb{F}_u }_{i_p}^{k_p}} \right]  
    354         + \delta_{k} \left[ {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p}} \right]   \right\} 
     365\begin{equation} 
     366  \label{eq:Gf_operator} 
     367  D_l^T = \frac{1}{b_T}  \sum_{\substack{i_p,\,k_p}} \left\{ 
     368    \delta_{i} \left[{_{i+1/2-i_p}^k {\mathbb{F}_u }_{i_p}^{k_p}} \right] 
     369    + \delta_{k} \left[ {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p}} \right]   \right\} 
    355370\end{equation} 
    356371where $b_T= e_{1T}\,e_{2T}\,e_{3T}$ is the volume of $T$-cells.  
     
    361376  The discretization of the diffusion operator recovers the traditional five-point Laplacian in 
    362377  the limit of flat iso-neutral direction: 
    363 \begin{equation} \label{eq:Gf_property1a} 
    364 D_l^T = \frac{1}{b_T}  \ \delta_{i}  
    365    \left[ \frac{e_{2u}\,e_{3u}}{e_{1u}} \; \overline{A}^{\,i} \; \delta_{i+1/2}[T] \right]  
    366 \qquad  \text{when} \quad  
    367    { _i^k \mathbb{R}_{i_p}^{k_p} }=0 
    368 \end{equation} 
     378  \[ 
     379    % \label{eq:Gf_property1a} 
     380    D_l^T = \frac{1}{b_T}  \ \delta_{i} 
     381    \left[ \frac{e_{2u}\,e_{3u}}{e_{1u}} \; \overline{A}^{\,i} \; \delta_{i+1/2}[T] \right] 
     382    \qquad  \text{when} \quad 
     383    { _i^k \mathbb{R}_{i_p}^{k_p} }=0 
     384  \] 
    369385 
    370386\item[$\bullet$ implicit treatment in the vertical] 
     
    374390  This is of paramount importance since it means that 
    375391  the implicit in time algorithm for solving the vertical diffusion equation can be used to evaluate this term. 
    376   It is a necessity since the vertical eddy diffusivity associated with this term,   
    377 \begin{equation} 
    378     \sum_{\substack{i_p, \,k_p}} \left\{   
     392  It is a necessity since the vertical eddy diffusivity associated with this term, 
     393  \[ 
     394    \sum_{\substack{i_p, \,k_p}} \left\{ 
    379395      A_i^k \; \left(_i^k \mathbb{R}_{i_p}^{k_p}\right)^2 
    380    \right\}  
    381 \end{equation} 
    382 can be quite large. 
     396    \right\} 
     397  \] 
     398  can be quite large. 
    383399 
    384400\item[$\bullet$ pure iso-neutral operator] 
    385401  The iso-neutral flux of locally referenced potential density is zero, $i.e.$ 
    386 \begin{align} \label{eq:Gf_property2} 
    387 \begin{matrix} 
    388 &{_i^k {\mathbb{F}_u}_{i_p}^{k_p} (\rho)}  
    389    &=    &\alpha_i^k   &{_i^k {\mathbb{F}_u}_{i_p}^{k_p} } (T)  
    390    &- \ \;  \beta _i^k    &{_i^k {\mathbb{F}_u}_{i_p}^{k_p} } (S) & = \ 0   \\ 
    391 &{_i^k {\mathbb{F}_w}_{i_p}^{k_p} (\rho)}  
    392    &=    &\alpha_i^k   &{_i^k {\mathbb{F}_w}_{i_p}^{k_p} } (T)  
    393    &- \  \; \beta _i^k    &{_i^k {\mathbb{F}_w}_{i_p}^{k_p} } (S)  &= \ 0 
    394 \end{matrix} 
    395 \end{align} 
    396 This result is trivially obtained using the \autoref{eq:Gf_triads} applied to $T$ and $S$ and 
    397 the definition of the triads' slopes \autoref{eq:Gf_slopes}. 
     402  \begin{align*} 
     403    % \label{eq:Gf_property2} 
     404    \begin{matrix} 
     405      &{_i^k {\mathbb{F}_u}_{i_p}^{k_p} (\rho)} 
     406      &=    &\alpha_i^k   &{_i^k {\mathbb{F}_u}_{i_p}^{k_p} } (T) 
     407      &- \ \;  \beta _i^k    &{_i^k {\mathbb{F}_u}_{i_p}^{k_p} } (S) & = \ 0   \\ 
     408      &{_i^k {\mathbb{F}_w}_{i_p}^{k_p} (\rho)} 
     409      &=    &\alpha_i^k   &{_i^k {\mathbb{F}_w}_{i_p}^{k_p} } (T) 
     410      &- \  \; \beta _i^k    &{_i^k {\mathbb{F}_w}_{i_p}^{k_p} } (S)  &= \ 0 
     411    \end{matrix} 
     412  \end{align*} 
     413  This result is trivially obtained using the \autoref{eq:Gf_triads} applied to $T$ and $S$ and 
     414  the definition of the triads' slopes \autoref{eq:Gf_slopes}. 
    398415 
    399416\item[$\bullet$ conservation of tracer] 
    400417  The iso-neutral diffusion term conserve the total tracer content, $i.e.$ 
    401 \begin{equation} \label{eq:Gf_property1} 
    402 \sum_{i,j,k} \left\{ D_l^T \ b_T \right\} = 0 
    403 \end{equation} 
     418  \[ 
     419    % \label{eq:Gf_property1} 
     420    \sum_{i,j,k} \left\{ D_l^T \ b_T \right\} = 0 
     421  \] 
    404422This property is trivially satisfied since the iso-neutral diffusive operator is written in flux form. 
    405423 
    406424\item[$\bullet$ decrease of tracer variance] 
    407425  The iso-neutral diffusion term does not increase the total tracer variance, $i.e.$ 
    408 \begin{equation} \label{eq:Gf_property1} 
    409 \sum_{i,j,k} \left\{ T \ D_l^T \ b_T \right\} \leq 0 
    410 \end{equation} 
     426  \[ 
     427    % \label{eq:Gf_property1} 
     428    \sum_{i,j,k} \left\{ T \ D_l^T \ b_T \right\} \leq 0 
     429  \] 
    411430The property is demonstrated in the \autoref{apdx:Gf_operator}. 
    412431It is a key property for a diffusion term. 
     
    418437\item[$\bullet$ self-adjoint operator] 
    419438  The iso-neutral diffusion operator is self-adjoint, $i.e.$ 
    420 \begin{equation} \label{eq:Gf_property1} 
    421 \sum_{i,j,k} \left\{ S \ D_l^T \ b_T \right\} = \sum_{i,j,k} \left\{ D_l^S \ T \ b_T \right\}  
    422 \end{equation} 
     439  \[ 
     440    % \label{eq:Gf_property1} 
     441    \sum_{i,j,k} \left\{ S \ D_l^T \ b_T \right\} = \sum_{i,j,k} \left\{ D_l^S \ T \ b_T \right\} 
     442  \] 
    423443In other word, there is no needs to develop a specific routine from the adjoint of this operator. 
    424444We just have to apply the same routine. 
     
    427447\end{description} 
    428448 
    429  
    430 $\ $\newline      %force an empty line 
    431449% ================================================================ 
    432450% Skew flux formulation for Eddy Induced Velocity :  
     
    443461 
    444462The eddy induced velocity is given by:  
    445 \begin{equation} \label{eq:eiv_v} 
    446 \begin{split} 
    447  u^* & = - \frac{1}{e_2\,e_{3}}          \;\partial_k \left( e_2 \, A_e \; r_i  \right)    
    448           = - \frac{1}{e_3}                     \;\partial_k \left(           A_e \; r_i  \right)            \\ 
    449  v^* & = - \frac{1}{e_1\,e_3}\;             \partial_k \left( e_1 \, A_e \; r_j  \right)    
    450           = - \frac{1}{e_3}                     \;\partial_k \left(           A_e \; r_j  \right)             \\ 
    451 w^* & =    \frac{1}{e_1\,e_2}\; \left\{   \partial_i  \left( e_2 \, A_e \; r_i  \right)  
    452                              + \partial_j  \left( e_1 \, A_e \;r_j   \right) \right\}   \\ 
    453 \end{split} 
     463\begin{equation} 
     464  \label{eq:eiv_v} 
     465  \begin{split} 
     466    u^* & = - \frac{1}{e_2\,e_{3}}          \;\partial_k \left( e_2 \, A_e \; r_i  \right) 
     467    = - \frac{1}{e_3}                     \;\partial_k \left(           A_e \; r_i  \right)            \\ 
     468    v^* & = - \frac{1}{e_1\,e_3}\;             \partial_k \left( e_1 \, A_e \; r_j  \right) 
     469    = - \frac{1}{e_3}                     \;\partial_k \left(           A_e \; r_j  \right)             \\ 
     470    w^* & =    \frac{1}{e_1\,e_2}\; \left\{   \partial_i  \left( e_2 \, A_e \; r_i  \right) 
     471      + \partial_j  \left( e_1 \, A_e \;r_j   \right) \right\} 
     472  \end{split} 
    454473\end{equation} 
    455474where $A_{e}$ is the eddy induced velocity coefficient, 
     
    475494%\end{split} 
    476495%\end{equation} 
    477 \begin{equation} \label{eq:eiv_vd}   
    478 \textbf{F}_{eiv}^T   \equiv   \left( \begin{aligned}                                 
    479  \sum_{\substack{i_p,\,k_p}} & 
    480  +{e_{2u}}_{i+1/2-i_p}^{k}                                  \ \ {A_{e}}_{i+1/2-i_p}^{k}  
    481 \ \ \ { _{i+1/2-i_p}^k \mathbb{R}_{i_p}^{k_p} }    \ \ \delta_{k+k_p}[T_{i+1/2-i_p}]      \\ 
    482     \\ 
    483  \sum_{\substack{i_p,\,k_p}} & 
    484  - {e_{2u}}_i^{k+1/2-k_p}                                      \ {A_{e}}_i^{k+1/2-k_p}  
    485 \ \ { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} }    \ \delta_{i+i_p}[T^{k+1/2-k_p}]    \\    
    486 \end{aligned}   \right) 
    487 \end{equation} 
     496\[ 
     497  % \label{eq:eiv_vd} 
     498  \textbf{F}_{eiv}^T   \equiv   \left( 
     499    \begin{aligned} 
     500      \sum_{\substack{i_p,\,k_p}} & 
     501      +{e_{2u}}_{i+1/2-i_p}^{k}                                  \ \ {A_{e}}_{i+1/2-i_p}^{k} 
     502      \ \ \ { _{i+1/2-i_p}^k \mathbb{R}_{i_p}^{k_p} }    \ \ \delta_{k+k_p}[T_{i+1/2-i_p}] \\ \\ 
     503      \sum_{\substack{i_p,\,k_p}} & 
     504      - {e_{2u}}_i^{k+1/2-k_p}                                      \ {A_{e}}_i^{k+1/2-k_p} 
     505      \ \ { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} }    \ \delta_{i+i_p}[T^{k+1/2-k_p}] 
     506    \end{aligned} 
     507  \right) 
     508\] 
    488509 
    489510\citep{Griffies_JPO98} introduces another way to implement the eddy induced advection, the so-called skew form. 
     
    491512For example in the (\textbf{i},\textbf{k}) plane, the tracer advective fluxes can be transformed as follows: 
    492513\begin{flalign*} 
    493 \begin{split} 
    494 \textbf{F}_{eiv}^T =  
    495 \begin{pmatrix}  
    496            {e_{2}\,e_{3}\;  u^*}       \\ 
    497       {e_{1}\,e_{2}\; w^*}  \\ 
    498 \end{pmatrix}   \;   T 
    499 &= 
    500 \begin{pmatrix}  
    501            { - \partial_k \left( e_{2} \, A_{e} \; r_i \right) \; T \;}       \\ 
    502       {+ \partial_i  \left( e_{2} \, A_{e} \; r_i \right) \; T \;}    \\ 
    503 \end{pmatrix}        \\ 
    504 &=        
    505 \begin{pmatrix}  
    506            { - \partial_k \left( e_{2} \, A_{e} \; r_i  \; T \right) \;}  \\ 
    507       {+ \partial_i  \left( e_{2} \, A_{e} \; r_i  \; T \right) \;}   \\ 
    508 \end{pmatrix}         
    509  +  
    510 \begin{pmatrix}  
    511            {+ e_{2} \, A_{e} \; r_i  \; \partial_k T}  \\ 
    512       { - e_{2} \, A_{e} \; r_i  \; \partial_i  T}  \\ 
    513 \end{pmatrix}    
    514 \end{split} 
     514  \begin{split} 
     515    \textbf{F}_{eiv}^T = 
     516    \begin{pmatrix} 
     517      {e_{2}\,e_{3}\;  u^*}      \\ 
     518      {e_{1}\,e_{2}\; w^*} 
     519    \end{pmatrix} 
     520    \;   T 
     521    &= 
     522    \begin{pmatrix} 
     523      { - \partial_k \left( e_{2} \, A_{e} \; r_i \right) \; T \;}      \\ 
     524      {+ \partial_i  \left( e_{2} \, A_{e} \; r_i \right) \; T \;} 
     525    \end{pmatrix} 
     526    \\ 
     527    &= 
     528    \begin{pmatrix} 
     529      { - \partial_k \left( e_{2} \, A_{e} \; r_i  \; T \right) \;}  \\ 
     530      {+ \partial_i  \left( e_{2} \, A_{e} \; r_i  \; T \right) \;} 
     531    \end{pmatrix} 
     532    + 
     533    \begin{pmatrix} 
     534      {+ e_{2} \, A_{e} \; r_i  \; \partial_k T}  \\ 
     535      { - e_{2} \, A_{e} \; r_i  \; \partial_i  T} 
     536    \end{pmatrix} 
     537  \end{split} 
    515538\end{flalign*} 
    516539and since the eddy induces velocity field is no-divergent, 
    517540we end up with the skew form of the eddy induced advective fluxes: 
    518 \begin{equation} \label{eq:eiv_skew_continuous} 
    519 \textbf{F}_{eiv}^T = \begin{pmatrix}  
    520            {+ e_{2} \, A_{e} \; r_i  \; \partial_k T}   \\ 
    521       { - e_{2} \, A_{e} \; r_i  \; \partial_i  T}  \\ 
    522                                  \end{pmatrix} 
     541\begin{equation} 
     542  \label{eq:eiv_skew_continuous} 
     543  \textbf{F}_{eiv}^T = 
     544  \begin{pmatrix} 
     545    {+ e_{2} \, A_{e} \; r_i  \; \partial_k T}   \\ 
     546    { - e_{2} \, A_{e} \; r_i  \; \partial_i  T} 
     547  \end{pmatrix} 
    523548\end{equation} 
    524549The tendency associated with eddy induced velocity is then simply the divergence of 
     
    528553Another interesting property of \autoref{eq:eiv_skew_continuous} form is that when $A=A_e$, 
    529554a simplification occurs in the sum of the iso-neutral diffusion and eddy induced velocity terms: 
    530 \begin{flalign} \label{eq:eiv_skew+eiv_continuous} 
    531 \textbf{F}_{iso}^T + \textbf{F}_{eiv}^T &=  
    532 \begin{pmatrix}  
    533            + \frac{e_2\,e_3\,}{e_1} A \;\partial_i T -  e_2 \, A \; r_i                              \;\partial_k T   \\ 
    534       -  e_2 \, A_{e} \; r_i           \;\partial_i T + \frac{e_1\,e_2}{e_3} \, A \; r_i^2 \;\partial_k T   \\ 
    535 \end{pmatrix} 
    536 + 
    537 \begin{pmatrix}  
    538            {+ e_{2} \, A_{e} \; r_i  \; \partial_k T}   \\ 
    539       { - e_{2} \, A_{e} \; r_i  \; \partial_i  T}  \\ 
    540 \end{pmatrix}      \\ 
    541 &= \begin{pmatrix}  
    542            + \frac{e_2\,e_3\,}{e_1} A \;\partial_i T    \\ 
    543       -  2\; e_2 \, A_{e} \; r_i      \;\partial_i T + \frac{e_1\,e_2}{e_3} \, A \; r_i^2 \;\partial_k T   \\ 
    544 \end{pmatrix} 
    545 \end{flalign} 
     555\begin{flalign*} 
     556  % \label{eq:eiv_skew+eiv_continuous} 
     557  \textbf{F}_{iso}^T + \textbf{F}_{eiv}^T &= 
     558  \begin{pmatrix} 
     559    + \frac{e_2\,e_3\,}{e_1} A \;\partial_i T -  e_2 \, A \; r_i                              \;\partial_k T   \\ 
     560    -  e_2 \, A_{e} \; r_i           \;\partial_i T + \frac{e_1\,e_2}{e_3} \, A \; r_i^2 \;\partial_k T 
     561  \end{pmatrix} 
     562  + 
     563  \begin{pmatrix} 
     564    {+ e_{2} \, A_{e} \; r_i  \; \partial_k T}   \\ 
     565    { - e_{2} \, A_{e} \; r_i  \; \partial_i  T} 
     566  \end{pmatrix} 
     567  \\ 
     568  &= 
     569  \begin{pmatrix} 
     570    + \frac{e_2\,e_3\,}{e_1} A \;\partial_i T    \\ 
     571    -  2\; e_2 \, A_{e} \; r_i      \;\partial_i T + \frac{e_1\,e_2}{e_3} \, A \; r_i^2 \;\partial_k T 
     572  \end{pmatrix} 
     573\end{flalign*} 
    546574The horizontal component reduces to the one use for an horizontal laplacian operator and 
    547575the vertical one keeps the same complexity, but not more. 
     
    552580Using the slopes \autoref{eq:Gf_slopes} and defining $A_e$ at $T$-point($i.e.$ as $A$, 
    553581the eddy diffusivity coefficient), the resulting discret form is given by: 
    554 \begin{equation} \label{eq:eiv_skew}   
    555 \textbf{F}_{eiv}^T   \equiv   \frac{1}{4} \left( \begin{aligned}                                 
    556  \sum_{\substack{i_p,\,k_p}} & 
    557  +{e_{2u}}_{i+1/2-i_p}^{k}                                  \ \ {A_{e}}_{i+1/2-i_p}^{k}  
    558 \ \ \ { _{i+1/2-i_p}^k \mathbb{R}_{i_p}^{k_p} }    \ \ \delta_{k+k_p}[T_{i+1/2-i_p}]      \\ 
    559     \\ 
    560  \sum_{\substack{i_p,\,k_p}} & 
    561  - {e_{2u}}_i^{k+1/2-k_p}                                      \ {A_{e}}_i^{k+1/2-k_p}  
    562 \ \ { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} }    \ \delta_{i+i_p}[T^{k+1/2-k_p}]    \\    
    563 \end{aligned}   \right) 
     582\begin{equation} 
     583  \label{eq:eiv_skew} 
     584  \textbf{F}_{eiv}^T   \equiv   \frac{1}{4} \left( 
     585    \begin{aligned} 
     586      \sum_{\substack{i_p,\,k_p}} & 
     587      +{e_{2u}}_{i+1/2-i_p}^{k}                                  \ \ {A_{e}}_{i+1/2-i_p}^{k} 
     588      \ \ \ { _{i+1/2-i_p}^k \mathbb{R}_{i_p}^{k_p} }    \ \ \delta_{k+k_p}[T_{i+1/2-i_p}] \\ \\ 
     589      \sum_{\substack{i_p,\,k_p}} & 
     590      - {e_{2u}}_i^{k+1/2-k_p}                                      \ {A_{e}}_i^{k+1/2-k_p} 
     591      \ \ { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} }    \ \delta_{i+i_p}[T^{k+1/2-k_p}] 
     592    \end{aligned} 
     593  \right) 
    564594\end{equation} 
    565595Note that \autoref{eq:eiv_skew} is valid in $z$-coordinate with or without partial cells.  
     
    572602$i.e.$ it does not include a diffusive component but is a "pure" advection term. 
    573603 
    574  
    575  
    576  
    577604$\ $\newpage      %force an empty line 
    578605% ================================================================ 
     
    587614 
    588615The continuous property to be demonstrated is: 
     616\[ 
     617  \int_D  D_l^T \; T \;dv   \leq 0 
     618\] 
     619The discrete form of its left hand side is obtained using \autoref{eq:iso_flux} 
     620 
    589621\begin{align*} 
    590 \int_D  D_l^T \; T \;dv   \leq 0 
    591 \end{align*} 
    592 The discrete form of its left hand side is obtained using \autoref{eq:iso_flux} 
    593  
    594 \begin{align*} 
    595 &\int_D  D_l^T \; T \;dv \equiv  \sum_{i,k} \left\{ T \ D_l^T \ b_T \right\}    \\ 
    596 &\equiv + \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{   
    597       \delta_{i} \left[{_{i+1/2-i_p}^k {\mathbb{F}_u }_{i_p}^{k_p}} \right]  
    598         + \delta_{k} \left[ {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p}} \right]  \ T \right\}    \\ 
    599 &\equiv  - \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{   
    600                 {_{i+1/2-i_p}^k {\mathbb{F}_u }_{i_p}^{k_p}} \ \delta_{i+1/2} [T] 
    601              + {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p}}  \ \delta_{k+1/2} [T]   \right\}      \\ 
    602 &\equiv -\sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{   
    603    \frac{ _{i+1/2-i_p}^k \mathbb{T}_{i_p}^{k_p} (T) }{ {e_{1u}}_{\,i+1/2}^{\,k} }  \ \delta_{i+1/2} [T] 
    604  - { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} } \ \;  
    605    \frac{ _i^{k+1/2-k_p} \mathbb{T}_{i_p}^{k_p} (T) }{ {e_{3w}}_{\,i}^{\,k+1/2}  } \ \delta_{k+1/2} [T]    
    606                                                                        \right\}      \\ 
    607 % 
    608 \allowdisplaybreaks 
    609 \intertext{ Expending the summation on $i_p$ and $k_p$, it becomes:} 
    610 % 
    611 &\equiv -\sum_{i,k} 
    612 \begin{Bmatrix}   
    613 &\ \ \Bigl(  { _{i+1}^{k} \mathbb{T}_{-1/2}^{-1/2} (T) }  
    614 &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}}  
    615 & -\ \ {_{i}^{k+1} \mathbb{R}_{-1/2}^{-1/2}}  
    616 &      {_{i}^{k+1} \mathbb{T}_{-1/2}^{-1/2} (T) }    
    617 &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr) 
    618 & \\ 
    619 &+\Bigl( \ \;\; { _i^k \mathbb{T}_{+1/2}^{-1/2} (T) }   
    620 &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}}  
    621 & -\ \ {_i^{k+1} \mathbb{R}_{+1/2}^{-1/2}} 
    622 & { _i^{k+1} \mathbb{T}_{+1/2}^{-1/2} (T) }    
    623 &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}      \Bigr) 
    624 & \\ 
    625 &+\Bigl(  { _{i+1}^{k} \mathbb{T}_{-1/2}^{+1/2} (T) }  
    626 &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}}  
    627 & -\ \ \ \;\;{_{i}^{k} \mathbb{R}_{-1/2}^{+1/2}}  
    628 &      \ \;\;{_{i}^{k} \mathbb{T}_{-1/2}^{+1/2} (T) }    
    629 &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr) 
    630 & \\ 
    631 &+\Bigl( \ \;\; { _{i}^{k} \mathbb{T}_{+1/2}^{+1/2} (T) }  
    632 &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}}  
    633 & -\ \ \ \;\;{_{i}^{k} \mathbb{R}_{+1/2}^{+1/2}}  
    634 &      \ \;\;{_{i}^{k} \mathbb{T}_{+1/2}^{+1/2} (T) }    
    635 &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr)   \\ 
    636 \end{Bmatrix} 
    637 % 
    638 \allowdisplaybreaks 
    639   \intertext{The summation is done over all $i$ and $k$ indices, 
     622  &\int_D  D_l^T \; T \;dv \equiv  \sum_{i,k} \left\{ T \ D_l^T \ b_T \right\}    \\ 
     623  &\equiv + \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{ 
     624    \delta_{i} \left[{_{i+1/2-i_p}^k {\mathbb{F}_u }_{i_p}^{k_p}} \right] 
     625    + \delta_{k} \left[ {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p}} \right]  \ T \right\}    \\ 
     626  &\equiv  - \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{ 
     627    {_{i+1/2-i_p}^k {\mathbb{F}_u }_{i_p}^{k_p}} \ \delta_{i+1/2} [T] 
     628    + {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p}}  \ \delta_{k+1/2} [T]   \right\}      \\ 
     629  &\equiv -\sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{ 
     630    \frac{ _{i+1/2-i_p}^k \mathbb{T}_{i_p}^{k_p} (T) }{ {e_{1u}}_{\,i+1/2}^{\,k} }  \ \delta_{i+1/2} [T] 
     631    - { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} } \ \; 
     632    \frac{ _i^{k+1/2-k_p} \mathbb{T}_{i_p}^{k_p} (T) }{ {e_{3w}}_{\,i}^{\,k+1/2}  } \ \delta_{k+1/2} [T] 
     633    \right\}      \\ 
     634    % 
     635  \allowdisplaybreaks 
     636  \intertext{ Expending the summation on $i_p$ and $k_p$, it becomes:} 
     637  % 
     638  &\equiv -\sum_{i,k} 
     639    \begin{Bmatrix} 
     640      &\ \ \Bigl(  { _{i+1}^{k} \mathbb{T}_{-1/2}^{-1/2} (T) } 
     641      &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}} 
     642      & -\ \ {_{i}^{k+1} \mathbb{R}_{-1/2}^{-1/2}} 
     643      &      {_{i}^{k+1} \mathbb{T}_{-1/2}^{-1/2} (T) } 
     644      &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr) 
     645      & \\ 
     646      &+\Bigl( \ \;\; { _i^k \mathbb{T}_{+1/2}^{-1/2} (T) } 
     647      &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}} 
     648      & -\ \ {_i^{k+1} \mathbb{R}_{+1/2}^{-1/2}} 
     649      & { _i^{k+1} \mathbb{T}_{+1/2}^{-1/2} (T) } 
     650      &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}      \Bigr) 
     651      & \\ 
     652      &+\Bigl(  { _{i+1}^{k} \mathbb{T}_{-1/2}^{+1/2} (T) } 
     653      &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}} 
     654      & -\ \ \ \;\;{_{i}^{k} \mathbb{R}_{-1/2}^{+1/2}} 
     655      &      \ \;\;{_{i}^{k} \mathbb{T}_{-1/2}^{+1/2} (T) } 
     656      &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr) 
     657      & \\ 
     658      &+\Bigl( \ \;\; { _{i}^{k} \mathbb{T}_{+1/2}^{+1/2} (T) } 
     659      &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}} 
     660      & -\ \ \ \;\;{_{i}^{k} \mathbb{R}_{+1/2}^{+1/2}} 
     661      &      \ \;\;{_{i}^{k} \mathbb{T}_{+1/2}^{+1/2} (T) } 
     662      &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr)   \\ 
     663    \end{Bmatrix} 
     664    % 
     665  \allowdisplaybreaks 
     666  \intertext{ 
     667  The summation is done over all $i$ and $k$ indices, 
    640668  it is therefore possible to introduce a shift of $-1$ either in $i$ or $k$ direction in order to 
    641669  regroup all the terms of the summation by triad at a ($i$,$k$) point. 
    642670  In other words, we regroup all the terms in the neighbourhood that contain a triad at the same ($i$,$k$) indices. 
    643   It becomes: } 
    644 % 
    645 &\equiv -\sum_{i,k} 
    646 \begin{Bmatrix}   
    647 &\ \ \Bigl(  {_i^k \mathbb{T}_{-1/2}^{-1/2} (T) }  
    648 &\frac{ \delta_{i -1/2} [T] }{{e_{1u} }_{\,i-1/2}^{\,k}}  
    649 & -\ \ {_i^k \mathbb{R}_{-1/2}^{-1/2}}  
    650 &      {_i^k \mathbb{T}_{-1/2}^{-1/2} (T) }    
    651 &\frac{ \delta_{k-1/2} [T] }{{e_{3w}}_{\,i}^{\,k-1/2}}     \Bigr) 
    652 & \\ 
    653 &+\Bigl(  { _i^k \mathbb{T}_{+1/2}^{-1/2} (T) }   
    654 &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}}  
    655 & -\ \ {_i^k \mathbb{R}_{+1/2}^{-1/2}} 
    656 &      { _i^k \mathbb{T}_{+1/2}^{-1/2} (T) }    
    657 &\frac{ \delta_{k-1/2} [T] }{{e_{3w}}_{\,i}^{\,k-1/2}}      \Bigr) 
    658 & \\ 
    659 &+\Bigl(  {_i^k \mathbb{T}_{-1/2}^{+1/2} (T) }  
    660 &\frac{ \delta_{i -1/2} [T] }{{e_{1u} }_{\,i-1/2}^{\,k}}  
    661 & -\ \ {_i^k \mathbb{R}_{-1/2}^{+1/2}}  
    662 &      {_i^k \mathbb{T}_{-1/2}^{+1/2} (T) }    
    663 &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr) 
    664 & \\ 
    665 &+\Bigl( { _i^k \mathbb{T}_{+1/2}^{+1/2} (T) }  
    666 &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}}  
    667 & -\ \ {_i^k \mathbb{R}_{+1/2}^{+1/2}}  
    668 &      {_i^k \mathbb{T}_{+1/2}^{+1/2} (T) }    
    669 &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr)   \\ 
    670 \end{Bmatrix}   \\ 
    671 % 
    672 \allowdisplaybreaks 
    673   \intertext{Then outing in factor the triad in each of the four terms of the summation and 
     671  It becomes: 
     672  } 
     673  % 
     674  &\equiv -\sum_{i,k} 
     675    \begin{Bmatrix} 
     676      &\ \ \Bigl(  {_i^k \mathbb{T}_{-1/2}^{-1/2} (T) } 
     677      &\frac{ \delta_{i -1/2} [T] }{{e_{1u} }_{\,i-1/2}^{\,k}} 
     678      & -\ \ {_i^k \mathbb{R}_{-1/2}^{-1/2}} 
     679      &      {_i^k \mathbb{T}_{-1/2}^{-1/2} (T) } 
     680      &\frac{ \delta_{k-1/2} [T] }{{e_{3w}}_{\,i}^{\,k-1/2}}     \Bigr) 
     681      & \\ 
     682      &+\Bigl(  { _i^k \mathbb{T}_{+1/2}^{-1/2} (T) } 
     683      &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}} 
     684      & -\ \ {_i^k \mathbb{R}_{+1/2}^{-1/2}} 
     685      &      { _i^k \mathbb{T}_{+1/2}^{-1/2} (T) } 
     686      &\frac{ \delta_{k-1/2} [T] }{{e_{3w}}_{\,i}^{\,k-1/2}}      \Bigr) 
     687      & \\ 
     688      &+\Bigl(  {_i^k \mathbb{T}_{-1/2}^{+1/2} (T) } 
     689      &\frac{ \delta_{i -1/2} [T] }{{e_{1u} }_{\,i-1/2}^{\,k}} 
     690      & -\ \ {_i^k \mathbb{R}_{-1/2}^{+1/2}} 
     691      &      {_i^k \mathbb{T}_{-1/2}^{+1/2} (T) } 
     692      &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr) 
     693      & \\ 
     694      &+\Bigl( { _i^k \mathbb{T}_{+1/2}^{+1/2} (T) } 
     695      &\frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}} 
     696      & -\ \ {_i^k \mathbb{R}_{+1/2}^{+1/2}} 
     697      &      {_i^k \mathbb{T}_{+1/2}^{+1/2} (T) } 
     698      &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr)   \\ 
     699    \end{Bmatrix}   \\ 
     700    % 
     701  \allowdisplaybreaks 
     702  \intertext{ 
     703  Then outing in factor the triad in each of the four terms of the summation and 
    674704  substituting the triads by their expression given in \autoref{eq:Gf_triads}. 
    675   It becomes: } 
    676 % 
    677 &\equiv -\sum_{i,k} 
    678 \begin{Bmatrix}   
    679 &\ \ \Bigl(  \frac{ \delta_{i -1/2} [T] }{{e_{1u} }_{\,i-1/2}^{\,k}}  
    680 & -\ \ {_i^k \mathbb{R}_{-1/2}^{-1/2}}  
    681 &\frac{ \delta_{k-1/2} [T] }{{e_{3w}}_{\,i}^{\,k-1/2}}     \Bigr)^2 
    682 & \frac{1}{4} \ {b_u}_{\,i-1/2}^{\,k}  \  A_i^k 
    683 & \\ 
    684 &+\Bigl(  \frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}}  
    685 & -\ \ {_i^k \mathbb{R}_{+1/2}^{-1/2}} 
    686 &\frac{ \delta_{k-1/2} [T] }{{e_{3w}}_{\,i}^{\,k-1/2}}      \Bigr)^2 
    687 & \frac{1}{4} \ {b_u}_{\,i+1/2}^{\,k}  \  A_i^k 
    688 & \\ 
    689 &+\Bigl(  \frac{ \delta_{i -1/2} [T] }{{e_{1u} }_{\,i-1/2}^{\,k}}  
    690 & -\ \ {_i^k \mathbb{R}_{-1/2}^{+1/2}}  
    691 &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr)^2 
    692 & \frac{1}{4} \ {b_u}_{\,i-1/2}^{\,k}  \  A_i^k 
    693 & \\ 
    694 &+\Bigl( \frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}}  
    695 & -\ \ {_i^k \mathbb{R}_{+1/2}^{+1/2}}  
    696 &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr)^2 
    697 & \frac{1}{4} \ {b_u}_{\,i+1/2}^{\,k}  \  A_i^k      \\ 
    698 \end{Bmatrix}   \\ 
    699 & \\ 
    700 % 
    701 &\equiv - \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{   
    702 \begin{matrix}   
    703 &\Bigl( \frac{ \delta_{i +i_p} [T] }{{e_{1u} }_{\,i+i_p}^{\,k}}  
    704 & -\ \ {_i^k \mathbb{R}_{i_p}^{k_p}}  
    705 &\frac{ \delta_{k+k_p} [T] }{{e_{3w}}_{\,i}^{\,k+k_p}}     \Bigr)^2 
    706 & \frac{1}{4} \ {b_u}_{\,i+i_p}^{\,k}  \  A_i^k   \ \  
    707 \end{matrix} 
    708  \right\}    
    709 \quad   \leq 0 
     705  It becomes: 
     706  } 
     707  % 
     708  &\equiv -\sum_{i,k} 
     709    \begin{Bmatrix} 
     710      &\ \ \Bigl(  \frac{ \delta_{i -1/2} [T] }{{e_{1u} }_{\,i-1/2}^{\,k}} 
     711      & -\ \ {_i^k \mathbb{R}_{-1/2}^{-1/2}} 
     712      &\frac{ \delta_{k-1/2} [T] }{{e_{3w}}_{\,i}^{\,k-1/2}}     \Bigr)^2 
     713      & \frac{1}{4} \ {b_u}_{\,i-1/2}^{\,k}  \  A_i^k 
     714      & \\ 
     715      &+\Bigl(  \frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}} 
     716      & -\ \ {_i^k \mathbb{R}_{+1/2}^{-1/2}} 
     717      &\frac{ \delta_{k-1/2} [T] }{{e_{3w}}_{\,i}^{\,k-1/2}}      \Bigr)^2 
     718      & \frac{1}{4} \ {b_u}_{\,i+1/2}^{\,k}  \  A_i^k 
     719      & \\ 
     720      &+\Bigl(  \frac{ \delta_{i -1/2} [T] }{{e_{1u} }_{\,i-1/2}^{\,k}} 
     721      & -\ \ {_i^k \mathbb{R}_{-1/2}^{+1/2}} 
     722      &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr)^2 
     723      & \frac{1}{4} \ {b_u}_{\,i-1/2}^{\,k}  \  A_i^k 
     724      & \\ 
     725      &+\Bigl( \frac{ \delta_{i +1/2} [T] }{{e_{1u} }_{\,i+1/2}^{\,k}} 
     726      & -\ \ {_i^k \mathbb{R}_{+1/2}^{+1/2}} 
     727      &\frac{ \delta_{k+1/2} [T] }{{e_{3w}}_{\,i}^{\,k+1/2}}     \Bigr)^2 
     728      & \frac{1}{4} \ {b_u}_{\,i+1/2}^{\,k}  \  A_i^k      \\ 
     729    \end{Bmatrix} 
     730  \\ 
     731  & \\ 
     732  % 
     733  &\equiv - \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{ 
     734    \begin{matrix} 
     735      &\Bigl( \frac{ \delta_{i +i_p} [T] }{{e_{1u} }_{\,i+i_p}^{\,k}} 
     736      & -\ \ {_i^k \mathbb{R}_{i_p}^{k_p}} 
     737      &\frac{ \delta_{k+k_p} [T] }{{e_{3w}}_{\,i}^{\,k+k_p}}     \Bigr)^2 
     738      & \frac{1}{4} \ {b_u}_{\,i+i_p}^{\,k}  \  A_i^k   \ \ 
     739    \end{matrix} 
     740        \right\} 
     741        \quad   \leq 0 
    710742\end{align*}  
    711743The last inequality is obviously obtained as we succeed in obtaining a negative summation of square quantities. 
     
    714746then the previous demonstration would have let to: 
    715747\begin{align*} 
    716 \int_D  S \; D_l^T  \;dv &\equiv  \sum_{i,k} \left\{ S \ D_l^T \ b_T \right\}    \\ 
    717 &\equiv - \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{   
    718 \left( \frac{ \delta_{i +i_p} [S] }{{e_{1u} }_{\,i+i_p}^{\,k}}  
    719  - {_i^k \mathbb{R}_{i_p}^{k_p}}  
    720 \frac{ \delta_{k+k_p} [S] }{{e_{3w}}_{\,i}^{\,k+k_p}}     \right)  \right.     
    721 \\   & \qquad \qquad \qquad \ \left. 
    722 \left( \frac{ \delta_{i +i_p} [T] }{{e_{1u} }_{\,i+i_p}^{\,k}}  
    723  - {_i^k \mathbb{R}_{i_p}^{k_p}}  
    724 \frac{ \delta_{k+k_p} [T] }{{e_{3w}}_{\,i}^{\,k+k_p}}     \right)  
    725  \frac{1}{4} \ {b_u}_{\,i+i_p}^{\,k}  \  A_i^k   \ 
    726  \right\}    
    727 % 
    728 \allowdisplaybreaks 
    729 \intertext{which, by applying the same operation as before but in reverse order, leads to: } 
    730 % 
    731 &\equiv  \sum_{i,k} \left\{ D_l^S \ T \ b_T \right\}    
     748  \int_D  S \; D_l^T  \;dv &\equiv  \sum_{i,k} \left\{ S \ D_l^T \ b_T \right\}    \\ 
     749                           &\equiv - \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{ 
     750                             \left( \frac{ \delta_{i +i_p} [S] }{{e_{1u} }_{\,i+i_p}^{\,k}} 
     751                             - {_i^k \mathbb{R}_{i_p}^{k_p}} 
     752                             \frac{ \delta_{k+k_p} [S] }{{e_{3w}}_{\,i}^{\,k+k_p}}     \right)  \right. \\ 
     753                           & \qquad \qquad \qquad \ \left. 
     754                             \left( \frac{ \delta_{i +i_p} [T] }{{e_{1u} }_{\,i+i_p}^{\,k}} 
     755                             - {_i^k \mathbb{R}_{i_p}^{k_p}} 
     756                             \frac{ \delta_{k+k_p} [T] }{{e_{3w}}_{\,i}^{\,k+k_p}}     \right) 
     757                             \frac{1}{4} \ {b_u}_{\,i+i_p}^{\,k}  \  A_i^k   \ 
     758                             \right\} 
     759                             % 
     760                             \allowdisplaybreaks 
     761                             \intertext{ 
     762                             which, by applying the same operation as before but in reverse order, leads to: 
     763                             } 
     764                             % 
     765                           &\equiv  \sum_{i,k} \left\{ D_l^S \ T \ b_T \right\} 
    732766\end{align*}  
    733767This means that the iso-neutral operator is self-adjoint. 
    734768There is no need to develop a specific to obtain it. 
    735769 
    736  
    737  
    738 $\ $\newpage      %force an empty line 
     770\newpage 
     771 
    739772% ================================================================ 
    740773% Discrete Invariants of the skew flux formulation 
     
    743776\label{subsec:eiv_skew} 
    744777 
    745  
    746778Demonstration for the conservation of the tracer variance in the (\textbf{i},\textbf{j}) plane.  
    747779 
     
    750782The continuous property to be demonstrated is: 
    751783\begin{align*} 
    752 \int_D \nabla \cdot \textbf{F}_{eiv}(T) \; T \;dv  \equiv 0 
     784  \int_D \nabla \cdot \textbf{F}_{eiv}(T) \; T \;dv  \equiv 0 
    753785\end{align*} 
    754786The discrete form of its left hand side is obtained using \autoref{eq:eiv_skew} 
    755787\begin{align*} 
    756  \sum\limits_{i,k} \sum_{\substack{i_p,\,k_p}}  \Biggl\{   \;\; 
    757  \delta_i  &\left[                                                     
    758 {e_{2u}}_{i+i_p+1/2}^{k}                                  \;\ \ {A_{e}}_{i+i_p+1/2}^{k}  
    759 \ \ \ { _{i+i_p+1/2}^k \mathbb{R}_{-i_p}^{k_p} }   \quad \delta_{k+k_p}[T_{i+i_p+1/2}]          
    760    \right] \; T_i^k      \\ 
    761 - \delta_k &\left[  
    762 {e_{2u}}_i^{k+k_p+1/2}                                     \ \ {A_{e}}_i^{k+k_p+1/2}  
    763 \ \ { _i^{k+k_p+1/2} \mathbb{R}_{i_p}^{-k_p} }   \ \ \delta_{i+i_p}[T^{k+k_p+1/2}]    
    764    \right] \; T_i^k      \         \Biggr\}    
     788  \sum\limits_{i,k} \sum_{\substack{i_p,\,k_p}}  \Biggl\{   \;\; 
     789  \delta_i  &\left[ 
     790              {e_{2u}}_{i+i_p+1/2}^{k}                                  \;\ \ {A_{e}}_{i+i_p+1/2}^{k} 
     791              \ \ \ { _{i+i_p+1/2}^k \mathbb{R}_{-i_p}^{k_p} }   \quad \delta_{k+k_p}[T_{i+i_p+1/2}] 
     792              \right] \; T_i^k      \\ 
     793  - \delta_k &\left[ 
     794               {e_{2u}}_i^{k+k_p+1/2}                                     \ \ {A_{e}}_i^{k+k_p+1/2} 
     795               \ \ { _i^{k+k_p+1/2} \mathbb{R}_{i_p}^{-k_p} }   \ \ \delta_{i+i_p}[T^{k+k_p+1/2}] 
     796               \right] \; T_i^k      \         \Biggr\} 
    765797\end{align*} 
    766798apply the adjoint of delta operator, it becomes 
    767799\begin{align*} 
    768  \sum\limits_{i,k} \sum_{\substack{i_p,\,k_p}}  \Biggl\{   \;\; 
    769   &\left(                                                     
    770 {e_{2u}}_{i+i_p+1/2}^{k}                                  \;\ \ {A_{e}}_{i+i_p+1/2}^{k}  
    771 \ \ \ { _{i+i_p+1/2}^k \mathbb{R}_{-i_p}^{k_p} }   \quad \delta_{k+k_p}[T_{i+i_p+1/2}]          
    772    \right) \; \delta_{i+1/2}[T^{k}]      \\ 
    773 - &\left(  
    774 {e_{2u}}_i^{k+k_p+1/2}                                     \ \ {A_{e}}_i^{k+k_p+1/2}  
    775 \ \ { _i^{k+k_p+1/2} \mathbb{R}_{i_p}^{-k_p} }   \ \ \delta_{i+i_p}[T^{k+k_p+1/2}]    
    776      \right) \; \delta_{k+1/2}[T_{i}]       \         \Biggr\}        
     800  \sum\limits_{i,k} \sum_{\substack{i_p,\,k_p}}  \Biggl\{   \;\; 
     801  &\left( 
     802    {e_{2u}}_{i+i_p+1/2}^{k}                                  \;\ \ {A_{e}}_{i+i_p+1/2}^{k} 
     803    \ \ \ { _{i+i_p+1/2}^k \mathbb{R}_{-i_p}^{k_p} }   \quad \delta_{k+k_p}[T_{i+i_p+1/2}] 
     804    \right) \; \delta_{i+1/2}[T^{k}]      \\ 
     805  - &\left( 
     806      {e_{2u}}_i^{k+k_p+1/2}                                     \ \ {A_{e}}_i^{k+k_p+1/2} 
     807      \ \ { _i^{k+k_p+1/2} \mathbb{R}_{i_p}^{-k_p} }   \ \ \delta_{i+i_p}[T^{k+k_p+1/2}] 
     808      \right) \; \delta_{k+1/2}[T_{i}]       \         \Biggr\} 
    777809\end{align*} 
    778810Expending the summation on $i_p$ and $k_p$, it becomes: 
    779811\begin{align*} 
    780  \begin{matrix}   
    781 &\sum\limits_{i,k}   \Bigl\{  
    782   &+{e_{2u}}_{i+1}^{k}                             &{A_{e}}_{i+1    }^{k}  
    783   &\ {_{i+1}^k \mathbb{R}_{- 1/2}^{-1/2}} &\delta_{k-1/2}[T_{i+1}]    &\delta_{i+1/2}[T^{k}]   &\\ 
    784 &&+{e_{2u}}_i^{k\ \ \ \:}                            &{A_{e}}_{i}^{k\ \ \ \:}       
    785   &\ {\ \ \;_i^k \mathbb{R}_{+1/2}^{-1/2}}  &\delta_{k-1/2}[T_{i\ \ \ \;}]  &\delta_{i+1/2}[T^{k}] &\\ 
    786 &&+{e_{2u}}_{i+1}^{k}                             &{A_{e}}_{i+1    }^{k}  
    787   &\ {_{i+1}^k \mathbb{R}_{- 1/2}^{+1/2}} &\delta_{k+1/2}[T_{i+1}]     &\delta_{i+1/2}[T^{k}] &\\ 
    788 &&+{e_{2u}}_i^{k\ \ \ \:}                            &{A_{e}}_{i}^{k\ \ \ \:}        
     812  \begin{matrix} 
     813    &\sum\limits_{i,k}   \Bigl\{ 
     814    &+{e_{2u}}_{i+1}^{k}                             &{A_{e}}_{i+1    }^{k} 
     815    &\ {_{i+1}^k \mathbb{R}_{- 1/2}^{-1/2}} &\delta_{k-1/2}[T_{i+1}]    &\delta_{i+1/2}[T^{k}]   &\\ 
     816    &&+{e_{2u}}_i^{k\ \ \ \:}                            &{A_{e}}_{i}^{k\ \ \ \:} 
     817    &\ {\ \ \;_i^k \mathbb{R}_{+1/2}^{-1/2}}  &\delta_{k-1/2}[T_{i\ \ \ \;}]  &\delta_{i+1/2}[T^{k}] &\\ 
     818    &&+{e_{2u}}_{i+1}^{k}                             &{A_{e}}_{i+1    }^{k} 
     819    &\ {_{i+1}^k \mathbb{R}_{- 1/2}^{+1/2}} &\delta_{k+1/2}[T_{i+1}]     &\delta_{i+1/2}[T^{k}] &\\ 
     820    &&+{e_{2u}}_i^{k\ \ \ \:}                            &{A_{e}}_{i}^{k\ \ \ \:} 
    789821    &\ {\ \ \;_i^k \mathbb{R}_{+1/2}^{+1/2}} &\delta_{k+1/2}[T_{i\ \ \ \;}] &\delta_{i+1/2}[T^{k}] &\\ 
    790 % 
    791 &&-{e_{2u}}_i^{k+1}                                &{A_{e}}_i^{k+1}  
    792   &{_i^{k+1} \mathbb{R}_{-1/2}^{- 1/2}}   &\delta_{i-1/2}[T^{k+1}]      &\delta_{k+1/2}[T_{i}] &\\    
    793 &&-{e_{2u}}_i^{k\ \ \ \:}                             &{A_{e}}_i^{k\ \ \ \:}  
    794   &{\ \ \;_i^k  \mathbb{R}_{-1/2}^{+1/2}}   &\delta_{i-1/2}[T^{k\ \ \ \:}]  &\delta_{k+1/2}[T_{i}] &\\ 
    795 &&-{e_{2u}}_i^{k+1    }                             &{A_{e}}_i^{k+1}  
    796   &{_i^{k+1} \mathbb{R}_{+1/2}^{- 1/2}}   &\delta_{i+1/2}[T^{k+1}]      &\delta_{k+1/2}[T_{i}] &\\    
    797 &&-{e_{2u}}_i^{k\ \ \ \:}                             &{A_{e}}_i^{k\ \ \ \:}  
    798   &{\ \ \;_i^k  \mathbb{R}_{+1/2}^{+1/2}}   &\delta_{i+1/2}[T^{k\ \ \ \:}]  &\delta_{k+1/2}[T_{i}]  
    799 &\Bigr\}  \\ 
    800 \end{matrix}    
     822    % 
     823    &&-{e_{2u}}_i^{k+1}                                &{A_{e}}_i^{k+1} 
     824    &{_i^{k+1} \mathbb{R}_{-1/2}^{- 1/2}}   &\delta_{i-1/2}[T^{k+1}]      &\delta_{k+1/2}[T_{i}] &\\ 
     825    &&-{e_{2u}}_i^{k\ \ \ \:}                             &{A_{e}}_i^{k\ \ \ \:} 
     826    &{\ \ \;_i^k  \mathbb{R}_{-1/2}^{+1/2}}   &\delta_{i-1/2}[T^{k\ \ \ \:}]  &\delta_{k+1/2}[T_{i}] &\\ 
     827    &&-{e_{2u}}_i^{k+1    }                             &{A_{e}}_i^{k+1} 
     828    &{_i^{k+1} \mathbb{R}_{+1/2}^{- 1/2}}   &\delta_{i+1/2}[T^{k+1}]      &\delta_{k+1/2}[T_{i}] &\\ 
     829    &&-{e_{2u}}_i^{k\ \ \ \:}                             &{A_{e}}_i^{k\ \ \ \:} 
     830    &{\ \ \;_i^k  \mathbb{R}_{+1/2}^{+1/2}}   &\delta_{i+1/2}[T^{k\ \ \ \:}]  &\delta_{k+1/2}[T_{i}] 
     831    &\Bigr\}  \\ 
     832  \end{matrix}    
    801833\end{align*} 
    802834The two terms associated with the triad ${_i^k \mathbb{R}_{+1/2}^{+1/2}}$ are the same but of opposite signs, 
     
    810842$i.e.$ the variance of the tracer is preserved by the discretisation of the skew fluxes. 
    811843 
     844\biblio 
     845 
    812846\end{document} 
  • NEMO/branches/2018/dev_r10164_HPC09_ESIWACE_PREP_MERGE/doc/latex/NEMO/subfiles/annex_iso.tex

    r10368 r10419  
    1 \documentclass[../tex_main/NEMO_manual]{subfiles} 
     1\documentclass[../main/NEMO_manual]{subfiles} 
     2 
    23\begin{document} 
    34% ================================================================ 
     
    78         {\texorpdfstring{Iso-Neutral Diffusion and\\ Eddy Advection using Triads}{Iso-Neutral Diffusion and Eddy Advection using Triads}} 
    89\label{apdx:triad} 
     10 
    911\minitoc 
    10 \pagebreak 
     12 
     13\newpage 
     14 
    1115\section{Choice of \protect\ngn{namtra\_ldf} namelist parameters} 
    1216%-----------------------------------------nam_traldf------------------------------------------------------ 
     
    5963\section{Triad formulation of iso-neutral diffusion} 
    6064\label{sec:iso} 
     65 
    6166We have implemented into \NEMO a scheme inspired by \citet{Griffies_al_JPO98}, 
    6267but formulated within the \NEMO framework, using scale factors rather than grid-sizes. 
    6368 
    64