# 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 7260 – NEMO

# Changeset 7260

Ignore:
Timestamp:
2016-11-18T09:27:42+01:00 (6 years ago)
Message:

phaze DOC/ directory of the CRS branch with nemo_v3_6_STABLE branch at rev 7213 (09-09-2016) (merge -r 5519:7213 )

Location:
branches/2015/dev_r5003_MERCATOR6_CRS/DOC
Files:
9 deleted
27 edited
9 copied

Unmodified
Removed

• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/NEMO_coding.conv.tex

 r2738 \usepackage{framed} \usepackage{makeidx} \graphicspath{{Figures/}} %%%%%%% \title{ \includegraphics[width=0.3\textwidth]{./TexFiles/Figures/NEMO_logo_Black.pdf} \\ \includegraphics[width=0.3\textwidth]{NEMO_logo_Black} \\ \vspace{1.0cm} \rule{345pt}{1.5pt} \\
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Abstracts_Foreword.tex

 r3294 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ be a flexible tool for studying the ocean and its interactions with the others components of the earth climate system over a wide range of space and time scales. Prognostic variables are the three-dimensional velocity field, a linear or non-linear sea surface height, the temperature and the salinity. In the horizontal direction, the model uses a curvilinear orthogonal grid and in the vertical direction, a full or partial step $z$-coordinate, or $s$-coordinate, or a mixture of the two. The distribution of variables is a three-dimensional Arakawa C-type grid. Various physical choices are available to describe ocean physics, including TKE, GLS and KPP vertical physics. Within NEMO, the ocean is interfaced with a sea-ice model (LIM v2 and v3), passive tracer and biogeochemical models (TOP) and, via the OASIS coupler, with several atmospheric general circulation models. It also support two-way grid embedding via the AGRIF software. Prognostic variables are the three-dimensional velocity field, a non-linear sea surface height, the \textit{Conservative} Temperature and the \textit{Absolute} Salinity. In the horizontal direction, the model uses a curvilinear orthogonal grid and in the vertical direction, a full or partial step $z$-coordinate, or $s$-coordinate, or a mixture of the two. The distribution of variables is a three-dimensional Arakawa C-type grid. Various physical choices are available to describe ocean physics, including TKE, and GLS vertical physics. Within NEMO, the ocean is interfaced with a sea-ice model (LIM or CICE), passive tracer and biogeochemical models (TOP) and, via the OASIS coupler, with several atmospheric general circulation models. It also support two-way grid embedding via the AGRIF software. % ================================================================ \vspace{0.5cm} % \vspace{0.5cm} Le moteur oc\'{e}anique de NEMO (Nucleus for European Modelling of the Ocean) est un mod\{e}le aux \'{e}quations primitives de la circulation oc\'{e}anique r\'{e}gionale et globale. Il se veut un outil flexible pour \'{e}tudier sur un vaste spectre spatiotemporel l'oc\'{e}an et ses interactions avec les autres composantes du syst\{e}me climatique terrestre. Les variables pronostiques sont le champ tridimensionnel de vitesse, une hauteur de la mer lin\'{e}aire ou non, la temperature et la salinit\'{e}. La distribution des variables se fait sur une grille C d'Arakawa tridimensionnelle utilisant une coordonn\'{e}e verticale $z$ \{a} niveaux entiers ou partiels, ou une coordonn\'{e}e s, ou encore une combinaison des deux. Diff\'{e}rents choix sont propos\'{e}s pour d\'{e}crire la physique oc\'{e}anique, incluant notamment des physiques verticales TKE, GLS et KPP. A travers l'infrastructure NEMO, l'oc\'{e}an est interfac\'{e} avec des mod\{e}les de glace de mer, de biog\'{e}ochimie et de traceurs passifs, et, via le coupleur OASIS, \{a} plusieurs mod\{e}les de circulation g\'{e}n\'{e}rale atmosph\'{e}rique. Il supporte \'{e}galement l'embo\^{i}tement interactif de maillages via le logiciel AGRIF. %Le moteur oc\'{e}anique de NEMO (Nucleus for European Modelling of the Ocean) est un %mod\{e}le aux \'{e}quations primitives de la circulation oc\'{e}anique r\'{e}gionale et globale. %Il se veut un outil flexible pour \'{e}tudier sur un vaste spectre spatiotemporel l'oc\'{e}an et ses %interactions avec les autres composantes du syst\{e}me climatique terrestre. %Les variables pronostiques sont le champ tridimensionnel de vitesse, une hauteur de la mer %lin\'{e}aire, la Temp\'{e}rature Conservative et la Salinit\'{e} Absolue. %La distribution des variables se fait sur une grille C d'Arakawa tridimensionnelle utilisant une %coordonn\'{e}e verticale $z$ \{a} niveaux entiers ou partiels, ou une coordonn\'{e}e s, ou encore %une combinaison des deux. Diff\'{e}rents choix sont propos\'{e}s pour d\'{e}crire la physique %oc\'{e}anique, incluant notamment des physiques verticales TKE et GLS. A travers l'infrastructure %NEMO, l'oc\'{e}an est interfac\'{e} avec des mod\{e}les de glace de mer (LIM ou CICE), %de biog\'{e}ochimie marine et de traceurs passifs, et, via le coupleur OASIS, \{a} plusieurs %mod\{e}les de circulation g\'{e}n\'{e}rale atmosph\'{e}rique. %Il supporte \'{e}galement l'embo\^{i}tement interactif de maillages via le logiciel AGRIF. } \vspace{0.5cm} \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Annex_A.tex

 r3294 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ expression of the 3D divergence in the $s-$coordinates established above. \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Annex_B.tex

 r3294 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter Ñ Appendix B : Diffusive Operators \eqref{Apdx_B_Lap_U} is used in both $z$- and $s$-coordinate systems, that is a Laplacian diffusion is applied on momentum along the coordinate directions. \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Annex_C.tex

 r3294 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter Ñ Appendix C : Discrete Invariants of the Equations \end{aligned}   } \right. where the indices $i_p$ and $k_p$ take the following value: where the indices $i_p$ and $j_p$ take the following value: $i_p = -1/2$ or $1/2$ and $j_p = -1/2$ or $1/2$, and the vorticity triads, ${^i_j}\mathbb{Q}^{i_p}_{j_p}$, defined at $T$-point, are given by: The discrete formulation of the horizontal diffusion of momentum ensures the conservation of potential vorticity and the horizontal divergence, and the dissipation of the square of these quantities (i.e. enstrophy and the dissipation of the square of these quantities ($i.e.$ enstrophy and the variance of the horizontal divergence) as well as the dissipation of the horizontal kinetic energy. In particular, when the eddy coefficients are &\int \limits_D \frac{1} {e_3 } \textbf{k} \cdot \nabla \times \Bigl[    \nabla_h  \left( A^{\,lm}\;\chi  \right) - \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)    \Bigr]\;dv  = 0 \end{flalign*} - \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)    \Bigr]\;dv   \\ %\end{flalign*} %%%%%%%%%%  recheck here....  (gm) \begin{flalign*} = \int \limits_D  -\frac{1} {e_3 } \textbf{k} \cdot \nabla \times \Bigl[ \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)  \Bigr]\;dv &&& \\ \end{flalign*} \begin{flalign*} %\begin{flalign*} =& \int \limits_D  -\frac{1} {e_3 } \textbf{k} \cdot \nabla \times \Bigl[ \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)  \Bigr]\;dv \\ %\end{flalign*} %\begin{flalign*} \equiv& \sum\limits_{i,j} \left\{ \delta_{i+1/2} \left[ \frac {e_{2v}} {e_{1v}\,e_{3v}}  \delta_i \left[ A_f^{\,lm} e_{3f} \zeta  \right] \right] + \delta_{j+1/2} \left[ \frac {e_{1u}} {e_{2u}\,e_{3u}} \delta_j \left[ A_f^{\,lm} e_{3f} \zeta  \right] \right] \right\} && \\ \delta_{i+1/2} \left[  \frac {e_{2v}} {e_{1v}\,e_{3v}}  \delta_i \left[ A_f^{\,lm} e_{3f} \zeta  \right]  \right] + \delta_{j+1/2} \left[  \frac {e_{1u}} {e_{2u}\,e_{3u}}  \delta_j \left[ A_f^{\,lm} e_{3f} \zeta  \right]  \right] \right\}     \\ % \intertext{Using \eqref{DOM_di_adj}, it follows:} \equiv& \sum\limits_{i,j,k} -\,\left\{ \frac{e_{2v}} {e_{1v}\,e_{3v}}  \delta_i \left[ A_f^{\,lm} e_{3f} \zeta  \right]\;\delta_i \left[ 1\right] + \frac{e_{1u}} {e_{2u}\,e_{3u}} \delta_j \left[ A_f^{\,lm} e_{3f} \zeta  \right]\;\delta_j \left[ 1\right] \frac{e_{2v}} {e_{1v}\,e_{3v}}  \delta_i  \left[ A_f^{\,lm} e_{3f} \zeta  \right]\;\delta_i \left[ 1\right] + \frac{e_{1u}} {e_{2u}\,e_{3u}}  \delta_j  \left[ A_f^{\,lm} e_{3f} \zeta  \right]\;\delta_j \left[ 1\right] \right\} \quad \equiv 0 && \\ \\ \end{flalign*} \subsection{Dissipation of Horizontal Kinetic Energy} \label{Apdx_C.3.2} The lateral momentum diffusion term dissipates the horizontal kinetic energy: \label{Apdx_C.3.3} The lateral momentum diffusion term dissipates the enstrophy when the eddy coefficients are horizontally uniform: \left[   \nabla_h \left( A^{\,lm}\;\chi  \right) - \nabla_h \times \left( A^{\,lm}\;\zeta \; \textbf{k} \right)   \right]\;dv &&&\\ &= A^{\,lm} \int \limits_D \zeta \textbf{k} \cdot \nabla \times &\quad = A^{\,lm} \int \limits_D \zeta \textbf{k} \cdot \nabla \times \left[    \nabla_h \times \left( \zeta \; \textbf{k} \right)   \right]\;dv &&&\\ &\equiv A^{\,lm} \sum\limits_{i,j,k}  \zeta \;e_{3f} &\quad \equiv A^{\,lm} \sum\limits_{i,j,k}  \zeta \;e_{3f} \left\{     \delta_{i+1/2} \left[  \frac{e_{2v}} {e_{1v}\,e_{3v}} \delta_i \left[ e_{3f} \zeta  \right]   \right] + \delta_{j+1/2} \left[  \frac{e_{1u}} {e_{2u}\,e_{3u}} \delta_j \left[ e_{3f} \zeta  \right]   \right]      \right\}   &&&\\ \intertext{Using \eqref{DOM_di_adj}, it follows:} % &\equiv  - A^{\,lm} \sum\limits_{i,j,k} &\quad \equiv  - A^{\,lm} \sum\limits_{i,j,k} \left\{    \left(  \frac{1} {e_{1v}\,e_{3v}}  \delta_i \left[ e_{3f} \zeta  \right]  \right)^2   b_v + \left(  \frac{1} {e_{2u}\,e_{3u}}  \delta_j \left[ e_{3f} \zeta  \right] \right)^2   b_u  \right\}      &&&\\ & \leq \;0       &&&\\ + \left(  \frac{1} {e_{2u}\,e_{3u}}  \delta_j \left[ e_{3f} \zeta  \right] \right)^2   b_u  \right\}  \quad \leq \;0    &&&\\ \end{flalign*} When the horizontal divergence of the horizontal diffusion of momentum (discrete sense) is taken, the term associated with the vertical curl of the vorticity is zero locally, due to (!!! II.1.8  !!!!!). The resulting term conserves the $\chi$ and dissipates $\chi^2$ when the eddy coefficients are horizontally uniform. vorticity is zero locally, due to \eqref{Eq_DOM_div_curl}. The resulting term conserves the $\chi$ and dissipates $\chi^2$ when the eddy coefficients are horizontally uniform. \begin{flalign*} & \int\limits_D  \nabla_h \cdot \Bigl[     \nabla_h \left( A^{\,lm}\;\chi \right) - \nabla_h \times \left( A^{\,lm}\;\zeta \;\textbf{k} \right)    \Bigr]  dv = \int\limits_D  \nabla_h \cdot \nabla_h \left( A^{\,lm}\;\chi  \right)   dv   &&&\\ = \int\limits_D  \nabla_h \cdot \nabla_h \left( A^{\,lm}\;\chi  \right)   dv   \\ % &\equiv \sum\limits_{i,j,k} \left\{   \delta_i \left[ A_u^{\,lm} \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2} \left[ \chi \right]  \right] + \delta_j \left[ A_v^{\,lm} \frac{e_{1v}\,e_{3v}} {e_{2v}}  \delta_{j+1/2} \left[ \chi \right]  \right]    \right\}    &&&\\ + \delta_j \left[ A_v^{\,lm} \frac{e_{1v}\,e_{3v}} {e_{2v}}  \delta_{j+1/2} \left[ \chi \right]  \right]    \right\}    \\ % \intertext{Using \eqref{DOM_di_adj}, it follows:} &\equiv \sum\limits_{i,j,k} - \left\{   \frac{e_{2u}\,e_{3u}} {e_{1u}}  A_u^{\,lm} \delta_{i+1/2} \left[ \chi \right] \delta_{i+1/2} \left[ 1 \right] + \frac{e_{1v}\,e_{3v}}  {e_{2v}}  A_v^{\,lm} \delta_{j+1/2} \left[ \chi \right] \delta_{j+1/2} \left[ 1 \right]    \right\} \qquad \equiv 0     &&& \\ + \frac{e_{1v}\,e_{3v}} {e_{2v}}  A_v^{\,lm} \delta_{j+1/2} \left[ \chi \right] \delta_{j+1/2} \left[ 1 \right]    \right\} \quad \equiv 0      \\ \end{flalign*} \left[    \nabla_h              \left( A^{\,lm}\;\chi                    \right) - \nabla_h   \times  \left( A^{\,lm}\;\zeta \;\textbf{k} \right)    \right]\;  dv = A^{\,lm}   \int\limits_D \chi \;\nabla_h \cdot \nabla_h \left( \chi \right)\;  dv    &&&\\ = A^{\,lm}   \int\limits_D \chi \;\nabla_h \cdot \nabla_h \left( \chi \right)\;  dv    \\ % &\equiv A^{\,lm}  \sum\limits_{i,j,k}  \frac{1} {e_{1t}\,e_{2t}\,e_{3t}}  \chi \delta_i  \left[   \frac{e_{2u}\,e_{3u}} {e_{1u}}  \delta_{i+1/2} \left[ \chi \right]   \right] + \delta_j  \left[   \frac{e_{1v}\,e_{3v}} {e_{2v}}   \delta_{j+1/2} \left[ \chi \right]   \right] \right\} \;   e_{1t}\,e_{2t}\,e_{3t}    &&&\\ \right\} \;   e_{1t}\,e_{2t}\,e_{3t}    \\ % \intertext{Using \eqref{DOM_di_adj}, it turns out to be:} &\equiv - A^{\,lm} \sum\limits_{i,j,k} \left\{    \left(  \frac{1} {e_{1u}}  \delta_{i+1/2}  \left[ \chi \right]  \right)^2  b_u + \left(  \frac{1} {e_{2v}}  \delta_{j+1/2}  \left[ \chi \right]  \right)^2  b_v    \right\} \;    &&&\\ % &\leq 0              &&&\\ + \left(  \frac{1} {e_{2v}}  \delta_{j+1/2}  \left[ \chi \right]  \right)^2  b_v    \right\} \quad \leq 0             \\ \end{flalign*} \section{Conservation Properties on Vertical Momentum Physics} \label{Apdx_C_4} As for the lateral momentum physics, the continuous form of the vertical diffusion \left(   \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)\; dv    \quad &\leq 0     \\ \end{align*} The first property is obvious. The second results from: \begin{flalign*} \int\limits_D e_{1f}\,e_{2f}\,e_{3f} \; \equiv 0   && \\ \end{flalign*} If the vertical diffusion coefficient is uniform over the whole domain, the enstrophy is dissipated, $i.e.$ \left( \frac{A^{\,vm}} {e_3 }\; \frac{\partial \textbf{U}_h } {\partial k}   \right)   \right)\; dv = 0   &&&\\ \end{flalign*} This property is only satisfied in $z$-coordinates: \begin{flalign*} \int\limits_D \zeta \, \textbf{k} \cdot \nabla \times The numerical schemes used for tracer subgridscale physics are written such that the heat and salt contents are conserved (equations in flux form, second order centered finite differences). Since a flux form is used to compute the temperature and salinity, the quadratic form of these quantities (i.e. their variance) globally tends to diminish. As for the advection term, there is generally no strict conservation of mass, even if in practice the mass is conserved to a very high accuracy. that the heat and salt contents are conserved (equations in flux form). Since a flux form is used to compute the temperature and salinity, the quadratic form of these quantities ($i.e.$ their variance) globally tends to diminish. As for the advection term, there is conservation of mass only if the Equation Of Seawater is linear. % ------------------------------------------------------------------------------------------------------------- %%%%  end of appendix in gm comment %} \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Annex_D.tex

 r3294 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Appendix D Ñ Coding Rules \hline public  \par or  \par module variable& \textbf{m n} \par \textit{but not} \par \textbf{nn\_}& \textbf{m n} \par \textit{but not} \par \textbf{nn\_ np\_}& \textbf{a b e f g h o q r} \par \textbf{t} \textit{to} \textbf{x} \par but not \par \textbf{fs rn\_}& \textbf{l} \par \textit{but not} \par \textbf{lp ld} \par \textbf{ ll ln\_}& \hline parameter& \textbf{jp}& \textbf{jp np\_}& \textbf{pp}& \textbf{lp}& %-------------------------------------------------------------------------------------------------------------- N.B.   Parameter here, in not only parameter in the \textsc{Fortran} acceptation, it is also used for code variables that are read in namelist and should never been modified during a simulation. It is the case, for example, for the size of a domain (jpi,jpj,jpk). \newpage % ================================================================ To be done.... \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Annex_E.tex

 r3294 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Appendix E : Note on some algorithms \begin{figure}[!ht] \label{Fig_ISO_triad} \begin{center} \includegraphics[width=0.70\textwidth]{./TexFiles/Figures/Fig_ISO_triad.pdf} \includegraphics[width=0.70\textwidth]{Fig_ISO_triad} \caption{  \label{Fig_ISO_triad} Triads used in the Griffies's like iso-neutral diffision scheme for tracer is preserved by the discretisation of the skew fluxes. \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Annex_ISO.tex

 r4147 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Iso-neutral diffusion : % >>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[h] \begin{center} \includegraphics[width=1.05\textwidth]{./TexFiles/Figures/Fig_GRIFF_triad_fluxes} \includegraphics[width=1.05\textwidth]{Fig_GRIFF_triad_fluxes} \caption{ \label{fig:triad:ISO_triad} (a) Arrangement of triads $S_i$ and tracer gradients to % >>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[h] \begin{center} \includegraphics[width=0.80\textwidth]{./TexFiles/Figures/Fig_GRIFF_qcells} \includegraphics[width=0.80\textwidth]{Fig_GRIFF_qcells} \caption{   \label{fig:triad:qcells} Triad notation for quarter cells. $T$-cells are inside % >>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[h] \begin{center} \includegraphics[width=0.60\textwidth]{./TexFiles/Figures/Fig_GRIFF_bdry_triads} \includegraphics[width=0.60\textwidth]{Fig_GRIFF_bdry_triads} \caption{  \label{fig:triad:bdry_triads} (a) Uppermost model layer $k=1$ with $i,1$ and $i+1,1$ tracer different $i_p,k_p$, denoted by different colours, (e.g. the green triad $i_p=1/2,k_p=-1/2$) are tapered to the appropriate basal triad.}} {\includegraphics[width=0.60\textwidth]{./TexFiles/Figures/Fig_GRIFF_MLB_triads}} {\includegraphics[width=0.60\textwidth]{Fig_GRIFF_MLB_triads}} \end{figure} % >>>>>>>>>>>>>>>>>>>>>>>>>>>> \end{split} \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_ASM.tex

 r4147 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter Assimilation increments (ASM) \end{verbatim} \end{alltt} \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_CFG.tex

 r4147 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter � Configurations %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]   \begin{center} \includegraphics[width=0.98\textwidth]{./TexFiles/Figures/Fig_ORCA_NH_mesh.pdf} \includegraphics[width=0.98\textwidth]{Fig_ORCA_NH_mesh} \caption{  \label{Fig_MISC_ORCA_msh} ORCA mesh conception. The departure from an isotropic Mercator grid start poleward of 20\deg N. ORCA mesh conception. The departure from an isotropic Mercator grid start poleward of 20\degN. The two "north pole" are the foci of a series of embedded ellipses (blue curves) which are determined analytically and form the i-lines of the ORCA mesh (pseudo latitudes). %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!tbp]  \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_ORCA_NH_msh05_e1_e2.pdf} \includegraphics[width=0.80\textwidth]{./TexFiles/Figures/Fig_ORCA_aniso.pdf} \includegraphics[width=1.0\textwidth]{Fig_ORCA_NH_msh05_e1_e2} \includegraphics[width=0.80\textwidth]{Fig_ORCA_aniso} \caption {  \label{Fig_MISC_ORCA_e1e2} \textit{Top}: Horizontal scale factors ($e_1$, $e_2$) and \textit{Bottom}: ratio of anisotropy ($e_1 / e_2$) for ORCA 0.5\deg ~mesh. South of 20\deg N a Mercator grid is used ($e_1 = e_2$) so that the anisotropy ratio is 1. Poleward of 20\deg N, the two "north pole" for ORCA 0.5\deg ~mesh. South of 20\degN a Mercator grid is used ($e_1 = e_2$) so that the anisotropy ratio is 1. Poleward of 20\degN, the two "north pole" introduce a weak anisotropy over the ocean areas ($< 1.2$) except in vicinity of Victoria Island (Canadian Arctic Archipelago). } The method is applied to Mercator grid ($i.e.$ same zonal and meridional grid spacing) poleward of $20\deg$N, so that the Equator is a mesh line, which provides a better numerical solution of 20\degN, so that the Equator is a mesh line, which provides a better numerical solution for equatorial dynamics. The choice of the series of embedded ellipses (position of the foci and variation of the ellipses) is a compromise between maintaining  the ratio of mesh anisotropy The ORCA\_R2 configuration has the following specificity : starting from a 2\deg~ORCA mesh, local mesh refinements were applied to the Mediterranean, Red, Black and Caspian Seas, so that the resolution is $1\deg \time 1\deg$ there. A local transformation were also applied so that the resolution is 1\deg \time 1\deg there. A local transformation were also applied with in the Tropics in order to refine the meridional resolution up to 0.5\deg at the Equator. The domain geometry is a closed rectangular basin on the $\beta$-plane centred at $\sim 30\deg$N and rotated by 45\deg, 3180~km long, 2120~km wide at $\sim$ 30\degN and rotated by 45\deg, 3180~km long, 2120~km wide and 4~km deep (Fig.~\ref{Fig_MISC_strait_hand}). The domain is bounded by vertical walls and by a flat bottom. The configuration is The applied forcings vary seasonally in a sinusoidal manner between winter and summer extrema \citep{Levy_al_OM10}. The wind stress is zonal and its curl changes sign at 22\deg N and 36\deg N. The wind stress is zonal and its curl changes sign at 22\degN and 36\degN. It forces a subpolar gyre in the north, a subtropical gyre in the wider part of the domain and a small recirculation gyre in the southern corner. %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]   \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_GYRE.pdf} \includegraphics[width=1.0\textwidth]{Fig_GYRE} \caption{  \label{Fig_GYRE} Snapshot of relative vorticity at the surface of the model domain temperature data. \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_Conservation.tex

 r3294 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ not been implemented. \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_DIA.tex

 r5602 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter I/O & Diagnostics % ================================================================ \chapter{Ouput and Diagnostics (IOM, DIA, TRD, FLO)} \chapter{Output and Diagnostics (IOM, DIA, TRD, FLO)} \label{DIA} \minitoc \newpage $\$\newline    % force a new ligne $\$\newline    % force a new line % ================================================================ Since version 3.2, iomput is the NEMO output interface of choice. It has been designed to be simple to use, flexible and efficient. The two main purposes of iomput are: Since version 3.2, iomput is the NEMO output interface of choice. It has been designed to be simple to use, flexible and efficient. The two main purposes of iomput are: \begin{enumerate} \item The complete and flexible control of the output files through external XML files adapted by the user from standard templates. % ------------------------------------------------------------------------------------------------------------- \section[Tracer/Dynamics Trends (TRD)] {Tracer/Dynamics Trends  (\key{trdtra}, \key{trddyn},    \\ \key{trddvor}, \key{trdmld})} {Tracer/Dynamics Trends  (\ngn{namtrd})} \label{DIA_trd} %------------------------------------------------------------------------------------------------------------- When \key{trddyn} and/or \key{trddyn} CPP variables are defined, each trend of the dynamics and/or temperature and salinity time evolution equations is stored in three-dimensional arrays just after their computation ($i.e.$ at the end of each $dyn\cdots.F90$ and/or $tra\cdots.F90$ routines). Options are defined by \ngn{namtrd} namelist variables. These trends are then used in \mdl{trdmod} (see TRD directory) every \textit{nn\_trd } time-steps. What is done depends on the CPP keys defined: Each trend of the dynamics and/or temperature and salinity time evolution equations can be send to \mdl{trddyn} and/or \mdl{trdtra} modules (see TRD directory) just after their computation ($i.e.$ at the end of each $dyn\cdots.F90$ and/or $tra\cdots.F90$ routines). This capability is controlled by options offered in \ngn{namtrd} namelist. Note that the output are done with xIOS, and therefore the \key{IOM} is required. What is done depends on the \ngn{namtrd} logical set to \textit{true}: \begin{description} \item[\key{trddyn}, \key{trdtra}] : a check of the basin averaged properties of the momentum and/or tracer equations is performed ; \item[\key{trdvor}] : a vertical summation of the moment tendencies is performed, then the curl is computed to obtain the barotropic vorticity tendencies which are output ; \item[\key{trdmld}] : output of the tracer tendencies averaged vertically either over the mixed layer (\np{nn\_ctls}=0), or       over a fixed number of model levels (\np{nn\_ctls}$>$1 provides the number of level), or       over a spatially varying but temporally fixed number of levels (typically the base of the winter mixed layer) read in \ifile{ctlsurf\_idx} (\np{nn\_ctls}=1) ; \item[\np{ln\_glo\_trd}] : at each \np{nn\_trd} time-step a check of the basin averaged properties of the momentum and tracer equations is performed. This also includes a check of $T^2$, $S^2$, $\tfrac{1}{2} (u^2+v2)$, and potential energy time evolution equations properties ; \item[\np{ln\_dyn\_trd}] : each 3D trend of the evolution of the two momentum components is output ; \item[\np{ln\_dyn\_mxl}] : each 3D trend of the evolution of the two momentum components averaged over the mixed layer is output  ; \item[\np{ln\_vor\_trd}] : a vertical summation of the moment tendencies is performed, then the curl is computed to obtain the barotropic vorticity tendencies which are output ; \item[\np{ln\_KE\_trd}]  : each 3D trend of the Kinetic Energy equation is output ; \item[\np{ln\_tra\_trd}] : each 3D trend of the evolution of temperature and salinity is output ; \item[\np{ln\_tra\_mxl}] : each 2D trend of the evolution of temperature and salinity averaged over the mixed layer is output ; \end{description} The units in the output file can be changed using the \np{nn\_ucf} namelist parameter. For example, in case of salinity tendency the units are given by PSU/s/\np{nn\_ucf}. Setting \np{nn\_ucf}=86400 ($i.e.$ the number of second in a day) provides the tendencies in PSU/d. When \key{trdmld} is defined, two time averaging procedure are proposed. Setting \np{ln\_trdmld\_instant} to \textit{true}, a simple time averaging is performed, so that the resulting tendency is the contribution to the change of a quantity between the two instantaneous values taken at the extremities of the time averaging period. Setting \np{ln\_trdmld\_instant} to \textit{false}, a double time averaging is performed, so that the resulting tendency is the contribution to the change of a quantity between two \textit{time mean} values. The later option requires the use of an extra file, \ifile{restart\_mld} (\np{ln\_trdmld\_restart}=true), to restart a run. Note that the mixed layer tendency diagnostic can also be used on biogeochemical models via the \key{trdtrc} and \key{trdmld\_trc} CPP keys. \textbf{Note that} in the current version (v3.6), many changes has been introduced but not fully tested. In particular, options associated with \np{ln\_dyn\_mxl}, \np{ln\_vor\_trd}, and \np{ln\_tra\_mxl} are not working, and none of the option have been tested with variable volume ($i.e.$ \key{vvl} defined). % ------------------------------------------------------------------------------------------------------------- \label{DIA_diag_harm} A module is available to compute the amplitude and phase for tidal waves. This diagnostic is actived with \key{diaharm}. %------------------------------------------namdia_harm---------------------------------------------------- \namdisplay{namdia_harm} %---------------------------------------------------------------------------------------------------------- Concerning the on-line Harmonic analysis, some parameters are available in namelist \ngn{namdia\_harm} : - \texttt{nit000\_han} is the first time step used for harmonic analysis - \texttt{nitend\_han} is the last time step used for harmonic analysis - \texttt{nstep\_han} is the time step frequency for harmonic analysis - \texttt{nb\_ana} is the number of harmonics to analyse - \texttt{tname} is an array with names of tidal constituents to analyse \texttt{nit000\_han} and \texttt{nitend\_han} must be between \texttt{nit000} and \texttt{nitend} of the simulation. A module is available to compute the amplitude and phase of tidal waves. This on-line Harmonic analysis is actived with \key{diaharm}. Some parameters are available in namelist \ngn{namdia\_harm} : - \np{nit000\_han} is the first time step used for harmonic analysis - \np{nitend\_han} is the last time step used for harmonic analysis - \np{nstep\_han} is the time step frequency for harmonic analysis - \np{nb\_ana} is the number of harmonics to analyse - \np{tname} is an array with names of tidal constituents to analyse \np{nit000\_han} and \np{nitend\_han} must be between \np{nit000} and \np{nitend} of the simulation. The restart capability is not implemented. The Harmonic analysis solve this equation: The Harmonic analysis solve the following equation: h_{i} - A_{0} + \sum^{nb\_ana}_{j=1}[A_{j}cos(\nu_{j}t_{j}-\phi_{j})] = e_{i} \label{DIA_diag_dct} A module is available to compute the transport of volume, heat and salt through sections. This diagnostic is actived with \key{diadct}. A module is available to compute the transport of volume, heat and salt through sections. This diagnostic is actived with \key{diadct}. Each section is defined by the coordinates of its 2 extremities. The pathways between them are contructed %------------------------------------------------------------------------------------------------------------- \texttt{nn\_dct}: frequency of instantaneous transports computing \texttt{nn\_dctwri}: frequency of writing ( mean of instantaneous transports ) \texttt{nn\_debug}: debugging of the section \np{nn\_dct}: frequency of instantaneous transports computing \np{nn\_dctwri}: frequency of writing ( mean of instantaneous transports ) \np{nn\_debug}: debugging of the section \subsubsection{ To create a binary file containing the pathway of each section } the \key{diahth} CPP key: - the mixed layer depth (based on a density criterion, \citet{de_Boyer_Montegut_al_JGR04}) (\mdl{diahth}) - the mixed layer depth (based on a density criterion \citep{de_Boyer_Montegut_al_JGR04}) (\mdl{diahth}) - the turbocline depth (based on a turbulent mixing coefficient criterion) (\mdl{diahth}) - the depth of the 20\deg C isotherm (\mdl{diahth}) - the depth of the 20\degC isotherm (\mdl{diahth}) - the depth of the thermocline (maximum of the vertical temperature gradient) (\mdl{diahth}) \np{ln\_diaptr} to true (see the \textit{\ngn{namptr} } namelist below). When \np{ln\_subbas}~=~true, transports and stream function are computed for the Atlantic, Indian, Pacific and Indo-Pacific Oceans (defined north of 30\deg S) for the Atlantic, Indian, Pacific and Indo-Pacific Oceans (defined north of 30\degS) as well as for the World Ocean. The sub-basin decomposition requires an input file (\ifile{subbasins}) which contains three 2D mask arrays, the Indo-Pacific mask %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]     \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_mask_subasins.pdf} \includegraphics[width=1.0\textwidth]{Fig_mask_subasins} \caption{   \label{Fig_mask_subasins} Decomposition of the World Ocean (here ORCA2) into sub-basin used in to compute \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_DOM.tex

 r5602 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter 2 � Space and Time Domain (DOM) % Chapter 2 ——— Space and Time Domain (DOM) % ================================================================ \chapter{Space Domain (DOM) } %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!tb]    \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_cell.pdf} \includegraphics[width=0.90\textwidth]{Fig_cell} \caption{ \label{Fig_cell} Arrangement of variables. $t$ indicates scalar points where temperature, and $f$-points, and its divergence defined at $t$-points: \begin{eqnarray}  \label{Eq_DOM_curl} \nabla \times {\rm {\bf A}}\equiv & \nabla \times {\rm{\bf A}}\equiv & \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} \\ +& \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} \\ Let $a$ and $b$ be two fields defined on the mesh, with value zero inside continental area. Using integration by parts it can be shown that the differencing operators ($\delta_i$, $\delta_j$ and $\delta_k$) are anti-symmetric linear operators, and further that the averaging operators $\overline{\,\cdot\,}^{\,i}$, operators ($\delta_i$, $\delta_j$ and $\delta_k$) are skew-symmetric linear operators, and further that the averaging operators $\overline{\,\cdot\,}^{\,i}$, $\overline{\,\cdot\,}^{\,k}$ and $\overline{\,\cdot\,}^{\,k}$) are symmetric linear operators, $i.e.$ %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!tb]  \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_index_hor.pdf} \includegraphics[width=0.90\textwidth]{Fig_index_hor} \caption{   \label{Fig_index_hor} Horizontal integer indexing used in the \textsc{Fortran} code. The dashed area indicates %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!pt]    \begin{center} \includegraphics[width=.90\textwidth]{./TexFiles/Figures/Fig_index_vert.pdf} \includegraphics[width=.90\textwidth]{Fig_index_vert} \caption{ \label{Fig_index_vert} Vertical integer indexing used in the \textsc{Fortran } code. Note that %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]     \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_zgr_e3.pdf} \includegraphics[width=0.90\textwidth]{Fig_zgr_e3} \caption{ \label{Fig_zgr_e3} Comparison of (a) traditional definitions of grid-point position and grid-size in the vertical, For both grids here,  the same $w$-point depth has been chosen but in (a) the $t$-points are set half way between $w$-points while in (b) they are defined from an analytical function: $z(k)=5\,(i-1/2)^3 - 45\,(i-1/2)^2 + 140\,(i-1/2) - 150$. an analytical function: $z(k)=5\,(k-1/2)^3 - 45\,(k-1/2)^2 + 140\,(k-1/2) - 150$. Note the resulting difference between the value of the grid-size $\Delta_k$ and those of the scale factor $e_k$. } The choice of the grid must be consistent with the boundary conditions specified by the parameter \np{jperio} (see {\S\ref{LBC}). by \np{jperio}, a parameter found in \ngn{namcfg} namelist (see {\S\ref{LBC}). % ------------------------------------------------------------------------------------------------------------- %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!tb]    \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_z_zps_s_sps.pdf} \includegraphics[width=1.0\textwidth]{Fig_z_zps_s_sps} \caption{  \label{Fig_z_zps_s_sps} The ocean bottom as seen by the model: %>>>>>>>>>>>>>>>>>>>>>>>>>>>> The choice of a vertical coordinate, even if it is made through a namelist parameter, The choice of a vertical coordinate, even if it is made through \ngn{namzgr} namelist parameters, must be done once of all at the beginning of an experiment. It is not intended as an option which can be enabled or disabled in the middle of an experiment. Three main bathymetry or $s$-coordinate (hybrid and partial step coordinates have not yet been tested in NEMO v2.3). If using $z$-coordinate with partial step bathymetry (\np{ln\_zps}~=~true), ocean cavity beneath ice shelves can be open (\np{ln\_isfcav}~=~true). (\np{ln\_zps}~=~true), ocean cavity beneath ice shelves can be open (\np{ln\_isfcav}~=~true) and partial step are also applied at the ocean/ice shelf interface. Contrary to the horizontal grid, the vertical grid is computed in the code and no provision is made for reading it from a file. The only input file is the bathymetry (in meters) (\ifile{bathy\_meter}) (in meters) (\ifile{bathy\_meter}). \footnote{N.B. in full step $z$-coordinate, a \ifile{bathy\_level} file can replace the \ifile{bathy\_meter} file, so that the computation of the number of wet ocean point Three options are possible for defining the bathymetry, according to the namelist variable \np{nn\_bathy}: namelist variable \np{nn\_bathy} (found in \ngn{namdom} namelist): \begin{description} \item[\np{nn\_bathy} = 0] a flat-bottom domain is defined. The total depth $z_w (jpk)$ domain width at the central latitude. This is meant for the "EEL-R5" configuration, a periodic or open boundary channel with a seamount. \item[\np{nn\_bathy} = 1] read a bathymetry. The \ifile{bathy\_meter} file (Netcdf format) provides the ocean depth (positive, in meters) at each grid point of the model grid. The bathymetry is usually built by interpolating a standard bathymetry product \item[\np{nn\_bathy} = 1] read a bathymetry and ice shelf draft (if needed). The \ifile{bathy\_meter} file (Netcdf format) provides the ocean depth (positive, in meters) at each grid point of the model grid. The bathymetry is usually built by interpolating a standard bathymetry product ($e.g.$ ETOPO2) onto the horizontal ocean mesh. Defining the bathymetry also defines the coastline: where the bathymetry is zero, no model levels are defined (all levels are masked). The \ifile{isfdraft\_meter} file (Netcdf format) provides the ice shelf draft (positive, in meters) at each grid point of the model grid. This file is only needed if \np{ln\_isfcav}~=~true. Defining the ice shelf draft will also define the ice shelf edge and the grounding line position. \end{description} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!tb]    \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_zgr.pdf} \includegraphics[width=0.90\textwidth]{Fig_zgr} \caption{ \label{Fig_zgr} Default vertical mesh for ORCA2: 30 ocean levels (L30). Vertical level functions for (Fig.~\ref{Fig_zgr}). If the ice shelf cavities are opened (\np{ln\_isfcav}=~true~}), the definition of $z_0$ is the same. However, definition of $e_3^0$ at $t$- and $w$-points is respectively changed to: \label{DOM_zgr_ana} \begin{split} e_3^T(k) &= z_W (k+1) - z_W (k)   \\ e_3^W(k) &= z_T (k)   - z_T (k-1) \\ \end{split} This formulation decrease the self-generated circulation into the ice shelf cavity (which can, in extreme case, leads to blow up).\\ The most used vertical grid for ORCA2 has $10~m$ ($500~m)$ resolution in the surface (bottom) layers and a depth which varies from 0 at the sea surface to a usually 10\%, of the default thickness $e_{3t}(jk)$). \colorbox{yellow}{Add a figure here of pstep especially at last ocean level } \gmcomment{ \colorbox{yellow}{Add a figure here of pstep especially at last ocean level } } % ------------------------------------------------------------------------------------------------------------- %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!ht]    \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_sco_function.pdf} \includegraphics[width=1.0\textwidth]{Fig_sco_function} \caption{  \label{Fig_sco_function} Examples of the stretching function applied to a seamount; from left to right: %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!ht] \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/FIG_DOM_compare_coordinates_surface.pdf} \includegraphics[width=1.0\textwidth]{FIG_DOM_compare_coordinates_surface} \caption{A comparison of the \citet{Song_Haidvogel_JCP94} $S$-coordinate (solid lines), a 50 level $Z$-coordinate (contoured surfaces) and the \citet{Siddorn_Furner_OM12} $S$-coordinate (dashed lines) in the surface 100m for a idealised bathymetry that goes from 50m to 5500m depth. For clarity every third coordinate surface is shown.} \label{fig_compare_coordinates_surface} gives the number of ocean levels ($i.e.$ those that are not masked) at each $t$-point. mbathy is computed from the meter bathymetry using the definiton of gdept as the number of $t$-points which gdept $\leq$ bathy. gdept as the number of $t$-points which gdept $\leq$ bathy. Modifications of the model bathymetry are performed in the \textit{bat\_ctl} routine (see \mdl{domzgr} module) after mbathy is computed. Isolated grid points that do not communicate with another ocean point at the same level are eliminated. that do not communicate with another ocean point at the same level are eliminated.\\ As for the representation of bathymetry, a 2D integer array, misfdep, is created. misfdep defines the level of the first wet $t$-point. All the cells between $k=1$ and $misfdep(i,j)-1$ are masked. By default, misfdep(:,:)=1 and no cells are masked. In case of ice shelf cavities (\np{ln\_isfcav}~=~true), modifications of the model bathymetry and ice shelf draft in the cavities are performed through the \textit{zgr\_isf} routine. The compatibility between ice shelf draft and bathymetry is checked: if only one cell on the water column is opened at $t$-, $u$- or $v$-points, the bathymetry or the ice shelf draft is dug to have a 2-level water column (i.e. two unmasked levels). If the incompatibility is too strong (i.e. need to dig more than one cell), the entire water column is masked.\\ From the \textit{mbathy} array, the mask fields are defined as follows: \begin{align*} tmask(i,j,k) &= \begin{cases}   \; 1&   \text{ if $k\leq mbathy(i,j)$  }    \\ \; 0&   \text{ if $k\leq mbathy(i,j)$  }    \end{cases}     \\ tmask(i,j,k) &= \begin{cases}   \; 0&   \text{ if $k < misfdep(i,j)$ } \\ \; 1&   \text{ if $misfdep(i,j) \leq k\leq mbathy(i,j)$  }    \\ \; 0&   \text{ if $k > mbathy(i,j)$  }    \end{cases}     \\ umask(i,j,k) &=         \; tmask(i,j,k) \ * \ tmask(i+1,j,k)   \\ vmask(i,j,k) &=         \; tmask(i,j,k) \ * \ tmask(i,j+1,k)   \\ fmask(i,j,k) &=         \; tmask(i,j,k) \ * \ tmask(i+1,j,k)   \\ & \ \ \, * tmask(i,j,k) \ * \ tmask(i+1,j,k) & \ \ \, * tmask(i,j,k) \ * \ tmask(i+1,j,k) \\ wmask(i,j,k) &=         \; tmask(i,j,k) \ * \ tmask(i,j,k-1) \text{ with } wmask(i,j,1) = tmask(i,j,1) \end{align*} Note that \textit{wmask} is not defined as it is exactly equal to \textit{tmask} with the numerical indexing used (\S~\ref{DOM_Num_Index}). Moreover, the specification of closed lateral boundaries requires that at least the first and last Note, wmask is now defined. It allows, in case of ice shelves, to deal with the top boundary (ice shelf/ocean interface) exactly in the same way as for the bottom boundary. The specification of closed lateral boundaries requires that at least the first and last rows and columns of the \textit{mbathy} array are set to zero. In the particular case of an east-west cyclical boundary condition, \textit{mbathy} has its last (typical of the tropical ocean), see \rou{istate\_t\_s} subroutine called from \mdl{istate} module. \end{description} \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_DYN.tex

 r5602 % ================================================================ % Chapter � Ocean Dynamics (DYN) \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter ——— Ocean Dynamics (DYN) % ================================================================ \chapter{Ocean Dynamics (DYN)} \label{DYN} \minitoc % add a figure for  dynvor ens, ene latices %\vspace{2.cm} %------------------------------------------------------------------------------------------------------------- The vector invariant form of the momentum equations is the one most often used in applications of the \NEMO ocean model. The flux form option (see next section) has been present since version $2$. Options are defined through the \ngn{namdyn\_adv} namelist variables Coriolis and momentum advection terms are evaluated using a leapfrog scheme, $i.e.$ the velocity appearing in these expressions is centred in time (\textit{now} velocity). The vector invariant form of the momentum equations (\np{ln\_dynhpg\_vec}~=~true) is the one most often used in applications of the \NEMO ocean model. The flux form option (\np{ln\_dynhpg\_vec}~=false) (see next section) has been present since version $2$. Options are defined through the \ngn{namdyn\_adv} namelist variables. Coriolis and momentum advection terms are evaluated using a leapfrog scheme, $i.e.$ the velocity appearing in these expressions is centred in time (\textit{now} velocity). At the lateral boundaries either free slip, no slip or partial slip boundary conditions are applied following Chap.\ref{LBC}. %>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!ht]    \begin{center} \includegraphics[width=0.70\textwidth]{./TexFiles/Figures/Fig_DYN_een_triad.pdf} \includegraphics[width=0.70\textwidth]{Fig_DYN_een_triad} \caption{ \label{Fig_DYN_een_triad} Triads used in the energy and enstrophy conserving scheme (een) for %>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> Note that a key point in \eqref{Eq_een_e3f} is that the averaging in the \textbf{i}- and \textbf{j}- directions uses the masked vertical scale factor but is always divided by $4$, not by the sum of the masks at the four $T$-points. This preserves the continuity of $e_{3f}$ when one or more of the neighbouring $e_{3t}$ tends to zero and extends by continuity the value of $e_{3f}$ into the land areas. This feature is essential for the $z$-coordinate with partial steps. A key point in \eqref{Eq_een_e3f} is how the averaging in the \textbf{i}- and \textbf{j}- directions is made. It uses the sum of masked t-point vertical scale factor divided either by the sum of the four t-point masks (\np{ln\_dynvor\_een\_old}~=~false), or  just by $4$ (\np{ln\_dynvor\_een\_old}~=~true). The latter case preserves the continuity of $e_{3f}$ when one or more of the neighbouring $e_{3t}$ tends to zero and extends by continuity the value of $e_{3f}$ into the land areas. This case introduces a sub-grid-scale topography at f-points (with a systematic reduction of $e_{3f}$ when a model level intercept the bathymetry) that tends to reinforce the topostrophy of the flow ($i.e.$ the tendency of the flow to follow the isobaths) \citep{Penduff_al_OS07}. Next, the vorticity triads, ${^i_j}\mathbb{Q}^{i_p}_{j_p}$ can be defined at a $T$-point as \end{aligned}         \right. When \np{ln\_dynzad\_zts}~=~\textit{true}, a split-explicit time stepping with 5 sub-timesteps is used on the vertical advection term. This option can be useful when the value of the timestep is limited by vertical advection \citep{Lemarie_OM2015}. Note that in this case, a similar split-explicit time stepping should be used on vertical advection of tracer to ensure a better stability, an option which is only available with a TVD scheme (see \np{ln\_traadv\_tvd\_zts} in \S\ref{TRA_adv_tvd}). % ================================================================ those in the centred second order method. As the scheme already includes a diffusion component, it can be used without explicit  lateral diffusion on momentum ($i.e.$ \np{ln\_dynldf\_lap}=\np{ln\_dynldf\_bilap}=false), and it is recommended to do so. ($i.e.$ setting both \np{ln\_dynldf\_lap} and \np{ln\_dynldf\_bilap} to \textit{false}), and it is recommended to do so. The UBS scheme is not used in all directions. In the vertical, the centred $2^{nd}$ ($e_{3w}$). $\bullet$ Traditional coding with adaptation for ice shelf cavities (\np{ln\_dynhpg\_isf}=true). This scheme need the activation of ice shelf cavities (\np{ln\_isfcav}=true). $\bullet$ Pressure Jacobian scheme (prj) (a research paper in preparation) (\np{ln\_dynhpg\_prj}=true) pressure Jacobian method is used to solve the horizontal pressure gradient. This method can provide a more accurate calculation of the horizontal pressure gradient than the standard scheme. \subsection{Ice shelf cavity} \label{DYN_hpg_isf} Beneath an ice shelf, the total pressure gradient is the sum of the pressure gradient due to the ice shelf load and the pressure gradient due to the ocean load. If cavities are present (\np{ln\_isfcav}~=~true) these two terms can be calculated by setting \np{ln\_dynhpg\_isf}~=~true. No other scheme is working with ice shelves.\\ $\bullet$ The main hypothesis to compute the ice shelf load is that the ice shelf is in isostatic equilibrium. The top pressure is computed integrating a reference density profile (prescribed as density of a water at 34.4 PSU and -1.9$^{\circ}C$) from the sea surface to the ice shelf base, which corresponds to the load of the water column in which the ice shelf is floatting. This top pressure is constant over time. A detailed description of this method is described in \citet{Losch2008}.\\ $\bullet$ The ocean load is computed using the expression \eqref{Eq_dynhpg_sco} described in \ref{DYN_hpg_sco}. A treatment of the top and bottom partial cells similar to the one described in \ref{DYN_hpg_zps} is done to reduce the residual circulation generated by the top partial cell. %-------------------------------------------------------------------------------------------------------------- $\$\newline      %force an empty line %%% Options are defined through the \ngn{namdyn\_spg} namelist variables. The surface pressure gradient term is related to the representation of the free surface (\S\ref{PE_hor_pg}). The main distinction is between the fixed volume case (linear free surface) and the variable volume case (nonlinear free surface, \key{vvl} is defined). In the linear free surface case (\S\ref{PE_free_surface}) the vertical scale factors $e_{3}$ are fixed in time, while they are time-dependent in the nonlinear case (\S\ref{PE_free_surface}). With both linear and nonlinear free surface, external gravity waves are allowed in the equations, which imposes a very small time step when an explicit time stepping is used. Two methods are proposed to allow a longer time step for the three-dimensional equations: the filtered free surface, which is a modification of the continuous equations (see \eqref{Eq_PE_flt}), and the split-explicit free surface described below. The extra term introduced in the filtered method is calculated implicitly, so that the update of the next velocities is done in module \mdl{dynspg\_flt} and not in \mdl{dynnxt}. %%% The surface pressure gradient term is related to the representation of the free surface (\S\ref{PE_hor_pg}). The main distinction is between the fixed volume case (linear free surface) and the variable volume case (nonlinear free surface, \key{vvl} is defined). In the linear free surface case (\S\ref{PE_free_surface}) the vertical scale factors $e_{3}$ are fixed in time, while they are time-dependent in the nonlinear case (\S\ref{PE_free_surface}). With both linear and nonlinear free surface, external gravity waves are allowed in the equations, which imposes a very small time step when an explicit time stepping is used. Two methods are proposed to allow a longer time step for the three-dimensional equations: the filtered free surface, which is a modification of the continuous equations (see \eqref{Eq_PE_flt}), and the split-explicit free surface described below. The extra term introduced in the filtered method is calculated implicitly, so that the update of the next velocities is done in module \mdl{dynspg\_flt} and not in \mdl{dynnxt}. implicitly, so that a solver is used to compute it. As a consequence the update of the $next$ velocities is done in module \mdl{dynspg\_flt} and not in \mdl{dynnxt}. $\rdt_e = \rdt / nn\_baro$. This parameter can be optionally defined automatically (\np{ln\_bt\_nn\_auto}=true) considering that the stability of the barotropic system is essentially controled by external waves propagation. Maximum allowed Courant number is in that case time independent, and easily computed online from the input bathymetry. Maximum Courant number is in that case time independent, and easily computed online from the input bathymetry. Therefore, $\rdt_e$ is adjusted so that the Maximum allowed Courant number is smaller than \np{rn\_bt\_cmax}. %%% %>   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   > \begin{figure}[!t]    \begin{center} \includegraphics[width=0.7\textwidth]{./TexFiles/Figures/Fig_DYN_dynspg_ts.pdf} \includegraphics[width=0.7\textwidth]{Fig_DYN_dynspg_ts} \caption{  \label{Fig_DYN_dynspg_ts} Schematic of the split-explicit time stepping scheme for the external and internal modes. Time increases to the right. In this particular exemple, a boxcar averaging window over $nn\_baro$ barotropic time steps is used ($nn\_bt\_filt=1$) and $nn\_baro=5$. a boxcar averaging window over $nn\_baro$ barotropic time steps is used ($nn\_bt\_flt=1$) and $nn\_baro=5$. Internal mode time steps (which are also the model time steps) are denoted by $t-\rdt$, $t$ and $t+\rdt$. Variables with $k$ superscript refer to instantaneous barotropic variables, The former are used to obtain time filtered quantities at $t+\rdt$ while the latter are used to obtain time averaged transports to advect tracers. a) Forward time integration: \np{ln\_bt\_fw}=true, \np{ln\_bt\_ave}=true. b) Centred time integration: \np{ln\_bt\_fw}=false, \np{ln\_bt\_ave}=true. c) Forward time integration with no time filtering (POM-like scheme): \np{ln\_bt\_fw}=true, \np{ln\_bt\_ave}=false. } a) Forward time integration: \np{ln\_bt\_fw}=true, \np{ln\_bt\_av}=true. b) Centred time integration: \np{ln\_bt\_fw}=false, \np{ln\_bt\_av}=true. c) Forward time integration with no time filtering (POM-like scheme): \np{ln\_bt\_fw}=true, \np{ln\_bt\_av}=false. } \end{center}    \end{figure} %>   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   > In the default case (\np{ln\_bt\_fw}=true), the external mode is integrated between \textit{now} and  \textit{after} baroclinic time-steps (Fig.~\ref{Fig_DYN_dynspg_ts}a). To avoid aliasing of fast barotropic motions into three dimensional equations, time filtering is eventually applied on barotropic quantities (\np{ln\_bt\_ave}=true). In that case, the integration is extended slightly beyond  \textit{after} time step to provide time filtered quantities. quantities (\np{ln\_bt\_av}=true). In that case, the integration is extended slightly beyond  \textit{after} time step to provide time filtered quantities. These are used for the subsequent initialization of the barotropic mode in the following baroclinic step. Since external mode equations written at baroclinic time steps finally follow a forward time stepping scheme, %%% One can eventually choose to feedback instantaneous values by not using any time filter (\np{ln\_bt\_ave}=false). One can eventually choose to feedback instantaneous values by not using any time filter (\np{ln\_bt\_av}=false). In that case, external mode equations are continuous in time, ie they are not re-initialized when starting a new sub-stepping sequence. This is the method used so far in the POM model, the stability being maintained by refreshing at (almost) Besides the surface and bottom stresses (see the above section) which are introduced as boundary conditions on the vertical mixing, two other forcings enter the dynamical equations. One is the effect of atmospheric pressure on the ocean dynamics. Another forcing term is the tidal potential. Both of which will be introduced into the reference version soon. \gmcomment{atmospheric pressure is there!!!!    include its description } introduced as boundary conditions on the vertical mixing, three other forcings may enter the dynamical equations by affecting the surface pressure gradient. (1) When \np{ln\_apr\_dyn}~=~true (see \S\ref{SBC_apr}), the atmospheric pressure is taken into account when computing the surface pressure gradient. (2) When \np{ln\_tide\_pot}~=~true and \key{tide} is defined (see \S\ref{SBC_tide}), the tidal potential is taken into account when computing the surface pressure gradient. (3) When \np{nn\_ice\_embd}~=~2 and LIM or CICE is used ($i.e.$ when the sea-ice is embedded in the ocean), the snow-ice mass is taken into account when computing the surface pressure gradient. \gmcomment{ missing : the lateral boundary condition !!!   another external forcing } % ================================================================ % ================================================================ \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_LBC.tex

 r4147 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter � Lateral Boundary Condition (LBC) % Chapter — Lateral Boundary Condition (LBC) % ================================================================ \chapter{Lateral Boundary Condition (LBC) } %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]     \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_LBC_uv.pdf} \includegraphics[width=0.90\textwidth]{Fig_LBC_uv} \caption{  \label{Fig_LBC_uv} Lateral boundary (thick line) at T-level. The velocity normal to the boundary is set to zero.} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!p] \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_LBC_shlat.pdf} \includegraphics[width=0.90\textwidth]{Fig_LBC_shlat} \caption{     \label{Fig_LBC_shlat} lateral boundary condition (a) free-slip ($rn\_shlat=0$) ; (b) no-slip ($rn\_shlat=2$) %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]     \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_LBC_jperio.pdf} \includegraphics[width=1.0\textwidth]{Fig_LBC_jperio} \caption{    \label{Fig_LBC_jperio} setting of (a) east-west cyclic  (b) symmetric across the equator boundary conditions.} %        North fold (\textit{jperio = 3 }to $6)$ % ------------------------------------------------------------------------------------------------------------- \subsection{North-fold (\textit{jperio = 3 }to $6)$ } \subsection{North-fold (\textit{jperio = 3 }to $6$) } \label{LBC_north_fold} The north fold boundary condition has been introduced in order to handle the north boundary of a three-polar ORCA grid. Such a grid has two poles in the northern hemisphere. \colorbox{yellow}{to be completed...} boundary of a three-polar ORCA grid. Such a grid has two poles in the northern hemisphere (Fig.\ref{Fig_MISC_ORCA_msh}, and thus requires a specific treatment illustrated in Fig.\ref{Fig_North_Fold_T}. Further information can be found in \mdl{lbcnfd} module which applies the north fold boundary condition. %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]    \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_North_Fold_T.pdf} \includegraphics[width=0.90\textwidth]{Fig_North_Fold_T} \caption{    \label{Fig_North_Fold_T} North fold boundary with a $T$-point pivot and cyclic east-west boundary condition ocean model. Second order finite difference schemes lead to local discrete operators that depend at the very most on one neighbouring point. The only non-local computations concern the vertical physics (implicit diffusion, 1.5 non-local computations concern the vertical physics (implicit diffusion, turbulent closure scheme, ...) (delocalization over the whole water column), and the solving of the elliptic equation associated with the surface pressure gradient computation (delocalization over the whole horizontal domain). Therefore, a pencil strategy is used for the data sub-structuration \gmcomment{no idea what this means!} : the 3D initial domain is laid out on local processor memories following a 2D horizontal topological splitting. Each sub-domain phase starts: each processor sends to its neighbouring processors the update values of the points corresponding to the interior overlapping area to its neighbouring sub-domain (i.e. the innermost of the two overlapping rows). The communication is done through message passing. Usually the parallel virtual language, PVM, is used as it is a standard language available on  nearly  all MPP computers. More specific languages (i.e. computer dependant languages) can be easily used to speed up the communication, such as SHEM on a T3E computer. The data exchanges between processors are required at the very neighbouring sub-domain ($i.e.$ the innermost of the two overlapping rows). The communication is done through the Message Passing Interface (MPI). The data exchanges between processors are required at the very place where lateral domain boundary conditions are set in the mono-domain computation (\S III.10-c): the lbc\_lnk routine which manages such conditions is substituted by mpplnk.F or mpplnk2.F routine when running on an MPP computer (\key{mpp\_mpi} defined). It has to be pointed out that when using the MPP version of the model, the east-west cyclic boundary condition is done implicitly, whilst the south-symmetric boundary condition option is not available. computation : the \rou{lbc\_lnk} routine (found in \mdl{lbclnk} module) which manages such conditions is interfaced with routines found in \mdl{lib\_mpp} module when running on an MPP computer ($i.e.$ when \key{mpp\_mpi} defined). It has to be pointed out that when using the MPP version of the model, the east-west cyclic boundary condition is done implicitly, whilst the south-symmetric boundary condition option is not available. %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]    \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_mpp.pdf} \includegraphics[width=0.90\textwidth]{Fig_mpp} \caption{   \label{Fig_mpp} Positioning of a sub-domain when massively parallel processing is used. } %>>>>>>>>>>>>>>>>>>>>>>>>>>>> In the standard version of the OPA model, the splitting is regular and arithmetic. the i-axis is divided by \jp{jpni} and the j-axis by \jp{jpnj} for a number of processors \jp{jpnij} most often equal to $jpni \times jpnj$ (model parameters set in \mdl{par\_oce}). Each processor is independent and without message passing or synchronous process \gmcomment{how does a synchronous process relate to this?}, programs run alone and access just its own local memory. For this reason, the main model dimensions are now the local dimensions of the subdomain (pencil) In the standard version of \NEMO, the splitting is regular and arithmetic. The i-axis is divided by \jp{jpni} and the j-axis by \jp{jpnj} for a number of processors \jp{jpnij} most often equal to $jpni \times jpnj$ (parameters set in \ngn{nammpp} namelist). Each processor is independent and without message passing or synchronous process, programs run alone and access just its own local memory. For this reason, the main model dimensions are now the local dimensions of the subdomain (pencil) that are named \jp{jpi}, \jp{jpj}, \jp{jpk}. These dimensions include the internal domain and the overlapping rows. The number of rows to exchange (known as where \jp{jpni}, \jp{jpnj} are the number of processors following the i- and j-axis. \colorbox{yellow}{Figure IV.3: example of a domain splitting with 9 processors and no east-west cyclic boundary conditions.} One also defines variables nldi and nlei which correspond to the internal domain bounds, and the variables nimpp and njmpp which are the position of the (1,1) grid-point in the global domain. An element of $T_{l}$, a local array (subdomain) corresponds to an element of $T_{g}$, a global array (whole domain) by the relationship: One also defines variables nldi and nlei which correspond to the internal domain bounds, and the variables nimpp and njmpp which are the position of the (1,1) grid-point in the global domain. An element of $T_{l}$, a local array (subdomain) corresponds to an element of $T_{g}$, a global array (whole domain) by the relationship: \label{Eq_lbc_nimpp} T_{g} (i+nimpp-1,j+njmpp-1,k) = T_{l} (i,j,k), nproc. In the standard version, a processor has no more than four neighbouring processors named nono (for north), noea (east), noso (south) and nowe (west) and two variables, nbondi and nbondj, indicate the relative position of the processor \colorbox{yellow}{(see Fig.IV.3)}: and two variables, nbondi and nbondj, indicate the relative position of the processor : \begin{itemize} \item       nbondi = -1    an east neighbour, no west processor, processor on its overlapping row, and sends the data issued from internal domain corresponding to the overlapping row of the other processor. \colorbox{yellow}{Figure IV.4: pencil splitting with the additional outer halos } global ocean where more than 50 \% of points are land points. For this reason, a pre-processing tool can be used to choose the mpp domain decomposition with a maximum number of only land points processors, which can then be eliminated. (For example, the mpp\_optimiz tools, available from the DRAKKAR web site.) maximum number of only land points processors, which can then be eliminated (Fig. \ref{Fig_mppini2}) (For example, the mpp\_optimiz tools, available from the DRAKKAR web site). This optimisation is dependent on the specific bathymetry employed. The user then chooses optimal parameters \jp{jpni}, \jp{jpnj} and \jp{jpnij} with $jpnij < jpni \times jpnj$, leading to the elimination of $jpni \times jpnj - jpnij$ land processors. When those parameters are specified in module \mdl{par\_oce}, land processors. When those parameters are specified in \ngn{nammpp} namelist, the algorithm in the \rou{inimpp2} routine sets each processor's parameters (nbound, nono, noea,...) so that the land-only processors are not taken into account. \colorbox{yellow}{Note that the inimpp2 routine is general so that the original inimpp \gmcomment{Note that the inimpp2 routine is general so that the original inimpp routine should be suppressed from the code.} When land processors are eliminated, the value corresponding to these locations in the model output files is zero. Note that this is a problem for a mesh output file written by such a model configuration, because model users often divide by the scale factors ($e1t$, $e2t$, etc) and do not expect the grid size to be zero, even on land. It may be best not to eliminate land processors when running the model especially to write the mesh files as outputs (when \np{nn\_msh} namelist parameter differs from 0). %% \gmcomment{Steven : dont understand this, no land processor means no output file covering this part of globe; its only when files are stitched together into one that you can leave a hole} %% the model output files is undefined. Note that this is a problem for the meshmask file which requires to be defined over the whole domain. Therefore, user should not eliminate land processors when creating a meshmask file ($i.e.$ when setting a non-zero value to \np{nn\_msh}). %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!ht]     \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_mppini2.pdf} \includegraphics[width=0.90\textwidth]{Fig_mppini2} \caption {    \label{Fig_mppini2} Example of Atlantic domain defined for the CLIPPER projet. Initial grid is %>>>>>>>>>>>>>>>>>>>>>>>>>>>> % ================================================================ % Open Boundary Conditions % ================================================================ \section{Open Boundary Conditions (\key{obc}) (OBC)} \label{LBC_obc} %-----------------------------------------nam_obc  ------------------------------------------- %-    nobc_dta    =    0     !  = 0 the obc data are equal to the initial state %-                           !  = 1 the obc data are read in 'obc   .dta' files %-    rn_dpein      =    1.    !  ??? %-    rn_dpwin      =    1.    !  ??? %-    rn_dpnin      =   30.    !  ??? %-    rn_dpsin      =    1.    !  ??? %-    rn_dpeob      = 1500.    !  time relaxation (days) for the east  open boundary %-    rn_dpwob      =   15.    !    "        "           for the west  open boundary %-    rn_dpnob      =  150.    !    "        "           for the north open boundary %-    rn_dpsob      =   15.    !    "        "           for the south open boundary %-    ln_obc_clim = .true.   !  climatological obc data files (default T) %-    ln_vol_cst  = .true.   !  total volume conserved \namdisplay{namobc} It is often necessary to implement a model configuration limited to an oceanic region or a basin, which communicates with the rest of the global ocean through ''open boundaries''. As stated by \citet{Roed1986}, an open boundary is a computational border where the aim of the calculations is to allow the perturbations generated inside the computational domain to leave it without deterioration of the inner model solution. However, an open boundary also has to let information from the outer ocean enter the model and should support inflow and outflow conditions. The open boundary package OBC is the first open boundary option developed in NEMO (originally in OPA8.2). It allows the user to \begin{itemize} \item tell the model that a boundary is ''open'' and not closed by a wall, for example by modifying the calculation of the divergence of velocity there; \item impose values of tracers and velocities at that boundary (values which may be taken from a climatology): this is thefixed OBC'' option. \item calculate boundary values by a sophisticated algorithm combining radiation and relaxation (radiative OBC'' option) \end{itemize} Options are defined through the \ngn{namobc} namelist variables. The package resides in the OBC directory. It is described here in four parts: the boundary geometry (parameters to be set in \mdl{obc\_par}), the forcing data at the boundaries (module \mdl{obcdta}),  the radiation algorithm involving the namelist and module \mdl{obcrad}, and a brief presentation of boundary update and restart files. %---------------------------------------------- \subsection{Boundary geometry} \label{OBC_geom} % First one has to realize that open boundaries may not necessarily be located at the extremities of the computational domain. They may exist in the middle of the domain, for example at Gibraltar Straits if one wants to avoid including the Mediterranean in an Atlantic domain. This flexibility has been found necessary for the CLIPPER project \citep{Treguier_al_JGR01}. Because of the complexity of the geometry of ocean basins, it may even be necessary to have more than one ''west'' open boundary, more than one ''north'', etc. This is not possible with the OBC option: only one open boundary of each kind, west, east, south and north is allowed; these names refer to the grid geometry (not to the direction of the geographical ''west'', ''east'', etc). The open boundary geometry is set by a series of parameters in the module \mdl{obc\_par}. For an eastern open boundary, parameters are \jp{lp\_obc\_east} (true if an east open boundary exists), \jp{jpieob} the $i$-index along which the eastern open boundary (eob) is located, \jp{jpjed} the $j$-index at which it starts, and \jp{jpjef} the $j$-index where it ends (note $d$ is for ''d\'{e}but'' and $f$ for ''fin'' in French). Similar parameters exist for the west, south and north cases (Table~\ref{Tab_obc_param}). %--------------------------------------------------TABLE-------------------------------------------------- \begin{table}[htbp]     \begin{center}    \begin{tabular}{|l|c|c|c|} \hline Boundary and  & Constant index  & Starting index (d\'{e}but) & Ending index (fin) \\ Logical flag  &                 &                            &                     \\ \hline West          & \jp{jpiwob} $>= 2$         &  \jp{jpjwd}$>= 2$          &  \jp{jpjwf}<= \np{jpjglo}-1 \\ lp\_obc\_west & $i$-index of a $u$ point   & $j$ of a $T$ point   &$j$ of a $T$ point \\ \hline East            & \jp{jpieob}$<=$\np{jpiglo}-2&\jp{jpjed} $>= 2$         & \jp{jpjef}$<=$ \np{jpjglo}-1 \\ lp\_obc\_east  & $i$-index of a $u$ point    & $j$ of a $T$ point & $j$ of a $T$ point \\ \hline South           & \jp{jpjsob} $>= 2$         & \jp{jpisd} $>= 2$          & \jp{jpisf}$<=$\np{jpiglo}-1 \\ lp\_obc\_south  & $j$-index of a $v$ point   & $i$ of a $T$ point   & $i$ of a $T$ point \\ \hline North           & \jp{jpjnob} $<=$ \np{jpjglo}-2& \jp{jpind} $>= 2$        & \jp{jpinf}$<=$\np{jpiglo}-1 \\ lp\_obc\_north  & $j$-index of a $v$ point      & $i$  of a $T$ point & $i$ of a $T$ point \\ \hline \end{tabular}    \end{center} \caption{     \label{Tab_obc_param} Names of different indices relating to the open boundaries. In the case of a completely open ocean domain with four ocean boundaries, the parameters take exactly the values indicated.} \end{table} %------------------------------------------------------------------------------------------------------------ The open boundaries must be along coordinate lines. On the C-grid, the boundary itself is along a line of normal velocity points: $v$ points for a zonal open boundary (the south or north one), and $u$ points for a meridional open boundary (the west or east one). Another constraint is that there still must be a row of masked points all around the domain, as if the domain were a closed basin (unless periodic conditions are used together with open boundary conditions). Therefore, an open boundary cannot be located at the first/last index, namely, 1, \jp{jpiglo} or \jp{jpjglo}. Also, the open boundary algorithm involves calculating the normal velocity points situated just on the boundary, as well as the tangential velocity and temperature and salinity just outside the boundary. This means that for a west/south boundary, normal velocities and temperature are calculated at the same index \jp{jpiwob} and \jp{jpjsob}, respectively. For an east/north boundary, the normal velocity is calculated at index \jp{jpieob} and \jp{jpjnob}, but the outside'' temperature is at index \jp{jpieob}+1 and \jp{jpjnob}+1. This means that \jp{jpieob}, \jp{jpjnob} cannot be bigger than \jp{jpiglo}-2, \jp{jpjglo}-2. The starting and ending indices are to be thought of as $T$ point indices: in many cases they indicate the first land $T$-point, at the extremity of an open boundary (the coast line follows the $f$ grid points, see Fig.~\ref{Fig_obc_north} for an example of a northern open boundary). All indices are relative to the global domain. In the free surface case it is possible to have ocean corners'', that is, an open boundary starting and ending in the ocean. %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]     \begin{center} \includegraphics[width=0.70\textwidth]{./TexFiles/Figures/Fig_obc_north.pdf} \caption{    \label{Fig_obc_north} Localization of the North open boundary points.} \end{center}     \end{figure} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> Although not compulsory, it is highly recommended that the bathymetry in the vicinity of an open boundary follows the following rule: in the direction perpendicular to the open line, the water depth should be constant for 4 grid points. This is in order to ensure that the radiation condition, which involves model variables next to the boundary, is calculated in a consistent way. On Fig.\ref{Fig_obc_north} we indicate by an $=$ symbol, the points which should have the same depth. It means that at the 4 points near the boundary, the bathymetry is cylindrical \gmcomment{not sure why cylindrical}. The line behind the open $T$-line must be 0 in the bathymetry file (as shown on Fig.\ref{Fig_obc_north} for example). %---------------------------------------------- \subsection{Boundary data} \label{OBC_data} It is necessary to provide information at the boundaries. The simplest case is when this information does not change in time and is equal to the initial conditions (namelist variable \np{nn\_obcdta}=0). This is the case for the standard configuration EEL5 with open boundaries. When (\np{nn\_obcdta}=1), open boundary information is read from netcdf files. For convenience the input files are supposed to be similar to the ''history'' NEMO output files, for dimension names and variable names. Open boundary arrays must be dimensioned according to the parameters of table~ \ref{Tab_obc_param}: for example, at the western boundary, arrays have a dimension of \jp{jpwf}-\jp{jpwd}+1 in the horizontal and \jp{jpk} in the vertical. When ocean observations are used to generate the boundary data (a hydrographic section for example, as in \citet{Treguier_al_JGR01}) it happens often that only the velocity normal to the boundary is known, which is the reason why the initial OBC code assumes that only $T$, $S$, and the normal velocity ($u$ or $v$) needs to be specified. As more and more global model solutions and ocean analysis products become available, it will be possible to provide information about all the variables (including the tangential velocity) so that the specification of four variables at each boundaries will become standard. For the sea surface height, one must distinguish between the filtered free surface case and the time-splitting or explicit treatment of the free surface. In the first case, it is assumed that the user does not wish to represent high frequency motions such as tides. The boundary condition is thus one of zero normal gradient of sea surface height at the open boundaries, following \citet{Marchesiello2001}. No information other than the total velocity needs to be provided at the open boundaries in that case. In the other two cases (time splitting or explicit free surface), the user must provide barotropic information (sea surface height and barotropic velocities) and the use of the Flather algorithm for barotropic variables is recommanded. However, this algorithm has not yet been fully tested and bugs remain in NEMO v2.3. Users should read the code carefully before using it. Finally, in the case of the rigid lid approximation the barotropic streamfunction must be provided, as documented in \citet{Treguier_al_JGR01}). This option is no longer recommended but remains in NEMO V2.3. One frequently encountered case is when an open boundary domain is constructed from a global or larger scale NEMO configuration. Assuming the domain corresponds to indices $ib:ie$, $jb:je$ of the global domain, the bathymetry and forcing of the small domain can be created by using the following netcdf utility on the global files: ncks -F $-d\;x,ib,ie$ $-d\;y,jb,je$ (part of the nco series of utilities, see their \href{http://nco.sourceforge.net}{website}). The open boundary files can be constructed using ncks commands, following table~\ref{Tab_obc_ind}. %--------------------------------------------------TABLE-------------------------------------------------- \begin{table}[htbp]     \begin{center}      \begin{tabular}{|l|c|c|c|c|c|} \hline OBC  & Variable   & file name      & Index  & Start  & end  \\ West &  T,S       &   obcwest\_TS.nc &  $ib$+1     &   $jb$+1 &  $je-1$  \\ &    U       &   obcwest\_U.nc  &  $ib$+1     &   $jb$+1 &  $je-1$  \\ &    V       &   obcwest\_V.nc  &  $ib$+1     &   $jb$+1 &  $je-1$  \\ \hline East &  T,S       &   obceast\_TS.nc &  $ie$-1     &   $jb$+1 &  $je-1$  \\ &    U       &   obceast\_U.nc  &  $ie$-2     &   $jb$+1 &  $je-1$  \\ &    V       &   obceast\_V.nc  &  $ie$-1     &   $jb$+1 &  $je-1$  \\ \hline South &  T,S      &   obcsouth\_TS.nc &  $jb$+1     &  $ib$+1 &  $ie-1$  \\ &    U      &   obcsouth\_U.nc  &  $jb$+1     &  $ib$+1 &  $ie-1$  \\ &    V      &   obcsouth\_V.nc  &  $jb$+1     &  $ib$+1 &  $ie-1$  \\ \hline North &  T,S      &   obcnorth\_TS.nc &  $je$-1     &  $ib$+1 &  $ie-1$  \\ &    U      &   obcnorth\_U.nc  &  $je$-1     &  $ib$+1 &  $ie-1$  \\ &    V      &   obcnorth\_V.nc  &  $je$-2     &  $ib$+1 &  $ie-1$  \\ \hline \end{tabular}     \end{center} \caption{    \label{Tab_obc_ind} Requirements for creating open boundary files from a global configuration, appropriate for the subdomain of indices $ib:ie$, $jb:je$. Index'' designates the $i$ or $j$ index along which the $u$ of $v$ boundary point is situated in the global configuration, starting and ending with the $j$ or $i$ indices indicated. For example, to generate file obcnorth\_V.nc, use the command ncks $-F$ $-d\;y,je-2$  $-d\;x,ib+1,ie-1$ } \end{table} %----------------------------------------------------------------------------------------------------------- It is assumed that the open boundary files contain the variables for the period of the model integration. If the boundary files contain one time frame, the boundary data is held fixed in time. If the files contain 12 values, it is assumed that the input is a climatology for a repeated annual cycle (corresponding to the case \np{ln\_obc\_clim} =true). The case of an arbitrary number of time frames is not yet implemented correctly; the user is required to write his own code in the module \mdl{obc\_dta} to deal with this situation. \subsection{Radiation algorithm} \label{OBC_rad} The art of open boundary management consists in applying a constraint strong enough that the inner domain "feels" the rest of the ocean, but weak enough that perturbations are allowed to leave the domain with minimum false reflections of energy. The constraints are specified separately at each boundary as time scales for ''inflow'' and ''outflow'' as defined below. The time scales are set (in days) by namelist parameters such as \np{rn\_dpein}, \np{rn\_dpeob} for the eastern open boundary for example. When both time scales are zero for a given boundary ($e.g.$ for the western boundary, \jp{lp\_obc\_west}=true, \np{rn\_dpwob}=0 and \np{rn\_dpwin}=0) this means that the boundary in question is a ''fixed '' boundary where the solution is set exactly by the boundary data. This is not recommended, except in combination with increased viscosity in a ''sponge'' layer next to the boundary in order to avoid spurious reflections. The radiation\/relaxation \gmcomment{the / doesnt seem to appear in the output} algorithm is applied when either relaxation time (for ''inflow'' or ''outflow'') is non-zero. It has been developed and tested in the SPEM model and its successor ROMS \citep{Barnier1996, Marchesiello2001}, which is an $s$-coordinate model on an Arakawa C-grid. Although the algorithm has been numerically successful in the CLIPPER Atlantic models, the physics do not work as expected \citep{Treguier_al_JGR01}. Users are invited to consider open boundary conditions (OBC hereafter) with some scepticism \citep{Durran2001, Blayo2005}. The first part of the algorithm calculates a phase velocity to determine whether perturbations tend to propagate toward, or away from, the boundary. Let us consider a model variable $\phi$. The phase velocities ($C_{\phi x}$,$C_{\phi y}$) for the variable $\phi$, in the directions normal and tangential to the boundary are \label{Eq_obc_cphi} C_{\phi x} = \frac{ -\phi_{t} }{ ( \phi_{x}^{2} + \phi_{y}^{2}) } \phi_{x} \;\;\;\;\; \;\;\; C_{\phi y} = \frac{ -\phi_{t} }{ ( \phi_{x}^{2} + \phi_{y}^{2}) } \phi_{y}. Following \citet{Treguier_al_JGR01} and \citet{Marchesiello2001} we retain only the normal component of the velocity, $C_{\phi x}$, setting $C_{\phi y} =0$ (but unlike the original Orlanski radiation algorithm we retain $\phi_{y}$ in the expression for $C_{\phi x}$). The discrete form of (\ref{Eq_obc_cphi}), described by \citet{Barnier1998}, takes into account the two rows of grid points situated inside the domain next to the boundary, and the three previous time steps ($n$, $n-1$, and $n-2$). The same equation can then be discretized at the boundary at time steps $n-1$, $n$ and $n+1$ \gmcomment{since the original was three time-level} in order to extrapolate for the new boundary value $\phi^{n+1}$. In the open boundary algorithm as implemented in NEMO v2.3, the new boundary values are updated differently depending on the sign of $C_{\phi x}$. Let us take an eastern boundary as an example. The solution for variable $\phi$ at the boundary is given by a generalized wave equation with phase velocity $C_{\phi}$, with the addition of a relaxation term, as: \begin{eqnarray} \phi_{t} &  =  & -C_{\phi x} \phi_{x} + \frac{1}{\tau_{o}} (\phi_{c}-\phi) \;\;\; \;\;\; \;\;\; (C_{\phi x} > 0), \label{Eq_obc_rado} \\ \phi_{t} &  =  & \frac{1}{\tau_{i}} (\phi_{c}-\phi) \;\;\; \;\;\; \;\;\;\;\;\; (C_{\phi x} < 0), \label{Eq_obc_radi} \end{eqnarray} where $\phi_{c}$ is the estimate of $\phi$ at the boundary, provided as boundary data. Note that in (\ref{Eq_obc_rado}), $C_{\phi x}$ is bounded by the ratio $\delta x/\delta t$ for stability reasons. When $C_{\phi x}$ is eastward (outward propagation), the radiation condition (\ref{Eq_obc_rado}) is used. When  $C_{\phi x}$ is westward (inward propagation), (\ref{Eq_obc_radi}) is used with a strong relaxation to climatology (usually $\tau_{i}=\np{rn\_dpein}=$1~day). Equation (\ref{Eq_obc_radi}) is solved with a Euler time-stepping scheme. As a consequence, setting $\tau_{i}$ smaller than, or equal to the time step is equivalent to a fixed boundary condition. A time scale of one day is usually a good compromise which guarantees that the inflow conditions remain close to climatology while ensuring numerical stability. In  the case of a western boundary located in the Eastern Atlantic, \citet{Penduff_al_JGR00} have been able to implement the radiation algorithm without any boundary data, using persistence from the previous time step instead. This solution has not worked in other cases \citep{Treguier_al_JGR01}, so that the use of boundary data is recommended. Even in the outflow condition (\ref{Eq_obc_rado}), we have found it desirable to maintain a weak relaxation to climatology. The time step is usually chosen so as to be larger than typical turbulent scales (of order 1000~days \gmcomment{or maybe seconds?}). The radiation condition is applied to the model variables: temperature, salinity, tangential and normal velocities. For normal and tangential velocities, $u$ and $v$, radiation is applied with phase velocities calculated from $u$ and $v$ respectively. For the radiation of tracers, we use the phase velocity calculated from the tangential velocity in order to avoid calculating too many independent radiation velocities and because tangential velocities and tracers have the same position along the boundary on a C-grid. \subsection{Domain decomposition (\key{mpp\_mpi})} \label{OBC_mpp} When \key{mpp\_mpi} is active in the code, the computational domain is divided into rectangles that are attributed each to a different processor. The open boundary code is mpp-compatible'' up to a certain point. The radiation algorithm will not work if there is an mpp subdomain boundary parallel to the open boundary at the index of the boundary, or the grid point after (outside), or three grid points before (inside). On the other hand, there is no problem if an mpp subdomain boundary cuts the open boundary perpendicularly. These geometrical limitations must be checked for by the user (there is no safeguard in the code). The general principle for the open boundary mpp code is that loops over the open boundaries {not sure what this means} are performed on local indices (nie0, nie1, nje0, nje1 for an eastern boundary for instance) that are initialized in module \mdl{obc\_ini}. Those indices have relevant values on the processors that contain a segment of an open boundary. For processors that do not include an open boundary segment, the indices are such that the calculations within the loops are not performed. \gmcomment{I dont understand most of the last few sentences} Arrays of climatological data that are read from files are seen by all processors and have the same dimensions for all (for instance, for the eastern boundary, uedta(jpjglo,jpk,2)). On the other hand, the arrays for the calculation of radiation are local to each processor (uebnd(jpj,jpk,3,3) for instance).  This allowed the CLIPPER model for example, to save on memory where the eastern boundary crossed 8 processors so that \jp{jpj} was much smaller than (\jp{jpjef}-\jp{jpjed}+1). \subsection{Volume conservation} \label{OBC_vol} It is necessary to control the volume inside a domain when using open boundaries. With fixed boundaries, it is enough to ensure that the total inflow/outflow has reasonable values (either zero or a value compatible with an observed volume balance). When using radiative boundary conditions it is necessary to have a volume constraint because each open boundary works independently from the others. The methodology used to control this volume is identical to the one coded in the ROMS model \citep{Marchesiello2001}. %---------------------------------------- EXTRAS \colorbox{yellow}{Explain obc\_vol{\ldots}} \colorbox{yellow}{OBC algorithm for update, OBC restart, list of routines where obc key appears{\ldots}} \colorbox{yellow}{OBC rigid lid? {\ldots}} % ==================================================================== %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]      \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_LBC_bdy_geom.pdf} \includegraphics[width=1.0\textwidth]{Fig_LBC_bdy_geom} \caption {      \label{Fig_LBC_bdy_geom} Example of geometry of unstructured open boundary} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]     \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_LBC_nc_header.pdf} \includegraphics[width=1.0\textwidth]{Fig_LBC_nc_header} \caption {     \label{Fig_LBC_nc_header} Example of the header for a coordinates.bdy.nc file} \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_LDF.tex

 r4147 % ================================================================ % Chapter � Lateral Ocean Physics (LDF) \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter ———  Lateral Ocean Physics (LDF) % ================================================================ \chapter{Lateral Ocean Physics (LDF)} When none of the \textbf{key\_dynldf\_...} and \textbf{key\_traldf\_...} keys are defined, a constant value is used over the whole ocean for momentum and tracers, which is specified through the \np{rn\_ahm0} and \np{rn\_aht0} namelist tracers, which is specified through the \np{rn\_ahm\_0\_lap} and \np{rn\_aht\_0} namelist parameters. mixing coefficients will require 3D arrays. In the 1D option, a hyperbolic variation of the lateral mixing coefficient is introduced in which the surface value is \np{rn\_aht0} (\np{rn\_ahm0}), the bottom value is 1/4 of the surface value, \np{rn\_aht\_0} (\np{rn\_ahm\_0\_lap}), the bottom value is 1/4 of the surface value, and the transition takes place around z=300~m with a width of 300~m ($i.e.$ both the depth and the width of the inflection point are set to 300~m). where $e_{max}$ is the maximum of $e_1$ and $e_2$ taken over the whole masked ocean domain, and $A_o^l$ is the \np{rn\_ahm0} (momentum) or \np{rn\_aht0} (tracer) ocean domain, and $A_o^l$ is the \np{rn\_ahm\_0\_lap} (momentum) or \np{rn\_aht\_0} (tracer) namelist parameter. This variation is intended to reflect the lesser need for subgrid scale eddy mixing where the grid size is smaller in the domain. It was introduced in Other formulations can be introduced by the user for a given configuration. For example, in the ORCA2 global ocean model (see Configurations), the laplacian viscosity operator uses \np{rn\_ahm0}~= 4.10$^4$ m$^2$/s poleward of 20$^{\circ}$ north and south and decreases linearly to \np{rn\_aht0}~= 2.10$^3$ m$^2$/s viscosity operator uses \np{rn\_ahm\_0\_lap}~= 4.10$^4$ m$^2$/s poleward of 20\deg north and south and decreases linearly to \np{rn\_aht\_0}~= 2.10$^3$ m$^2$/s at the equator \citep{Madec_al_JPO96, Delecluse_Madec_Bk00}. This modification can be found in routine \rou{ldf\_dyn\_c2d\_orca} defined in \mdl{ldfdyn\_c2d}. \subsubsection{Space and Time Varying Mixing Coefficients} There is no default specification of space and time varying mixing coefficient. The only case available is specific to the ORCA2 and ORCA05 global ocean configurations. It provides only a tracer mixing coefficient for eddy induced velocity (ORCA2) or both iso-neutral and eddy induced velocity (ORCA05) that depends on the local growth rate of baroclinic instability. This specification is actually used when an ORCA key There are no default specifications of space and time varying mixing coefficient.  One available case is specific to the ORCA2 and ORCA05 global ocean configurations. It provides only a tracer mixing coefficient for eddy induced velocity (ORCA2) or both iso-neutral and eddy induced velocity (ORCA05) that depends on the local growth rate of baroclinic instability. This specification is actually used when an ORCA key and both \key{traldf\_eiv} and \key{traldf\_c2d} are defined. \subsubsection{Smagorinsky viscosity (\key{dynldf\_c3d} and \key{dynldf\_smag})} The \key{dynldf\_smag} key activates a 3D, time-varying viscosity that depends on the resolved motions. Following \citep{Smagorinsky_93} the viscosity coefficient is set proportional to a local deformation rate based on the horizontal shear and tension, namely: A_{m_{Smag}} = \left(\frac{{\sf CM_{Smag}}}{\pi}\right)^2L^2\vert{D}\vert \noindent where the deformation rate $\vert{D}\vert$ is given by \vert{D}\vert=\sqrt{\left({\frac{\partial{u}} {\partial{x}}} -{\frac{\partial{v}} {\partial{y}}}\right)^2 +  \left({\frac{\partial{u}} {\partial{y}}} +{\frac{\partial{v}} {\partial{x}}}\right)^2} \noindent and $L$ is the local gridscale given by: L^2 = \frac{2{e_1}^2 {e_2}^2}{\left ( {e_1}^2 + {e_2}^2 \right )} \citep{Griffies_Hallberg_MWR00} suggest values in the range 2.2 to 4.0 of the coefficient $\sf CM_{Smag}$ for oceanic flows. This value is set via the \np{rn\_cmsmag\_1} namelist parameter. An additional parameter: \np{rn\_cmsh} is included in NEMO for experimenting with the contribution of the shear term. A value of 1.0 (the default) calculates the deformation rate as above; a value of 0.0 will discard the shear term entirely. For numerical stability, the calculated viscosity is bounded according to the following: {\rm MIN}\left ({ L^2\over {8\Delta{t}}}, rn\_ahm\_m\_lap\right ) \geq A_{m_{Smag}} \geq rn\_ahm\_0\_lap \noindent with both parameters for the upper and lower bounds being provided via the indicated namelist parameters. \bigskip When $ln\_dynldf\_bilap = .true.$, a biharmonic version of the Smagorinsky viscosity is also available which sets a coefficient for the biharmonic viscosity as: B_{m_{Smag}} = - \left(\frac{{\sf CM_{bSmag}}}{\pi}\right)^2 {L^4\over 8}\vert{D}\vert \noindent which is bounded according to: {\rm MAX}\left (-{ L^4\over {64\Delta{t}}}, rn\_ahm\_m\_blp\right ) \leq B_{m_{Smag}} \leq rn\_ahm\_0\_blp \noindent Note the reversal of the inequalities here because NEMO requires the biharmonic coefficients as negative numbers. $\sf CM_{bSmag}$ is set via the \np{rn\_cmsmag\_2} namelist parameter and the bounding values have corresponding entries in the namelist too. \bigskip The current implementation in NEMO also allows for 3D, time-varying diffusivities to be set using the Smagorinsky approach. Users should note that this option is not recommended for many applications since diffusivities will tend to be largest near boundaries (where shears are greatest) leading to spurious upwellings (\citep{Griffies_Bk04}, chapter 18.3.4). Nevertheless the option is there for those wishing to experiment. This choice requires both \key{traldf\_c3d} and \key{traldf\_smag} and uses the \np{rn\_chsmag} (${\sf CH_{Smag}}$), \np{rn\_smsh} and \np{rn\_aht\_m} namelist parameters in an analogous way to \np{rn\_cmsmag\_1}, \np{rn\_cmsh} and \np{rn\_ahm\_m\_lap} (see above) to set the diffusion coefficient: A_{h_{Smag}} = \left(\frac{{\sf CH_{Smag}}}{\pi}\right)^2L^2\vert{D}\vert For numerical stability, the calculated diffusivity is bounded according to the following: {\rm MIN}\left ({ L^2\over {8\Delta{t}}}, rn\_aht\_m\right ) \geq A_{h_{Smag}} \geq rn\_aht\_0 $\$\newline    % force a new ligne (3) for isopycnal diffusion on momentum or tracers, an additional purely horizontal background diffusion with uniform coefficient can be added by setting a non zero value of \np{rn\_ahmb0} or \np{rn\_ahtb0}, a background horizontal setting a non zero value of \np{rn\_ahmb\_0} or \np{rn\_ahtb\_0}, a background horizontal eddy viscosity or diffusivity coefficient (namelist parameters whose default values are $0$). However, the technique used to compute the isopycnal slopes is intended to get rid of such a background diffusion, since it introduces spurious diapycnal diffusion (see {\S\ref{LDF_slp}). spurious diapycnal diffusion (see \S\ref{LDF_slp}). (4) when an eddy induced advection term is used (\key{traldf\_eiv}), $A^{eiv}$, %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!ht]      \begin{center} \includegraphics[width=0.70\textwidth]{./TexFiles/Figures/Fig_LDF_ZDF1.pdf} \includegraphics[width=0.70\textwidth]{Fig_LDF_ZDF1} \caption {    \label{Fig_LDF_ZDF1} averaging procedure for isopycnal slope computation.} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!ht]     \begin{center} \includegraphics[width=0.70\textwidth]{./TexFiles/Figures/Fig_eiv_slp.pdf} \includegraphics[width=0.70\textwidth]{Fig_eiv_slp} \caption {     \label{Fig_eiv_slp} Vertical profile of the slope used for lateral mixing in the mixed layer : diffusion along model level surfaces, i.e. using the shear computed along the model levels and with no additional friction at the ocean bottom (see {\S\ref{LBC_coast}). \S\ref{LBC_coast}). \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_MISC.tex

 r5602 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter � Miscellaneous Topics has been made to set them in a generic way. However, examples of how they can be set up is given in the ORCA 2\deg and 0.5\deg configurations. For example, for details of implementation in ORCA2, search: \vspace{-10pt} \begin{alltt} \tiny \begin{verbatim} IF( cp_cfg == "orca" .AND. jp_cfg == 2 ) \end{verbatim} \end{alltt} for details of implementation in ORCA2, search: \texttt{ IF( cp\_cfg == "orca" .AND. jp\_cfg == 2 ) } % ------------------------------------------------------------------------------------------------------------- %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!tbp]     \begin{center} \includegraphics[width=0.80\textwidth]{./TexFiles/Figures/Fig_Gibraltar.pdf} \includegraphics[width=0.80\textwidth]{./TexFiles/Figures/Fig_Gibraltar2.pdf} \includegraphics[width=0.80\textwidth]{Fig_Gibraltar} \includegraphics[width=0.80\textwidth]{Fig_Gibraltar2} \caption{   \label{Fig_MISC_strait_hand} Example of the Gibraltar strait defined in a $1\deg \times 1\deg$ mesh. Example of the Gibraltar strait defined in a $1^{\circ} \times 1^{\circ}$ mesh. \textit{Top}: using partially open cells. The meridional scale factor at $v$-point is reduced on both sides of the strait to account for the real width of the strait %-------------------------------------------------------------------------------------------------------------- \colorbox{yellow}{Add a short description of CLA staff here or in lateral boundary condition chapter?} Options are defined through the  \ngn{namcla} namelist variables. This option is an obsolescent feature that will be removed in version 3.7 and followings. %The problem is resolved here by allowing the mixing of tracers and mass/volume between non-adjacent water columns at nominated regions within the model. Momentum is not mixed. The scheme conserves total tracer content, and total volume (the latter in $z*$- or $s*$-coordinate), and maintains compatibility between the tracer and mass/volume budgets. %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!ht]    \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_LBC_zoom.pdf} \includegraphics[width=0.90\textwidth]{Fig_LBC_zoom} \caption{   \label{Fig_LBC_zoom} Position of a model domain compared to the data input domain when the zoom functionality is used.} \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_Model_Basics.tex

 r3294 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter 1 Ñ Model Basics %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!ht]   \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_I_ocean_bc.pdf} \includegraphics[width=0.90\textwidth]{Fig_I_ocean_bc} \caption{    \label{Fig_ocean_bc} The ocean is bounded by two surfaces, $z=-H(i,j)$ and $z=\eta(i,j,t)$, where $H$ sufficient to solve a linearized version of (\ref{Eq_PE_ssh}), which still allows to take into account freshwater fluxes applied at the ocean surface \citep{Roullet_Madec_JGR00}. Nevertheless, with the linearization, an exact conservation of heat and salt contents is lost. The filtering of EGWs in models with a free surface is usually a matter of discretisation of the temporal derivatives, using the time splitting method \citep{Killworth_al_JPO91, Zhang_Endoh_JGR92} or the implicit scheme \citep{Dukowicz1994}. In \NEMO, we use a slightly different approach developed by \citet{Roullet_Madec_JGR00}: the damping of EGWs is ensured by introducing an additional force in the momentum equation. \eqref{Eq_PE_dyn} becomes: \label{Eq_PE_flt} \frac{\partial {\rm {\bf U}}_h }{\partial t}= {\rm {\bf M}} - g \nabla \left( \tilde{\rho} \ \eta \right) - g \ T_c \nabla \left( \widetilde{\rho} \ \partial_t \eta \right) where $T_c$, is a parameter with dimensions of time which characterizes the force, $\widetilde{\rho} = \rho / \rho_o$ is the dimensionless density, and $\rm {\bf M}$ represents the collected contributions of the Coriolis, hydrostatic pressure gradient, non-linear and viscous terms in \eqref{Eq_PE_dyn}. The new force can be interpreted as a diffusion of vertically integrated volume flux divergence. The time evolution of $D$ is thus governed by a balance of two terms, $-g$ \textbf{A} $\eta$ and $g \, T_c \,$ \textbf{A} $D$, associated with a propagative regime and a diffusive regime in the temporal spectrum, respectively. In the diffusive regime, the EGWs no longer propagate, $i.e.$ they are stationary and damped. The diffusion regime applies to the modes shorter than $T_c$. For longer ones, the diffusion term vanishes. Hence, the temporally unresolved EGWs can be damped by choosing $T_c > \rdt$. \citet{Roullet_Madec_JGR00} demonstrate that (\ref{Eq_PE_flt}) can be integrated with a leap frog scheme except the additional term which has to be computed implicitly. This is not surprising since the use of a large time step has a necessarily numerical cost. Two gains arise in comparison with the previous formulations. Firstly, the damping of EGWs can be quantified through the magnitude of the additional term. Secondly, the numerical scheme does not need any tuning. Numerical stability is ensured as soon as $T_c > \rdt$. When the variations of free surface elevation are small compared to the thickness of the first model layer, the free surface equation (\ref{Eq_PE_ssh}) can be linearized. As emphasized by \citet{Roullet_Madec_JGR00} the linearization of (\ref{Eq_PE_ssh}) has consequences on the conservation of salt in the model. With the nonlinear free surface equation, the time evolution of the total salt content is \label{Eq_PE_salt_content} \frac{\partial }{\partial t}\int\limits_{D\eta } {S\;dv} =\int\limits_S {S\;(-\frac{\partial \eta }{\partial t}-D+P-E)\;ds} where $S$ is the salinity, and the total salt is integrated over the whole ocean volume $D_\eta$ bounded by the time-dependent free surface. The right hand side (which is an integral over the free surface) vanishes when the nonlinear equation (\ref{Eq_PE_ssh}) is satisfied, so that the salt is perfectly conserved. When the free surface equation is linearized, \citet{Roullet_Madec_JGR00} show that the total salt content integrated in the fixed volume $D$ (bounded by the surface $z=0$) is no longer conserved: \label{Eq_PE_salt_content_linear} \frac{\partial }{\partial t}\int\limits_D {S\;dv} = - \int\limits_S {S\;\frac{\partial \eta }{\partial t}ds} The right hand side of (\ref{Eq_PE_salt_content_linear}) is small in equilibrium solutions \citep{Roullet_Madec_JGR00}. It can be significant when the freshwater forcing is not balanced and the globally averaged free surface is drifting. An increase in sea surface height \textit{$\eta$} results in a decrease of the salinity in the fixed volume $D$. Even in that case though, the total salt integrated in the variable volume $D_{\eta}$ varies much less, since (\ref{Eq_PE_salt_content_linear}) can be rewritten as \label{Eq_PE_salt_content_corrected} \frac{\partial }{\partial t}\int\limits_{D\eta } {S\;dv} =\frac{\partial}{\partial t} \left[ \;{\int\limits_D {S\;dv} +\int\limits_S {S\eta \;ds} } \right] =\int\limits_S {\eta \;\frac{\partial S}{\partial t}ds} Although the total salt content is not exactly conserved with the linearized free surface, its variations are driven by correlations of the time variation of surface salinity with the sea surface height, which is a negligible term. This situation contrasts with the case of the rigid lid approximation in which case freshwater forcing is represented by a virtual salt flux, leading to a spurious source of salt at the ocean surface \citep{Huang_JPO93, Roullet_Madec_JGR00}. \newpage $\$\newline    % force a new ligne of the temporal derivatives, using a split-explicit method \citep{Killworth_al_JPO91, Zhang_Endoh_JGR92} or the implicit scheme \citep{Dukowicz1994} or the addition of a filtering force in the momentum equation \citep{Roullet_Madec_JGR00}. With the present release, \NEMO offers the choice between an explicit free surface (see \S\ref{DYN_spg_exp}) or a split-explicit scheme strongly inspired the one proposed by \citet{Shchepetkin_McWilliams_OM05} (see \S\ref{DYN_spg_ts}). %\newpage %$\$\newline    % force a new line % ================================================================ %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!tb]   \begin{center} \includegraphics[width=0.60\textwidth]{./TexFiles/Figures/Fig_I_earth_referential.pdf} \includegraphics[width=0.60\textwidth]{Fig_I_earth_referential} \caption{   \label{Fig_referential} the geographical coordinate system $(\lambda,\varphi,z)$ and the curvilinear The equations solved by the ocean model \eqref{Eq_PE} in $s-$coordinate can be written as follows: The equations solved by the ocean model \eqref{Eq_PE} in $s-$coordinate can be written as follows (see Appendix~\ref{Apdx_A_momentum}): \vspace{0.5cm} * momentum equation: $\bullet$ Vector invariant form of the momentum equation : \begin{multline} \label{Eq_PE_sco_u} \frac{1}{e_3} \frac{\partial \left(  e_3\,u  \right) }{\partial t}= \frac{\partial  u  }{\partial t}= +   \left( {\zeta +f} \right)\,v -   \frac{1}{2\,e_1} \frac{\partial}{\partial i} \left(  u^2+v^2   \right) \end{multline} \begin{multline} \label{Eq_PE_sco_v} \frac{1}{e_3} \frac{\partial \left(  e_3\,v  \right) }{\partial t}= \frac{\partial v }{\partial t}= -   \left( {\zeta +f} \right)\,u -   \frac{1}{2\,e_2 }\frac{\partial }{\partial j}\left(  u^2+v^2  \right) +  D_v^{\vect{U}}  +   F_v^{\vect{U}} \quad \end{multline} \vspace{0.5cm} $\bullet$ Vector invariant form of the momentum equation : \begin{multline} \label{Eq_PE_sco_u} \frac{1}{e_3} \frac{\partial \left(  e_3\,u  \right) }{\partial t}= +   \left( { f + \frac{1}{e_1 \; e_2 } \left(    v \frac{\partial e_2}{\partial i} -u \frac{\partial e_1}{\partial j}  \right)}    \right) \, v    \\ - \frac{1}{e_1 \; e_2 \; e_3 }   \left( \frac{\partial \left( {e_2 \, e_3 \, u\,u} \right)}{\partial i} +        \frac{\partial \left( {e_1 \, e_3 \, v\,u} \right)}{\partial j}   \right) - \frac{1}{e_3 }\frac{\partial \left( { \omega\,u} \right)}{\partial k}    \\ - \frac{1}{e_1} \frac{\partial}{\partial i} \left( \frac{p_s + p_h}{\rho _o}    \right) +  g\frac{\rho }{\rho _o}\sigma _1 +   D_u^{\vect{U}}  +   F_u^{\vect{U}} \quad \end{multline} \begin{multline} \label{Eq_PE_sco_v} \frac{1}{e_3} \frac{\partial \left(  e_3\,v  \right) }{\partial t}= -   \left( { f + \frac{1}{e_1 \; e_2} \left(    v \frac{\partial e_2}{\partial i} -u \frac{\partial e_1}{\partial j}  \right)}    \right) \, u   \\ - \frac{1}{e_1 \; e_2 \; e_3 }   \left( \frac{\partial \left( {e_2 \; e_3  \,u\,v} \right)}{\partial i} +        \frac{\partial \left( {e_1 \; e_3  \,v\,v} \right)}{\partial j}   \right) - \frac{1}{e_3 } \frac{\partial \left( { \omega\,v} \right)}{\partial k}    \\ -   \frac{1}{e_2 }\frac{\partial }{\partial j}\left( \frac{p_s+p_h }{\rho _o}  \right) +  g\frac{\rho }{\rho _o }\sigma _2 +  D_v^{\vect{U}}  +   F_v^{\vect{U}} \quad \end{multline} where the relative vorticity, \textit{$\zeta$}, the surface pressure gradient, and the hydrostatic pressure have the same expressions as in $z$-coordinates although they do not represent exactly the same quantities. $\omega$ is provided by the continuity equation (see Appendix~\ref{Apdx_A}): \label{Eq_PE_sco_continuity} \frac{\partial e_3}{\partial t} + e_3 \; \chi + \frac{\partial \omega }{\partial s} = 0 \vspace{0.5cm} * tracer equations: $\bullet$ tracer equations: \begin{multline} \label{Eq_PE_sco_t} \frac{1}{e_3} \frac{\partial \left(  e_3\,T  \right) }{\partial t}= %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!b]    \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_z_zstar.pdf} \includegraphics[width=1.0\textwidth]{Fig_z_zstar} \caption{   \label{Fig_z_zstar} (a) $z$-coordinate in linear free-surface case ; \label{PE_zco_tilde} The $\tilde{z}$-coordinate has been developed by \citet{Leclair_Madec_OM10s}. It is not available in the current version of \NEMO. The $\tilde{z}$-coordinate has been developed by \citet{Leclair_Madec_OM11}. It is available in \NEMO since the version 3.4. Nevertheless, it is currently not robust enough to be used in all possible configurations. Its use is therefore not recommended. \newpage operator acting along $s-$surfaces (see \S\ref{LDF}). \subsubsection{Lateral second order tracer diffusive operator} The lateral second order tracer diffusive operator is defined by (see Appendix~\ref{Apdx_B}): \subsubsection{Lateral Laplacian tracer diffusive operator} The lateral Laplacian tracer diffusive operator is defined by (see Appendix~\ref{Apdx_B}): \label{Eq_PE_iso_tensor} D^{lT}=\nabla {\rm {\bf .}}\left( {A^{lT}\;\Re \;\nabla T} \right) \qquad ocean (see Appendix~\ref{Apdx_B}). For \textit{iso-level} diffusion, $r_1$ and $r_2$ are zero. $\Re$ reduces to the identity in the horizontal direction, no rotation is applied. For \textit{geopotential} diffusion, $r_1$ and $r_2$ are the slopes between the geopotential and computational surfaces: in $z$-coordinates they are zero ($r_1 = r_2 = 0$) while in $s$-coordinate (including $\textit{z*}$ case) they are equal to $\sigma _1$ and $\sigma _2$, respectively (see \eqref{Eq_PE_sco_slope} ). geopotential and computational surfaces: they are equal to $\sigma _1$ and $\sigma _2$, respectively (see \eqref{Eq_PE_sco_slope} ). For \textit{isoneutral} diffusion $r_1$ and $r_2$ are the slopes between the isoneutral to zero in the vicinity of the boundaries. The latter strategy is used in \NEMO (cf. Chap.~\ref{LDF}). \subsubsection{Lateral fourth order tracer diffusive operator} The lateral fourth order tracer diffusive operator is defined by: \subsubsection{Lateral bilaplacian tracer diffusive operator} The lateral bilaplacian tracer diffusive operator is defined by: \label{Eq_PE_bilapT} D^{lT}=\Delta \left( {A^{lT}\;\Delta T} \right) \qquad \text{where} \  D^{lT}=\Delta \left( {A^{lT}\;\Delta T} \right) It is the second order operator given by \eqref{Eq_PE_iso_tensor} applied twice with the eddy diffusion coefficient correctly placed. \subsubsection{Lateral second order momentum diffusive operator} The second order momentum diffusive operator along $z$- or $s$-surfaces is found by \subsubsection{Lateral Laplacian momentum diffusive operator} The Laplacian momentum diffusive operator along $z$- or $s$-surfaces is found by applying \eqref{Eq_PE_lap_vector} to the horizontal velocity vector (see Appendix~\ref{Apdx_B}): \label{Eq_PE_lapU} of the Equator in a geographical coordinate system \citep{Lengaigne_al_JGR03}. \subsubsection{lateral fourth order momentum diffusive operator} \subsubsection{lateral bilaplacian momentum diffusive operator} As for tracers, the fourth order momentum diffusive operator along $z$ or $s$-surfaces \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_Model_Basics_zstar.tex

 r4147 % ================================================================ % Chapter 1 � Model Basics \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter 1 ——— Model Basics % ================================================================ % ================================================================ %>   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   > \begin{figure}[!t]   \begin{center} \includegraphics[width=0.90\textwidth]{./Figures/Fig_DYN_dynspg_ts.pdf} \includegraphics[width=0.90\textwidth]{Fig_DYN_dynspg_ts} \caption{    \label{Fig_DYN_dynspg_ts} Schematic of the split-explicit time stepping scheme for the barotropic and baroclinic modes, \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_OBS.tex

 r4245 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter observation operator (OBS) %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}      \begin{center} \includegraphics[width=10cm,height=12cm,angle=-90.]{./TexFiles/Figures/Fig_ASM_obsdist_local} \includegraphics[width=10cm,height=12cm,angle=-90.]{Fig_ASM_obsdist_local} \caption{      \label{fig:obslocal} Example of the distribution of observations with the geographical distribution of observational data.} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}     \begin{center} \includegraphics[width=10cm,height=12cm,angle=-90.]{./TexFiles/Figures/Fig_ASM_obsdist_global} \includegraphics[width=10cm,height=12cm,angle=-90.]{Fig_ASM_obsdist_global} \caption{      \label{fig:obsglobal} Example of the distribution of observations with the round-robin distribution of observational data.} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}     \begin{center} %\includegraphics[width=10cm,height=12cm,angle=-90.]{./TexFiles/Figures/Fig_OBS_dataplot_main} \includegraphics[width=9cm,angle=-90.]{./TexFiles/Figures/Fig_OBS_dataplot_main} %\includegraphics[width=10cm,height=12cm,angle=-90.]{Fig_OBS_dataplot_main} \includegraphics[width=9cm,angle=-90.]{Fig_OBS_dataplot_main} \caption{      \label{fig:obsdataplotmain} Main window of dataplot.} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}     \begin{center} %\includegraphics[width=10cm,height=12cm,angle=-90.]{./TexFiles/Figures/Fig_OBS_dataplot_prof} \includegraphics[width=7cm,angle=-90.]{./TexFiles/Figures/Fig_OBS_dataplot_prof} %\includegraphics[width=10cm,height=12cm,angle=-90.]{Fig_OBS_dataplot_prof} \includegraphics[width=7cm,angle=-90.]{Fig_OBS_dataplot_prof} \caption{      \label{fig:obsdataplotprofile} Profile plot from dataplot produced by right clicking on a point in the main window.} \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_SBC.tex

 r5602 % ================================================================ % Chapter � Surface Boundary Condition (SBC, ISF, ICB) \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter —— Surface Boundary Condition (SBC, ISF, ICB) % ================================================================ \chapter{Surface Boundary Condition (SBC, ISF, ICB) } \item the two components of the surface ocean stress $\left( {\tau _u \;,\;\tau _v} \right)$ \item the incoming solar and non solar heat fluxes $\left( {Q_{ns} \;,\;Q_{sr} } \right)$ \item the surface freshwater budget $\left( {\textit{emp},\;\textit{emp}_S } \right)$ \item the surface freshwater budget $\left( {\textit{emp}} \right)$ \item the surface salt flux associated with freezing/melting of seawater $\left( {\textit{sfx}} \right)$ \end{itemize} plus an optional field: are controlled by namelist \ngn{namsbc} variables: an analytical formulation (\np{ln\_ana}~=~true), a flux formulation (\np{ln\_flx}~=~true), a bulk formulae formulation (CORE (\np{ln\_core}~=~true), CLIO (\np{ln\_clio}~=~true) or MFS (\np{ln\_blk\_core}~=~true), CLIO (\np{ln\_blk\_clio}~=~true) or MFS \footnote { Note that MFS bulk formulae compute fluxes only for the ocean component} (\np{ln\_mfs}~=~true) bulk formulae) and a coupled formulation (exchanges with a atmospheric model via the OASIS coupler) (\np{ln\_cpl}~=~true). When used, the atmospheric pressure forces both ocean and ice dynamics (\np{ln\_apr\_dyn}~=~true). The frequency at which the six or seven fields have to be updated is the \np{nn\_fsbc} namelist parameter. (\np{ln\_blk\_mfs}~=~true) bulk formulae) and a coupled or mixed forced/coupled formulation (exchanges with a atmospheric model via the OASIS coupler) (\np{ln\_cpl} or \np{ln\_mixcpl}~=~true). When used ($i.e.$ \np{ln\_apr\_dyn}~=~true), the atmospheric pressure forces both ocean and ice dynamics. The frequency at which the forcing fields have to be updated is given by the \np{nn\_fsbc} namelist parameter. When the fields are supplied from data files (flux and bulk formulations), the input fields need not be supplied on the model grid.  Instead a file of coordinates and weights can need not be supplied on the model grid. Instead a file of coordinates and weights can be supplied which maps the data from the supplied grid to the model points (so called "Interpolation on the Fly", see \S\ref{SBC_iof}). can be masked to avoid spurious results in proximity of the coasts  as large sea-land gradients characterize most of the atmospheric variables. In addition, the resulting fields can be further modified using several namelist options. These options control  the rotation of vector components supplied relative to an east-north coordinate system onto the local grid directions in the model; the addition of a surface restoring term to observed SST and/or SSS (\np{ln\_ssr}~=~true); the modification of fluxes below ice-covered areas (using observed ice-cover or a sea-ice model) (\np{nn\_ice}~=~0,1, 2 or 3); the addition of river runoffs as surface freshwater fluxes or lateral inflow (\np{ln\_rnf}~=~true); the addition of isf melting as lateral inflow (parameterisation) (\np{nn\_isf}~=~2 or 3 and \np{ln\_isfcav}~=~false) or as surface flux at the land-ice ocean interface (\np{nn\_isf}~=~1 or 4 and \np{ln\_isfcav}~=~true); the addition of a freshwater flux adjustment in order to avoid a mean sea-level drift (\np{nn\_fwb}~=~0,~1~or~2); the transformation of the solar radiation (if provided as daily mean) into a diurnal cycle (\np{ln\_dm2dc}~=~true); and a neutral drag coefficient can be read from an external wave model (\np{ln\_cdgw}~=~true). The latter option is possible only in case core or mfs bulk formulas are selected. These options control \begin{itemize} \item the rotation of vector components supplied relative to an east-north coordinate system onto the local grid directions in the model ; \item the addition of a surface restoring term to observed SST and/or SSS (\np{ln\_ssr}~=~true) ; \item the modification of fluxes below ice-covered areas (using observed ice-cover or a sea-ice model) (\np{nn\_ice}~=~0,1, 2 or 3) ; \item the addition of river runoffs as surface freshwater fluxes or lateral inflow (\np{ln\_rnf}~=~true) ; \item the addition of isf melting as lateral inflow (parameterisation) (\np{nn\_isf}~=~2 or 3 and \np{ln\_isfcav}~=~false) or as fluxes applied at the land-ice ocean interface (\np{nn\_isf}~=~1 or 4 and \np{ln\_isfcav}~=~true) ; \item the addition of a freshwater flux adjustment in order to avoid a mean sea-level drift (\np{nn\_fwb}~=~0,~1~or~2) ; \item the transformation of the solar radiation (if provided as daily mean) into a diurnal cycle (\np{ln\_dm2dc}~=~true) ; and a neutral drag coefficient can be read from an external wave model (\np{ln\_cdgw}~=~true). \end{itemize} The latter option is possible only in case core or mfs bulk formulas are selected. In this chapter, we first discuss where the surface boundary condition appears in the The surface ocean stress is the stress exerted by the wind and the sea-ice on the ocean. The two components of stress are assumed to be interpolated onto the ocean mesh, $i.e.$ resolved onto the model (\textbf{i},\textbf{j}) direction at $u$- and $v$-points They are applied as a surface boundary condition of the computation of the momentum vertical mixing trend (\mdl{dynzdf} module) : \label{Eq_sbc_dynzdf} \left.{\left( {\frac{A^{vm} }{e_3 }\ \frac{\partial \textbf{U}_h}{\partial k}} \right)} \right|_{z=1} = \frac{1}{\rho _o} \binom{\tau _u}{\tau _v } where $(\tau _u ,\;\tau _v )=(utau,vtau)$ are the two components of the wind stress vector in the $(\textbf{i},\textbf{j})$ coordinate system. on the ocean. It is applied in \mdl{dynzdf} module as a surface boundary condition of the computation of the momentum vertical mixing trend (see \eqref{Eq_dynzdf_sbc} in \S\ref{DYN_zdf}). As such, it has to be provided as a 2D vector interpolated onto the horizontal velocity ocean mesh, $i.e.$ resolved onto the model (\textbf{i},\textbf{j}) direction at $u$- and $v$-points. The surface heat flux is decomposed into two parts, a non solar and a solar heat flux, $Q_{ns}$ and $Q_{sr}$, respectively. The former is the non penetrative part of the heat flux ($i.e.$ the sum of sensible, latent and long wave heat fluxes). It is applied as a surface boundary condition trend of the first level temperature time evolution equation (\mdl{trasbc} module). \label{Eq_sbc_trasbc_q} \frac{\partial T}{\partial t}\equiv \cdots \;+\;\left. {\frac{Q_{ns} }{\rho _o \;C_p \;e_{3t} }} \right|_{k=1} \quad $Q_{sr}$ is the penetrative part of the heat flux. It is applied as a 3D trends of the temperature equation (\mdl{traqsr} module) when \np{ln\_traqsr}=True. \label{Eq_sbc_traqsr} \frac{\partial T}{\partial t}\equiv \cdots \;+\frac{Q_{sr} }{\rho_o C_p \,e_{3t} }\delta _k \left[ {I_w } \right] where $I_w$ is a non-dimensional function that describes the way the light penetrates inside the water column. It is generally a sum of decreasing exponentials (see \S\ref{TRA_qsr}). The surface freshwater budget is provided by fields: \textit{emp} and $\textit{emp}_S$ which may or may not be identical. Indeed, a surface freshwater flux has two effects: it changes the volume of the ocean and it changes the surface concentration of salt (and other tracers). Therefore it appears in the sea surface height as a volume flux, \textit{emp} (\textit{dynspg\_xxx} modules), and in the salinity time evolution equations as a concentration/dilution effect, $\textit{emp}_{S}$ (\mdl{trasbc} module). \label{Eq_trasbc_emp} \begin{aligned} &\frac{\partial \eta }{\partial t}\equiv \cdots \;+\;\textit{emp}\quad  \\ \\ &\frac{\partial S}{\partial t}\equiv \cdots \;+\left. {\frac{\textit{emp}_S \;S}{e_{3t} }} \right|_{k=1} \\ \end{aligned} In the real ocean, $\textit{emp}=\textit{emp}_S$ and the ocean salt content is conserved, but it exist several numerical reasons why this equality should be broken. For example, when the ocean is coupled to a sea-ice model, the water exchanged between ice and ocean is slightly salty (mean sea-ice salinity is $\sim$\textit{4 psu}). In this case, $\textit{emp}_{S}$ take into account both concentration/dilution effect associated with freezing/melting and the salt flux between ice and ocean, while \textit{emp} is only the volume flux. In addition, in the current version of \NEMO, the sea-ice is assumed to be above the ocean (the so-called levitating sea-ice). Freezing/melting does not change the ocean volume (no impact on \textit{emp}) but it modifies the SSS. %gm  \colorbox{yellow}{(see {\S} on LIM sea-ice model)}. Note that SST can also be modified by a freshwater flux. Precipitation (in particular solid precipitation) may have a temperature significantly different from the SST. Due to the lack of information about the temperature of precipitation, we assume it is equal to the SST. Therefore, no concentration/dilution term appears in the temperature equation. It has to be emphasised that this absence does not mean that there is no heat flux associated with precipitation! Precipitation can change the ocean volume and thus the ocean heat content. It is therefore associated with a heat flux (not yet diagnosed in the model) \citep{Roullet_Madec_JGR00}). of the heat flux ($i.e.$ the sum of sensible, latent and long wave heat fluxes plus the heat content of the mass exchange with the atmosphere and sea-ice). It is applied in \mdl{trasbc} module as a surface boundary condition trend of the first level temperature time evolution equation (see \eqref{Eq_tra_sbc} and \eqref{Eq_tra_sbc_lin} in \S\ref{TRA_sbc}). The latter is the penetrative part of the heat flux. It is applied as a 3D trends of the temperature equation (\mdl{traqsr} module) when \np{ln\_traqsr}=\textit{true}. The way the light penetrates inside the water column is generally a sum of decreasing exponentials (see \S\ref{TRA_qsr}). The surface freshwater budget is provided by the \textit{emp} field. It represents the mass flux exchanged with the atmosphere (evaporation minus precipitation) and possibly with the sea-ice and ice shelves (freezing minus melting of ice). It affects both the ocean in two different ways: $(i)$   it changes the volume of the ocean and therefore appears in the sea surface height equation as a volume flux, and $(ii)$  it changes the surface temperature and salinity through the heat and salt contents of the mass exchanged with the atmosphere, the sea-ice and the ice shelves. %\colorbox{yellow}{Miss: } %Sbcmod manage the providing'' (fourniture) to the ocean the 7 fields % %Fluxes update only each nf{\_}sbc time step (namsbc) explain relation %between nf{\_}sbc and nf{\_}ice, do we define nf{\_}blk??? ? only one %nf{\_}sbc %Fluxes update only each nn{\_}fsbc time step (namsbc) explain relation %between nn{\_}fsbc and nf{\_}ice, do we define nf{\_}blk??? ? only one %nn{\_}fsbc % %Explain here all the namlist namsbc variable{\ldots}. % % explain : use or not of surface currents % %\colorbox{yellow}{End Miss } The ocean model provides the surface currents, temperature and salinity averaged over \np{nf\_sbc} time-step (\ref{Tab_ssm}).The computation of the mean is done in \mdl{sbcmod} module. The ocean model provides, at each time step, to the surface module (\mdl{sbcmod}) the surface currents, temperature and salinity. These variables are averaged over \np{nn\_fsbc} time-step (\ref{Tab_ssm}), and it is these averaged fields which are used to computes the surface fluxes at a frequency of \np{nn\_fsbc} time-step. %-------------------------------------------------TABLE--------------------------------------------------- \caption{  \label{Tab_ssm} Ocean variables provided by the ocean to the surface module (SBC). The variable are averaged over nf{\_}sbc time step, $i.e.$ the frequency of The variable are averaged over nn{\_}fsbc time step, $i.e.$ the frequency of computation of surface fluxes.} \end{center}   \end{table} %-------------------------------------------------------------------------------------------------------------- In some circumstances it may be useful to avoid calculating the 3D temperature, salinity and velocity fields and simply read them in from  a previous run. Options are defined through the  \ngn{namsbc\_sas} namelist variables. In some circumstances it may be useful to avoid calculating the 3D temperature, salinity and velocity fields and simply read them in from a previous run or receive them from OASIS. For example: \begin{enumerate} \item  Multiple runs of the model are required in code development to see the affect of different algorithms in \begin{itemize} \item  Multiple runs of the model are required in code development to see the effect of different algorithms in the bulk formulae. \item  The effect of different parameter sets in the ice model is to be examined. \end{enumerate} \item  Development of sea-ice algorithms or parameterizations. \item  spinup of the iceberg floats \item  ocean/sea-ice simulation with both media running in parallel (\np{ln\_mixcpl}~=~\textit{true}) \end{itemize} The StandAlone Surface scheme provides this utility. Its options are defined through the \ngn{namsbc\_sas} namelist variables. A new copy of the model has to be compiled with a configuration based on ORCA2\_SAS\_LIM. However no namelist parameters need be changed from the settings of the previous run (except perhaps nn{\_}date0) Routines replaced are: \begin{enumerate} \item  \mdl{nemogcm} This routine initialises the rest of the model and repeatedly calls the stp time stepping routine (step.F90) \begin{itemize} \item \mdl{nemogcm} : This routine initialises the rest of the model and repeatedly calls the stp time stepping routine (step.F90) Since the ocean state is not calculated all associated initialisations have been removed. \item  \mdl{step} The main time stepping routine now only needs to call the sbc routine (and a few utility functions). \item  \mdl{sbcmod} This has been cut down and now only calculates surface forcing and the ice model required.  New surface modules \item  \mdl{step} : The main time stepping routine now only needs to call the sbc routine (and a few utility functions). \item  \mdl{sbcmod} : This has been cut down and now only calculates surface forcing and the ice model required.  New surface modules that can function when only the surface level of the ocean state is defined can also be added (e.g. icebergs). \item  \mdl{daymod} No ocean restarts are read or written (though the ice model restarts are retained), so calls to restart functions \item  \mdl{daymod} : No ocean restarts are read or written (though the ice model restarts are retained), so calls to restart functions have been removed.  This also means that the calendar cannot be controlled by time in a restart file, so the user must make sure that nn{\_}date0 in the model namelist is correct for his or her purposes. \item  \mdl{stpctl} Since there is no free surface solver, references to it have been removed from \rou{stp\_ctl} module. \item  \mdl{diawri} All 3D data have been removed from the output.  The surface temperature, salinity and velocity components (which \item  \mdl{stpctl} : Since there is no free surface solver, references to it have been removed from \rou{stp\_ctl} module. \item  \mdl{diawri} : All 3D data have been removed from the output.  The surface temperature, salinity and velocity components (which have been read in) are written along with relevant forcing and ice data. \end{enumerate} \end{itemize} One new routine has been added: \begin{enumerate} \item  \mdl{sbcsas} This module initialises the input files needed for reading temperature, salinity and velocity arrays at the surface. \begin{itemize} \item  \mdl{sbcsas} : This module initialises the input files needed for reading temperature, salinity and velocity arrays at the surface. These filenames are supplied in namelist namsbc{\_}sas.  Unfortunately because of limitations with the \mdl{iom} module, the full 3D fields from the mean files have to be read in and interpolated in time, before using just the top level. Since fldread is used to read in the data, Interpolation on the Fly may be used to change input data resolution. \end{enumerate} \end{itemize} % Missing the description of the 2 following variables: %   ln_3d_uve   = .true.    !  specify whether we are supplying a 3D u,v and e3 field %   ln_read_frq = .false.    !  specify whether we must read frq or not % ================================================================ reanalysis and satellite data. They use an inertial dissipative method to compute the turbulent transfer coefficients (momentum, sensible heat and evaporation) from the 10 metre wind speed, air temperature and specific humidity. from the 10 meters wind speed, air temperature and specific humidity. This \citet{Large_Yeager_Rep04} dataset is available through the \href{http://nomads.gfdl.noaa.gov/nomads/forms/mom4/CORE.html}{GFDL web site}. or larger than the one of the input atmospheric fields. The  \np{sn\_wndi}, \np{sn\_wndj}, \np{sn\_qsr}, \np{sn\_qlw}, \np{sn\_tair},\np{sn\_humi},\np{sn\_prec}, \np{sn\_snow}, \np{sn\_tdif} parameters describe the fields and the way they have to be used (spatial and temporal interpolations). \np{cn\_dir} is the directory of location of bulk files \np{ln\_taudif} is the flag to specify if we use Hight Frequency (HF) tau information (.true.) or not (.false.) \np{rn\_zqt}: is the height of humidity and temperature measurements (m) \np{rn\_zu}: is the height of wind measurements (m) The multiplicative factors to activate (value is 1) or deactivate (value is 0) : \np{rn\_pfac} for precipitations (total and snow) \np{rn\_efac} for evaporation \np{rn\_vfac} for for ice/ocean velocities in the calculation of wind stress % ------------------------------------------------------------------------------------------------------------- %        CLIO Bulk formulea are sent to the atmospheric component. A generalised coupled interface has been developed. It is currently interfaced with OASIS 3 (\key{oasis3}) and does not support OASIS 4 \footnote{The \key{oasis4} exist. It activates portion of the code that are still under development.}. A generalised coupled interface has been developed. It is currently interfaced with OASIS-3-MCT (\key{oasis3}). It has been successfully used to interface \NEMO to most of the European atmospheric GCM (ARPEGE, ECHAM, ECMWF, HadAM, HadGAM, LMDz), \label{SBC_tide} A module is available to use the tidal potential forcing and is activated with with \key{tide}. %------------------------------------------nam_tide---------------------------------------------------- %------------------------------------------nam_tide--------------------------------------- \namdisplay{nam_tide} %------------------------------------------------------------------------------------------------------------- Concerning the tidal potential, some parameters are available in namelist \ngn{nam\_tide}: %----------------------------------------------------------------------------------------- A module is available to compute the tidal potential and use it in the momentum equation. This option is activated when \key{tide} is defined. Some parameters are available in namelist \ngn{nam\_tide}: - \np{ln\_tide\_pot} activate the tidal potential forcing - \np{clname} is the name of constituent The tide is generated by the forces of gravity ot the Earth-Moon and Earth-Sun sytem; lowest box the river water is being added to (i.e. the total depth that river water is being added to in the model). %Christian: If the depth information is not provide in the NetCDF file, it can be estimate from the runoff input file at the initial time-step, by setting the namelist parameter \np{ln\_rnf\_depth\_ini} to true. This estimation is a simple linear relation between the runoff and a given depth : h\_dep  = \frac{rn\_dep\_max} {rn\_rnf\_max}  rnf where  \np{rn\_dep\_max} is the given maximum depth over which the runoffs is spread, \np{rn\_rnf\_max} is the maximum value of the runoff climatologie over the global domain and rnf is the maximum value in time of the runoff climatology at each grid cell (computed online). The estimated depth array can be output if needed in a NetCDF file by setting the namelist parameter \np{nn\_rnf\_depth\_file} to 1. The mass/volume addition due to the river runoff is, at each relevant depth level, added to the horizontal divergence (\textit{hdivn}) in the subroutine \rou{sbc\_rnf\_div} (called from \mdl{divcur}). \namdisplay{namsbc_isf} %-------------------------------------------------------------------------------------------------------- Namelist variable in \ngn{namsbc}, \np{nn\_isf},  control the kind of ice shelf representation used. Namelist variable in \ngn{namsbc}, \np{nn\_isf}, controls the ice shelf representation used (Fig. \ref{Fig_SBC_isf}): %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!h]    \begin{center} \includegraphics[width=0.8\textwidth]{Fig_SBC_isf} \caption{ \label{Fig_SBC_isf} Schematic for all the options available trough \np{nn\_isf}.} \end{center}   \end{figure} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{description} \item[\np{nn\_isf}~=~0] The ice shelf routines are not used. The ice shelf melting is not computed or prescribed, the cavity have to be closed. If needed, the ice shelf melting should be added to the runoff or the precipitation file. \item[\np{nn\_isf}~=~1] The ice shelf cavity is represented. The fwf and heat flux are computed. Full description, sensitivity and validation in preparation. The ice shelf cavity is represented. The fwf and heat flux are computed. Two different bulk formula are available: \begin{description} \item[\np{nn\_isfblk}~=~1] The bulk formula used to compute the melt is based the one described in \citet{Hunter2006}. This formulation is based on a balance between the upward ocean heat flux and the latent heat flux at the ice shelf base. \item[\np{nn\_isfblk}~=~2] The bulk formula used to compute the melt is based the one described in \citet{Jenkins1991}. This formulation is based on a 3 equations formulation (a heat flux budget, a salt flux budget and a linearised freezing point temperature equation). \end{description} For this 2 bulk formulations, there are 3 different ways to compute the exchange coeficient: \begin{description} \item[\np{nn\_gammablk~=~0~}] The salt and heat exchange coefficients are constant and defined by \np{rn\_gammas0} and \np{rn\_gammat0} \item[\np{nn\_gammablk~=~1~}] The salt and heat exchange coefficients are velocity dependent and defined as $\np{rn\_gammas0} \times u_{*}$ and $\np{rn\_gammat0} \times u_{*}$ where $u_{*}$ is the friction velocity in the top boundary layer (ie first \np{rn\_hisf\_tbl} meters). See \citet{Jenkins2010} for all the details on this formulation. \item[\np{nn\_gammablk~=~2~}] The salt and heat exchange coefficients are velocity and stability dependent and defined as $\gamma_{T,S} = \frac{u_{*}}{\Gamma_{Turb} + \Gamma^{T,S}_{Mole}}$ where $u_{*}$ is the friction velocity in the top boundary layer (ie first \np{rn\_hisf\_tbl} meters), $\Gamma_{Turb}$ the contribution of the ocean stability and $\Gamma^{T,S}_{Mole}$ the contribution of the molecular diffusion. See \citet{Holland1999} for all the details on this formulation. \end{description} \item[\np{nn\_isf}~=~2] The fwf is distributed along the ice shelf edge between the depth of the average grounding line (GL) (\np{sn\_depmax\_isf}) and the base of the ice shelf along the calving front (\np{sn\_depmin\_isf}) as in (\np{nn\_isf}~=~3). Furthermore the fwf is computed using the \citet{Beckmann2003} parameterisation of isf melting. Furthermore the fwf and heat flux are computed using the \citet{Beckmann2003} parameterisation of isf melting. The effective melting length (\np{sn\_Leff\_isf}) is read from a file. \item[\np{nn\_isf}~=~3] A simple parameterisation of isf is used. The ice shelf cavity is not represented. The fwf (\np{sn\_rnfisf}) is distributed along the ice shelf edge between the depth of the average grounding line (GL) (\np{sn\_depmax\_isf}) and the base of the ice shelf along the calving front (\np{sn\_depmin\_isf}). Full description, sensitivity and validation in preparation. The fwf (\np{sn\_rnfisf}) is prescribed and distributed along the ice shelf edge between the depth of the average grounding line (GL) (\np{sn\_depmax\_isf}) and the base of the ice shelf along the calving front (\np{sn\_depmin\_isf}). The heat flux ($Q_h$) is computed as $Q_h = fwf \times L_f$. \item[\np{nn\_isf}~=~4] The ice shelf cavity is represented. However, the fwf (\np{sn\_fwfisf}) and heat flux (\np{sn\_qisf}) are not computed but specified from file. The ice shelf cavity is opened. However, the fwf is not computed but specified from file \np{sn\_fwfisf}). The heat flux ($Q_h$) is computed as $Q_h = fwf \times L_f$.\\ \end{description} \np{nn\_isf}~=~1 and \np{nn\_isf}~=~2 compute a melt rate based on the water masse properties, ocean velocities and depth. This flux is thus highly dependent of the model resolution (horizontal and vertical), realism of the water masse onto the shelf ... \np{nn\_isf}~=~3 and \np{nn\_isf}~=~4 read the melt rate and heat flux from a file. You have total control of the fwf scenario. This can be usefull if the water masses on the shelf are not realistic or the resolution (horizontal/vertical) are too coarse to have realistic melting or for sensitivity studies where you want to control your input. Full description, sensitivity and validation in preparation. There is 2 ways to apply the fwf to NEMO. The first possibility (\np{ln\_divisf}~=~false) applied the fwf and heat flux directly on the salinity and temperature tendancy. The second possibility (\np{ln\_divisf}~=~true) apply the fwf as for the runoff fwf (see \S\ref{SBC_rnf}). The mass/volume addition due to the ice shelf melting is, at each relevant depth level, added to the horizontal divergence (\textit{hdivn}) in the subroutine \rou{sbc\_isf\_div} (called from \mdl{divcur}). $\bullet$ \np{nn\_isf}~=~1 and \np{nn\_isf}~=~2 compute a melt rate based on the water mass properties, ocean velocities and depth. This flux is thus highly dependent of the model resolution (horizontal and vertical), realism of the water masses onto the shelf ...\\ $\bullet$ \np{nn\_isf}~=~3 and \np{nn\_isf}~=~4 read the melt rate from a file. You have total control of the fwf forcing. This can be usefull if the water masses on the shelf are not realistic or the resolution (horizontal/vertical) are too coarse to have realistic melting or for studies where you need to control your heat and fw input.\\ Two namelist parameters control how the heat and fw fluxes are passed to NEMO: \np{rn\_hisf\_tbl} and \np{ln\_divisf} \begin{description} \item[\np{rn\_hisf\_tbl}] is the top boundary layer thickness as defined in \citet{Losch2008}. This parameter is only used if \np{nn\_isf}~=~1 or \np{nn\_isf}~=~4 It allows you to control over which depth you want to spread the heat and fw fluxes. If \np{rn\_hisf\_tbl} = 0.0, the fluxes are put in the top level whatever is its tickness. If \np{rn\_hisf\_tbl} $>$ 0.0, the fluxes are spread over the first \np{rn\_hisf\_tbl} m (ie over one or several cells). \item[\np{ln\_divisf}] is a flag to apply the fw flux as a volume flux or as a salt flux. \np{ln\_divisf}~=~true applies the fwf as a volume flux. This volume flux is implemented with in the same way as for the runoff. The fw addition due to the ice shelf melting is, at each relevant depth level, added to the horizontal divergence (\textit{hdivn}) in the subroutine \rou{sbc\_isf\_div}, called from \mdl{divcur}. See the runoff section \ref{SBC_rnf} for all the details about the divergence correction. \np{ln\_divisf}~=~false applies the fwf and heat flux directly on the salinity and temperature tendancy. \item[\np{ln\_conserve}] is a flag for \np{nn\_isf}~=~1. A conservative boundary layer scheme as described in \citet{Jenkins2001} is used if \np{ln\_conserve}=true. It takes into account the fact that the melt water is at freezing T and needs to be warm up to ocean temperature. It is only relevant for \np{ln\_divisf}~=~false. If \np{ln\_divisf}~=~true, \np{ln\_conserve} has to be set to false to avoid a double counting of the contribution. \end{description} % % ================================================================ %        Handling of icebergs % ================================================================ \section{ Handling of icebergs (ICB) } \section{Handling of icebergs (ICB)} \label{ICB_icebergs} %------------------------------------------namberg---------------------------------------------------- %------------------------------------------------------------------------------------------------------------- Icebergs are modelled as lagrangian particles in NEMO. Their physical behaviour is controlled by equations as described in  \citet{Martin_Adcroft_OM10} ). (Note that the authors kindly provided a copy of their code to act as a basis for implementation in NEMO.) Icebergs are initially spawned into one of ten classes which have specific mass and thickness as described in the \ngn{namberg} namelist: Icebergs are modelled as lagrangian particles in NEMO \citep{Marsh_GMD2015}. Their physical behaviour is controlled by equations as described in \citet{Martin_Adcroft_OM10} ). (Note that the authors kindly provided a copy of their code to act as a basis for implementation in NEMO). Icebergs are initially spawned into one of ten classes which have specific mass and thickness as described in the \ngn{namberg} namelist: \np{rn\_initial\_mass} and \np{rn\_initial\_thickness}. Each class has an associated scaling (\np{rn\_mass\_scaling}), which is an integer representing how many icebergs %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]    \begin{center} \includegraphics[width=0.8\textwidth]{./TexFiles/Figures/Fig_SBC_diurnal.pdf} \includegraphics[width=0.8\textwidth]{Fig_SBC_diurnal} \caption{ \label{Fig_SBC_diurnal} Example of recontruction of the diurnal cycle variation of short wave flux %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]  \begin{center} \includegraphics[width=0.7\textwidth]{./TexFiles/Figures/Fig_SBC_dcy.pdf} \includegraphics[width=0.7\textwidth]{Fig_SBC_dcy} \caption{ \label{Fig_SBC_dcy} Example of recontruction of the diurnal cycle variation of short wave flux The presence at the sea surface of an ice covered area modifies all the fluxes transmitted to the ocean. There are several way to handle sea-ice in the system depending on the value of the \np{nn{\_}ice} namelist parameter. depending on the value of the \np{nn\_ice} namelist parameter found in \ngn{namsbc} namelist. \begin{description} \item[nn{\_}ice = 0]  there will never be sea-ice in the computational domain. % ------------------------------------------------------------------------------------------------------------- \subsection   [Neutral drag coefficient from external wave model (\textit{sbcwave})] {Neutral drag coefficient from external wave model (\mdl{sbcwave})} {Neutral drag coefficient from external wave model (\mdl{sbcwave})} \label{SBC_wave} %------------------------------------------namwave---------------------------------------------------- \namdisplay{namsbc_wave} %------------------------------------------------------------------------------------------------------------- \begin{description} \item [??] In order to read a neutral drag coeff, from an external data source (i.e. a wave model), the logical variable \np{ln\_cdgw} in $namsbc$ namelist must be defined ${.true.}$. In order to read a neutral drag coeff, from an external data source ($i.e.$ a wave model), the logical variable \np{ln\_cdgw} in \ngn{namsbc} namelist must be set to \textit{true}. The \mdl{sbcwave} module containing the routine \np{sbc\_wave} reads the namelist \ngn{namsbc\_wave} (for external data names, locations, frequency, interpolation and all the miscellanous options allowed by Input Data generic Interface see \S\ref{SBC_input}) and a 2D field of neutral drag coefficient. Then using the routine TURB\_CORE\_1Z or TURB\_CORE\_2Z, and starting from the neutral drag coefficent provided, the drag coefficient is computed according to stable/unstable conditions of the air-sea interface following \citet{Large_Yeager_Rep04}. \end{description} and a 2D field of neutral drag coefficient. Then using the routine TURB\_CORE\_1Z or TURB\_CORE\_2Z, and starting from the neutral drag coefficent provided, the drag coefficient is computed according to stable/unstable conditions of the air-sea interface following \citet{Large_Yeager_Rep04}. % Griffies doc: % 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. %How often the normalization is done is a matter of choice. In mom4p1, we choose to do so at each model time step, so that there is always a zero net input of water to the ocean-ice system. Others choose to normalize over an annual cycle, in which case the net imbalance over an annual cycle is used to alter the subsequent year�s water budget in an attempt to damp the annual water imbalance. Note that the annual budget approach may be inappropriate with interannually varying precipitation forcing. %When running ocean-ice coupled models, it is incorrect to include the water transport between the ocean and ice models when aiming to balance the hydrological cycle. The reason is that it is the sum of the water in the ocean plus ice that should be balanced when running ocean-ice models, not the water in any one sub-component. As an extreme example to illustrate the issue, consider an ocean-ice model with zero initial sea ice. As the ocean-ice model spins up, there should be a net accumulation of water in the growing sea ice, and thus a net loss of water from the ocean. The total water contained in the ocean plus ice system is constant, but there is an exchange of water between the subcomponents. This exchange should not be part of the normalization used to balance the hydrological cycle in ocean-ice models. % 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. %How often the normalization is done is a matter of choice. In mom4p1, we choose to do so at each model time step, % so that there is always a zero net input of water to the ocean-ice system. % Others choose to normalize over an annual cycle, in which case the net imbalance over an annual cycle is used % to alter the subsequent year�s water budget in an attempt to damp the annual water imbalance. % Note that the annual budget approach may be inappropriate with interannually varying precipitation forcing. % When running ocean-ice coupled models, it is incorrect to include the water transport between the ocean % and ice models when aiming to balance the hydrological cycle. % The reason is that it is the sum of the water in the ocean plus ice that should be balanced when running ocean-ice models, % not the water in any one sub-component. As an extreme example to illustrate the issue, % consider an ocean-ice model with zero initial sea ice. As the ocean-ice model spins up, % there should be a net accumulation of water in the growing sea ice, and thus a net loss of water from the ocean. % The total water contained in the ocean plus ice system is constant, but there is an exchange of water between % the subcomponents. This exchange should not be part of the normalization used to balance the hydrological cycle % in ocean-ice models. \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_STO.tex

 r5602 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter stochastic parametrization of EOS (STO) \label{STO} Authors: P.-A. Bouttier \minitoc \newpage $\$\newline    % force a new line The stochastic parametrization module aims to explicitly simulate uncertainties in the model. More particularly, \cite{Brankart_OM2013} has shown that, because of the nonlinearity of the seawater equation of state, unresolved scales represent a major source of uncertainties in the computation of the large scale horizontal density gradient (from T/S large scale fields), and that the impact of these uncertainties can be simulated by random processes representing unresolved T/S fluctuations. The stochastic formulation of the equation of state can be written as: \label{eq:eos_sto} \rho = \frac{1}{2} \sum_{i=1}^m\{ \rho[T+\Delta T_i,S+\Delta S_i,p_o(z)] + \rho[T-\Delta T_i,S-\Delta S_i,p_o(z)] \} where $p_o(z)$ is the reference pressure depending on the depth and $\Delta T_i$ and $\Delta S_i$ are a set of T/S perturbations defined as the scalar product of the respective local T/S gradients with random walks $\mathbf{\xi}$: \label{eq:sto_pert} \Delta T_i = \mathbf{\xi}_i \cdot \nabla T \qquad \hbox{and} \qquad \Delta S_i = \mathbf{\xi}_i \cdot \nabla S $\mathbf{\xi}_i$ are produced by a first-order autoregressive processes (AR-1) with a parametrized decorrelation time scale, and horizontal and vertical standard deviations $\sigma_s$. $\mathbf{\xi}$ are uncorrelated over the horizontal and fully correlated along the vertical. \section{Stochastic processes} \label{STO_the_details} The starting point of our implementation of stochastic parameterizations in NEMO is to observe that many existing parameterizations are based on autoregressive processes, which are used as a basic source of randomness to transform a deterministic model into a probabilistic model. A generic approach is thus to add one single new module in NEMO, generating processes with appropriate statistics to simulate each kind of uncertainty in the model (see \cite{Brankart_al_GMD2015} for more details). In practice, at every model grid point, independent Gaussian autoregressive processes~$\xi^{(i)},\,i=1,\ldots,m$ are first generated using the same basic equation: \label{eq:autoreg} \xi^{(i)}_{k+1} = a^{(i)} \xi^{(i)}_k + b^{(i)} w^{(i)} + c^{(i)} \noindent where $k$ is the index of the model timestep; and $a^{(i)}$, $b^{(i)}$, $c^{(i)}$ are parameters defining the mean ($\mu^{(i)}$) standard deviation ($\sigma^{(i)}$) and correlation timescale ($\tau^{(i)}$) of each process: \begin{itemize} \item for order~1 processes, $w^{(i)}$ is a Gaussian white noise, with zero mean and standard deviation equal to~1, and the parameters $a^{(i)}$, $b^{(i)}$, $c^{(i)}$ are given by: \label{eq:ord1} \left\{ \begin{array}{l} a^{(i)} = \varphi \\ b^{(i)} = \sigma^{(i)} \sqrt{ 1 - \varphi^2 } \qquad\qquad\mbox{with}\qquad\qquad \varphi = \exp \left( - 1 / \tau^{(i)} \right) \\ c^{(i)} = \mu^{(i)} \left( 1 - \varphi \right) \\ \end{array} \right. \item for order~$n>1$ processes, $w^{(i)}$ is an order~$n-1$ autoregressive process, with zero mean, standard deviation equal to~$\sigma^{(i)}$; correlation timescale equal to~$\tau^{(i)}$; and the parameters $a^{(i)}$, $b^{(i)}$, $c^{(i)}$ are given by: \label{eq:ord2} \left\{ \begin{array}{l} a^{(i)} = \varphi \\ b^{(i)} = \frac{n-1}{2(4n-3)} \sqrt{ 1 - \varphi^2 } \qquad\qquad\mbox{with}\qquad\qquad \varphi = \exp \left( - 1 / \tau^{(i)} \right) \\ c^{(i)} = \mu^{(i)} \left( 1 - \varphi \right) \\ \end{array} \right. \end{itemize} \noindent In this way, higher order processes can be easily generated recursively using the same piece of code implementing Eq.~(\ref{eq:autoreg}), and using succesively processes from order $0$ to~$n-1$ as~$w^{(i)}$. The parameters in Eq.~(\ref{eq:ord2}) are computed so that this recursive application of Eq.~(\ref{eq:autoreg}) leads to processes with the required standard deviation and correlation timescale, with the additional condition that the $n-1$ first derivatives of the autocorrelation function are equal to zero at~$t=0$, so that the resulting processes become smoother and smoother as $n$ is increased. Overall, this method provides quite a simple and generic way of generating a wide class of stochastic processes. However, this also means that new model parameters are needed to specify each of these stochastic processes. As in any parameterization of lacking physics, a very important issues then to tune these new parameters using either first principles, model simulations, or real-world observations. \section{Implementation details} \label{STO_thech_details} The computer code implementing stochastic parametrisations is made of one single FORTRAN module, with 3 public routines to be called by the model (in our case, NEMO): The first routine ({sto\_par}) is a direct implementation of Eq.~(\ref{eq:autoreg}), applied at each model grid point (in 2D or 3D), and called at each model time step ($k$) to update every autoregressive process ($i=1,\ldots,m$). This routine also includes a filtering operator, applied to $w^{(i)}$, to introduce a spatial correlation between the stochastic processes. The second routine ({sto\_par\_init}) is an initialization routine mainly dedicated to the computation of parameters $a^{(i)}, b^{(i)}, c^{(i)}$ for each autoregressive process, as a function of the statistical properties required by the model user (mean, standard deviation, time correlation, order of the process,\ldots). Parameters for the processes can be specified through the following namelist parameters: \begin{alltt} \tiny \begin{verbatim} nn_sto_eos = 1                ! number of independent random walks rn_eos_stdxy = 1.4            ! random walk horz. standard deviation (in grid points) rn_eos_stdz  = 0.7            ! random walk vert. standard deviation (in grid points) rn_eos_tcor  = 1440.0         ! random walk time correlation (in timesteps) nn_eos_ord  = 1               ! order of autoregressive processes nn_eos_flt  = 0               ! passes of Laplacian filter rn_eos_lim  = 2.0             ! limitation factor (default = 3.0) \end{verbatim} \end{alltt} This routine also includes the initialization (seeding) of the random number generator. The third routine ({sto\_rst\_write}) writes a restart file'' with the current value of all autoregressive processes to allow restarting a simulation from where it has been interrupted. This file also contains the current state of the random number generator. In case of a restart, this file is then read by the initialization routine ({sto\_par\_init}), so that the simulation can continue exactly as if it was not interrupted. Restart capabilities of the module are driven by the following namelist parameters: \begin{alltt} \tiny \begin{verbatim} ln_rststo = .false.           ! start from mean parameter (F) or from restart file (T) ln_rstseed = .true.           ! read seed of RNG from restart file cn_storst_in  = "restart_sto" !  suffix of stochastic parameter restart file (input) cn_storst_out = "restart_sto" !  suffix of stochastic parameter restart file (output) \end{verbatim} \end{alltt} In the particular case of the stochastic equation of state, there is also an additional module ({sto\_pts}) implementing Eq~\ref{eq:sto_pert} and specific piece of code in the equation of state implementing Eq~\ref{eq:eos_sto}. \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_STP.tex

 r4147 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]     \begin{center} \includegraphics[width=0.7\textwidth]{./TexFiles/Figures/Fig_TimeStepping_flowchart.pdf} \includegraphics[width=0.7\textwidth]{Fig_TimeStepping_flowchart} \caption{   \label{Fig_TimeStep_flowchart} Sketch of the leapfrog time stepping sequence in \NEMO from \citet{Leclair_Madec_OM09}. %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]     \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_MLF_forcing.pdf} \includegraphics[width=0.90\textwidth]{Fig_MLF_forcing} \caption{   \label{Fig_MLF_forcing} Illustration of forcing integration methods. } %% \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_TRA.tex

 r5602 % ================================================================ % Chapter 1 � Ocean Tracers (TRA) \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter 1 ——— Ocean Tracers (TRA) % ================================================================ \chapter{Ocean Tracers (TRA)} (BBL) parametrisation, and an internal damping (DMP) term. The terms QSR, BBC, BBL and DMP are optional. The external forcings and parameterisations require complex inputs and complex calculations (e.g. bulk formulae, estimation require complex inputs and complex calculations ($e.g.$ bulk formulae, estimation of mixing coefficients) that are carried out in the SBC, LDF and ZDF modules and described in chapters \S\ref{SBC}, \S\ref{LDF} and  \S\ref{ZDF}, respectively. Note that \mdl{tranpc}, the non-penetrative convection module,  although (temporarily) located in the NEMO/OPA/TRA directory, is described with the model vertical physics (ZDF). %%% \gmcomment{change the position of eosbn2 in the reference code} %%% Note that \mdl{tranpc}, the non-penetrative convection module, although located in the NEMO/OPA/TRA directory as it directly modifies the tracer fields, is described with the model vertical physics (ZDF) together with other available parameterization of convection. In the present chapter we also describe the diagnostic equations used to compute the sea-water properties (density, Brunt-Vais\"{a}l\"{a} frequency, specific heat and the sea-water properties (density, Brunt-V\"{a}is\"{a}l\"{a} frequency, specific heat and freezing point with associated modules \mdl{eosbn2} and \mdl{phycst}). found in the \textit{trattt} or \textit{trattt\_xxx} module, in the NEMO/OPA/TRA directory. The user has the option of extracting each tendency term on the rhs of the tracer equation for output (\key{trdtra} is defined), as described in Chap.~\ref{MISC}. The user has the option of extracting each tendency term on the RHS of the tracer equation for output (\np{ln\_tra\_trd} or \np{ln\_tra\_mxl}~=~true), as described in Chap.~\ref{DIA}. $\$\newline    % force a new ligne %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]    \begin{center} \includegraphics[width=0.9\textwidth]{./TexFiles/Figures/Fig_adv_scheme.pdf} \includegraphics[width=0.9\textwidth]{Fig_adv_scheme} \caption{   \label{Fig_adv_scheme} Schematic representation of some ways used to evaluate the tracer value \end{description} In all cases, this boundary condition retains local conservation of tracer. Global conservation is obtained in both rigid-lid and non-linear free surface cases, but not in the linear free surface case. Nevertheless, in the latter case, it is achieved to a good approximation since the non-conservative Global conservation is obtained in non-linear free surface case, but \textit{not} in the linear free surface case. Nevertheless, in the latter case, it is achieved to a good approximation since the non-conservative term is the product of the time derivative of the tracer and the free surface height, two quantities that are not correlated (see \S\ref{PE_free_surface}, The velocity field that appears in (\ref{Eq_tra_adv}) and (\ref{Eq_tra_adv_zco}) is the centred (\textit{now}) \textit{eulerian} ocean velocity (see Chap.~\ref{DYN}). When eddy induced velocity (\textit{eiv}) parameterisation is used it is the \textit{now} \textit{effective} velocity ($i.e.$ the sum of the eulerian and eiv velocities) which is used. is the centred (\textit{now}) \textit{effective} ocean velocity, $i.e.$ the \textit{eulerian} velocity (see Chap.~\ref{DYN}) plus the eddy induced velocity (\textit{eiv}) and/or the mixed layer eddy induced velocity (\textit{eiv}) when those parameterisations are used (see Chap.~\ref{LDF}). The choice of an advection scheme is made in the \textit{\ngn{nam\_traadv}} namelist, by Note that (1) cen2, cen4 and TVD schemes require an explicit diffusion (1) cen2 and TVD schemes require an explicit diffusion operator while the other schemes are diffusive enough so that they do not require additional diffusion ; (2) cen2, cen4, MUSCL2, and UBS are not \textit{positive} schemes (2) cen2, MUSCL2, and UBS are not \textit{positive} schemes \footnote{negative values can appear in an initially strictly positive tracer field which is advected} temperature is close to the freezing point). This combined scheme has been included for specific grid points in the ORCA2 and ORCA4 configurations only. This is an obsolescent feature as the recommended configuration only. This is an obsolescent feature as the recommended advection scheme for the ORCA configuration is TVD (see  \S\ref{TRA_adv_tvd}). have this order of accuracy. \gmcomment{Note also that ... blah, blah} % ------------------------------------------------------------------------------------------------------------- %        4nd order centred scheme % ------------------------------------------------------------------------------------------------------------- \subsection   [$4^{nd}$ order centred scheme (cen4) (\np{ln\_traadv\_cen4})] {$4^{nd}$ order centred scheme (cen4) (\np{ln\_traadv\_cen4}=true)} \label{TRA_adv_cen4} In the $4^{th}$ order formulation (to be implemented), tracer values are evaluated at velocity points as a $4^{th}$ order interpolation, and thus depend on the four neighbouring $T$-points. For example, in the $i$-direction: \label{Eq_tra_adv_cen4} \tau _u^{cen4} =\overline{   T - \frac{1}{6}\,\delta _i \left[ \delta_{i+1/2}[T] \,\right]   }^{\,i+1/2} Strictly speaking, the cen4 scheme is not a $4^{th}$ order advection scheme but a $4^{th}$ order evaluation of advective fluxes, since the divergence of advective fluxes \eqref{Eq_tra_adv} is kept at $2^{nd}$ order. The phrase $4^{th}$ order scheme'' used in oceanographic literature is usually associated with the scheme presented here. Introducing a \textit{true} $4^{th}$ order advection scheme is feasible but, for consistency reasons, it requires changes in the discretisation of the tracer advection together with changes in both the continuity equation and the momentum advection terms. A direct consequence of the pseudo-fourth order nature of the scheme is that it is not non-diffusive, i.e. the global variance of a tracer is not preserved using \textit{cen4}. Furthermore, it must be used in conjunction with an explicit diffusion operator to produce a sensible solution. The time-stepping is also performed using a leapfrog scheme in conjunction with an Asselin time-filter, so $T$ in (\ref{Eq_tra_adv_cen4}) is the \textit{now} tracer. At a $T$-grid cell adjacent to a boundary (coastline, bottom and surface), an additional hypothesis must be made to evaluate $\tau _u^{cen4}$. This hypothesis usually reduces the order of the scheme. Here we choose to set the gradient of $T$ across the boundary to zero. Alternative conditions can be specified, such as a reduction to a second order scheme for these near boundary grid points. % ------------------------------------------------------------------------------------------------------------- used for the diffusive part. An additional option has been added controlled by \np{ln\_traadv\_tvd\_zts}. By setting this logical to true, a TVD scheme is used on both horizontal and vertical direction, but on the latter, a split-explicit time stepping is used, with 5 sub-timesteps. This option can be useful when the value of the timestep is limited by vertical advection \citep{Lemarie_OM2015}. Note that in this case, a similar split-explicit time stepping should be used on vertical advection of momentum to ensure a better stability (see \np{ln\_dynzad\_zts} in \S\ref{DYN_zad}). % ------------------------------------------------------------------------------------------------------------- %        MUSCL scheme For an ocean grid point adjacent to land and where the ocean velocity is directed toward land, two choices are available: an upstream flux (\np{ln\_traadv\_muscl}=true) or a second order flux (\np{ln\_traadv\_muscl2}=true). Note that the latter choice does not ensure the \textit{positive} character of the scheme. Only the former can be used on both active and passive tracers. The two MUSCL schemes are implemented in the \mdl{traadv\_tvd} and \mdl{traadv\_tvd2} modules. directed toward land, two choices are available: an upstream flux (\np{ln\_traadv\_muscl}=true) or a second order flux (\np{ln\_traadv\_muscl2}=true). Note that the latter choice does not ensure the \textit{positive} character of the scheme. Only the former can be used on both active and passive tracers. The two MUSCL schemes are implemented in the \mdl{traadv\_tvd} and \mdl{traadv\_tvd2} modules. Note that when using np{ln\_traadv\_msc\_ups}~=~true in addition to \np{ln\_traadv\_muscl}=true, the MUSCL fluxes are replaced by upstream fluxes in vicinity of river mouths. % ------------------------------------------------------------------------------------------------------------- direction (as for the UBS case) should be implemented to restore this property. % ------------------------------------------------------------------------------------------------------------- %        PPM scheme % ------------------------------------------------------------------------------------------------------------- \subsection   [Piecewise Parabolic Method (PPM) (\np{ln\_traadv\_ppm})] {Piecewise Parabolic Method (PPM) (\np{ln\_traadv\_ppm}=true)} \label{TRA_adv_ppm} The Piecewise Parabolic Method (PPM) proposed by Colella and Woodward (1984) \sgacomment{reference?} is based on a quadradic piecewise construction. Like the QCK scheme, it is associated with the ULTIMATE QUICKEST limiter \citep{Leonard1991}. It has been implemented in \NEMO by G. Reffray (MERCATOR-ocean) but is not yet offered in the reference version 3.3. % ================================================================ surfaces is given by: \label{Eq_tra_ldf_lap} D_T^{lT} =\frac{1}{b_tT} \left( \; D_T^{lT} =\frac{1}{b_t} \left( \; \delta _{i}\left[ A_u^{lT} \; \frac{e_{2u}\,e_{3u}}{e_{1u}} \;\delta _{i+1/2} [T] \right] + \delta _{j}\left[ A_v^{lT} \;  \frac{e_{1v}\,e_{3v}}{e_{2v}} \;\delta _{j+1/2} [T] \right]  \;\right) the thickness of the top model layer. Due to interactions and mass exchange of water ($F_{mass}$) with other Earth system components ($i.e.$ atmosphere, sea-ice, land), the change in the heat and salt content of the surface layer of the ocean is due both to the heat and salt fluxes crossing the sea surface (not linked with $F_{mass}$) and to the heat and salt content of the mass exchange. \sgacomment{ the following does not apply to the release to which this documentation is attached and so should not be included .... In a forthcoming release, these two parts, computed in the surface module (SBC), will be included directly in $Q_{ns}$, the surface heat flux and $F_{salt}$, the surface salt flux. The specification of these fluxes is further detailed in the SBC chapter (see \S\ref{SBC}). This change will provide a forcing formulation which is the same for any tracer (including temperature and salinity). In the current version, the situation is a little bit more complicated. } Due to interactions and mass exchange of water ($F_{mass}$) with other Earth system components ($i.e.$ atmosphere, sea-ice, land), the change in the heat and salt content of the surface layer of the ocean is due both to the heat and salt fluxes crossing the sea surface (not linked with $F_{mass}$) and to the heat and salt content of the mass exchange. They are both included directly in $Q_{ns}$, the surface heat flux, and $F_{salt}$, the surface salt flux (see \S\ref{SBC} for further details). By doing this, the forcing formulation is the same for any tracer (including temperature and salinity). The surface module (\mdl{sbcmod}, see \S\ref{SBC}) provides the following $\bullet$ $Q_{ns}$, the non-solar part of the net surface heat flux that crosses the sea surface (i.e. the difference between the total surface heat flux and the fraction of the short wave flux that penetrates into the water column, see \S\ref{TRA_qsr}) $\bullet$ \textit{emp}, the mass flux exchanged with the atmosphere (evaporation minus precipitation) $\bullet$ $\textit{emp}_S$, an equivalent mass flux taking into account the effect of ice-ocean mass exchange $\bullet$ \textit{rnf}, the mass flux associated with runoff (see \S\ref{SBC_rnf} for further detail of how it acts on temperature and salinity tendencies) The $\textit{emp}_S$ field is not simply the budget of evaporation-precipitation+freezing-melting because the sea-ice is not currently embedded in the ocean but levitates above it. There is no mass exchanged between the sea-ice and the ocean. Instead we only take into account the salt flux associated with the non-zero salinity of sea-ice, and the concentration/dilution effect due to the freezing/melting (F/M) process. These two parts of the forcing are then converted into an equivalent mass flux given by $\textit{emp}_S - \textit{emp}$. As a result of this mess, the surface boundary condition on temperature and salinity is applied as follows: In the nonlinear free surface case (\key{vvl} is defined): penetrates into the water column, see \S\ref{TRA_qsr}) plus the heat content associated with of the mass exchange with the atmosphere and lands. $\bullet$ $\textit{sfx}$, the salt flux resulting from ice-ocean mass exchange (freezing, melting, ridging...) $\bullet$ \textit{emp}, the mass flux exchanged with the atmosphere (evaporation minus precipitation) and possibly with the sea-ice and ice-shelves. $\bullet$ \textit{rnf}, the mass flux associated with runoff (see \S\ref{SBC_rnf} for further detail of how it acts on temperature and salinity tendencies) $\bullet$ \textit{fwfisf}, the mass flux associated with ice shelf melt, (see \S\ref{SBC_isf} for further details on how the ice shelf melt is computed and applied).\\ In the non-linear free surface case (\key{vvl} is defined), the surface boundary condition on temperature and salinity is applied as follows: \label{Eq_tra_sbc} \begin{aligned} &F^T = \frac{ 1 }{\rho _o \;C_p \,\left. e_{3t} \right|_{k=1} }  &\overline{ Q_{ns}       }^t  & \\ & F^S =\frac{ 1 }{\rho _o  \,      \left. e_{3t} \right|_{k=1} }  &\overline{ \textit{sfx} }^t   & \\ \end{aligned} where $\overline{x }^t$ means that $x$ is averaged over two consecutive time steps ($t-\rdt/2$ and $t+\rdt/2$). Such time averaging prevents the divergence of odd and even time step (see \S\ref{STP}). In the linear free surface case (\key{vvl} is \textit{not} defined), an additional term has to be added on both temperature and salinity. On temperature, this term remove the heat content associated with mass exchange that has been added to $Q_{ns}$. On salinity, this term mimics the concentration/dilution effect that would have resulted from a change in the volume of the first level. The resulting surface boundary condition is applied as follows: \label{Eq_tra_sbc_lin} \begin{aligned} &F^T = \frac{ 1 }{\rho _o \;C_p \,\left. e_{3t} \right|_{k=1} } % & F^S =\frac{ 1 }{\rho _o \,\left. e_{3t} \right|_{k=1} } &\overline{ \left( (\textit{emp}_S - \textit{emp})\;\left. S \right|_{k=1}  \right) }^t   & \\ &\overline{ \left( \;\textit{sfx} - \textit{emp} \;\left. S \right|_{k=1}  \right) }^t   & \\ \end{aligned} In the linear free surface case (\key{vvl} not defined): \label{Eq_tra_sbc_lin} \begin{aligned} &F^T = \frac{ 1 }{\rho _o \;C_p \,\left. e_{3t} \right|_{k=1} }  &\overline{ Q_{ns} }^t  & \\ % & F^S =\frac{ 1 }{\rho _o \,\left. e_{3t} \right|_{k=1} } &\overline{ \left( \textit{emp}_S\;\left. S \right|_{k=1}  \right) }^t   & \\ \end{aligned} where $\overline{x }^t$ means that $x$ is averaged over two consecutive time steps ($t-\rdt/2$ and $t+\rdt/2$). Such time averaging prevents the divergence of odd and even time step (see \S\ref{STP}). The two set of equations, \eqref{Eq_tra_sbc} and \eqref{Eq_tra_sbc_lin}, are obtained by assuming that the temperature of precipitation and evaporation are equal to the ocean surface temperature and that their salinity is zero. Therefore, the heat content of the \textit{emp} budget must be added to the temperature equation in the variable volume case, while it does not appear in the constant volume case. Similarly, the \textit{emp} budget affects the ocean surface salinity in the constant volume case (through the concentration dilution effect) while it does not appears explicitly in the variable volume case since salinity change will be induced by volume change. In both constant and variable volume cases, surface salinity will change with ice-ocean salt flux and F/M flux (both contained in $\textit{emp}_S - \textit{emp}$) without mass exchanges. Note that the concentration/dilution effect due to F/M is computed using a constant ice salinity as well as a constant ocean salinity. This approximation suppresses the correlation between \textit{SSS} and F/M flux, allowing the ice-ocean salt exchanges to be conservative. Indeed, if this approximation is not made, even if the F/M budget is zero on average over the whole ocean domain and over the seasonal cycle, the associated salt flux is not zero, since sea-surface salinity and F/M flux are intrinsically correlated (high \textit{SSS} are found where freezing is strong whilst low \textit{SSS} is usually associated with high melting areas). Even using this approximation, an exact conservation of heat and salt content is only achieved in the variable volume case. In the constant volume case, there is a small imbalance associated with the product $(\partial_t\eta - \textit{emp}) * \textit{SSS}$. Nevertheless, the salt content variation is quite small and will not induce a long term drift as there is no physical reason for $(\partial_t\eta - \textit{emp})$ and \textit{SSS} to be correlated \citep{Roullet_Madec_JGR00}. Note that, while quite small, the imbalance in the constant volume case is larger Note that an exact conservation of heat and salt content is only achieved with non-linear free surface. In the linear free surface case, there is a small imbalance. The imbalance is larger than the imbalance associated with the Asselin time filter \citep{Leclair_Madec_OM09}. This is the reason why the modified filter is not applied in the constant volume case. This is the reason why the modified filter is not applied in the linear free surface case (see \S\ref{STP}). % ------------------------------------------------------------------------------------------------------------- ($i.e.$ the inverses of the extinction length scales) are tabulated over 61 nonuniform chlorophyll classes ranging from 0.01 to 10 g.Chl/L (see the routine \rou{trc\_oce\_rgb} in \mdl{trc\_oce} module). Three types of chlorophyll can be chosen in the RGB formulation: (1) a constant 0.05 g.Chl/L value everywhere (\np{nn\_chdta}=0) ; (2) an observed time varying chlorophyll (\np{nn\_chdta}=1) ; (3) simulated time varying chlorophyll by TOP biogeochemical model (\np{ln\_qsr\_bio}=true). In the latter case, the RGB formulation is used to calculate both the phytoplankton light limitation in PISCES or LOBSTER and the oceanic heating rate. in \mdl{trc\_oce} module). Four types of chlorophyll can be chosen in the RGB formulation: \begin{description} \item[\np{nn\_chdta}=0] a constant 0.05 g.Chl/L value everywhere ; \item[\np{nn\_chdta}=1] an observed time varying chlorophyll deduced from satellite surface ocean color measurement spread uniformly in the vertical direction ; \item[\np{nn\_chdta}=2] same as previous case except that a vertical profile of chlorophyl is used. Following \cite{Morel_Berthon_LO89}, the profile is computed from the local surface chlorophyll value ; \item[\np{ln\_qsr\_bio}=true] simulated time varying chlorophyll by TOP biogeochemical model. In this case, the RGB formulation is used to calculate both the phytoplankton light limitation in PISCES or LOBSTER and the oceanic heating rate. \end{description} The trend in \eqref{Eq_tra_qsr} associated with the penetration of the solar radiation is added to the temperature trend, and the surface heat flux is modified in routine \mdl{traqsr}. %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]     \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_TRA_Irradiance.pdf} \includegraphics[width=1.0\textwidth]{Fig_TRA_Irradiance} \caption{    \label{Fig_traqsr_irradiance} Penetration profile of the downward solar irradiance calculated by four models. \label{TRA_bbc} %--------------------------------------------nambbc-------------------------------------------------------- \namdisplay{namtra_bbc} \namdisplay{nambbc} %-------------------------------------------------------------------------------------------------------------- %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]     \begin{center} \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_TRA_geoth.pdf} \includegraphics[width=1.0\textwidth]{Fig_TRA_geoth} \caption{   \label{Fig_geothermal} Geothermal Heat flux (in $mW.m^{-2}$) used by \cite{Emile-Geay_Madec_OS09}. %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]   \begin{center} \includegraphics[width=0.7\textwidth]{./TexFiles/Figures/Fig_BBL_adv.pdf} \includegraphics[width=0.7\textwidth]{Fig_BBL_adv} \caption{   \label{Fig_bbl} Advective/diffusive Bottom Boundary Layer. The BBL parameterisation is \subsection[DMP\_TOOLS]{Generating resto.nc using DMP\_TOOLS} DMP\_TOOLS can be used to generate a netcdf file containing the restoration coefficient $\gamma$. Note that in order to maintain bit comparison with previous NEMO versions DMP\_TOOLS must be compiled and run on the same machine as the NEMO model. A mesh\_mask.nc file for the model configuration is required as an input. This can be generated by carrying out a short model run with the namelist parameter \np{nn\_msh} set to 1. The namelist parameter \np{ln\_tradmp} will also need to be set to .false. for this to work. The \nl{nam\_dmp\_create} namelist in the DMP\_TOOLS directory is used to specify options for the restoration coefficient. DMP\_TOOLS can be used to generate a netcdf file containing the restoration coefficient $\gamma$. Note that in order to maintain bit comparison with previous NEMO versions DMP\_TOOLS must be compiled and run on the same machine as the NEMO model. A mesh\_mask.nc file for the model configuration is required as an input. This can be generated by carrying out a short model run with the namelist parameter \np{nn\_msh} set to 1. The namelist parameter \np{ln\_tradmp} will also need to be set to .false. for this to work. The \nl{nam\_dmp\_create} namelist in the DMP\_TOOLS directory is used to specify options for the restoration coefficient. %--------------------------------------------nam_dmp_create------------------------------------------------- \np{cp\_cfg}, \np{cp\_cpz}, \np{jp\_cfg} and \np{jperio} specify the model configuration being used and should be the same as specified in \nl{namcfg}. The variable \nl{lzoom} is used to specify that the damping is being used as in case \textit{a} above to provide boundary conditions to a zoom configuration. In the case of the arctic or antarctic zoom configurations this includes some specific treatment. Otherwise damping is applied to the 6 grid points along the ocean boundaries. The open boundaries are specified by the variables \np{lzoom\_n}, \np{lzoom\_e}, \np{lzoom\_s}, \np{lzoom\_w} in the \nl{nam\_zoom\_dmp} name list. The remaining switch namelist variables determine the spatial variation of the restoration coefficient in non-zoom configurations. \np{ln\_full\_field} specifies that newtonian damping should be applied to the whole model domain. \np{ln\_med\_red\_seas} specifies grid specific restoration coefficients in the Mediterranean Sea for the ORCA4, ORCA2 and ORCA05 configurations. If \np{ln\_old\_31\_lev\_code} is set then the depth variation of the coeffients will be specified as a function of the model number. This option is included to allow backwards compatability of the ORCA2 reference configurations with previous model versions. \np{ln\_coast} specifies that the restoration coefficient should be reduced near to coastlines. This option only has an effect if \np{ln\_full\_field} is true. \np{ln\_zero\_top\_layer} specifies that the restoration coefficient should be zero in the surface layer. Finally \np{ln\_custom} specifies that the custom module will be called. This module is contained in the file custom.F90 and can be edited by users. For example damping could be applied in a specific region. The restoration coefficient can be set to zero in equatorial regions by specifying a positive value of \np{nn\_hdmp}. Equatorward of this latitude the restoration coefficient will be zero with a smooth transition to the full values of a 10$^{\circ}$ latitud band. This is often used because of the short adjustment time scale in the equatorial region \citep{Reverdin1991, Fujio1991, Marti_PhD92}. The time scale associated with the damping depends on the depth as a hyperbolic tangent, with \np{rn\_surf} as surface value, \np{rn\_bot} as bottom value and a transition depth of \np{rn\_dep}. The remaining switch namelist variables determine the spatial variation of the restoration coefficient in non-zoom configurations. \np{ln\_full\_field} specifies that newtonian damping should be applied to the whole model domain. \np{ln\_med\_red\_seas} specifies grid specific restoration coefficients in the Mediterranean Sea for the ORCA4, ORCA2 and ORCA05 configurations. If \np{ln\_old\_31\_lev\_code} is set then the depth variation of the coeffients will be specified as a function of the model number. This option is included to allow backwards compatability of the ORCA2 reference configurations with previous model versions. \np{ln\_coast} specifies that the restoration coefficient should be reduced near to coastlines. This option only has an effect if \np{ln\_full\_field} is true. \np{ln\_zero\_top\_layer} specifies that the restoration coefficient should be zero in the surface layer. Finally \np{ln\_custom} specifies that the custom module will be called. This module is contained in the file custom.F90 and can be edited by users. For example damping could be applied in a specific region. The restoration coefficient can be set to zero in equatorial regions by specifying a positive value of \np{nn\_hdmp}. Equatorward of this latitude the restoration coefficient will be zero with a smooth transition to the full values of a 10\deg latitud band. This is often used because of the short adjustment time scale in the equatorial region \citep{Reverdin1991, Fujio1991, Marti_PhD92}. The time scale associated with the damping depends on the depth as a hyperbolic tangent, with \np{rn\_surf} as surface value, \np{rn\_bot} as bottom value and a transition depth of \np{rn\_dep}. % ================================================================ %        Equation of State % ------------------------------------------------------------------------------------------------------------- \subsection{Equation of State (\np{nn\_eos} = 0, 1 or 2)} \subsection{Equation Of Seawater (\np{nn\_eos} = -1, 0, or 1)} \label{TRA_eos} It is necessary to know the equation of state for the ocean very accurately to determine stability properties (especially the Brunt-Vais\"{a}l\"{a} frequency), particularly in the deep ocean. The ocean seawater volumic mass, $\rho$, abusively called density, is a non linear empirical function of \textit{in situ} temperature, salinity and pressure. The reference equation of state is that defined by the Joint Panel on Oceanographic Tables and Standards \citep{UNESCO1983}. It was the standard equation of state used in early releases of OPA. However, even though this computation is fully vectorised, it is quite time consuming ($15$ to $20${\%} of the total CPU time) since it requires the prior computation of the \textit{in situ} temperature from the model \textit{potential} temperature using the \citep{Bryden1973} polynomial for adiabatic lapse rate and a $4^th$ order Runge-Kutta integration scheme. Since OPA6, we have used the \citet{JackMcD1995} equation of state for seawater instead. It allows the computation of the \textit{in situ} ocean density directly as a function of \textit{potential} temperature relative to the surface (an \NEMO variable), the practical salinity (another \NEMO variable) and the pressure (assuming no pressure variation along geopotential surfaces, $i.e.$ the pressure in decibars is approximated by the depth in meters). Both the \citet{UNESCO1983} and \citet{JackMcD1995} equations of state have exactly the same except that the values of the various coefficients have been adjusted by \citet{JackMcD1995} in order to directly use the \textit{potential} temperature instead of the \textit{in situ} one. This reduces the CPU time of the \textit{in situ} density computation to about $3${\%} of the total CPU time, while maintaining a quite accurate equation of state. In the computer code, a \textit{true} density anomaly, $d_a= \rho / \rho_o - 1$, is computed, with $\rho_o$ a reference volumic mass. Called \textit{rau0} in the code, $\rho_o$ is defined in \mdl{phycst}, and a value of $1,035~Kg/m^3$. The Equation Of Seawater (EOS) is an empirical nonlinear thermodynamic relationship linking seawater density, $\rho$, to a number of state variables, most typically temperature, salinity and pressure. Because density gradients control the pressure gradient force through the hydrostatic balance, the equation of state provides a fundamental bridge between the distribution of active tracers and the fluid dynamics. Nonlinearities of the EOS are of major importance, in particular influencing the circulation through determination of the static stability below the mixed layer, thus controlling rates of exchange between the atmosphere  and the ocean interior \citep{Roquet_JPO2015}. Therefore an accurate EOS based on either the 1980 equation of state (EOS-80, \cite{UNESCO1983}) or TEOS-10 \citep{TEOS10} standards should be used anytime a simulation of the real ocean circulation is attempted \citep{Roquet_JPO2015}. The use of TEOS-10 is highly recommended because \textit{(i)} it is the new official EOS, \textit{(ii)} it is more accurate, being based on an updated database of laboratory measurements, and \textit{(iii)} it uses Conservative Temperature and Absolute Salinity (instead of potential temperature and practical salinity for EOS-980, both variables being more suitable for use as model variables \citep{TEOS10, Graham_McDougall_JPO13}. EOS-80 is an obsolescent feature of the NEMO system, kept only for backward compatibility. For process studies, it is often convenient to use an approximation of the EOS. To that purposed, a simplified EOS (S-EOS) inspired by \citet{Vallis06} is also available. In the computer code, a density anomaly, $d_a= \rho / \rho_o - 1$, is computed, with $\rho_o$ a reference density. Called \textit{rau0} in the code, $\rho_o$ is set in \mdl{phycst} to a value of $1,026~Kg/m^3$. This is a sensible choice for the reference density used in a Boussinesq ocean climate model, as, with the exception of only a small percentage of the ocean, density in the World Ocean varies by no more than 2$\%$ from $1,035~kg/m^3$ \citep{Gill1982}. Options are defined through the  \ngn{nameos} namelist variables. The default option (namelist parameter \np{nn\_eos}=0) is the \citet{JackMcD1995} equation of state. Its use is highly recommended. However, for process studies, it is often convenient to use a linear approximation of the density. density in the World Ocean varies by no more than 2$\%$ from that value \citep{Gill1982}. Options are defined through the  \ngn{nameos} namelist variables, and in particular \np{nn\_eos} which controls the EOS used (=-1 for TEOS10 ; =0 for EOS-80 ; =1 for S-EOS). \begin{description} \item[\np{nn\_eos}$=-1$] the polyTEOS10-bsq equation of seawater \citep{Roquet_OM2015} is used. The accuracy of this approximation is comparable to the TEOS-10 rational function approximation, but it is optimized for a boussinesq fluid and the polynomial expressions have simpler and more computationally efficient expressions for their derived quantities which make them more adapted for use in ocean models. Note that a slightly higher precision polynomial form is now used replacement of the TEOS-10 rational function approximation for hydrographic data analysis  \citep{TEOS10}. A key point is that conservative state variables are used: Absolute Salinity (unit: g/kg, notation: $S_A$) and Conservative Temperature (unit: \degC, notation: $\Theta$). The pressure in decibars is approximated by the depth in meters. With TEOS10, the specific heat capacity of sea water, $C_p$, is a constant. It is set to $C_p=3991.86795711963~J\,Kg^{-1}\,^{\circ}K^{-1}$, according to \citet{TEOS10}. Choosing polyTEOS10-bsq implies that the state variables used by the model are $\Theta$ and $S_A$. In particular, the initial state deined by the user have to be given as \textit{Conservative} Temperature and \textit{Absolute} Salinity. In addition, setting \np{ln\_useCT} to \textit{true} convert the Conservative SST to potential SST prior to either computing the air-sea and ice-sea fluxes (forced mode) or sending the SST field to the atmosphere (coupled mode). \item[\np{nn\_eos}$=0$] the polyEOS80-bsq equation of seawater is used. It takes the same polynomial form as the polyTEOS10, but the coefficients have been optimized to accurately fit EOS80 (Roquet, personal comm.). The state variables used in both the EOS80 and the ocean model are: the Practical Salinity ((unit: psu, notation: $S_p$)) and Potential Temperature (unit: $^{\circ}C$, notation: $\theta$). The pressure in decibars is approximated by the depth in meters. With thsi EOS, the specific heat capacity of sea water, $C_p$, is a function of temperature, salinity and pressure \citep{UNESCO1983}. Nevertheless, a severe assumption is made in order to have a heat content ($C_p T_p$) which is conserved by the model: $C_p$ is set to a constant value, the TEOS10 value. \item[\np{nn\_eos}$=1$] a simplified EOS (S-EOS) inspired by \citet{Vallis06} is chosen, the coefficients of which has been optimized to fit the behavior of TEOS10 (Roquet, personal comm.) (see also \citet{Roquet_JPO2015}). It provides a simplistic linear representation of both cabbeling and thermobaricity effects which is enough for a proper treatment of the EOS in theoretical studies \citep{Roquet_JPO2015}. With such an equation of state there is no longer a distinction between \textit{in situ} and \textit{potential} density and both cabbeling and thermobaric effects are removed. Two linear formulations are available: a function of $T$ only (\np{nn\_eos}=1) and a function of both $T$ and $S$ (\np{nn\_eos}=2): \label{Eq_tra_eos_linear} \textit{conservative} and \textit{potential} temperature, as well as between \textit{absolute} and \textit{practical} salinity. S-EOS takes the following expression: \label{Eq_tra_S-EOS} \begin{split} d_a(T)       &=  \rho (T)      /  \rho_o   - 1     =  \  0.0285         -  \alpha   \;T     \\ d_a(T,S)    &=  \rho (T,S)   /  \rho_o   - 1     =  \  \beta \; S       -  \alpha   \;T d_a(T,S,z)  =  ( & - a_0 \; ( 1 + 0.5 \; \lambda_1 \; T_a + \mu_1 \; z ) * T_a  \\ & + b_0 \; ( 1 - 0.5 \; \lambda_2 \; S_a - \mu_2 \; z ) * S_a  \\ & - \nu \; T_a \; S_a \;  ) \; / \; \rho_o                     \\ with \ \  T_a = T-10  \; ;  & \;  S_a = S-35  \; ;\;  \rho_o = 1026~Kg/m^3 \end{split} where $\alpha$ and $\beta$ are the thermal and haline expansion coefficients, and $\rho_o$, the reference volumic mass, $rau0$. ($\alpha$ and $\beta$ can be modified through the \np{rn\_alpha} and \np{rn\_beta} namelist variables). Note that when $d_a$ is a function of $T$ only (\np{nn\_eos}=1), the salinity is a passive tracer and can be used as such. % ------------------------------------------------------------------------------------------------------------- %        Brunt-Vais\"{a}l\"{a} Frequency % ------------------------------------------------------------------------------------------------------------- \subsection{Brunt-Vais\"{a}l\"{a} Frequency (\np{nn\_eos} = 0, 1 or 2)} where the computer name of the coefficients as well as their standard value are given in \ref{Tab_SEOS}. In fact, when choosing S-EOS, various approximation of EOS can be specified simply by changing the associated coefficients. Setting to zero the two thermobaric coefficients ($\mu_1$, $\mu_2$) remove thermobaric effect from S-EOS. setting to zero the three cabbeling coefficients ($\lambda_1$, $\lambda_2$, $\nu$) remove cabbeling effect from S-EOS. Keeping non-zero value to $a_0$ and $b_0$ provide a linear EOS function of T and S. \end{description} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{table}[!tb] \begin{center} \begin{tabular}{|p{26pt}|p{72pt}|p{56pt}|p{136pt}|} \hline coeff.   & computer name   & S-EOS     &  description                      \\ \hline $a_0$       & \np{rn\_a0}     & 1.6550 $10^{-1}$ &  linear thermal expansion coeff.    \\ \hline $b_0$       & \np{rn\_b0}     & 7.6554 $10^{-1}$ &  linear haline  expansion coeff.    \\ \hline $\lambda_1$ & \np{rn\_lambda1}& 5.9520 $10^{-2}$ &  cabbeling coeff. in $T^2$          \\ \hline $\lambda_2$ & \np{rn\_lambda2}& 5.4914 $10^{-4}$ &  cabbeling coeff. in $S^2$       \\ \hline $\nu$       & \np{rn\_nu}     & 2.4341 $10^{-3}$ &  cabbeling coeff. in $T \, S$       \\ \hline $\mu_1$     & \np{rn\_mu1}    & 1.4970 $10^{-4}$ &  thermobaric coeff. in T         \\ \hline $\mu_2$     & \np{rn\_mu2}    & 1.1090 $10^{-5}$ &  thermobaric coeff. in S            \\ \hline \end{tabular} \caption{ \label{Tab_SEOS} Standard value of S-EOS coefficients. } \end{center} \end{table} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> % ------------------------------------------------------------------------------------------------------------- %        Brunt-V\"{a}is\"{a}l\"{a} Frequency % ------------------------------------------------------------------------------------------------------------- \subsection{Brunt-V\"{a}is\"{a}l\"{a} Frequency (\np{nn\_eos} = 0, 1 or 2)} \label{TRA_bn2} An accurate computation of the ocean stability (i.e. of $N$, the brunt-Vais\"{a}l\"{a} frequency) is of paramount importance as it is used in several ocean parameterisations (namely TKE, KPP, Richardson number dependent vertical diffusion, enhanced vertical diffusion, non-penetrative convection, iso-neutral diffusion). In particular, one must be aware that $N^2$ has to be computed with an \textit{in situ} reference. The expression for $N^2$ depends on the type of equation of state used (\np{nn\_eos} namelist parameter). For \np{nn\_eos}=0 (\citet{JackMcD1995} equation of state), the \citet{McDougall1987} polynomial expression is used (with the pressure in decibar approximated by the depth in meters): An accurate computation of the ocean stability (i.e. of $N$, the brunt-V\"{a}is\"{a}l\"{a} frequency) is of paramount importance as determine the ocean stratification and is used in several ocean parameterisations (namely TKE, GLS, Richardson number dependent vertical diffusion, enhanced vertical diffusion, non-penetrative convection, tidal mixing parameterisation, iso-neutral diffusion). In particular, $N^2$ has to be computed at the local pressure (pressure in decibar being approximated by the depth in meters). The expression for $N^2$ is given by: \label{Eq_tra_bn2} N^2 = \frac{g}{e_{3w}} \; \beta   \ \left(  \alpha / \beta \ \delta_{k+1/2}[T]     - \delta_{k+1/2}[S]   \right) where $\alpha$ and $\beta$ are the thermal and haline expansion coefficients. They are a function of  $\overline{T}^{\,k+1/2},\widetilde{S}=\overline{S}^{\,k+1/2} - 35.$, and  $z_w$, with $T$ the \textit{potential} temperature and $\widetilde{S}$ a salinity anomaly. Note that both $\alpha$ and $\beta$ depend on \textit{potential} temperature and salinity which are averaged at $w$-points prior to the computation instead of being computed at $T$-points and then averaged to $w$-points. When a linear equation of state is used (\np{nn\_eos}=1 or 2, \eqref{Eq_tra_bn2} reduces to: \label{Eq_tra_bn2_linear} N^2 = \frac{g}{e_{3w}} \left(   \beta \;\delta_{k+1/2}[S] - \alpha \;\delta_{k+1/2}[T]   \right) where $\alpha$ and $\beta$ are the constant coefficients used to defined the linear equation of state \eqref{Eq_tra_eos_linear}. % ------------------------------------------------------------------------------------------------------------- %        Specific Heat % ------------------------------------------------------------------------------------------------------------- \subsection    [Specific Heat (\textit{phycst})] {Specific Heat (\mdl{phycst})} \label{TRA_adv_ldf} The specific heat of sea water, $C_p$, is a function of temperature, salinity and pressure \citep{UNESCO1983}. It is only used in the model to convert surface heat fluxes into surface temperature increase and so the pressure dependence is neglected. The dependence on $T$ and $S$ is weak. For example, with $S=35~psu$, $C_p$ increases from $3989$ to $4002$ when $T$ varies from -2~\degres C to 31~\degres C. Therefore, $C_p$ has been chosen as a constant: $C_p=4.10^3~J\,Kg^{-1}\,\degres K^{-1}$. Its value is set in \mdl{phycst} module. where $(T,S) = (\Theta, S_A)$ for TEOS10, $= (\theta, S_p)$ for TEOS-80, or $=(T,S)$ for S-EOS, and, $\alpha$ and $\beta$ are the thermal and haline expansion coefficients. The coefficients are a polynomial function of temperature, salinity and depth which expression depends on the chosen EOS. They are computed through \textit{eos\_rab}, a \textsc{Fortran} function that can be found in \mdl{eosbn2}. % ------------------------------------------------------------------------------------------------------------- sea water ($i.e.$ referenced to the surface $p=0$), thus the pressure dependent terms in \eqref{Eq_tra_eos_fzp} (last term) have been dropped. The freezing point is computed through \textit{tfreez}, a \textsc{Fortran} function that can be found point is computed through \textit{eos\_fzp}, a \textsc{Fortran} function that can be found in \mdl{eosbn2}. \label{TRA_zpshde} \gmcomment{STEVEN: to be consistent with earlier discussion of differencing and averaging operators, I've changed "derivative" to "difference" and "mean" to "average"} With partial bottom cells (\np{ln\_zps}=true), in general, tracers in horizontally \gmcomment{STEVEN: to be consistent with earlier discussion of differencing and averaging operators, I've changed "derivative" to "difference" and "mean" to "average"} With partial cells (\np{ln\_zps}=true) at bottom and top (\np{ln\_isfcav}=true), in general, tracers in horizontally adjacent cells live at different depths. Horizontal gradients of tracers are needed for horizontal diffusion (\mdl{traldf} module) and for the hydrostatic pressure gradient (\mdl{dynhpg} module) to be active. \gmcomment{STEVEN from gm : question: not sure of  what -to be active- means} Before taking horizontal gradients between the tracers next to the bottom, a linear interpolation in the vertical is used to approximate the deeper tracer as if it actually %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!p]    \begin{center} \includegraphics[width=0.9\textwidth]{./TexFiles/Figures/Partial_step_scheme.pdf} \includegraphics[width=0.9\textwidth]{Partial_step_scheme} \caption{   \label{Fig_Partial_step_scheme} Discretisation of the horizontal difference and average of tracers in the $z$-partial \gmcomment{gm :   this last remark has to be done} %%% If under ice shelf seas opened (\np{ln\_isfcav}=true), the partial cell properties at the top are computed in the same way as for the bottom. Some extra variables are, however, computed to reduce the flow generated at the top and bottom if $z*$ coordinates activated. The extra variables calculated and used by \S\ref{DYN_hpg_isf} are: $\bullet$ $\overline{T}_k^{\,i+1/2}$ as described in \eqref{Eq_zps_hde} $\bullet$ $\delta _{i+1/2} Z_{T_k} = \widetilde {Z}^{\,i}_{T_k}-Z^{\,i}_{T_k}$ to compute the pressure gradient correction term used by \eqref{Eq_dynhpg_sco} in \S\ref{DYN_hpg_isf}, with $\widetilde {Z}_{T_k}$ the depth of the point $\widetilde {T}_{k}$ in case of $z^*$ coordinates (this term = 0 in z-coordinates) \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Chap_ZDF.tex

 r5602 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ % Chapter  Vertical Ocean Physics (ZDF) points, respectively (see \S\ref{TRA_zdf} and \S\ref{DYN_zdf}). These coefficients can be assumed to be either constant, or a function of the local Richardson number, or computed from a turbulent closure model (either TKE or KPP formulation). The computation of these coefficients is initialized in the \mdl{zdfini} module and performed in the \mdl{zdfric}, \mdl{zdftke} or \mdl{zdfkpp} modules. The trends due to the vertical momentum and tracer diffusion, including the surface forcing, are computed and added to the general trend in the \mdl{dynzdf} and \mdl{trazdf} modules, respectively. Richardson number, or computed from a turbulent closure model (TKE, GLS or KPP formulation). The computation of these coefficients is initialized in the \mdl{zdfini} module and performed in the \mdl{zdfric}, \mdl{zdftke}, \mdl{zdfgls} or \mdl{zdfkpp} modules. The trends due to the vertical momentum and tracer diffusion, including the surface forcing, are computed and added to the general trend in the \mdl{dynzdf} and \mdl{trazdf} modules, respectively. These trends can be computed using either a forward time stepping scheme (namelist parameter \np{ln\_zdfexp}=true) or a backward time stepping %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t] \begin{center} \includegraphics[width=1.00\textwidth]{./TexFiles/Figures/Fig_mixing_length.pdf} \includegraphics[width=1.00\textwidth]{Fig_mixing_length} \caption{ \label{Fig_mixing_length} Illustration of the mixing length computation. } At the ocean surface, a non zero length scale is set through the  \np{rn\_lmin0} namelist At the ocean surface, a non zero length scale is set through the  \np{rn\_mxl0} namelist parameter. Usually the surface scale is given by $l_o = \kappa \,z_o$ where $\kappa = 0.4$ is von Karman's constant and $z_o$ the roughness parameter of the surface. Assuming $z_o=0.1$~m \citep{Craig_Banner_JPO94} leads to a 0.04~m, the default value of \np{rn\_lsurf}. In the ocean interior leads to a 0.04~m, the default value of \np{rn\_mxl0}. In the ocean interior a minimum length scale is set to recover the molecular viscosity when $\bar{e}$ reach its minimum value ($1.10^{-6}= C_k\, l_{min} \,\sqrt{\bar{e}_{min}}$ ). As the surface boundary condition on TKE is prescribed through $\bar{e}_o = e_{bb} |\tau| / \rho_o$, with $e_{bb}$ the \np{rn\_ebb} namelist parameter, setting \np{rn\_ebb}~=~67.83 corresponds to $\alpha_{CB} = 100$. further setting  \np{ln\_lsurf} to true applies \eqref{ZDF_Lsbc} as surface boundary condition on length scale, with $\beta$ hard coded to the Stacet's value. to $\alpha_{CB} = 100$. Further setting  \np{ln\_mxl0} to true applies \eqref{ZDF_Lsbc} as surface boundary condition on length scale, with $\beta$ hard coded to the Stacey's value. Note that a minimal threshold of \np{rn\_emin0}$=10^{-4}~m^2.s^{-2}$ (namelist parameters) is applied on surface $\bar{e}$ value. %--------------------------------------------------------------% To be add here a description of "penetration of TKE" and the associated namelist parameters \np{nn\_etau}, \np{rn\_efr} and \np{nn\_htau}. Vertical mixing parameterizations commonly used in ocean general circulation models tend to produce mixed-layer depths that are too shallow during summer months and windy conditions. This bias is particularly acute over the Southern Ocean. To overcome this systematic bias, an ad hoc parameterization is introduced into the TKE scheme  \cite{Rodgers_2014}. The parameterization is an empirical one, $i.e.$ not derived from theoretical considerations, but rather is meant to account for observed processes that affect the density structure of the ocean’s planetary boundary layer that are not explicitly captured by default in the TKE scheme ($i.e.$ near-inertial oscillations and ocean swells and waves). When using this parameterization ($i.e.$ when \np{nn\_etau}~=~1), the TKE input to the ocean ($S$) imposed by the winds in the form of near-inertial oscillations, swell and waves is parameterized by \eqref{ZDF_Esbc} the standard TKE surface boundary condition, plus a depth depend one given by: \label{ZDF_Ehtau} S = (1-f_i) \; f_r \; e_s \; e^{-z / h_\tau} where $z$ is the depth, $e_s$ is TKE surface boundary condition, $f_r$ is the fraction of the surface TKE that penetrate in the ocean, $h_\tau$ is a vertical mixing length scale that controls exponential shape of the penetration, and $f_i$ is the ice concentration (no penetration if $f_i=1$, that is if the ocean is entirely covered by sea-ice). The value of $f_r$, usually a few percents, is specified through \np{rn\_efr} namelist parameter. The vertical mixing length scale, $h_\tau$, can be set as a 10~m uniform value (\np{nn\_etau}~=~0) or a latitude dependent value (varying from 0.5~m at the Equator to a maximum value of 30~m at high latitudes (\np{nn\_etau}~=~1). Note that two other option existe, \np{nn\_etau}~=~2, or 3. They correspond to applying \eqref{ZDF_Ehtau} only at the base of the mixed layer, or to using the high frequency part of the stress to evaluate the fraction of TKE that penetrate the ocean. Those two options are obsolescent features introduced for test purposes. They will be removed in the next release. % from Burchard et al OM 2008 : % the most critical process not reproduced by statistical turbulence models is the activity of internal waves and their interaction with turbulence. After the Reynolds decomposition, internal waves are in principle included in the RANS equations, but later partially excluded by the hydrostatic assumption and the model resolution. Thus far, the representation of internal wave mixing in ocean models has been relatively crude (e.g. Mellor, 1989; Large et al., 1994; Meier, 2001; Axell, 2002; St. Laurent and Garrett, 2002). % the most critical process not reproduced by statistical turbulence models is the activity of % internal waves and their interaction with turbulence. After the Reynolds decomposition, % internal waves are in principle included in the RANS equations, but later partially % excluded by the hydrostatic assumption and the model resolution. % Thus far, the representation of internal wave mixing in ocean models has been relatively crude % (e.g. Mellor, 1989; Large et al., 1994; Meier, 2001; Axell, 2002; St. Laurent and Garrett, 2002). %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]   \begin{center} \includegraphics[width=1.00\textwidth]{./TexFiles/Figures/Fig_ZDF_TKE_time_scheme.pdf} \includegraphics[width=1.00\textwidth]{Fig_ZDF_TKE_time_scheme} \caption{ \label{Fig_TKE_time_scheme} Illustration of the TKE time integration and its links to the momentum and tracer time integration. } value near physical boundaries (logarithmic boundary layer law). $C_{\mu}$ and $C_{\mu'}$ are calculated from stability function proposed by \citet{Galperin_al_JAS88}, or by \citet{Kantha_Clayson_1994} or one of the two functions suggested by \citet{Canuto_2001}  (\np{nn\_stab\_func} = 0, 1, 2 or 3, resp.}). or one of the two functions suggested by \citet{Canuto_2001}  (\np{nn\_stab\_func} = 0, 1, 2 or 3, resp.). The value of $C_{0\mu}$ depends of the choice of the stability function. Options are defined through the  \ngn{namzdf\_kpp} namelist variables. \colorbox{yellow}{Add a description of KPP here.} Note that KPP is an obsolescent feature of the \NEMO system. It will be removed in the next release (v3.7 and followings). %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!htb]    \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_npc.pdf} \includegraphics[width=0.90\textwidth]{Fig_npc} \caption{  \label{Fig_npc} Example of an unstable density profile treated by the non penetrative Options are defined through the  \ngn{namzdf} namelist variables. The non-penetrative convective adjustment is used when \np{ln\_zdfnpc}=true. The non-penetrative convective adjustment is used when \np{ln\_zdfnpc}~=~\textit{true}. It is applied at each \np{nn\_npc} time step and mixes downwards instantaneously the statically unstable portion of the water column, but only until the density (Fig. \ref{Fig_npc}): starting from the top of the ocean, the first instability is found. Assume in the following that the instability is located between levels $k$ and $k+1$. The potential temperature and salinity in the two levels are $k$ and $k+1$. The temperature and salinity in the two levels are vertically mixed, conserving the heat and salt contents of the water column. The new density is then computed by a linear approximation. If the new \citep{Madec_al_JPO91, Madec_al_DAO91, Madec_Crepon_Bk91}. Note that in the current implementation of this algorithm presents several limitations. First, potential density referenced to the sea surface is used to check whether the density profile is stable or not. This is a strong simplification which leads to large errors for realistic ocean simulations. Indeed, many water masses of the world ocean, especially Antarctic Bottom Water, are unstable when represented in surface-referenced potential density. The scheme will erroneously mix them up. Second, the mixing of potential density is assumed to be linear. This assures the convergence of the algorithm even when the equation of state is non-linear. Small static instabilities can thus persist due to cabbeling: they will be treated at the next time step. Third, temperature and salinity, and thus density, are mixed, but the corresponding velocity fields remain unchanged. When using a Richardson Number dependent eddy viscosity, the mixing of momentum is done through the vertical diffusion: after a static adjustment, the Richardson Number is zero and thus the eddy viscosity coefficient is at a maximum. When this convective adjustment algorithm is used with constant vertical eddy viscosity, spurious solutions can occur since the vertical momentum diffusion remains small even after a static adjustment. In that case, we recommend the addition of momentum mixing in a manner that mimics the mixing in temperature and salinity \citep{Speich_PhD92, Speich_al_JPO96}. The current implementation has been modified in order to deal with any non linear equation of seawater (L. Brodeau, personnal communication). Two main differences have been introduced compared to the original algorithm: $(i)$ the stability is now checked using the Brunt-V\"{a}is\"{a}l\"{a} frequency (not the the difference in potential density) ; $(ii)$ when two levels are found unstable, their thermal and haline expansion coefficients are vertically mixed in the same way their temperature and salinity has been mixed. These two modifications allow the algorithm to perform properly and accurately with TEOS10 or EOS-80 without having to recompute the expansion coefficients at each mixing iteration. % ------------------------------------------------------------------------------------------------------------- % ------------------------------------------------------------------------------------------------------------- \subsection   [Enhanced Vertical Diffusion (\np{ln\_zdfevd})] {Enhanced Vertical Diffusion (\np{ln\_zdfevd}=true)} {Enhanced Vertical Diffusion (\np{ln\_zdfevd}=true)} \label{ZDF_evd} %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]   \begin{center} \includegraphics[width=0.99\textwidth]{./TexFiles/Figures/Fig_zdfddm.pdf} \includegraphics[width=0.99\textwidth]{Fig_zdfddm} \caption{  \label{Fig_zdfddm} From \citet{Merryfield1999} : (a) Diapycnal diffusivities $A_f^{vT}$ % Bottom Friction % ================================================================ \section  [Bottom and top Friction (\textit{zdfbfr})]   {Bottom Friction (\mdl{zdfbfr} module)} \section  [Bottom and Top Friction (\textit{zdfbfr})]   {Bottom and Top Friction (\mdl{zdfbfr} module)} \label{ZDF_bfr} Options to define the top and bottom friction are defined through the  \ngn{nambfr} namelist variables. The top friction is activated only if the ice shelf cavities are opened (\np{ln\_isfcav}~=~true). As the friction processes at the top and bottom are the represented similarly, only the bottom friction is described in detail. The bottom friction represents the friction generated by the bathymetry. The top friction represents the friction generated by the ice shelf/ocean interface. As the friction processes at the top and bottom are represented similarly, only the bottom friction is described in detail below.\\ Both the surface momentum flux (wind stress) and the bottom momentum $H = 4000$~m, the resulting friction coefficient is $r = 4\;10^{-4}$~m\;s$^{-1}$. This is the default value used in \NEMO. It corresponds to a decay time scale of 115~days. It can be changed by specifying \np{rn\_bfric1} (namelist parameter). of 115~days. It can be changed by specifying \np{rn\_bfri1} (namelist parameter). For the linear friction case the coefficients defined in the general \end{split} When \np{nn\_botfr}=1, the value of $r$ used is \np{rn\_bfric1}. When \np{nn\_botfr}=1, the value of $r$ used is \np{rn\_bfri1}. Setting \np{nn\_botfr}=0 is equivalent to setting $r=0$ and leads to a free-slip bottom boundary condition. These values are assigned in \mdl{zdfbfr}. in the \ifile{bfr\_coef} input NetCDF file. The mask values should vary from 0 to 1. Locations with a non-zero mask value will have the friction coefficient increased by $mask\_value$*\np{rn\_bfrien}*\np{rn\_bfric1}. by $mask\_value$*\np{rn\_bfrien}*\np{rn\_bfri1}. % ------------------------------------------------------------------------------------------------------------- $e_b = 2.5\;10^{-3}$m$^2$\;s$^{-2}$, while the FRAM experiment \citep{Killworth1992} uses $C_D = 1.4\;10^{-3}$ and $e_b =2.5\;\;10^{-3}$m$^2$\;s$^{-2}$. The CME choices have been set as default values (\np{rn\_bfric2} and \np{rn\_bfeb2} The CME choices have been set as default values (\np{rn\_bfri2} and \np{rn\_bfeb2} namelist parameters). The coefficients that control the strength of the non-linear bottom friction are initialised as namelist parameters: $C_D$= \np{rn\_bfri2}, and $e_b$ =\np{rn\_bfeb2}. Note for applications which treat tides explicitly a low or even zero value of \np{rn\_bfeb2} is recommended. From v3.2 onwards a local enhancement of $C_D$ is possible via an externally defined 2D mask array (\np{ln\_bfr2d}=true). See previous section for details. The coefficients that control the strength of the non-linear bottom friction are initialised as namelist parameters: $C_D$= \np{rn\_bfri2}, and $e_b$ =\np{rn\_bfeb2}. Note for applications which treat tides explicitly a low or even zero value of \np{rn\_bfeb2} is recommended. From v3.2 onwards a local enhancement of $C_D$ is possible via an externally defined 2D mask array (\np{ln\_bfr2d}=true).  This works in the same way as for the linear bottom friction case with non-zero masked locations increased by $mask\_value$*\np{rn\_bfrien}*\np{rn\_bfri2}. % ------------------------------------------------------------------------------------------------------------- %       Bottom Friction Log-layer % ------------------------------------------------------------------------------------------------------------- \subsection{Log-layer Bottom Friction enhancement (\np{nn\_botfr} = 2, \np{ln\_loglayer} = .true.)} \label{ZDF_bfr_loglayer} In the non-linear bottom friction case, the drag coefficient, $C_D$, can be optionally enhanced using a "law of the wall" scaling. If  \np{ln\_loglayer} = .true., $C_D$ is no longer constant but is related to the thickness of the last wet layer in each column by: C_D = \left ( {\kappa \over {\rm log}\left ( 0.5e_{3t}/rn\_bfrz0 \right ) } \right )^2 \noindent where $\kappa$ is the von-Karman constant and \np{rn\_bfrz0} is a roughness length provided via the namelist. For stability, the drag coefficient is bounded such that it is kept greater or equal to the base \np{rn\_bfri2} value and it is not allowed to exceed the value of an additional namelist parameter: \np{rn\_bfri2\_max}, i.e.: rn\_bfri2 \leq C_D \leq rn\_bfri2\_max \noindent Note also that a log-layer enhancement can also be applied to the top boundary friction if under ice-shelf cavities are in use (\np{ln\_isfcav}=.true.).  In this case, the relevant namelist parameters are \np{rn\_tfrz0}, \np{rn\_tfri2} and \np{rn\_tfri2\_max}. % ------------------------------------------------------------------------------------------------------------- baroclinic and barotropic components which is appropriate when using either the explicit or filtered surface pressure gradient algorithms (\key{dynspg\_exp} or {\key{dynspg\_flt}). Extra attention is required, however, when using \key{dynspg\_flt}). Extra attention is required, however, when using split-explicit time stepping (\key{dynspg\_ts}). In this case the free surface equation is solved with a small time step \np{rn\_rdt}/\np{nn\_baro}, while the three %>>>>>>>>>>>>>>>>>>>>>>>>>>>> \begin{figure}[!t]   \begin{center} \includegraphics[width=0.90\textwidth]{./TexFiles/Figures/Fig_ZDF_M2_K1_tmx.pdf} \includegraphics[width=0.90\textwidth]{Fig_ZDF_M2_K1_tmx} \caption{  \label{Fig_ZDF_M2_K1_tmx} (a) M2 and (b) K1 internal wave drag energy from \citet{Carrere_Lyard_GRL03} ($W/m^2$). } % ================================================================ % Internal wave-driven mixing % ================================================================ \section{Internal wave-driven mixing (\key{zdftmx\_new})} \label{ZDF_tmx_new} %--------------------------------------------namzdf_tmx_new------------------------------------------ \namdisplay{namzdf_tmx_new} %-------------------------------------------------------------------------------------------------------------- The parameterization of mixing induced by breaking internal waves is a generalization of the approach originally proposed by \citet{St_Laurent_al_GRL02}. A three-dimensional field of internal wave energy dissipation $\epsilon(x,y,z)$ is first constructed, and the resulting diffusivity is obtained as \label{Eq_Kwave} A^{vT}_{wave} =  R_f \,\frac{ \epsilon }{ \rho \, N^2 } where $R_f$ is the mixing efficiency and $\epsilon$ is a specified three dimensional distribution of the energy available for mixing. If the \np{ln\_mevar} namelist parameter is set to false, the mixing efficiency is taken as constant and equal to 1/6 \citep{Osborn_JPO80}. In the opposite (recommended) case, $R_f$ is instead a function of the turbulence intensity parameter $Re_b = \frac{ \epsilon}{\nu \, N^2}$, with $\nu$ the molecular viscosity of seawater, following the model of \cite{Bouffard_Boegman_DAO2013} and the implementation of \cite{de_lavergne_JPO2016_efficiency}. Note that $A^{vT}_{wave}$ is bounded by $10^{-2}\,m^2/s$, a limit that is often reached when the mixing efficiency is constant. In addition to the mixing efficiency, the ratio of salt to heat diffusivities can chosen to vary as a function of $Re_b$ by setting the \np{ln\_tsdiff} parameter to true, a recommended choice). This parameterization of differential mixing, due to \cite{Jackson_Rehmann_JPO2014}, is implemented as in \cite{de_lavergne_JPO2016_efficiency}. The three-dimensional distribution of the energy available for mixing, $\epsilon(i,j,k)$, is constructed from three static maps of column-integrated internal wave energy dissipation, $E_{cri}(i,j)$, $E_{pyc}(i,j)$, and $E_{bot}(i,j)$, combined to three corresponding vertical structures (de Lavergne et al., in prep): \begin{align*} F_{cri}(i,j,k) &\propto e^{-h_{ab} / h_{cri} }\\ F_{pyc}(i,j,k) &\propto N^{n\_p}\\ F_{bot}(i,j,k) &\propto N^2 \, e^{- h_{wkb} / h_{bot} } \end{align*} In the above formula, $h_{ab}$ denotes the height above bottom, $h_{wkb}$ denotes the WKB-stretched height above bottom, defined by \begin{equation*} h_{wkb} = H \, \frac{ \int_{-H}^{z} N \, dz' } { \int_{-H}^{\eta} N \, dz'  } \; , \end{equation*} The $n_p$ parameter (given by \np{nn\_zpyc} in \ngn{namzdf\_tmx\_new} namelist)  controls the stratification-dependence of the pycnocline-intensified dissipation. It can take values of 1 (recommended) or 2. Finally, the vertical structures $F_{cri}$ and $F_{bot}$ require the specification of the decay scales $h_{cri}(i,j)$ and $h_{bot}(i,j)$, which are defined by two additional input maps. $h_{cri}$ is related to the large-scale topography of the ocean (etopo2) and $h_{bot}$ is a function of the energy flux $E_{bot}$, the characteristic horizontal scale of the abyssal hill topography \citep{Goff_JGR2010} and the latitude. % ================================================================ \end{document}
• ## branches/2015/dev_r5003_MERCATOR6_CRS/DOC/TexFiles/Chapters/Introduction.tex

 r4661 \documentclass[NEMO_book]{subfiles} \begin{document} % ================================================================ release 8.2, described in \citet{Madec1998}. This model has been used for a wide range of applications, both regional or global, as a forced ocean model and as a model coupled with the atmosphere. A complete list of references is found on the \NEMO web site. model coupled with the sea-ice and/or the atmosphere. This manual is organised in as follows. Chapter~\ref{PE} presents the model basics, $i.e.$ the equations and their assumptions, the vertical coordinates used, and the subgrid scale physics. This part deals with the continuous equations of the model (primitive equations, with potential temperature, salinity and an equation of state). (primitive equations, with temperature, salinity and an equation of seawater). The equations are written in a curvilinear coordinate system, with a choice of vertical coordinates ($z$ or $s$, with the rescaled height coordinate formulation \textit{z*}, or space and time variable coefficient \citet{Treguier1997}. The model has vertical harmonic viscosity and diffusion with a space and time variable coefficient, with options to compute the coefficients with \citet{Blanke1993}, \citet{Large_al_RG94}, \citet{Pacanowski_Philander_JPO81}, the coefficients with \citet{Blanke1993}, \citet{Pacanowski_Philander_JPO81}, or \citet{Umlauf_Burchard_JMS03} mixing schemes. \vspace{1cm} %%gm    To be put somewhere else .... \noindent CPP keys and namelists are used for inputs to the code.  \newline \vspace{1cm} %%gm  end Model outputs management and specific online diagnostics are described in chapters~\ref{DIA}. \item a deep re-writting and simplification of the off-line tracer component (OFF\_SRC) ; \item the merge of passive and active advection and diffusion modules ; \item  Use of the Flexible Configuration Manager (FCM) to build configurations, generate the Makefile and produce the executable ; \item Use of the Flexible Configuration Manager (FCM) to build configurations, generate the Makefile and produce the executable ; \item Linear-tangent and Adjoint component (TAM) added, phased with v3.0 \end{enumerate} \vspace{1cm} $\bullet$ The main modifications from NEMO/OPA v3.4 and  v3.6 are :\\ \begin{enumerate} \item I/O management: NEMO in now interfaced with XIOS, a Input/Output server having a versatile xml user interface, and allowing I/O to be performed on dedicated processors thus improving scalability and performance on massively parallel platforms. \item ICB module \citep{Marsh_GMD2015}: icebergs as lagrangian floats ; \item SAS: Stand Alone Surface module allowing testing of forcing set with bulk formulae, to run sea-ice models without ocean, to run ICB icebergs module alone, and to test AGRIF with sea-ice \item ISF : Under ice-selves cavities (parametrisation and/or explicit representation) \item Coupled interface for next IPCC requirements (multi category sea-ice, calving and iceberg module) \item Ocean and ice allowed to be explicitly coupled through OASIS, using StandAlone Surface module) \item On line coarsening of ocean I/O \item Major evolution of LIM3 sea-ice model \citep{Rousset_GMD2015} \item Open boundaries: completion of BDY/OBC merge : BDY is now the only Open boundary module available \item re-visit of the specification of heat/salt(tracers)/mass fluxes ; \item levitating or fully embedded sea-ice (for LIM and CICE) ; \item a new parameterization of mixing induced by breaking internal waves (de Lavergne et al. in prep.) And also: \item update of AGRIF package and AGRIF compatibility with LIM2 sea-ice model ; \item A new vertical sigma coordinate stretching function \citep{Siddorn_Furner_OM12} ; \item Smagorinsky eddy coefficients: the \cite{Griffies_Hallberg_MWR00} Smagorinsky type diffusivity/viscosity for lateral mixing has been introduced ; \item Standard Fox Kemper parametrisation \item Analytical tropical cyclones taken in account using track and magnitude observations (Vincent et al. JGR 2012a,b) ; \item OBS: observation operators improved and now available in Standalone mode ; \item Log layer option for bottom friction \item Faster split-explicit time stepping ; \item Z-tilde ALE coordinates \citep{Leclair_Madec_OM11} ; \item implicit bottom friction ; \item Runoff improved and SBC with BGC \item MPP assessment and optimisation \item First steps of wave coupling Features becoming obsolete: LIM2 (replaced by LIM3 monocategory) ; IOIPSL (replaced by XIOS) ; Features that has been removed : LOBSTER (now included in PISCES) ; OBC, replaced by BDY ; \end{enumerate} \end{document}
Note: See TracChangeset for help on using the changeset viewer.