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

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

source: branches/dev_005_AWL/DOC/TexFiles/Chapters/Annex_C.tex @ 3050

Last change on this file since 3050 was 1223, checked in by gm, 16 years ago

minor corrections in the Appendix from Steven see ticket #282

  • Property svn:executable set to *
File size: 50.3 KB
Line 
1% ================================================================
2% Chapter Ñ Appendix C : Discrete Invariants of the Equations
3% ================================================================
4\chapter{Discrete Invariants of the Equations}
5\label{Apdx_C}
6\minitoc
7
8%%%  Appendix put in gmcomment as it has not been updated for z* and s coordinate
9I'm writting this appendix. It will be available in a forthcoming release of the documentation
10
11%\gmcomment{
12
13% ================================================================
14% Conservation Properties on Ocean Dynamics
15% ================================================================
16\section{Conservation Properties on Ocean Dynamics}
17\label{Apdx_C.1}
18
19First, the boundary condition on the vertical velocity (no flux through the surface
20and the bottom) is established for the discrete set of momentum equations.
21Then, it is shown that the non-linear terms of the momentum equation are written
22such that the potential enstrophy of a horizontally non-divergent flow is preserved
23while all the other non-diffusive terms preserve the kinetic energy; in practice the
24energy is also preserved. In addition, an option is also offered for the vorticity term
25discretization which provides a total kinetic energy conserving discretization for
26that term.
27
28Nota Bene: these properties are established here in the rigid-lid case and for the
292nd order centered scheme. A forthcoming update will be their generalisation to
30the free surface case and higher order scheme.
31
32% -------------------------------------------------------------------------------------------------------------
33%       Bottom Boundary Condition on Vertical Velocity Field
34% -------------------------------------------------------------------------------------------------------------
35\subsection{Bottom Boundary Condition on Vertical Velocity Field}
36\label{Apdx_C.1.1}
37
38
39The discrete set of momentum equations used in the rigid-lid approximation
40automatically satisfies the surface and bottom boundary conditions
41(no flux through the surface and the bottom: $w_{surface} =w_{bottom} =~0$).
42Indeed, taking the discrete horizontal divergence of the vertical sum of the
43horizontal momentum equations (!!!Eqs. (II.2.1) and (II.2.2)!!!) weighted by the
44vertical scale factors, it becomes:
45\begin{flalign*}
46\frac{\partial } {\partial t}  \left( \sum\limits_k    \chi    \right)
47\equiv 
48\frac{\partial } {\partial t}  \left(  w_{surface} -w_{bottom}     \right)&&&\\
49\end{flalign*}
50\begin{flalign*}
51\equiv \frac{1} {e_{1T}\,e_{2T}\,e_{3T}} 
52   \biggl\{ \quad
53   \delta_i
54      &\left[
55      e_{2u}\,H_u
56         \left(
57         M_u - M_u - \frac{1} {H_u\,e_{2u}} \delta_j
58            \left[ \partial_t\, \psi \right] 
59         \right)
60      \right] &&
61   \biggr. \\
62   \biggl.
63   + \delta_j
64      &\left[
65      e_{1v}\,H_v
66         \left( M_v - M_v - \frac{1} {H_v\,e_{1v}} \delta_i
67            \left[ \partial_i\, \psi \right] 
68         \right)
69      \right]
70   \biggr\}&& \\
71\end{flalign*}
72\begin{flalign*}
73\equiv \frac{1} {e_{1T} \,e_{2T} \,e_{3T}} \;
74   \biggl\{ 
75   - \delta_i
76      \Bigl[
77      \delta_j
78         \left[ \partial_t \psi  \right] 
79      \Bigr]
80   + \delta_j
81      \Bigl[
82      \delta_i
83         \left[ \partial_t \psi  \right] 
84      \Bigr]\; 
85   \biggr\}\;
86   \equiv 0
87   &&&\\
88\end{flalign*}
89
90
91The surface boundary condition associated with the rigid lid approximation
92($w_{surface} =0)$ is imposed in the computation of the vertical velocity (!!! II.2.5!!!!).
93Therefore, it turns out to be:
94\begin{equation*}
95\frac{\partial } {\partial t}w_{bottom} \equiv 0
96\end{equation*}
97As the bottom velocity is initially set to zero, it remains zero all the time.
98Symmetrically, if $w_{bottom} =0$ is used in the computation of the vertical
99velocity (upward integral of the horizontal divergence), the same computation
100leads to $w_{surface} =0$ as soon as the surface vertical velocity is initially
101set to zero.
102
103% -------------------------------------------------------------------------------------------------------------
104%       Coriolis and advection terms: vector invariant form
105% -------------------------------------------------------------------------------------------------------------
106\subsection{Coriolis and advection terms: vector invariant form}
107\label{Apdx_C_vor_zad}
108
109% -------------------------------------------------------------------------------------------------------------
110%       Vorticity Term
111% -------------------------------------------------------------------------------------------------------------
112\subsubsection{Vorticity Term}
113\label{Apdx_C_vor} 
114
115Potential vorticity is located at $f$-points and defined as: $\zeta / e_{3f}$.
116The standard discrete formulation of the relative vorticity term obviously
117conserves potential vorticity (ENS scheme). It also conserves the potential
118enstrophy for a horizontally non-divergent flow (i.e. $\chi $=0) but not the
119total kinetic energy. Indeed, using the symmetry or skew symmetry properties
120of the operators (Eqs \eqref{DOM_mi_adj} and \eqref{DOM_di_adj}), it can
121be shown that:
122\begin{equation} \label{Apdx_C_1.1}
123\int_D {\zeta / e_3\,\;{\textbf{k}}\cdot \frac{1} {e_3} \nabla \times \left( {\zeta \;{\textbf{k}}\times {\textbf{U}}_h } \right)\;dv} \equiv 0
124\end{equation}
125where $dv=e_1\,e_2\,e_3 \; di\,dj\,dk$ is the volume element. Indeed, using
126\eqref{Eq_dynvor_ens}, the discrete form of the right hand side of \eqref{Apdx_C_1.1} 
127can be transformed as follow:
128\begin{flalign*} 
129&\int_D \zeta / e_3\,\; \textbf{k} \cdot \frac{1} {e_3 } \nabla \times 
130   \left(
131   \zeta \; \textbf{k} \times  \textbf{U}_
132   \right)\;
133   dv
134   &&& \displaybreak[0] \\
135%
136\equiv& \sum\limits_{i,j,k} 
137\frac{\zeta / e_{3f}} {e_{1f}\,e_{2f}\,e_{3f}} 
138   \biggl\{ \quad
139   \delta_{i+1/2} 
140      \left[
141         - \overline {\left( {\zeta / e_{3f}} \right)}^{\,i}\;
142            \overline{\overline {\left( e_{2u}\,e_{3u}\,u \right)}}^{\,i,j+1/ 2} 
143       \right
144   &&  \\ & \qquad \qquad \qquad \;\;
145   - \delta_{j+1/2} 
146      \left[   \;\;\;
147           \overline {\left( \zeta / e_{3f} \right)}^{\,j}\;
148           \overline{\overline {\left( e_{1v}\,e_{3v}\,v \right)}}^{\,i+1/2,j} 
149      \right]
150   \;\;\biggr\} \;  e_{1f}\,e_{2f}\,e_{3f}       && \displaybreak[0] \\ 
151%
152\equiv& \sum\limits_{i,j,k} 
153   \biggl\{   \delta_i     \left[   \frac{\zeta} {e_{3f}}   \right] \;
154           \overline{  \left(   \frac{\zeta} {e_{3f}}   \right}^{\,i}\; 
155           \overline{  \overline{   \left( e_{1u}\,e_{3u}\,u \right}  }^{\,i,j+1/2} 
156         + \delta_j   \left[   \frac{\zeta} {e_{3f}}   \right] \;
157            \overline{   \left\frac{\zeta} {e_{3f}}    \right}^{\,j} \; 
158      \overline{\overline {\left( e_{2v}\,e_{3v}\,v \right)}}^{\,i+1/2,j}         \biggr\} 
159      &&&& \displaybreak[0] \\ 
160%
161\equiv& \frac{1} {2} \sum\limits_{i,j,k} 
162   \biggl\{ \delta_i    \Bigl[    \left(  \frac{\zeta} {e_{3f}} \right)^2   \Bigr]\;
163         \overline{\overline {\left( e_{2u}\,e_{3u}\,u \right)}}^{\,i,j+1/2} 
164            + \delta_\Bigl[    \left( \zeta / e_{3f} \right)^2     \Bigr]\; 
165         \overline{\overline {\left( e_{1v}\,e_{3v}\,v \right)}}^{\,i+1/2,j} 
166   \biggr\} 
167   && \displaybreak[0] \\ 
168%
169\equiv& - \frac{1} {2} \sum\limits_{i,j,k}   \left\frac{\zeta} {e_{3f}} \right)^2\;
170   \biggl\{    \delta_{i+1/2} 
171         \left[   \overline{\overline {\left( e_{2u}\,e_{3u}\,u \right)}}^{\,i,j+1/2}    \right] 
172               + \delta_{j+1/2}
173      \left[   \overline{\overline {\left( e_{1v}\,e_{3v}\,v \right)}}^{\,i+1/2,j}     \right] 
174   \biggr\}    && \\ 
175\end{flalign*}
176Since $\overline {\;\cdot \;} $ and $\delta $ operators commute: $\delta_{i+1/2}
177\left[ {\overline a^{\,i}} \right] = \overline {\delta_i \left[ a \right]}^{\,i+1/2}$,
178and introducing the horizontal divergence $\chi $, it becomes:
179\begin{align*}
180\equiv& \sum\limits_{i,j,k} - \frac{1} {2} \left\frac{\zeta} {e_{3f}} \right)^2 \; \overline{\overline{ e_{1T}\,e_{2T}\,e_{3T}\, \chi}}^{\,i+1/2,j+1/2} \;\;\equiv 0
181\qquad \qquad \qquad \qquad \qquad \qquad \qquad &&&&\\
182\end{align*}
183
184Note that the derivation is demonstrated here for the relative potential
185vorticity but it applies also to the planetary ($f/e_3$) and the total
186potential vorticity $((\zeta +f) /e_3 )$. Another formulation of the two
187components of the vorticity term is optionally offered (ENE scheme) :
188\begin{equation*}
189   - \zeta \;{\textbf{k}}\times {\textbf {U}}_h
190\equiv 
191   \left( {{
192   \begin{array} {*{20}c}
193      + \frac{1} {e_{1u}} \; 
194      \overline {\left( \zeta / e_{3f}      \right)   
195      \overline {\left( e_{1v}\,e_{3v}\,v \right)}^{\,i+1/2}} ^{\,j} 
196      \hfill \\
197      - \frac{1} {e_{2v}} \; 
198      \overline {\left( \zeta / e_{3f}      \right)
199      \overline {\left( e_{2u}\,e_{3u}\,u \right)}^{\,j+1/2}} ^{\,i} 
200      \hfill \\
201   \end{array}} } 
202   \right)
203\end{equation*}
204
205This formulation does not conserve the enstrophy but it does conserve the
206total kinetic energy. It is also possible to mix the two formulations in order
207to conserve enstrophy on the relative vorticity term and energy on the
208Coriolis term.
209\begin{flalign*}
210&\int\limits_D - \textbf{U}_h \cdot   \left\zeta \;\textbf{k} \times \textbf{U}_\right\;  dv &&  \\
211\equiv& \sum\limits_{i,j,k}   \biggl\{   
212      \overline {\left\frac{\zeta} {e_{3f}}      \right)
213        \overline {\left( e_{1v}e_{3v}v \right)}^{\,i+1/2}} ^{\,j} \, e_{2u}e_{3u}u
214   - \overline {\left\frac{\zeta} {e_{3f}}       \right)
215       \overline {\left( e_{2u}e_{3u}u \right)}^{\,j+1/2}} ^{\,i} \, e_{1v}e_{3v}v \;
216                                   \biggr\}     
217\\
218\equiv& \sum\limits_{i,j,k}  \frac{\zeta} {e_{3f}}
219   \biggl\{  \overline {\left( e_{1v}e_{3v} v \right)}^{\,i+1/2}\;
220             \overline {\left( e_{2u}e_{3u} u \right)}^{\,j+1/2}       
221        - \overline {\left( e_{2u}e_{3u} u \right)}^{\,j+1/2}\;
222               \overline {\left( e_{1v}e_{3v} v \right)}^{\,i+1/2}
223   \biggr\}
224   \equiv 0
225\end{flalign*}
226
227
228% -------------------------------------------------------------------------------------------------------------
229%       Gradient of Kinetic Energy / Vertical Advection
230% -------------------------------------------------------------------------------------------------------------
231\subsubsection{Gradient of Kinetic Energy / Vertical Advection}
232\label{Apdx_C_zad} 
233
234The change of Kinetic Energy (KE) due to the vertical advection is exactly
235balanced by the change of KE due to the horizontal gradient of KE~:
236\begin{equation*}
237      \int_D \textbf{U}_h \cdot \nabla_h \left( \frac{1}{2}\;{\textbf{U}_h}^2 \right)\;dv
238 = - \int_D \textbf{U}_h \cdot w \frac{\partial \textbf{U}_h} {\partial k}\;dv
239\end{equation*}
240Indeed, using successively \eqref{DOM_di_adj} ($i.e.$ the skew symmetry
241property of the $\delta$ operator) and the incompressibility, then
242\eqref{DOM_di_adj} again, then the commutativity of operators
243$\overline {\,\cdot \,}$ and $\delta$, and finally \eqref{DOM_mi_adj} 
244($i.e.$ the symmetry property of the $\overline {\,\cdot \,}$ operator)
245applied in the horizontal and vertical directions, it becomes:
246\begin{flalign*}
247&\int_D \textbf{U}_h \cdot \nabla_h \left( \frac{1}{2}\;{\textbf{U}_h}^2 \right)\;dv   &&&\\
248\equiv& \frac{1}{2} \sum\limits_{i,j,k} 
249   \biggl\{ 
250   \frac{1} {e_{1u}}  \delta_{i+1/2} 
251   \left[   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}    \right]  u\,e_{1u}e_{2u}e_{3u} 
252     + \frac{1} {e_{2v}}  \delta_{j+1/2} 
253   \left[   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right]  v\,e_{1v}e_{2v}e_{3v} 
254   \biggr\} 
255   &&& \displaybreak[0] \\ 
256%
257\equiv&  \frac{1}{2} \sum\limits_{i,j,k} 
258   \left(   \overline {u^2}^{\,i} + \overline {v^2}^{\,j}   \right)\;
259   \delta_k \left[  e_{1T}\,e_{2T} \,w   \right]
260%
261\;\; \equiv -\frac{1}{2} \sum\limits_{i,j,k}  \delta_{k+1/2} 
262   \left[
263      \overline{ u^2}^{\,i} 
264   + \overline{ v^2}^{\,j} 
265   \right] \;
266   e_{1v}\,e_{2v}\,w
267   &&& \displaybreak[0]\\
268%
269\equiv &\frac{1} {2} \sum\limits_{i,j,k} 
270   \left(    \overline {\delta_{k+1/2} \left[ u^2 \right]}^{\,i} 
271      + \overline {\delta_{k+1/2} \left[ v^2 \right]}^{\,j}    \right) \; e_{1T}\,e_{2T} \,w
272   && \displaybreak[0] \\
273
274\equiv &\frac{1} {2} \sum\limits_{i,j,k} 
275   \biggl\{  \overline {e_{1T}\,e_{2T} \,w}^{\,i+1/2}\;2   
276         \overline {u}^{\,k+1/2}\; \delta_{k+1/2}         \left[ u \right]     %&&&  \\
277    + \overline {e_{1T}\,e_{2T} \,w}^{\,j+1/2}\;\overline {v}^{\,k+1/2}\; \delta_{k+1/2}  \left[ v \right]  \;
278   \biggr\} 
279   &&\displaybreak[0] \\ 
280%
281\equiv& -\sum\limits_{i,j,k} 
282   \biggl\{
283   \quad \frac{1} {b_u } \;
284   \overline {\Bigl\{ \overline {e_{1T}\,e_{2T} \,w}^{\,i+1/2}\,\delta_{k+1/2}
285      \left[ u \right] 
286             \Bigr\} }^{\,k} \;u\;e_{1u}\,e_{2u}\,e_{3u} 
287   && \\
288   &\qquad \quad\; + \frac{1} {b_v } \;
289   \overline {\Bigl\{ \overline {e_{1T}\,e_{2T} \,w}^{\,j+1/2} \delta_{k+1/2}
290       \left[ v \right] 
291         \Bigr\} }^{\,k} \;v\;e_{1v}\,e_{2v}\,e_{3v}  \;
292   \biggr\} 
293   && \\ 
294\equiv& -\int\limits_D \textbf{U}_h \cdot w \frac{\partial \textbf{U}_h} {\partial k}\;dv &&&\\
295\end{flalign*}
296
297The main point here is that the satisfaction of this property links the choice of
298the discrete formulation of the vertical advection and of the horizontal gradient
299of KE. Choosing one imposes the other. For example KE can also be discretized
300as $1/2\,({\overline u^{\,i}}^2 + {\overline v^{\,j}}^2)$. This leads to the following
301expression for the vertical advection:
302\begin{equation*}
303\frac{1} {e_3 }\; w\; \frac{\partial \textbf{U}_h } {\partial k}
304\equiv \left( {{\begin{array} {*{20}c}
305\frac{1} {e_{1u}\,e_{2u}\,e_{3u}} \;
306\overline{\overline {e_{1T}\,e_{2T} \,w\;\delta_{k+1/2} 
307\left[ \overline u^{\,i+1/2} \right]}}^{\,i+1/2,k}  \hfill \\
308\frac{1} {e_{1v}\,e_{2v}\,e_{3v}} \;
309\overline{\overline {e_{1T}\,e_{2T} \,w\;\delta_{k+1/2}
310\left[ \overline v^{\,j+1/2} \right]}}^{\,j+1/2,k} \hfill \\
311\end{array}} } \right)
312\end{equation*}
313a formulation that requires an additional horizontal mean in contrast with
314the one used in NEMO. Nine velocity points have to be used instead of 3.
315This is the reason why it has not been chosen.
316
317% -------------------------------------------------------------------------------------------------------------
318%       Coriolis and advection terms: flux form
319% -------------------------------------------------------------------------------------------------------------
320\subsection{Coriolis and advection terms: flux form}
321\label{Apdx_C.1.3}
322
323% -------------------------------------------------------------------------------------------------------------
324%       Coriolis plus ``metric'' Term
325% -------------------------------------------------------------------------------------------------------------
326\subsubsection{Coriolis plus ``metric'' Term}
327\label{Apdx_C.1.3.1} 
328
329In flux from the vorticity term reduces to a Coriolis term in which the Coriolis
330parameter has been modified to account for the ``metric'' term. This altered
331Coriolis parameter is discretised at an f-point. It is given by:
332\begin{equation*}
333f+\frac{1} {e_1 e_2 } 
334\left( v \frac{\partial e_2 } {\partial i} - u \frac{\partial e_1 } {\partial j}\right)\;
335\equiv \;
336f+\frac{1} {e_{1f}\,e_{2f}} 
337\left( \overline v^{\,i+1/2} \delta_{i+1/2} \left[ e_{2u} \right] 
338-\overline u^{\,j+1/2} \delta_{j+1/2} \left[ e_{1u}  \right] \right)
339\end{equation*}
340
341The ENE scheme is then applied to obtain the vorticity term in flux form.
342It therefore conserves the total KE. The derivation is the same as for the
343vorticity term in the vector invariant form (\S\ref{Apdx_C_vor}).
344
345% -------------------------------------------------------------------------------------------------------------
346%       Flux form advection
347% -------------------------------------------------------------------------------------------------------------
348\subsubsection{Flux form advection}
349\label{Apdx_C.1.3.2} 
350
351The flux form operator of the momentum advection is evaluated using a
352centered second order finite difference scheme. Because of the flux form,
353the discrete operator does not contribute to the global budget of linear
354momentum. Because of the centered second order scheme, it conserves
355the horizontal kinetic energy, that is :
356
357\begin{equation} \label{Apdx_C_I.3.10}
358\int_D \textbf{U}_h \cdot 
359\left( {{\begin{array} {*{20}c}
360\nabla \cdot \left( \textbf{U}\,u \right) \hfill \\
361\nabla \cdot \left( \textbf{U}\,v \right) \hfill \\
362\end{array}} } \right)\;dv =\;0
363\end{equation}
364
365Let us demonstrate this property for the first term of the scalar product
366($i.e.$ considering just the the terms associated with the i-component of
367the advection):
368\begin{flalign*}
369&\int_D u \cdot \nabla \cdot \left(   \textbf{U}\,u   \right) \; dv    &&&\\
370%
371\equiv& \sum\limits_{i,j,k} 
372\biggl\{    \frac{1} {e_{1u}\, e_{2u}\,e_{3u}}    \biggl(   
373      \delta_{i+1/2}  \left[   \overline {e_{2u}\,e_{3u}\,u}^{\,i}      \;\overline u^{\,i}          \right]   
374   + \delta_j           \left[   \overline {e_{1u}\,e_{3u}\,v}^{\,i+1/2}\;\overline u^{\,j+1/2}   \right] 
375      &&& \\ & \qquad \qquad \qquad \qquad \qquad \qquad
376   + \delta_k          \left[   \overline {e_{1w}\,e_{2w}\,w}^{\,i+1/2}\;\overline u^{\,k+1/2} \right]
377         \biggr)   \;   \biggr\} \, e_{1u}\,e_{2u}\,e_{3u} \;u
378      &&& \displaybreak[0] \\ 
379%
380\equiv& \sum\limits_{i,j,k} 
381   \biggl\{ 
382      \delta_{i+1/2} \left[   \overline {e_{2u}\,e_{3u}\,u}^{\,i}\;  \overline u^{\,i}  \right]
383   + \delta_j          \left[   \overline {e_{1u}\,e_{3u}\,v}^{\,i+1/2}\;\overline u^{\,j+1/2}   \right]
384      &&& \\ & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad
385   + \delta_k         \left[   \overline {e_{1w}\,e_{2w}\,w}^{\,i+12}\;\overline u^{\,k+1/2}  \right]
386      \; \biggr\} \; u    &&& \displaybreak[0] \\
387%
388\equiv& - \sum\limits_{i,j,k}
389   \biggl\{ 
390      \overline {e_{2u}\,e_{3u}\,u}^{\,i}\;        \overline u^{\,i}       \delta_i
391      \left[ u \right] 
392        + \overline {e_{1u}\,e_{3u}\,v}^{\,i+1/2}\;   \overline u^{\,j+1/2}   \delta_{j+1/2} 
393      \left[ u \right] 
394      &&& \\ & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad
395       + \overline {e_{1w}\,e_{2w}\,w}^{\,i+1/2}\; \overline u^{\,k+1/2}   \delta_{k+1/2}    \left[ u \right]     \biggr\}     && \displaybreak[0] \\
396%
397\equiv& - \sum\limits_{i,j,k}
398   \biggl\{ 
399        \overline {e_{2u}\,e_{3u}\,u}^{\,i}        \delta_i       \left[ u^2 \right] 
400    + \overline {e_{1u}\,e_{3u}\,v}^{\,i+1/2}      \delta_{j+/2}  \left[ u^2 \right]
401    + \overline {e_{1w}\,e_{2w}\,w}^{\,i+1/2}   \delta_{k+1/2}    \left[ u^2 \right] 
402   \biggr\} 
403   && \displaybreak[0] \\
404%
405\equiv& \sum\limits_{i,j,k}
406   \bigg\{ 
407      e_{2u}\,e_{3u}\,u\;     \delta_{i+1/2}       \left[ \overline {u^2}^{\,i} \right]
408        + e_{1u}\,e_{3u}\,v\; \delta_{j+1/2}    \; \left[ \overline {u^2}^{\,i} \right]
409    + e_{1w}\,e_{2w}\,w\;  \delta_{k+1/2}       \left[ \overline {u^2}^{\,i} \right] 
410   \biggr\} 
411   && \displaybreak[0] \\
412%
413\equiv& \sum\limits_{i,j,k}
414\overline {u^2}^{\,i} 
415   \biggl\{ 
416      \delta_{i+1/2}    \left[ e_{2u}\,e_{3u}\,u  \right]
417   + \delta_{j+1/2}  \left[ e_{1u}\,e_{3u}\,v  \right]
418   + \delta_{k+1/2}  \left[ e_{1w}\,e_{2w}\,w \right] 
419   \biggr\}  \;\;  \equiv 0
420   &&& \\
421\end{flalign*}
422
423When the UBS scheme is used to evaluate the flux form momentum advection,
424the discrete operator does not contribute to the global budget of linear momentum
425(flux form). The horizontal kinetic energy is not conserved, but forced to decay
426($i.e.$ the scheme is diffusive).
427
428% -------------------------------------------------------------------------------------------------------------
429%       Hydrostatic Pressure Gradient Term
430% -------------------------------------------------------------------------------------------------------------
431\subsection{Hydrostatic Pressure Gradient Term}
432\label{Apdx_C.1.4}
433
434
435A pressure gradient has no contribution to the evolution of the vorticity as the
436curl of a gradient is zero. In the $z$-coordinate, this property is satisfied locally
437on a C-grid with 2nd order finite differences (property \eqref{Eq_DOM_curl_grad}).
438When the equation of state is linear ($i.e.$ when an advection-diffusion equation
439for density can be derived from those of temperature and salinity) the change of
440KE due to the work of pressure forces is balanced by the change of potential
441energy due to buoyancy forces:
442\begin{equation*}
443\int_D - \frac{1} {\rho_o} \left. \nabla p^h \right|_z \cdot \textbf{U}_h \;dv
444= \int_D \nabla \cdot \left( \rho \,\textbf {U} \right)\;g\;z\;\;dv
445\end{equation*}
446
447This property can be satisfied in a discrete sense for both $z$- and $s$-coordinates.
448Indeed, defining the depth of a $T$-point, $z_T$, as the sum of the vertical scale
449factors at $w$-points starting from the surface, the work of pressure forces can be
450written as:
451\begin{flalign*}
452&\int_D - \frac{1} {\rho_o} \left. \nabla p^h \right|_z \cdot \textbf{U}_h \;dv   &&& \\
453\equiv& \sum\limits_{i,j,k} \biggl\{ \;  - \frac{1} {\rho_o e_{1u}}   \Bigl(
454\delta_{i+1/2} \left[ p^h \right] - g\;\overline \rho^{\,i+1/2}\;\delta_{i+1/2} \left[ z_T \right] 
455               \Bigr\; u\;e_{1u}\,e_{2u}\,e_{3u} 
456   &&  \\ & \qquad \qquad
457                                 - \frac{1} {\rho_o e_{2v}}    \Bigl(
458\delta_{j+1/2} \left[ p^h \right] - g\;\overline \rho^{\,j+1/2}\delta_{j+1/2}  \left[ z_T \right] 
459               \Bigr\; v\;e_{1v}\,e_{2v}\,e_{3v} \;
460   \biggr\}   && \\ 
461\end{flalign*}
462
463Using  \eqref{DOM_di_adj}, $i.e.$ the skew symmetry property of the $\delta$ 
464operator, \eqref{Eq_wzv}, the continuity equation), and \eqref{Eq_dynhpg_sco},
465the hydrostatic equation in the $s$-coordinate, it becomes:
466\begin{flalign*} 
467\equiv& \frac{1} {\rho_o} \sum\limits_{i,j,k}    \biggl\{ 
468      e_{2u}\,e_{3u} \;u\;g\; \overline \rho^{\,i+1/2}\;\delta_{i+1/2}[ z_T]   
469   +  e_{1v}\,e_{3v} \;v\;g\; \overline \rho^{\,j+1/2}\;\delta_{j+1/2}[ z_T]     
470&& \\  & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \;\;\,
471   +\Bigl\delta_i[ e_{2u}\,e_{3u}\,u] + \delta_j [ e_{1v}\,e_{3v}\,v]  \Bigr)\;p^h \biggr\}  &&\\
472%
473\equiv& \frac{1} {\rho_o } \sum\limits_{i,j,k}
474   \biggl\{ 
475       e_{2u}\,e_{3u} \;u\;g\;   \overline \rho^{\,i+1/2} \delta_{i+1/2} \left[ z_T \right]
476   +  e_{1v}\,e_{3v} \;v\;g\; \overline \rho^{\,j+1/2} \delta_{j+1/2} \left[ z_T \right] 
477   &&&\\ & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \;\;\,
478    - \delta_k \left[ e_{1w} e_{2w}\,w \right]\;p^h   \biggr\}   &&&\\ 
479%
480\equiv& \frac{1} {\rho_o } \sum\limits_{i,j,k}
481   \biggl\{ 
482      e_{2u}\,e_{3u} \;u\;g\; \overline \rho^{\,i+1/2}\;\delta_{i+1/2} \left[ z_T \right]
483   +  e_{1v}\,e_{3v} \;v\;g\; \overline \rho^{\,j+1/2} \;\delta_{j+1/2} \left[ z_T \right] 
484   &&& \\ & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \;\;\,
485   +   e_{1w} e_{2w} \;w\;\delta_{k+1/2} \left[ p_h \right] 
486   \biggr\}  &&&\\ 
487%
488\equiv& \frac{g} {\rho_o}  \sum\limits_{i,j,k}
489   \biggl\{ 
490      e_{2u}\,e_{3u} \;u\; \overline \rho^{\,i+1/2}\;\delta_{i+1/2} \left[ z_T \right]
491   +  e_{1v}\,e_{3v} \;v\; \overline \rho^{\,j+1/2}\;\delta_{j+1/2} \left[ z_T \right]   
492   &&& \\ & \qquad \qquad \qquad \qquad \qquad \qquad \qquad \;\;\,
493   -  e_{1w} e_{2w} \;w\;e_{3w} \overline \rho^{\,k+1/2} 
494   \biggr\}   &&&\\ 
495\end{flalign*}
496noting that by definition of $z_T$, $\delta_{k+1/2} \left[ z_T \right] \equiv - e_{3w} $, thus:
497\begin{multline*}
498\equiv \frac{g} {\rho_o}  \sum\limits_{i,j,k}
499   \biggl\{ 
500      e_{2u}\,e_{3u} \;u\; \overline \rho^{\,i+1/2}\;\delta_{i+1/2} \left[ z_T \right]
501   +  e_{1v}\,e_{3v} \;v\; \overline \rho^{\,j+1/2} \delta_{j+1/2} \left[ z_T \right]
502   \biggr. \\ 
503\shoveright{
504   \biggl.
505   +  e_{1w} e_{2w} \;w\;  \overline \rho^{\,k+1/2}\;\delta_{k+1/2} \left[ z_T \right] 
506   \biggr\} } \\ 
507\end{multline*}
508Using \eqref{DOM_di_adj}, it becomes:
509\begin{flalign*}
510\equiv& - \frac{g} {\rho_o} \sum\limits_{i,j,k} z_T
511   \biggl\{ 
512      \delta_i    \left[ e_{2u}\,e_{3u}\,u\; \overline \rho^{\,i+1/2}   \right]
513   +  \delta_j    \left[ e_{1v}\,e_{3v}\,v\; \overline \rho^{\,j+1/2}   \right]
514   +  \delta_k    \left[ e_{1w} e_{2w}\,w\;  \overline \rho^{\,k+1/2}   \right] 
515   \biggr\} 
516   &&& \\
517%
518\equiv& -\int_D \nabla \cdot \left( \rho \, \textbf{U} \right)\;g\;z\;\;dv    &&& \\
519\end{flalign*}
520
521Note that this property strongly constrains the discrete expression of both
522the depth of $T-$points and of the term added to the pressure gradient in the
523$s$-coordinate. Nevertheless, it is almost never satisfied since a linear equation
524of state is rarely used.
525
526% -------------------------------------------------------------------------------------------------------------
527%       Surface Pressure Gradient Term
528% -------------------------------------------------------------------------------------------------------------
529\subsection{Surface Pressure Gradient Term}
530\label{Apdx_C.1.5}
531
532
533The surface pressure gradient has no contribution to the evolution of the vorticity.
534This property is trivially satisfied locally since the equation verified by $\psi$ has
535been derived from the discrete formulation of the momentum equation and of the curl.
536But it has to be noted that since the elliptic equation satisfied by $\psi$ is solved
537numerically by an iterative solver (preconditioned conjugate gradient or successive
538over relaxation), the property is only satisfied at the precision requested for the
539solver used.
540
541With the rigid-lid approximation, the change of KE due to the work of surface
542pressure forces is exactly zero. This is satisfied in discrete form, at the precision
543requested for the elliptic solver used to solve this equation. This can be
544demonstrated as follows:
545\begin{flalign*}
546\int\limits_D  - \frac{1} {\rho_o} \nabla_h \left( p_s \right) \cdot \textbf{U}_h \;dv%   &&& \\
547%
548&\equiv \sum\limits_{i,j,k}   \biggl\{    \;
549    \left(  - M_u - \frac{1} {H_u \,e_{2u}}  \delta_j    \left[ \partial_t \psi  \right]   \right)\;
550    u\;e_{1u}\,e_{2u}\,e_{3u} 
551&&&\\&  \qquad \;\;\,
552      + \left(  - M_v + \frac{1} {H_v \,e_{1v}}  \delta_i \left[ \partial_t \psi \right]     \right)\;
553     v\;e_{1v}\,e_{2v}\,e_{3v}   \; \biggr\}     
554&&&\\
555\\
556%
557&\equiv \sum\limits_{i,j}  \Biggl\{   \;
558   \biggl( - M_u - \frac{1} {H_u \,e_{2u}}  \delta_j \left[ \partial_t \psi  \right]   \biggr)
559   \biggl( \sum\limits_k  u\;e_{3u}   \biggr)\;  e_{1u}\,e_{2u} 
560&&&\\&  \qquad \;\;\,
561   + \biggl( - M_v + \frac{1} {H_v \,e_{1v}}  \delta_i \left[ \partial_t \psi  \right]   \biggr)
562      \biggl(   \sum\limits_k   v\;e_{3v}   \biggr)\;   e_{1v}\,e_{2v} \;   \Biggr\} 
563   && \\ 
564%
565\intertext{using the relation between \textit{$\psi $} and the vertical sum of the velocity, it becomes:}
566%
567&\equiv \sum\limits_{i,j} 
568   \biggl\{  \;   
569      \left( \;\;\,
570      M_u + \frac{1} {H_u \,e_{2u}}  \delta_j \left[ \partial_t \psi \right] 
571      \right)\;
572      e_{1u} \,\delta_j
573         \left[ \partial_t \psi  \right] 
574   && \\ &  \qquad \;\;\,
575      + \left(
576      - M_v + \frac{1} {H_v \,e_{1v}}  \delta_i \left[ \partial_t \psi \right] 
577      \right)\;
578      e_{2v} \,\delta_i \left[ \partial_t \psi \right]   \;
579   \biggr\} 
580   && \\ 
581%
582\intertext{applying the adjoint of the $\delta$ operator, it is now:}
583%
584&\equiv \sum\limits_{i,j}  - \partial_t \psi \;
585   \biggl\{    \;
586     \delta_{j+1/2} \left[ e_{1u} M_u \right] 
587     - \delta_{i+1/2} \left[ e_{1v} M_v \right] 
588   && \\ &  \qquad \;\;\,
589   + \delta_{i+1/2} 
590      \left[ \frac{e_{2v}} {H_v \,e_{2v}}  \delta_i \left[ \partial_t \psi \right] 
591      \right]
592   + \delta_{j+1/2} 
593       \left[ \frac{e_{1u}} {H_u \,e_{2u}}  \delta_j \left[ \partial_t \psi \right] 
594       \right
595   \biggr\}   &&&\\
596   &\equiv 0                   && \\ 
597\end{flalign*}
598
599The last equality is obtained using \eqref{Eq_dynspg_rl}, the discrete barotropic
600streamfunction time evolution equation. By the way, this shows that
601\eqref{Eq_dynspg_rl} is the only way to compute the streamfunction,
602otherwise the surface pressure forces will do work. Nevertheless, since
603the elliptic equation satisfied by $\psi $ is solved numerically by an iterative
604solver, the property is only satisfied at the precision requested for the solver.
605
606% ================================================================
607% Conservation Properties on Tracers
608% ================================================================
609\section{Conservation Properties on Tracers}
610\label{Apdx_C.2}
611
612
613All the numerical schemes used in NEMO are written such that the tracer content
614is conserved by the internal dynamics and physics (equations in flux form).
615For advection, only the CEN2 scheme ($i.e.$ $2^{nd}$ order finite different scheme)
616conserves the global variance of tracer. Nevertheless the other schemes ensure
617that the global variance decreases ($i.e.$ they are at least slightly diffusive).
618For diffusion, all the schemes ensure the decrease of the total tracer variance,
619except the iso-neutral operator. There is generally no strict conservation of mass,
620as the equation of state is non linear with respect to $T$ and $S$. In practice,
621the mass is conserved to a very high accuracy.
622% -------------------------------------------------------------------------------------------------------------
623%       Advection Term
624% -------------------------------------------------------------------------------------------------------------
625\subsection{Advection Term}
626\label{Apdx_C.2.1}
627
628Whatever the advection scheme considered it conserves of the tracer content as all
629the scheme are written in flux form. Let $\tau$ be the tracer interpolated at velocity point
630(whatever the interpolation is). The conservation of the tracer content is obtained as follows:
631\begin{flalign*}
632&\int_D \nabla \cdot \left( T \textbf{U} \right)\;dv    &&&\\
633&\equiv  \sum\limits_{i,j,k}    \biggl\{
634    \frac{1} {e_{1T}\,e_{2T}\,e_{3T}} 
635    \left\delta_i    \left[   e_{2u}\,e_{3u}\; u \;\tau_u   \right]
636           + \delta_j    \left[   e_{1v}\,e_{3v}\; v  \;\tau_v   \right] \right)
637&&&\\& \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad \qquad
638   + \frac{1} {e_{3T}} \delta_k \left[ w\;\tau \right]    \biggl\}  e_{1T}\,e_{2T}\,e_{3T} &&&\\
639%
640&\equiv  \sum\limits_{i,j,k}     \left\{
641      \delta_\left[ e_{2u}\,e_{3u}  \,\overline T^{\,i+1/2}\,u \right]
642         + \delta_\left[ e_{1v}\,e_{3v}  \,\overline T^{\,j+1/2}\,v \right] 
643   + \delta_k \left[ e_{1T}\,e_{2T} \,\overline T^{\,k+1/2}\,w \right] \right\} 
644    && \\
645&\equiv 0 &&&
646\end{flalign*}
647
648The conservation of the variance of tracer can be achieved only with the CEN2 scheme.
649It can be demonstarted as follows:
650\begin{flalign*}
651&\int\limits_D T\;\nabla \cdot \left( T\; \textbf{U} \right)\;dv &&&\\
652\equiv& \sum\limits_{i,j,k} T\;
653   \left\{
654      \delta_\left[ e_{2u}\,e_{3u} \overline T^{\,i+1/2}\,u \right]
655   + \delta_\left[ e_{1v}\,e_{3v} \overline T^{\,j+1/2}\,v \right]
656   + \delta_k \left[ e_{1T}\,e_{2T} \overline T^{\,k+1/2}w \right]
657   \right\} 
658   && \\
659\equiv& \sum\limits_{i,j,k} 
660   \left\{
661   -           e_{2u}\,e_{3u} \overline T^{\,i+1/2}\,u\,\delta_{i+1/2}  \left[ T \right] \right.
662   -           e_{1v}\,e_{3v}  \overline T^{\,j+1/2}\,v\;\delta_{j+1/2}  \left[ T \right]
663&&&\\& \qquad \qquad \qquad \qquad \qquad \qquad \quad \;
664   - \left. e_{1T}\,e_{2T} \overline T^{\,k+1/2}w\;\delta_{k+1/2} \left[ T \right]
665   \right\} 
666   &&\\
667\equiv&  -\frac{1} {2}  \sum\limits_{i,j,k}
668   \Bigl\{
669      e_{2u}\,e_{3u} \;  u\;\delta_{i+1/2} \left[ T^2 \right]
670   + e_{1v}\,e_{3v} \;  v\;\delta_{j+1/2}  \left[ T^2 \right]
671   + e_{1T}\,e_{2T} \;w\;\delta_{k+1/2} \left[ T^2 \right]
672   \Bigr\} 
673   && \\ 
674\equiv& \frac{1} {2}  \sum\limits_{i,j,k} T^2
675   \Bigl\{
676      \delta_\left[ e_{2u}\,e_{3u}\,u \right]
677   + \delta_\left[ e_{1v}\,e_{3v}\,v \right]
678   + \delta_k \left[ e_{1T}\,e_{2T}\,w \right]
679   \Bigr\} 
680\quad \equiv 0 &&&
681\end{flalign*}
682
683
684% ================================================================
685% Conservation Properties on Lateral Momentum Physics
686% ================================================================
687\section{Conservation Properties on Lateral Momentum Physics}
688\label{Apdx_dynldf_properties}
689
690
691The discrete formulation of the horizontal diffusion of momentum ensures the
692conservation of potential vorticity and the horizontal divergence, and the
693dissipation of the square of these quantities (i.e. enstrophy and the
694variance of the horizontal divergence) as well as the dissipation of the
695horizontal kinetic energy. In particular, when the eddy coefficients are
696horizontally uniform, it ensures a complete separation of vorticity and
697horizontal divergence fields, so that diffusion (dissipation) of vorticity
698(enstrophy) does not generate horizontal divergence (variance of the
699horizontal divergence) and \textit{vice versa}.
700
701These properties of the horizontal diffusion operator are a direct consequence
702of properties \eqref{Eq_DOM_curl_grad} and \eqref{Eq_DOM_div_curl}.
703When the vertical curl of the horizontal diffusion of momentum (discrete sense)
704is taken, the term associated with the horizontal gradient of the divergence is
705locally zero.
706
707% -------------------------------------------------------------------------------------------------------------
708%       Conservation of Potential Vorticity
709% -------------------------------------------------------------------------------------------------------------
710\subsection{Conservation of Potential Vorticity}
711\label{Apdx_C.3.1}
712
713The lateral momentum diffusion term conserves the potential vorticity :
714\begin{flalign*}
715&\int \limits_D \frac{1} {e_3 } \textbf{k} \cdot \nabla \times 
716   \Bigl[ \nabla_h
717      \left( A^{\,lm}\;\chi  \right)
718   - \nabla_h \times
719      \left( A^{\,lm}\;\zeta \; \textbf{k} \right)
720   \Bigr]\;dv  = 0
721\end{flalign*}
722%%%%%%%%%%  recheck here....  (gm)
723\begin{flalign*}
724= \int \limits_D  -\frac{1} {e_3 } \textbf{k} \cdot \nabla \times 
725   \Bigl[ \nabla_h \times 
726      \left( A^{\,lm}\;\zeta \; \textbf{k} \right)
727   \Bigr]\;dv &&& \\ 
728\end{flalign*}
729\begin{flalign*}
730\equiv& \sum\limits_{i,j}
731   \left\{
732   \delta_{i+1/2} 
733   \left[
734   \frac {e_{2v}} {e_{1v}\,e_{3v}}  \delta_i
735      \left[ A_f^{\,lm} e_{3f} \zeta  \right]
736    \right]
737   + \delta_{j+1/2} 
738   \left[
739   \frac {e_{1u}} {e_{2u}\,e_{3u}} \delta_j
740      \left[ A_f^{\,lm} e_{3f} \zeta  \right]
741   \right]
742   \right\} 
743   && \\ 
744%
745\intertext{Using \eqref{DOM_di_adj}, it follows:}
746%
747\equiv& \sum\limits_{i,j,k} 
748   -\,\left\{
749      \frac{e_{2v}} {e_{1v}\,e_{3v}}  \delta_i
750      \left[ A_f^{\,lm} e_{3f} \zeta  \right]\;\delta_i \left[ 1\right]
751   + \frac{e_{1u}} {e_{2u}\,e_{3u}} \delta_j
752      \left[ A_f^{\,lm} e_{3f} \zeta  \right]\;\delta_j \left[ 1\right]
753   \right\} \quad \equiv 0
754   && \\ 
755\end{flalign*}
756
757% -------------------------------------------------------------------------------------------------------------
758%       Dissipation of Horizontal Kinetic Energy
759% -------------------------------------------------------------------------------------------------------------
760\subsection{Dissipation of Horizontal Kinetic Energy}
761\label{Apdx_C.3.2}
762
763
764The lateral momentum diffusion term dissipates the horizontal kinetic energy:
765%\begin{flalign*}
766\begin{equation*}
767\begin{split}
768\int_D \textbf{U}_h \cdot 
769   \left[ \nabla_h      \right.   &     \left.       \left( A^{\,lm}\;\chi \right)     
770   - \nabla_h \times  \left( A^{\,lm}\;\zeta \;\textbf{k} \right)     \right] \; dv    \\
771\\  %%%
772\equiv& \sum\limits_{i,j,k} 
773   \left\{
774     \frac{1} {e_{1u}}               \delta_{i+1/2} \left[  A_T^{\,lm}          \chi     \right]
775   - \frac{1} {e_{2u}\,e_{3u}}  \delta_j           \left[ A_f^{\,lm} e_{3f} \zeta   \right]
776   \right\} \; e_{1u}\,e_{2u}\,e_{3u} \;u     \\
777&\;\; +  \left\{
778      \frac{1} {e_{2u}}             \delta_{j+1/2} \left[ A_T^{\,lm}          \chi    \right] 
779   + \frac{1} {e_{1v}\,e_{3v}} \delta_i            \left[ A_f^{\,lm} e_{3f} \zeta  \right] 
780   \right\} \; e_{1v}\,e_{2u}\,e_{3v} \;v     \qquad \\ 
781\\  %%%
782\equiv& \sum\limits_{i,j,k} 
783   \Bigl\{
784     e_{2u}\,e_{3u} \;u\;  \delta_{i+1/2} \left[ A_T^{\,lm}           \chi    \right]
785   - e_{1u}             \;u\;  \delta_j           \left[ A_f^{\,lm} e_{3f} \zeta  \right]
786    \Bigl\} 
787    \\ 
788&\;\; + \Bigl\{
789      e_{1v}\,e_{3v} \;v\;  \delta_{j+1/2}  \left[ A_T^{\,lm}           \chi    \right]
790   + e_{2v}             \;v\;  \delta_i            \left[ A_f^{\,lm} e_{3f} \zeta  \right]
791   \Bigl\}      \\ 
792\\  %%%
793\equiv& \sum\limits_{i,j,k} 
794   - \Bigl(
795     \delta_i   \left[  e_{2u}\,e_{3u} \;u  \right]
796   + \delta_\left[  e_{1v}\,e_{3v}  \;v  \right] 
797        \Bigr) \;  A_T^{\,lm} \chi   \\ 
798&\;\; - \Bigl(
799     \delta_{i+1/2}  \left[  e_{2v}  \;v  \right]
800   - \delta_{j+1/2}  \left[  e_{1u} \;u  \right] 
801        \Bigr)\;  A_f^{\,lm} e_{3f} \zeta      \\ 
802\\  %%%
803\equiv& \sum\limits_{i,j,k} 
804   - A_T^{\,lm}  \,\chi^2   \;e_{1T}\,e_{2T}\,e_{3T}
805   - A_f ^{\,lm}  \,\zeta^2 \;e_{1f }\,e_{2f }\,e_{3f} 
806\quad \leq 0       \\
807\end{split}
808\end{equation*}
809
810% -------------------------------------------------------------------------------------------------------------
811%       Dissipation of Enstrophy
812% -------------------------------------------------------------------------------------------------------------
813\subsection{Dissipation of Enstrophy}
814\label{Apdx_C.3.3}
815
816
817The lateral momentum diffusion term dissipates the enstrophy when the eddy
818coefficients are horizontally uniform:
819\begin{flalign*}
820&\int\limits_\zeta \; \textbf{k} \cdot \nabla \times 
821   \left[
822     \nabla_h
823      \left( A^{\,lm}\;\chi  \right)
824   -\nabla_h \times 
825      \left( A^{\,lm}\;\zeta \; \textbf{k} \right)
826   \right]\;dv &&&\\
827&= A^{\,lm} \int \limits_D \zeta \textbf{k} \cdot \nabla \times 
828   \left[
829   \nabla_h \times 
830      \left( \zeta \; \textbf{k} \right)
831   \right]\;dv &&&\displaybreak[0]\\
832&\equiv A^{\,lm} \sum\limits_{i,j,k}  \zeta \;e_{3f} 
833   \left\{
834     \delta_{i+1/2} 
835   \left[
836   \frac{e_{2v}} {e_{1v}\,e_{3v}} \delta_i
837      \left[ e_{3f} \zeta  \right]
838   \right]
839   + \delta_{j+1/2} 
840   \left[
841   \frac{e_{1u}} {e_{2u}\,e_{3u}} \delta_j
842      \left[ e_{3f} \zeta  \right]
843   \right]
844   \right\} 
845   &&&\\ 
846%
847\intertext{Using \eqref{DOM_di_adj}, it follows:}
848%
849&\equiv  - A^{\,lm} \sum\limits_{i,j,k} 
850   \left\{
851     \left(
852     \frac{1} {e_{1v}\,e_{3v}}  \delta_i
853      \left[ e_{3f} \zeta  \right] 
854     \right)^2   e_{1v}\,e_{2v}\,e_{3v}
855   + \left(
856     \frac{1} {e_{2u}\,e_{3u}}  \delta_j
857      \left[ e_{3f} \zeta  \right]
858     \right)^2   e_{1u}\,e_{2u}\,e_{3u}
859     \right\}      &&&\\
860& \leq \;0       &&&\\ 
861\end{flalign*}
862
863% -------------------------------------------------------------------------------------------------------------
864%       Conservation of Horizontal Divergence
865% -------------------------------------------------------------------------------------------------------------
866\subsection{Conservation of Horizontal Divergence}
867\label{Apdx_C.3.4}
868
869When the horizontal divergence of the horizontal diffusion of momentum
870(discrete sense) is taken, the term associated with the vertical curl of the
871vorticity is zero locally, due to (!!! II.1.8  !!!!!). The resulting term conserves the
872$\chi$ and dissipates $\chi^2$ when the eddy coefficients are
873horizontally uniform.
874\begin{flalign*}
875& \int\limits_\nabla_h \cdot 
876   \Bigl[
877     \nabla_h
878      \left( A^{\,lm}\;\chi \right)
879   - \nabla_h \times 
880      \left( A^{\,lm}\;\zeta \;\textbf{k} \right)
881   \Bigr]
882   dv
883= \int\limits_\nabla_h \cdot \nabla_h
884   \left( A^{\,lm}\;\chi  \right)
885   dv
886&&&\\
887&\equiv \sum\limits_{i,j,k} 
888   \left\{ 
889     \delta_i
890      \left[
891      A_u^{\,lm} \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2} 
892         \left[ \chi \right] 
893      \right]
894   + \delta_j
895      \left[
896      A_v^{\,lm} \frac{e_{1v}\,e_{3v}} {e_{2v}}  \delta_{j+1/2} 
897         \left[ \chi \right] 
898      \right]
899   \right\}
900   &&&\\ 
901%
902\intertext{Using \eqref{DOM_di_adj}, it follows:}
903%
904&\equiv \sum\limits_{i,j,k} 
905   - \left\{
906   \frac{e_{2u}\,e_{3u}} {e_{1u}}  A_u^{\,lm} \delta_{i+1/2} 
907      \left[ \chi \right]
908   \delta_{i+1/2} 
909      \left[ 1 \right] 
910   + \frac{e_{1v}\,e_{3v}} {e_{2v}}  A_v^{\,lm} \delta_{j+1/2} 
911      \left[ \chi \right]
912   \delta_{j+1/2} 
913      \left[ 1 \right]
914   \right\} \;
915   \equiv 0
916   &&& \\ 
917\end{flalign*}
918
919% -------------------------------------------------------------------------------------------------------------
920%       Dissipation of Horizontal Divergence Variance
921% -------------------------------------------------------------------------------------------------------------
922\subsection{Dissipation of Horizontal Divergence Variance}
923\label{Apdx_C.3.5}
924
925\begin{flalign*}
926&\int\limits_D \chi \;\nabla_h \cdot 
927   \left[    \nabla_h              \left( A^{\,lm}\;\chi                    \right)
928           - \nabla_h   \times  \left( A^{\,lm}\;\zeta \;\textbf{k} \right)    \right]\;  dv
929 = A^{\,lm}   \int\limits_D \chi \;\nabla_h \cdot \nabla_h \left( \chi \right)\;  dv    &&&\\ 
930%
931&\equiv A^{\,lm}  \sum\limits_{i,j,k}  \frac{1} {e_{1T}\,e_{2T}\,e_{3T}}  \chi 
932   \left\{
933      \delta_\left[   \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2} \left[ \chi \right]   \right]
934   + \delta_\left[   \frac{e_{1v}\,e_{3v}} {e_{2v}}   \delta_{j+1/2} \left[ \chi \right]   \right]
935   \right\} \;   e_{1T}\,e_{2T}\,e_{3T}    &&&\\ 
936%
937\intertext{Using \eqref{DOM_di_adj}, it turns out to be:}
938%
939&\equiv - A^{\,lm} \sum\limits_{i,j,k}
940   \left\{ 
941   \left\frac{1} {e_{1u}}  \delta_{i+1/2}  \left[ \chi \right]  \right)^2  e_{1u}\,e_{2u}\,e_{3u}
942+ \left\frac{1} {e_{2v}}  \delta_{j+1/2}  \left[ \chi \right]  \right)^2  e_{1v}\,e_{2v}\,e_{3v}
943   \right\} \;    &&&\\
944&\leq 0              &&&\\
945\end{flalign*}
946
947% ================================================================
948% Conservation Properties on Vertical Momentum Physics
949% ================================================================
950\section{Conservation Properties on Vertical Momentum Physics}
951\label{Apdx_C_4}
952
953
954As for the lateral momentum physics, the continuous form of the vertical diffusion
955of momentum satisfies several integral constraints. The first two are associated
956with the conservation of momentum and the dissipation of horizontal kinetic energy:
957\begin{align*}
958 \int\limits_
959    \frac{1} {e_3 }\; \frac{\partial } {\partial k}
960   \left(
961   \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}
962   \right)\;
963   dv \qquad \quad &= \vec{\textbf{0}}
964   \\
965%
966\intertext{and}
967%
968\int\limits_D
969   \textbf{U}_h \cdot 
970   \frac{1} {e_3 }\; \frac{\partial } {\partial k}
971   \left(
972   \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}
973   \right)\;
974   dv \quad &\leq 0
975   \\
976\end{align*}
977The first property is obvious. The second results from:
978
979\begin{flalign*}
980\int\limits_D
981   \textbf{U}_h \cdot 
982   \frac{1} {e_3 }\; \frac{\partial } {\partial k}
983   \left(
984   \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} 
985   \right)\;dv
986   &&&\\
987\end{flalign*}
988\begin{flalign*}
989&\equiv \sum\limits_{i,j,k} 
990   \left(
991     u\; \delta_k
992      \left[
993      \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} 
994         \left[ u \right] 
995      \right]\;
996      e_{1u}\,e_{2u} 
997   + v\;\delta_k
998      \left[
999      \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2} 
1000         \left[ v \right] 
1001      \right]\;
1002      e_{1v}\,e_{2v} 
1003   \right)
1004   &&&\\ 
1005%
1006\intertext{since the horizontal scale factor does not depend on $k$, it follows:}
1007%
1008&\equiv - \sum\limits_{i,j,k} 
1009   \left(
1010      \frac{A_u^{\,vm}} {e_{3uw}}
1011      \left(
1012      \delta_{k+1/2} 
1013         \left[ u \right] 
1014      \right)^2\;
1015      e_{1u}\,e_{2u} 
1016   + \frac{A_v^{\,vm}} {e_{3vw}} 
1017      \left( \delta_{k+1/2} 
1018         \left[ v \right] 
1019      \right)^2\;
1020      e_{1v}\,e_{2v}
1021   \right)
1022    \quad \leq 0
1023    &&&\\
1024\end{flalign*}
1025
1026The vorticity is also conserved. Indeed:
1027\begin{flalign*}
1028\int \limits_D
1029   \frac{1} {e_3 } \textbf{k} \cdot \nabla \times 
1030      \left(
1031      \frac{1} {e_3 }\; \frac{\partial } {\partial k}
1032         \left(
1033         \frac{A^{\,vm}} {e_3}\; \frac{\partial \textbf{U}_h } {\partial k} 
1034         \right)
1035      \right)\;
1036      dv
1037      &&&\\ 
1038\end{flalign*}
1039\begin{flalign*}
1040\equiv \sum\limits_{i,j,k}  \frac{1} {e_{3f}}\; \frac{1} {e_{1f}\,e_{2f}}
1041   \bigg\{    \biggr.   \quad
1042   \delta_{i+1/2} 
1043      &\left(
1044      \frac{e_{2v}} {e_{3v}} \delta_k
1045         \left[
1046         \frac{1} {e_{3vw}} \delta_{k+1/2} 
1047            \left[ v \right] 
1048         \right]
1049      \right)
1050    &&\\
1051   \biggl.
1052   - \delta_{j+1/2} 
1053      &\left(
1054      \frac{e_{1u}} {e_{3u}} \delta_k
1055         \left[
1056         \frac{1} {e_{3uw}}\delta_{k+1/2} 
1057            \left[ u \right]
1058         \right]
1059      \right)
1060   \biggr\} \;
1061   e_{1f}\,e_{2f}\,e_{3f} \; \equiv 0
1062   && \\
1063\end{flalign*}
1064If the vertical diffusion coefficient is uniform over the whole domain, the
1065enstrophy is dissipated, $i.e.$
1066\begin{flalign*}
1067\int\limits_D \zeta \, \textbf{k} \cdot \nabla \times 
1068   \left(
1069   \frac{1} {e_3}\; \frac{\partial } {\partial k}
1070      \left(
1071      \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} 
1072      \right)
1073   \right)\;
1074   dv = 0
1075   &&&\\
1076\end{flalign*}
1077This property is only satisfied in $z$-coordinates:
1078
1079\begin{flalign*}
1080\int\limits_D \zeta \, \textbf{k} \cdot \nabla \times 
1081   \left(
1082   \frac{1} {e_3}\; \frac{\partial } {\partial k}
1083      \left(
1084      \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} 
1085      \right)
1086   \right)\;
1087   dv
1088   &&& \\ 
1089\end{flalign*}
1090\begin{flalign*}
1091\equiv \sum\limits_{i,j,k} \zeta \;e_{3f} \;
1092   \biggl\{    \biggr\quad
1093   \delta_{i+1/2} 
1094      &\left(
1095         \frac{e_{2v}} {e_{3v}} \delta_k
1096         \left[
1097         \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2} 
1098            \left[ v \right] 
1099         \right]
1100         \right)
1101         &&\\
1102   - \delta_{j+1/2} 
1103      &\biggl.
1104      \left(   
1105         \frac{e_{1u}} {e_{3u}} \delta_k
1106         \left[
1107         \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} 
1108            \left[ u \right]
1109          \right]
1110         \right)
1111   \biggr\} 
1112   &&\\ 
1113\end{flalign*}
1114\begin{flalign*}
1115\equiv \sum\limits_{i,j,k} \zeta \;e_{3f} 
1116   \biggl\{    \biggr\quad
1117   \frac{1} {e_{3v}} \delta_k
1118      &\left[
1119      \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2} 
1120         \left[ \delta_{i+1/2} 
1121            \left[ e_{2v}\,v \right]
1122          \right]
1123      \right]
1124      &&\\ 
1125    \biggl.
1126   - \frac{1} {e_{3u}} \delta_k
1127      &\left[
1128      \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} 
1129         \left[ \delta_{j+1/2} 
1130            \left[ e_{1u}\,u \right]
1131          \right]
1132      \right]
1133   \biggr\} 
1134   &&\\ 
1135\end{flalign*}
1136Using the fact that the vertical diffusion coefficients are uniform, and that in
1137$z$-coordinate, the vertical scale factors do not depend on $i$ and $j$ so
1138that: $e_{3f} =e_{3u} =e_{3v} =e_{3T} $ and $e_{3w} =e_{3uw} =e_{3vw} $,
1139it follows:
1140\begin{flalign*}
1141\equiv A^{\,vm} \sum\limits_{i,j,k} \zeta \;\delta_k
1142   \left[
1143   \frac{1} {e_{3w}} \delta_{k+1/2} 
1144      \Bigl[
1145      \delta_{i+1/2} 
1146         \left[ e_{2v}\,v \right]
1147      - \delta_{j+1/ 2} 
1148         \left[ e_{1u}\,u \right]
1149       \Bigr]
1150   \right]
1151   &&&\\
1152\end{flalign*}
1153\begin{flalign*}
1154\equiv - A^{\,vm} \sum\limits_{i,j,k} \frac{1} {e_{3w}}
1155   \left(
1156   \delta_{k+1/2} 
1157      \left[ \zeta  \right]
1158    \right)^2 \;
1159    e_{1f}\,e_{2f} 
1160    \; \leq 0
1161    &&&\\
1162\end{flalign*}
1163Similarly, the horizontal divergence is obviously conserved:
1164
1165\begin{flalign*}
1166\int\limits_D \nabla \cdot 
1167   \left(
1168   \frac{1} {e_3 }\; \frac{\partial } {\partial k}
1169      \left(
1170      \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} 
1171      \right)
1172   \right)\;
1173   dv = 0
1174   &&&\\
1175\end{flalign*}
1176and the square of the horizontal divergence decreases ($i.e.$ the horizontal
1177divergence is dissipated) if the vertical diffusion coefficient is uniform over the
1178whole domain:
1179
1180\begin{flalign*}
1181\int\limits_D \chi \;\nabla \cdot 
1182   \left(
1183   \frac{1} {e_3 }\; \frac{\partial } {\partial k}
1184      \left(
1185      \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} 
1186      \right)
1187   \right)\;
1188   dv = 0
1189   &&&\\
1190\end{flalign*}
1191This property is only satisfied in the $z$-coordinate:
1192\begin{flalign*}
1193\int\limits_D \chi \;\nabla \cdot 
1194   \left(
1195   \frac{1} {e_3 }\; \frac{\partial } {\partial k}
1196      \left(
1197      \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k} 
1198      \right)
1199   \right)\;
1200   dv
1201   &&&\\
1202\end{flalign*}
1203\begin{flalign*}
1204\equiv \sum\limits_{i,j,k} \frac{\chi } {e_{1T}\,e_{2T}}
1205   \biggl\{    \Biggr\quad
1206   \delta_{i+1/2} 
1207      &\left(
1208         \frac{e_{2u}} {e_{3u}} \delta_k
1209            \left[
1210         \frac{A_u^{\,vm}} {e_{3uw}} \delta_{k+1/2} 
1211            \left[ u \right] 
1212         \right]
1213       \right)
1214       &&\\ 
1215   \Biggl.
1216   + \delta_{j+1/2} 
1217      &\left(
1218      \frac{e_{1v}} {e_{3v}} \delta_k
1219         \left[
1220         \frac{A_v^{\,vm}} {e_{3vw}} \delta_{k+1/2} 
1221            \left[ v \right]
1222          \right]
1223      \right)
1224   \Biggr\} \;
1225   e_{1T}\,e_{2T}\,e_{3T} 
1226   &&\\ 
1227\end{flalign*}
1228
1229\begin{flalign*}
1230\equiv A^{\,vm} \sum\limits_{i,j,k}  \chi \,
1231   \biggl\{ \biggr\quad
1232   \delta_{i+1/2}
1233      &\left(
1234         \delta_k
1235         \left[
1236         \frac{1} {e_{3uw}} \delta_{k+1/2} 
1237            \left[ e_{2u}\,u \right]
1238          \right]
1239         \right)
1240         && \\ 
1241   \biggl.
1242   + \delta_{j+1/2} 
1243      &\left(
1244         \delta_k
1245         \left[
1246         \frac{1} {e_{3vw}} \delta_{k+1/2} 
1247            \left[ e_{1v}\,v \right]
1248          \right]
1249         \right)
1250   \biggr\} 
1251   && \\ 
1252\end{flalign*}
1253
1254\begin{flalign*}
1255\equiv -A^{\,vm} \sum\limits_{i,j,k} 
1256\frac{\delta_{k+1/2} \left[ \chi \right]} {e_{3w}}\;
1257   \biggl\{ 
1258   \delta_{k+1/2} 
1259      \Bigl[
1260         \delta_{i+1/2} 
1261         \left[ e_{2u}\,u \right]
1262      + \delta_{j+1/2} 
1263         \left[ e_{1v}\,v \right]
1264      \Bigr]
1265   \biggr\} 
1266   &&&\\
1267\end{flalign*}
1268
1269\begin{flalign*}
1270\equiv -A^{\,vm} \sum\limits_{i,j,k}
1271 \frac{1} {e_{3w}} 
1272\delta_{k+1/2} 
1273   \left[ \chi \right]\;
1274\delta_{k+1/2} 
1275   \left[ e_{1T}\,e_{2T} \;\chi \right]
1276&&&\\
1277\end{flalign*}
1278
1279\begin{flalign*}
1280\equiv -A^{\,vm} \sum\limits_{i,j,k} 
1281\frac{e_{1T}\,e_{2T}} {e_{3w}}\;
1282   \left(
1283   \delta_{k+1/2} 
1284      \left[ \chi \right]
1285   \right)^2
1286   \quad  \equiv 0
1287&&&\\
1288\end{flalign*}
1289
1290% ================================================================
1291% Conservation Properties on Tracer Physics
1292% ================================================================
1293\section{Conservation Properties on Tracer Physics}
1294\label{Apdx_C.5}
1295
1296The numerical schemes used for tracer subgridscale physics are written such
1297that the heat and salt contents are conserved (equations in flux form, second
1298order centered finite differences). Since a flux form is used to compute the
1299temperature and salinity, the quadratic form of these quantities (i.e. their variance)
1300globally tends to diminish. As for the advection term, there is generally no strict
1301conservation of mass, even if in practice the mass is conserved to a very high
1302accuracy.
1303
1304% -------------------------------------------------------------------------------------------------------------
1305%       Conservation of Tracers
1306% -------------------------------------------------------------------------------------------------------------
1307\subsection{Conservation of Tracers}
1308\label{Apdx_C.5.1}
1309
1310constraint of conservation of tracers:
1311\begin{flalign*}
1312&\int\limits_\nabla  \cdot \left( A\;\nabla T \right)\;dv  &&&\\ 
1313\\
1314&\equiv \sum\limits_{i,j,k} 
1315   \biggl\{    \biggr.
1316   \delta_i
1317      \left[
1318      A_u^{\,lT} \frac{e_{2u}\,e_{3u}} {e_{1u}} \delta_{i+1/2} 
1319         \left[ T \right]
1320      \right]
1321   + \delta_j
1322      \left[
1323      A_v^{\,lT} \frac{e_{1v}\,e_{3v}} {e_{2v}} \delta_{j+1/2} 
1324         \left[ T \right] 
1325      \right]
1326   &&\\  & \qquad \qquad \qquad \qquad \qquad \qquad \quad \;\;\;
1327   + \delta_k
1328      \left[
1329      A_w^{\,vT} \frac{e_{1T}\,e_{2T}} {e_{3T}} \delta_{k+1/2} 
1330         \left[ T \right] 
1331      \right]
1332   \biggr\}   \quad  \equiv 0
1333   &&\\ 
1334\end{flalign*}
1335
1336In fact, this property simply results from the flux form of the operator.
1337
1338% -------------------------------------------------------------------------------------------------------------
1339%       Dissipation of Tracer Variance
1340% -------------------------------------------------------------------------------------------------------------
1341\subsection{Dissipation of Tracer Variance}
1342\label{Apdx_C.5.2}
1343
1344constraint on the dissipation of tracer variance:
1345\begin{flalign*}
1346\int\limits_D T\;\nabla & \cdot \left( A\;\nabla T \right)\;dv &&&\\ 
1347&\equiv   \sum\limits_{i,j,k} \; T
1348\biggl\{  \biggr.
1349     \delta_i \left[ A_u^{\,lT} \frac{e_{2u}\,e_{3u}} {e_{1u}} \delta_{i+1/2} \left[T\right] \right]
1350& + \delta_j \left[ A_v^{\,lT} \frac{e_{1v} \,e_{3v}} {e_{2v}} \delta_{j+1/2} \left[T\right] \right]
1351      \quad&& \\ 
1352 \biggl.
1353&&+ \delta_k \left[A_w^{\,vT}\frac{e_{1T}\,e_{2T}} {e_{3T}}\delta_{k+1/2}\left[T\right]\right]
1354\biggr\} && 
1355\end{flalign*}
1356\begin{flalign*}
1357\equiv - \sum\limits_{i,j,k} 
1358   \biggl\{    \biggr\quad
1359   & A_u^{\,lT} 
1360      \left(
1361      \frac{1} {e_{1u}} \delta_{i+1/2} 
1362         \left[ T \right]
1363      \right)^2
1364      e_{1u}\,e_{2u}\,e_{3u}
1365   && \\
1366   & + A_v^{\,lT} 
1367      \left(
1368      \frac{1} {e_{2v}} \delta_{j+1/2} 
1369         \left[ T \right] 
1370      \right)^2
1371      e_{1v}\,e_{2v}\,e_{3v}
1372   && \\ 
1373   \biggl.
1374   & + A_w^{\,vT} 
1375      \left(
1376      \frac{1} {e_{3w}} \delta_{k+1/2} 
1377         \left[ T \right] 
1378      \right)^2
1379      e_{1w}\,e_{2w}\,e_{3w} 
1380   \biggr\} 
1381   \quad \leq 0
1382   && \\ 
1383\end{flalign*}
1384
1385
1386%%%%  end of appendix in gm comment
1387%}
Note: See TracBrowser for help on using the repository browser.