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

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

Ignore:
Timestamp:
2012-01-28T17:44:18+01:00 (12 years ago)
Author:
rblod
Message:

Merge of 3.4beta into the trunk

Location:
trunk/DOC/TexFiles/Chapters
Files:
24 edited

Legend:

Unmodified
Added
Removed
  • trunk/DOC/TexFiles/Chapters/Abstracts_Foreword.tex

    • Property svn:executable deleted
    r2541 r3294  
    88\vspace{-40pt} 
    99 
    10 \small{  
     10{\small 
    1111The ocean engine of NEMO (Nucleus for European Modelling of the Ocean) is a primitive  
    1212equation model adapted to regional and global ocean circulation problems. It is intended to  
  • trunk/DOC/TexFiles/Chapters/Annex_A.tex

    • Property svn:executable deleted
    r2282 r3294  
    1313% Chain rule 
    1414% ================================================================ 
    15 \section{Chain rule of $s-$coordinate} 
     15\section{The chain rule for $s-$coordinates} 
    1616\label{Apdx_A_continuity} 
    1717 
    18 In order to establish the set of Primitive Equation in curvilinear $s-$coordinates 
     18In order to establish the set of Primitive Equation in curvilinear $s$-coordinates 
    1919($i.e.$ an orthogonal curvilinear coordinate in the horizontal and an Arbitrary Lagrangian  
    2020Eulerian (ALE) coordinate in the vertical), we start from the set of equations established  
     
    6262% continuity equation 
    6363% ================================================================ 
    64 \section{Continuity Equation in $s-$coordinate} 
     64\section{Continuity Equation in $s-$coordinates} 
    6565\label{Apdx_A_continuity} 
    6666 
     
    128128Here, $w$ is the vertical velocity relative to the $z-$coordinate system.  
    129129Introducing the dia-surface velocity component, $\omega $, defined as  
    130 the velocity relative to the moving $s-$surfaces and normal to them: 
     130the volume flux across the moving $s$-surfaces per unit horizontal area: 
    131131\begin{equation} \label{Apdx_A_w_s} 
    132132\omega  = w - w_s - \sigma _1 \,u - \sigma _2 \,v    \\ 
     
    429429This formulation of the pressure gradient is characterised by the appearance of a term depending on the  
    430430the sea surface height only (last term on the right hand side of expression \eqref{Apdx_A_grad_p}). 
    431 This term will be abusively named \textit{surface pressure gradient} whereas the first term will be named  
     431This term will be loosely termed \textit{surface pressure gradient} 
     432whereas the first term will be termed the  
    432433\textit{hydrostatic pressure gradient} by analogy to the $z$-coordinate formulation.  
    433434In fact, the the true surface pressure gradient is $1/\rho_o \nabla (\rho \eta)$, and  
     
    451452To sum up, in a curvilinear $s$-coordinate system, the vector invariant momentum equation  
    452453solved by the model has the same mathematical expression as the one in a curvilinear  
    453 $z-$coordinate, but the pressure gradient term : 
     454$z-$coordinate, except for the pressure gradient term : 
    454455\begin{subequations} \label{Apdx_A_dyn_vect} 
    455456\begin{multline} \label{Apdx_A_PE_dyn_vect_u} 
     
    495496\end{subequations} 
    496497Both formulation share the same hydrostatic pressure balance expressed in terms of 
    497 hydrostatic pressure and density anmalies, $p_h'$ and $d=( \frac{\rho}{\rho_o}-1 )$: 
     498hydrostatic pressure and density anomalies, $p_h'$ and $d=( \frac{\rho}{\rho_o}-1 )$: 
    498499\begin{equation} \label{Apdx_A_dyn_zph} 
    499500\frac{\partial p_h'}{\partial k} = - d \, g \, e_3 
     
    502503It is important to realize that the change in coordinate system has only concerned 
    503504the position on the vertical. It has not affected (\textbf{i},\textbf{j},\textbf{k}), the  
    504 orthogonal curvilinear set of unit vector. ($u$,$v$) are always horizontal velocities 
     505orthogonal curvilinear set of unit vectors. ($u$,$v$) are always horizontal velocities 
    505506so that their evolution is driven by \emph{horizontal} forces, in particular  
    506507the pressure gradient. By contrast, $\omega$ is not $w$, the third component of the velocity, 
    507 but the dia-surface velocity component, $i.e.$ the velocity relative to the moving  
    508 $s-$surfaces and normal to them.  
     508but the dia-surface velocity component, $i.e.$ the volume flux across the moving  
     509$s$-surfaces per unit horizontal area.  
    509510 
    510511 
  • trunk/DOC/TexFiles/Chapters/Annex_B.tex

    • Property svn:executable deleted
    r2282 r3294  
    1616\label{Apdx_B_1} 
    1717 
    18  
    19 In the $z$-coordinate, the horizontal/vertical second order tracer diffusion operator  
     18\subsubsection*{In z-coordinates} 
     19In $z$-coordinates, the horizontal/vertical second order tracer diffusion operator 
    2020is given by: 
    2121\begin{eqnarray} \label{Apdx_B1} 
    22  &D^T = \frac{1}{e_1 \, e_2}      \left[  
    23   \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.          
     22 &D^T = \frac{1}{e_1 \, e_2}      \left[ 
     23  \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. 
    2424                       \left. 
    25 + \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]          
     25+ \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] 
    2626+ \frac{\partial }{\partial z}\left( {A^{vT} \;\frac{\partial T}{\partial z}} \right) 
    2727\end{eqnarray} 
    2828 
    29 In the $s$-coordinate, we defined the slopes of $s$-surfaces, $\sigma_1$ and  
    30 $\sigma_2$ by \eqref{Apdx_A_s_slope} and the vertical/horizontal ratio of diffusion  
     29\subsubsection*{In generalized vertical coordinates} 
     30In $s$-coordinates, we defined the slopes of $s$-surfaces, $\sigma_1$ and 
     31$\sigma_2$ by \eqref{Apdx_A_s_slope} and the vertical/horizontal ratio of diffusion 
    3132coefficient by $\epsilon = A^{vT} / A^{lT}$. The diffusion operator is given by: 
    3233 
    3334\begin{equation} \label{Apdx_B2} 
    34 D^T = \left. \nabla \right|_s \cdot  
     35D^T = \left. \nabla \right|_s \cdot 
    3536           \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_s T  \right] \\ 
    3637\;\;\text{where} \;\Re =\left( {{\begin{array}{*{20}c} 
    3738 1 \hfill & 0 \hfill & {-\sigma _1 } \hfill \\ 
    3839 0 \hfill & 1 \hfill & {-\sigma _2 } \hfill \\ 
    39  {-\sigma _1 } \hfill & {-\sigma _2 } \hfill & {\varepsilon +\sigma _1  
     40 {-\sigma _1 } \hfill & {-\sigma _2 } \hfill & {\varepsilon +\sigma _1 
    4041^2+\sigma _2 ^2} \hfill \\ 
    4142\end{array} }} \right) 
     
    4344or in expanded form: 
    4445\begin{subequations} 
    45 \begin{align*} {\begin{array}{*{20}l}  
    46 D^T=& \frac{1}{e_1\,e_2\,e_3 }\;\left[ {\ \ \ \ e_2\,e_3\,A^{lT} \;\left.  
     46\begin{align*} {\begin{array}{*{20}l} 
     47D^T=& \frac{1}{e_1\,e_2\,e_3 }\;\left[ {\ \ \ \ e_2\,e_3\,A^{lT} \;\left. 
    4748{\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.  \\ 
    4849&\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 \\ 
    49 &\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.  
    50  \left. {\left. {+\left( {\varepsilon +\sigma _1^2+\sigma _2 ^2} \right)\;\frac{1}{e_3 }\;\frac{\partial T}{\partial s}} \right)\;\;} \right]  
    51 \end{array} }      
     50&\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. 
     51 \left. {\left. {+\left( {\varepsilon +\sigma _1^2+\sigma _2 ^2} \right)\;\frac{1}{e_3 }\;\frac{\partial T}{\partial s}} \right)\;\;} \right] 
     52\end{array} } 
    5253\end{align*} 
    5354\end{subequations} 
    5455 
    55 Equation \eqref{Apdx_B2} is obtained from \eqref{Apdx_B1} without any  
    56 additional assumption. Indeed, for the special case $k=z$ and thus $e_3 =1$,  
    57 we introduce an arbitrary vertical coordinate $s = s (i,j,z)$ as in Appendix~\ref{Apdx_A}  
    58 and use \eqref{Apdx_A_s_slope} and \eqref{Apdx_A_s_chain_rule}.  
    59 Since no cross horizontal derivative $\partial _i \partial _j $ appears in  
    60 \eqref{Apdx_B1}, the ($i$,$z$) and ($j$,$z$) planes are independent.  
    61 The derivation can then be demonstrated for the ($i$,$z$)~$\to$~($j$,$s$)  
     56Equation \eqref{Apdx_B2} is obtained from \eqref{Apdx_B1} without any 
     57additional assumption. Indeed, for the special case $k=z$ and thus $e_3 =1$, 
     58we introduce an arbitrary vertical coordinate $s = s (i,j,z)$ as in Appendix~\ref{Apdx_A} 
     59and use \eqref{Apdx_A_s_slope} and \eqref{Apdx_A_s_chain_rule}. 
     60Since no cross horizontal derivative $\partial _i \partial _j $ appears in 
     61\eqref{Apdx_B1}, the ($i$,$z$) and ($j$,$z$) planes are independent. 
     62The derivation can then be demonstrated for the ($i$,$z$)~$\to$~($j$,$s$) 
    6263transformation without any loss of generality: 
    6364 
    64 \begin{subequations}  
    65 \begin{align*} {\begin{array}{*{20}l}  
    66 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  
     65\begin{subequations} 
     66\begin{align*} {\begin{array}{*{20}l} 
     67D^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 
    6768                     +\frac{\partial }{\partial z}\left( {A^{vT}\;\frac{\partial T}{\partial z}} \right)     \\ 
     69 \\ 
     70% 
     71&=\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 
     72                                                    -\frac{e_1\,\sigma _1 }{e_3 }\frac{\partial T}{\partial s}} \right)} \right)} \right|_s } \right. \\ 
     73& \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] 
     74\shoveright{ +\frac{1}{e_3 }\frac{\partial }{\partial s}\left[ {\frac{A^{vT}}{e_3 }\;\frac{\partial T}{\partial s}} \right]}  \qquad \qquad \qquad \\ 
     75 \\ 
     76% 
     77&=\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. \\ 
     78&  \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) \\ 
     79&  \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] }\\ 
     80\end{array} }     \\ 
     81% 
     82 {\begin{array}{*{20}l} 
     83\intertext{Noting that $\frac{1}{e_1} \left. \frac{\partial e_3 }{\partial i} \right|_s = \frac{\partial \sigma _1 }{\partial s}$, it becomes:} 
     84% 
     85& =\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. \\ 
     86& \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) \\ 
     87& \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] }\\ 
    6888\\ 
    69 \allowdisplaybreaks 
    70 &=\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  
    71                                                     -\frac{e_1\,\sigma _1 }{e_3 }\frac{\partial T}{\partial s}} \right)} \right)} \right|_s } \right. \\  
    72 & \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]    
    73 \shoveright{ +\frac{1}{e_3 }\frac{\partial }{\partial s}\left[ {\frac{A^{vT}}{e_3 }\;\frac{\partial T}{\partial s}} \right]}  \qquad \qquad \qquad \\  
    74 \\ 
    75 \allowdisplaybreaks 
    76 &=\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. \\  
    77 &  \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) \\ 
    78 &  \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] }\\  
    79 \end{array} }     \\ 
    80  {\begin{array}{*{20}l} 
    81 % 
    82 \allowdisplaybreaks 
    83 \intertext{Noting that $\frac{1}{e_1} \left. \frac{\partial e_3 }{\partial i} \right|_s = \frac{\partial \sigma _1 }{\partial s}$, it becomes:} 
    84 % 
    85 & =\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. \\  
    86 & \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) \\  
    87 & \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] }\\  
    88 \\ 
    89 &=\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. \\  
    90 & \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 \\  
    91 & \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) \\  
    92 & \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]} \\  
    93 % 
    94 \allowdisplaybreaks 
     89&=\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. \\ 
     90& \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 \\ 
     91& \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) \\ 
     92& \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]} 
     93\end{array} } \\ 
     94{\begin{array}{*{20}l} 
     95% 
    9596\intertext{using the same remark as just above, it becomes:} 
    9697% 
    97 &= \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.\;\;\; \\  
    98 & \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} \\  
    99 & \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) \\  
    100 & \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] }\\  
    101 % 
    102 \allowdisplaybreaks 
    103 \intertext{Since the horizontal scale factors do not depend on the vertical coordinate,  
    104 the last term of the first line and the first term of the last line cancel, while  
     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 -e_2 \,\sigma _1 A^{lT}\;\frac{\partial T}{\partial s}} \right)} \right|_s } \right.\;\;\; \\ 
     99& \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} \\ 
     100& \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) \\ 
     101& \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] } 
     102 \end{array} } \\ 
     103{\begin{array}{*{20}l} 
     104% 
     105\intertext{Since the horizontal scale factors do not depend on the vertical coordinate, 
     106the last term of the first line and the first term of the last line cancel, while 
    105107the second line reduces to a single vertical derivative, so it becomes:} 
    106108% 
    107 & =\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. \\  
    108 & \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]} \\  
    109 % 
    110 \allowdisplaybreaks 
    111 \intertext{in other words, the horizontal Laplacian operator in the ($i$,$s$) plane takes the following form :} 
    112 \end{array} }     \\ 
    113 % 
    114 D^T = {\frac{1}{e_1\,e_2\,e_3}} 
     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 \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]} 
     111 \\ 
     112% 
     113\intertext{in other words, the horizontal/vertical Laplacian operator in the ($i$,$s$) plane takes the following form:} 
     114\end{array} } \\ 
     115% 
     116{\frac{1}{e_1\,e_2\,e_3}} 
    115117\left( {{\begin{array}{*{30}c} 
    116118{\left. {\frac{\partial \left( {e_2 e_3 \bullet } \right)}{\partial i}} \right|_s } \hfill \\ 
     
    120122\left( {{\begin{array}{*{30}c} 
    121123 {1} \hfill & {-\sigma_1 } \hfill \\ 
    122  {-\sigma_1} \hfill & {\varepsilon_1^2} \hfill \\ 
    123 \end{array} }} \right) 
    124 \cdot  
     124 {-\sigma_1} \hfill & {\varepsilon + \sigma_1^2} \hfill \\ 
     125\end{array} }} \right) 
     126\cdot 
    125127\left( {{\begin{array}{*{30}c} 
    126128{\frac{1}{e_1 }\;\left. {\frac{\partial \bullet }{\partial i}} \right|_s } \hfill \\ 
     
    129131\end{align*} 
    130132\end{subequations} 
    131   
     133\addtocounter{equation}{-2} 
    132134 
    133135% ================================================================ 
     
    137139\label{Apdx_B_2} 
    138140 
    139  
    140 The iso/diapycnal diffusive tensor $\textbf {A}_{\textbf I}$ expressed in the ($i$,$j$,$k$)  
    141 curvilinear coordinate system in which the equations of the ocean circulation model are  
     141\subsubsection*{In z-coordinates} 
     142 
     143The iso/diapycnal diffusive tensor $\textbf {A}_{\textbf I}$ expressed in the ($i$,$j$,$k$) 
     144curvilinear coordinate system in which the equations of the ocean circulation model are 
    142145formulated, takes the following form \citep{Redi_JPO82}: 
    143146 
    144 \begin{equation*} 
     147\begin{equation} \label{Apdx_B3} 
    145148\textbf {A}_{\textbf I} = \frac{A^{lT}}{\left( {1+a_1 ^2+a_2 ^2} \right)} 
    146149\left[ {{\begin{array}{*{20}c} 
     
    149152 {-a_1 } \hfill & {-a_2 } \hfill & {\varepsilon +a_1 ^2+a_2 ^2} \hfill \\ 
    150153\end{array} }} \right] 
    151 \end{equation*} 
    152 where ($a_1$, $a_2$) are the isopycnal slopes in ($\textbf{i}$, $\textbf{j}$) directions: 
     154\end{equation} 
     155where ($a_1$, $a_2$) are the isopycnal slopes in ($\textbf{i}$, 
     156$\textbf{j}$) directions, relative to geopotentials: 
    153157\begin{equation*} 
    154158a_1 =\frac{e_3 }{e_1 }\left( {\frac{\partial \rho }{\partial i}} \right)\left( {\frac{\partial \rho }{\partial k}} \right)^{-1} 
    155159\qquad , \qquad 
    156 a_2 =\frac{e_3 }{e_2 }\left( {\frac{\partial \rho }{\partial j}}  
     160a_2 =\frac{e_3 }{e_2 }\left( {\frac{\partial \rho }{\partial j}} 
    157161\right)\left( {\frac{\partial \rho }{\partial k}} \right)^{-1} 
    158162\end{equation*} 
    159163 
    160 In practice, the isopycnal slopes are generally less than $10^{-2}$ in the ocean, so  
     164In practice, isopycnal slopes are generally less than $10^{-2}$ in the ocean, so 
    161165$\textbf {A}_{\textbf I}$ can be simplified appreciably \citep{Cox1987}: 
    162 \begin{equation*} 
    163 {\textbf{A}_{\textbf{I}}} \approx A^{lT} 
     166\begin{subequations} \label{Apdx_B4} 
     167\begin{equation} \label{Apdx_B4a} 
     168{\textbf{A}_{\textbf{I}}} \approx A^{lT}\;\Re\;\text{where} \;\Re = 
    164169\left[ {{\begin{array}{*{20}c} 
    165170 1 \hfill & 0 \hfill & {-a_1 } \hfill \\ 
    166171 0 \hfill & 1 \hfill & {-a_2 } \hfill \\ 
    167172 {-a_1 } \hfill & {-a_2 } \hfill & {\varepsilon +a_1 ^2+a_2 ^2} \hfill \\ 
    168 \end{array} }} \right] 
    169 \end{equation*} 
    170  
    171 The resulting isopycnal operator conserves the quantity and dissipates its square.  
    172 The demonstration of the first property is trivial as \eqref{Apdx_B2} is the divergence  
     173\end{array} }} \right], 
     174\end{equation} 
     175and the iso/dianeutral diffusive operator in $z$-coordinates is then 
     176\begin{equation}\label{Apdx_B4b} 
     177 D^T = \left. \nabla \right|_z \cdot 
     178           \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_z T  \right]. \\ 
     179\end{equation} 
     180\end{subequations} 
     181 
     182 
     183Physically, the full tensor \eqref{Apdx_B3} 
     184represents strong isoneutral diffusion on a plane parallel to the isoneutral 
     185surface and weak dianeutral diffusion perpendicular to this plane. 
     186However, the approximate `weak-slope' tensor \eqref{Apdx_B4a} represents strong 
     187diffusion along the isoneutral surface, with weak 
     188\emph{vertical}  diffusion -- the principal axes of the tensor are no 
     189longer orthogonal. This simplification also decouples 
     190the ($i$,$z$) and ($j$,$z$) planes of the tensor. The weak-slope operator therefore takes the same 
     191form, \eqref{Apdx_B4}, as \eqref{Apdx_B2}, the diffusion operator for geopotential 
     192diffusion written in non-orthogonal $i,j,s$-coordinates. Written out 
     193explicitly, 
     194 
     195\begin{multline} \label{Apdx_B_ldfiso} 
     196 D^T=\frac{1}{e_1 e_2 }\left\{ 
     197 {\;\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]} 
     198 {+\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\} \\ 
     199\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]}. \\ 
     200\end{multline} 
     201 
     202 
     203The isopycnal diffusion operator \eqref{Apdx_B4}, 
     204\eqref{Apdx_B_ldfiso} conserves tracer quantity and dissipates its 
     205square. The demonstration of the first property is trivial as \eqref{Apdx_B4} is the divergence 
    173206of fluxes. Let us demonstrate the second one: 
    174207\begin{equation*} 
    175 \iiint\limits_D T\;\nabla .\left( {\textbf{A}}_{\textbf{I}} \nabla T \right)\,dv  
    176           = -\iiint\limits_D \nabla T\;.\left( {\textbf{A}}_{\textbf{I}} \nabla T \right)\,dv 
     208\iiint\limits_D T\;\nabla .\left( {\textbf{A}}_{\textbf{I}} \nabla T \right)\,dv 
     209          = -\iiint\limits_D \nabla T\;.\left( {\textbf{A}}_{\textbf{I}} \nabla T \right)\,dv, 
    177210\end{equation*} 
    178 since 
    179 \begin{subequations}  
    180 \begin{align*} {\begin{array}{*{20}l}  
    181 \nabla T\;.\left( {{\rm {\bf A}}_{\rm {\bf I}} \nabla T}  
    182 \right)&=A^{lT}\left[ {\left( {\frac{\partial T}{\partial i}} \right)^2-2a_1  
    183 \frac{\partial T}{\partial i}\frac{\partial T}{\partial k}+\left(  
    184 {\frac{\partial T}{\partial j}} \right)^2} \right. \\  
     211and since 
     212\begin{subequations} 
     213\begin{align*} {\begin{array}{*{20}l} 
     214\nabla T\;.\left( {{\rm {\bf A}}_{\rm {\bf I}} \nabla T} 
     215\right)&=A^{lT}\left[ {\left( {\frac{\partial T}{\partial i}} \right)^2-2a_1 
     216\frac{\partial T}{\partial i}\frac{\partial T}{\partial k}+\left( 
     217{\frac{\partial T}{\partial j}} \right)^2} \right. \\ 
    185218&\qquad \qquad \qquad 
    186 { \left. -\,{2a_2 \frac{\partial T}{\partial j}\frac{\partial T}{\partial k}+\left( {a_1 ^2+a_2 ^2} \right)\left( {\frac{\partial T}{\partial k}} \right)^2} \right]} \\ 
    187 &=A_h \left[ {\left( {\frac{\partial T}{\partial i}-a_1 \frac{\partial T}{\partial k}} \right)^2+\left( {\frac{\partial T}{\partial j}-a_2 \frac{\partial T}{\partial k}} \right)^2} \right]      \\ 
     219{ \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]} \\ 
     220&=A_h \left[ {\left( {\frac{\partial T}{\partial i}-a_1 \frac{\partial 
     221          T}{\partial k}} \right)^2+\left( {\frac{\partial T}{\partial 
     222          j}-a_2 \frac{\partial T}{\partial k}} \right)^2} 
     223  +\varepsilon \left(\frac{\partial T}{\partial k}\right) ^2\right]      \\ 
    188224& \geq 0 
    189 \end{array} }      
     225\end{array} } 
    190226\end{align*} 
    191227\end{subequations} 
    192 the property becomes obvious.  
    193  
    194 The resulting diffusion operator in $z$-coordinate has the following form : 
    195 \begin{multline*} \label{Apdx_B_ldfiso} 
    196  D^T=\frac{1}{e_1 e_2 }\left\{  
    197  {\;\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]} 
    198  {+\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\} \\ 
    199 \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} \right)}{e_3 }\frac{\partial T}{\partial k}} \right)} \right]} \\  
    200 \end{multline*} 
    201  
    202 It has to be emphasised that the simplification introduced, leads to a decoupling  
    203 between ($i$,$z$) and ($j$,$z$) planes. The operator has therefore the same  
    204 expression as \eqref{Apdx_B3}, the diffusion operator obtained for geopotential  
    205 diffusion in the $s$-coordinate.  
     228\addtocounter{equation}{-1} 
     229 the property becomes obvious. 
     230 
     231\subsubsection*{In generalized vertical coordinates} 
     232 
     233Because the weak-slope operator \eqref{Apdx_B4}, \eqref{Apdx_B_ldfiso} is decoupled 
     234in the ($i$,$z$) and ($j$,$z$) planes, it may be transformed into 
     235generalized $s$-coordinates in the same way as \eqref{Apdx_B_1} was transformed into 
     236\eqref{Apdx_B_2}. The resulting operator then takes the simple form 
     237 
     238\begin{equation} \label{Apdx_B_ldfiso_s} 
     239D^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), 
     247\end{equation} 
     248 
     249where ($r_1$, $r_2$) are the isopycnal slopes in ($\textbf{i}$, 
     250$\textbf{j}$) directions, relative to $s$-coordinate surfaces: 
     251\begin{equation*} 
     252r_1 =\frac{e_3 }{e_1 }\left( {\frac{\partial \rho }{\partial i}} \right)\left( {\frac{\partial \rho }{\partial s}} \right)^{-1} 
     253\qquad , \qquad 
     254r_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*} 
     257 
     258To prove  \eqref{Apdx_B5}  by direct re-expression of \eqref{Apdx_B_ldfiso} is 
     259straightforward, but laborious. An easier way is first to note (by reversing the 
     260derivation of \eqref{Apdx_B_2} from \eqref{Apdx_B_1} ) that the 
     261weak-slope operator may be \emph{exactly} reexpressed in  
     262non-orthogonal $i,j,\rho$-coordinates as 
     263 
     264\begin{equation} \label{Apdx_B5} 
     265D^T = \left. \nabla \right|_\rho \cdot 
     266           \left[ A^{lT} \;\Re \cdot \left. \nabla \right|_\rho T  \right] \\ 
     267\;\;\text{where} \;\Re =\left( {{\begin{array}{*{20}c} 
     268 1 \hfill & 0 \hfill &0 \hfill \\ 
     269 0 \hfill & 1 \hfill & 0 \hfill \\ 
     2700 \hfill & 0 \hfill & \varepsilon \hfill \\ 
     271\end{array} }} \right). 
     272\end{equation} 
     273Then direct transformation from $i,j,\rho$-coordinates to 
     274$i,j,s$-coordinates gives \eqref{Apdx_B_ldfiso_s} immediately. 
     275 
     276Note that the weak-slope approximation is only made in 
     277transforming from the (rotated,orthogonal) isoneutral axes to the 
     278non-orthogonal $i,j,\rho$-coordinates. The further transformation 
     279into $i,j,s$-coordinates is exact, whatever the steepness of 
     280the  $s$-surfaces, in the same way as the transformation of 
     281horizontal/vertical Laplacian diffusion in $z$-coordinates, 
     282\eqref{Apdx_B_1} onto $s$-coordinates is exact, however steep the $s$-surfaces. 
     283 
    206284 
    207285% ================================================================ 
     
    211289\label{Apdx_B_3} 
    212290 
    213 The second order momentum diffusion operator (Laplacian) in the $z$-coordinate  
    214 is found by applying \eqref{Eq_PE_lap_vector}, the expression for the Laplacian  
    215 of a vector,  to the horizontal velocity vector :  
     291The second order momentum diffusion operator (Laplacian) in the $z$-coordinate 
     292is found by applying \eqref{Eq_PE_lap_vector}, the expression for the Laplacian 
     293of a vector,  to the horizontal velocity vector : 
    216294\begin{align*} 
    217 \Delta {\textbf{U}}_h  
     295\Delta {\textbf{U}}_h 
    218296&=\nabla \left( {\nabla \cdot {\textbf{U}}_h } \right)- 
    219297\nabla \times \left( {\nabla \times {\textbf{U}}_h } \right)    \\ 
     
    224302 {\frac{1}{e_3 }\frac{\partial \chi }{\partial k}} \hfill \\ 
    225303\end{array} }} \right)-\left( {{\begin{array}{*{20}c} 
    226  {\frac{1}{e_2 }\frac{\partial \zeta }{\partial j}-\frac{1}{e_3  
    227 }\frac{\partial }{\partial k}\left( {\frac{1}{e_3 }\frac{\partial  
     304 {\frac{1}{e_2 }\frac{\partial \zeta }{\partial j}-\frac{1}{e_3 
     305}\frac{\partial }{\partial k}\left( {\frac{1}{e_3 }\frac{\partial 
    228306u}{\partial k}} \right)} \hfill \\ 
    229  {\frac{1}{e_3 }\frac{\partial }{\partial k}\left( {-\frac{1}{e_3  
    230 }\frac{\partial v}{\partial k}} \right)-\frac{1}{e_1 }\frac{\partial \zeta  
     307 {\frac{1}{e_3 }\frac{\partial }{\partial k}\left( {-\frac{1}{e_3 
     308}\frac{\partial v}{\partial k}} \right)-\frac{1}{e_1 }\frac{\partial \zeta 
    231309}{\partial i}} \hfill \\ 
    232  {\frac{1}{e_1 e_2 }\left[ {\frac{\partial }{\partial i}\left( {\frac{e_2  
    233 }{e_3 }\frac{\partial u}{\partial k}} \right)-\frac{\partial }{\partial  
    234 j}\left( {-\frac{e_1 }{e_3 }\frac{\partial v}{\partial k}} \right)} \right]}  
     310 {\frac{1}{e_1 e_2 }\left[ {\frac{\partial }{\partial i}\left( {\frac{e_2 
     311}{e_3 }\frac{\partial u}{\partial k}} \right)-\frac{\partial }{\partial 
     312j}\left( {-\frac{e_1 }{e_3 }\frac{\partial v}{\partial k}} \right)} \right]} 
    235313\hfill \\ 
    236314\end{array} }} \right) 
     
    249327\end{array} }} \right) 
    250328\end{align*} 
    251 Using \eqref{Eq_PE_div}, the definition of the horizontal divergence, the third  
     329Using \eqref{Eq_PE_div}, the definition of the horizontal divergence, the third 
    252330componant of the second vector is obviously zero and thus : 
    253331\begin{equation*} 
     
    255333\end{equation*} 
    256334 
    257 Note that this operator ensures a full separation between the vorticity and horizontal  
    258 divergence fields (see Appendix~\ref{Apdx_C}). It is only equal to a Laplacian  
     335Note that this operator ensures a full separation between the vorticity and horizontal 
     336divergence fields (see Appendix~\ref{Apdx_C}). It is only equal to a Laplacian 
    259337applied to each component in Cartesian coordinates, not on the sphere. 
    260338 
    261 The horizontal/vertical second order (Laplacian type) operator used to diffuse  
     339The horizontal/vertical second order (Laplacian type) operator used to diffuse 
    262340horizontal momentum in the $z$-coordinate therefore takes the following form : 
    263341\begin{equation} \label{Apdx_B_Lap_U} 
    264  {\textbf{D}}^{\textbf{U}} =  
     342 {\textbf{D}}^{\textbf{U}} = 
    265343     \nabla _h \left( {A^{lm}\;\chi } \right) 
    266344   - \nabla _h \times \left( {A^{lm}\;\zeta \;{\textbf{k}}} \right) 
    267345   + \frac{1}{e_3 }\frac{\partial }{\partial k}\left( {\frac{A^{vm}\;}{e_3 } 
    268             \frac{\partial {\rm {\bf U}}_h }{\partial k}} \right) \\  
     346            \frac{\partial {\rm {\bf U}}_h }{\partial k}} \right) \\ 
    269347\end{equation} 
    270348that is, in expanded form: 
    271349\begin{align*} 
    272 D^{\textbf{U}}_u  
     350D^{\textbf{U}}_u 
    273351& = \frac{1}{e_1} \frac{\partial \left( {A^{lm}\chi   } \right)}{\partial i} 
    274352     -\frac{1}{e_2} \frac{\partial \left( {A^{lm}\zeta } \right)}{\partial j} 
    275353     +\frac{1}{e_3} \frac{\partial u}{\partial k}      \\ 
    276 D^{\textbf{U}}_v    
     354D^{\textbf{U}}_v 
    277355& = \frac{1}{e_2 }\frac{\partial \left( {A^{lm}\chi   } \right)}{\partial j} 
    278356     +\frac{1}{e_1 }\frac{\partial \left( {A^{lm}\zeta } \right)}{\partial i} 
     
    280358\end{align*} 
    281359 
    282 Note Bene: introducing a rotation in \eqref{Apdx_B_Lap_U} does not lead to a  
    283 useful expression for the iso/diapycnal Laplacian operator in the $z$-coordinate.  
    284 Similarly, we did not found an expression of practical use for the geopotential  
    285 horizontal/vertical Laplacian operator in the $s$-coordinate. Generally,  
    286 \eqref{Apdx_B_Lap_U} is used in both $z$- and $s$-coordinate systems, that is  
     360Note Bene: introducing a rotation in \eqref{Apdx_B_Lap_U} does not lead to a 
     361useful expression for the iso/diapycnal Laplacian operator in the $z$-coordinate. 
     362Similarly, we did not found an expression of practical use for the geopotential 
     363horizontal/vertical Laplacian operator in the $s$-coordinate. Generally, 
     364\eqref{Apdx_B_Lap_U} is used in both $z$- and $s$-coordinate systems, that is 
    287365a Laplacian diffusion is applied on momentum along the coordinate directions. 
  • trunk/DOC/TexFiles/Chapters/Annex_C.tex

    • Property svn:executable deleted
  • trunk/DOC/TexFiles/Chapters/Annex_D.tex

    • Property svn:executable deleted
  • trunk/DOC/TexFiles/Chapters/Annex_E.tex

    • Property svn:executable deleted
  • trunk/DOC/TexFiles/Chapters/Annex_ISO.tex

    r2376 r3294  
    11% ================================================================ 
    2 % Iso-neutral diffusion :  
     2% Iso-neutral diffusion : 
    33% ================================================================ 
    4 \chapter{Griffies's iso-neutral diffusion} 
    5 \label{Apdx_C} 
     4\chapter[Iso-neutral diffusion and eddy advection using 
     5triads]{Iso-neutral diffusion and eddy advection using triads} 
     6\label{sec:triad} 
    67\minitoc 
    7  
    8 \section{Griffies's formulation of iso-neutral diffusion} 
    9  
    10 \subsection{Introduction} 
    11  We define a scheme that get its inspiration from the scheme of 
    12 \citet{Griffies_al_JPO98}, but is formulated within the \NEMO 
     8\pagebreak 
     9\section{Choice of namelist parameters} 
     10%-----------------------------------------nam_traldf------------------------------------------------------ 
     11\namdisplay{namtra_ldf} 
     12%--------------------------------------------------------------------------------------------------------- 
     13If the namelist variable \np{ln\_traldf\_grif} is set true (and 
     14\key{ldfslp} is set), \NEMO updates both active and passive tracers 
     15using the Griffies triad representation of iso-neutral diffusion and 
     16the eddy-induced advective skew (GM) fluxes. Otherwise (by default) the 
     17filtered version of Cox's original scheme is employed 
     18(\S\ref{LDF_slp}). In the present implementation of the Griffies 
     19scheme, the advective skew fluxes are implemented even if 
     20\key{traldf\_eiv} is not set. 
     21 
     22Values of iso-neutral diffusivity and GM coefficient are set as 
     23described in \S\ref{LDF_coef}. If none of the keys \key{traldf\_cNd}, 
     24N=1,2,3 is set (the default), spatially constant iso-neutral $A_l$ and 
     25GM diffusivity $A_e$ are directly set by \np{rn\_aeih\_0} and 
     26\np{rn\_aeiv\_0}. If 2D-varying coefficients are set with 
     27\key{traldf\_c2d} then $A_l$ is reduced in proportion with horizontal 
     28scale factor according to \eqref{Eq_title} \footnote{Except in global 
     29  $0.5^{\circ}$ runs (\key{orca\_r05}) with \key{traldf\_eiv}, where 
     30  $A_l$ is set like $A_e$ but with a minimum vale of 
     31  $100\;\mathrm{m}^2\;\mathrm{s}^{-1}$}. In idealised setups with 
     32\key{traldf\_c2d}, $A_e$ is reduced similarly, but if \key{traldf\_eiv} 
     33is set in the global configurations \key{orca\_r2}, \key{orca\_r1} or 
     34\key{orca\_r05} with \key{traldf\_c2d}, a horizontally varying $A_e$ is 
     35instead set from the Held-Larichev parameterisation\footnote{In this 
     36  case, $A_e$ at low latitudes $|\theta|<20^{\circ}$ is further 
     37  reduced by a factor $|f/f_{20}|$, where $f_{20}$ is the value of $f$ 
     38  at $20^{\circ}$~N} (\mdl{ldfeiv}) and \np{rn\_aeiv\_0} is ignored 
     39unless it is zero. 
     40 
     41The options specific to the Griffies scheme include: 
     42\begin{description}[font=\normalfont] 
     43\item[\np{ln\_traldf\_gdia}] Default value is false. See \S\ref{sec:triad:sfdiag}. If this is set true, time-mean 
     44  eddy-advective (GM) velocities are output for diagnostic purposes, even 
     45  though the eddy advection is accomplished by means of the skew 
     46  fluxes. 
     47\item[\np{ln\_traldf\_iso}] See \S\ref{sec:triad:taper}. If this is set false (the default), then 
     48  `iso-neutral' mixing is accomplished within the surface mixed-layer 
     49  along slopes linearly decreasing with depth from the value immediately below 
     50  the mixed-layer to zero (flat) at the surface (\S\ref{sec:triad:lintaper}). This is the same 
     51  treatment as used in the default implementation 
     52  \S\ref{LDF_slp_iso}; Fig.~\ref{Fig_eiv_slp}.  Where 
     53  \np{ln\_traldf\_iso} is set true, the vertical skew flux is further 
     54  reduced to ensure no vertical buoyancy flux, giving an almost pure 
     55  horizontal diffusive tracer flux within the mixed layer. This is similar to 
     56  the tapering suggested by \citet{Gerdes1991}. See \S\ref{sec:triad:Gerdes-taper} 
     57\item[\np{ln\_traldf\_botmix}] See \S\ref{sec:triad:iso_bdry}. If this 
     58  is set false (the default) then the lateral diffusive fluxes 
     59  associated with triads partly masked by topography are neglected. If 
     60  it is set true, however, then these lateral diffusive fluxes are 
     61  applied, giving smoother bottom tracer fields at the cost of 
     62  introducing diapycnal mixing. 
     63\end{description} 
     64\section{Triad formulation of iso-neutral diffusion} 
     65\label{sec:triad:iso} 
     66We have implemented into \NEMO a scheme inspired by \citet{Griffies_al_JPO98}, but formulated within the \NEMO 
    1367framework, using scale factors rather than grid-sizes. 
    1468 
    15 The off-diagonal terms of the small angle diffusion tensor 
    16 \eqref{Eq_PE_iso_tensor} produce skew-fluxes along the 
    17 i- and j-directions resulting from the vertical tracer gradient: 
    18 \begin{align} 
    19   \label{eq:i13c} 
    20   &+\kappa r_1\frac{1}{e_3}\frac{\partial T}{\partial k},\qquad+\kappa r_2\frac{1}{e_3}\frac{\partial T}{\partial k}\\ 
    21 \intertext{and in the k-direction resulting from the lateral tracer gradients} 
    22   \label{eq:i31c} 
    23  & \kappa r_1\frac{1}{e_1}\frac{\partial T}{\partial i}+\kappa r_2\frac{1}{e_1}\frac{\partial T}{\partial i} 
    24 \end{align} 
    25 where \eqref{Eq_PE_iso_slopes} 
     69\subsection{The iso-neutral diffusion operator} 
     70The iso-neutral second order tracer diffusive operator for small 
     71angles between iso-neutral surfaces and geopotentials is given by 
     72\eqref{Eq_PE_iso_tensor}: 
     73\begin{subequations} \label{eq:triad:PE_iso_tensor} 
     74  \begin{equation} 
     75    D^{lT}=-\Div\vect{f}^{lT}\equiv 
     76    -\frac{1}{e_1e_2e_3}\left[\pd{i}\left (f_1^{lT}e_2e_3\right) + 
     77      \pd{j}\left (f_2^{lT}e_2e_3\right) + \pd{k}\left (f_3^{lT}e_1e_2\right)\right], 
     78  \end{equation} 
     79  where the diffusive flux per unit area of physical space 
     80  \begin{equation} 
     81    \vect{f}^{lT}=-\Alt\Re\cdot\grad T, 
     82  \end{equation} 
     83  \begin{equation} 
     84    \label{eq:triad:PE_iso_tensor:c} 
     85    \mbox{with}\quad \;\;\Re = 
     86    \begin{pmatrix} 
     87      1&0&-r_1\mystrut \\ 
     88      0&1&-r_2\mystrut \\ 
     89      -r_1&-r_2&r_1 ^2+r_2 ^2\mystrut 
     90    \end{pmatrix} 
     91    \quad \text{and} \quad\grad T= 
     92    \begin{pmatrix} 
     93      \frac{1}{e_1}\pd[T]{i}\mystrut \\ 
     94      \frac{1}{e_2}\pd[T]{j}\mystrut \\ 
     95      \frac{1}{e_3}\pd[T]{k}\mystrut 
     96    \end{pmatrix}. 
     97  \end{equation} 
     98\end{subequations} 
     99% \left( {{\begin{array}{*{20}c} 
     100%  1 \hfill & 0 \hfill & {-r_1 } \hfill \\ 
     101%  0 \hfill & 1 \hfill & {-r_2 } \hfill \\ 
     102%  {-r_1 } \hfill & {-r_2 } \hfill & {r_1 ^2+r_2 ^2} \hfill \\ 
     103% \end{array} }} \right) 
     104 Here \eqref{Eq_PE_iso_slopes} 
    26105\begin{align*} 
    27106  r_1 &=-\frac{e_3 }{e_1 } \left( \frac{\partial \rho }{\partial i} 
     
    33112    }{\partial k} \right)^{-1} 
    34113\end{align*} 
    35 is the i-component of the slope of the isoneutral surface relative to the computational 
    36 surface, and $r_2$ is the j-component. 
    37  
    38 The extra vertical diffusive flux associated with the $_{33}$ 
     114is the $i$-component of the slope of the iso-neutral surface relative to the computational 
     115surface, and $r_2$ is the $j$-component. 
     116 
     117We will find it useful to consider the fluxes per unit area in $i,j,k$ 
     118space; we write 
     119\begin{equation} 
     120  \label{eq:triad:Fijk} 
     121  \vect{F}_{\mathrm{iso}}=\left(f_1^{lT}e_2e_3, f_2^{lT}e_1e_3, f_3^{lT}e_1e_2\right). 
     122\end{equation} 
     123Additionally, we will sometimes write the contributions towards the 
     124fluxes $\vect{f}$ and $\vect{F}_\mathrm{iso}$ from the component 
     125$R_{ij}$ of $\Re$ as $f_{ij}$, $F_{\mathrm{iso}\: ij}$, with 
     126$f_{ij}=R_{ij}e_i^{-1}\partial T/\partial x_i$ (no summation) etc. 
     127 
     128The off-diagonal terms of the small angle diffusion tensor 
     129\eqref{Eq_PE_iso_tensor}, \eqref{eq:triad:PE_iso_tensor:c} produce skew-fluxes along the 
     130$i$- and $j$-directions resulting from the vertical tracer gradient: 
     131\begin{align} 
     132  \label{eq:triad:i13c} 
     133  f_{13}=&+\Alt r_1\frac{1}{e_3}\frac{\partial T}{\partial k},\qquad f_{23}=+\Alt r_2\frac{1}{e_3}\frac{\partial T}{\partial k}\\ 
     134\intertext{and in the k-direction resulting from the lateral tracer gradients} 
     135  \label{eq:triad:i31c} 
     136 f_{31}+f_{32}=& \Alt r_1\frac{1}{e_1}\frac{\partial T}{\partial i}+\Alt r_2\frac{1}{e_1}\frac{\partial T}{\partial i} 
     137\end{align} 
     138 
     139The vertical diffusive flux associated with the $_{33}$ 
    39140component of the small angle diffusion tensor is 
    40141\begin{equation} 
    41   \label{eq:i33c} 
    42   -\kappa(r_1^2 +r_2^2) \frac{1}{e_3}\frac{\partial T}{\partial k}. 
     142  \label{eq:triad:i33c} 
     143  f_{33}=-\Alt(r_1^2 +r_2^2) \frac{1}{e_3}\frac{\partial T}{\partial k}. 
    43144\end{equation} 
    44145 
    45146Since there are no cross terms involving $r_1$ and $r_2$ in the above, we can 
    46 consider the isoneutral diffusive fluxes separately in the i-k and j-k 
     147consider the iso-neutral diffusive fluxes separately in the $i$-$k$ and $j$-$k$ 
    47148planes, just adding together the vertical components from each 
    48 plane. The following description will describe the fluxes on the i-k 
     149plane. The following description will describe the fluxes on the $i$-$k$ 
    49150plane. 
    50151 
    51 There is no natural discretization for the i-component of the 
    52 skew-flux, \eqref{eq:i13c}, as 
    53 although it must be evaluated at u-points, it involves vertical 
     152There is no natural discretization for the $i$-component of the 
     153skew-flux, \eqref{eq:triad:i13c}, as 
     154although it must be evaluated at $u$-points, it involves vertical 
    54155gradients (both for the tracer and the slope $r_1$), defined at 
    55 w-points. Similarly, the vertical skew flux, \eqref{eq:i31c}, is evaluated at 
    56 w-points but involves horizontal gradients defined at u-points. 
     156$w$-points. Similarly, the vertical skew flux, \eqref{eq:triad:i31c}, is evaluated at 
     157$w$-points but involves horizontal gradients defined at $u$-points. 
    57158 
    58159\subsection{The standard discretization} 
    59160The straightforward approach to discretize the lateral skew flux 
    60 \eqref{eq:i13c} from tracer cell $i,k$ to $i+1,k$, introduced in 1995 
     161\eqref{eq:triad:i13c} from tracer cell $i,k$ to $i+1,k$, introduced in 1995 
    61162into OPA, \eqref{Eq_tra_ldf_iso}, is to calculate a mean vertical 
    62 gradient at the u-point from the average of the four surrounding 
     163gradient at the $u$-point from the average of the four surrounding 
    63164vertical tracer gradients, and multiply this by a mean slope at the 
    64 u-point, calculated from the averaged surrounding vertical density 
    65 gradients. The total area-integrated skew-flux from tracer cell $i,k$ 
    66 to $i+1,k$, noting that the $e_{{3u}_{i+1/2}^k}$ in the area 
    67 $e_{{3u}_{i+1/2}^k}e_{{2u}_{i+1/2}^k}$ at the u-point cancels out with 
    68 the $1/e_{{3u}_{i+1/2}^k}$ associated with the vertical tracer 
     165$u$-point, calculated from the averaged surrounding vertical density 
     166gradients. The total area-integrated skew-flux (flux per unit area in 
     167$ijk$ space) from tracer cell $i,k$ 
     168to $i+1,k$, noting that the $e_{{3}_{i+1/2}^k}$ in the area 
     169$e{_{3}}_{i+1/2}^k{e_{2}}_{i+1/2}i^k$ at the $u$-point cancels out with 
     170the $1/{e_{3}}_{i+1/2}^k$ associated with the vertical tracer 
    69171gradient, is then \eqref{Eq_tra_ldf_iso} 
    70172\begin{equation*} 
    71   \left(F_u^{\mathrm{skew}} \right)_{i+\hhalf}^k = \kappa _{i+\hhalf}^k 
    72   e_{{2u}_{i+1/2}^k} \overline{\overline 
     173  \left(F_u^{13} \right)_{i+\hhalf}^k = \Alts_{i+\hhalf}^k 
     174  {e_{2}}_{i+1/2}^k \overline{\overline 
    73175    r_1} ^{\,i,k}\,\overline{\overline{\delta_k T}}^{\,i,k}, 
    74176\end{equation*} 
     
    76178\begin{equation*} 
    77179  \overline{\overline 
    78     r_1} ^{\,i,k} = -\frac{e_{{3u}_{i+1/2}^k}}{e_{{1u}_{i+1/2}^k}} 
    79   \frac{\delta_{i+1/2} [\rho]}{\overline{\overline{\delta_k \rho}}^{\,i,k}}. 
     180   r_1} ^{\,i,k} = -\frac{{e_{3u}}_{i+1/2}^k}{{e_{1u}}_{i+1/2}^k} 
     181  \frac{\delta_{i+1/2} [\rho]}{\overline{\overline{\delta_k \rho}}^{\,i,k}}, 
    80182\end{equation*} 
    81  
     183and here and in the following we drop the $^{lT}$ superscript from 
     184$\Alt$ for simplicity. 
    82185Unfortunately the resulting combination $\overline{\overline{\delta_k 
    83186    \bullet}}^{\,i,k}$ of a $k$ average and a $k$ difference %of the tracer 
     
    89192global-average variance. To correct this, we introduced a smoothing of 
    90193the slopes of the iso-neutral surfaces (see \S\ref{LDF}). This 
    91 technique works fine for $T$ and $S$ as they are active tracers 
     194technique works for $T$ and $S$ in so far as they are active tracers 
    92195($i.e.$ they enter the computation of density), but it does not work 
    93196for a passive tracer. 
     
    95198\citep{Griffies_al_JPO98} introduce a different discretization of the 
    96199off-diagonal terms that nicely solves the problem. 
    97 % Instead of multiplying the mean slope calculated at the u-point by 
    98 % the mean vertical gradient at the u-point, 
     200% Instead of multiplying the mean slope calculated at the $u$-point by 
     201% the mean vertical gradient at the $u$-point, 
    99202% >>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    100203\begin{figure}[h] \begin{center} 
    101204    \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_triad_fluxes} 
    102     \caption{  \label{Fig_ISO_triad}   
     205    \caption{ \label{fig:triad:ISO_triad} 
    103206      (a) Arrangement of triads $S_i$ and tracer gradients to 
    104            give lateral tracer flux from box $i,k$ to $i+1,k$  
     207           give lateral tracer flux from box $i,k$ to $i+1,k$ 
    105208      (b) Triads $S'_i$ and tracer gradients to give vertical tracer flux from 
    106209            box $i,k$ to $i,k+1$.} 
    107     \label{Fig_triad} 
    108   \end{center} \end{figure} 
     210 \end{center} \end{figure} 
    109211% >>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    110212They get the skew flux from the products of the vertical gradients at 
    111 each w-point surrounding the u-point with the corresponding `triad' 
    112 slope calculated from the lateral density gradient across the u-point 
    113 divided by the vertical density gradient at the same w-point as the 
    114 tracer gradient. See Fig.~\ref{Fig_triad}a, where the thick lines 
     213each $w$-point surrounding the $u$-point with the corresponding `triad' 
     214slope calculated from the lateral density gradient across the $u$-point 
     215divided by the vertical density gradient at the same $w$-point as the 
     216tracer gradient. See Fig.~\ref{fig:triad:ISO_triad}a, where the thick lines 
    115217denote the tracer gradients, and the thin lines the corresponding 
    116218triads, with slopes $s_1, \dotsc s_4$. The total area-integrated 
    117219skew-flux from tracer cell $i,k$ to $i+1,k$ 
    118220\begin{multline} 
    119   \label{eq:i13} 
    120   \left( F_u^{13}  \right)_{i+\frac{1}{2}}^k = \kappa _{i+1}^k a_1 s_1 
     221  \label{eq:triad:i13} 
     222  \left( F_u^{13}  \right)_{i+\frac{1}{2}}^k = \Alts_{i+1}^k a_1 s_1 
    121223  \delta _{k+\frac{1}{2}} \left[ T^{i+1} 
    122   \right]/e_{{3w}_{i+1}}^{k+\frac{1}{2}}  + \kappa _i^k a_2 s_2 \delta 
     224  \right]/e_{{3w}_{i+1}}^{k+\frac{1}{2}}  + \Alts _i^k a_2 s_2 \delta 
    123225  _{k+\frac{1}{2}} \left[ T^i 
    124226  \right]/e_{{3w}_{i+1}}^{k+\frac{1}{2}} \\ 
    125    +\kappa _{i+1}^k a_3 s_3 \delta _{k-\frac{1}{2}} \left[ T^{i+1} 
    126   \right]/e_{{3w}_{i+1}}^{k+\frac{1}{2}}  +\kappa _i^k a_4 s_4 \delta 
     227   +\Alts _{i+1}^k a_3 s_3 \delta _{k-\frac{1}{2}} \left[ T^{i+1} 
     228  \right]/e_{{3w}_{i+1}}^{k+\frac{1}{2}}  +\Alts _i^k a_4 s_4 \delta 
    127229  _{k-\frac{1}{2}} \left[ T^i \right]/e_{{3w}_{i+1}}^{k+\frac{1}{2}}, 
    128230\end{multline} 
    129231where the contributions of the triad fluxes are weighted by areas 
    130 $a_1, \dotsc a_4$, and $\kappa$ is now defined at the tracer points 
    131 rather than the u-points. This discretization gives a much closer 
     232$a_1, \dotsc a_4$, and $\Alts$ is now defined at the tracer points 
     233rather than the $u$-points. This discretization gives a much closer 
    132234stencil, and disallows the two-point computational modes. 
    133235 
    134  The vertical skew flux \eqref{eq:i31c} from tracer cell $i,k$ to $i,k+1$ at the 
    135 w-point $i,k+\hhalf$ is constructed similarly (Fig.~\ref{Fig_triad}b) 
     236 The vertical skew flux \eqref{eq:triad:i31c} from tracer cell $i,k$ to $i,k+1$ at the 
     237$w$-point $i,k+\hhalf$ is constructed similarly (Fig.~\ref{fig:triad:ISO_triad}b) 
    136238by multiplying lateral tracer gradients from each of the four 
    137 surrounding u-points by the appropriate triad slope: 
     239surrounding $u$-points by the appropriate triad slope: 
    138240\begin{multline} 
    139   \label{eq:i31} 
    140   \left( F_w^{31} \right) _i ^{k+\frac{1}{2}} =  \kappa_i^{k+1} a_{1}' 
     241  \label{eq:triad:i31} 
     242  \left( F_w^{31} \right) _i ^{k+\frac{1}{2}} =  \Alts_i^{k+1} a_{1}' 
    141243  s_{1}' \delta _{i-\frac{1}{2}} \left[ T^{k+1} \right]/{e_{3u}}_{i-\frac{1}{2}}^{k+1} 
    142    +\kappa_i^{k+1} a_{2}' s_{2}' \delta _{i+\frac{1}{2}} \left[ T^{k+1} \right]/{e_{3u}}_{i+\frac{1}{2}}^{k+1}\\ 
    143   + \kappa_i^k a_{3}' s_{3}' \delta _{i-\frac{1}{2}} \left[ T^k\right]/{e_{3u}}_{i-\frac{1}{2}}^k 
    144   +\kappa_i^k a_{4}' s_{4}' \delta _{i+\frac{1}{2}} \left[ T^k \right]/{e_{3u}}_{i+\frac{1}{2}}^k. 
     244   +\Alts_i^{k+1} a_{2}' s_{2}' \delta _{i+\frac{1}{2}} \left[ T^{k+1} \right]/{e_{3u}}_{i+\frac{1}{2}}^{k+1}\\ 
     245  + \Alts_i^k a_{3}' s_{3}' \delta _{i-\frac{1}{2}} \left[ T^k\right]/{e_{3u}}_{i-\frac{1}{2}}^k 
     246  +\Alts_i^k a_{4}' s_{4}' \delta _{i+\frac{1}{2}} \left[ T^k \right]/{e_{3u}}_{i+\frac{1}{2}}^k. 
    145247\end{multline} 
    146   
    147 We notate the triad slopes in terms of the `anchor point' $i,k$ 
    148 (appearing in both the vertical and lateral gradient), and the u- and 
    149 w-points $(i+i_p,k)$, $(i,k+k_p)$ at the centres of the `arms' of the 
    150 triad as follows (see also Fig.~\ref{Fig_triad}): 
    151 \begin{equation} 
    152   \label{Gf_slopes} 
    153   _i^k \mathbb{R}_{i_p}^{k_p}  
    154   =\frac{ {e_{3w}}_{\,i}^{\,k+k_p}} { {e_{1u}}_{\,i+i_p}^{\,k}} 
     248 
     249We notate the triad slopes $s_i$ and $s'_i$ in terms of the `anchor point' $i,k$ 
     250(appearing in both the vertical and lateral gradient), and the $u$- and 
     251$w$-points $(i+i_p,k)$, $(i,k+k_p)$ at the centres of the `arms' of the 
     252triad as follows (see also Fig.~\ref{fig:triad:ISO_triad}): 
     253\begin{equation} 
     254  \label{eq:triad:R} 
     255  _i^k \mathbb{R}_{i_p}^{k_p} 
     256  =-\frac{ {e_{3w}}_{\,i}^{\,k+k_p}} { {e_{1u}}_{\,i+i_p}^{\,k}} 
    155257  \ 
    156   \frac  
     258  \frac 
    157259  {\left(\alpha / \beta \right)_i^k  \ \delta_{i + i_p}[T^k] - \delta_{i + i_p}[S^k] } 
    158260  {\left(\alpha / \beta \right)_i^k  \ \delta_{k+k_p}[T^i ] - \delta_{k+k_p}[S^i ] }. 
     
    160262In calculating the slopes of the local neutral 
    161263surfaces, the expansion coefficients $\alpha$ and $\beta$ are 
    162 evaluated at the anchor points of the triad \footnote{Note that in \eqref{Gf_slopes} we use the ratio $\alpha / \beta$ 
     264evaluated at the anchor points of the triad \footnote{Note that in \eqref{eq:triad:R} we use the ratio $\alpha / \beta$ 
    163265instead of multiplying the temperature derivative by $\alpha$ and the 
    164266salinity derivative by $\beta$. This is more efficient as the ratio 
    165267$\alpha / \beta$ can to be evaluated directly}, while the metrics are 
    166 calculated at the u- and w-points on the arms. 
     268calculated at the $u$- and $w$-points on the arms. 
    167269 
    168270% >>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    169271\begin{figure}[h] \begin{center} 
    170272    \includegraphics[width=0.60\textwidth]{./TexFiles/Figures/Fig_qcells} 
    171     \caption{   \label{Fig_ISO_triad_notation}   
    172     Triad notation for quarter cells.T-cells are inside 
    173       boxes, while the  $i+\half,k$ u-cell is shaded in green and the 
    174       $i,k+\half$ w-cell is shaded in pink.} 
    175     \label{qcells} 
     273    \caption{   \label{fig:triad:qcells} 
     274    Triad notation for quarter cells.$T$-cells are inside 
     275      boxes, while the  $i+\half,k$ $u$-cell is shaded in green and the 
     276      $i,k+\half$ $w$-cell is shaded in pink.} 
    176277  \end{center} \end{figure} 
    177278% >>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    178279 
    179 Each triad $\{_i^k\:_{i_p}^{k_p}\}$ is associated (Fig.~\ref{qcells}) with the quarter 
    180 cell that is the intersection of the $i,k$ T-cell, the $i+i_p,k$ 
    181 u-cell and the $i,k+k_p$ w-cell. Expressing the slopes $s_i$ and 
    182 $s'_i$ in \eqref{eq:i13} and \eqref{eq:i31} in this notation, we have 
     280Each triad $\{_i^k\:_{i_p}^{k_p}\}$ is associated (Fig.~\ref{fig:triad:qcells}) with the quarter 
     281cell that is the intersection of the $i,k$ $T$-cell, the $i+i_p,k$ 
     282$u$-cell and the $i,k+k_p$ $w$-cell. Expressing the slopes $s_i$ and 
     283$s'_i$ in \eqref{eq:triad:i13} and \eqref{eq:triad:i31} in this notation, we have 
    183284e.g.\ $s_1=s'_1={\:}_i^k \mathbb{R}_{1/2}^{1/2}$. Each triad slope $_i^k 
    184285\mathbb{R}_{i_p}^{k_p}$ is used once (as an $s$) to calculate the 
    185 lateral flux along its u-arm, at $(i+i_p,k)$, and then again as an 
    186 $s'$ to calculate the vertical flux along its w-arm at 
     286lateral flux along its $u$-arm, at $(i+i_p,k)$, and then again as an 
     287$s'$ to calculate the vertical flux along its $w$-arm at 
    187288$(i,k+k_p)$. Each vertical area $a_i$ used to calculate the lateral 
    188289flux and horizontal area $a'_i$ used to calculate the vertical flux 
    189 can also be identified as the area across the u- and w-arms of a 
    190 unique triad, and we can notate these areas, similarly to the triad 
     290can also be identified as the area across the $u$- and $w$-arms of a 
     291unique triad, and we notate these areas, similarly to the triad 
    191292slopes, as $_i^k{\mathbb{A}_u}_{i_p}^{k_p}$, 
    192 $_i^k{\mathbb{A}_w}_{i_p}^{k_p}$, where e.g. in \eqref{eq:i13} 
    193 $a_{1}={\:}_i^k{\mathbb{A}_u}_{1/2}^{1/2}$, and in \eqref{eq:i31} 
     293$_i^k{\mathbb{A}_w}_{i_p}^{k_p}$, where e.g. in \eqref{eq:triad:i13} 
     294$a_{1}={\:}_i^k{\mathbb{A}_u}_{1/2}^{1/2}$, and in \eqref{eq:triad:i31} 
    194295$a'_{1}={\:}_i^k{\mathbb{A}_w}_{1/2}^{1/2}$. 
    195296 
    196297\subsection{The full triad fluxes} 
    197 A key property of isoneutral diffusion is that it should not affect 
     298A key property of iso-neutral diffusion is that it should not affect 
    198299the (locally referenced) density. In particular there should be no 
    199300lateral or vertical density flux. The lateral density flux disappears so long as the 
     
    202303form 
    203304\begin{equation} 
    204   \label{eq:i11} 
     305  \label{eq:triad:i11} 
    205306  \left( F_u^{11} \right) _{i+\frac{1}{2}} ^{k} = 
    206   - \left( \kappa_i^{k+1} a_{1} + \kappa_i^{k+1} a_{2} + \kappa_i^k 
    207     a_{3} + \kappa_i^k a_{4} \right) 
     307  - \left( \Alts_i^{k+1} a_{1} + \Alts_i^{k+1} a_{2} + \Alts_i^k 
     308    a_{3} + \Alts_i^k a_{4} \right) 
    208309  \frac{\delta _{i+1/2} \left[ T^k\right]}{{e_{1u}}_{\,i+1/2}^{\,k}}, 
    209310\end{equation} 
    210 where the areas $a_i$ are as in \eqref{eq:i13}. In this case, 
    211 separating the total lateral flux, the sum of \eqref{eq:i13} and 
    212 \eqref{eq:i11}, into triad components, a lateral tracer 
     311where the areas $a_i$ are as in \eqref{eq:triad:i13}. In this case, 
     312separating the total lateral flux, the sum of \eqref{eq:triad:i13} and 
     313\eqref{eq:triad:i11}, into triad components, a lateral tracer 
    213314flux 
    214315\begin{equation} 
    215   \label{eq:latflux-triad} 
    216   _i^k {\mathbb{F}_u}_{i_p}^{k_p} (T) = -A_i^k{ \:}_i^k{\mathbb{A}_u}_{i_p}^{k_p} 
     316  \label{eq:triad:latflux-triad} 
     317  _i^k {\mathbb{F}_u}_{i_p}^{k_p} (T) = - \Alts_i^k{ \:}_i^k{\mathbb{A}_u}_{i_p}^{k_p} 
    217318  \left( 
    218319    \frac{ \delta_{i+ i_p}[T^k] }{ {e_{1u}}_{\,i + i_p}^{\,k} } 
     
    227328density flux associated with each triad separately disappears. 
    228329\begin{equation} 
    229   \label{eq:latflux-rho} 
     330  \label{eq:triad:latflux-rho} 
    230331  {\mathbb{F}_u}_{i_p}^{k_p} (\rho)=-\alpha _i^k {\:}_i^k {\mathbb{F}_u}_{i_p}^{k_p} (T) + \beta_i^k {\:}_i^k {\mathbb{F}_u}_{i_p}^{k_p} (S)=0 
    231332\end{equation} 
     
    234335to $i+1,k$ must also vanish since it is a sum of four such triad fluxes. 
    235336 
    236 The squared slope $r_1^2$ in the expression \eqref{eq:i33c} for the 
     337The squared slope $r_1^2$ in the expression \eqref{eq:triad:i33c} for the 
    237338$_{33}$ component is also expressed in terms of area-weighted 
    238339squared triad slopes, so the area-integrated vertical flux from tracer 
    239340cell $i,k$ to $i,k+1$ resulting from the $r_1^2$ term is 
    240341\begin{equation} 
    241   \label{eq:i33} 
     342  \label{eq:triad:i33} 
    242343  \left( F_w^{33} \right) _i^{k+\frac{1}{2}} = 
    243     - \left( \kappa_i^{k+1} a_{1}' s_{1}'^2 
    244     + \kappa_i^{k+1} a_{2}' s_{2}'^2 
    245     + \kappa_i^k a_{3}' s_{3}'^2 
    246     + \kappa_i^k a_{4}' s_{4}'^2 \right)\delta_{k+\frac{1}{2}} \left[ T^{i+1} \right], 
     344    - \left( \Alts_i^{k+1} a_{1}' s_{1}'^2 
     345    + \Alts_i^{k+1} a_{2}' s_{2}'^2 
     346    + \Alts_i^k a_{3}' s_{3}'^2 
     347    + \Alts_i^k a_{4}' s_{4}'^2 \right)\delta_{k+\frac{1}{2}} \left[ T^{i+1} \right], 
    247348\end{equation} 
    248349where the areas $a'$ and slopes $s'$ are the same as in 
    249 \eqref{eq:i31}. 
    250 Then, separating the total vertical flux, the sum of \eqref{eq:i31} and 
    251 \eqref{eq:i33}, into triad components,  a vertical flux  
     350\eqref{eq:triad:i31}. 
     351Then, separating the total vertical flux, the sum of \eqref{eq:triad:i31} and 
     352\eqref{eq:triad:i33}, into triad components,  a vertical flux 
    252353\begin{align} 
    253   \label{eq:vertflux-triad} 
     354  \label{eq:triad:vertflux-triad} 
    254355  _i^k {\mathbb{F}_w}_{i_p}^{k_p} (T) 
    255   &= A_i^k{\: }_i^k{\mathbb{A}_w}_{i_p}^{k_p} 
     356  &= \Alts_i^k{\: }_i^k{\mathbb{A}_w}_{i_p}^{k_p} 
    256357  \left( 
    257358    {_i^k\mathbb{R}_{i_p}^{k_p}}\frac{ \delta_{i+ i_p}[T^k] }{ {e_{1u}}_{\,i + i_p}^{\,k} } 
     
    260361  \right) \\ 
    261362  &= - \left(\left.{ }_i^k{\mathbb{A}_w}_{i_p}^{k_p}\right/{ }_i^k{\mathbb{A}_u}_{i_p}^{k_p}\right) 
    262    {_i^k\mathbb{R}_{i_p}^{k_p}}{\: }_i^k{\mathbb{F}_u}_{i_p}^{k_p} (T) \label{eq:vertflux-triad2} 
     363   {_i^k\mathbb{R}_{i_p}^{k_p}}{\: }_i^k{\mathbb{F}_u}_{i_p}^{k_p} (T) \label{eq:triad:vertflux-triad2} 
    263364\end{align} 
    264365may be associated with each triad. Each vertical density flux $_i^k {\mathbb{F}_w}_{i_p}^{k_p} (\rho)$ 
     
    270371fluxes. 
    271372 
    272 We can explicitly identify (Fig.~\ref{qcells}) the triads associated with the $s_i$, $a_i$, and $s'_i$, $a'_i$ used in the definition of 
    273 the u-fluxes and w-fluxes in 
    274 \eqref{eq:i31}, \eqref{eq:i13}, \eqref{eq:i11} \eqref{eq:i33} and 
    275 Fig.~\ref{Fig_triad} to  write out the iso-neutral fluxes at $u$- and 
     373We can explicitly identify (Fig.~\ref{fig:triad:qcells}) the triads associated with the $s_i$, $a_i$, and $s'_i$, $a'_i$ used in the definition of 
     374the $u$-fluxes and $w$-fluxes in 
     375\eqref{eq:triad:i31}, \eqref{eq:triad:i13}, \eqref{eq:triad:i11} \eqref{eq:triad:i33} and 
     376Fig.~\ref{fig:triad:ISO_triad} to  write out the iso-neutral fluxes at $u$- and 
    276377$w$-points as sums of the triad fluxes that cross the $u$- and $w$-faces: 
    277378%(Fig.~\ref{Fig_ISO_triad}): 
    278 \begin{flalign} \label{Eq_iso_flux} \textbf{F}_{iso}(T) &\equiv 
     379\begin{flalign} \label{Eq_iso_flux} \vect{F}_\mathrm{iso}(T) &\equiv 
    279380  \sum_{\substack{i_p,\,k_p}} 
    280381  \begin{pmatrix} 
     
    284385  \end{pmatrix}. 
    285386\end{flalign} 
    286 \subsection{Ensuring the scheme cannot increase tracer variance} 
    287 \label{sec:variance} 
    288  
    289 We now require that this operator cannot increase the 
     387\subsection{Ensuring the scheme does not increase tracer variance} 
     388\label{sec:triad:variance} 
     389 
     390We now require that this operator should not increase the 
    290391globally-integrated tracer variance. 
    291392%This changes according to 
    292393% \begin{align*} 
    293394% &\int_D  D_l^T \; T \;dv \equiv  \sum_{i,k} \left\{ T \ D_l^T \ b_T \right\}    \\ 
    294 % &\equiv + \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{   
    295 %     \delta_{i} \left[{_{i+1/2-i_p}^k {\mathbb{F}_u }_{i_p}^{k_p}} \right]  
     395% &\equiv + \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{ 
     396%     \delta_{i} \left[{_{i+1/2-i_p}^k {\mathbb{F}_u }_{i_p}^{k_p}} \right] 
    296397%       + \delta_{k} \left[ {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p}} \right]  \ T \right\}    \\ 
    297 % &\equiv  - \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{   
     398% &\equiv  - \sum_{i,k} \sum_{\substack{i_p,\,k_p}} \left\{ 
    298399%                 {_{i+1/2-i_p}^k {\mathbb{F}_u }_{i_p}^{k_p}} \ \delta_{i+1/2} [T] 
    299400%              + {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p}}  \ \delta_{k+1/2} [T]   \right\}      \\ 
    300401% \end{align*} 
    301402Each triad slope $_i^k\mathbb{R}_{i_p}^{k_p}$ drives a lateral flux 
    302 $_i^k{\mathbb{F}_u}_{i_p}^{k_p} (T)$ across the u-point $i+i_p,k$ and 
     403$_i^k{\mathbb{F}_u}_{i_p}^{k_p} (T)$ across the $u$-point $i+i_p,k$ and 
    303404a vertical flux $_i^k{\mathbb{F}_w}_{i_p}^{k_p} (T)$ across the 
    304 w-point $i,k+k_p$.  The lateral flux drives a net rate of change of 
    305 variance at points $i+i_p-\half,k$ and $i+i_p+\half,k$ of 
     405$w$-point $i,k+k_p$.  The lateral flux drives a net rate of change of 
     406variance, summed over the two $T$-points $i+i_p-\half,k$ and $i+i_p+\half,k$, of 
    306407\begin{multline} 
    307408  {b_T}_{i+i_p-1/2}^k\left(\frac{\partial T}{\partial t}T\right)_{i+i_p-1/2}^k+ 
     
    311412  &= -T_{i+i_p-1/2}^k{\;} _i^k{\mathbb{F}_u}_{i_p}^{k_p} (T) \quad + \quad  T_{i+i_p+1/2}^k 
    312413  {\;}_i^k{\mathbb{F}_u}_{i_p}^{k_p} (T) \\ 
    313   &={\;} _i^k{\mathbb{F}_u}_{i_p}^{k_p} (T)\,\delta_{i+ i_p}[T^k], \label{locFdtdx} 
     414  &={\;} _i^k{\mathbb{F}_u}_{i_p}^{k_p} (T)\,\delta_{i+ i_p}[T^k], \label{eq:triad:dvar_iso_i} 
    314415 \end{split} 
    315416\end{multline} 
    316 while the vertical flux similarly drives a net rate of change of variance at points $i,k+k_p-\half$ and 
    317 $i,k+k_p+\half$ of 
    318 \begin{equation} 
    319 \label{locFdtdz} 
     417while the vertical flux similarly drives a net rate of change of 
     418variance summed over the $T$-points $i,k+k_p-\half$ (above) and 
     419$i,k+k_p+\half$ (below) of 
     420\begin{equation} 
     421\label{eq:triad:dvar_iso_k} 
    320422  _i^k{\mathbb{F}_w}_{i_p}^{k_p} (T) \,\delta_{k+ k_p}[T^i]. 
    321423\end{equation} 
    322424The total variance tendency driven by the triad is the sum of these 
    323425two. Expanding $_i^k{\mathbb{F}_u}_{i_p}^{k_p} (T)$ and 
    324 $_i^k{\mathbb{F}_w}_{i_p}^{k_p} (T)$ with \eqref{eq:latflux-triad} and 
    325 \eqref{eq:vertflux-triad}, it is 
     426$_i^k{\mathbb{F}_w}_{i_p}^{k_p} (T)$ with \eqref{eq:triad:latflux-triad} and 
     427\eqref{eq:triad:vertflux-triad}, it is 
    326428\begin{multline*} 
    327 -A_i^k\left \{ 
     429-\Alts_i^k\left \{ 
    328430{ } _i^k{\mathbb{A}_u}_{i_p}^{k_p} 
    329431  \left( 
     
    343445to be related to a triad volume $_i^k\mathbb{V}_{i_p}^{k_p}$ by 
    344446\begin{equation} 
    345   \label{eq:V-A} 
     447  \label{eq:triad:V-A} 
    346448  _i^k\mathbb{V}_{i_p}^{k_p} 
    347449  ={\;}_i^k{\mathbb{A}_u}_{i_p}^{k_p}\,{e_{1u}}_{\,i + i_p}^{\,k} 
     
    350452the variance tendency reduces to the perfect square 
    351453\begin{equation} 
    352   \label{eq:perfect-square} 
    353   -A_i^k{\:} _i^k\mathbb{V}_{i_p}^{k_p} 
     454  \label{eq:triad:perfect-square} 
     455  -\Alts_i^k{\:} _i^k\mathbb{V}_{i_p}^{k_p} 
    354456  \left( 
    355457    \frac{ \delta_{i+ i_p}[T^k] }{ {e_{1u}}_{\,i + i_p}^{\,k} } 
     
    358460  \right)^2\leq 0. 
    359461\end{equation} 
    360 Thus, the constraint \eqref{eq:V-A} ensures that the fluxes associated 
     462Thus, the constraint \eqref{eq:triad:V-A} ensures that the fluxes (\ref{eq:triad:latflux-triad}, \ref{eq:triad:vertflux-triad}) associated 
    361463with a given slope triad $_i^k\mathbb{R}_{i_p}^{k_p}$ do not increase 
    362464the net variance. Since the total fluxes are sums of such fluxes from 
     
    365467increase. 
    366468 
    367 The expression \eqref{eq:V-A} can be interpreted as a discretization 
     469The expression \eqref{eq:triad:V-A} can be interpreted as a discretization 
    368470of the global integral 
    369471\begin{equation} 
    370   \label{eq:cts-var} 
    371   \frac{\partial}{\partial t}\int\half T^2\, dV = 
    372   \int\mathbf{F}\cdot\nabla T\, dV, 
     472  \label{eq:triad:cts-var} 
     473  \frac{\partial}{\partial t}\int\!\half T^2\, dV = 
     474  \int\!\mathbf{F}\cdot\nabla T\, dV, 
    373475\end{equation} 
    374476where, within each triad volume $_i^k\mathbb{V}_{i_p}^{k_p}$, the 
     
    376478\[ 
    377479\mathbf{F}=\left( 
    378 _i^k{\mathbb{F}_u}_{i_p}^{k_p} (T)/_i^k{\mathbb{A}_u}_{i_p}^{k_p}, 
    379 {\:}_i^k{\mathbb{F}_w}_{i_p}^{k_p} (T)/_i^k{\mathbb{A}_w}_{i_p}^{k_p} 
     480\left.{}_i^k{\mathbb{F}_u}_{i_p}^{k_p} (T)\right/{}_i^k{\mathbb{A}_u}_{i_p}^{k_p}, 
     481\left.{\:}_i^k{\mathbb{F}_w}_{i_p}^{k_p} (T)\right/{}_i^k{\mathbb{A}_w}_{i_p}^{k_p} 
    380482 \right) 
    381483\] 
    382484and the gradient 
    383485 \[\nabla T = \left( 
    384 \delta_{i+ i_p}[T^k] / {e_{1u}}_{\,i + i_p}^{\,k}, 
    385 \delta_{k+ k_p}[T^i] / {e_{3w}}_{\,i}^{\,k + k_p} 
     486\left.\delta_{i+ i_p}[T^k] \right/ {e_{1u}}_{\,i + i_p}^{\,k}, 
     487\left.\delta_{k+ k_p}[T^i] \right/ {e_{3w}}_{\,i}^{\,k + k_p} 
    386488\right) 
    387489\] 
     
    390492volumes $_i^k\mathbb{V}_{i_p}^{k_p}$. \citet{Griffies_al_JPO98} identify 
    391493these $_i^k\mathbb{V}_{i_p}^{k_p}$ as the volumes of the quarter 
    392 cells, defined in terms of the distances between T, u,f and 
    393 w-points. This is the natural discretization of 
    394 \eqref{eq:cts-var}. The \NEMO model, however, operates with scale 
     494cells, defined in terms of the distances between $T$, $u$,$f$ and 
     495$w$-points. This is the natural discretization of 
     496\eqref{eq:triad:cts-var}. The \NEMO model, however, operates with scale 
    395497factors instead of grid sizes, and scale factors for the quarter 
    396498cells are not defined. Instead, therefore we simply choose 
    397499\begin{equation} 
    398   \label{eq:V-NEMO} 
     500  \label{eq:triad:V-NEMO} 
    399501  _i^k\mathbb{V}_{i_p}^{k_p}=\quarter {b_u}_{i+i_p}^k, 
    400502\end{equation} 
    401 as a quarter of the volume of the u-cell inside which the triad 
     503as a quarter of the volume of the $u$-cell inside which the triad 
    402504quarter-cell lies. This has the nice property that when the slopes 
    403505$\mathbb{R}$ vanish, the lateral flux from tracer cell $i,k$ to 
    404506$i+1,k$ reduces to the classical form 
    405507\begin{equation} 
    406   \label{eq:lat-normal} 
    407 -\overline{A}_{\,i+1/2}^k\; 
     508  \label{eq:triad:lat-normal} 
     509-\overline\Alts_{\,i+1/2}^k\; 
    408510\frac{{b_u}_{i+1/2}^k}{{e_{1u}}_{\,i + i_p}^{\,k}} 
    409511\;\frac{\delta_{i+ 1/2}[T^k] }{{e_{1u}}_{\,i + i_p}^{\,k}} 
    410  = -\overline{A}_{\,i+1/2}^k\;\frac{{e_{1w}}_{\,i + 1/2}^{\,k}\:{e_{1v}}_{\,i + 1/2}^{\,k}}{{e_{1u}}_{\,i + 1/2}^{\,k}}. 
    411 \end{equation} 
    412 In fact if the diffusive coefficient is defined at u-points, so that 
    413 we employ $A_{i+i_p}^k$ instead of $A_i^k$ in the definitions of the 
    414 triad fluxes \eqref{eq:latflux-triad} and \eqref{eq:vertflux-triad}, 
     512 = -\overline\Alts_{\,i+1/2}^k\;\frac{{e_{1w}}_{\,i + 1/2}^{\,k}\:{e_{1v}}_{\,i + 1/2}^{\,k}\;\delta_{i+ 1/2}[T^k]}{{e_{1u}}_{\,i + 1/2}^{\,k}}. 
     513\end{equation} 
     514In fact if the diffusive coefficient is defined at $u$-points, so that 
     515we employ $\Alts_{i+i_p}^k$ instead of  $\Alts_i^k$ in the definitions of the 
     516triad fluxes \eqref{eq:triad:latflux-triad} and \eqref{eq:triad:vertflux-triad}, 
    415517we can replace $\overline{A}_{\,i+1/2}^k$ by $A_{i+1/2}^k$ in the above. 
    416518 
    417519\subsection{Summary of the scheme} 
    418 The divergence of the expression \eqref{Eq_iso_flux} for the fluxes gives the iso-neutral diffusion tendency at 
     520The iso-neutral fluxes at $u$- and 
     521$w$-points are the sums of the triad fluxes that cross the $u$- and 
     522$w$-faces \eqref{Eq_iso_flux}: 
     523\begin{subequations}\label{eq:triad:alltriadflux} 
     524  \begin{flalign}\label{eq:triad:vect_isoflux} 
     525    \vect{F}_\mathrm{iso}(T) &\equiv 
     526    \sum_{\substack{i_p,\,k_p}} 
     527    \begin{pmatrix} 
     528      {_{i+1/2-i_p}^k {\mathbb{F}_u}_{i_p}^{k_p} } (T)      \\ 
     529      \\ 
     530      {_i^{k+1/2-k_p} {\mathbb{F}_w}_{i_p}^{k_p} } (T)  
     531    \end{pmatrix}, 
     532  \end{flalign} 
     533  where \eqref{eq:triad:latflux-triad}: 
     534  \begin{align} 
     535    \label{eq:triad:triadfluxu} 
     536    _i^k {\mathbb{F}_u}_{i_p}^{k_p} (T) &= - \Alts_i^k{ 
     537      \:}\frac{{{}_i^k\mathbb{V}}_{i_p}^{k_p}}{{e_{1u}}_{\,i + i_p}^{\,k}} 
     538    \left( 
     539      \frac{ \delta_{i+ i_p}[T^k] }{ {e_{1u}}_{\,i + i_p}^{\,k} } 
     540      -\ {_i^k\mathbb{R}_{i_p}^{k_p}} \ 
     541      \frac{ \delta_{k+k_p} [T^i] }{{e_{3w}}_{\,i}^{\,k+k_p} } 
     542    \right),\\ 
     543    \intertext{and} 
     544    _i^k {\mathbb{F}_w}_{i_p}^{k_p} (T) 
     545    &= \Alts_i^k{\: }\frac{{{}_i^k\mathbb{V}}_{i_p}^{k_p}}{{e_{3w}}_{\,i}^{\,k+k_p}} 
     546    \left( 
     547      {_i^k\mathbb{R}_{i_p}^{k_p}}\frac{ \delta_{i+ i_p}[T^k] }{ {e_{1u}}_{\,i + i_p}^{\,k} } 
     548      -\ \left({_i^k\mathbb{R}_{i_p}^{k_p}}\right)^2 \ 
     549      \frac{ \delta_{k+k_p} [T^i] }{{e_{3w}}_{\,i}^{\,k+k_p} } 
     550    \right),\label{eq:triad:triadfluxw} 
     551  \end{align} 
     552  with \eqref{eq:triad:V-NEMO} 
     553  \begin{equation} 
     554    \label{eq:triad:V-NEMO2} 
     555    _i^k{\mathbb{V}}_{i_p}^{k_p}=\quarter {b_u}_{i+i_p}^k. 
     556  \end{equation} 
     557\end{subequations} 
     558 
     559 The divergence of the expression \eqref{Eq_iso_flux} for the fluxes gives the iso-neutral diffusion tendency at 
    419560each tracer point: 
    420 \begin{equation} \label{Gf_operator} D_l^T = \frac{1}{b_T} 
     561\begin{equation} \label{eq:triad:iso_operator} D_l^T = \frac{1}{b_T} 
    421562  \sum_{\substack{i_p,\,k_p}} \left\{ \delta_{i} \left[{_{i+1/2-i_p}^k 
    422563        {\mathbb{F}_u }_{i_p}^{k_p}} \right] + \delta_{k} \left[ 
     
    427568\begin{description} 
    428569\item[$\bullet$ horizontal diffusion] The discretization of the 
    429   diffusion operator recovers \eqref{eq:lat-normal} the traditional five-point Laplacian in 
     570  diffusion operator recovers \eqref{eq:triad:lat-normal} the traditional five-point Laplacian in 
    430571  the limit of flat iso-neutral direction : 
    431   \begin{equation} \label{Gf_property1a} D_l^T = \frac{1}{b_T} \ 
     572  \begin{equation} \label{eq:triad:iso_property0} D_l^T = \frac{1}{b_T} \ 
    432573    \delta_{i} \left[ \frac{e_{2u}\,e_{3u}}{e_{1u}} \; 
    433       \overline{A}^{\,i} \; \delta_{i+1/2}[T] \right] \qquad 
     574      \overline\Alts^{\,i} \; \delta_{i+1/2}[T] \right] \qquad 
    434575    \text{when} \quad { _i^k \mathbb{R}_{i_p}^{k_p} }=0 
    435576  \end{equation} 
     
    437578\item[$\bullet$ implicit treatment in the vertical] Only tracer values 
    438579  associated with a single water column appear in the expression 
    439   \eqref{eq:i33} for the $_{33}$ fluxes, vertical fluxes driven by 
     580  \eqref{eq:triad:i33} for the $_{33}$ fluxes, vertical fluxes driven by 
    440581  vertical gradients. This is of paramount importance since it means 
    441   that an implicit in time algorithm can be used to solve the vertical 
    442   diffusion equation. This is a necessity since the vertical eddy 
     582  that a time-implicit algorithm can be used to solve the vertical 
     583  diffusion equation. This is necessary 
     584 since the vertical eddy 
    443585  diffusivity associated with this term, 
    444586  \begin{equation} 
    445     \frac{1}{b_w}\sum_{\substack{i_p, \,k_p}} \left\{   
    446       {\:}_i^k\mathbb{V}_{i_p}^{k_p} \:A_i^k \: \left(_i^k \mathbb{R}_{i_p}^{k_p}\right)^2 
    447     \right\}  =  
    448     \frac{1}{4b_w}\sum_{\substack{i_p, \,k_p}} \left\{   
    449       {b_u}_{i+i_p}^k\:A_i^k \: \left(_i^k \mathbb{R}_{i_p}^{k_p}\right)^2 
     587    \frac{1}{b_w}\sum_{\substack{i_p, \,k_p}} \left\{ 
     588      {\:}_i^k\mathbb{V}_{i_p}^{k_p} \: \Alts_i^k \: \left(_i^k \mathbb{R}_{i_p}^{k_p}\right)^2 
     589    \right\}  = 
     590    \frac{1}{4b_w}\sum_{\substack{i_p, \,k_p}} \left\{ 
     591      {b_u}_{i+i_p}^k\: \Alts_i^k \: \left(_i^k \mathbb{R}_{i_p}^{k_p}\right)^2 
    450592    \right\}, 
    451593 \end{equation} 
     
    454596\item[$\bullet$ pure iso-neutral operator] The iso-neutral flux of 
    455597  locally referenced potential density is zero. See 
    456   \eqref{eq:latflux-rho} and \eqref{eq:vertflux-triad2}. 
     598  \eqref{eq:triad:latflux-rho} and \eqref{eq:triad:vertflux-triad2}. 
    457599 
    458600\item[$\bullet$ conservation of tracer] The iso-neutral diffusion 
    459601  conserves tracer content, $i.e.$ 
    460   \begin{equation} \label{Gf_property1} \sum_{i,j,k} \left\{ D_l^T \ 
     602  \begin{equation} \label{eq:triad:iso_property1} \sum_{i,j,k} \left\{ D_l^T \ 
    461603      b_T \right\} = 0 
    462604  \end{equation} 
     
    466608\item[$\bullet$ no increase of tracer variance] The iso-neutral diffusion 
    467609  does not increase the tracer variance, $i.e.$ 
    468   \begin{equation} \label{Gf_property1} \sum_{i,j,k} \left\{ T \ D_l^T 
     610  \begin{equation} \label{eq:triad:iso_property2} \sum_{i,j,k} \left\{ T \ D_l^T 
    469611      \ b_T \right\} \leq 0 
    470612  \end{equation} 
    471613  The property is demonstrated in 
    472   \ref{sec:variance} above. It is a key property for a diffusion 
    473   term. It means that it is also a dissipation term, $i.e.$ it is a 
    474   diffusion of the square of the quantity on which it is applied.  It 
     614  \S\ref{sec:triad:variance} above. It is a key property for a diffusion 
     615  term. It means that it is also a dissipation term, $i.e.$ it 
     616  dissipates the square of the quantity on which it is applied.  It 
    475617  therefore ensures that, when the diffusivity coefficient is large 
    476   enough, the field on which it is applied become free of grid-point 
     618  enough, the field on which it is applied becomes free of grid-point 
    477619  noise. 
    478620 
    479621\item[$\bullet$ self-adjoint operator] The iso-neutral diffusion 
    480622  operator is self-adjoint, $i.e.$ 
    481   \begin{equation} \label{Gf_property1} \sum_{i,j,k} \left\{ S \ D_l^T 
     623  \begin{equation} \label{eq:triad:iso_property3} \sum_{i,j,k} \left\{ S \ D_l^T 
    482624      \ b_T \right\} = \sum_{i,j,k} \left\{ D_l^S \ T \ b_T \right\} 
    483625  \end{equation} 
     
    486628  routine. This property can be demonstrated similarly to the proof of 
    487629  the `no increase of tracer variance' property. The contribution by a 
    488   single triad towards the left hand side of \eqref{Gf_property1}, can 
    489   be found by replacing $\delta[T]$ by $\delta[S]$ in \eqref{locFdtdx} 
    490   and \eqref{locFdtdx}. This results in a term similar to 
    491   \eqref{eq:perfect-square}, 
    492 \begin{equation} 
    493   \label{eq:TScovar} 
    494   -A_i^k{\:} _i^k\mathbb{V}_{i_p}^{k_p} 
     630  single triad towards the left hand side of \eqref{eq:triad:iso_property3}, can 
     631  be found by replacing $\delta[T]$ by $\delta[S]$ in \eqref{eq:triad:dvar_iso_i} 
     632  and \eqref{eq:triad:dvar_iso_k}. This results in a term similar to 
     633  \eqref{eq:triad:perfect-square}, 
     634\begin{equation} 
     635  \label{eq:triad:TScovar} 
     636  - \Alts_i^k{\:} _i^k\mathbb{V}_{i_p}^{k_p} 
    495637  \left( 
    496638    \frac{ \delta_{i+ i_p}[T^k] }{ {e_{1u}}_{\,i + i_p}^{\,k} } 
     
    506648This is symmetrical in $T $ and $S$, so exactly the same term arises 
    507649from the discretization of this triad's contribution towards the 
    508 RHS of \eqref{Gf_property1}. 
     650RHS of \eqref{eq:triad:iso_property3}. 
    509651\end{description} 
    510  
    511  
    512 $\ $\newline %force an empty line 
     652\subsection{Treatment of the triads at the boundaries}\label{sec:triad:iso_bdry} 
     653The triad slope can only be defined where both the grid boxes centred at 
     654the end of the arms exist. Triads that would poke up 
     655through the upper ocean surface into the atmosphere, or down into the 
     656ocean floor, must be masked out. See Fig.~\ref{fig:triad:bdry_triads}. Surface layer triads 
     657$\triad{i}{1}{R}{1/2}{-1/2}$ (magenta) and 
     658$\triad{i+1}{1}{R}{-1/2}{-1/2}$ (blue) that require density to be 
     659specified above the ocean surface are masked (Fig.~\ref{fig:triad:bdry_triads}a): this ensures that lateral 
     660tracer gradients produce no flux through the ocean surface. However, 
     661to prevent surface noise, it is customary to retain the $_{11}$ contributions towards 
     662the lateral triad fluxes $\triad[u]{i}{1}{F}{1/2}{-1/2}$ and 
     663$\triad[u]{i+1}{1}{F}{-1/2}{-1/2}$; this drives diapycnal tracer 
     664fluxes. Similar comments apply to triads that would intersect the 
     665ocean floor (Fig.~\ref{fig:triad:bdry_triads}b). Note that both near bottom 
     666triad slopes $\triad{i}{k}{R}{1/2}{1/2}$ and 
     667$\triad{i+1}{k}{R}{-1/2}{1/2}$ are masked when either of the $i,k+1$ 
     668or $i+1,k+1$ tracer points is masked, i.e.\ the $i,k+1$ $u$-point is 
     669masked. The associated lateral fluxes (grey-black dashed line) are 
     670masked if \np{ln\_botmix\_grif}=false, but left unmasked, 
     671giving bottom mixing, if \np{ln\_botmix\_grif}=true. 
     672 
     673The default option \np{ln\_botmix\_grif}=false is suitable when the 
     674bbl mixing option is enabled (\key{trabbl}, with \np{nn\_bbl\_ldf}=1), 
     675or  for simple idealized  problems. For setups with topography without 
     676bbl mixing, \np{ln\_botmix\_grif}=true may be necessary. 
     677% >>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     678\begin{figure}[h] \begin{center} 
     679    \includegraphics[width=0.60\textwidth]{./TexFiles/Figures/Fig_bdry_triads} 
     680    \caption{  \label{fig:triad:bdry_triads} 
     681      (a) Uppermost model layer $k=1$ with $i,1$ and $i+1,1$ tracer 
     682      points (black dots), and $i+1/2,1$ $u$-point (blue square). Triad 
     683      slopes $\triad{i}{1}{R}{1/2}{-1/2}$ (magenta) and $\triad{i+1}{1}{R}{-1/2}{-1/2}$ 
     684      (blue) poking through the ocean surface are masked (faded in 
     685      figure). However, the lateral $_{11}$ contributions towards 
     686      $\triad[u]{i}{1}{F}{1/2}{-1/2}$ and $\triad[u]{i+1}{1}{F}{-1/2}{-1/2}$ 
     687      (yellow line) are still applied, giving diapycnal diffusive 
     688      fluxes.\\ 
     689      (b) Both near bottom triad slopes $\triad{i}{k}{R}{1/2}{1/2}$ and 
     690      $\triad{i+1}{k}{R}{-1/2}{1/2}$ are masked when either of the $i,k+1$ 
     691      or $i+1,k+1$ tracer points is masked, i.e.\ the $i,k+1$ $u$-point 
     692      is masked. The associated lateral fluxes (grey-black dashed 
     693      line) are masked if \np{botmix\_grif}=.false., but left 
     694      unmasked, giving bottom mixing, if \np{botmix\_grif}=.true.} 
     695 \end{center} \end{figure} 
     696% >>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     697\subsection{ Limiting of the slopes within the interior}\label{sec:triad:limit} 
     698As discussed in \S\ref{LDF_slp_iso}, iso-neutral slopes relative to 
     699geopotentials must be bounded everywhere, both for consistency with the small-slope 
     700approximation and for numerical stability \citep{Cox1987, 
     701  Griffies_Bk04}. The bound chosen in \NEMO is applied to each 
     702component of the slope separately and has a value of $1/100$ in the ocean interior. 
     703%, ramping linearly down above 70~m depth to zero at the surface 
     704It is of course relevant to the iso-neutral slopes $\tilde{r}_i=r_i+\sigma_i$ relative to 
     705geopotentials (here the $\sigma_i$ are the slopes of the coordinate surfaces relative to 
     706geopotentials) \eqref{Eq_PE_slopes_eiv} rather than the slope $r_i$ relative to coordinate 
     707surfaces, so we require 
     708\begin{equation*} 
     709  |\tilde{r}_i|\leq \tilde{r}_\mathrm{max}=0.01. 
     710\end{equation*} 
     711and then recalculate the slopes $r_i$ relative to coordinates. 
     712Each individual triad slope 
     713 \begin{equation} 
     714   \label{eq:triad:Rtilde} 
     715_i^k\tilde{\mathbb{R}}_{i_p}^{k_p} = {}_i^k\mathbb{R}_{i_p}^{k_p}  + \frac{\delta_{i+i_p}[z_T^k]}{{e_{1u}}_{\,i + i_p}^{\,k}} 
     716 \end{equation} 
     717is limited like this and then the corresponding 
     718$_i^k\mathbb{R}_{i_p}^{k_p} $ are recalculated and combined to form the fluxes. 
     719Note that where the slopes have been limited, there is now a non-zero 
     720iso-neutral density flux that drives dianeutral mixing.  In particular this iso-neutral density flux 
     721is always downwards, and so acts to reduce gravitational potential energy. 
     722\subsection{Tapering within the surface mixed layer}\label{sec:triad:taper} 
     723 
     724Additional tapering of the iso-neutral fluxes is necessary within the 
     725surface mixed layer. When the Griffies triads are used, we offer two 
     726options for this. 
     727\subsubsection{Linear slope tapering within the surface mixed layer}\label{sec:triad:lintaper} 
     728This is the option activated by the default choice 
     729\np{ln\_triad\_iso}=false. Slopes $\tilde{r}_i$ relative to 
     730geopotentials are tapered linearly from their value immediately below the mixed layer to zero at the 
     731surface, as described in option (c) of Fig.~\ref{Fig_eiv_slp}, to values 
     732\begin{subequations} 
     733  \begin{equation} 
     734   \label{eq:triad:rmtilde} 
     735     \rMLt = 
     736  -\frac{z}{h}\left.\tilde{r}_i\right|_{z=-h}\quad \text{ for  } z>-h, 
     737  \end{equation} 
     738and then the $r_i$ relative to vertical coordinate surfaces are appropriately 
     739adjusted to 
     740  \begin{equation} 
     741   \label{eq:triad:rm} 
     742 \rML =\rMLt -\sigma_i \quad \text{ for  } z>-h. 
     743  \end{equation} 
     744\end{subequations} 
     745Thus the diffusion operator within the mixed layer is given by: 
     746\begin{equation} \label{eq:triad:iso_tensor_ML} 
     747D^{lT}=\nabla {\rm {\bf .}}\left( {A^{lT}\;\Re \;\nabla T} \right) \qquad 
     748\mbox{with}\quad \;\;\Re =\left( {{\begin{array}{*{20}c} 
     749 1 \hfill & 0 \hfill & {-\rML[1]}\hfill \\ 
     750 0 \hfill & 1 \hfill & {-\rML[2]} \hfill \\ 
     751 {-\rML[1]}\hfill &   {-\rML[2]} \hfill & {\rML[1]^2+\rML[2]^2} \hfill 
     752\end{array} }} \right) 
     753\end{equation} 
     754 
     755This slope tapering gives a natural connection between tracer in the 
     756mixed-layer and in isopycnal layers immediately below, in the 
     757thermocline. It is consistent with the way the $\tilde{r}_i$ are 
     758tapered within the mixed layer (see \S\ref{sec:triad:taperskew} below) 
     759so as to ensure a uniform GM eddy-induced velocity throughout the 
     760mixed layer. However, it gives a downwards density flux and so acts so 
     761as to reduce potential energy in the same way as does the slope 
     762limiting discussed above in \S\ref{sec:triad:limit}. 
     763  
     764As in \S\ref{sec:triad:limit} above, the tapering 
     765\eqref{eq:triad:rmtilde} is applied separately to each triad 
     766$_i^k\tilde{\mathbb{R}}_{i_p}^{k_p}$, and the 
     767$_i^k\mathbb{R}_{i_p}^{k_p}$ adjusted. For clarity, we assume 
     768$z$-coordinates in the following; the conversion from 
     769$\mathbb{R}$ to $\tilde{\mathbb{R}}$ and back to $\mathbb{R}$ follows exactly as described 
     770above by \eqref{eq:triad:Rtilde}. 
     771\begin{enumerate} 
     772\item Mixed-layer depth is defined so as to avoid including regions of weak 
     773vertical stratification in the slope definition. 
     774 At each $i,j$ (simplified to $i$ in 
     775Fig.~\ref{fig:triad:MLB_triad}), we define the mixed-layer by setting 
     776the vertical index of the tracer point immediately below the mixed 
     777layer, $k_\mathrm{ML}$, as the maximum $k$ (shallowest tracer point) 
     778such that the potential density 
     779${\rho_0}_{i,k}>{\rho_0}_{i,k_{10}}+\Delta\rho_c$, where $i,k_{10}$ is 
     780the tracer gridbox within which the depth reaches 10~m. See the left 
     781side of Fig.~\ref{fig:triad:MLB_triad}. We use the $k_{10}$-gridbox 
     782instead of the surface gridbox to avoid problems e.g.\ with thin 
     783daytime mixed-layers. Currently we use the same 
     784$\Delta\rho_c=0.01\;\mathrm{kg\:m^{-3}}$ for ML triad tapering as is 
     785used to output the diagnosed mixed-layer depth 
     786$h_\mathrm{ML}=|z_{W}|_{k_\mathrm{ML}+1/2}$, the depth of the $w$-point 
     787above the $i,k_\mathrm{ML}$ tracer point. 
     788 
     789\item We define `basal' triad slopes 
     790${\:}_i{\mathbb{R}_\mathrm{base}}_{\,i_p}^{k_p}$ as the slopes 
     791of those triads whose vertical `arms' go down from the 
     792$i,k_\mathrm{ML}$ tracer point to the $i,k_\mathrm{ML}-1$ tracer point 
     793below. This is to ensure that the vertical density gradients 
     794associated with these basal triad slopes 
     795${\:}_i{\mathbb{R}_\mathrm{base}}_{\,i_p}^{k_p}$ are 
     796representative of the thermocline. The four basal triads defined in the bottom part 
     797of Fig.~\ref{fig:triad:MLB_triad} are then 
     798\begin{align} 
     799  {\:}_i{\mathbb{R}_\mathrm{base}}_{\,i_p}^{k_p} &= 
     800 {\:}^{k_\mathrm{ML}-k_p-1/2}_i{\mathbb{R}_\mathrm{base}}_{\,i_p}^{k_p}, \label{eq:triad:Rbase} 
     801\\ 
     802\intertext{with e.g.\ the green triad} 
     803{\:}_i{\mathbb{R}_\mathrm{base}}_{1/2}^{-1/2}&= 
     804{\:}^{k_\mathrm{ML}}_i{\mathbb{R}_\mathrm{base}}_{\,1/2}^{-1/2}. \notag 
     805\end{align} 
     806The vertical flux associated with each of these triads passes through the $w$-point 
     807$i,k_\mathrm{ML}-1/2$ lying \emph{below} the $i,k_\mathrm{ML}$ tracer point, 
     808so it is this depth 
     809\begin{equation} 
     810  \label{eq:triad:zbase} 
     811  {z_\mathrm{base}}_{\,i}={z_{w}}_{k_\mathrm{ML}-1/2} 
     812\end{equation} 
     813(one gridbox deeper than the 
     814diagnosed ML depth $z_\mathrm{ML})$ that sets the $h$ used to taper 
     815the slopes in \eqref{eq:triad:rmtilde}. 
     816\item Finally, we calculate the adjusted triads 
     817${\:}_i^k{\mathbb{R}_\mathrm{ML}}_{\,i_p}^{k_p}$ within the mixed 
     818layer, by multiplying the appropriate 
     819${\:}_i{\mathbb{R}_\mathrm{base}}_{\,i_p}^{k_p}$ by the ratio of 
     820the depth of the $w$-point ${z_w}_{k+k_p}$ to ${z_\mathrm{base}}_{\,i}$. For 
     821instance the green triad centred on $i,k$ 
     822\begin{align} 
     823  {\:}_i^k{\mathbb{R}_\mathrm{ML}}_{\,1/2}^{-1/2} &= 
     824\frac{{z_w}_{k-1/2}}{{z_\mathrm{base}}_{\,i}}{\:}_i{\mathbb{R}_\mathrm{base}}_{\,1/2}^{-1/2} 
     825\notag \\ 
     826\intertext{and more generally} 
     827 {\:}_i^k{\mathbb{R}_\mathrm{ML}}_{\,i_p}^{k_p} &= 
     828\frac{{z_w}_{k+k_p}}{{z_\mathrm{base}}_{\,i}}{\:}_i{\mathbb{R}_\mathrm{base}}_{\,i_p}^{k_p}.\label{eq:triad:RML} 
     829\end{align} 
     830\end{enumerate} 
     831 
     832% >>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     833\begin{figure}[h] 
     834  \fcapside {\caption{\label{fig:triad:MLB_triad} Definition of 
     835      mixed-layer depth and calculation of linearly tapered 
     836      triads. The figure shows a water column at a given $i,j$ 
     837      (simplified to $i$), with the ocean surface at the top. Tracer points are denoted by 
     838      bullets, and black lines the edges of the tracer cells; $k$ 
     839      increases upwards. \\ 
     840      \hspace{5 em}We define the mixed-layer by setting the vertical index 
     841      of the tracer point immediately below the mixed layer, 
     842      $k_\mathrm{ML}$, as the maximum $k$ (shallowest tracer point) 
     843      such that ${\rho_0}_{i,k}>{\rho_0}_{i,k_{10}}+\Delta\rho_c$, 
     844      where $i,k_{10}$ is the tracer gridbox within which the depth 
     845      reaches 10~m. We calculate the triad slopes within the mixed 
     846      layer by linearly tapering them from zero (at the surface) to 
     847      the `basal' slopes, the slopes of the four triads passing through the 
     848      $w$-point $i,k_\mathrm{ML}-1/2$ (blue square), 
     849      ${\:}_i{\mathbb{R}_\mathrm{base}}_{\,i_p}^{k_p}$. Triads with 
     850    different $i_p,k_p$, denoted by different colours, (e.g. the green 
     851    triad $i_p=1/2,k_p=-1/2$) are tapered to the appropriate basal triad.}} 
     852  {\includegraphics[width=0.60\textwidth]{./TexFiles/Figures/Fig_triad_MLB}} 
     853\end{figure} 
     854% >>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     855 
     856\subsubsection{Additional truncation of skew iso-neutral flux 
     857  components} 
     858\label{sec:triad:Gerdes-taper} 
     859The alternative option is activated by setting \np{ln\_triad\_iso} = 
     860  true. This retains the same tapered slope $\rML$  described above for the 
     861calculation of the $_{33}$ term of the iso-neutral diffusion tensor (the 
     862vertical tracer flux driven by vertical tracer gradients), but 
     863replaces the $\rML$ in the skew term by 
     864\begin{equation} 
     865  \label{eq:triad:rm*} 
     866  \rML^*=\left.\rMLt^2\right/\tilde{r}_i-\sigma_i, 
     867\end{equation} 
     868giving a ML diffusive operator 
     869\begin{equation} \label{eq:triad:iso_tensor_ML2} 
     870D^{lT}=\nabla {\rm {\bf .}}\left( {A^{lT}\;\Re \;\nabla T} \right) \qquad 
     871\mbox{with}\quad \;\;\Re =\left( {{\begin{array}{*{20}c} 
     872 1 \hfill & 0 \hfill & {-\rML[1]^*}\hfill \\ 
     873 0 \hfill & 1 \hfill & {-\rML[2]^*} \hfill \\ 
     874 {-\rML[1]^*}\hfill &   {-\rML[2]^*} \hfill & {\rML[1]^2+\rML[2]^2} \hfill \\ 
     875\end{array} }} \right). 
     876\end{equation} 
     877This operator 
     878\footnote{To ensure good behaviour where horizontal density 
     879  gradients are weak, we in fact follow \citet{Gerdes1991} and set 
     880$\rML^*=\mathrm{sgn}(\tilde{r}_i)\min(|\rMLt^2/\tilde{r}_i|,|\tilde{r}_i|)-\sigma_i$.} 
     881then has the property it gives no vertical density flux, and so does 
     882not change the potential energy. 
     883This approach is similar to multiplying the iso-neutral  diffusion 
     884coefficient by $\tilde{r}_\mathrm{max}^{-2}\tilde{r}_i^{-2}$ for steep 
     885slopes, as suggested by \citet{Gerdes1991} (see also \citet{Griffies_Bk04}). 
     886Again it is applied separately to each triad $_i^k\mathbb{R}_{i_p}^{k_p}$ 
     887 
     888In practice, this approach gives weak vertical tracer fluxes through 
     889the mixed-layer, as well as vanishing density fluxes. While it is 
     890theoretically advantageous that it does not change the potential 
     891energy, it may give a discontinuity between the 
     892fluxes within the mixed-layer (purely horizontal) and just below (along 
     893iso-neutral surfaces). 
     894% This may give strange looking results, 
     895% particularly where the mixed-layer depth varies strongly laterally. 
    513896% ================================================================ 
    514897% Skew flux formulation for Eddy Induced Velocity : 
    515898% ================================================================ 
    516 \section{ Eddy induced velocity and Skew flux formulation} 
    517  
    518 When Gent and McWilliams's [1990] diffusion is used (\key{traldf\_eiv} defined),  
    519 an additional advection term is added. The associated velocity is the so called  
     899\section{Eddy induced advection formulated as a skew flux}\label{sec:triad:skew-flux} 
     900 
     901\subsection{The continuous skew flux formulation}\label{sec:triad:continuous-skew-flux} 
     902 
     903 When Gent and McWilliams's [1990] diffusion is used, 
     904an additional advection term is added. The associated velocity is the so called 
    520905eddy induced velocity, the formulation of which depends on the slopes of iso- 
    521 neutral surfaces. Contrary to the case of iso-neutral mixing, the slopes used  
    522 here are referenced to the geopotential surfaces, $i.e.$ \eqref{Eq_ldfslp_geo}  
     906neutral surfaces. Contrary to the case of iso-neutral mixing, the slopes used 
     907here are referenced to the geopotential surfaces, $i.e.$ \eqref{Eq_ldfslp_geo} 
    523908is used in $z$-coordinate, and the sum \eqref{Eq_ldfslp_geo} 
    524 + \eqref{Eq_ldfslp_iso} in $z^*$ or $s$-coordinates.  
    525  
    526 The eddy induced velocity is given by:  
    527 \begin{equation} \label{Eq_eiv_v} 
     909+ \eqref{Eq_ldfslp_iso} in $z^*$ or $s$-coordinates. 
     910 
     911The eddy induced velocity is given by: 
     912\begin{subequations} \label{eq:triad:eiv} 
     913\begin{equation}\label{eq:triad:eiv_v} 
    528914\begin{split} 
    529  u^* & = - \frac{1}{e_{2}e_{3}}\;          \partial_k \left( e_{2} \, A_{e} \; r_i \right)   \\ 
    530  v^* & = - \frac{1}{e_{1}e_{3}}\;          \partial_k \left( e_{1} \, A_{e} \; r_j \right)   \\ 
    531 w^* & =    \frac{1}{e_{1}e_{2}}\; \left\{ \partial_i  \left( e_{2} \, A_{e} \; r_i \right)  
    532                          + \partial_j  \left( e_{1} \, A_{e} \;r_j \right) \right\} \\ 
     915 u^* & = - \frac{1}{e_{3}}\;          \partial_i\psi_1,  \\ 
     916 v^* & = - \frac{1}{e_{3}}\;          \partial_j\psi_2,    \\ 
     917w^* & =    \frac{1}{e_{1}e_{2}}\; \left\{ \partial_i  \left( e_{2} \, \psi_1\right) 
     918                         + \partial_j  \left( e_{1} \, \psi_2\right) \right\}, 
    533919\end{split} 
    534920\end{equation} 
    535 where $A_{e}$ is the eddy induced velocity coefficient, and $r_i$ and $r_j$ the slopes between the iso-neutral and the geopotential surfaces.  
    536  
    537 The traditional way to implement this additional advection is to add it to the Eulerian  
    538 velocity prior to computing the tracer advection. This allows us to take advantage of  
    539 all the advection schemes offered for the tracers (see \S\ref{TRA_adv}) and not just  
    540 a $2^{nd}$ order advection scheme. This is particularly useful for passive tracers  
    541 where \emph{positivity} of the advection scheme is of paramount importance.  
    542  
    543 \citet{Griffies_JPO98} introduces another way to implement the eddy induced advection,  
    544 the so-called skew form. It is based on a transformation of the advective fluxes  
    545 using the non-divergent nature of the eddy induced velocity.  
    546 For example in the (\textbf{i},\textbf{k}) plane, the tracer advective fluxes can be  
     921where the streamfunctions $\psi_i$ are given by 
     922\begin{equation} \label{eq:triad:eiv_psi} 
     923\begin{split} 
     924\psi_1 & = A_{e} \; \tilde{r}_1,   \\ 
     925\psi_2 & = A_{e} \; \tilde{r}_2, 
     926\end{split} 
     927\end{equation} 
     928\end{subequations} 
     929with $A_{e}$ the eddy induced velocity coefficient, and $\tilde{r}_1$ and $\tilde{r}_2$ the slopes between the iso-neutral and the geopotential surfaces. 
     930 
     931The traditional way to implement this additional advection is to add 
     932it to the Eulerian velocity prior to computing the tracer 
     933advection. This is implemented if \key{traldf\_eiv} is set in the 
     934default implementation, where \np{ln\_traldf\_grif} is set 
     935false. This allows us to take advantage of all the advection schemes 
     936offered for the tracers (see \S\ref{TRA_adv}) and not just a $2^{nd}$ 
     937order advection scheme. This is particularly useful for passive 
     938tracers where \emph{positivity} of the advection scheme is of 
     939paramount importance. 
     940 
     941However, when \np{ln\_traldf\_grif} is set true, \NEMO instead 
     942implements eddy induced advection according to the so-called skew form 
     943\citep{Griffies_JPO98}. It is based on a transformation of the advective fluxes 
     944using the non-divergent nature of the eddy induced velocity. 
     945For example in the (\textbf{i},\textbf{k}) plane, the tracer advective 
     946fluxes per unit area in $ijk$ space can be 
    547947transformed as follows: 
    548948\begin{flalign*} 
    549949\begin{split} 
    550 \textbf{F}_{eiv}^T =  
    551 \begin{pmatrix}  
     950\textbf{F}_\mathrm{eiv}^T = 
     951\begin{pmatrix} 
    552952           {e_{2}\,e_{3}\;  u^*}       \\ 
    553953      {e_{1}\,e_{2}\; w^*}  \\ 
    554954\end{pmatrix}   \;   T 
    555955&= 
    556 \begin{pmatrix}  
    557            { - \partial_k \left( e_{2} \, A_{e} \; r_i \right) \; T \;}       \\ 
    558       {+ \partial_i  \left( e_{2} \, A_{e} \; r_i \right) \; T \;}    \\ 
     956\begin{pmatrix} 
     957           { - \partial_k \left( e_{2} \,\psi_1 \right) \; T \;}     \\ 
     958      {+ \partial_i  \left( e_{2} \, \psi_1 \right) \; T \;}    \\ 
    559959\end{pmatrix}        \\ 
    560 &=        
    561 \begin{pmatrix}  
    562            { - \partial_k \left( e_{2} \, A_{e} \; r_i  \; T \right) \;}  \\ 
    563       {+ \partial_i  \left( e_{2} \, A_{e} \; r_i \; T \right) \;}   \\ 
    564 \end{pmatrix}         
    565  +  
    566 \begin{pmatrix}  
    567            {+ e_{2} \, A_{e} \; r_i  \; \partial_k T}  \\ 
    568       { - e_{2} \, A_{e} \; r_i  \; \partial_i  T}  \\ 
    569 \end{pmatrix}    
     960&= 
     961\begin{pmatrix} 
     962           { - \partial_k \left( e_{2} \, \psi_1  \; T \right) \;}  \\ 
     963      {+ \partial_i  \left( e_{2} \,\psi_1 \; T \right) \;}  \\ 
     964\end{pmatrix} 
     965 + 
     966\begin{pmatrix} 
     967           {+ e_{2} \, \psi_1  \; \partial_k T}  \\ 
     968      { - e_{2} \, \psi_1  \; \partial_i  T}  \\ 
     969\end{pmatrix} 
    570970\end{split} 
    571971\end{flalign*} 
    572 and since the eddy induces velocity field is no-divergent, we end up with the skew  
    573 form of the eddy induced advective fluxes: 
    574 \begin{equation} \label{Eq_eiv_skew_continuous} 
    575 \textbf{F}_{eiv}^T = \begin{pmatrix}  
    576            {+ e_{2} \, A_{e} \; r_i  \; \partial_k T}   \\ 
    577       { - e_{2} \, A_{e} \; r_i  \; \partial_i  T}  \\ 
     972and since the eddy induced velocity field is non-divergent, we end up with the skew 
     973form of the eddy induced advective fluxes per unit area in $ijk$ space: 
     974\begin{equation} \label{eq:triad:eiv_skew_ijk} 
     975\textbf{F}_\mathrm{eiv}^T = \begin{pmatrix} 
     976           {+ e_{2} \, \psi_1  \; \partial_k T}   \\ 
     977      { - e_{2} \, \psi_1  \; \partial_i  T}  \\ 
    578978                                 \end{pmatrix} 
    579979\end{equation} 
    580 The tendency associated with eddy induced velocity is then simply the divergence  
    581 of the \eqref{Eq_eiv_skew_continuous} fluxes. It naturally conserves the tracer  
    582 content, as it is expressed in flux form. It also preserve the tracer variance. 
    583  
    584 The discrete form of  \eqref{Eq_eiv_skew_continuous} using the slopes \eqref{Gf_slopes} and defining $A_e$ at $T$-point is then given by: 
    585 \begin{flalign} \label{Eq_eiv_skew}   \begin{split} 
    586 \textbf{F}_{eiv}^T   \equiv                                    
    587                         \sum_{\substack{i_p,\,k_p}} \begin{pmatrix}  
    588 +{e_{2u}}_{i+1/2-i_p}^{k}                                    \ {A_{e}}_{i+1/2-i_p}^{k}  
    589 \ \ { _{i+1/2-i_p}^k \mathbb{R}_{i_p}^{k_p} }    \ \ \delta_{k+k_p}[T_{i+1/2-i_p}]      \\ 
    590     \\ 
    591 - {e_{2u}}_i^{k+1/2-k_p}                                      \ {A_{e}}_i^{k+1/2-k_p}  
    592 \ \ { _i^{k+1/2-k_p} \mathbb{R}_{i_p}^{k_p} }    \ \delta_{i+i_p}[T^{k+1/2-k_p}]    \\    
    593                                                                        \end{pmatrix}    
    594 \end{split}   \end{flalign} 
    595 Note that \eqref{Eq_eiv_skew} is valid in $z$-coordinate with or without partial cells. In $z^*$ or $s$-coordinate, the the slope between the level and the geopotential surfaces must be added to $\mathbb{R}$ for the discret form to be exact.  
    596  
    597 Such a choice of discretisation is consistent with the iso-neutral operator as it uses the same definition for the slopes. It also ensures the conservation of the tracer variance (see Appendix \ref{Apdx_eiv_skew}), $i.e.$ it does not include a diffusive component but is a `pure' advection term. 
    598  
    599  
    600  
    601  
    602 \newpage      %force an empty line 
    603 % ================================================================ 
    604 % Discrete Invariants of the skew flux formulation 
    605 % ================================================================ 
    606 \subsection{Discrete Invariants of the skew flux formulation} 
    607 \label{Apdx_eiv_skew} 
    608  
    609  
    610 Demonstration for the conservation of the tracer variance in the (\textbf{i},\textbf{j}) plane.  
    611  
    612 This have to be moved in an Appendix. 
    613  
    614 The continuous property to be demonstrated is : 
    615 \begin{align*} 
    616 \int_D \nabla \cdot \textbf{F}_{eiv}(T) \; T \;dv  \equiv 0 
    617 \end{align*} 
    618 The discrete form of its left hand side is obtained using \eqref{Eq_eiv_skew} 
    619 \begin{align*} 
    620  \sum\limits_{i,k} \sum_{\substack{i_p,\,k_p}}  \Biggl\{   \;\; 
    621  \delta_i  &\left[                                                     
    622 {e_{2u}}_{i+i_p+1/2}^{k}                                  \;\ \ {A_{e}}_{i+i_p+1/2}^{k}  
    623 \ \ \ { _{i+i_p+1/2}^k \mathbb{R}_{-i_p}^{k_p} }   \quad \delta_{k+k_p}[T_{i+i_p+1/2}]          
    624    \right] \; T_i^k      \\ 
    625 - \delta_k &\left[  
    626 {e_{2u}}_i^{k+k_p+1/2}                                     \ \ {A_{e}}_i^{k+k_p+1/2}  
    627 \ \ { _i^{k+k_p+1/2} \mathbb{R}_{i_p}^{-k_p} }   \ \ \delta_{i+i_p}[T^{k+k_p+1/2}]    
    628    \right] \; T_i^k      \         \Biggr\}    
    629 \end{align*} 
    630 apply the adjoint of delta operator, it becomes 
    631 \begin{align*} 
    632  \sum\limits_{i,k} \sum_{\substack{i_p,\,k_p}}  \Biggl\{   \;\; 
    633   &\left(                                                     
    634 {e_{2u}}_{i+i_p+1/2}^{k}                                  \;\ \ {A_{e}}_{i+i_p+1/2}^{k}  
    635 \ \ \ { _{i+i_p+1/2}^k \mathbb{R}_{-i_p}^{k_p} }   \quad \delta_{k+k_p}[T_{i+i_p+1/2}]          
    636    \right) \; \delta_{i+1/2}[T^{k}]      \\ 
    637 - &\left(  
    638 {e_{2u}}_i^{k+k_p+1/2}                                     \ \ {A_{e}}_i^{k+k_p+1/2}  
    639 \ \ { _i^{k+k_p+1/2} \mathbb{R}_{i_p}^{-k_p} }   \ \ \delta_{i+i_p}[T^{k+k_p+1/2}]    
    640      \right) \; \delta_{k+1/2}[T_{i}]       \         \Biggr\}        
    641 \end{align*} 
    642 Expending the summation on $i_p$ and $k_p$, it becomes: 
    643 \begin{align*} 
    644  \begin{matrix}   
    645 &\sum\limits_{i,k}   \Bigl\{  
    646   &+{e_{2u}}_{i+1}^{k}                             &{A_{e}}_{i+1    }^{k}  
    647   &\ {_{i+1}^k \mathbb{R}_{- 1/2}^{-1/2}} &\delta_{k-1/2}[T_{i+1}]    &\delta_{i+1/2}[T^{k}]   &\\ 
    648 &&+{e_{2u}}_i^{k\ \ \ \:}                            &{A_{e}}_{i}^{k\ \ \ \:}       
    649   &\ {\ \ \;_i^k \mathbb{R}_{+1/2}^{-1/2}}  &\delta_{k-1/2}[T_{i\ \ \ \;}]  &\delta_{i+1/2}[T^{k}] &\\ 
    650 &&+{e_{2u}}_{i+1}^{k}                             &{A_{e}}_{i+1    }^{k}  
    651   &\ {_{i+1}^k \mathbb{R}_{- 1/2}^{+1/2}} &\delta_{k+1/2}[T_{i+1}]     &\delta_{i+1/2}[T^{k}] &\\ 
    652 &&+{e_{2u}}_i^{k\ \ \ \:}                            &{A_{e}}_{i}^{k\ \ \ \:}        
    653     &\ {\ \ \;_i^k \mathbb{R}_{+1/2}^{+1/2}} &\delta_{k+1/2}[T_{i\ \ \ \;}] &\delta_{i+1/2}[T^{k}] &\\ 
    654 % 
    655 &&-{e_{2u}}_i^{k+1}                                &{A_{e}}_i^{k+1}  
    656   &{_i^{k+1} \mathbb{R}_{-1/2}^{- 1/2}}   &\delta_{i-1/2}[T^{k+1}]      &\delta_{k+1/2}[T_{i}] &\\    
    657 &&-{e_{2u}}_i^{k\ \ \ \:}                             &{A_{e}}_i^{k\ \ \ \:}  
    658   &{\ \ \;_i^k  \mathbb{R}_{-1/2}^{+1/2}}   &\delta_{i-1/2}[T^{k\ \ \ \:}]  &\delta_{k+1/2}[T_{i}] &\\ 
    659 &&-{e_{2u}}_i^{k+1    }                             &{A_{e}}_i^{k+1}  
    660   &{_i^{k+1} \mathbb{R}_{+1/2}^{- 1/2}}   &\delta_{i+1/2}[T^{k+1}]      &\delta_{k+1/2}[T_{i}] &\\    
    661 &&-{e_{2u}}_i^{k\ \ \ \:}                             &{A_{e}}_i^{k\ \ \ \:}  
    662   &{\ \ \;_i^k  \mathbb{R}_{+1/2}^{+1/2}}   &\delta_{i+1/2}[T^{k\ \ \ \:}]  &\delta_{k+1/2}[T_{i}]  
    663 &\Bigr\}  \\ 
    664 \end{matrix}    
    665 \end{align*} 
    666 The two terms associated with the triad ${_i^k \mathbb{R}_{+1/2}^{+1/2}}$ are the  
    667 same but of opposite signs, they cancel out.  
    668 Exactly the same thing occurs for the triad ${_i^k \mathbb{R}_{-1/2}^{-1/2}}$.  
    669 The two terms associated with the triad ${_i^k \mathbb{R}_{+1/2}^{-1/2}}$ are the  
    670 same but both of opposite signs and shifted by 1 in $k$ direction. When summing over $k$  
    671 they cancel out with the neighbouring grid points.  
    672 Exactly the same thing occurs for the triad ${_i^k \mathbb{R}_{-1/2}^{+1/2}}$ in the  
    673 $i$ direction. Therefore the sum over the domain is zero, $i.e.$ the variance of the  
    674 tracer is preserved by the discretisation of the skew fluxes. 
    675  
    676 %%% Local Variables:  
    677 %%% TeX-master: "../../NEMO_book.tex" 
    678 %%% End:  
     980The total fluxes per unit physical area are then 
     981\begin{equation}\label{eq:triad:eiv_skew_physical} 
     982\begin{split} 
     983 f^*_1 & = \frac{1}{e_{3}}\; \psi_1 \partial_k T   \\ 
     984 f^*_2 & = \frac{1}{e_{3}}\; \psi_2 \partial_k T   \\ 
     985 f^*_3 & =  -\frac{1}{e_{1}e_{2}}\; \left\{ e_{2} \psi_1 \partial_i T 
     986   + e_{1} \psi_2 \partial_j T \right\}. \\ 
     987\end{split} 
     988\end{equation} 
     989Note that Eq.~ \eqref{eq:triad:eiv_skew_physical} takes the same form whatever the 
     990vertical coordinate, though of course the slopes 
     991$\tilde{r}_i$ which define the $\psi_i$ in \eqref{eq:triad:eiv_psi} are relative to geopotentials. 
     992The tendency associated with eddy induced velocity is then simply the convergence 
     993of the fluxes (\ref{eq:triad:eiv_skew_ijk}, \ref{eq:triad:eiv_skew_physical}), so 
     994\begin{equation} \label{eq:triad:skew_eiv_conv} 
     995\frac{\partial T}{\partial t}= -\frac{1}{e_1 \, e_2 \, e_3 }      \left[ 
     996  \frac{\partial}{\partial i} \left( e_2 \psi_1 \partial_k T\right) 
     997  + \frac{\partial}{\partial j} \left( e_1  \; 
     998    \psi_2 \partial_k T\right) 
     999 -  \frac{\partial}{\partial k} \left( e_{2} \psi_1 \partial_i T 
     1000   + e_{1} \psi_2 \partial_j T \right)  \right] 
     1001\end{equation} 
     1002 It naturally conserves the tracer content, as it is expressed in flux 
     1003 form. Since it has the same divergence as the advective form it also 
     1004 preserves the tracer variance. 
     1005 
     1006\subsection{The discrete skew flux formulation} 
     1007The skew fluxes in (\ref{eq:triad:eiv_skew_physical}, \ref{eq:triad:eiv_skew_ijk}), like the off-diagonal terms 
     1008(\ref{eq:triad:i13c}, \ref{eq:triad:i31c}) of the small angle diffusion tensor, are best 
     1009expressed in terms of the triad slopes, as in Fig.~\ref{fig:triad:ISO_triad} 
     1010and Eqs~(\ref{eq:triad:i13}, \ref{eq:triad:i31}); but now in terms of the triad slopes 
     1011$\tilde{\mathbb{R}}$ relative to geopotentials instead of the 
     1012$\mathbb{R}$ relative to coordinate surfaces. The discrete form of 
     1013\eqref{eq:triad:eiv_skew_ijk} using the slopes \eqref{eq:triad:R} and 
     1014defining $A_e$ at $T$-points is then given by: 
     1015 
     1016 
     1017\begin{subequations}\label{eq:triad:allskewflux} 
     1018  \begin{flalign}\label{eq:triad:vect_skew_flux} 
     1019    \vect{F}_\mathrm{eiv}(T) &\equiv 
     1020    \sum_{\substack{i_p,\,k_p}} 
     1021    \begin{pmatrix} 
     1022      {_{i+1/2-i_p}^k {\mathbb{S}_u}_{i_p}^{k_p} } (T)      \\ 
     1023      \\ 
     1024      {_i^{k+1/2-k_p} {\mathbb{S}_w}_{i_p}^{k_p} } (T)      \\ 
     1025    \end{pmatrix}, 
     1026  \end{flalign} 
     1027  where the skew flux in the $i$-direction associated with a given 
     1028  triad is (\ref{eq:triad:latflux-triad}, \ref{eq:triad:triadfluxu}): 
     1029  \begin{align} 
     1030    \label{eq:triad:skewfluxu} 
     1031    _i^k {\mathbb{S}_u}_{i_p}^{k_p} (T) &= + \quarter {A_e}_i^k{ 
     1032      \:}\frac{{b_u}_{i+i_p}^k}{{e_{1u}}_{\,i + i_p}^{\,k}} 
     1033     \ {_i^k\tilde{\mathbb{R}}_{i_p}^{k_p}} \ 
     1034      \frac{ \delta_{k+k_p} [T^i] }{{e_{3w}}_{\,i}^{\,k+k_p} }, 
     1035   \\ 
     1036    \intertext{and \eqref{eq:triad:triadfluxw} in the $k$-direction, changing the sign 
     1037      to be consistent with \eqref{eq:triad:eiv_skew_ijk}:} 
     1038    _i^k {\mathbb{S}_w}_{i_p}^{k_p} (T) 
     1039    &= -\quarter {A_e}_i^k{\: }\frac{{b_u}_{i+i_p}^k}{{e_{3w}}_{\,i}^{\,k+k_p}} 
     1040     {_i^k\tilde{\mathbb{R}}_{i_p}^{k_p}}\frac{ \delta_{i+ i_p}[T^k] }{ {e_{1u}}_{\,i + i_p}^{\,k} }.\label{eq:triad:skewfluxw} 
     1041  \end{align} 
     1042\end{subequations} 
     1043 
     1044Such a discretisation is consistent with the iso-neutral 
     1045operator as it uses the same definition for the slopes.  It also 
     1046ensures the following two key properties. 
     1047\subsubsection{No change in tracer variance} 
     1048The discretization conserves tracer variance, $i.e.$ it does not 
     1049include a diffusive component but is a `pure' advection term. This can 
     1050be seen 
     1051%either from Appendix \ref{Apdx_eiv_skew} or 
     1052by considering the 
     1053fluxes associated with a given triad slope 
     1054$_i^k{\mathbb{R}}_{i_p}^{k_p} (T)$. For, following 
     1055\S\ref{sec:triad:variance} and \eqref{eq:triad:dvar_iso_i}, the 
     1056associated horizontal skew-flux $_i^k{\mathbb{S}_u}_{i_p}^{k_p} (T)$ 
     1057drives a net rate of change of variance, summed over the two 
     1058$T$-points $i+i_p-\half,k$ and $i+i_p+\half,k$, of 
     1059\begin{equation} 
     1060\label{eq:triad:dvar_eiv_i} 
     1061  _i^k{\mathbb{S}_u}_{i_p}^{k_p} (T)\,\delta_{i+ i_p}[T^k], 
     1062\end{equation} 
     1063while the associated vertical skew-flux gives a variance change summed over the 
     1064$T$-points $i,k+k_p-\half$ (above) and $i,k+k_p+\half$ (below) of 
     1065\begin{equation} 
     1066\label{eq:triad:dvar_eiv_k} 
     1067  _i^k{\mathbb{S}_w}_{i_p}^{k_p} (T) \,\delta_{k+ k_p}[T^i]. 
     1068\end{equation} 
     1069Inspection of the definitions (\ref{eq:triad:skewfluxu}, \ref{eq:triad:skewfluxw}) 
     1070shows that these two variance changes (\ref{eq:triad:dvar_eiv_i}, \ref{eq:triad:dvar_eiv_k}) 
     1071sum to zero. Hence the two fluxes associated with each triad make no 
     1072net contribution to the variance budget. 
     1073 
     1074\subsubsection{Reduction in gravitational PE} 
     1075The vertical density flux associated with the vertical skew-flux 
     1076always has the same sign as the vertical density gradient; thus, so 
     1077long as the fluid is stable (the vertical density gradient is 
     1078negative) the vertical density flux is negative (downward) and hence 
     1079reduces the gravitational PE. 
     1080 
     1081For the change in gravitational PE driven by the $k$-flux is 
     1082\begin{align} 
     1083  \label{eq:triad:vert_densityPE} 
     1084  g {e_{3w}}_{\,i}^{\,k+k_p}{\mathbb{S}_w}_{i_p}^{k_p} (\rho) 
     1085  &=g {e_{3w}}_{\,i}^{\,k+k_p}\left[-\alpha _i^k {\:}_i^k 
     1086    {\mathbb{S}_w}_{i_p}^{k_p} (T) + \beta_i^k {\:}_i^k 
     1087    {\mathbb{S}_w}_{i_p}^{k_p} (S) \right]. \notag \\ 
     1088\intertext{Substituting  ${\:}_i^k {\mathbb{S}_w}_{i_p}^{k_p}$ from 
     1089  \eqref{eq:triad:skewfluxw}, gives} 
     1090% and separating out 
     1091% $\rtriadt{R}=\rtriad{R} + \delta_{i+i_p}[z_T^k]$, 
     1092% gives two terms. The 
     1093% first $\rtriad{R}$ term (the only term for $z$-coordinates) is: 
     1094 &=-\quarter g{A_e}_i^k{\: }{b_u}_{i+i_p}^k {_i^k\tilde{\mathbb{R}}_{i_p}^{k_p}} 
     1095\frac{ -\alpha _i^k\delta_{i+ i_p}[T^k]+ \beta_i^k\delta_{i+ i_p}[S^k]} { {e_{1u}}_{\,i + i_p}^{\,k} } \notag \\ 
     1096 &=+\quarter g{A_e}_i^k{\: }{b_u}_{i+i_p}^k 
     1097     \left({_i^k\mathbb{R}_{i_p}^{k_p}}+\frac{\delta_{i+i_p}[z_T^k]}{{e_{1u}}_{\,i + i_p}^{\,k}}\right) {_i^k\mathbb{R}_{i_p}^{k_p}} 
     1098\frac{-\alpha_i^k \delta_{k+ k_p}[T^i]+ \beta_i^k\delta_{k+ k_p}[S^i]} {{e_{3w}}_{\,i}^{\,k+k_p}}, 
     1099\end{align} 
     1100using the definition of the triad slope $\rtriad{R}$, 
     1101\eqref{eq:triad:R} to express $-\alpha _i^k\delta_{i+ i_p}[T^k]+ 
     1102\beta_i^k\delta_{i+ i_p}[S^k]$ in terms of  $-\alpha_i^k \delta_{k+ 
     1103  k_p}[T^i]+ \beta_i^k\delta_{k+ k_p}[S^i]$. 
     1104 
     1105Where the coordinates slope, the $i$-flux gives a PE change 
     1106\begin{multline} 
     1107  \label{eq:triad:lat_densityPE} 
     1108 g \delta_{i+i_p}[z_T^k] 
     1109\left[ 
     1110-\alpha _i^k {\:}_i^k {\mathbb{S}_u}_{i_p}^{k_p} (T) + \beta_i^k {\:}_i^k {\mathbb{S}_u}_{i_p}^{k_p} (S) 
     1111\right] \\ 
     1112= +\quarter g{A_e}_i^k{\: }{b_u}_{i+i_p}^k 
     1113     \frac{\delta_{i+i_p}[z_T^k]}{{e_{1u}}_{\,i + i_p}^{\,k}} 
     1114\left({_i^k\mathbb{R}_{i_p}^{k_p}}+\frac{\delta_{i+i_p}[z_T^k]}{{e_{1u}}_{\,i + i_p}^{\,k}}\right) 
     1115\frac{-\alpha_i^k \delta_{k+ k_p}[T^i]+ \beta_i^k\delta_{k+ k_p}[S^i]} {{e_{3w}}_{\,i}^{\,k+k_p}}, 
     1116\end{multline} 
     1117(using \eqref{eq:triad:skewfluxu}) and so the total PE change 
     1118\eqref{eq:triad:vert_densityPE} + \eqref{eq:triad:lat_densityPE} associated with the triad fluxes is 
     1119\begin{multline} 
     1120  \label{eq:triad:tot_densityPE} 
     1121  g{e_{3w}}_{\,i}^{\,k+k_p}{\mathbb{S}_w}_{i_p}^{k_p} (\rho) + 
     1122g\delta_{i+i_p}[z_T^k] {\:}_i^k {\mathbb{S}_u}_{i_p}^{k_p} (\rho) \\ 
     1123= +\quarter g{A_e}_i^k{\: }{b_u}_{i+i_p}^k 
     1124     \left({_i^k\mathbb{R}_{i_p}^{k_p}}+\frac{\delta_{i+i_p}[z_T^k]}{{e_{1u}}_{\,i + i_p}^{\,k}}\right)^2 
     1125\frac{-\alpha_i^k \delta_{k+ k_p}[T^i]+ \beta_i^k\delta_{k+ k_p}[S^i]} {{e_{3w}}_{\,i}^{\,k+k_p}}. 
     1126\end{multline} 
     1127Where the fluid is stable, with $-\alpha_i^k \delta_{k+ k_p}[T^i]+ 
     1128\beta_i^k\delta_{k+ k_p}[S^i]<0$, this PE change is negative. 
     1129 
     1130\subsection{Treatment of the triads at the boundaries}\label{sec:triad:skew_bdry} 
     1131Triad slopes \rtriadt{R} used for the calculation of the eddy-induced skew-fluxes 
     1132are masked at the boundaries in exactly the same way as are the triad 
     1133slopes \rtriad{R} used for the iso-neutral diffusive fluxes, as 
     1134described in \S\ref{sec:triad:iso_bdry} and 
     1135Fig.~\ref{fig:triad:bdry_triads}. Thus surface layer triads 
     1136$\triadt{i}{1}{R}{1/2}{-1/2}$ and $\triadt{i+1}{1}{R}{-1/2}{-1/2}$ are 
     1137masked, and both near bottom triad slopes $\triadt{i}{k}{R}{1/2}{1/2}$ 
     1138and $\triadt{i+1}{k}{R}{-1/2}{1/2}$ are masked when either of the 
     1139$i,k+1$ or $i+1,k+1$ tracer points is masked, i.e.\ the $i,k+1$ 
     1140$u$-point is masked. The namelist parameter \np{ln\_botmix\_grif} has 
     1141no effect on the eddy-induced skew-fluxes. 
     1142 
     1143\subsection{ Limiting of the slopes within the interior}\label{sec:triad:limitskew} 
     1144Presently, the iso-neutral slopes $\tilde{r}_i$ relative 
     1145to geopotentials are limited to be less than $1/100$, exactly as in 
     1146calculating the iso-neutral diffusion, \S \ref{sec:triad:limit}. Each 
     1147individual triad \rtriadt{R} is so limited. 
     1148 
     1149\subsection{Tapering within the surface mixed layer}\label{sec:triad:taperskew} 
     1150The slopes $\tilde{r}_i$ relative to 
     1151geopotentials (and thus the individual triads \rtriadt{R}) are always tapered linearly from their value immediately below the mixed layer to zero at the 
     1152surface \eqref{eq:triad:rmtilde}, as described in \S\ref{sec:triad:lintaper}. This is 
     1153option (c) of Fig.~\ref{Fig_eiv_slp}. This linear tapering for the 
     1154slopes used to calculate the eddy-induced fluxes is 
     1155unaffected by the value of \np{ln\_triad\_iso}. 
     1156 
     1157The justification for this linear slope tapering is that, for $A_e$ 
     1158that is constant or varies only in the horizontal (the most commonly 
     1159used options in \NEMO: see \S\ref{LDF_coef}), it is 
     1160equivalent to a horizontal eiv (eddy-induced velocity) that is uniform 
     1161within the mixed layer \eqref{eq:triad:eiv_v}. This ensures that the 
     1162eiv velocities do not restratify the mixed layer \citep{Treguier1997, 
     1163  Danabasoglu_al_2008}. Equivantly, in terms 
     1164of the skew-flux formulation we use here, the 
     1165linear slope tapering within the mixed-layer gives a linearly varying 
     1166vertical flux, and so a tracer convergence uniform in depth (the 
     1167horizontal flux convergence is relatively insignificant within the mixed-layer). 
     1168 
     1169\subsection{Streamfunction diagnostics}\label{sec:triad:sfdiag} 
     1170Where the namelist parameter \np{ln\_traldf\_gdia}=true, diagnosed 
     1171mean eddy-induced velocities are output. Each time step, 
     1172streamfunctions are calculated in the $i$-$k$ and $j$-$k$ planes at 
     1173$uw$ (integer +1/2 $i$, integer $j$, integer +1/2 $k$) and $vw$ 
     1174(integer $i$, integer +1/2 $j$, integer +1/2 $k$) points (see Table 
     1175\ref{Tab_cell}) respectively. We follow \citep{Griffies_Bk04} and 
     1176calculate the streamfunction at a given $uw$-point from the 
     1177surrounding four triads according to: 
     1178\begin{equation} 
     1179  \label{eq:triad:sfdiagi} 
     1180  {\psi_1}_{i+1/2}^{k+1/2}={\quarter}\sum_{\substack{i_p,\,k_p}} 
     1181  {A_e}_{i+1/2-i_p}^{k+1/2-k_p}\:\triadd{i+1/2-i_p}{k+1/2-k_p}{R}{i_p}{k_p}. 
     1182\end{equation} 
     1183The streamfunction $\psi_1$ is calculated similarly at $vw$ points. 
     1184The eddy-induced velocities are then calculated from the 
     1185straightforward discretisation of \eqref{eq:triad:eiv_v}: 
     1186\begin{equation}\label{eq:triad:eiv_v_discrete} 
     1187\begin{split} 
     1188 {u^*}_{i+1/2}^{k} & = - \frac{1}{{e_{3u}}_{i}^{k}}\left({\psi_1}_{i+1/2}^{k+1/2}-{\psi_1}_{i+1/2}^{k+1/2}\right),   \\ 
     1189 {v^*}_{j+1/2}^{k} & = - \frac{1}{{e_{3v}}_{j}^{k}}\left({\psi_2}_{j+1/2}^{k+1/2}-{\psi_2}_{j+1/2}^{k+1/2}\right),   \\ 
     1190 {w^*}_{i,j}^{k+1/2} & =    \frac{1}{e_{1t}e_{2t}}\; \left\{ 
     1191 {e_{2u}}_{i+1/2}^{k+1/2} \,{\psi_1}_{i+1/2}^{k+1/2} - 
     1192 {e_{2u}}_{i-1/2}^{k+1/2} \,{\psi_1}_{i-1/2}^{k+1/2} \right. + \\ 
     1193\phantom{=} & \qquad\qquad\left. {e_{2v}}_{j+1/2}^{k+1/2} \,{\psi_2}_{j+1/2}^{k+1/2} - {e_{2v}}_{j-1/2}^{k+1/2} \,{\psi_2}_{j-1/2}^{k+1/2} \right\}, 
     1194\end{split} 
     1195\end{equation} 
  • trunk/DOC/TexFiles/Chapters/Chap_ASM.tex

    r2483 r3294  
    1515The ASM code adds the functionality to apply increments to the model variables:  
    1616temperature, salinity, sea surface height, velocity and sea ice concentration.  
    17 These are read into the model from a NetCDF file which may be produced by data 
    18 assimilation.  The code can also output model background fields which are used 
     17These are read into the model from a NetCDF file which may be produced by separate data 
     18assimilation code.  The code can also output model background fields which are used 
    1919as an input to data assimilation code. This is all controlled by the namelist 
    2020\textit{nam\_asminc}.  There is a brief description of all the namelist options 
     
    8686 
    8787%========================================================================== 
     88% Divergence damping description %%% 
     89\section{Divergence damping initialisation} 
     90\label{ASM_details} 
     91 
     92The velocity increments may be initialized by the iterative application of  
     93a divergence damping operator. In iteration step $n$ new estimates of  
     94velocity increments $u^{n}_I$ and $v^{n}_I$ are updated by: 
     95\begin{equation} \label{eq:asm_dmp} 
     96\left\{ \begin{aligned} 
     97 u^{n}_I = u^{n-1}_I + \frac{1}{e_{1u} } \delta _{i+1/2} \left( {A_D 
     98\;\chi^{n-1}_I } \right) \\ 
     99\\ 
     100 v^{n}_I = v^{n-1}_I + \frac{1}{e_{2v} } \delta _{j+1/2} \left( {A_D 
     101\;\chi^{n-1}_I } \right) \\ 
     102\end{aligned} \right., 
     103\end{equation} 
     104where 
     105\begin{equation} \label{eq:asm_div} 
     106\chi^{n-1}_I = \frac{1}{e_{1t}\,e_{2t}\,e_{3t} } 
     107                \left( {\delta _i \left[ {e_{2u}\,e_{3u}\,u^{n-1}_I} \right] 
     108                       +\delta _j \left[ {e_{1v}\,e_{3v}\,v^{n-1}_I} \right]} \right). 
     109\end{equation} 
     110By the application of \eqref{eq:asm_dmp} and \eqref{eq:asm_dmp} the divergence is filtered 
     111in each iteration, and the vorticity is left unchanged. In the presence of coastal boundaries 
     112with zero velocity increments perpendicular to the coast the divergence is strongly damped. 
     113This type of the initialisation reduces the vertical velocity magnitude  and alleviates the 
     114problem of the excessive unphysical vertical mixing in the first steps of the model  
     115integration \citep{Talagrand_JAS72, Dobricic_al_OS07}. Diffusion coefficients are defined as  
     116$A_D = \alpha e_{1t} e_{2t}$, where $\alpha = 0.2$. The divergence damping is activated by 
     117assigning to \np{nn\_divdmp} in the \textit{nam\_asminc} namelist a value greater than zero.  
     118By choosing this value to be of the order of 100 the increments in the vertical velocity will  
     119be significantly reduced. 
     120 
     121 
     122%========================================================================== 
    88123 
    89124\section{Implementation details} 
  • trunk/DOC/TexFiles/Chapters/Chap_CFG.tex

    • Property svn:executable deleted
    r2541 r3294  
    219219at $\sim 30\deg$N and rotated by 45\deg, 3180~km long, 2120~km wide  
    220220and 4~km deep (Fig.~\ref{Fig_MISC_strait_hand}).  
    221 The domain is bounded by vertical walls and by a ßat bottom. The configuration is  
     221The domain is bounded by vertical walls and by a flat bottom. The configuration is  
    222222meant to represent an idealized North Atlantic or North Pacific basin.  
    223 The circulation is forced by analytical profiles of wind and buoyancy ßuxes.  
     223The circulation is forced by analytical profiles of wind and buoyancy fluxes.  
    224224The applied forcings vary seasonally in a sinusoidal manner between winter  
    225225and summer extrema \citep{Levy_al_OM10}.  
     
    227227It forces a subpolar gyre in the north, a subtropical gyre in the wider part of the domain  
    228228and a small recirculation gyre in the southern corner.  
    229 The net heat ßux takes the form of a restoring toward a zonal apparent air  
    230 temperature profile. A portion of the net heat ßux which comes from the solar radiation 
     229The net heat flux takes the form of a restoring toward a zonal apparent air  
     230temperature profile. A portion of the net heat flux which comes from the solar radiation 
    231231is allowed to penetrate within the water column.  
    232 The fresh water ßux is also prescribed and varies zonally.  
    233 It is determined such as, at each time step, the basin-integrated ßux is zero.  
     232The fresh water flux is also prescribed and varies zonally.  
     233It is determined such as, at each time step, the basin-integrated flux is zero.  
    234234The basin is initialised at rest with vertical profiles of temperature and salinity  
    235235uniformly applied to the whole domain. 
     
    269269 
    270270% ------------------------------------------------------------------------------------------------------------- 
    271 %       POMME configuration 
    272 % ------------------------------------------------------------------------------------------------------------- 
    273 \section{POMME: mid-latitude sub-domain} 
    274 \label{MISC_config_POMME} 
    275  
    276  
    277 \key{pomme\_r025} : to be described.... 
    278  
    279  
    280  
     271%       AMM configuration 
     272% ------------------------------------------------------------------------------------------------------------- 
     273\section{AMM: atlantic margin configuration (\key{amm\_12km})} 
     274\label{MISC_config_AMM} 
     275 
     276The AMM, Atlantic Margins Model, is a regional model covering the 
     277Northwest European Shelf domain on a regular lat-lon grid at 
     278approximately 12km horizontal resolution. The key \key{amm\_12km} 
     279is used to create the correct dimensions of the AMM domain. 
     280 
     281This configuration tests several features of NEMO functionality specific 
     282to the shelf seas. 
     283In particular, the AMM uses $S$-coordinates in the vertical rather than 
     284$z$-coordinates and is forced with tidal lateral boundary conditions 
     285using a flather boundary condition from the BDY module (key\_bdy). 
     286The AMM configuration  uses the GLS (key\_zdfgls) turbulence scheme, the 
     287VVL non-linear free surface(key\_vvl) and time-splitting 
     288(key\_dynspg\_ts). 
     289 
     290In addition to the tidal boundary condition the model may also take 
     291open boundary conditions from a North Atlantic model. Boundaries may be 
     292completely ommited by removing the BDY key (key\_bdy). 
     293Sample surface fluxes, river forcing and a sample initial restart file 
     294are included to test a realistic model run. The Baltic boundary is 
     295included within the river input file and is specified as a river source. 
     296Unlike ordinary river points the Baltic inputs also include salinity and 
     297temperature data. 
     298 
  • trunk/DOC/TexFiles/Chapters/Chap_Conservation.tex

    • Property svn:executable deleted
  • trunk/DOC/TexFiles/Chapters/Chap_DIA.tex

    • Property svn:executable deleted
    r2541 r3294  
    236236\item[group]: define a group of file or field. Accept the same attributes as file or field. 
    237237 
    238 \item[file]: define the output fileÕs characteristics. Accepted attributes are description, enable,  
     238\item[file]: define the output file's characteristics. Accepted attributes are description, enable,  
    239239output\_freq, output\_level, id, name, name\_suffix. Child of file\_definition or group of files tag. 
    240240 
     
    321321\item[output\_level]: file attribute. Integer from 0 to 10 defining the output priority of variables in a file:  
    322322all variables listed in the file with a level smaller or equal to output\_level will be output.  
    323 Other variables wonÕt be output even if they are listed in the file.   
     323Other variables won't be output even if they are listed in the file.   
    324324 
    325325\item[positive]: axis attribute (always .FALSE.). Logical defining the vertical axis convention used  
     
    681681numeric of the code, so that the trajectories never intercept the bathymetry.  
    682682 
     683\subsubsection{ Input data: initial coordinates } 
     684 
     685Initial coordinates can be given with Ariane Tools convention ( IJK coordinates ,(\np{ln\_ariane}=true) ) 
     686or with longitude and latitude. 
     687 
     688 
     689In case of Ariane convention, input filename is \np{"init\_float\_ariane"}. Its format is: 
     690 
     691\texttt{ I J K nisobfl itrash itrash } 
     692 
     693\noindent with:  
     694 
     695 - I,J,K  : indexes of initial position 
     696 
     697 - nisobfl: 0 for an isobar float, 1 for a float following the w velocity   
     698 
     699 - itrash : set to zero; it is a dummy variable to respect Ariane Tools convention 
     700 
     701 - itrash :set to zero; it is a dummy variable to respect Ariane Tools convention 
     702 
     703\noindent Example:\\ 
     704\noindent \texttt{ 100.00000  90.00000  -1.50000 1.00000   0.00000}\\ 
     705\texttt{ 102.00000  90.00000  -1.50000 1.00000   0.00000}\\ 
     706\texttt{ 104.00000  90.00000  -1.50000 1.00000   0.00000}\\ 
     707\texttt{ 106.00000  90.00000  -1.50000 1.00000   0.00000}\\ 
     708\texttt{ 108.00000  90.00000  -1.50000 1.00000   0.00000}\\ 
     709 
     710 
     711In the other case ( longitude and latitude ), input filename is \np{"init\_float"}. Its format is: 
     712 
     713\texttt{ Long Lat depth nisobfl ngrpfl itrash} 
     714 
     715\noindent with: 
     716 
     717 - Long, Lat, depth  : Longitude, latitude, depth 
     718 
     719 - nisobfl: 0 for an isobar float, 1 for a float following the w velocity 
     720 
     721 - ngrpfl : number to identify searcher group 
     722 
     723 - itrash :set to 1; it is a dummy variable. 
     724 
     725\noindent Example: 
     726 
     727\noindent\texttt{  20.0 0.0 0.0 0 1 1 }\\ 
     728\texttt{ -21.0 0.0 0.0 0 1 1 }\\ 
     729\texttt{ -22.0 0.0 0.0 0 1 1 }\\ 
     730\texttt{ -23.0 0.0 0.0 0 1 1 }\\ 
     731\texttt{ -24.0 0.0 0.0 0 1 1 }\\ 
     732 
     733\np{jpnfl} is the total number of floats during the run. 
     734When initial positions are read in a restart file ( \np{ln\_rstflo= .TRUE.} ),  \np{jpnflnewflo} 
     735can be added in the initialization file.  
     736 
     737\subsubsection{ Output data } 
     738 
     739\np{nn\_writefl} is the frequency of writing in float output file and \np{nn\_stockfl}  
     740is the frequency of creation of the float restart file. 
     741 
     742Output data can be written in ascii files (\np{ln\_flo\_ascii = .TRUE.} ). In that case,  
     743output filename is \np{is trajec\_float}. 
     744 
     745Another possiblity of writing format is Netcdf (\np{ln\_flo\_ascii = .FALSE.} ). There are 2 possibilities: 
     746 
     747 - if (\key{iomput}) is used, outputs are selected in  \np{iodef.xml}. Here it is an example of specification  
     748   to put in files description section: 
     749 
     750\vspace{-30pt} 
     751\begin{alltt}  {{\scriptsize 
     752\begin{verbatim} 
     753 
     754     <group id="1d\_grid\_T" name="auto" description="ocean T grid variables" >   } 
     755       <file id="floats"  description="floats variables"> }\\ 
     756           <field ref="traj\_lon"   name="floats\_longitude"   freq\_op="86400" />} 
     757           <field ref="traj\_lat"   name="floats\_latitude"    freq\_op="86400" />} 
     758           <field ref="traj\_dep"   name="floats\_depth"       freq\_op="86400" />} 
     759           <field ref="traj\_temp"  name="floats\_temperature" freq\_op="86400" />} 
     760           <field ref="traj\_salt"  name="floats\_salinity"    freq\_op="86400" />} 
     761           <field ref="traj\_dens"  name="floats\_density"     freq\_op="86400" />} 
     762           <field ref="traj\_group" name="floats\_group"       freq\_op="86400" />} 
     763       </file>} 
     764  </group>} 
     765 
     766\end{verbatim} 
     767}}\end{alltt} 
     768 
     769 
     770 -  if (\key{iomput}) is not used, a file called \np{trajec\_float.nc} will be created by IOIPSL library. 
     771 
     772 
     773 
    683774See also \href{http://stockage.univ-brest.fr/~grima/Ariane/}{here} the web site describing  
    684775the off-line use of this marvellous diagnostic tool. 
     776 
     777 
     778% ------------------------------------------------------------------------------------------------------------- 
     779%       Harmonic analysis of tidal constituents 
     780% ------------------------------------------------------------------------------------------------------------- 
     781\section{Harmonic analysis of tidal constituents (\key{diaharm}) } 
     782\label{DIA_diag_harm} 
     783 
     784A module is available to compute the amplitude and phase for tidal waves.  
     785This diagnostic is actived with \key{diaharm}. 
     786 
     787%------------------------------------------namdia_harm---------------------------------------------------- 
     788\namdisplay{namdia_harm} 
     789%---------------------------------------------------------------------------------------------------------- 
     790 
     791Concerning the on-line Harmonic analysis, some parameters are available in namelist: 
     792 
     793- \texttt{nit000\_han} is the first time step used for harmonic analysis 
     794 
     795- \texttt{nitend\_han} is the last time step used for harmonic analysis 
     796 
     797- \texttt{nstep\_han} is the time step frequency for harmonic analysis 
     798 
     799- \texttt{nb\_ana} is the number of harmonics to analyse 
     800 
     801- \texttt{tname} is an array with names of tidal constituents to analyse 
     802 
     803\texttt{nit000\_han} and \texttt{nitend\_han} must be between \texttt{nit000} and \texttt{nitend} of the simulation. 
     804The restart capability is not implemented. 
     805 
     806The Harmonic analysis solve this equation: 
     807\begin{equation} 
     808h_{i} - A_{0} + \sum^{nb\_ana}_{j=1}[A_{j}cos(\nu_{j}t_{j}-\phi_{j})] = e_{i} 
     809\end{equation} 
     810 
     811With $A_{j}$,$\nu_{j}$,$\phi_{j}$, the amplitude, frequency and phase for each wave and $e_{i}$ the error. 
     812$h_{i}$ is the sea level for the time $t_{i}$ and $A_{0}$ is the mean sea level. \\ 
     813We can rewrite this equation: 
     814\begin{equation} 
     815h_{i} - A_{0} + \sum^{nb\_ana}_{j=1}[C_{j}cos(\nu_{j}t_{j})+S_{j}sin(\nu_{j}t_{j})] = e_{i} 
     816\end{equation} 
     817with $A_{j}=\sqrt{C^{2}_{j}+S^{2}_{j}}$ et $\phi_{j}=arctan(S_{j}/C_{j})$. 
     818 
     819We obtain in output $C_{j}$ and $S_{j}$ for each tidal wave. 
     820 
     821% ------------------------------------------------------------------------------------------------------------- 
     822%       Sections transports 
     823% ------------------------------------------------------------------------------------------------------------- 
     824\section{Transports across sections (\key{diadct}) } 
     825\label{DIA_diag_dct} 
     826 
     827A module is available to compute the transport of volume, heat and salt through sections. This diagnostic 
     828is actived with \key{diadct}. 
     829 
     830Each section is defined by the coordinates of its 2 extremities. The pathways between them are contructed 
     831using tools which can be found in  \texttt{NEMOGCM/TOOLS/SECTIONS\_DIADCT} and are written in a binary file 
     832 \texttt{section\_ijglobal.diadct\_ORCA2\_LIM} which is later read in by NEMO to compute on-line transports. 
     833 
     834The on-line transports module creates three output ascii files:  
     835 
     836- \texttt{volume\_transport} for volume transports (  unit: $10^{6} m^{3} s^{-1}$ ) 
     837 
     838- \texttt{heat\_transport}   for heat transports   (  unit: $10^{15} W $ ) 
     839 
     840- \texttt{salt\_transport}   for salt transports   (  unit: $10^{9}g s^{-1}$ )\\ 
     841 
     842 
     843Namelist parameters control how frequently the flows are summed and the time scales over which 
     844 they are averaged, as well as the level of output for debugging: 
     845 
     846%------------------------------------------namdct---------------------------------------------------- 
     847\namdisplay{namdct} 
     848%------------------------------------------------------------------------------------------------------------- 
     849 
     850\texttt{nn\_dct}: frequency of instantaneous transports computing 
     851 
     852\texttt{nn\_dctwri}: frequency of writing ( mean of instantaneous transports ) 
     853 
     854\texttt{nn\_debug}: debugging of the section 
     855 
     856\subsubsection{ To create a binary file containing the pathway of each section } 
     857 
     858In \texttt{NEMOGCM/TOOLS/SECTIONS\_DIADCT/run}, the file \texttt{ {list\_sections.ascii\_global}} 
     859contains a list of all the sections that are to be computed (this list of sections is based on MERSEA project metrics). 
     860 
     861Another file is available for the GYRE configuration (\texttt{ {list\_sections.ascii\_GYRE}}).  
     862 
     863Each section is defined by: 
     864 
     865\noindent \texttt{ long1 lat1 long2 lat2 nclass (ok/no)strpond (no)ice section\_name }\\ 
     866with: 
     867 
     868- \texttt{long1 lat1} , coordinates of the first extremity of the section; 
     869 
     870- \texttt{long2 lat2} , coordinates of the second extremity of the section; 
     871 
     872- \texttt{nclass} the number of bounds of your classes (e.g. 3 bounds for 2 classes); 
     873 
     874- \texttt{okstrpond} to compute heat and salt transport, \texttt{nostrpond} if no; 
     875 
     876- \texttt{ice}  to compute surface and volume ice transports, \texttt{noice} if no. \\ 
     877 
     878 
     879\noindent The results of the computing of transports, and the directions of positive 
     880 and negative flow do not depend on the order of the 2 extremities in this file.\\  
     881 
     882 
     883\noindent If nclass =/ 0,the next lines contain the class type and the nclass bounds: 
     884 
     885\texttt{long1 lat1 long2 lat2 nclass (ok/no)strpond (no)ice section\_name} 
     886 
     887\texttt{classtype} 
     888 
     889\texttt{zbound1} 
     890 
     891\texttt{zbound2} 
     892 
     893\texttt{.} 
     894 
     895\texttt{.} 
     896 
     897\texttt{nclass-1} 
     898 
     899\texttt{nclass} 
     900 
     901\noindent where \texttt{classtype} can be: 
     902 
     903- \texttt{zsal} for salinity classes 
     904 
     905- \texttt{ztem} for temperature classes 
     906 
     907- \texttt{zlay} for depth classes 
     908 
     909- \texttt{zsigi} for insitu density classes 
     910 
     911- \texttt{zsigp} for potential density classes \\ 
     912 
     913   
     914The script \texttt{job.ksh} computes the pathway for each section and creates a binary file  
     915\texttt{section\_ijglobal.diadct\_ORCA2\_LIM} which is read by NEMO. \\ 
     916 
     917It is possible to use this tools for new configuations: \texttt{job.ksh} has to be updated  
     918with the coordinates file name and path. \\ 
     919 
     920 
     921Examples of two sections, the ACC\_Drake\_Passage with no classes, and the 
     922 ATL\_Cuba\_Florida with 4 temperature clases (5 class bounds), are shown: 
     923 
     924\noindent \texttt{ -68.    -54.5   -60.    -64.7  00 okstrpond noice ACC\_Drake\_Passage} 
     925 
     926\noindent \texttt{ -80.5    22.5   -80.5    25.5  05 nostrpond noice ATL\_Cuba\_Florida} 
     927 
     928\noindent \texttt{ztem} 
     929 
     930\noindent \texttt{-2.0} 
     931 
     932\noindent \texttt{ 4.5} 
     933 
     934\noindent \texttt{ 7.0} 
     935 
     936\noindent \texttt{12.0} 
     937 
     938\noindent \texttt{40.0} 
     939 
     940 
     941\subsubsection{ To read the output files } 
     942 
     943The output format is : 
     944  
     945{\small\texttt{date, time-step number, section number, section name, section slope coefficient, class number,  
     946class name, class bound 1 , classe bound2, transport\_direction1 ,  transport\_direction2, transport\_total}}\\ 
     947 
     948 
     949For sections with classes, the first \texttt{nclass-1} lines correspond to the transport for each class  
     950and the last line corresponds to the total transport summed over all classes. For sections with no classes, class number 
     951\texttt{ 1 } corresponds to \texttt{ total class } and this class is called  \texttt{N}, meaning \texttt{none}.\\ 
     952 
     953 
     954\noindent \texttt{ transport\_direction1 } is the positive part of the transport ( \texttt{ > = 0 } ). 
     955 
     956\noindent \texttt{ transport\_direction2 } is the negative part of the transport ( \texttt{ < = 0 } ).\\ 
     957 
     958 
     959\noindent The \texttt{section slope coefficient} gives information about the significance of transports signs and direction:\\ 
     960 
     961 
     962 
     963\begin{tabular}{|c|c|c|c|p{4cm}|} 
     964\hline 
     965section slope coefficient & section type & direction 1 & direction 2 & total transport \\ \hline 
     9660.    &  horizontal & northward & southward & postive: northward  \\ \hline 
     9671000. &  vertical   & eastward  & westward  & postive: eastward  \\ \hline                 
     968\texttt{=/0, =/ 1000.}   &  diagonal   & eastward  & westward  & postive: eastward  \\ \hline                 
     969\end{tabular} 
     970 
     971 
    685972 
    686973% ------------------------------------------------------------------------------------------------------------- 
     
    7261013are removed from the sub-basins. Note also that the Arctic Ocean has been split  
    7271014into Atlantic and Pacific basins along the North fold line.  } 
    728 \end{center}   \end{figure} 
     1015\end{center}   \end{figure}   
    7291016%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    7301017 
     
    7331020(see Section \ref{MISC_steric} below for one of them).  
    7341021Activating those outputs requires to define the \key{diaar5} CPP key. 
     1022\\ 
     1023\\ 
    7351024 
    7361025 
  • trunk/DOC/TexFiles/Chapters/Chap_DOM.tex

    • Property svn:executable deleted
    r2376 r3294  
    8181 
    8282%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    83 \begin{table}[!tb] \label{Tab_cell} 
     83\begin{table}[!tb] 
    8484\begin{center} \begin{tabular}{|p{46pt}|p{56pt}|p{56pt}|p{56pt}|} 
    8585\hline 
     
    9393fw & $i+1/2$   & $j+1/2$   & $k+1/2$   \\ \hline 
    9494\end{tabular} 
    95 \caption{ \label{Tab_cell}    
     95\caption{ \label{Tab_cell} 
    9696Location of grid-points as a function of integer or integer and a half value of the column,  
    9797line or level. This indexing is only used for the writing of the semi-discrete equation.  
     
    123123the following discrete forms in the curvilinear $s$-coordinate system: 
    124124\begin{equation} \label{Eq_DOM_grad} 
    125 \nabla q\equiv    \frac{1}{e_{1u} } \delta _{i+1/2 } [q] \;\,{\rm {\bf i}} 
    126       +  \frac{1}{e_{2v} } \delta _{j+1/2 } [q] \;\,{\rm {\bf j}} 
    127       +  \frac{1}{e_{3w}} \delta _{k+1/2} [q] \;\,{\rm {\bf k}} 
     125\nabla q\equiv    \frac{1}{e_{1u} } \delta _{i+1/2 } [q] \;\,\mathbf{i} 
     126      +  \frac{1}{e_{2v} } \delta _{j+1/2 } [q] \;\,\mathbf{j} 
     127      +  \frac{1}{e_{3w}} \delta _{k+1/2} [q] \;\,\mathbf{k} 
    128128\end{equation} 
    129129\begin{multline} \label{Eq_DOM_lap} 
    130 \Delta q\equiv \frac{1}{e_{1t}\,e_{2t}\,e_{3t} }  
     130\Delta q\equiv \frac{1}{e_{1t}\,e_{2t}\,e_{3t} } 
    131131       \;\left(          \delta_i  \left[ \frac{e_{2u}\,e_{3u}} {e_{1u}} \;\delta_{i+1/2} [q] \right] 
    132132+                        \delta_j  \left[ \frac{e_{1v}\,e_{3v}}  {e_{2v}} \;\delta_{j+1/2} [q] \right] \;  \right)      \\ 
     
    139139\begin{eqnarray}  \label{Eq_DOM_curl} 
    140140 \nabla \times {\rm {\bf A}}\equiv & 
    141       \frac{1}{e_{2v}\,e_{3vw} } \ \left( \delta_{j +1/2} \left[e_{3w}\,a_3 \right] -\delta_{k+1/2} \left[e_{2v} \,a_2 \right] \right)  &\ \rm{\bf i} \\  
    142  +& \frac{1}{e_{2u}\,e_{3uw}} \ \left( \delta_{k+1/2} \left[e_{1u}\,a_1  \right] -\delta_{i +1/2} \left[e_{3w}\,a_3 \right] \right)  &\ \rm{\bf j} \\  
    143  +& \frac{1}{e_{1f} \,e_{2f}    } \ \left( \delta_{i +1/2} \left[e_{2v}\,a_2  \right] -\delta_{j +1/2} \left[e_{1u}\,a_1 \right] \right)  &\ \rm{\bf k} 
     141      \frac{1}{e_{2v}\,e_{3vw} } \ \left( \delta_{j +1/2} \left[e_{3w}\,a_3 \right] -\delta_{k+1/2} \left[e_{2v} \,a_2 \right] \right)  &\ \mathbf{i} \\  
     142 +& \frac{1}{e_{2u}\,e_{3uw}} \ \left( \delta_{k+1/2} \left[e_{1u}\,a_1  \right] -\delta_{i +1/2} \left[e_{3w}\,a_3 \right] \right)  &\ \mathbf{j} \\ 
     143 +& \frac{1}{e_{1f} \,e_{2f}    } \ \left( \delta_{i +1/2} \left[e_{2v}\,a_2  \right] -\delta_{j +1/2} \left[e_{1u}\,a_1 \right] \right)  &\ \mathbf{k} 
    144144 \end{eqnarray} 
    145145\begin{equation} \label{Eq_DOM_div} 
     
    819819\end{align*} 
    820820 
    821 \gmcomment{ STEVEN: are the dots multiplications?}       
    822  
    823821Note that \textit{wmask} is not defined as it is exactly equal to \textit{tmask} with  
    824822the numerical indexing used (\S~\ref{DOM_Num_Index}). Moreover, the  
     
    832830\gmcomment{   \colorbox{yellow}{Add one word on tricky trick !} mbathy in further modified in zdfbfr{\ldots}.  } 
    833831%%% 
     832 
     833% ================================================================ 
     834% Domain: Initial State (dtatsd & istate) 
     835% ================================================================ 
     836\section  [Domain: Initial State (\textit{istate and dtatsd})] 
     837      {Domain: Initial State \small{(\mdl{istate} and \mdl{dtatsd} modules)} } 
     838\label{DTA_tsd} 
     839%-----------------------------------------namtsd------------------------------------------- 
     840\namdisplay{namtsd}  
     841%------------------------------------------------------------------------------------------ 
     842 
     843By default, the ocean start from rest (the velocity field is set to zero) and the initialization of  
     844temperature and salinity fields is controlled through the \np{ln\_tsd\_ini} namelist parameter. 
     845\begin{description} 
     846\item[ln\_tsd\_init = .true.]  use a T and S input files that can be given on the model grid itself or  
     847on their native input data grid. In the latter case, the data will be interpolated on-the-fly both in the  
     848horizontal and the vertical to the model grid (see \S~\ref{SBC_iof}). The information relative to the  
     849input files are given in the \np{sn\_tem} and \np{sn\_sal} structures.  
     850The computation is done in the \mdl{dtatsd} module. 
     851\item[ln\_tsd\_init = .false.] use constant salinity value of 35.5 psu and an analytical profile of temperature 
     852(typical of the tropical ocean), see \rou{istate\_t\_s} subroutine called from \mdl{istate} module. 
     853\end{description} 
  • trunk/DOC/TexFiles/Chapters/Chap_DYN.tex

    • Property svn:executable deleted
    r2541 r3294  
    189189the relative vorticity term and horizontal kinetic energy for the planetary vorticity  
    190190term (MIX scheme) ; or conserving both the potential enstrophy of horizontally non-divergent  
    191 flow and horizontal kinetic energy (ENE scheme) (see  Appendix~\ref{Apdx_C_vor_zad}).  
     191flow and horizontal kinetic energy (EEN scheme) (see  Appendix~\ref{Apdx_C_vor_zad}). In the  
     192case of ENS, ENE or MIX schemes the land sea mask may be slightly modified to ensure the  
     193consistency of vorticity term with analytical equations (\textit{ln\_dynvor\_con}=true). 
    192194The vorticity terms are all computed in dedicated routines that can be found in  
    193195the \mdl{dynvor} module. 
     
    605607Pressure gradient formulations in an $s$-coordinate have been the subject of a vast  
    606608number of papers ($e.g.$, \citet{Song1998, Shchepetkin_McWilliams_OM05}).  
    607 A number of different pressure gradient options are coded, but they are not yet fully  
    608 documented or tested.  
    609  
    610 $\bullet$ Traditional coding (see for example \citet{Madec_al_JPO96}: (\np{ln\_dynhpg\_sco}=true,  
    611 \np{ln\_dynhpg\_hel}=true) 
     609A number of different pressure gradient options are coded but the ROMS-like, density Jacobian with  
     610cubic polynomial method is currently disabled whilst known bugs are under investigation. 
     611 
     612$\bullet$ Traditional coding (see for example \citet{Madec_al_JPO96}: (\np{ln\_dynhpg\_sco}=true) 
    612613\begin{equation} \label{Eq_dynhpg_sco} 
    613614\left\{ \begin{aligned} 
     
    622623\eqref{Eq_dynhpg_zco_surf} - \eqref{Eq_dynhpg_zco}, and $z_T$ is the depth of  
    623624the $T$-point evaluated from the sum of the vertical scale factors at the $w$-point  
    624 ($e_{3w}$). The version \np{ln\_dynhpg\_hel}=true has been added by Aike  
    625 Beckmann and involves a redefinition of the relative position of $T$-points relative  
    626 to $w$-points.  
    627  
    628 $\bullet$ Weighted density Jacobian (WDJ) \citep{Song1998} (\np{ln\_dynhpg\_wdj}=true) 
     625($e_{3w}$).  
     626 
     627$\bullet$ Pressure Jacobian scheme (prj) (a research paper in preparation) (\np{ln\_dynhpg\_prj}=true) 
    629628 
    630629$\bullet$ Density Jacobian with cubic polynomial scheme (DJC) \citep{Shchepetkin_McWilliams_OM05}  
    631 (\np{ln\_dynhpg\_djc}=true) 
    632  
    633 $\bullet$ Rotated axes scheme (rot) \citep{Thiem_Berntsen_OM06} (\np{ln\_dynhpg\_rot}=true) 
    634  
    635 Note that expression \eqref{Eq_dynhpg_sco} is used when the variable volume  
    636 formulation is activated (\key{vvl}) because in that case, even with a flat bottom,  
    637 the coordinate surfaces are not horizontal but follow the free surface  
    638 \citep{Levier2007}. The other pressure gradient options are not yet available. 
     630(\np{ln\_dynhpg\_djc}=true) (currently disabled; under development) 
     631 
     632Note that expression \eqref{Eq_dynhpg_sco} is commonly used when the variable volume formulation is 
     633activated (\key{vvl}) because in that case, even with a flat bottom, the coordinate surfaces are not 
     634horizontal but follow the free surface \citep{Levier2007}. The pressure jacobian scheme 
     635(\np{ln\_dynhpg\_prj}=true) is available as an improved option to \np{ln\_dynhpg\_sco}=true when 
     636\key{vvl} is active.  The pressure Jacobian scheme uses a constrained cubic spline to reconstruct 
     637the density profile across the water column. This method maintains the monotonicity between the 
     638density nodes  The pressure can be calculated by analytical integration of the density profile and a 
     639pressure Jacobian method is used to solve the horizontal pressure gradient. This method can provide 
     640a more accurate calculation of the horizontal pressure gradient than the standard scheme. 
    639641 
    640642%-------------------------------------------------------------------------------------------------------------- 
     
    11621164 
    11631165% ================================================================ 
     1166% Neptune effect  
     1167% ================================================================ 
     1168\section  [Neptune effect (\textit{dynnept})] 
     1169                {Neptune effect (\mdl{dynnept})} 
     1170\label{DYN_nept} 
     1171 
     1172The "Neptune effect" (thus named in \citep{HollowayOM86}) is a 
     1173parameterisation of the potentially large effect of topographic form stress 
     1174(caused by eddies) in driving the ocean circulation. Originally developed for 
     1175low-resolution models, in which it was applied via a Laplacian (second-order) 
     1176diffusion-like term in the momentum equation, it can also be applied in eddy 
     1177permitting or resolving models, in which a more scale-selective bilaplacian 
     1178(fourth-order) implementation is preferred. This mechanism has a 
     1179significant effect on boundary currents (including undercurrents), and the 
     1180upwelling of deep water near continental shelves. 
     1181 
     1182The theoretical basis for the method can be found in  
     1183\citep{HollowayJPO92}, including the explanation of why form stress is not 
     1184necessarily a drag force, but may actually drive the flow.  
     1185\citep{HollowayJPO94} demonstrate the effects of the parameterisation in 
     1186the GFDL-MOM model, at a horizontal resolution of about 1.8 degrees.  
     1187\citep{HollowayOM08} demonstrate the biharmonic version of the 
     1188parameterisation in a global run of the POP model, with an average horizontal 
     1189grid spacing of about 32km. 
     1190 
     1191The NEMO implementation is a simplified form of that supplied by 
     1192Greg Holloway, the testing of which was described in \citep{HollowayJGR09}. 
     1193The major simplification is that a time invariant Neptune velocity 
     1194field is assumed.  This is computed only once, during start-up, and 
     1195made available to the rest of the code via a module.  Vertical 
     1196diffusive terms are also ignored, and the model topography itself 
     1197is used, rather than a separate topographic dataset as in 
     1198\citep{HollowayOM08}.  This implementation is only in the iso-level 
     1199formulation, as is the case anyway for the bilaplacian operator. 
     1200 
     1201The velocity field is derived from a transport stream function given by: 
     1202 
     1203\begin{equation} \label{Eq_dynnept_sf} 
     1204\psi = -fL^2H 
     1205\end{equation} 
     1206 
     1207where $L$ is a latitude-dependant length scale given by: 
     1208 
     1209\begin{equation} \label{Eq_dynnept_ls} 
     1210L = l_1 + (l_2 -l_1)\left ( {1 + \cos 2\phi \over 2 } \right ) 
     1211\end{equation} 
     1212 
     1213where $\phi$ is latitude and $l_1$ and $l_2$ are polar and equatorial length scales respectively. 
     1214Neptune velocity components, $u^*$, $v^*$ are derived from the stremfunction as: 
     1215 
     1216\begin{equation} \label{Eq_dynnept_vel} 
     1217u^* = -{1\over H} {\partial \psi \over \partial y}\ \ \  ,\ \ \ v^* = {1\over H} {\partial \psi \over \partial x} 
     1218\end{equation} 
     1219 
     1220\smallskip 
     1221%----------------------------------------------namdom---------------------------------------------------- 
     1222\namdisplay{namdyn_nept} 
     1223%-------------------------------------------------------------------------------------------------------- 
     1224\smallskip 
     1225 
     1226The Neptune effect is enabled when \np{ln\_neptsimp}=true (default=false). 
     1227\np{ln\_smooth\_neptvel} controls whether a scale-selective smoothing is applied 
     1228to the Neptune effect flow field (default=false) (this smoothing method is as 
     1229used by Holloway).  \np{rn\_tslse} and \np{rn\_tslsp} are the equatorial and 
     1230polar values respectively of the length-scale parameter $L$ used in determining 
     1231the Neptune stream function \eqref{Eq_dynnept_sf} and \eqref{Eq_dynnept_ls}. 
     1232Values at intermediate latitudes are given by a cosine fit, mimicking the 
     1233variation of the deformation radius with latitude.  The default values of 12km 
     1234and 3km are those given in \citep{HollowayJPO94}, appropriate for a coarse 
     1235resolution model. The finer resolution study of \citep{HollowayOM08} increased 
     1236the values of L by a factor of $\sqrt 2$ to 17km and 4.2km, thus doubling the 
     1237stream function for a given topography. 
     1238 
     1239The simple formulation for ($u^*$, $v^*$) can give unacceptably large velocities 
     1240in shallow water, and \citep{HollowayOM08} add an offset to the depth in the 
     1241denominator to control this problem. In this implementation we offer instead (at 
     1242the suggestion of G. Madec) the option of ramping down the Neptune flow field to 
     1243zero over a finite depth range. The switch \np{ln\_neptramp} activates this 
     1244option (default=false), in which case velocities at depths greater than 
     1245\np{rn\_htrmax} are unaltered, but ramp down linearly with depth to zero at a 
     1246depth of \np{rn\_htrmin} (and shallower). 
     1247 
     1248% ================================================================ 
  • trunk/DOC/TexFiles/Chapters/Chap_LBC.tex

    • Property svn:executable deleted
    r3230 r3294  
    742742 
    743743%-----------------------------------------nambdy-------------------------------------------- 
    744 %-    cn_mask    =  ''                        !  name of mask file (if ln_bdy_mask=.TRUE.) 
    745 %-    cn_dta_frs_T  = 'bdydata_grid_T.nc'     !  name of data file (T-points) 
    746 %-    cn_dta_frs_U  = 'bdydata_grid_U.nc'     !  name of data file (U-points) 
    747 %-    cn_dta_frs_V  = 'bdydata_grid_V.nc'     !  name of data file (V-points) 
    748 %-    cn_dta_fla_T  = 'bdydata_bt_grid_T.nc'  !  name of data file for Flather condition (T-points) 
    749 %-    cn_dta_fla_U  = 'bdydata_bt_grid_U.nc'  !  name of data file for Flather condition (U-points) 
    750 %-    cn_dta_fla_V  = 'bdydata_bt_grid_V.nc'  !  name of data file for Flather condition (V-points) 
    751 %-    ln_clim    = .false.                    !  contain 1 (T) or 12 (F) time dumps and be cyclic 
    752 %-    ln_vol     = .true.                     !  total volume correction (see volbdy parameter) 
    753 %-    ln_mask    = .false.                    !  boundary mask from filbdy_mask (T) or boundaries are on edges of domain (F) 
    754 %-    ln_tides   = .true.                     !  Apply tidal harmonic forcing with Flather condition 
    755 %-    ln_dyn_fla = .true.                     !  Apply Flather condition to velocities 
    756 %-    ln_tra_frs = .false.                    !  Apply FRS condition to temperature and salinity 
    757 %-    ln_dyn_frs = .false.                    !  Apply FRS condition to velocities 
    758 %-    nn_rimwidth    =  9                     !  width of the relaxation zone 
    759 %-    nn_dtactl      =  1                     !  = 0, bdy data are equal to the initial state 
    760 %-                                            !  = 1, bdy data are read in 'bdydata   .nc' files 
    761 %-    nn_volctl      =  0                     !  = 0, the total water flux across open boundaries is zero 
    762 %-                                            !  = 1, the total volume of the system is conserved 
    763744\namdisplay{nambdy}  
     745%----------------------------------------------------------------------------------------------- 
     746%-----------------------------------------nambdy_index-------------------------------------------- 
     747\namdisplay{nambdy_index}  
     748%----------------------------------------------------------------------------------------------- 
     749%-----------------------------------------nambdy_dta-------------------------------------------- 
     750\namdisplay{nambdy_dta}  
     751%----------------------------------------------------------------------------------------------- 
     752%-----------------------------------------nambdy_dta-------------------------------------------- 
     753\namdisplay{nambdy_dta2}  
    764754%----------------------------------------------------------------------------------------------- 
    765755 
     
    774764The BDY module was modelled on the OBC module and shares many features 
    775765and a similar coding structure \citep{Chanut2005}. 
     766 
     767The BDY module is completely rewritten at NEMO 3.4 and there is a new 
     768set of namelists. Boundary data files used with earlier versions of 
     769NEMO may need to be re-ordered to work with this version. See the 
     770section on the Input Boundary Data Files for details. 
     771 
     772%---------------------------------------------- 
     773\subsection{The namelists} 
     774\label{BDY_namelist} 
     775 
     776It is possible to define more than one boundary ``set'' and apply 
     777different boundary conditions to each set. The number of boundary 
     778sets is defined by \np{nb\_bdy}.  Each boundary set may be defined 
     779as a set of straight line segments in a namelist 
     780(\np{ln\_coords\_file}=.false.) or read in from a file 
     781(\np{ln\_coords\_file}=.true.). If the set is defined in a namelist, 
     782then the namelists nambdy\_index must be included separately, one for 
     783each set. If the set is defined by a file, then a 
     784``coordinates.bdy.nc'' file must be provided. The coordinates.bdy file 
     785is analagous to the usual NEMO ``coordinates.nc'' file. In the example 
     786above, there are two boundary sets, the first of which is defined via 
     787a file and the second is defined in a namelist. For more details of 
     788the definition of the boundary geometry see section 
     789\ref{BDY_geometry}. 
     790 
     791For each boundary set a boundary 
     792condition has to be chosen for the barotropic solution (``u2d'': 
     793sea-surface height and barotropic velocities), for the baroclinic 
     794velocities (``u3d''), and for the active tracers\footnote{The BDY 
     795  module does not deal with passive tracers at this version} 
     796(``tra''). For each set of variables there is a choice of algorithm 
     797and a choice for the data, eg. for the active tracers the algorithm is 
     798set by \np{nn\_tra} and the choice of data is set by 
     799\np{nn\_tra\_dta}.  
     800 
     801The choice of algorithm is currently as follows: 
     802 
     803\mbox{} 
     804 
     805\begin{itemize} 
     806\item[0.] No boundary condition applied. So the solution will ``see'' 
     807  the land points around the edge of the edge of the domain. 
     808\item[1.] Flow Relaxation Scheme (FRS) available for all variables.  
     809\item[2.] Flather radiation scheme for the barotropic variables. The 
     810  Flather scheme is not compatible with the filtered free surface 
     811  ({\it dynspg\_ts}).  
     812\end{itemize} 
     813 
     814\mbox{} 
     815 
     816The main choice for the boundary data is 
     817to use initial conditions as boundary data (\np{nn\_tra\_dta}=0) or to 
     818use external data from a file (\np{nn\_tra\_dta}=1). For the 
     819barotropic solution there is also the option to use tidal 
     820harmonic forcing either by itself or in addition to other external 
     821data.  
     822 
     823If external boundary data is required then the nambdy\_dta namelist 
     824must be defined. One nambdy\_dta namelist is required for each boundary 
     825set in the order in which the boundary sets are defined in nambdy. In 
     826the example given, two boundary sets have been defined and so there 
     827are two nambdy\_dta namelists. The boundary data is read in using the 
     828fldread module, so the nambdy\_dta namelist is in the format required 
     829for fldread. For each variable required, the filename, the frequency 
     830of the files and the frequency of the data in the files is given. Also 
     831whether or not time-interpolation is required and whether the data is 
     832climatological (time-cyclic) data. Note that on-the-fly spatial 
     833interpolation of boundary data is not available at this version.  
     834 
     835In the example namelists given, two boundary sets are defined. The 
     836first set is defined via a file and applies FRS conditions to 
     837temperature and salinity and Flather conditions to the barotropic 
     838variables. External data is provided in daily files (from a 
     839large-scale model). Tidal harmonic forcing is also used. The second 
     840set is defined in a namelist. FRS conditions are applied on 
     841temperature and salinity and climatological data is read from external 
     842files.  
    776843 
    777844%---------------------------------------------- 
     
    832899Note that the sea-surface height gradient in \eqref{Eq_bdy_fla1} 
    833900is a spatial gradient across the model boundary, so that $\eta_{e}$ is 
    834 defined on the $T$ points with $nbrdta=1$ and $\eta$ is defined on the 
    835 $T$ points with $nbrdta=2$. $U$ and $U_{e}$ are defined on the $U$ or 
    836 $V$ points with $nbrdta=1$, $i.e.$ between the two $T$ grid points. 
    837  
    838 %---------------------------------------------- 
    839 \subsection{Choice of schemes} 
    840 \label{BDY_choice_of_schemes} 
    841  
    842 The Flow Relaxation Scheme may be applied separately to the 
    843 temperature and salinity (\np{ln\_tra\_frs} = true) and 
    844 the velocity fields (\np{ln\_dyn\_frs} = true). Flather 
    845 radiation conditions may be applied using externally defined 
    846 barotropic velocities and sea-surface height (\np{ln\_dyn\_fla} = true)  
    847 or using tidal harmonics fields (\np{ln\_tides} = true)  
    848 or both. FRS and Flather conditions may be applied simultaneously.  
    849 A typical configuration where all possible conditions might be used is a tidal,  
    850 shelf-seas model, where the barotropic boundary conditions are fixed  
    851 with the Flather scheme using tidal harmonics and possibly output  
    852 from a large-scale model, and FRS conditions are applied to the tracers  
    853 and baroclinic velocity fields, using fields from a large-scale model. 
    854  
    855 Note that FRS conditions will work with the filtered 
    856 (\key{dynspg\_flt}) or time-split (\key{dynspg\_ts}) solutions for the 
    857 surface pressure gradient. The Flather condition will only work for 
    858 the time-split solution (\key{dynspg\_ts}). FRS conditions are applied 
    859 at the end of the main model time step. Flather conditions are applied 
    860 during the barotropic subcycle in the time-split solution.  
     901defined on the $T$ points with $nbr=1$ and $\eta$ is defined on the 
     902$T$ points with $nbr=2$. $U$ and $U_{e}$ are defined on the $U$ or 
     903$V$ points with $nbr=1$, $i.e.$ between the two $T$ grid points. 
    861904 
    862905%---------------------------------------------- 
     
    864907\label{BDY_geometry} 
    865908 
    866 The definition of the open boundary is completely flexible. An example 
    867 is shown in Fig.~\ref{Fig_LBC_bdy_geom}. The boundary zone is 
    868 defined by a series of index arrays read in from the input boundary 
    869 data files: $nbidta$, $nbjdta$, and $nbrdta$. The first two of these 
    870 define the global $(i,j)$ indices of each point in the boundary zone 
    871 and the $nbrdta$ array defines the discrete distance from the boundary 
    872 with $nbrdta=1$ meaning that the point is next to the edge of the 
    873 model domain and $nbrdta>1$ showing that the point is increasingly 
    874 further away from the edge of the model domain. These arrays are 
    875 defined separately for each of the $T$, $U$ and $V$ grids, but the 
    876 relationship between the points is assumed to be as in Fig. 
    877 \ref{Fig_LBC_bdy_geom} with the $T$ points forming the outermost row 
    878 of the boundary and the first row of velocities normal to the boundary 
    879 being inside the first row of $T$ points. The order in which the 
    880 points are defined is unimportant.  
     909Each open boundary set is defined as a list of points. The information 
     910is stored in the arrays $nbi$, $nbj$, and $nbr$ in the $idx\_bdy$ 
     911structure.  The $nbi$ and $nbj$ arrays 
     912define the local $(i,j)$ indices of each point in the boundary zone 
     913and the $nbr$ array defines the discrete distance from the boundary 
     914with $nbr=1$ meaning that the point is next to the edge of the 
     915model domain and $nbr>1$ showing that the point is increasingly 
     916further away from the edge of the model domain. A set of $nbi$, $nbj$, 
     917and $nbr$ arrays is defined for each of the $T$, $U$ and $V$ 
     918grids. Figure \ref{Fig_LBC_bdy_geom} shows an example of an irregular 
     919boundary.  
     920 
     921The boundary geometry for each set may be defined in a namelist 
     922nambdy\_index or by reading in a ``coordinates.bdy.nc'' file. The 
     923nambdy\_index namelist defines a series of straight-line segments for 
     924north, east, south and west boundaries. For the northern boundary, 
     925\np{nbdysegn} gives the number of segments, \np{jpjnob} gives the $j$ 
     926index for each segment and \np{jpindt} and \np{jpinft} give the start 
     927and end $i$ indices for each segment with similar for the other 
     928boundaries. These segments define a list of $T$ grid points along the 
     929outermost row of the boundary ($nbr\,=\, 1$). The code deduces the $U$ and 
     930$V$ points and also the points for $nbr\,>\, 1$ if 
     931$nn\_rimwidth\,>\,1$. 
     932 
     933The boundary geometry may also be defined from a 
     934``coordinates.bdy.nc'' file. Figure \ref{Fig_LBC_nc_header} 
     935gives an example of the header information from such a file. The file 
     936should contain the index arrays for each of the $T$, $U$ and $V$ 
     937grids. The arrays must be in order of increasing $nbr$. Note that the 
     938$nbi$, $nbj$ values in the file are global values and are converted to 
     939local values in the code. Typically this file will be used to generate 
     940external boundary data via interpolation and so will also contain the 
     941latitudes and longitudes of each point as shown. However, this is not 
     942necessary to run the model.  
     943 
     944For some choices of irregular boundary the model domain may contain 
     945areas of ocean which are not part of the computational domain. For 
     946example if an open boundary is defined along an isobath, say at the 
     947shelf break, then the areas of ocean outside of this boundary will 
     948need to be masked out. This can be done by reading a mask file defined 
     949as \np{cn\_mask\_file} in the nam\_bdy namelist. Only one mask file is 
     950used even if multiple boundary sets are defined. 
    881951 
    882952%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     
    892962\label{BDY_data} 
    893963 
    894 The input data files for the FRS conditions are defined in the 
    895 namelist as \np{cn\_dta\_frs\_T}, \np{cn\_dta\_frs\_U},  
    896 \np{cn\_dta\_frs\_V}. The input data files for the Flather conditions 
    897 are defined in the namelist as \np{cn\_dta\_fla\_T},  
    898 \np{cn\_dta\_fla\_U}, \np{cn\_dta\_fla\_V}.  
    899  
    900 The netcdf header of a typical input data file is shown in Fig.~\ref{Fig_LBC_nc_header}.  
    901 The file contains the index arrays which define the boundary geometry  
    902 as noted above and the data arrays for each field.   
    903 The data arrays are dimensioned on: a time dimension; $xb$  
    904 which is the index of the boundary data point in the horizontal;  
    905 and $yb$ which is a degenerate dimension of 1 to enable 
    906 the file to be read by the standard NEMO I/O routines. The 3D fields 
    907 also have a depth dimension. 
    908  
    909 If \np{ln\_clim} is set to \textit{false}, the model expects the 
    910 units of the time axis to have the form shown in 
    911 Fig.~\ref{Fig_LBC_nc_header}, $i.e.$ {\it ``seconds since yyyy-mm-dd 
    912 hh:mm:ss''} The fields are then linearly interpolated to the model 
    913 time at each timestep. Note that for this option, the time axis of the 
    914 input files must completely span the time period of the model 
    915 integration. If \np{ln\_clim} is set to \textit{true} (climatological 
    916 boundary forcing), the model will expect either a single set of annual 
    917 mean fields (constant boundary forcing) or 12 sets of monthly mean 
    918 fields in the input files. 
    919  
    920 As in the OBC module there is an option to use initial conditions as 
    921 boundary conditions. This is chosen by setting 
    922 \np{nn\_dtactl}~=~0. However, since the model defines the boundary 
    923 geometry by reading the boundary index arrays from the input files, 
    924 it is still necessary to provide a set of input files in this 
    925 case. They need only contain the boundary index arrays, $nbidta$, 
    926 \textit{nbjdta}, \textit{nbrdta}. 
     964The data files contain the data arrays 
     965in the order in which the points are defined in the $nbi$ and $nbj$ 
     966arrays. The data arrays are dimensioned on: a time dimension; 
     967$xb$ which is the index of the boundary data point in the horizontal; 
     968and $yb$ which is a degenerate dimension of 1 to enable the file to be 
     969read by the standard NEMO I/O routines. The 3D fields also have a 
     970depth dimension.  
     971 
     972At Version 3.4 there are new restrictions on the order in which the 
     973boundary points are defined (and therefore restrictions on the order 
     974of the data in the file). In particular: 
     975 
     976\mbox{} 
     977 
     978\begin{enumerate} 
     979\item The data points must be in order of increasing $nbr$, ie. all 
     980  the $nbr=1$ points, then all the $nbr=2$ points etc. 
     981\item All the data for a particular boundary set must be in the same 
     982  order. (Prior to 3.4 it was possible to define barotropic data in a 
     983  different order to the data for tracers and baroclinic velocities).  
     984\end{enumerate} 
     985 
     986\mbox{} 
     987 
     988These restrictions mean that data files used with previous versions of 
     989the model may not work with version 3.4. A fortran utility 
     990{\it bdy\_reorder} exists in the TOOLS directory which will re-order the 
     991data in old BDY data files.  
    927992 
    928993%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     
    930995\includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_LBC_nc_header.pdf} 
    931996\caption {     \label{Fig_LBC_nc_header}  
    932 Example of header of netcdf input data file for BDY} 
     997Example of the header for a coordinates.bdy.nc file} 
    933998\end{center}   \end{figure} 
    934999%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     
    9401005There is an option to force the total volume in the regional model to be constant,  
    9411006similar to the option in the OBC module. This is controlled  by the \np{nn\_volctl}  
    942 parameter in the namelist. A value of\np{nn\_volctl}~=~0 indicates that this option is not used.  
     1007parameter in the namelist. A value of \np{nn\_volctl}~=~0 indicates that this option is not used.  
    9431008If  \np{nn\_volctl}~=~1 then a correction is applied to the normal velocities  
    9441009around the boundary at each timestep to ensure that the integrated volume flow  
     
    9471012flux across the surface and the correction velocity corrects for this as well. 
    9481013 
    949  
     1014If more than one boundary set is used then volume correction is 
     1015applied to all boundaries at once. 
     1016 
     1017\newpage 
    9501018%---------------------------------------------- 
    9511019\subsection{Tidal harmonic forcing} 
    9521020\label{BDY_tides} 
    9531021 
     1022%-----------------------------------------nambdy_tide-------------------------------------------- 
     1023\namdisplay{nambdy_tide}  
     1024%----------------------------------------------------------------------------------------------- 
     1025 
    9541026To be written.... 
    9551027 
  • trunk/DOC/TexFiles/Chapters/Chap_LDF.tex

    • Property svn:executable deleted
    r2376 r3294  
    2121and for tracers only, eddy induced advection on tracers). These three aspects  
    2222of the lateral diffusion are set through namelist parameters and CPP keys  
    23 (see the \textit{nam\_traldf} and \textit{nam\_dynldf} below). 
     23(see the \textit{nam\_traldf} and \textit{nam\_dynldf} below). Note 
     24that this chapter describes the default implementation of iso-neutral 
     25tracer mixing, and Griffies's implementation, which is used if 
     26\np{traldf\_grif}=true, is described in Appdx\ref{sec:triad} 
    2427 
    2528%-----------------------------------nam_traldf - nam_dynldf-------------------------------------------- 
     
    128131$\ $\newline    % force a new ligne 
    129132 
    130 A space variation in the eddy coefficient appeals several remarks: 
     133The following points are relevant when the eddy coefficient varies spatially: 
    131134 
    132135(1) the momentum diffusion operator acting along model level surfaces is  
    133136written in terms of curl and divergent components of the horizontal current  
    134 (see \S\ref{PE_ldf}). Although the eddy coefficient can be set to different values  
    135 in these two terms, this option is not available.  
     137(see \S\ref{PE_ldf}). Although the eddy coefficient could be set to different values  
     138in these two terms, this option is not currently available.  
    136139 
    137140(2) with an horizontally varying viscosity, the quadratic integral constraints  
     
    220223and either \np{ln\_traldf\_hor}=True or \np{ln\_dynldf\_hor}=True.  
    221224 
    222 \subsection{slopes for tracer iso-neutral mixing} 
     225\subsection{Slopes for tracer iso-neutral mixing}\label{LDF_slp_iso} 
    223226In iso-neutral mixing  $r_1$ and $r_2$ are the slopes between the iso-neutral  
    224227and computational surfaces. Their formulation does not depend on the vertical  
     
    275278 
    276279\item[$s$- or hybrid $s$-$z$- coordinate : ] in the current release of \NEMO,  
    277 there is no specific treatment for iso-neutral mixing in the $s$-coordinate.  
     280iso-neutral mixing is only employed for $s$-coordinates if the 
     281Griffies scheme is used (\np{traldf\_grif}=true; see Appdx \ref{sec:triad}).  
    278282In other words, iso-neutral mixing will only be accurately represented with a  
    279283linear equation of state (\np{nn\_eos}=1 or 2). In the case of a "true" equation  
     
    332336\end{description} 
    333337 
    334 This implementation is a rather old one. It is similar to the one proposed  
    335 by Cox [1987], except for the background horizontal diffusion. Indeed,  
    336 the Cox implementation of isopycnal diffusion in GFDL-type models requires  
    337 a minimum background horizontal diffusion for numerical stability reasons.  
    338 To overcome this problem, several techniques have been proposed in which  
    339 the numerical schemes of the ocean model are modified \citep{Weaver_Eby_JPO97,  
    340 Griffies_al_JPO98}. Here, another strategy has been chosen \citep{Lazar_PhD97}:  
    341 a local filtering of the iso-neutral slopes (made on 9 grid-points) prevents  
    342 the development of grid point noise generated by the iso-neutral diffusion  
    343 operator (Fig.~\ref{Fig_LDF_ZDF1}). This allows an iso-neutral diffusion scheme  
    344 without additional background horizontal mixing. This technique can be viewed  
    345 as a diffusion operator that acts along large-scale (2~$\Delta$x)  
    346 \gmcomment{2deltax doesnt seem very large scale}  
    347 iso-neutral surfaces. The diapycnal diffusion required for numerical stability is  
    348 thus minimized and its net effect on the flow is quite small when compared to  
    349 the effect of an horizontal background mixing.  
     338This implementation is a rather old one. It is similar to the one 
     339proposed by Cox [1987], except for the background horizontal 
     340diffusion. Indeed, the Cox implementation of isopycnal diffusion in 
     341GFDL-type models requires a minimum background horizontal diffusion 
     342for numerical stability reasons.  To overcome this problem, several 
     343techniques have been proposed in which the numerical schemes of the 
     344ocean model are modified \citep{Weaver_Eby_JPO97, 
     345  Griffies_al_JPO98}. Griffies's scheme is now available in \NEMO if 
     346\np{traldf\_grif\_iso} is set true; see Appdx \ref{sec:triad}. Here, 
     347another strategy is presented \citep{Lazar_PhD97}: a local 
     348filtering of the iso-neutral slopes (made on 9 grid-points) prevents 
     349the development of grid point noise generated by the iso-neutral 
     350diffusion operator (Fig.~\ref{Fig_LDF_ZDF1}). This allows an 
     351iso-neutral diffusion scheme without additional background horizontal 
     352mixing. This technique can be viewed as a diffusion operator that acts 
     353along large-scale (2~$\Delta$x) \gmcomment{2deltax doesnt seem very 
     354  large scale} iso-neutral surfaces. The diapycnal diffusion required 
     355for numerical stability is thus minimized and its net effect on the 
     356flow is quite small when compared to the effect of an horizontal 
     357background mixing. 
    350358 
    351359Nevertheless, this iso-neutral operator does not ensure that variance cannot increase,  
     
    369377 
    370378 
    371 In addition and also for numerical stability reasons \citep{Cox1987, Griffies_Bk04},  
    372 the slopes are bounded by $1/100$ everywhere. This limit is decreasing linearly  
    373 to zero fom $70$ meters depth and the surface (the fact that the eddies "feel" the  
    374 surface motivates this flattening of isopycnals near the surface). 
     379% In addition and also for numerical stability reasons \citep{Cox1987, Griffies_Bk04},  
     380% the slopes are bounded by $1/100$ everywhere. This limit is decreasing linearly  
     381% to zero fom $70$ meters depth and the surface (the fact that the eddies "feel" the  
     382% surface motivates this flattening of isopycnals near the surface). 
    375383 
    376384For numerical stability reasons \citep{Cox1987, Griffies_Bk04}, the slopes must also  
  • trunk/DOC/TexFiles/Chapters/Chap_MISC.tex

    • Property svn:executable deleted
    r2541 r3294  
    253253Note this implementation may be sensitive to the optimization level.  
    254254 
     255\subsection{MPP scalability} 
     256\label{MISC_mppsca} 
     257 
     258The default method of communicating values across the north-fold in distributed memory applications 
     259(\key{mpp\_mpi}) uses a \textsc{MPI\_ALLGATHER} function to exchange values from each processing 
     260region in the northern row with every other processing region in the northern row. This enables a 
     261global width array containing the top 4 rows to be collated on every northern row processor and then 
     262folded with a simple algorithm. Although conceptually simple, this "All to All" communication will 
     263hamper performance scalability for large numbers of northern row processors. From version 3.4 
     264onwards an alternative method is available which only performs direct "Peer to Peer" communications 
     265between each processor and its immediate "neighbours" across the fold line. This is achieved by 
     266using the default \textsc{MPI\_ALLGATHER} method during initialisation to help identify the "active" 
     267neighbours. Stored lists of these neighbours are then used in all subsequent north-fold exchanges to 
     268restrict exchanges to those between associated regions. The collated global width array for each 
     269region is thus only partially filled but is guaranteed to be set at all the locations actually 
     270required by each individual for the fold operation. This alternative method should give identical 
     271results to the default \textsc{ALLGATHER} method and is recommended for large values of \np{jpni}. 
     272The new method is activated by setting \np{ln\_nnogather} to be true ({\bf nammpp}). The 
     273reproducibility of results using the two methods should be confirmed for each new, non-reference 
     274configuration. 
    255275 
    256276% ================================================================ 
  • trunk/DOC/TexFiles/Chapters/Chap_Model_Basics.tex

    • Property svn:executable deleted
    r2376 r3294  
    10941094% Lateral Diffusive and Viscous Operators Formulation 
    10951095% ------------------------------------------------------------------------------------------------------------- 
    1096 \subsection{Lateral Diffusive and Viscous Operators Formulation} 
     1096\subsection{Formulation of the Lateral Diffusive and Viscous Operators} 
    10971097\label{PE_ldf} 
    10981098 
     
    11341134 
    11351135In eddy-resolving configurations, a second order operator can be used, but  
    1136 usually a more scale selective one (biharmonic operator) is preferred as the  
     1136usually the more scale selective biharmonic operator is preferred as the  
    11371137grid-spacing is usually not small enough compared to the scale of the  
    11381138eddies. The role devoted to the subgrid-scale physics is to dissipate the  
    1139 energy that cascades toward the grid scale and thus ensures the stability of  
    1140 the model while not interfering with the solved mesoscale activity. Another approach  
     1139energy that cascades toward the grid scale and thus to ensure the stability of  
     1140the model while not interfering with the resolved mesoscale activity. Another approach  
    11411141is becoming more and more popular: instead of specifying explicitly a sub-grid scale  
    11421142term in the momentum and tracer time evolution equations, one uses a advective  
    11431143scheme which is diffusive enough to maintain the model stability. It must be emphasised 
    1144 that then, all the sub-grid scale physics is in this case include in the formulation of the 
     1144that then, all the sub-grid scale physics is included in the formulation of the 
    11451145advection scheme.  
    11461146 
    1147 All these parameterisations of subgrid scale physics present advantages and  
     1147All these parameterisations of subgrid scale physics have advantages and  
    11481148drawbacks. There are not all available in \NEMO. In the $z$-coordinate  
    11491149formulation, five options are offered for active tracers (temperature and  
     
    11571157operator acting along $s-$surfaces (see \S\ref{LDF}). 
    11581158 
    1159 \subsubsection{lateral second order tracer diffusive operator} 
     1159\subsubsection{Lateral second order tracer diffusive operator} 
    11601160 
    11611161The lateral second order tracer diffusive operator is defined by (see Appendix~\ref{Apdx_B}): 
     
    11861186 
    11871187For \textit{isoneutral} diffusion $r_1$ and $r_2$ are the slopes between the isoneutral  
    1188 and computational surfaces. Therefore, they have a same expression in $z$- and $s$-coordinates: 
     1188and computational surfaces. Therefore, they are different quantities, 
     1189but have similar expressions in $z$- and $s$-coordinates. In $z$-coordinates: 
    11891190\begin{equation} \label{Eq_PE_iso_slopes} 
    11901191r_1 =\frac{e_3 }{e_1 }  \left( {\frac{\partial \rho }{\partial i}} \right) 
    11911192                  \left( {\frac{\partial \rho }{\partial k}} \right)^{-1} \ , \quad 
    11921193r_1 =\frac{e_3 }{e_1 }  \left( {\frac{\partial \rho }{\partial i}} \right) 
    1193                   \left( {\frac{\partial \rho }{\partial k}} \right)^{-1} 
    1194 \end{equation} 
    1195  
    1196 When the \textit{Eddy Induced Velocity} parametrisation (eiv) \citep{Gent1990} is used,  
     1194                  \left( {\frac{\partial \rho }{\partial k}} \right)^{-1}, 
     1195\end{equation} 
     1196while in $s$-coordinates $\partial/\partial k$ is replaced by 
     1197$\partial/\partial s$. 
     1198 
     1199\subsubsection{Eddy induced velocity} 
     1200 When the \textit{eddy induced velocity} parametrisation (eiv) \citep{Gent1990} is used,  
    11971201an additional tracer advection is introduced in combination with the isoneutral diffusion of tracers: 
    11981202\begin{equation} \label{Eq_PE_iso+eiv} 
     
    12131217where $A^{eiv}$ is the eddy induced velocity coefficient (or equivalently the isoneutral  
    12141218thickness diffusivity coefficient), and $\tilde{r}_1$ and $\tilde{r}_2$ are the slopes  
    1215 between isoneutral and \emph{geopotential} surfaces and thus depends on the coordinate  
    1216 considered:  
     1219between isoneutral and \emph{geopotential} surfaces. Their values are 
     1220thus independent of the vertical coordinate, but their expression depends on the coordinate:  
    12171221\begin{align} \label{Eq_PE_slopes_eiv} 
    12181222\tilde{r}_n = \begin{cases} 
     
    12271231to zero in the vicinity of the boundaries. The latter strategy is used in \NEMO (cf. Chap.~\ref{LDF}). 
    12281232 
    1229 \subsubsection{lateral fourth order tracer diffusive operator} 
     1233\subsubsection{Lateral fourth order tracer diffusive operator} 
    12301234 
    12311235The lateral fourth order tracer diffusive operator is defined by: 
     
    12391243 
    12401244 
    1241 \subsubsection{lateral second order momentum diffusive operator} 
     1245\subsubsection{Lateral second order momentum diffusive operator} 
    12421246 
    12431247The second order momentum diffusive operator along $z$- or $s$-surfaces is found by  
  • trunk/DOC/TexFiles/Chapters/Chap_Model_Basics_zstar.tex

    • Property svn:executable deleted
  • trunk/DOC/TexFiles/Chapters/Chap_OBS.tex

    r2483 r3294  
    1313$\ $\newline    % force a new line 
    1414 
    15 The observation and model comparison code (OBS) reads in observation files 
    16 (profile temperature and salinity, sea surface temperature, sea level anomaly, 
    17 sea ice concentration, and velocity) and calculates  an interpolated model equivalent 
    18 value at the observation location and nearest model timestep. The OBS code is 
    19 called from \np{opa.F90} in order to initialise the model and to calculate the 
    20 model equivalent values for observations on the 0th timestep. The code is then 
    21 called again after each timestep from \np{step.F90}. The code was originally 
    22 developed for use with NEMOVAR.  
    23  
    24 For all data types a 2D horizontal  interpolator is needed 
    25 to interpolate the model fields to the observation location. 
    26 For {\em in situ} profiles, a 1D vertical interpolator is needed in addition to 
    27 provide model fields at the observation depths. Currently this only works in 
    28 z-level model configurations, but is being developed to work with a 
    29 generalised vertical coordinate system. 
    30 Temperature data from moored buoys (TAO, TRITON, PIRATA) in the 
    31 ENACT/ENSEMBLES data-base are available as daily averaged quantities. For this 
    32 type of observation the 
    33 observation operator will compare such observations to the model temperature 
     15The observation and model comparison code (OBS) reads in observation files (profile 
     16temperature and salinity, sea surface temperature, sea level anomaly, sea ice concentration, 
     17and velocity) and calculates  an interpolated model equivalent value at the observation 
     18location and nearest model timestep. The resulting data are saved in a ``feedback'' file (or 
     19files). The code was originally developed for use with the NEMOVAR data assimilation code, but 
     20can be used for validation or verification of model or  any other data assimilation system. 
     21 
     22The OBS code is called from \np{opa.F90} for model initialisation and to calculate the model 
     23equivalent values for observations on the 0th timestep. The code is then called again after 
     24each timestep from \np{step.F90}. To build with the OBS code active \key{diaobs} must be 
     25set. 
     26 
     27For all data types a 2D horizontal  interpolator is needed to interpolate the model fields to 
     28the observation location. For {\em in situ} profiles, a 1D vertical interpolator is needed in 
     29addition to provide model fields at the observation depths. Currently this only works in 
     30z-level model configurations, but is being developed to work with a generalised vertical 
     31coordinate system. Temperature data from moored buoys (TAO, TRITON, PIRATA) in the 
     32ENACT/ENSEMBLES data-base are available as daily averaged quantities. For this type of 
     33observation the observation operator will compare such observations to the model temperature 
    3434fields averaged over one day. The relevant observation type may be specified in the namelist 
    35 using \np{endailyavtypes}. Otherwise the model value from the nearest 
    36 timestep to the observation time is used. 
    37  
    38 The resulting data are saved in a ``feedback'' file (or files) which can be used 
    39 for model validation and verification and also to provide information for data 
    40 assimilation. This code is controlled by the namelist \textit{nam\_obs}. To 
    41 build with the OBS code active \key{diaobs} must be set. 
    42  
    43 Section~\ref{OBS_example} introduces a test example of the observation operator 
    44 code including where to obtain data and how to setup the namelist. 
    45 Section~\ref{OBS_details} introduces some more technical details of the 
    46 different observation types used and also shows a more complete namelist. 
    47 Finally section~\ref{OBS_theory} introduces some of the theoretical aspects of 
    48 the observation operator including interpolation methods and running on multiple 
    49 processors.  
     35using \np{endailyavtypes}. Otherwise the model value from the nearest timestep to the 
     36observation time is used. 
     37 
     38The code is controlled by the namelist \textit{nam\_obs}. See the following sections for more 
     39details on setting up the namelist.  
     40 
     41Section~\ref{OBS_example} introduces a test example of the observation operator code including 
     42where to obtain data and how to setup the namelist. Section~\ref{OBS_details} introduces some 
     43more technical details of the different observation types used and also shows a more complete 
     44namelist. Section~\ref{OBS_theory} introduces some of the theoretical aspects of the 
     45observation operator including interpolation methods and running on multiple processors. 
     46Section~\ref{OBS_obsutils} introduces some utilities to help working with the files produced 
     47by the OBS code. 
    5048 
    5149% ================================================================ 
     
    6967\item Add the following to the NEMO namelist to run the observation 
    7068operator on this data. Set the \np{enactfiles} namelist parameter to the 
    71 observation  file name (or link in to \np{profiles\_01\.nc}): 
     69observation  file name: 
    7270\end{enumerate} 
    7371 
     
    7674%------------------------------------------------------------------------------------------------------------- 
    7775 
    78 The option \np{ln\_t3d} and \np{ln\_s3d} switch on the temperature and salinity 
     76The options \np{ln\_t3d} and \np{ln\_s3d} switch on the temperature and salinity 
    7977profile observation operator code. The \np{ln\_ena} switch turns on the reading 
    8078of ENACT/ENSEMBLES type profile data. The filename or array of filenames are 
     
    8886Setting \np{ln\_grid\_global} means that the code distributes the observations 
    8987evenly between processors. Alternatively each processor will work with 
    90 observations located within the model subdomain. 
    91  
    92 The NEMOVAR system contains utilities to plot the feedback files, convert and 
    93 recombine the files. These are available on request from the NEMOVAR team. 
     88observations located within the model subdomain (see section~\ref{OBS_parallel}). 
     89 
     90A number of utilities are now provided to plot the feedback files, convert and 
     91recombine the files. These are explained in more detail in section~\ref{OBS_obsutils}. 
    9492 
    9593\section{Technical details} 
     
    713711 
    714712\subsection{Parallel aspects of horizontal interpolation} 
     713\label{OBS_parallel} 
    715714 
    716715For horizontal interpolation, there is the basic problem that the 
     
    779778\subsection{Vertical interpolation operator} 
    780779 
    781 The vertical interpolation is achieved using either a cubic spline or 
     780Vertical interpolation is achieved using either a cubic spline or 
    782781linear interpolation. For the cubic spline, the top and 
    783782bottom boundary conditions for the second derivative of the  
    784783interpolating polynomial in the spline are set to zero. 
    785784At the bottom boundary, this is done using the land-ocean mask. 
     785 
     786\newpage 
     787 
     788\section{Observation Utilities} 
     789\label{OBS_obsutils} 
     790 
     791Some tools for viewing and processing of observation and feedback files are provided in the 
     792NEMO repository for convenience. These include OBSTOOLS which are a collection of Fortran 
     793programs which are helpful to deal with feedback files. They do such tasks as observation file 
     794conversion, printing of file contents, some basic statistical analysis of feedback files. The 
     795other tool is an IDL program called dataplot which uses a graphical interface to visualise 
     796observations and feedback files. OBSTOOLS and dataplot are described in more detail below.   
     797 
     798\subsection{Obstools} 
     799 
     800A series of Fortran utilities is provided with NEMO called OBSTOOLS. This are helpful in 
     801handling observation files and the feedback file output from the NEMO observation operator. 
     802The utilities are as follows 
     803 
     804\subsubsection{corio2fb} 
     805 
     806The program corio2fb converts profile observation files from the Coriolis format to the 
     807standard feedback format. The program is called in the following way: 
     808 
     809\begin{alltt} 
     810\footnotesize 
     811\begin{verbatim} 
     812corio2fb.exe outputfile inputfile1 inputfile2 ... 
     813\end{verbatim} 
     814\end{alltt} 
     815 
     816\subsubsection{enact2fb} 
     817 
     818The program enact2fb converts profile observation files from the ENACT format to the standard 
     819feedback format. The program is called in the following way: 
     820 
     821\begin{alltt} 
     822\footnotesize 
     823\begin{verbatim} 
     824enact2fb.exe outputfile inputfile1 inputfile2 ... 
     825\end{verbatim} 
     826\end{alltt} 
     827 
     828\subsubsection{fbcomb} 
     829 
     830The program fbcomb combines multiple feedback files produced by individual processors in an 
     831MPI run of NEMO into a single feedback file. The program is called in the following way: 
     832 
     833\begin{alltt} 
     834\footnotesize 
     835\begin{verbatim} 
     836fbcomb.exe outputfile inputfile1 inputfile2 ... 
     837\end{verbatim} 
     838\end{alltt} 
     839 
     840\subsubsection{fbmatchup} 
     841 
     842The program fbmatchup will match observations from two feedback files. The program is called 
     843in the following way: 
     844 
     845\begin{alltt} 
     846\footnotesize 
     847\begin{verbatim} 
     848fbmatchup.exe outputfile inputfile1 varname1 inputfile2 varname2 ... 
     849\end{verbatim} 
     850\end{alltt} 
     851 
     852 
     853\subsubsection{fbprint} 
     854 
     855The program fbprint will print the contents of a feedback file or files to standard output. 
     856Selected information can be output using optional arguments. The program is called in the 
     857following way: 
     858 
     859\begin{alltt} 
     860\footnotesize 
     861\begin{verbatim} 
     862fbprint.exe [options] inputfile 
     863 
     864options: 
     865     -b            shorter output 
     866     -q            Select observations based on QC flags 
     867     -Q            Select observations based on QC flags 
     868     -B            Select observations based on QC flags 
     869     -u            unsorted 
     870     -s ID         select station ID   
     871     -t TYPE       select observation type 
     872     -v NUM1-NUM2  select variable range to print by number  
     873                      (default all) 
     874     -a NUM1-NUM2  select additional variable range to print by number  
     875                      (default all) 
     876     -e NUM1-NUM2  select extra variable range to print by number  
     877                      (default all) 
     878     -d            output date range 
     879     -D            print depths 
     880     -z            use zipped files 
     881\end{verbatim} 
     882\end{alltt} 
     883 
     884\subsubsection{fbsel} 
     885 
     886The program fbsel will select or subsample observations. The program is called in the 
     887following way: 
     888 
     889\begin{alltt} 
     890\footnotesize 
     891\begin{verbatim} 
     892fbsel.exe <input filename> <output filename> 
     893\end{verbatim} 
     894\end{alltt} 
     895 
     896\subsubsection{fbstat} 
     897 
     898The program fbstat will output summary statistics in different global areas into a number of 
     899files. The program is called in the following way: 
     900 
     901\begin{alltt} 
     902\footnotesize 
     903\begin{verbatim} 
     904fbstat.exe [-nmlev] <filenames> 
     905\end{verbatim} 
     906\end{alltt} 
     907 
     908\subsubsection{fbthin} 
     909 
     910The program fbthin will thin the data to 1 degree resolution. The code could easily be 
     911modified to thin to a different resolution. The program is called in the following way: 
     912 
     913\begin{alltt} 
     914\footnotesize 
     915\begin{verbatim} 
     916fbthin.exe inputfile outputfile 
     917\end{verbatim} 
     918\end{alltt} 
     919 
     920\subsubsection{sla2fb} 
     921 
     922The program sla2fb will convert an AVISO SLA format file to feedback format. The program is 
     923called in the following way: 
     924 
     925\begin{alltt} 
     926\footnotesize 
     927\begin{verbatim} 
     928sla2fb.exe [-s type] outputfile inputfile1 inputfile2 ... 
     929 
     930Option: 
     931     -s            Select altimeter data_source 
     932\end{verbatim} 
     933\end{alltt} 
     934 
     935\subsubsection{vel2fb} 
     936 
     937The program vel2fb will convert TAO/PIRATA/RAMA currents files to feedback format. The program 
     938is called in the following way: 
     939 
     940\begin{alltt} 
     941\footnotesize 
     942\begin{verbatim} 
     943vel2fb.exe outputfile inputfile1 inputfile2 ... 
     944\end{verbatim} 
     945\end{alltt} 
     946 
     947\subsection{building the obstools} 
     948 
     949To build the obstools use in the tools directory use ./maketools -n OBSTOOLS -m [ARCH]. 
     950 
     951\subsection{Dataplot} 
     952 
     953An IDL program called dataplot is included which uses a graphical interface to visualise 
     954observations and feedback files. It is possible to zoom in, plot individual profiles and 
     955calculate some basic statistics. To plot some data run IDL and then: 
     956\begin{alltt} 
     957\footnotesize 
     958\begin{verbatim} 
     959IDL> dataplot, "filename" 
     960\end{verbatim} 
     961\end{alltt} 
     962 
     963To read multiple files into dataplot, for example multiple feedback files from different 
     964processors or from different days, the easiest method is to use the spawn command to generate 
     965a list of files which can then be passed to dataplot. 
     966\begin{alltt} 
     967\footnotesize 
     968\begin{verbatim} 
     969IDL> spawn, 'ls profb*.nc', files 
     970IDL> dataplot, files 
     971\end{verbatim} 
     972\end{alltt} 
     973 
     974Fig~\ref{fig:obsdataplotmain} shows the main window which is launched when dataplot starts. 
     975This is split into three parts. At the top there is a menu bar which contains a variety of 
     976drop down menus. Areas - zooms into prespecified regions; plot - plots the data as a 
     977timeseries or a T-S diagram if appropriate; Find - allows data to be searched; Config - sets 
     978various configuration options. 
     979 
     980The middle part is a plot of the geographical location of the observations. This will plot the 
     981observation value, the model background value or observation minus background value depending 
     982on the option selected in the radio button at the bottom of the window. The plotting colour 
     983range can be changed by clicking on the colour bar. The title of the plot gives some basic 
     984information about the date range and depth range shown, the extreme values, and the mean and 
     985rms values. It is possible to zoom in using a drag-box. You may also zoom in or out using the 
     986mouse wheel. 
     987 
     988The bottom part of the window controls what is visible in the plot above. There are two bars 
     989which select the level range plotted (for profile data). The other bars below select the date 
     990range shown. The bottom of the figure allows the option to plot the mean, root mean square, 
     991standard deviation or mean square values. As mentioned above you can choose to plot the 
     992observation value, the model background value or observation minus background value. The next 
     993group of radio buttons selects the map projection. This can either be regular latitude 
     994longitude grid, or north or south polar stereographic. The next group of radio buttons will 
     995plot bad observations, switch to salinity and plot density for profile observations. The 
     996rightmost group of buttons will print the plot window as a postscript, save it as png, or exit 
     997from dataplot. 
     998 
     999%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     1000\begin{figure}     \begin{center} 
     1001%\includegraphics[width=10cm,height=12cm,angle=-90.]{./TexFiles/Figures/Fig_OBS_dataplot_main} 
     1002\includegraphics[width=9cm,angle=-90.]{./TexFiles/Figures/Fig_OBS_dataplot_main} 
     1003\caption{      \label{fig:obsdataplotmain} 
     1004Main window of dataplot.} 
     1005\end{center}     \end{figure} 
     1006%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     1007 
     1008If a profile point is clicked with the mouse button a plot of the observation and background 
     1009values as a function of depth (Fig~\ref{fig:obsdataplotprofile}). 
     1010 
     1011%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     1012\begin{figure}     \begin{center} 
     1013%\includegraphics[width=10cm,height=12cm,angle=-90.]{./TexFiles/Figures/Fig_OBS_dataplot_prof} 
     1014\includegraphics[width=7cm,angle=-90.]{./TexFiles/Figures/Fig_OBS_dataplot_prof} 
     1015\caption{      \label{fig:obsdataplotprofile} 
     1016Profile plot from dataplot produced by right clicking on a point in the main window.} 
     1017\end{center}     \end{figure} 
     1018%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     1019 
     1020 
     1021 
     1022 
  • trunk/DOC/TexFiles/Chapters/Chap_SBC.tex

    • Property svn:executable deleted
    r2541 r3294  
    2424\end{itemize} 
    2525 
    26 Four different ways to provide the first six fields to the ocean are available which  
     26Five different ways to provide the first six fields to the ocean are available which  
    2727are controlled by namelist variables: an analytical formulation (\np{ln\_ana}~=~true),  
    2828a flux formulation (\np{ln\_flx}~=~true), a bulk formulae formulation (CORE  
    29 (\np{ln\_core}~=~true) or CLIO (\np{ln\_clio}~=~true) bulk formulae) and a coupled  
     29(\np{ln\_core}~=~true), CLIO (\np{ln\_clio}~=~true) or MFS 
     30\footnote { Note that MFS bulk formulae compute fluxes only for the ocean component} 
     31(\np{ln\_mfs}~=~true) bulk formulae) and a coupled  
    3032formulation (exchanges with a atmospheric model via the OASIS coupler)  
    3133(\np{ln\_cpl}~=~true). When used, the atmospheric pressure forces both  
    32 ocean and ice dynamics (\np{ln\_apr\_dyn}~=~true) 
    33 \footnote{The surface pressure field could be use in bulk formulae, nevertheless  
    34 none of the current bulk formulea (CLIO and CORE) uses the it.}.  
     34ocean and ice dynamics (\np{ln\_apr\_dyn}~=~true). 
    3535The frequency at which the six or seven fields have to be updated is the \np{nn\_fsbc}  
    3636namelist parameter.  
     
    4646(\np{nn\_ice}~=~0,1, 2 or 3); the addition of river runoffs as surface freshwater  
    4747fluxes or lateral inflow (\np{ln\_rnf}~=~true); the addition of a freshwater flux adjustment  
    48 in order to avoid a mean sea-level drift (\np{nn\_fwb}~=~0,~1~or~2); and the  
     48in order to avoid a mean sea-level drift (\np{nn\_fwb}~=~0,~1~or~2); the  
    4949transformation of the solar radiation (if provided as daily mean) into a diurnal  
    50 cycle (\np{ln\_dm2dc}~=~true). 
     50cycle (\np{ln\_dm2dc}~=~true); and a neutral drag coefficient can be read from an external wave  
     51model (\np{ln\_cdgw}~=~true). The latter option is possible only in case core or mfs bulk formulas are selected. 
    5152 
    5253In this chapter, we first discuss where the surface boundary condition appears in the 
    53 model equations. Then we present the four ways of providing the surface boundary condition,  
     54model equations. Then we present the five ways of providing the surface boundary condition,  
    5455followed by the description of the atmospheric pressure and the river runoff.  
    5556Next the scheme for interpolation on the fly is described. 
     
    245246actual year/month/day, always coded with 4 or 2 digits. Note that (1) in mpp, if the file is split  
    246247over each subdomain, the suffix '.nc' is replaced by '\_PPPP.nc', where 'PPPP' is the  
    247 process number coded with 4 digits; (2) when using AGRIF, the prefix ÔN\_Õ is added to files,  
     248process number coded with 4 digits; (2) when using AGRIF, the prefix 
     249'\_N' is added to files,  
    248250where 'N'  is the child grid number.} 
    249251\end{table} 
     
    480482% Bulk formulation 
    481483% ================================================================ 
    482 \section  [Bulk formulation (\textit{sbcblk\_core} or \textit{sbcblk\_clio}) ] 
    483       {Bulk formulation \small{(\mdl{sbcblk\_core} or \mdl{sbcblk\_clio} module)} } 
     484\section  [Bulk formulation (\textit{sbcblk\_core}, \textit{sbcblk\_clio} or \textit{sbcblk\_mfs}) ] 
     485      {Bulk formulation \small{(\mdl{sbcblk\_core} \mdl{sbcblk\_clio} \mdl{sbcblk\_mfs} modules)} } 
    484486\label{SBC_blk} 
    485487 
     
    487489using bulk formulae and atmospheric fields and ocean (and ice) variables.  
    488490 
    489 The atmospheric fields used depend on the bulk formulae used. Two bulk formulations  
    490 are available : the CORE and CLIO bulk formulea. The choice is made by setting to true 
    491 one of the following namelist variable : \np{ln\_core} and \np{ln\_clio}. 
    492  
    493 Note : in forced mode, when a sea-ice model is used, a bulk formulation have to be used.  
    494 Therefore the two bulk formulea provided include the computation of the fluxes over both  
     491The atmospheric fields used depend on the bulk formulae used. Three bulk formulations  
     492are available : the CORE, the CLIO and the MFS bulk formulea. The choice is made by setting to true 
     493one of the following namelist variable : \np{ln\_core} ; \np{ln\_clio} or  \np{ln\_mfs}. 
     494 
     495Note : in forced mode, when a sea-ice model is used, a bulk formulation (CLIO or CORE) have to be used.  
     496Therefore the two bulk (CLIO and CORE) formulea include the computation of the fluxes over both  
    495497an ocean and an ice surface.  
    496498 
     
    583585namelist (see \S\ref{SBC_fldread}).  
    584586 
     587% ------------------------------------------------------------------------------------------------------------- 
     588%        MFS Bulk formulae 
     589% ------------------------------------------------------------------------------------------------------------- 
     590\subsection    [MFS Bulk formulea (\np{ln\_mfs}=true)] 
     591            {MFS Bulk formulea (\np{ln\_mfs}=true, \mdl{sbcblk\_mfs})} 
     592\label{SBC_blk_mfs} 
     593%------------------------------------------namsbc_mfs---------------------------------------------------- 
     594\namdisplay{namsbc_mfs}  
     595%---------------------------------------------------------------------------------------------------------- 
     596 
     597The MFS (Mediterranean Forecasting System) bulk formulae have been developed by 
     598 \citet{Castellari_al_JMS1998}.  
     599They have been designed to handle the ECMWF operational data and are currently  
     600in use in the MFS operational system \citep{Tonani_al_OS08}, \citep{Oddo_al_OS09}. 
     601The wind stress computation uses a drag coefficient computed according to \citet{Hellerman_Rosenstein_JPO83}. 
     602The surface boundary condition for temperature involves the balance between surface solar radiation, 
     603net long-wave radiation, the latent and sensible heat fluxes. 
     604Solar radiation is dependent on cloud cover and is computed by means of 
     605an astronomical formula \citep{Reed_JPO77}. Albedo monthly values are from \citet{Payne_JAS72}  
     606as means of the values at $40^{o}N$ and $30^{o}N$ for the Atlantic Ocean (hence the same latitudinal 
     607band of the Mediterranean Sea). The net long-wave radiation flux 
     608\citep{Bignami_al_JGR95} is a function of 
     609air temperature, sea-surface temperature, cloud cover and relative humidity. 
     610Sensible heat and latent heat fluxes are computed by classical 
     611bulk formulae parameterized according to \citet{Kondo1975}. 
     612Details on the bulk formulae used can be found in \citet{Maggiore_al_PCE98} and \citet{Castellari_al_JMS1998}. 
     613 
     614The required 7 input fields must be provided on the model Grid-T and  are: 
     615\begin{itemize} 
     616\item          Zonal Component of the 10m wind ($ms^{-1}$)  (\np{sn\_windi}) 
     617\item          Meridional Component of the 10m wind ($ms^{-1}$)  (\np{sn\_windj}) 
     618\item          Total Claud Cover (\%)  (\np{sn\_clc}) 
     619\item          2m Air Temperature ($K$) (\np{sn\_tair}) 
     620\item          2m Dew Point Temperature ($K$)  (\np{sn\_rhm}) 
     621\item          Total Precipitation ${Kg} m^{-2} s^{-1}$ (\np{sn\_prec}) 
     622\item          Mean Sea Level Pressure (${Pa}$) (\np{sn\_msl}) 
     623\end{itemize} 
     624% ------------------------------------------------------------------------------------------------------------- 
    585625% ================================================================ 
    586626% Coupled formulation 
     
    602642\footnote{The \key{oasis4} exist. It activates portion of the code that are still under development.}.  
    603643It has been successfully used to interface \NEMO to most of the European atmospheric  
    604 GCM (ARPEGE, ECHAM, ECMWF, HadAM, LMDz),  
     644GCM (ARPEGE, ECHAM, ECMWF, HadAM, HadGAM, LMDz),  
    605645as well as to \href{http://wrf-model.org/}{WRF} (Weather Research and Forecasting Model). 
    606646 
     
    610650When PISCES biogeochemical model (\key{top} and \key{pisces}) is also used in the coupled system,  
    611651the whole carbon cycle is computed by defining \key{cpl\_carbon\_cycle}. In this case,  
    612 CO$_2$ fluxes are exchanged between the atmosphere and the ice-ocean system. 
     652CO$_2$ fluxes will be exchanged between the atmosphere and the ice-ocean system (and need to be activated 
     653in namsbc{\_}cpl). 
     654 
     655The new namelist above allows control of various aspects of the coupling fields (particularly for 
     656vectors) and now allows for any coupling fields to have multiple sea ice categories (as required by LIM3 
     657and CICE).  When indicating a multi-category coupling field in namsbc{\_}cpl the number of categories will be 
     658determined by the number used in the sea ice model.  In some limited cases it may be possible to specify  
     659single category coupling fields even when the sea ice model is running with multiple categories - in this 
     660case the user should examine the code to be sure the assumptions made are satisfactory.  In cases where 
     661this is definitely not possible the model should abort with an error message.  The new code has been tested using 
     662ECHAM with LIM2, and HadGAM3 with CICE but although it will compile with \key{lim3} additional minor code changes 
     663may be required to run using LIM3. 
    613664 
    614665 
     
    645696 
    646697% ================================================================ 
     698%        Tidal Potential 
     699% ================================================================ 
     700\section   [Tidal Potential (\textit{sbctide})] 
     701                        {Tidal Potential (\mdl{sbctide})} 
     702\label{SBC_tide} 
     703 
     704A module is available to use the tidal potential forcing and is activated with with \key{tide}. 
     705 
     706 
     707%------------------------------------------nam_tide---------------------------------------------------- 
     708\namdisplay{nam_tide} 
     709%------------------------------------------------------------------------------------------------------------- 
     710 
     711Concerning the tidal potential, some parameters are available in namelist: 
     712 
     713- \texttt{ln\_tide\_pot} activate the tidal potential forcing 
     714 
     715- \texttt{nb\_harmo} is the number of constituent used 
     716 
     717- \texttt{clname} is the name of constituent 
     718 
     719 
     720The tide is generated by the forces of gravity ot the Earth-Moon and Earth-Sun sytem; 
     721they are expressed as the gradient of the astronomical potential ($\vec{\nabla}\Pi_{a}$). \\ 
     722 
     723The potential astronomical expressed, for the three types of tidal frequencies 
     724following, by : \\ 
     725Tide long period : 
     726\begin{equation} 
     727\Pi_{a}=gA_{k}(\frac{1}{2}-\frac{3}{2}sin^{2}\phi)cos(\omega_{k}t+V_{0k}) 
     728\end{equation} 
     729diurnal Tide : 
     730\begin{equation} 
     731\Pi_{a}=gA_{k}(sin 2\phi)cos(\omega_{k}t+\lambda+V_{0k}) 
     732\end{equation} 
     733Semi-diurnal tide: 
     734\begin{equation} 
     735\Pi_{a}=gA_{k}(cos^{2}\phi)cos(\omega_{k}t+2\lambda+V_{0k}) 
     736\end{equation} 
     737 
     738 
     739$A_{k}$ is the amplitude of the wave k, $\omega_{k}$ the pulsation of the wave k, $V_{0k}$ the astronomical phase of the wave 
     740$k$ to Greenwich. 
     741 
     742We make corrections to the astronomical potential. 
     743We obtain :  
     744\begin{equation} 
     745\Pi-g\delta = (1+k-h) \Pi_{A}(\lambda,\phi) 
     746\end{equation} 
     747with $k$ a number of Love estimated to 0.6 which parametrized the astronomical tidal land, 
     748and $h$ a number of Love to 0.3 which parametrized the parametrization due to the astronomical tidal land. 
     749 
     750% ================================================================ 
    647751%        River runoffs 
    648752% ================================================================ 
     
    759863%To do this we need to treat evaporation/precipitation fluxes and river runoff differently in the tra_sbc module.  We decided to separate them throughout the code, so that the variable emp represented solely evaporation minus precipitation fluxes, and a new 2d variable rnf was added which represents the volume flux of river runoff (in kg/m2s to remain consistent with emp).  This meant many uses of emp and emps needed to be changed, a list of all modules which use emp or emps and the changes made are below: 
    760864 
    761 } 
     865%} 
    762866 
    763867% ================================================================ 
     
    9091013ice-ocean fluxes, that are combined with the air-sea fluxes using the ice fraction of  
    9101014each model cell to provide the surface ocean fluxes. Note that the activation of a  
    911 sea-ice model is is done by defining a CPP key (\key{lim2} or \key{lim3}).  
    912 The activation automatically ovewrite the read value of nn{\_}ice to its appropriate  
    913 value ($i.e.$ $2$ for LIM-2 and $3$ for LIM-3). 
     1015sea-ice model is is done by defining a CPP key (\key{lim2}, \key{lim3} or \key{cice}).  
     1016The activation automatically overwrites the read value of nn{\_}ice to its appropriate  
     1017value ($i.e.$ $2$ for LIM-2, $3$ for LIM-3 or $4$ for CICE). 
    9141018\end{description} 
    9151019 
    9161020% {Description of Ice-ocean interface to be added here or in LIM 2 and 3 doc ?} 
     1021 
     1022\subsection   [Interface to CICE (\textit{sbcice\_cice})] 
     1023         {Interface to CICE (\mdl{sbcice\_cice})} 
     1024\label{SBC_cice} 
     1025 
     1026It is now possible to couple a global NEMO configuration (without AGRIF) to the CICE sea-ice 
     1027model by using \key{cice}.  The CICE code can be obtained from  
     1028\href{http://oceans11.lanl.gov/trac/CICE/}{LANL} and the additional 'hadgem3' drivers will be required,  
     1029even with the latest code release.  Input grid files consistent with those used in NEMO will also be needed,  
     1030and CICE CPP keys \textbf{ORCA\_GRID}, \textbf{CICE\_IN\_NEMO} and \textbf{coupled} should be used (seek advice from UKMO  
     1031if necessary).  Currently the code is only designed to work when using the CORE forcing option for NEMO (with 
     1032\textit{calc\_strair~=~true} and \textit{calc\_Tsfc~=~true} in the CICE name-list), or alternatively when NEMO  
     1033is coupled to the HadGAM3 atmosphere model (with \textit{calc\_strair~=~false} and \textit{calc\_Tsfc~=~false}). 
     1034The code is intended to be used with \np{nn\_fsbc} set to 1 (although coupling ocean and ice less frequently  
     1035should work, it is possible the calculation of some of the ocean-ice fluxes needs to be modified slightly - the 
     1036user should check that results are not significantly different to the standard case). 
     1037 
     1038There are two options for the technical coupling between NEMO and CICE.  The standard version allows 
     1039complete flexibility for the domain decompositions in the individual models, but this is at the expense of global 
     1040gather and scatter operations in the coupling which become very expensive on larger numbers of processors. The 
     1041alternative option (using \key{nemocice\_decomp} for both NEMO and CICE) ensures that the domain decomposition is 
     1042identical in both models (provided domain parameters are set appropriately, and  
     1043\textit{processor\_shape~=~square-ice} and \textit{distribution\_wght~=~block} in the CICE name-list) and allows 
     1044much more efficient direct coupling on individual processors.  This solution scales much better although it is at  
     1045the expense of having more idle CICE processors in areas where there is no sea ice. 
     1046 
    9171047 
    9181048% ------------------------------------------------------------------------------------------------------------- 
     
    9381068\end{description} 
    9391069 
     1070% ------------------------------------------------------------------------------------------------------------- 
     1071%        Neutral Drag Coefficient from external wave model 
     1072% ------------------------------------------------------------------------------------------------------------- 
     1073\subsection   [Neutral drag coefficient from external wave model (\textit{sbcwave})] 
     1074                        {Neutral drag coefficient from external wave model (\mdl{sbcwave})} 
     1075\label{SBC_wave} 
     1076%------------------------------------------namwave---------------------------------------------------- 
     1077\namdisplay{namsbc_wave} 
     1078%------------------------------------------------------------------------------------------------------------- 
     1079\begin{description} 
     1080 
     1081\item [??] In order to read a neutral drag coeff, from an external data source (i.e. a wave model), the  
     1082logical variable \np{ln\_cdgw} 
     1083 in $namsbc$ namelist must be defined ${.true.}$.  
     1084The \mdl{sbcwave} module containing the routine \np{sbc\_wave} reads the 
     1085namelist ${namsbc\_wave}$ (for external data names, locations, frequency, interpolation and all  
     1086the miscellanous options allowed by Input Data generic Interface see \S\ref{SBC_input})  
     1087and a 2D field of neutral drag coefficient. Then using the routine  
     1088TURB\_CORE\_1Z or TURB\_CORE\_2Z, and starting from the neutral drag coefficent provided, the drag coefficient is computed according  
     1089to stable/unstable conditions of the air-sea interface following \citet{Large_Yeager_Rep04}. 
     1090 
     1091\end{description} 
     1092 
    9401093% Griffies doc: 
    9411094% When running ocean-ice simulations, we are not explicitly representing land processes, such as rivers, catchment areas, snow accumulation, etc. However, to reduce model drift, it is important to balance the hydrological cycle in ocean-ice models. We thus need to prescribe some form of global normalization to the precipitation minus evaporation plus river runoff. The result of the normalization should be a global integrated zero net water input to the ocean-ice system over a chosen time scale.  
     
    9441097 
    9451098 
    946  
  • trunk/DOC/TexFiles/Chapters/Chap_STP.tex

    • Property svn:executable deleted
  • trunk/DOC/TexFiles/Chapters/Chap_TRA.tex

    • Property svn:executable deleted
    r2541 r3294  
    491491\label{TRA_ldf_iso} 
    492492 
    493 The general form of the second order lateral tracer subgrid scale physics  
     493If the Griffies trad scheme is not employed 
     494(\np{ln\_traldf\_grif}=true; see App.\ref{sec:triad}) the general form of the second order lateral tracer subgrid scale physics  
    494495(\ref{Eq_PE_zdf}) takes the following semi-discrete space form in $z$- and  
    495496$s$-coordinates: 
     
    536537(see \S\ref{LDF}) allows the model to run safely without any additional  
    537538background horizontal diffusion \citep{Guilyardi_al_CD01}. An alternative scheme  
    538 developed by \cite{Griffies_al_JPO98} which preserves both tracer and its variance  
     539developed by \cite{Griffies_al_JPO98} which ensures tracer variance decreases  
    539540is also available in \NEMO (\np{ln\_traldf\_grif}=true). A complete description of  
    540 the algorithm is given in App.\ref{Apdx_Griffies}. 
     541the algorithm is given in App.\ref{sec:triad}. 
    541542 
    542543Note that in the partial step $z$-coordinate (\np{ln\_zps}=true), the horizontal  
     
    10531054%--------------------------------------------namtra_dmp------------------------------------------------- 
    10541055\namdisplay{namtra_dmp} 
    1055 \namdisplay{namdta_tem} 
    1056 \namdisplay{namdta_sal} 
    10571056%-------------------------------------------------------------------------------------------------------------- 
    10581057 
     
    10671066where $\gamma$ is the inverse of a time scale, and $T_o$ and $S_o$  
    10681067are given temperature and salinity fields (usually a climatology).  
    1069 The restoring term is added when \key{tradmp} is defined.  
    1070 It also requires that both \key{dtatem} and \key{dtasal} are defined  
    1071 and fill in \textit{namdta\_tem} and \textit{namdta\_sal namelists}  
    1072 ($i.e.$ that $T_o$ and $S_o$ are read using \mdl{fldread},  
    1073 see \S\ref{SBC_fldread}). The restoring coefficient $\gamma$ is  
    1074 a three-dimensional array initialized by the user in routine \rou{dtacof}  
    1075 also located in module \mdl{tradmp}.  
     1068The restoring term is added when the namelist parameter \np{ln\_tradmp} is set to true.  
     1069It also requires that both \np{ln\_tsd\_init} and \np{ln\_tsd\_tradmp} are set to true 
     1070in \textit{namtsd} namelist as well as \np{sn\_tem} and \np{sn\_sal} structures are  
     1071correctly set  ($i.e.$ that $T_o$ and $S_o$ are provided in input files and read  
     1072using \mdl{fldread}, see \S\ref{SBC_fldread}).  
     1073The restoring coefficient $\gamma$ is a three-dimensional array initialized by the  
     1074user in routine \rou{dtacof} also located in module \mdl{tradmp}.  
    10761075 
    10771076The two main cases in which \eqref{Eq_tra_dmp} is used are \textit{(a)}  
  • trunk/DOC/TexFiles/Chapters/Chap_ZDF.tex

    • Property svn:executable deleted
    r2541 r3294  
    11% ================================================================ 
    2 % Chapter Ñ Vertical Ocean Physics (ZDF) 
     2% Chapter Vertical Ocean Physics (ZDF) 
    33% ================================================================ 
    44\chapter{Vertical Ocean Physics (ZDF)} 
     
    100100$a=5$ and $n=2$. The last three values can be modified by setting the  
    101101\np{rn\_avmri}, \np{rn\_alp} and \np{nn\_ric} namelist parameters, respectively. 
     102 
     103A simple mixing-layer model to transfer and dissipate the atmospheric 
     104 forcings (wind-stress and buoyancy fluxes) can be activated setting  
     105the \np{ln\_mldw} =.true. in the namelist. 
     106 
     107In this case, the local depth of turbulent wind-mixing or "Ekman depth" 
     108 $h_{e}(x,y,t)$ is evaluated and the vertical eddy coefficients prescribed within this layer. 
     109 
     110This depth is assumed proportional to the "depth of frictional influence" that is limited by rotation: 
     111\begin{equation} 
     112         h_{e} = Ek \frac {u^{*}} {f_{0}}    \\ 
     113\end{equation} 
     114where, $Ek$ is an empirical parameter, $u^{*}$ is the friction velocity and $f_{0}$ is the Coriolis  
     115parameter. 
     116 
     117In this similarity height relationship, the turbulent friction velocity: 
     118\begin{equation} 
     119         u^{*} = \sqrt \frac {|\tau|} {\rho_o}     \\ 
     120\end{equation} 
     121 
     122is computed from the wind stress vector $|\tau|$ and the reference dendity $ \rho_o$. 
     123The final $h_{e}$ is further constrained by the adjustable bounds \np{rn\_mldmin} and \np{rn\_mldmax}. 
     124Once $h_{e}$ is computed, the vertical eddy coefficients within $h_{e}$ are set to  
     125the empirical values \np{rn\_wtmix} and \np{rn\_wvmix} \citep{Lermusiaux2001}. 
    102126 
    103127% ------------------------------------------------------------------------------------------------------------- 
     
    539563the clipping factor is of crucial importance for the entrainment depth predicted in  
    540564stably stratified situations, and that its value has to be chosen in accordance  
    541 with the algebraic model for the turbulent ßuxes. The clipping is only activated  
     565with the algebraic model for the turbulent fluxes. The clipping is only activated  
    542566if \np{ln\_length\_lim}=true, and the $c_{lim}$ is set to the \np{rn\_clim\_galp} value. 
    543567 
     
    9811005reduced as necessary to ensure stability; these changes are not reported. 
    9821006 
     1007Limits on the bottom friction coefficient are not imposed if the user has elected to 
     1008handle the bottom friction implicitly (see \S\ref{ZDF_bfr_imp}). The number of potential 
     1009breaches of the explicit stability criterion are still reported for information purposes. 
     1010 
     1011% ------------------------------------------------------------------------------------------------------------- 
     1012%       Implicit Bottom Friction 
     1013% ------------------------------------------------------------------------------------------------------------- 
     1014\subsection{Implicit Bottom Friction (\np{ln\_bfrimp}$=$\textit{T})} 
     1015\label{ZDF_bfr_imp} 
     1016 
     1017An optional implicit form of bottom friction has been implemented to improve 
     1018model stability. We recommend this option for shelf sea and coastal ocean applications, especially  
     1019for split-explicit time splitting. This option can be invoked by setting \np{ln\_bfrimp}  
     1020to \textit{true} in the \textit{nambfr} namelist. This option requires \np{ln\_zdfexp} to be \textit{false}  
     1021in the \textit{namzdf} namelist.  
     1022 
     1023This implementation is realised in \mdl{dynzdf\_imp} and \mdl{dynspg\_ts}. In \mdl{dynzdf\_imp}, the  
     1024bottom boundary condition is implemented implicitly. 
     1025 
     1026\begin{equation} \label{Eq_dynzdf_bfr} 
     1027\left.{\left( {\frac{A^{vm} }{e_3 }\ \frac{\partial \textbf{U}_h}{\partial k}} \right)} \right|_{mbk} 
     1028    = \binom{c_{b}^{u}u^{n+1}_{mbk}}{c_{b}^{v}v^{n+1}_{mbk}} 
     1029\end{equation} 
     1030 
     1031where $mbk$ is the layer number of the bottom wet layer. superscript $n+1$ means the velocity used in the 
     1032friction formula is to be calculated, so, it is implicit. 
     1033 
     1034If split-explicit time splitting is used, care must be taken to avoid the double counting of 
     1035the bottom friction in the 2-D barotropic momentum equations. As NEMO only updates the barotropic  
     1036pressure gradient and Coriolis' forcing terms in the 2-D barotropic calculation, we need to remove 
     1037the bottom friction induced by these two terms which has been included in the 3-D momentum trend  
     1038and update it with the latest value. On the other hand, the bottom friction contributed by the 
     1039other terms (e.g. the advection term, viscosity term) has been included in the 3-D momentum equations 
     1040and should not be added in the 2-D barotropic mode. 
     1041 
     1042The implementation of the implicit bottom friction in \mdl{dynspg\_ts} is done in two steps as the 
     1043following: 
     1044 
     1045\begin{equation} \label{Eq_dynspg_ts_bfr1} 
     1046\frac{\textbf{U}_{med}-\textbf{U}^{m-1}}{2\Delta t}=-g\nabla\eta-f\textbf{k}\times\textbf{U}^{m}+c_{b} 
     1047\left(\textbf{U}_{med}-\textbf{U}^{m-1}\right) 
     1048\end{equation} 
     1049\begin{equation} \label{Eq_dynspg_ts_bfr2} 
     1050\frac{\textbf{U}^{m+1}-\textbf{U}_{med}}{2\Delta t}=\textbf{T}+ 
     1051\left(g\nabla\eta^{'}+f\textbf{k}\times\textbf{U}^{'}\right)- 
     10522\Delta t_{bc}c_{b}\left(g\nabla\eta^{'}+f\textbf{k}\times\textbf{u}_{b}\right) 
     1053\end{equation} 
     1054 
     1055where $\textbf{T}$ is the vertical integrated 3-D momentum trend. We assume the leap-frog time-stepping 
     1056is used here. $\Delta t$ is the barotropic mode time step and $\Delta t_{bc}$ is the baroclinic mode time step. 
     1057 $c_{b}$ is the friction coefficient. $\eta$ is the sea surface level calculated in the barotropic loops 
     1058while $\eta^{'}$ is the sea surface level used in the 3-D baroclinic mode. $\textbf{u}_{b}$ is the bottom 
     1059layer horizontal velocity. 
     1060 
     1061 
     1062 
     1063 
    9831064% ------------------------------------------------------------------------------------------------------------- 
    9841065%       Bottom Friction with split-explicit time splitting 
    9851066% ------------------------------------------------------------------------------------------------------------- 
    986 \subsection{Bottom Friction with split-explicit time splitting} 
     1067\subsection{Bottom Friction with split-explicit time splitting (\np{ln\_bfrimp}$=$\textit{F})} 
    9871068\label{ZDF_bfr_ts} 
    9881069 
     
    9931074{\key{dynspg\_flt}). Extra attention is required, however, when using  
    9941075split-explicit time stepping (\key{dynspg\_ts}). In this case the free surface  
    995 equation is solved with a small time step \np{nn\_baro}*\np{rn\_rdt}, while the three  
    996 dimensional prognostic variables are solved with a longer time step that is a  
    997 multiple of \np{rn\_rdt}. The trend in the barotropic momentum due to bottom  
     1076equation is solved with a small time step \np{rn\_rdt}/\np{nn\_baro}, while the three  
     1077dimensional prognostic variables are solved with the longer time step  
     1078of \np{rn\_rdt} seconds. The trend in the barotropic momentum due to bottom  
    9981079friction appropriate to this method is that given by the selected parameterisation  
    9991080($i.e.$ linear or non-linear bottom friction) computed with the evolving velocities  
     
    10181099\end{enumerate} 
    10191100 
    1020 Note that the use of an implicit formulation 
     1101Note that the use of an implicit formulation within the barotropic loop 
    10211102for the bottom friction trend means that any limiting of the bottom friction coefficient  
    10221103in \mdl{dynbfr} does not adversely affect the solution when using split-explicit time  
    10231104splitting. This is because the major contribution to bottom friction is likely to come from  
    1024 the barotropic component which uses the unrestricted value of the coefficient. 
    1025  
    1026 The implicit formulation takes the form: 
     1105the barotropic component which uses the unrestricted value of the coefficient. However, if the 
     1106limiting is thought to be having a major effect (a more likely prospect in coastal and shelf seas 
     1107applications) then the fully implicit form of the bottom friction should be used (see \S\ref{ZDF_bfr_imp} )  
     1108which can be selected by setting \np{ln\_bfrimp} $=$ \textit{true}. 
     1109 
     1110Otherwise, the implicit formulation takes the form: 
    10271111\begin{equation} \label{Eq_zdfbfr_implicitts} 
    10281112 \bar{U}^{t+ \rdt} = \; \left [ \bar{U}^{t-\rdt}\; + 2 \rdt\;RHS \right ] / \left [ 1 - 2 \rdt \;c_b^{u} / H_e \right ]   
     
    10911175The essential goal of the parameterization is to represent the momentum  
    10921176exchange between the barotropic tides and the unrepresented internal waves  
    1093 induced by the tidal ßow over rough topography in a stratified ocean.  
     1177induced by the tidal flow over rough topography in a stratified ocean.  
    10941178In the current version of \NEMO, the map is built from the output of  
    10951179the barotropic global ocean tide model MOG2D-G \citep{Carrere_Lyard_GRL03}. 
  • trunk/DOC/TexFiles/Chapters/Introduction.tex

    • Property svn:executable deleted
    r2570 r3294  
    6363\citep{OASIS2006}. Two-way nesting is also available through an interface to the 
    6464AGRIF package (Adaptative Grid Refinement in \textsc{Fortran}) \citep{Debreu_al_CG2008}. 
     65The interface code for coupling to an alternative sea ice model (CICE, \citet{Hunke2008}) is now  
     66available although this is currently only designed for global domains, without the use of AGRIF. 
    6567 
    6668Other model characteristics are the lateral boundary conditions (chapter~\ref{LBC}).   
     
    200202concern of improving the model performance.  
    201203 
     204 \vspace{1cm} 
     205$\bullet$ The main modifications from NEMO/OPA v3.3 and  v3.4 are :\\ 
     206\begin{enumerate} 
     207\item finalisation of above iso-neutral mixing \citep{Griffies_al_JPO98}";  
     208\item "Neptune effect" parametrisation; 
     209\item horizontal pressure gradient suitable for s-coordinate;  
     210\item semi-implicit bottom friction; 
     211\item finalisation of the merge of passive and active tracers advection-diffusion modules;  
     212\item a new bulk formulae (so-called MFS); 
     213\item use fldread for the off-line tracer component (OFF\_SRC) ;  
     214\item use MPI point to point communications  for north fold; 
     215\item diagnostic of transport ;  
     216\end{enumerate} 
     217 
     218 
Note: See TracChangeset for help on using the changeset viewer.