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 7351 for branches/2016/dev_INGV_UKMO_2016/DOC/TexFiles/Chapters/Chap_TRA.tex – NEMO

Ignore:
Timestamp:
2016-11-28T17:04:10+01:00 (7 years ago)
Author:
emanuelaclementi
Message:

ticket #1805 step 3: /2016/dev_INGV_UKMO_2016 aligned to the trunk at revision 7161

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2016/dev_INGV_UKMO_2016/DOC/TexFiles/Chapters/Chap_TRA.tex

    r5102 r7351  
    1 % ================================================================ 
    2 % Chapter 1 � Ocean Tracers (TRA) 
     1\documentclass[NEMO_book]{subfiles} 
     2\begin{document} 
     3% ================================================================ 
     4% Chapter 1 ——— Ocean Tracers (TRA) 
    35% ================================================================ 
    46\chapter{Ocean Tracers (TRA)} 
     
    3638(BBL) parametrisation, and an internal damping (DMP) term. The terms QSR,  
    3739BBC, BBL and DMP are optional. The external forcings and parameterisations  
    38 require complex inputs and complex calculations (e.g. bulk formulae, estimation  
     40require complex inputs and complex calculations ($e.g.$ bulk formulae, estimation  
    3941of mixing coefficients) that are carried out in the SBC, LDF and ZDF modules and  
    4042described in chapters \S\ref{SBC}, \S\ref{LDF} and  \S\ref{ZDF}, respectively.  
    41 Note that \mdl{tranpc}, the non-penetrative convection module,  although  
    42 (temporarily) located in the NEMO/OPA/TRA directory, is described with the  
    43 model vertical physics (ZDF). 
    44 %%% 
    45 \gmcomment{change the position of eosbn2 in the reference code} 
    46 %%% 
     43Note that \mdl{tranpc}, the non-penetrative convection module, although  
     44located in the NEMO/OPA/TRA directory as it directly modifies the tracer fields,  
     45is described with the model vertical physics (ZDF) together with other available  
     46parameterization of convection. 
    4747 
    4848In the present chapter we also describe the diagnostic equations used to compute  
    49 the sea-water properties (density, Brunt-Vais\"{a}l\"{a} frequency, specific heat and  
     49the sea-water properties (density, Brunt-V\"{a}is\"{a}l\"{a} frequency, specific heat and  
    5050freezing point with associated modules \mdl{eosbn2} and \mdl{phycst}). 
    5151 
    52 The different options available to the user are managed by namelist logicals or  
    53 CPP keys. For each equation term \textit{ttt}, the namelist logicals are \textit{ln\_trattt\_xxx},  
     52The different options available to the user are managed by namelist logicals or CPP keys.  
     53For each equation term  \textit{TTT}, the namelist logicals are \textit{ln\_traTTT\_xxx},  
    5454where \textit{xxx} is a 3 or 4 letter acronym corresponding to each optional scheme.  
    55 The CPP key (when it exists) is \textbf{key\_trattt}. The equivalent code can be  
    56 found in the \textit{trattt} or \textit{trattt\_xxx} module, in the NEMO/OPA/TRA directory. 
    57  
    58 The user has the option of extracting each tendency term on the rhs of the tracer  
    59 equation for output (\key{trdtra} is defined), as described in Chap.~\ref{MISC}. 
     55The CPP key (when it exists) is \textbf{key\_traTTT}. The equivalent code can be  
     56found in the \textit{traTTT} or \textit{traTTT\_xxx} module, in the NEMO/OPA/TRA directory. 
     57 
     58The user has the option of extracting each tendency term on the RHS of the tracer  
     59equation for output (\np{ln\_tra\_trd} or \np{ln\_tra\_mxl}~=~true), as described in Chap.~\ref{DIA}. 
    6060 
    6161$\ $\newline    % force a new ligne 
     
    7070%------------------------------------------------------------------------------------------------------------- 
    7171 
    72 The advection tendency of a tracer in flux form is the divergence of the advective  
    73 fluxes. Its discrete expression is given by : 
     72When considered ($i.e.$ when \np{ln\_traadv\_NONE} is not set to \textit{true}),  
     73the advection tendency of a tracer is expressed in flux form,  
     74$i.e.$ as the divergence of the advective fluxes. Its discrete expression is given by : 
    7475\begin{equation} \label{Eq_tra_adv} 
    7576ADV_\tau =-\frac{1}{b_t} \left(  
     
    8283implicitly requires the use of the continuity equation. Indeed, it is obtained 
    8384by using the following equality : $\nabla \cdot \left( \vect{U}\,T \right)=\vect{U} \cdot \nabla T$  
    84 which results from the use of the continuity equation, $\nabla \cdot \vect{U}=0$ or  
    85 $ \partial _t e_3 + e_3\;\nabla \cdot \vect{U}=0$ in constant volume or variable volume case, respectively.  
     85which results from the use of the continuity equation,  $\partial _t e_3 + e_3\;\nabla \cdot \vect{U}=0$  
     86(which reduces to $\nabla \cdot \vect{U}=0$ in linear free surface, $i.e.$ \np{ln\_linssh}=true).  
    8687Therefore it is of paramount importance to design the discrete analogue of the  
    8788advection tendency so that it is consistent with the continuity equation in order to  
    8889enforce the conservation properties of the continuous equations. In other words,  
    89 by replacing $\tau$ by the number 1 in (\ref{Eq_tra_adv}) we recover the discrete form of  
     90by setting $\tau = 1$ in (\ref{Eq_tra_adv}) we recover the discrete form of  
    9091the continuity equation which is used to calculate the vertical velocity. 
    9192%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    9293\begin{figure}[!t]    \begin{center} 
    93 \includegraphics[width=0.9\textwidth]{./TexFiles/Figures/Fig_adv_scheme.pdf} 
     94\includegraphics[width=0.9\textwidth]{Fig_adv_scheme} 
    9495\caption{   \label{Fig_adv_scheme}  
    9596Schematic representation of some ways used to evaluate the tracer value  
     
    113114boundary condition depends on the type of sea surface chosen:  
    114115\begin{description} 
    115 \item [linear free surface:] the first level thickness is constant in time:  
     116\item [linear free surface:] (\np{ln\_linssh}=true) the first level thickness is constant in time:  
    116117the vertical boundary condition is applied at the fixed surface $z=0$  
    117118rather than on the moving surface $z=\eta$. There is a non-zero advective  
     
    119120$\left. {\tau _w } \right|_{k=1/2} =T_{k=1} $, $i.e.$  
    120121the product of surface velocity (at $z=0$) by the first level tracer value. 
    121 \item [non-linear free surface:] (\key{vvl} is defined)  
     122\item [non-linear free surface:] (\np{ln\_linssh}=false)  
    122123convergence/divergence in the first ocean level moves the free surface  
    123124up/down. There is no tracer advection through it so that the advective  
     
    125126\end{description} 
    126127In all cases, this boundary condition retains local conservation of tracer.  
    127 Global conservation is obtained in both rigid-lid and non-linear free surface  
    128 cases, but not in the linear free surface case. Nevertheless, in the latter 
    129 case, it is achieved to a good approximation since the non-conservative  
     128Global conservation is obtained in non-linear free surface case,  
     129but \textit{not} in the linear free surface case. Nevertheless, in the latter case,  
     130it is achieved to a good approximation since the non-conservative  
    130131term is the product of the time derivative of the tracer and the free surface  
    131 height, two quantities that are not correlated (see \S\ref{PE_free_surface},  
    132 and also \citet{Roullet_Madec_JGR00,Griffies_al_MWR01,Campin2004}). 
     132height, two quantities that are not correlated \citep{Roullet_Madec_JGR00,Griffies_al_MWR01,Campin2004}. 
    133133 
    134134The velocity field that appears in (\ref{Eq_tra_adv}) and (\ref{Eq_tra_adv_zco})  
    135 is the centred (\textit{now}) \textit{eulerian} ocean velocity (see Chap.~\ref{DYN}).  
    136 When eddy induced velocity (\textit{eiv}) parameterisation is used it is the \textit{now}  
    137 \textit{effective} velocity ($i.e.$ the sum of the eulerian and eiv velocities) which is used. 
    138  
    139 The choice of an advection scheme is made in the \textit{\ngn{nam\_traadv}} namelist, by  
    140 setting to \textit{true} one and only one of the logicals \textit{ln\_traadv\_xxx}. The  
    141 corresponding code can be found in the \textit{traadv\_xxx.F90} module, where  
    142 \textit{xxx} is a 3 or 4 letter acronym corresponding to each scheme. Details  
    143 of the advection schemes are given below. The choice of an advection scheme  
     135is the centred (\textit{now}) \textit{effective} ocean velocity, $i.e.$ the \textit{eulerian} velocity 
     136(see Chap.~\ref{DYN}) plus the eddy induced velocity (\textit{eiv})  
     137and/or the mixed layer eddy induced velocity (\textit{eiv}) 
     138when those parameterisations are used (see Chap.~\ref{LDF}). 
     139 
     140Several tracer advection scheme are proposed, namely  
     141a $2^{nd}$ or $4^{th}$ order centred schemes (CEN),  
     142a $2^{nd}$ or $4^{th}$ order Flux Corrected Transport scheme (FCT), 
     143a Monotone Upstream Scheme for Conservative Laws scheme (MUSCL), 
     144a $3^{rd}$ Upstream Biased Scheme (UBS, also often called UP3), and 
     145a Quadratic Upstream Interpolation for Convective Kinematics with  
     146Estimated Streaming Terms scheme (QUICKEST). 
     147The choice is made in the \textit{\ngn{namtra\_adv}} namelist, by  
     148setting to \textit{true} one of the logicals \textit{ln\_traadv\_xxx}.  
     149The corresponding code can be found in the \textit{traadv\_xxx.F90} module,  
     150where \textit{xxx} is a 3 or 4 letter acronym corresponding to each scheme.  
     151By default ($i.e.$ in the reference namelist, \ngn{namelist\_ref}), all the logicals  
     152are set to \textit{false}. If the user does not select an advection scheme  
     153in the configuration namelist (\ngn{namelist\_cfg}), the tracers will \textit{not} be advected ! 
     154 
     155Details of the advection schemes are given below. The choosing an advection scheme  
    144156is a complex matter which depends on the model physics, model resolution,  
    145 type of tracer, as well as the issue of numerical cost.  
    146  
    147 Note that  
    148 (1) cen2, cen4 and TVD schemes require an explicit diffusion  
    149 operator while the other schemes are diffusive enough so that they do not  
    150 require additional diffusion ;  
    151 (2) cen2, cen4, MUSCL2, and UBS are not \textit{positive} schemes 
     157type of tracer, as well as the issue of numerical cost. In particular, we note that 
     158(1) CEN and FCT schemes require an explicit diffusion operator  
     159while the other schemes are diffusive enough so that they do not necessarily need additional diffusion ;  
     160(2) CEN and UBS are not \textit{positive} schemes 
    152161\footnote{negative values can appear in an initially strictly positive tracer field  
    153162which is advected} 
     
    163172 
    164173% ------------------------------------------------------------------------------------------------------------- 
     174%        2nd and 4th order centred schemes 
     175% ------------------------------------------------------------------------------------------------------------- 
     176\subsection [Centred schemes (CEN) (\np{ln\_traadv\_cen})] 
     177            {Centred schemes (CEN) (\np{ln\_traadv\_cen}=true)} 
     178\label{TRA_adv_cen} 
     179 
    165180%        2nd order centred scheme   
    166 % ------------------------------------------------------------------------------------------------------------- 
    167 \subsection   [$2^{nd}$ order centred scheme (cen2) (\np{ln\_traadv\_cen2})] 
    168          {$2^{nd}$ order centred scheme (cen2) (\np{ln\_traadv\_cen2}=true)} 
    169 \label{TRA_adv_cen2} 
    170  
    171 In the centred second order formulation, the tracer at velocity points is  
    172 evaluated as the mean of the two neighbouring $T$-point values.  
     181 
     182The centred advection scheme (CEN) is used when \np{ln\_traadv\_cen}~=~\textit{true}.  
     183Its order ($2^{nd}$ or $4^{th}$) can be chosen independently on horizontal (iso-level)  
     184and vertical direction by setting \np{nn\_cen\_h} and \np{nn\_cen\_v} to $2$ or $4$.  
     185CEN implementation can be found in the \mdl{traadv\_cen} module. 
     186 
     187In the $2^{nd}$ order centred formulation (CEN2), the tracer at velocity points  
     188is evaluated as the mean of the two neighbouring $T$-point values.  
    173189For example, in the $i$-direction : 
    174190\begin{equation} \label{Eq_tra_adv_cen2} 
     
    176192\end{equation} 
    177193 
    178 The scheme is non diffusive ($i.e.$ it conserves the tracer variance, $\tau^2)$  
     194CEN2 is non diffusive ($i.e.$ it conserves the tracer variance, $\tau^2)$  
    179195but dispersive ($i.e.$ it may create false extrema). It is therefore notoriously  
    180196noisy and must be used in conjunction with an explicit diffusion operator to  
    181197produce a sensible solution. The associated time-stepping is performed using  
    182198a leapfrog scheme in conjunction with an Asselin time-filter, so $T$ in  
    183 (\ref{Eq_tra_adv_cen2}) is the \textit{now} tracer value. The centered second  
    184 order advection is computed in the \mdl{traadv\_cen2} module. In this module, 
    185 it is advantageous to combine the \textit{cen2} scheme with an upstream scheme 
    186 in specific areas which require a strong diffusion in order to avoid the generation  
    187 of false extrema. These areas are the vicinity of large river mouths, some straits  
    188 with coarse resolution, and the vicinity of ice cover area ($i.e.$ when the ocean  
    189 temperature is close to the freezing point). 
    190 This combined scheme has been included for specific grid points in the ORCA2  
    191 and ORCA4 configurations only. This is an obsolescent feature as the recommended  
    192 advection scheme for the ORCA configuration is TVD (see  \S\ref{TRA_adv_tvd}). 
    193  
    194 Note that using the cen2 scheme, the overall tracer advection is of second  
     199(\ref{Eq_tra_adv_cen2}) is the \textit{now} tracer value.  
     200 
     201Note that using the CEN2, the overall tracer advection is of second  
    195202order accuracy since both (\ref{Eq_tra_adv}) and (\ref{Eq_tra_adv_cen2})  
    196 have this order of accuracy. \gmcomment{Note also that ... blah, blah} 
    197  
    198 % ------------------------------------------------------------------------------------------------------------- 
     203have this order of accuracy. 
     204 
    199205%        4nd order centred scheme   
    200 % ------------------------------------------------------------------------------------------------------------- 
    201 \subsection   [$4^{nd}$ order centred scheme (cen4) (\np{ln\_traadv\_cen4})] 
    202            {$4^{nd}$ order centred scheme (cen4) (\np{ln\_traadv\_cen4}=true)} 
    203 \label{TRA_adv_cen4} 
    204  
    205 In the $4^{th}$ order formulation (to be implemented), tracer values are  
    206 evaluated at velocity points as a $4^{th}$ order interpolation, and thus depend on  
    207 the four neighbouring $T$-points. For example, in the $i$-direction: 
     206 
     207In the $4^{th}$ order formulation (CEN4), tracer values are evaluated at u- and v-points as  
     208a $4^{th}$ order interpolation, and thus depend on the four neighbouring $T$-points.  
     209For example, in the $i$-direction: 
    208210\begin{equation} \label{Eq_tra_adv_cen4} 
    209211\tau _u^{cen4}  
    210212=\overline{   T - \frac{1}{6}\,\delta _i \left[ \delta_{i+1/2}[T] \,\right]   }^{\,i+1/2} 
    211213\end{equation} 
    212  
    213 Strictly speaking, the cen4 scheme is not a $4^{th}$ order advection scheme  
     214In the vertical direction (\np{nn\_cen\_v}=$4$), a $4^{th}$ COMPACT interpolation  
     215has been prefered \citep{Demange_PhD2014}. 
     216In the COMPACT scheme, both the field and its derivative are interpolated,  
     217which leads, after a matrix inversion, spectral characteristics  
     218similar to schemes of higher order \citep{Lele_JCP1992}. 
     219  
     220 
     221Strictly speaking, the CEN4 scheme is not a $4^{th}$ order advection scheme  
    214222but a $4^{th}$ order evaluation of advective fluxes, since the divergence of  
    215 advective fluxes \eqref{Eq_tra_adv} is kept at $2^{nd}$ order. The phrase ``$4^{th}$  
    216 order scheme'' used in oceanographic literature is usually associated  
    217 with the scheme presented here. Introducing a \textit{true} $4^{th}$ order advection  
    218 scheme is feasible but, for consistency reasons, it requires changes in the  
    219 discretisation of the tracer advection together with changes in both the  
    220 continuity equation and the momentum advection terms.   
     223advective fluxes \eqref{Eq_tra_adv} is kept at $2^{nd}$ order.  
     224The expression \textit{$4^{th}$ order scheme} used in oceanographic literature  
     225is usually associated with the scheme presented here.  
     226Introducing a \textit{true} $4^{th}$ order advection scheme is feasible but,  
     227for consistency reasons, it requires changes in the discretisation of the tracer  
     228advection together with changes in the continuity equation,  
     229and the momentum advection and pressure terms.   
    221230 
    222231A direct consequence of the pseudo-fourth order nature of the scheme is that  
    223 it is not non-diffusive, i.e. the global variance of a tracer is not preserved using  
    224 \textit{cen4}. Furthermore, it must be used in conjunction with an explicit  
    225 diffusion operator to produce a sensible solution. The time-stepping is also  
    226 performed using a leapfrog scheme in conjunction with an Asselin time-filter,  
    227 so $T$ in (\ref{Eq_tra_adv_cen4}) is the \textit{now} tracer. 
    228  
    229 At a $T$-grid cell adjacent to a boundary (coastline, bottom and surface), an  
    230 additional hypothesis must be made to evaluate $\tau _u^{cen4}$. This  
    231 hypothesis usually reduces the order of the scheme. Here we choose to set  
    232 the gradient of $T$ across the boundary to zero. Alternative conditions can be  
    233 specified, such as a reduction to a second order scheme for these near boundary  
    234 grid points. 
    235  
    236 % ------------------------------------------------------------------------------------------------------------- 
    237 %        TVD scheme   
    238 % ------------------------------------------------------------------------------------------------------------- 
    239 \subsection   [Total Variance Dissipation scheme (TVD) (\np{ln\_traadv\_tvd})] 
    240          {Total Variance Dissipation scheme (TVD) (\np{ln\_traadv\_tvd}=true)} 
     232it is not non-diffusive, $i.e.$ the global variance of a tracer is not preserved using CEN4.  
     233Furthermore, it must be used in conjunction with an explicit diffusion operator  
     234to produce a sensible solution.  
     235As in CEN2 case, the time-stepping is performed using a leapfrog scheme in conjunction  
     236with an Asselin time-filter, so $T$ in (\ref{Eq_tra_adv_cen4}) is the \textit{now} tracer. 
     237 
     238At a $T$-grid cell adjacent to a boundary (coastline, bottom and surface),  
     239an additional hypothesis must be made to evaluate $\tau _u^{cen4}$.  
     240This hypothesis usually reduces the order of the scheme.  
     241Here we choose to set the gradient of $T$ across the boundary to zero.  
     242Alternative conditions can be specified, such as a reduction to a second order scheme  
     243for these near boundary grid points. 
     244 
     245% ------------------------------------------------------------------------------------------------------------- 
     246%        FCT scheme   
     247% ------------------------------------------------------------------------------------------------------------- 
     248\subsection   [Flux Corrected Transport schemes (FCT) (\np{ln\_traadv\_fct})] 
     249         {Flux Corrected Transport schemes (FCT) (\np{ln\_traadv\_fct}=true)} 
    241250\label{TRA_adv_tvd} 
    242251 
    243 In the Total Variance Dissipation (TVD) formulation, the tracer at velocity  
    244 points is evaluated using a combination of an upstream and a centred scheme.  
    245 For example, in the $i$-direction : 
    246 \begin{equation} \label{Eq_tra_adv_tvd} 
     252The Flux Corrected Transport schemes (FCT) is used when \np{ln\_traadv\_fct}~=~\textit{true}.  
     253Its order ($2^{nd}$ or $4^{th}$) can be chosen independently on horizontal (iso-level)  
     254and vertical direction by setting \np{nn\_fct\_h} and \np{nn\_fct\_v} to $2$ or $4$. 
     255FCT implementation can be found in the \mdl{traadv\_fct} module. 
     256 
     257In FCT formulation, the tracer at velocity points is evaluated using a combination of  
     258an upstream and a centred scheme. For example, in the $i$-direction : 
     259\begin{equation} \label{Eq_tra_adv_fct} 
    247260\begin{split} 
    248261\tau _u^{ups}&= \begin{cases} 
     
    251264              \end{cases}     \\ 
    252265\\ 
    253 \tau _u^{tvd}&=\tau _u^{ups} +c_u \;\left( {\tau _u^{cen2} -\tau _u^{ups} } \right) 
     266\tau _u^{fct}&=\tau _u^{ups} +c_u \;\left( {\tau _u^{cen} -\tau _u^{ups} } \right) 
    254267\end{split} 
    255268\end{equation} 
    256269where $c_u$ is a flux limiter function taking values between 0 and 1.  
     270The FCT order is the one of the centred scheme used ($i.e.$ it depends on the setting of 
     271\np{nn\_fct\_h} and \np{nn\_fct\_v}. 
    257272There exist many ways to define $c_u$, each corresponding to a different  
    258 total variance decreasing scheme. The one chosen in \NEMO is described in  
    259 \citet{Zalesak_JCP79}. $c_u$ only departs from $1$ when the advective term  
    260 produces a local extremum in the tracer field. The resulting scheme is quite  
    261 expensive but \emph{positive}. It can be used on both active and passive tracers.  
    262 This scheme is tested and compared with MUSCL and the MPDATA scheme in  
    263 \citet{Levy_al_GRL01}; note that in this paper it is referred to as "FCT" (Flux corrected  
    264 transport) rather than TVD. The TVD scheme is implemented in the \mdl{traadv\_tvd} module. 
    265  
    266 For stability reasons (see \S\ref{STP}), 
    267 $\tau _u^{cen2}$ is evaluated  in (\ref{Eq_tra_adv_tvd}) using the \textit{now} tracer while $\tau _u^{ups}$  
    268 is evaluated using the \textit{before} tracer. In other words, the advective part of  
    269 the scheme is time stepped with a leap-frog scheme while a forward scheme is  
    270 used for the diffusive part.  
     273FCT scheme. The one chosen in \NEMO is described in \citet{Zalesak_JCP79}.  
     274$c_u$ only departs from $1$ when the advective term produces a local extremum in the tracer field.  
     275The resulting scheme is quite expensive but \emph{positive}.  
     276It can be used on both active and passive tracers.  
     277A comparison of FCT-2 with MUSCL and a MPDATA scheme can be found in \citet{Levy_al_GRL01}.  
     278 
     279An additional option has been added controlled by \np{nn\_fct\_zts}. By setting this integer to  
     280a value larger than zero, a $2^{nd}$ order FCT scheme is used on both horizontal and vertical direction,  
     281but on the latter, a split-explicit time stepping is used, with a number of sub-timestep equals 
     282to \np{nn\_fct\_zts}. This option can be useful when the size of the timestep is limited  
     283by vertical advection \citep{Lemarie_OM2015}. Note that in this case, a similar split-explicit  
     284time stepping should be used on vertical advection of momentum to insure a better stability 
     285(see \S\ref{DYN_zad}). 
     286 
     287For stability reasons (see \S\ref{STP}), $\tau _u^{cen}$ is evaluated in (\ref{Eq_tra_adv_fct})  
     288using the \textit{now} tracer while $\tau _u^{ups}$ is evaluated using the \textit{before} tracer. In other words,  
     289the advective part of the scheme is time stepped with a leap-frog scheme  
     290while a forward scheme is used for the diffusive part.  
    271291 
    272292% ------------------------------------------------------------------------------------------------------------- 
    273293%        MUSCL scheme   
    274294% ------------------------------------------------------------------------------------------------------------- 
    275 \subsection[MUSCL scheme  (\np{ln\_traadv\_muscl})] 
    276    {Monotone Upstream Scheme for Conservative Laws (MUSCL) (\np{ln\_traadv\_muscl}=T)} 
    277 \label{TRA_adv_muscl} 
    278  
    279 The Monotone Upstream Scheme for Conservative Laws (MUSCL) has been  
    280 implemented by \citet{Levy_al_GRL01}. In its formulation, the tracer at velocity points  
     295\subsection[MUSCL scheme  (\np{ln\_traadv\_mus})] 
     296   {Monotone Upstream Scheme for Conservative Laws (MUSCL) (\np{ln\_traadv\_mus}=T)} 
     297\label{TRA_adv_mus} 
     298 
     299The Monotone Upstream Scheme for Conservative Laws (MUSCL) is used when \np{ln\_traadv\_mus}~=~\textit{true}.  
     300MUSCL implementation can be found in the \mdl{traadv\_mus} module. 
     301 
     302MUSCL has been first implemented in \NEMO by \citet{Levy_al_GRL01}. In its formulation, the tracer at velocity points  
    281303is evaluated assuming a linear tracer variation between two $T$-points  
    282304(Fig.\ref{Fig_adv_scheme}). For example, in the $i$-direction : 
    283 \begin{equation} \label{Eq_tra_adv_muscl} 
     305\begin{equation} \label{Eq_tra_adv_mus} 
    284306   \tau _u^{mus} = \left\{      \begin{aligned} 
    285307         &\tau _i  &+ \frac{1}{2} \;\left( 1-\frac{u_{i+1/2} \;\rdt}{e_{1u}} \right) 
     
    296318 
    297319For an ocean grid point adjacent to land and where the ocean velocity is  
    298 directed toward land, two choices are available: an upstream flux  
    299 (\np{ln\_traadv\_muscl}=true) or a second order flux  
    300 (\np{ln\_traadv\_muscl2}=true). Note that the latter choice does not ensure  
    301 the \textit{positive} character of the scheme. Only the former can be used  
    302 on both active and passive tracers. The two MUSCL schemes are implemented  
    303 in the \mdl{traadv\_tvd} and \mdl{traadv\_tvd2} modules. 
     320directed toward land, an upstream flux is used. This choice ensure  
     321the \textit{positive} character of the scheme.  
     322In addition, fluxes round a grid-point where a runoff is applied can optionally be  
     323computed using upstream fluxes (\np{ln\_mus\_ups}~=~\textit{true}). 
    304324 
    305325% ------------------------------------------------------------------------------------------------------------- 
     
    310330\label{TRA_adv_ubs} 
    311331 
    312 The UBS advection scheme is an upstream-biased third order scheme based on  
    313 an upstream-biased parabolic interpolation. It is also known as the Cell  
    314 Averaged QUICK scheme (Quadratic Upstream Interpolation for Convective  
    315 Kinematics). For example, in the $i$-direction : 
     332The Upstream-Biased Scheme (UBS) is used when \np{ln\_traadv\_ubs}~=~\textit{true}.  
     333UBS implementation can be found in the \mdl{traadv\_mus} module. 
     334 
     335The UBS scheme, often called UP3, is also known as the Cell Averaged QUICK scheme  
     336(Quadratic Upstream Interpolation for Convective Kinematics). It is an upstream-biased  
     337third order scheme based on an upstream-biased parabolic interpolation.   
     338For example, in the $i$-direction : 
    316339\begin{equation} \label{Eq_tra_adv_ubs} 
    317340   \tau _u^{ubs} =\overline T ^{i+1/2}-\;\frac{1}{6} \left\{       
     
    324347 
    325348This results in a dissipatively dominant (i.e. hyper-diffusive) truncation  
    326 error \citep{Shchepetkin_McWilliams_OM05}. The overall performance of the advection  
    327 scheme is similar to that reported in \cite{Farrow1995}.  
     349error \citep{Shchepetkin_McWilliams_OM05}. The overall performance of 
     350 the advection scheme is similar to that reported in \cite{Farrow1995}.  
    328351It is a relatively good compromise between accuracy and smoothness.  
    329 It is not a \emph{positive} scheme, meaning that false extrema are permitted,  
     352Nevertheless the scheme is not \emph{positive}, meaning that false extrema are permitted,  
    330353but the amplitude of such are significantly reduced over the centred second  
    331 order method. Nevertheless it is not recommended that it should be applied  
    332 to a passive tracer that requires positivity.  
     354or fourth order method. therefore it is not recommended that it should be  
     355applied to a passive tracer that requires positivity.  
    333356 
    334357The intrinsic diffusion of UBS makes its use risky in the vertical direction  
    335 where the control of artificial diapycnal fluxes is of paramount importance.  
    336 Therefore the vertical flux is evaluated using the TVD scheme when  
    337 \np{ln\_traadv\_ubs}=true. 
     358where the control of artificial diapycnal fluxes is of paramount importance \citep{Shchepetkin_McWilliams_OM05, Demange_PhD2014}.  
     359Therefore the vertical flux is evaluated using either a $2^nd$ order FCT scheme  
     360or a $4^th$ order COMPACT scheme (\np{nn\_cen\_v}=2 or 4). 
    338361 
    339362For stability reasons  (see \S\ref{STP}), 
    340 the first term  in \eqref{Eq_tra_adv_ubs} (which corresponds to a second order centred scheme)  
    341 is evaluated using the \textit{now} tracer (centred in time) while the  
    342 second term (which is the diffusive part of the scheme), is  
     363the first term  in \eqref{Eq_tra_adv_ubs} (which corresponds to a second order  
     364centred scheme) is evaluated using the \textit{now} tracer (centred in time)  
     365while the second term (which is the diffusive part of the scheme), is  
    343366evaluated using the \textit{before} tracer (forward in time).  
    344367This choice is discussed by \citet{Webb_al_JAOT98} in the context of the  
     
    350373substitution in the \mdl{traadv\_ubs} module and obtain a QUICK scheme. 
    351374 
    352 Four different options are possible for the vertical  
    353 component used in the UBS scheme. $\tau _w^{ubs}$ can be evaluated  
    354 using either \textit{(a)} a centred $2^{nd}$ order scheme, or  \textit{(b)}  
    355 a TVD scheme, or  \textit{(c)} an interpolation based on conservative  
    356 parabolic splines following the \citet{Shchepetkin_McWilliams_OM05}  
    357 implementation of UBS in ROMS, or  \textit{(d)} a UBS. The $3^{rd}$ case  
    358 has dispersion properties similar to an eighth-order accurate conventional scheme. 
    359 The current reference version uses method b) 
    360  
    361 Note that : 
    362  
    363 (1) When a high vertical resolution $O(1m)$ is used, the model stability can  
    364 be controlled by vertical advection (not vertical diffusion which is usually  
    365 solved using an implicit scheme). Computer time can be saved by using a  
    366 time-splitting technique on vertical advection. Such a technique has been  
    367 implemented and validated in ORCA05 with 301 levels. It is not available  
    368 in the current reference version.  
    369  
    370 (2) It is straightforward to rewrite \eqref{Eq_tra_adv_ubs} as follows: 
     375Note that it is straightforward to rewrite \eqref{Eq_tra_adv_ubs} as follows: 
    371376\begin{equation} \label{Eq_traadv_ubs2} 
    372377\tau _u^{ubs} = \tau _u^{cen4} + \frac{1}{12} \left\{   
     
    390395Thirdly, the diffusion term is in fact a biharmonic operator with an eddy  
    391396coefficient which is simply proportional to the velocity: 
    392  $A_u^{lm}= - \frac{1}{12}\,{e_{1u}}^3\,|u|$. Note that NEMO v3.4 still uses  
    393  \eqref{Eq_tra_adv_ubs}, not \eqref{Eq_traadv_ubs2}. 
    394  %%% 
    395  \gmcomment{the change in UBS scheme has to be done} 
    396  %%% 
     397 $A_u^{lm}= \frac{1}{12}\,{e_{1u}}^3\,|u|$. Note the current version of NEMO uses  
     398the computationally more efficient formulation \eqref{Eq_tra_adv_ubs}. 
    397399 
    398400% ------------------------------------------------------------------------------------------------------------- 
     
    405407The Quadratic Upstream Interpolation for Convective Kinematics with  
    406408Estimated Streaming Terms (QUICKEST) scheme proposed by \citet{Leonard1979}  
    407 is the third order Godunov scheme. It is associated with the ULTIMATE QUICKEST  
     409is used when \np{ln\_traadv\_qck}~=~\textit{true}.  
     410QUICKEST implementation can be found in the \mdl{traadv\_qck} module. 
     411 
     412QUICKEST is the third order Godunov scheme which is associated with the ULTIMATE QUICKEST  
    408413limiter \citep{Leonard1991}. It has been implemented in NEMO by G. Reffray  
    409414(MERCATOR-ocean) and can be found in the \mdl{traadv\_qck} module. 
     
    413418direction where the control of artificial diapycnal fluxes is of paramount importance.  
    414419Therefore the vertical flux is evaluated using the CEN2 scheme.  
    415 This no longer guarantees the positivity of the scheme. The use of TVD in the vertical  
    416 direction (as for the UBS case) should be implemented to restore this property. 
    417  
    418  
    419 % ------------------------------------------------------------------------------------------------------------- 
    420 %        PPM scheme   
    421 % ------------------------------------------------------------------------------------------------------------- 
    422 \subsection   [Piecewise Parabolic Method (PPM) (\np{ln\_traadv\_ppm})] 
    423          {Piecewise Parabolic Method (PPM) (\np{ln\_traadv\_ppm}=true)} 
    424 \label{TRA_adv_ppm} 
    425  
    426 The Piecewise Parabolic Method (PPM) proposed by Colella and Woodward (1984)  
    427 \sgacomment{reference?} 
    428 is based on a quadradic piecewise construction. Like the QCK scheme, it is associated  
    429 with the ULTIMATE QUICKEST limiter \citep{Leonard1991}. It has been implemented  
    430 in \NEMO by G. Reffray (MERCATOR-ocean) but is not yet offered in the reference  
    431 version 3.3. 
     420This no longer guarantees the positivity of the scheme.  
     421The use of FCT in the vertical direction (as for the UBS case) should be implemented  
     422to restore this property. 
     423 
     424%%%gmcomment   :  Cross term are missing in the current implementation.... 
     425 
    432426 
    433427% ================================================================ 
     
    441435%------------------------------------------------------------------------------------------------------------- 
    442436  
    443 Options are defined through the  \ngn{namtra\_ldf} namelist variables. 
    444 The options available for lateral diffusion are a laplacian (rotated or not)  
    445 or a biharmonic operator, the latter being more scale-selective (more  
    446 diffusive at small scales). The specification of eddy diffusivity  
    447 coefficients (either constant or variable in space and time) as well as the  
    448 computation of the slope along which the operators act, are performed in the  
    449 \mdl{ldftra} and \mdl{ldfslp} modules, respectively. This is described in Chap.~\ref{LDF}.  
     437Options are defined through the \ngn{namtra\_ldf} namelist variables. 
     438They are regrouped in four items, allowing to specify  
     439$(i)$   the type of operator used (none, laplacian, bilaplacian),  
     440$(ii)$  the direction along which the operator acts (iso-level, horizontal, iso-neutral),  
     441$(iii)$ some specific options related to the rotated operators ($i.e.$ non-iso-level operator), and  
     442$(iv)$  the specification of eddy diffusivity coefficient (either constant or variable in space and time). 
     443Item $(iv)$ will be described in Chap.\ref{LDF} . 
     444The direction along which the operators act is defined through the slope between this direction and the iso-level surfaces. 
     445The slope is computed in the \mdl{ldfslp} module and will also be described in Chap.~\ref{LDF}.  
     446 
    450447The lateral diffusion of tracers is evaluated using a forward scheme,  
    451448$i.e.$ the tracers appearing in its expression are the \textit{before} tracers in time,  
    452 except for the pure vertical component that appears when a rotation tensor  
    453 is used. This latter term is solved implicitly together with the  
    454 vertical diffusion term (see \S\ref{STP}). 
    455  
    456 % ------------------------------------------------------------------------------------------------------------- 
    457 %        Iso-level laplacian operator 
    458 % ------------------------------------------------------------------------------------------------------------- 
    459 \subsection   [Iso-level laplacian operator (lap) (\np{ln\_traldf\_lap})] 
    460          {Iso-level laplacian operator (lap) (\np{ln\_traldf\_lap}=true) } 
    461 \label{TRA_ldf_lap} 
    462  
    463 A laplacian diffusion operator ($i.e.$ a harmonic operator) acting along the model  
    464 surfaces is given by:  
     449except for the pure vertical component that appears when a rotation tensor is used.  
     450This latter component is solved implicitly together with the vertical diffusion term (see \S\ref{STP}).  
     451When \np{ln\_traldf\_msc}~=~\textit{true}, a Method of Stabilizing Correction is used in which  
     452the pure vertical component is split into an explicit and an implicit part \citep{Lemarie_OM2012}. 
     453 
     454% ------------------------------------------------------------------------------------------------------------- 
     455%        Type of operator 
     456% ------------------------------------------------------------------------------------------------------------- 
     457\subsection   [Type of operator (\np{ln\_traldf\_NONE}, \np{ln\_traldf\_lap}, \np{ln\_traldf\_blp})] 
     458              {Type of operator (\np{ln\_traldf\_NONE}, \np{ln\_traldf\_lap}, or \np{ln\_traldf\_blp} = true) }  
     459\label{TRA_ldf_op} 
     460 
     461Three operator options are proposed and, one and only one of them must be selected: 
     462\begin{description} 
     463\item [\np{ln\_traldf\_NONE}] = true : no operator selected, the lateral diffusive tendency will not be  
     464applied to the tracer equation. This option can be used when the selected advection scheme  
     465is diffusive enough (MUSCL scheme for example). 
     466\item [ \np{ln\_traldf\_lap}] = true : a laplacian operator is selected. This harmonic operator  
     467takes the following expression:  $\mathpzc{L}(T)=\nabla \cdot A_{ht}\;\nabla T $,  
     468where the gradient operates along the selected direction (see \S\ref{TRA_ldf_dir}), 
     469and $A_{ht}$ is the eddy diffusivity coefficient expressed in $m^2/s$ (see Chap.~\ref{LDF}). 
     470\item [\np{ln\_traldf\_blp}] = true : a bilaplacian operator is selected. This biharmonic operator  
     471takes the following expression:   
     472$\mathpzc{B}=- \mathpzc{L}\left(\mathpzc{L}(T) \right) = -\nabla \cdot b\nabla \left( {\nabla \cdot b\nabla T} \right)$  
     473where the gradient operats along the selected direction, 
     474and $b^2=B_{ht}$ is the eddy diffusivity coefficient expressed in $m^4/s$  (see Chap.~\ref{LDF}). 
     475In the code, the bilaplacian operator is obtained by calling the laplacian twice. 
     476\end{description} 
     477 
     478Both laplacian and bilaplacian operators ensure the total tracer variance decrease.  
     479Their primary role is to provide strong dissipation at the smallest scale supported  
     480by the grid while minimizing the impact on the larger scale features.  
     481The main difference between the two operators is the scale selectiveness.  
     482The bilaplacian damping time ($i.e.$ its spin down time) scales like $\lambda^{-4}$  
     483for disturbances of wavelength $\lambda$ (so that short waves damped more rapidelly than long ones),  
     484whereas the laplacian damping time scales only like $\lambda^{-2}$. 
     485 
     486 
     487% ------------------------------------------------------------------------------------------------------------- 
     488%        Direction of action 
     489% ------------------------------------------------------------------------------------------------------------- 
     490\subsection   [Direction of action (\np{ln\_traldf\_lev}, \np{ln\_traldf\_hor}, \np{ln\_traldf\_iso}, \np{ln\_traldf\_triad})] 
     491              {Direction of action (\np{ln\_traldf\_lev}, \textit{...\_hor}, \textit{...\_iso}, or \textit{...\_triad} = true) }  
     492\label{TRA_ldf_dir} 
     493 
     494The choice of a direction of action determines the form of operator used.  
     495The operator is a simple (re-entrant) laplacian acting in the (\textbf{i},\textbf{j}) plane  
     496when iso-level option is used (\np{ln\_traldf\_lev}~=~\textit{true}) 
     497or when a horizontal ($i.e.$ geopotential) operator is demanded in \textit{z}-coordinate  
     498(\np{ln\_traldf\_hor} and \np{ln\_zco} equal \textit{true}).  
     499The associated code can be found in the \mdl{traldf\_lap\_blp} module. 
     500The operator is a rotated (re-entrant) laplacian when the direction along which it acts  
     501does not coincide with the iso-level surfaces,  
     502that is when standard or triad iso-neutral option is used (\np{ln\_traldf\_iso} or  
     503 \np{ln\_traldf\_triad} equals \textit{true}, see \mdl{traldf\_iso} or \mdl{traldf\_triad} module, resp.),  
     504or when a horizontal ($i.e.$ geopotential) operator is demanded in \textit{s}-coordinate  
     505(\np{ln\_traldf\_hor} and \np{ln\_sco} equal \textit{true}) 
     506\footnote{In this case, the standard iso-neutral operator will be automatically selected}.  
     507In that case, a rotation is applied to the gradient(s) that appears in the operator  
     508so that diffusive fluxes acts on the three spatial direction. 
     509 
     510The resulting discret form of the three operators (one iso-level and two rotated one)  
     511is given in the next two sub-sections.  
     512 
     513 
     514% ------------------------------------------------------------------------------------------------------------- 
     515%       iso-level operator 
     516% ------------------------------------------------------------------------------------------------------------- 
     517\subsection   [Iso-level (bi-)laplacian operator ( \np{ln\_traldf\_iso})] 
     518         {Iso-level (bi-)laplacian operator ( \np{ln\_traldf\_iso}) } 
     519\label{TRA_ldf_lev} 
     520 
     521The laplacian diffusion operator acting along the model (\textit{i,j})-surfaces is given by:  
    465522\begin{equation} \label{Eq_tra_ldf_lap} 
    466 D_T^{lT} =\frac{1}{b_tT} \left( \; 
     523D_t^{lT} =\frac{1}{b_t} \left( \; 
    467524   \delta _{i}\left[ A_u^{lT} \; \frac{e_{2u}\,e_{3u}}{e_{1u}} \;\delta _{i+1/2} [T] \right]  
    468525+ \delta _{j}\left[ A_v^{lT} \;  \frac{e_{1v}\,e_{3v}}{e_{2v}} \;\delta _{j+1/2} [T] \right]  \;\right) 
    469526\end{equation} 
    470 where  $b_t$=$e_{1t}\,e_{2t}\,e_{3t}$  is the volume of $T$-cells.  
    471 It is implemented in the \mdl{traadv\_lap} module. 
    472  
    473 This lateral operator is computed in \mdl{traldf\_lap}. It is a \emph{horizontal}  
    474 operator ($i.e.$ acting along geopotential surfaces) in the $z$-coordinate with  
    475 or without partial steps, but is simply an iso-level operator in the $s$-coordinate.  
    476 It is thus used when, in addition to \np{ln\_traldf\_lap}=true, we have  
    477 \np{ln\_traldf\_level}=true or \np{ln\_traldf\_hor}=\np{ln\_zco}=true.  
     527where  $b_t$=$e_{1t}\,e_{2t}\,e_{3t}$  is the volume of $T$-cells  
     528and where zero diffusive fluxes is assumed across solid boundaries,  
     529first (and third in bilaplacian case) horizontal tracer derivative are masked.  
     530It is implemented in the \rou{traldf\_lap} subroutine found in the \mdl{traldf\_lap} module.  
     531The module also contains \rou{traldf\_blp}, the subroutine calling twice \rou{traldf\_lap}  
     532in order to compute the iso-level bilaplacian operator.  
     533 
     534It is a \emph{horizontal} operator ($i.e.$ acting along geopotential surfaces) in the $z$-coordinate  
     535with or without partial steps, but is simply an iso-level operator in the $s$-coordinate.  
     536It is thus used when, in addition to \np{ln\_traldf\_lap} or \np{ln\_traldf\_blp}~=~\textit{true},  
     537we have \np{ln\_traldf\_lev}~=~\textit{true} or \np{ln\_traldf\_hor}~=~\np{ln\_zco}~=~\textit{true}.  
    478538In both cases, it significantly contributes to diapycnal mixing.  
    479 It is therefore not recommended. 
     539It is therefore never recommended, even when using it in the bilaplacian case. 
    480540 
    481541Note that in the partial step $z$-coordinate (\np{ln\_zps}=true), tracers in horizontally  
     
    485545described in \S\ref{TRA_zpshde}. 
    486546 
    487 % ------------------------------------------------------------------------------------------------------------- 
    488 %        Rotated laplacian operator 
    489 % ------------------------------------------------------------------------------------------------------------- 
    490 \subsection   [Rotated laplacian operator (iso) (\np{ln\_traldf\_lap})] 
    491          {Rotated laplacian operator (iso) (\np{ln\_traldf\_lap}=true)} 
     547 
     548% ------------------------------------------------------------------------------------------------------------- 
     549%         Rotated laplacian operator 
     550% ------------------------------------------------------------------------------------------------------------- 
     551\subsection   [Standard and triad rotated (bi-)laplacian operator (\mdl{traldf\_iso}, \mdl{traldf\_triad})] 
     552               {Standard and triad (bi-)laplacian operator (\mdl{traldf\_iso}, \mdl{traldf\_triad}))} 
     553\label{TRA_ldf_iso_triad} 
     554 
     555%&&    Standard rotated (bi-)laplacian operator 
     556%&& ---------------------------------------------- 
     557\subsubsection   [Standard rotated (bi-)laplacian operator (\mdl{traldf\_iso})] 
     558                 {Standard rotated (bi-)laplacian operator (\mdl{traldf\_iso})} 
    492559\label{TRA_ldf_iso} 
    493  
    494 If the Griffies trad scheme is not employed 
    495 (\np{ln\_traldf\_grif}=true; see App.\ref{sec:triad}) the general form of the second order lateral tracer subgrid scale physics  
    496 (\ref{Eq_PE_zdf}) takes the following semi-discrete space form in $z$- and  
    497 $s$-coordinates: 
     560The general form of the second order lateral tracer subgrid scale physics  
     561(\ref{Eq_PE_zdf}) takes the following semi-discrete space form in $z$- and $s$-coordinates: 
    498562\begin{equation} \label{Eq_tra_ldf_iso} 
    499563\begin{split} 
     
    537601of the tracer variance. Nevertheless the treatment performed on the slopes  
    538602(see \S\ref{LDF}) allows the model to run safely without any additional  
    539 background horizontal diffusion \citep{Guilyardi_al_CD01}. An alternative scheme  
    540 developed by \cite{Griffies_al_JPO98} which ensures tracer variance decreases  
     603background horizontal diffusion \citep{Guilyardi_al_CD01}.  
     604 
     605Note that in the partial step $z$-coordinate (\np{ln\_zps}=true), the horizontal derivatives  
     606at the bottom level in \eqref{Eq_tra_ldf_iso} require a specific treatment.  
     607They are calculated in module zpshde, described in \S\ref{TRA_zpshde}. 
     608 
     609%&&     Triad rotated (bi-)laplacian operator 
     610%&&  ------------------------------------------- 
     611\subsubsection   [Triad rotated (bi-)laplacian operator (\np{ln\_traldf\_triad})] 
     612                 {Triad rotated (bi-)laplacian operator (\np{ln\_traldf\_triad})} 
     613\label{TRA_ldf_triad} 
     614 
     615If the Griffies triad scheme is employed (\np{ln\_traldf\_triad}=true ; see App.\ref{sec:triad})  
     616 
     617An alternative scheme developed by \cite{Griffies_al_JPO98} which ensures tracer variance decreases  
    541618is also available in \NEMO (\np{ln\_traldf\_grif}=true). A complete description of  
    542619the algorithm is given in App.\ref{sec:triad}. 
    543  
    544 Note that in the partial step $z$-coordinate (\np{ln\_zps}=true), the horizontal  
    545 derivatives at the bottom level in \eqref{Eq_tra_ldf_iso} require a specific  
    546 treatment. They are calculated in module zpshde, described in \S\ref{TRA_zpshde}. 
    547  
    548 % ------------------------------------------------------------------------------------------------------------- 
    549 %        Iso-level bilaplacian operator 
    550 % ------------------------------------------------------------------------------------------------------------- 
    551 \subsection   [Iso-level bilaplacian operator (bilap) (\np{ln\_traldf\_bilap})] 
    552          {Iso-level bilaplacian operator (bilap) (\np{ln\_traldf\_bilap}=true)} 
    553 \label{TRA_ldf_bilap} 
    554620 
    555621The lateral fourth order bilaplacian operator on tracers is obtained by  
    556622applying (\ref{Eq_tra_ldf_lap}) twice. The operator requires an additional assumption  
    557623on boundary conditions: both first and third derivative terms normal to the  
    558 coast are set to zero. It is used when, in addition to \np{ln\_traldf\_bilap}=true,  
    559 we have \np{ln\_traldf\_level}=true, or both \np{ln\_traldf\_hor}=true and  
    560 \np{ln\_zco}=false. In both cases, it can contribute diapycnal mixing,  
    561 although less than in the laplacian case. It is therefore not recommended. 
    562  
    563 Note that in the code, the bilaplacian routine does not call the laplacian  
    564 routine twice but is rather a separate routine that can be found in the 
    565 \mdl{traldf\_bilap} module. This is due to the fact that we introduce the  
    566 eddy diffusivity coefficient, A, in the operator as:  
    567 $\nabla \cdot \nabla \left( {A\nabla \cdot \nabla T} \right)$,  
    568 instead of  
    569 $-\nabla \cdot a\nabla \left( {\nabla \cdot a\nabla T} \right)$  
    570 where $a=\sqrt{|A|}$ and $A<0$. This was a mistake: both formulations  
    571 ensure the total variance decrease, but the former requires a larger  
    572 number of code-lines. 
    573  
    574 % ------------------------------------------------------------------------------------------------------------- 
    575 %        Rotated bilaplacian operator 
    576 % ------------------------------------------------------------------------------------------------------------- 
    577 \subsection   [Rotated bilaplacian operator (bilapg) (\np{ln\_traldf\_bilap})] 
    578          {Rotated bilaplacian operator (bilapg) (\np{ln\_traldf\_bilap}=true)} 
    579 \label{TRA_ldf_bilapg} 
     624coast are set to zero. 
    580625 
    581626The lateral fourth order operator formulation on tracers is obtained by  
    582627applying (\ref{Eq_tra_ldf_iso}) twice. It requires an additional assumption  
    583628on boundary conditions: first and third derivative terms normal to the  
    584 coast, normal to the bottom and normal to the surface are set to zero. It can be found in the 
    585 \mdl{traldf\_bilapg}. 
    586  
    587 It is used when, in addition to \np{ln\_traldf\_bilap}=true, we have  
    588 \np{ln\_traldf\_iso}= .true, or both \np{ln\_traldf\_hor}=true and \np{ln\_zco}=true.  
    589 This rotated bilaplacian operator has never been seriously  
    590 tested. There are no guarantees that it is either free of bugs or correctly formulated.  
    591 Moreover, the stability range of such an operator will be probably quite  
    592 narrow, requiring a significantly smaller time-step than the one used with an 
    593 unrotated operator. 
     629coast, normal to the bottom and normal to the surface are set to zero.  
     630 
     631%&&    Option for the rotated operators 
     632%&& ---------------------------------------------- 
     633\subsubsection   [Option for the rotated operators] 
     634                 {Option for the rotated operators} 
     635\label{TRA_ldf_options} 
     636 
     637\np{ln\_traldf\_msc} = Method of Stabilizing Correction (both operators) 
     638 
     639\np{rn\_slpmax} = slope limit (both operators) 
     640 
     641\np{ln\_triad\_iso} = pure horizontal mixing in ML (triad only) 
     642 
     643\np{rn\_sw\_triad} =1 switching triad ; =0 all 4 triads used (triad only)  
     644 
     645\np{ln\_botmix\_triad} = lateral mixing on bottom (triad only) 
    594646 
    595647% ================================================================ 
     
    603655%-------------------------------------------------------------------------------------------------------------- 
    604656 
    605 Options are defined through the  \ngn{namzdf} namelist variables. 
     657Options are defined through the \ngn{namzdf} namelist variables. 
    606658The formulation of the vertical subgrid scale tracer physics is the same  
    607659for all the vertical coordinates, and is based on a laplacian operator.  
     
    661713the thickness of the top model layer.  
    662714 
    663 Due to interactions and mass exchange of water ($F_{mass}$) with other Earth system components ($i.e.$ atmosphere, sea-ice, land), 
    664 the change in the heat and salt content of the surface layer of the ocean is due both  
    665 to the heat and salt fluxes crossing the sea surface (not linked with $F_{mass}$) 
    666  and to the heat and salt content of the mass exchange. 
    667 \sgacomment{ the following does not apply to the release to which this documentation is  
    668 attached and so should not be included .... 
    669 In a forthcoming release, these two parts, computed in the surface module (SBC), will be included directly 
    670 in $Q_{ns}$, the surface heat flux and $F_{salt}$, the surface salt flux. 
    671 The specification of these fluxes is further detailed in the SBC chapter (see \S\ref{SBC}).  
    672 This change will provide a forcing formulation which is the same for any tracer (including temperature and salinity). 
    673   
    674 In the current version, the situation is a little bit more complicated. } 
     715Due to interactions and mass exchange of water ($F_{mass}$) with other Earth system components  
     716($i.e.$ atmosphere, sea-ice, land), the change in the heat and salt content of the surface layer  
     717of the ocean is due both to the heat and salt fluxes crossing the sea surface (not linked with $F_{mass}$)  
     718and to the heat and salt content of the mass exchange. They are both included directly in $Q_{ns}$,  
     719the surface heat flux, and $F_{salt}$, the surface salt flux (see \S\ref{SBC} for further details). 
     720By doing this, the forcing formulation is the same for any tracer (including temperature and salinity). 
    675721 
    676722The surface module (\mdl{sbcmod}, see \S\ref{SBC}) provides the following  
     
    679725$\bullet$ $Q_{ns}$, the non-solar part of the net surface heat flux that crosses the sea surface  
    680726(i.e. the difference between the total surface heat flux and the fraction of the short wave flux that  
    681 penetrates into the water column, see \S\ref{TRA_qsr}) 
    682  
    683 $\bullet$ \textit{emp}, the mass flux exchanged with the atmosphere (evaporation minus precipitation) 
    684  
    685 $\bullet$ $\textit{emp}_S$, an equivalent mass flux taking into account the effect of ice-ocean mass exchange 
    686  
    687 $\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) 
    688  
    689 The $\textit{emp}_S$ field is not simply the budget of evaporation-precipitation+freezing-melting because  
    690 the sea-ice is not currently embedded in the ocean but levitates above it. There is no mass 
    691 exchanged between the sea-ice and the ocean. Instead we only take into account the salt 
    692 flux associated with the non-zero salinity of sea-ice, and the concentration/dilution effect 
    693 due to the freezing/melting (F/M) process. These two parts of the forcing are then converted into  
    694 an equivalent mass flux given by $\textit{emp}_S - \textit{emp}$. As a result of this mess,  
    695 the surface boundary condition on temperature and salinity is applied as follows: 
    696  
    697 In the nonlinear free surface case (\key{vvl} is defined): 
     727penetrates into the water column, see \S\ref{TRA_qsr}) plus the heat content associated with  
     728of the mass exchange with the atmosphere and lands. 
     729 
     730$\bullet$ $\textit{sfx}$, the salt flux resulting from ice-ocean mass exchange (freezing, melting, ridging...) 
     731 
     732$\bullet$ \textit{emp}, the mass flux exchanged with the atmosphere (evaporation minus precipitation)  
     733 and possibly with the sea-ice and ice-shelves. 
     734 
     735$\bullet$ \textit{rnf}, the mass flux associated with runoff  
     736(see \S\ref{SBC_rnf} for further detail of how it acts on temperature and salinity tendencies) 
     737 
     738$\bullet$ \textit{fwfisf}, the mass flux associated with ice shelf melt,  
     739(see \S\ref{SBC_isf} for further details on how the ice shelf melt is computed and applied). 
     740 
     741The surface boundary condition on temperature and salinity is applied as follows: 
    698742\begin{equation} \label{Eq_tra_sbc} 
     743\begin{aligned} 
     744 &F^T = \frac{ 1 }{\rho _o \;C_p \,\left. e_{3t} \right|_{k=1} }  &\overline{ Q_{ns}       }^t  & \\  
     745& F^S =\frac{ 1 }{\rho _o  \,      \left. e_{3t} \right|_{k=1} }  &\overline{ \textit{sfx} }^t   & \\    
     746 \end{aligned} 
     747\end{equation}  
     748where $\overline{x }^t$ means that $x$ is averaged over two consecutive time steps  
     749($t-\rdt/2$ and $t+\rdt/2$). Such time averaging prevents the  
     750divergence of odd and even time step (see \S\ref{STP}). 
     751 
     752In the linear free surface case (\np{ln\_linssh}~=~\textit{true}),  
     753an additional term has to be added on both temperature and salinity.  
     754On temperature, this term remove the heat content associated with mass exchange 
     755that has been added to $Q_{ns}$. On salinity, this term mimics the concentration/dilution effect that 
     756would have resulted from a change in the volume of the first level. 
     757The resulting surface boundary condition is applied as follows: 
     758\begin{equation} \label{Eq_tra_sbc_lin} 
    699759\begin{aligned} 
    700760 &F^T = \frac{ 1 }{\rho _o \;C_p \,\left. e_{3t} \right|_{k=1} }    
     
    702762% 
    703763& F^S =\frac{ 1 }{\rho _o \,\left. e_{3t} \right|_{k=1} }  
    704            &\overline{ \left( (\textit{emp}_S - \textit{emp})\;\left. S \right|_{k=1}  \right) }^t   & \\    
     764           &\overline{ \left( \;\textit{sfx} - \textit{emp} \;\left. S \right|_{k=1}  \right) }^t   & \\    
    705765 \end{aligned} 
    706766\end{equation}  
    707  
    708 In the linear free surface case (\key{vvl} not defined): 
    709 \begin{equation} \label{Eq_tra_sbc_lin} 
    710 \begin{aligned} 
    711  &F^T = \frac{ 1 }{\rho _o \;C_p \,\left. e_{3t} \right|_{k=1} }  &\overline{ Q_{ns} }^t  & \\  
    712 % 
    713 & F^S =\frac{ 1 }{\rho _o \,\left. e_{3t} \right|_{k=1} }  
    714            &\overline{ \left( \textit{emp}_S\;\left. S \right|_{k=1}  \right) }^t   & \\    
    715  \end{aligned} 
    716 \end{equation}  
    717 where $\overline{x }^t$ means that $x$ is averaged over two consecutive time steps  
    718 ($t-\rdt/2$ and $t+\rdt/2$). Such time averaging prevents the  
    719 divergence of odd and even time step (see \S\ref{STP}). 
    720  
    721 The two set of equations, \eqref{Eq_tra_sbc} and \eqref{Eq_tra_sbc_lin}, are obtained  
    722 by assuming that the temperature of precipitation and evaporation are equal to 
    723 the ocean surface temperature and that their salinity is zero. Therefore, the heat content 
    724 of the \textit{emp} budget must be added to the temperature equation in the variable volume case,  
    725 while it does not appear in the constant volume case. Similarly, the \textit{emp} budget affects  
    726 the ocean surface salinity in the constant volume case (through the concentration dilution effect) 
    727 while it does not appears explicitly in the variable volume case since salinity change will be 
    728 induced by volume change. In both constant and variable volume cases, surface salinity  
    729 will change with ice-ocean salt flux and F/M flux (both contained in $\textit{emp}_S - \textit{emp}$) without mass exchanges. 
    730  
    731 Note that the concentration/dilution effect due to F/M is computed using 
    732 a constant ice salinity as well as a constant ocean salinity.  
    733 This approximation suppresses the correlation between \textit{SSS}  
    734 and F/M flux, allowing the ice-ocean salt exchanges to be conservative. 
    735 Indeed, if this approximation is not made, even if the F/M budget is zero  
    736 on average over the whole ocean domain and over the seasonal cycle,  
    737 the associated salt flux is not zero, since sea-surface salinity and F/M flux are  
    738 intrinsically correlated (high \textit{SSS} are found where freezing is  
    739 strong whilst low \textit{SSS} is usually associated with high melting areas). 
    740  
    741 Even using this approximation, an exact conservation of heat and salt content  
    742 is only achieved in the variable volume case. In the constant volume case,  
    743 there is a small imbalance associated with the product $(\partial_t\eta - \textit{emp}) * \textit{SSS}$. 
    744 Nevertheless, the salt content variation is quite small and will not induce 
    745 a long term drift as there is no physical reason for $(\partial_t\eta - \textit{emp})$  
    746 and \textit{SSS} to be correlated \citep{Roullet_Madec_JGR00}.  
    747 Note that, while quite small, the imbalance in the constant volume case is larger  
     767Note that an exact conservation of heat and salt content is only achieved with non-linear free surface.  
     768In the linear free surface case, there is a small imbalance. The imbalance is larger  
    748769than the imbalance associated with the Asselin time filter \citep{Leclair_Madec_OM09}.  
    749 This is the reason why the modified filter is not applied in the constant volume case. 
     770This is the reason why the modified filter is not applied in the linear free surface case (see \S\ref{STP}). 
    750771 
    751772% ------------------------------------------------------------------------------------------------------------- 
     
    821842($i.e.$ the inverses of the extinction length scales) are tabulated over 61 nonuniform  
    822843chlorophyll classes ranging from 0.01 to 10 g.Chl/L (see the routine \rou{trc\_oce\_rgb}  
    823 in \mdl{trc\_oce} module). Three types of chlorophyll can be chosen in the RGB formulation: 
    824 (1) a constant 0.05 g.Chl/L value everywhere (\np{nn\_chdta}=0) ; (2) an observed  
    825 time varying chlorophyll (\np{nn\_chdta}=1) ; (3) simulated time varying chlorophyll 
    826 by TOP biogeochemical model (\np{ln\_qsr\_bio}=true). In the latter case, the RGB  
    827 formulation is used to calculate both the phytoplankton light limitation in PISCES  
    828 or LOBSTER and the oceanic heating rate.  
    829  
     844in \mdl{trc\_oce} module). Four types of chlorophyll can be chosen in the RGB formulation: 
     845\begin{description}  
     846\item[\np{nn\_chdta}=0]  
     847a constant 0.05 g.Chl/L value everywhere ;  
     848\item[\np{nn\_chdta}=1]   
     849an observed time varying chlorophyll deduced from satellite surface ocean color measurement  
     850spread uniformly in the vertical direction ;  
     851\item[\np{nn\_chdta}=2]   
     852same as previous case except that a vertical profile of chlorophyl is used.  
     853Following \cite{Morel_Berthon_LO89}, the profile is computed from the local surface chlorophyll value ; 
     854\item[\np{ln\_qsr\_bio}=true]   
     855simulated time varying chlorophyll by TOP biogeochemical model.  
     856In this case, the RGB formulation is used to calculate both the phytoplankton  
     857light limitation in PISCES or LOBSTER and the oceanic heating rate.  
     858\end{description}  
    830859The trend in \eqref{Eq_tra_qsr} associated with the penetration of the solar radiation  
    831860is added to the temperature trend, and the surface heat flux is modified in routine \mdl{traqsr}.  
     
    842871%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    843872\begin{figure}[!t]     \begin{center} 
    844 \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_TRA_Irradiance.pdf} 
     873\includegraphics[width=1.0\textwidth]{Fig_TRA_Irradiance} 
    845874\caption{    \label{Fig_traqsr_irradiance} 
    846875Penetration profile of the downward solar irradiance calculated by four models.  
     
    859888\label{TRA_bbc} 
    860889%--------------------------------------------nambbc-------------------------------------------------------- 
    861 \namdisplay{namtra_bbc} 
     890\namdisplay{nambbc} 
    862891%-------------------------------------------------------------------------------------------------------------- 
    863892%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    864893\begin{figure}[!t]     \begin{center} 
    865 \includegraphics[width=1.0\textwidth]{./TexFiles/Figures/Fig_TRA_geoth.pdf} 
     894\includegraphics[width=1.0\textwidth]{Fig_TRA_geoth} 
    866895\caption{   \label{Fig_geothermal} 
    867896Geothermal Heat flux (in $mW.m^{-2}$) used by \cite{Emile-Geay_Madec_OS09}. 
     
    9731002%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    9741003\begin{figure}[!t]   \begin{center} 
    975 \includegraphics[width=0.7\textwidth]{./TexFiles/Figures/Fig_BBL_adv.pdf} 
     1004\includegraphics[width=0.7\textwidth]{Fig_BBL_adv} 
    9761005\caption{   \label{Fig_bbl}   
    9771006Advective/diffusive Bottom Boundary Layer. The BBL parameterisation is  
     
    11031132\subsection[DMP\_TOOLS]{Generating resto.nc using DMP\_TOOLS} 
    11041133 
    1105 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. 
     1134DMP\_TOOLS can be used to generate a netcdf file containing the restoration coefficient $\gamma$.  
     1135Note that in order to maintain bit comparison with previous NEMO versions DMP\_TOOLS must be compiled  
     1136and run on the same machine as the NEMO model. A mesh\_mask.nc file for the model configuration is required as an input.  
     1137This can be generated by carrying out a short model run with the namelist parameter \np{nn\_msh} set to 1.  
     1138The namelist parameter \np{ln\_tradmp} will also need to be set to .false. for this to work.  
     1139The \nl{nam\_dmp\_create} namelist in the DMP\_TOOLS directory is used to specify options for the restoration coefficient. 
    11061140 
    11071141%--------------------------------------------nam_dmp_create------------------------------------------------- 
    1108 \namdisplay{nam_dmp_create} 
     1142\namtools{namelist_dmp} 
    11091143%------------------------------------------------------------------------------------------------------- 
    11101144 
    11111145\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. 
    11121146 
    1113 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. 
    1114  
    1115 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}.   
     1147The remaining switch namelist variables determine the spatial variation of the restoration coefficient in non-zoom configurations.  
     1148\np{ln\_full\_field} specifies that newtonian damping should be applied to the whole model domain.  
     1149\np{ln\_med\_red\_seas} specifies grid specific restoration coefficients in the Mediterranean Sea  
     1150for the ORCA4, ORCA2 and ORCA05 configurations.  
     1151If \np{ln\_old\_31\_lev\_code} is set then the depth variation of the coeffients will be specified as  
     1152a function of the model number. This option is included to allow backwards compatability of the ORCA2 reference  
     1153configurations with previous model versions.  
     1154\np{ln\_coast} specifies that the restoration coefficient should be reduced near to coastlines.  
     1155This option only has an effect if \np{ln\_full\_field} is true.  
     1156\np{ln\_zero\_top\_layer} specifies that the restoration coefficient should be zero in the surface layer.  
     1157Finally \np{ln\_custom} specifies that the custom module will be called.  
     1158This module is contained in the file custom.F90 and can be edited by users. For example damping could be applied in a specific region. 
     1159 
     1160The restoration coefficient can be set to zero in equatorial regions by specifying a positive value of \np{nn\_hdmp}.  
     1161Equatorward of this latitude the restoration coefficient will be zero with a smooth transition to  
     1162the full values of a 10\deg latitud band.  
     1163This is often used because of the short adjustment time scale in the equatorial region  
     1164\citep{Reverdin1991, Fujio1991, Marti_PhD92}. The time scale associated with the damping depends on the depth as a  
     1165hyperbolic tangent, with \np{rn\_surf} as surface value, \np{rn\_bot} as bottom value and a transition depth of \np{rn\_dep}.   
    11161166 
    11171167% ================================================================ 
     
    11671217%        Equation of State 
    11681218% ------------------------------------------------------------------------------------------------------------- 
    1169 \subsection{Equation of State (\np{nn\_eos} = 0, 1 or 2)} 
     1219\subsection{Equation Of Seawater (\np{nn\_eos} = -1, 0, or 1)} 
    11701220\label{TRA_eos} 
    11711221 
    1172 It is necessary to know the equation of state for the ocean very accurately  
    1173 to determine stability properties (especially the Brunt-Vais\"{a}l\"{a} frequency),  
    1174 particularly in the deep ocean. The ocean seawater volumic mass, $\rho$,  
    1175 abusively called density, is a non linear empirical function of \textit{in situ}  
    1176 temperature, salinity and pressure. The reference equation of state is that  
    1177 defined by the Joint Panel on Oceanographic Tables and Standards  
    1178 \citep{UNESCO1983}. It was the standard equation of state used in early  
    1179 releases of OPA. However, even though this computation is fully vectorised,  
    1180 it is quite time consuming ($15$ to $20${\%} of the total CPU time) since  
    1181 it requires the prior computation of the \textit{in situ} temperature from the  
    1182 model \textit{potential} temperature using the \citep{Bryden1973} polynomial  
    1183 for adiabatic lapse rate and a $4^th$ order Runge-Kutta integration scheme.  
    1184 Since OPA6, we have used the \citet{JackMcD1995} equation of state for  
    1185 seawater instead. It allows the computation of the \textit{in situ} ocean density  
    1186 directly as a function of \textit{potential} temperature relative to the surface  
    1187 (an \NEMO variable), the practical salinity (another \NEMO variable) and the  
    1188 pressure (assuming no pressure variation along geopotential surfaces, $i.e.$  
    1189 the pressure in decibars is approximated by the depth in meters).  
    1190 Both the \citet{UNESCO1983} and \citet{JackMcD1995} equations of state  
    1191 have exactly the same except that the values of the various coefficients have  
    1192 been adjusted by \citet{JackMcD1995} in order to directly use the \textit{potential}  
    1193 temperature instead of the \textit{in situ} one. This reduces the CPU time of the  
    1194 \textit{in situ} density computation to about $3${\%} of the total CPU time,  
    1195 while maintaining a quite accurate equation of state. 
    1196  
    1197 In the computer code, a \textit{true} density anomaly, $d_a= \rho / \rho_o - 1$,  
    1198 is computed, with $\rho_o$ a reference volumic mass. Called \textit{rau0}  
    1199 in the code, $\rho_o$ is defined in \mdl{phycst}, and a value of $1,035~Kg/m^3$.  
     1222The Equation Of Seawater (EOS) is an empirical nonlinear thermodynamic relationship  
     1223linking seawater density, $\rho$, to a number of state variables,  
     1224most typically temperature, salinity and pressure.  
     1225Because density gradients control the pressure gradient force through the hydrostatic balance,  
     1226the equation of state provides a fundamental bridge between the distribution of active tracers  
     1227and the fluid dynamics. Nonlinearities of the EOS are of major importance, in particular  
     1228influencing the circulation through determination of the static stability below the mixed layer,  
     1229thus controlling rates of exchange between the atmosphere  and the ocean interior \citep{Roquet_JPO2015}.  
     1230Therefore an accurate EOS based on either the 1980 equation of state (EOS-80, \cite{UNESCO1983})  
     1231or TEOS-10 \citep{TEOS10} standards should be used anytime a simulation of the real  
     1232ocean circulation is attempted \citep{Roquet_JPO2015}.  
     1233The use of TEOS-10 is highly recommended because  
     1234\textit{(i)} it is the new official EOS,  
     1235\textit{(ii)} it is more accurate, being based on an updated database of laboratory measurements, and  
     1236\textit{(iii)} it uses Conservative Temperature and Absolute Salinity (instead of potential temperature  
     1237and practical salinity for EOS-980, both variables being more suitable for use as model variables  
     1238\citep{TEOS10, Graham_McDougall_JPO13}.  
     1239EOS-80 is an obsolescent feature of the NEMO system, kept only for backward compatibility. 
     1240For process studies, it is often convenient to use an approximation of the EOS. To that purposed,  
     1241a simplified EOS (S-EOS) inspired by \citet{Vallis06} is also available. 
     1242 
     1243In the computer code, a density anomaly, $d_a= \rho / \rho_o - 1$,  
     1244is computed, with $\rho_o$ a reference density. Called \textit{rau0}  
     1245in the code, $\rho_o$ is set in \mdl{phycst} to a value of $1,026~Kg/m^3$.  
    12001246This is a sensible choice for the reference density used in a Boussinesq ocean  
    12011247climate model, as, with the exception of only a small percentage of the ocean,  
    1202 density in the World Ocean varies by no more than 2$\%$ from $1,035~kg/m^3$  
    1203 \citep{Gill1982}. 
    1204  
    1205 Options are defined through the  \ngn{nameos} namelist variables. 
    1206 The default option (namelist parameter \np{nn\_eos}=0) is the \citet{JackMcD1995}  
    1207 equation of state. Its use is highly recommended. However, for process studies,  
    1208 it is often convenient to use a linear approximation of the density. 
     1248density in the World Ocean varies by no more than 2$\%$ from that value \citep{Gill1982}. 
     1249 
     1250Options are defined through the  \ngn{nameos} namelist variables, and in particular \np{nn\_eos}  
     1251which controls the EOS used (=-1 for TEOS10 ; =0 for EOS-80 ; =1 for S-EOS). 
     1252\begin{description} 
     1253 
     1254\item[\np{nn\_eos}$=-1$] the polyTEOS10-bsq equation of seawater \citep{Roquet_OM2015} is used.   
     1255The accuracy of this approximation is comparable to the TEOS-10 rational function approximation,  
     1256but it is optimized for a boussinesq fluid and the polynomial expressions have simpler  
     1257and more computationally efficient expressions for their derived quantities  
     1258which make them more adapted for use in ocean models.  
     1259Note that a slightly higher precision polynomial form is now used replacement of the TEOS-10  
     1260rational function approximation for hydrographic data analysis  \citep{TEOS10}.  
     1261A key point is that conservative state variables are used:  
     1262Absolute Salinity (unit: g/kg, notation: $S_A$) and Conservative Temperature (unit: \degC, notation: $\Theta$). 
     1263The pressure in decibars is approximated by the depth in meters.  
     1264With TEOS10, the specific heat capacity of sea water, $C_p$, is a constant. It is set to  
     1265$C_p=3991.86795711963~J\,Kg^{-1}\,^{\circ}K^{-1}$, according to \citet{TEOS10}. 
     1266 
     1267Choosing polyTEOS10-bsq implies that the state variables used by the model are  
     1268$\Theta$ and $S_A$. In particular, the initial state deined by the user have to be given as  
     1269\textit{Conservative} Temperature and \textit{Absolute} Salinity.  
     1270In addition, setting \np{ln\_useCT} to \textit{true} convert the Conservative SST to potential SST  
     1271prior to either computing the air-sea and ice-sea fluxes (forced mode)  
     1272or sending the SST field to the atmosphere (coupled mode). 
     1273 
     1274\item[\np{nn\_eos}$=0$] the polyEOS80-bsq equation of seawater is used. 
     1275It takes the same polynomial form as the polyTEOS10, but the coefficients have been optimized  
     1276to accurately fit EOS80 (Roquet, personal comm.). The state variables used in both the EOS80  
     1277and the ocean model are:  
     1278the Practical Salinity ((unit: psu, notation: $S_p$)) and Potential Temperature (unit: $^{\circ}C$, notation: $\theta$). 
     1279The pressure in decibars is approximated by the depth in meters.   
     1280With thsi EOS, the specific heat capacity of sea water, $C_p$, is a function of temperature,  
     1281salinity and pressure \citep{UNESCO1983}. Nevertheless, a severe assumption is made in order to  
     1282have a heat content ($C_p T_p$) which is conserved by the model: $C_p$ is set to a constant  
     1283value, the TEOS10 value.  
     1284  
     1285\item[\np{nn\_eos}$=1$] a simplified EOS (S-EOS) inspired by \citet{Vallis06} is chosen,  
     1286the coefficients of which has been optimized to fit the behavior of TEOS10 (Roquet, personal comm.)  
     1287(see also \citet{Roquet_JPO2015}). It provides a simplistic linear representation of both  
     1288cabbeling and thermobaricity effects which is enough for a proper treatment of the EOS  
     1289in theoretical studies \citep{Roquet_JPO2015}. 
    12091290With such an equation of state there is no longer a distinction between  
    1210 \textit{in situ} and \textit{potential} density and both cabbeling and thermobaric 
    1211 effects are removed. 
    1212 Two linear formulations are available: a function of $T$ only (\np{nn\_eos}=1)  
    1213 and a function of both $T$ and $S$ (\np{nn\_eos}=2): 
    1214 \begin{equation} \label{Eq_tra_eos_linear} 
     1291\textit{conservative} and \textit{potential} temperature, as well as between \textit{absolute}  
     1292and \textit{practical} salinity. 
     1293S-EOS takes the following expression: 
     1294\begin{equation} \label{Eq_tra_S-EOS} 
    12151295\begin{split} 
    1216   d_a(T)       &=  \rho (T)      /  \rho_o   - 1     =  \  0.0285         -  \alpha   \;T     \\  
    1217   d_a(T,S)    &=  \rho (T,S)   /  \rho_o   - 1     =  \  \beta \; S       -  \alpha   \;T     
     1296  d_a(T,S,z)  =  ( & - a_0 \; ( 1 + 0.5 \; \lambda_1 \; T_a + \mu_1 \; z ) * T_a  \\ 
     1297                                & + b_0 \; ( 1 - 0.5 \; \lambda_2 \; S_a - \mu_2 \; z ) * S_a  \\ 
     1298                                & - \nu \; T_a \; S_a \;  ) \; / \; \rho_o                     \\ 
     1299  with \ \  T_a = T-10  \; ;  & \;  S_a = S-35  \; ;\;  \rho_o = 1026~Kg/m^3 
    12181300\end{split} 
    12191301\end{equation}  
    1220 where $\alpha$ and $\beta$ are the thermal and haline expansion  
    1221 coefficients, and $\rho_o$, the reference volumic mass, $rau0$.  
    1222 ($\alpha$ and $\beta$ can be modified through the \np{rn\_alpha} and  
    1223 \np{rn\_beta} namelist variables). Note that when $d_a$ is a function  
    1224 of $T$ only (\np{nn\_eos}=1), the salinity is a passive tracer and can be  
    1225 used as such. 
    1226  
    1227 % ------------------------------------------------------------------------------------------------------------- 
    1228 %        Brunt-Vais\"{a}l\"{a} Frequency 
    1229 % ------------------------------------------------------------------------------------------------------------- 
    1230 \subsection{Brunt-Vais\"{a}l\"{a} Frequency (\np{nn\_eos} = 0, 1 or 2)} 
     1302where the computer name of the coefficients as well as their standard value are given in \ref{Tab_SEOS}. 
     1303In fact, when choosing S-EOS, various approximation of EOS can be specified simply by changing  
     1304the associated coefficients.  
     1305Setting to zero the two thermobaric coefficients ($\mu_1$, $\mu_2$) remove thermobaric effect from S-EOS. 
     1306setting to zero the three cabbeling coefficients ($\lambda_1$, $\lambda_2$, $\nu$) remove cabbeling effect from S-EOS. 
     1307Keeping non-zero value to $a_0$ and $b_0$ provide a linear EOS function of T and S. 
     1308 
     1309\end{description} 
     1310 
     1311 
     1312%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     1313\begin{table}[!tb] 
     1314\begin{center} \begin{tabular}{|p{26pt}|p{72pt}|p{56pt}|p{136pt}|} 
     1315\hline 
     1316coeff.   & computer name   & S-EOS     &  description                      \\ \hline 
     1317$a_0$       & \np{rn\_a0}     & 1.6550 $10^{-1}$ &  linear thermal expansion coeff.    \\ \hline 
     1318$b_0$       & \np{rn\_b0}     & 7.6554 $10^{-1}$ &  linear haline  expansion coeff.    \\ \hline 
     1319$\lambda_1$ & \np{rn\_lambda1}& 5.9520 $10^{-2}$ &  cabbeling coeff. in $T^2$          \\ \hline 
     1320$\lambda_2$ & \np{rn\_lambda2}& 5.4914 $10^{-4}$ &  cabbeling coeff. in $S^2$       \\ \hline 
     1321$\nu$       & \np{rn\_nu}     & 2.4341 $10^{-3}$ &  cabbeling coeff. in $T \, S$       \\ \hline 
     1322$\mu_1$     & \np{rn\_mu1}    & 1.4970 $10^{-4}$ &  thermobaric coeff. in T         \\ \hline 
     1323$\mu_2$     & \np{rn\_mu2}    & 1.1090 $10^{-5}$ &  thermobaric coeff. in S            \\ \hline 
     1324\end{tabular} 
     1325\caption{ \label{Tab_SEOS} 
     1326Standard value of S-EOS coefficients. } 
     1327\end{center} 
     1328\end{table} 
     1329%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
     1330 
     1331 
     1332% ------------------------------------------------------------------------------------------------------------- 
     1333%        Brunt-V\"{a}is\"{a}l\"{a} Frequency 
     1334% ------------------------------------------------------------------------------------------------------------- 
     1335\subsection{Brunt-V\"{a}is\"{a}l\"{a} Frequency (\np{nn\_eos} = 0, 1 or 2)} 
    12311336\label{TRA_bn2} 
    12321337 
    1233 An accurate computation of the ocean stability (i.e. of $N$, the brunt-Vais\"{a}l\"{a} 
    1234  frequency) is of paramount importance as it is used in several ocean  
    1235  parameterisations (namely TKE, KPP, Richardson number dependent  
    1236  vertical diffusion, enhanced vertical diffusion, non-penetrative convection,  
    1237  iso-neutral diffusion). In particular, one must be aware that $N^2$ has to  
    1238  be computed with an \textit{in situ} reference. The expression for $N^2$  
    1239  depends on the type of equation of state used (\np{nn\_eos} namelist parameter). 
    1240  
    1241 For \np{nn\_eos}=0 (\citet{JackMcD1995} equation of state), the \citet{McDougall1987}  
    1242 polynomial expression is used (with the pressure in decibar approximated by  
    1243 the depth in meters):  
     1338An accurate computation of the ocean stability (i.e. of $N$, the brunt-V\"{a}is\"{a}l\"{a} 
     1339 frequency) is of paramount importance as determine the ocean stratification and  
     1340 is used in several ocean parameterisations (namely TKE, GLS, Richardson number dependent  
     1341 vertical diffusion, enhanced vertical diffusion, non-penetrative convection, tidal mixing  
     1342 parameterisation, iso-neutral diffusion). In particular, $N^2$ has to be computed at the local pressure  
     1343 (pressure in decibar being approximated by the depth in meters). The expression for $N^2$  
     1344 is given by:  
    12441345\begin{equation} \label{Eq_tra_bn2} 
    1245 N^2 = \frac{g}{e_{3w}} \; \beta   \  
    1246       \left(  \alpha / \beta \ \delta_{k+1/2}[T]     - \delta_{k+1/2}[S]   \right)  
    1247 \end{equation}  
    1248 where $\alpha$ and $\beta$ are the thermal and haline expansion coefficients.  
    1249 They are a function of  $\overline{T}^{\,k+1/2},\widetilde{S}=\overline{S}^{\,k+1/2} - 35.$,  
    1250 and  $z_w$, with $T$ the \textit{potential} temperature and $\widetilde{S}$ a salinity anomaly.  
    1251 Note that both $\alpha$ and $\beta$ depend on \textit{potential}  
    1252 temperature and salinity which are averaged at $w$-points prior  
    1253 to the computation instead of being computed at $T$-points and  
    1254 then averaged to $w$-points. 
    1255  
    1256 When a linear equation of state is used (\np{nn\_eos}=1 or 2,  
    1257 \eqref{Eq_tra_bn2} reduces to: 
    1258 \begin{equation} \label{Eq_tra_bn2_linear} 
    12591346N^2 = \frac{g}{e_{3w}} \left(   \beta \;\delta_{k+1/2}[S] - \alpha \;\delta_{k+1/2}[T]   \right) 
    12601347\end{equation}  
    1261 where $\alpha$ and $\beta $ are the constant coefficients used to  
    1262 defined the linear equation of state \eqref{Eq_tra_eos_linear}. 
    1263  
    1264 % ------------------------------------------------------------------------------------------------------------- 
    1265 %        Specific Heat 
    1266 % ------------------------------------------------------------------------------------------------------------- 
    1267 \subsection    [Specific Heat (\textit{phycst})] 
    1268          {Specific Heat (\mdl{phycst})} 
    1269 \label{TRA_adv_ldf} 
    1270  
    1271 The specific heat of sea water, $C_p$, is a function of temperature, salinity  
    1272 and pressure \citep{UNESCO1983}. It is only used in the model to convert  
    1273 surface heat fluxes into surface temperature increase and so the pressure  
    1274 dependence is neglected. The dependence on $T$ and $S$ is weak.  
    1275 For example, with $S=35~psu$, $C_p$ increases from $3989$ to $4002$  
    1276 when $T$ varies from -2~\degres C to 31~\degres C. Therefore, $C_p$ has  
    1277 been chosen as a constant: $C_p=4.10^3~J\,Kg^{-1}\,\degres K^{-1}$.  
    1278 Its value is set in \mdl{phycst} module.  
    1279  
     1348where $(T,S) = (\Theta, S_A)$ for TEOS10, $= (\theta, S_p)$ for TEOS-80, or $=(T,S)$ for S-EOS,  
     1349and, $\alpha$ and $\beta$ are the thermal and haline expansion coefficients.  
     1350The coefficients are a polynomial function of temperature, salinity and depth which expression  
     1351depends on the chosen EOS. They are computed through \textit{eos\_rab}, a \textsc{Fortran}  
     1352function that can be found in \mdl{eosbn2}. 
    12801353 
    12811354% ------------------------------------------------------------------------------------------------------------- 
     
    12981371sea water ($i.e.$ referenced to the surface $p=0$), thus the pressure dependent  
    12991372terms in \eqref{Eq_tra_eos_fzp} (last term) have been dropped. The freezing 
    1300 point is computed through \textit{tfreez}, a \textsc{Fortran} function that can be found  
     1373point is computed through \textit{eos\_fzp}, a \textsc{Fortran} function that can be found  
    13011374in \mdl{eosbn2}.   
     1375 
     1376 
     1377% ------------------------------------------------------------------------------------------------------------- 
     1378%        Potential Energy      
     1379% ------------------------------------------------------------------------------------------------------------- 
     1380%\subsection{Potential Energy anomalies} 
     1381%\label{TRA_bn2} 
     1382 
     1383%    =====>>>>> TO BE written 
     1384% 
     1385 
    13021386 
    13031387% ================================================================ 
     
    13081392\label{TRA_zpshde} 
    13091393 
    1310 \gmcomment{STEVEN: to be consistent with earlier discussion of differencing and averaging operators, I've changed "derivative" to "difference" and "mean" to "average"} 
    1311  
    1312 With partial bottom cells (\np{ln\_zps}=true), in general, tracers in horizontally  
    1313 adjacent cells live at different depths. Horizontal gradients of tracers are needed  
    1314 for horizontal diffusion (\mdl{traldf} module) and for the hydrostatic pressure  
    1315 gradient (\mdl{dynhpg} module) to be active.  
    1316 \gmcomment{STEVEN from gm : question: not sure of  what -to be active- means} 
     1394\gmcomment{STEVEN: to be consistent with earlier discussion of differencing and averaging operators,  
     1395                   I've changed "derivative" to "difference" and "mean" to "average"} 
     1396 
     1397With partial cells (\np{ln\_zps}=true) at bottom and top (\np{ln\_isfcav}=true), in general,  
     1398tracers in horizontally adjacent cells live at different depths.  
     1399Horizontal gradients of tracers are needed for horizontal diffusion (\mdl{traldf} module)  
     1400and the hydrostatic pressure gradient calculations (\mdl{dynhpg} module).  
     1401The partial cell properties at the top (\np{ln\_isfcav}=true) are computed in the same way as for the bottom.  
     1402So, only the bottom interpolation is explained below. 
     1403 
    13171404Before taking horizontal gradients between the tracers next to the bottom, a linear  
    13181405interpolation in the vertical is used to approximate the deeper tracer as if it actually  
     
    13231410%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    13241411\begin{figure}[!p]    \begin{center} 
    1325 \includegraphics[width=0.9\textwidth]{./TexFiles/Figures/Partial_step_scheme.pdf} 
     1412\includegraphics[width=0.9\textwidth]{Partial_step_scheme} 
    13261413\caption{   \label{Fig_Partial_step_scheme}  
    13271414Discretisation of the horizontal difference and average of tracers in the $z$-partial  
     
    13901477\gmcomment{gm :   this last remark has to be done} 
    13911478%%% 
     1479\end{document} 
Note: See TracChangeset for help on using the changeset viewer.