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 11512 for NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/doc/latex/NEMO/subfiles/chap_DYN.tex – NEMO

Ignore:
Timestamp:
2019-09-09T12:05:20+02:00 (5 years ago)
Author:
smasson
Message:

dev_r10984_HPC-13 : merge with trunk@11511, see #2285

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/dev_r10984_HPC-13_IRRMANN_BDY_optimization/doc/latex/NEMO/subfiles/chap_DYN.tex

    r11263 r11512  
    88\label{chap:DYN} 
    99 
    10 \minitoc 
     10\chaptertoc 
    1111 
    1212Using the representation described in \autoref{chap:DOM}, 
     
    3636(surface wind stress calculation using bulk formulae, estimation of mixing coefficients) 
    3737that are carried out in modules SBC, LDF and ZDF and are described in 
    38 \autoref{chap:SBC}, \autoref{chap:LDF} and \autoref{chap:ZDF}, respectively.  
     38\autoref{chap:SBC}, \autoref{chap:LDF} and \autoref{chap:ZDF}, respectively. 
    3939 
    4040In the present chapter we also describe the diagnostic equations used to compute the horizontal divergence, 
    4141curl of the velocities (\emph{divcur} module) and the vertical velocity (\emph{wzvmod} module). 
    4242 
    43 The different options available to the user are managed by namelist variables.  
    44 For term \textit{ttt} in the momentum equations, the logical namelist variables are \textit{ln\_dynttt\_xxx},  
     43The different options available to the user are managed by namelist variables. 
     44For term \textit{ttt} in the momentum equations, the logical namelist variables are \textit{ln\_dynttt\_xxx}, 
    4545where \textit{xxx} is a 3 or 4 letter acronym corresponding to each optional scheme. 
    46 If a CPP key is used for this term its name is \key{ttt}. 
     46%If a CPP key is used for this term its name is \key{ttt}. 
    4747The corresponding code can be found in the \textit{dynttt\_xxx} module in the DYN directory, 
    4848and it is usually computed in the \textit{dyn\_ttt\_xxx} subroutine. 
    4949 
    5050The user has the option of extracting and outputting each tendency term from the 3D momentum equations 
    51 (\key{trddyn} defined), as described in \autoref{chap:MISC}. 
    52 Furthermore, the tendency terms associated with the 2D barotropic vorticity balance (when \key{trdvor} is defined) 
     51(\texttt{trddyn?} defined), as described in \autoref{chap:MISC}. 
     52Furthermore, the tendency terms associated with the 2D barotropic vorticity balance (when \texttt{trdvor?} is defined) 
    5353can be derived from the 3D terms. 
    5454%%% 
    55 \gmcomment{STEVEN: not quite sure I've got the sense of the last sentence. does  
     55\gmcomment{STEVEN: not quite sure I've got the sense of the last sentence. does 
    5656MISC correspond to "extracting tendency terms" or "vorticity balance"?} 
    5757 
     
    6969\label{subsec:DYN_divcur} 
    7070 
    71 The vorticity is defined at an $f$-point (\ie corner point) as follows: 
     71The vorticity is defined at an $f$-point (\ie\ corner point) as follows: 
    7272\begin{equation} 
    7373  \label{eq:divcur_cur} 
    7474  \zeta =\frac{1}{e_{1f}\,e_{2f} }\left( {\;\delta_{i+1/2} \left[ {e_{2v}\;v} \right] 
    7575      -\delta_{j+1/2} \left[ {e_{1u}\;u} \right]\;} \right) 
    76 \end{equation}  
     76\end{equation} 
    7777 
    7878The horizontal divergence is defined at a $T$-point. 
     
    9797ensure perfect restartability. 
    9898The vorticity and divergence at the \textit{now} time step are used for the computation of 
    99 the nonlinear advection and of the vertical velocity respectively.  
     99the nonlinear advection and of the vertical velocity respectively. 
    100100 
    101101%-------------------------------------------------------------------------------------------------------------- 
     
    117117  \end{aligned} 
    118118\end{equation} 
    119 where \textit{emp} is the surface freshwater budget (evaporation minus precipitation),  
     119where \textit{emp} is the surface freshwater budget (evaporation minus precipitation), 
    120120expressed in Kg/m$^2$/s (which is equal to mm/s), 
    121121and $\rho_w$=1,035~Kg/m$^3$ is the reference density of sea water (Boussinesq approximation). 
    122122If river runoff is expressed as a surface freshwater flux (see \autoref{chap:SBC}) then 
    123 \textit{emp} can be written as the evaporation minus precipitation, minus the river runoff.  
     123\textit{emp} can be written as the evaporation minus precipitation, minus the river runoff. 
    124124The sea-surface height is evaluated using exactly the same time stepping scheme as 
    125125the tracer equation \autoref{eq:tra_nxt}: 
    126126a leapfrog scheme in combination with an Asselin time filter, 
    127 \ie the velocity appearing in \autoref{eq:dynspg_ssh} is centred in time (\textit{now} velocity). 
     127\ie\ the velocity appearing in \autoref{eq:dynspg_ssh} is centred in time (\textit{now} velocity). 
    128128This is of paramount importance. 
    129129Replacing $T$ by the number $1$ in the tracer equation and summing over the water column must lead to 
     
    144144\end{equation} 
    145145 
    146 In the case of a non-linear free surface (\key{vvl}), the top vertical velocity is $-\textit{emp}/\rho_w$,  
     146In the case of a non-linear free surface (\texttt{vvl?}), the top vertical velocity is $-\textit{emp}/\rho_w$, 
    147147as changes in the divergence of the barotropic transport are absorbed into the change of the level thicknesses, 
    148148re-orientated downward. 
     
    151151The upper boundary condition applies at a fixed level $z=0$. 
    152152The top vertical velocity is thus equal to the divergence of the barotropic transport 
    153 (\ie the first term in the right-hand-side of \autoref{eq:dynspg_ssh}). 
     153(\ie\ the first term in the right-hand-side of \autoref{eq:dynspg_ssh}). 
    154154 
    155155Note also that whereas the vertical velocity has the same discrete expression in $z$- and $s$-coordinates, 
     
    158158Note also that the $k$-axis is re-orientated downwards in the \fortran code compared to 
    159159the indexing used in the semi-discrete equations such as \autoref{eq:wzv} 
    160 (see \autoref{subsec:DOM_Num_Index_vertical}).  
     160(see \autoref{subsec:DOM_Num_Index_vertical}). 
    161161 
    162162 
     
    168168%-----------------------------------------nam_dynadv---------------------------------------------------- 
    169169 
    170 \nlst{namdyn_adv}  
     170\nlst{namdyn_adv} 
    171171%------------------------------------------------------------------------------------------------------------- 
    172172 
    173173The vector invariant form of the momentum equations is the one most often used in 
    174 applications of the \NEMO ocean model. 
     174applications of the \NEMO\ ocean model. 
    175175The flux form option (see next section) has been present since version $2$. 
    176 Options are defined through the \ngn{namdyn\_adv} namelist variables Coriolis and 
     176Options are defined through the \nam{dyn\_adv} namelist variables Coriolis and 
    177177momentum advection terms are evaluated using a leapfrog scheme, 
    178 \ie the velocity appearing in these expressions is centred in time (\textit{now} velocity).  
     178\ie\ the velocity appearing in these expressions is centred in time (\textit{now} velocity). 
    179179At the lateral boundaries either free slip, no slip or partial slip boundary conditions are applied following 
    180180\autoref{chap:LBC}. 
    181181 
    182182% ------------------------------------------------------------------------------------------------------------- 
    183 %        Vorticity term  
     183%        Vorticity term 
    184184% ------------------------------------------------------------------------------------------------------------- 
    185185\subsection[Vorticity term (\textit{dynvor.F90})] 
     
    188188%------------------------------------------nam_dynvor---------------------------------------------------- 
    189189 
    190 \nlst{namdyn_vor}  
     190\nlst{namdyn_vor} 
    191191%------------------------------------------------------------------------------------------------------------- 
    192192 
    193 Options are defined through the \ngn{namdyn\_vor} namelist variables. 
    194 Four discretisations of the vorticity term (\np{ln\_dynvor\_xxx}\forcode{ = .true.}) are available: 
     193Options are defined through the \nam{dyn\_vor} namelist variables. 
     194Four discretisations of the vorticity term (\texttt{ln\_dynvor\_xxx}\forcode{ = .true.}) are available: 
    195195conserving potential enstrophy of horizontally non-divergent flow (ENS scheme); 
    196196conserving horizontal kinetic energy (ENE scheme); 
     
    212212In the enstrophy conserving case (ENS scheme), 
    213213the discrete formulation of the vorticity term provides a global conservation of the enstrophy 
    214 ($ [ (\zeta +f ) / e_{3f} ]^2 $ in $s$-coordinates) for a horizontally non-divergent flow (\ie $\chi$=$0$), 
     214($ [ (\zeta +f ) / e_{3f} ]^2 $ in $s$-coordinates) for a horizontally non-divergent flow (\ie\ $\chi$=$0$), 
    215215but does not conserve the total kinetic energy. 
    216216It is given by: 
     
    225225    \end{aligned} 
    226226  \right. 
    227 \end{equation}  
     227\end{equation} 
    228228 
    229229%------------------------------------------------------------- 
     
    246246    \end{aligned} 
    247247  \right. 
    248 \end{equation}  
     248\end{equation} 
    249249 
    250250%------------------------------------------------------------- 
     
    285285the presence of grid point oscillation structures that will be invisible to the operator. 
    286286These structures are \textit{computational modes} that will be at least partly damped by 
    287 the momentum diffusion operator (\ie the subgrid-scale advection), but not by the resolved advection term. 
     287the momentum diffusion operator (\ie\ the subgrid-scale advection), but not by the resolved advection term. 
    288288The ENS and ENE schemes therefore do not contribute to dump any grid point noise in the horizontal velocity field. 
    289289Such noise would result in more noise in the vertical velocity field, an undesirable feature. 
     
    291291$u$ and $v$ are located at different grid points, 
    292292a price worth paying to avoid a double averaging in the pressure gradient term as in the $B$-grid. 
    293 \gmcomment{ To circumvent this, Adcroft (ADD REF HERE)  
     293\gmcomment{ To circumvent this, Adcroft (ADD REF HERE) 
    294294Nevertheless, this technique strongly distort the phase and group velocity of Rossby waves....} 
    295295 
     
    299299\citep{griffies.gnanadesikan.ea_JPO98} for the discretization of the iso-neutral diffusion operator (see \autoref{apdx:C}). 
    300300 
    301 The \citet{arakawa.hsu_MWR90} vorticity advection scheme for a single layer is modified  
    302 for spherical coordinates as described by \citet{arakawa.lamb_MWR81} to obtain the EEN scheme.  
    303 First consider the discrete expression of the potential vorticity, $q$, defined at an $f$-point:  
     301The \citet{arakawa.hsu_MWR90} vorticity advection scheme for a single layer is modified 
     302for spherical coordinates as described by \citet{arakawa.lamb_MWR81} to obtain the EEN scheme. 
     303First consider the discrete expression of the potential vorticity, $q$, defined at an $f$-point: 
    304304\[ 
    305305  % \label{eq:pot_vor} 
     
    307307\] 
    308308where the relative vorticity is defined by (\autoref{eq:divcur_cur}), 
    309 the Coriolis parameter is given by $f=2 \,\Omega \;\sin \varphi _f $ and the layer thickness at $f$-points is:  
     309the Coriolis parameter is given by $f=2 \,\Omega \;\sin \varphi _f $ and the layer thickness at $f$-points is: 
    310310\begin{equation} 
    311311  \label{eq:een_e3f} 
     
    326326% >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    327327 
    328 A key point in \autoref{eq:een_e3f} is how the averaging in the \textbf{i}- and \textbf{j}- directions is made.  
     328A key point in \autoref{eq:een_e3f} is how the averaging in the \textbf{i}- and \textbf{j}- directions is made. 
    329329It uses the sum of masked t-point vertical scale factor divided either by the sum of the four t-point masks 
    330330(\np{nn\_een\_e3f}\forcode{ = 1}), or just by $4$ (\np{nn\_een\_e3f}\forcode{ = .true.}). 
     
    334334(with a systematic reduction of $e_{3f}$ when a model level intercept the bathymetry) 
    335335that tends to reinforce the topostrophy of the flow 
    336 (\ie the tendency of the flow to follow the isobaths) \citep{penduff.le-sommer.ea_OS07}.  
     336(\ie\ the tendency of the flow to follow the isobaths) \citep{penduff.le-sommer.ea_OS07}. 
    337337 
    338338Next, the vorticity triads, $ {^i_j}\mathbb{Q}^{i_p}_{j_p}$ can be defined at a $T$-point as 
    339339the following triad combinations of the neighbouring potential vorticities defined at f-points 
    340 (\autoref{fig:DYN_een_triad}):  
     340(\autoref{fig:DYN_een_triad}): 
    341341\begin{equation} 
    342342  \label{eq:Q_triads} 
     
    344344  = \frac{1}{12} \ \left(   q^{i-i_p}_{j+j_p} + q^{i+j_p}_{j+i_p} + q^{i+i_p}_{j-j_p}  \right) 
    345345\end{equation} 
    346 where the indices $i_p$ and $k_p$ take the values: $i_p = -1/2$ or $1/2$ and $j_p = -1/2$ or $1/2$.  
    347  
    348 Finally, the vorticity terms are represented as:  
     346where the indices $i_p$ and $k_p$ take the values: $i_p = -1/2$ or $1/2$ and $j_p = -1/2$ or $1/2$. 
     347 
     348Finally, the vorticity terms are represented as: 
    349349\begin{equation} 
    350350  \label{eq:dynvor_een} 
     
    357357      \end{aligned} 
    358358    } \right. 
    359 \end{equation}  
     359\end{equation} 
    360360 
    361361This EEN scheme in fact combines the conservation properties of the ENS and ENE schemes. 
    362362It conserves both total energy and potential enstrophy in the limit of horizontally nondivergent flow 
    363 (\ie $\chi$=$0$) (see \autoref{subsec:C_vorEEN}).  
     363(\ie\ $\chi$=$0$) (see \autoref{subsec:C_vorEEN}). 
    364364Applied to a realistic ocean configuration, it has been shown that it leads to a significant reduction of 
    365365the noise in the vertical velocity field \citep{le-sommer.penduff.ea_OM09}. 
    366366Furthermore, used in combination with a partial steps representation of bottom topography, 
    367367it improves the interaction between current and topography, 
    368 leading to a larger topostrophy of the flow \citep{barnier.madec.ea_OD06, penduff.le-sommer.ea_OS07}.  
     368leading to a larger topostrophy of the flow \citep{barnier.madec.ea_OD06, penduff.le-sommer.ea_OS07}. 
    369369 
    370370%-------------------------------------------------------------------------------------------------------------- 
     
    412412When \np{ln\_dynzad\_zts}\forcode{ = .true.}, 
    413413a split-explicit time stepping with 5 sub-timesteps is used on the vertical advection term. 
    414 This option can be useful when the value of the timestep is limited by vertical advection \citep{lemarie.debreu.ea_OM15}.  
     414This option can be useful when the value of the timestep is limited by vertical advection \citep{lemarie.debreu.ea_OM15}. 
    415415Note that in this case, 
    416416a similar split-explicit time stepping should be used on vertical advection of tracer to ensure a better stability, 
     
    425425%------------------------------------------nam_dynadv---------------------------------------------------- 
    426426 
    427 \nlst{namdyn_adv}  
     427\nlst{namdyn_adv} 
    428428%------------------------------------------------------------------------------------------------------------- 
    429429 
    430 Options are defined through the \ngn{namdyn\_adv} namelist variables. 
     430Options are defined through the \nam{dyn\_adv} namelist variables. 
    431431In the flux form (as in the vector invariant form), 
    432432the Coriolis and momentum advection terms are evaluated using a leapfrog scheme, 
    433 \ie the velocity appearing in their expressions is centred in time (\textit{now} velocity). 
     433\ie\ the velocity appearing in their expressions is centred in time (\textit{now} velocity). 
    434434At the lateral boundaries either free slip, 
    435435no slip or partial slip boundary conditions are applied following \autoref{chap:LBC}. 
     
    445445In flux form, the vorticity term reduces to a Coriolis term in which the Coriolis parameter has been modified to account for the "metric" term. 
    446446This altered Coriolis parameter is thus discretised at $f$-points. 
    447 It is given by:  
     447It is given by: 
    448448\begin{multline*} 
    449449  % \label{eq:dyncor_metric} 
     
    451451  \equiv   f + \frac{1}{e_{1f} e_{2f} } \left( { \ \overline v ^{i+1/2}\delta_{i+1/2} \left[ {e_{2u} } \right] 
    452452      -  \overline u ^{j+1/2}\delta_{j+1/2} \left[ {e_{1u} } \right]  }  \ \right) 
    453 \end{multline*}  
     453\end{multline*} 
    454454 
    455455Any of the (\autoref{eq:dynvor_ens}), (\autoref{eq:dynvor_ene}) and (\autoref{eq:dynvor_een}) schemes can be used to 
    456456compute the product of the Coriolis parameter and the vorticity. 
    457457However, the energy-conserving scheme (\autoref{eq:dynvor_een}) has exclusively been used to date. 
    458 This term is evaluated using a leapfrog scheme, \ie the velocity is centred in time (\textit{now} velocity). 
     458This term is evaluated using a leapfrog scheme, \ie\ the velocity is centred in time (\textit{now} velocity). 
    459459 
    460460%-------------------------------------------------------------------------------------------------------------- 
     
    487487or a $3^{rd}$ order upstream biased scheme, UBS. 
    488488The latter is described in \citet{shchepetkin.mcwilliams_OM05}. 
    489 The schemes are selected using the namelist logicals \np{ln\_dynadv\_cen2} and \np{ln\_dynadv\_ubs}.  
     489The schemes are selected using the namelist logicals \np{ln\_dynadv\_cen2} and \np{ln\_dynadv\_ubs}. 
    490490In flux form, the schemes differ by the choice of a space and time interpolation to define the value of 
    491 $u$ and $v$ at the centre of each face of $u$- and $v$-cells, \ie at the $T$-, $f$-, 
    492 and $uw$-points for $u$ and at the $f$-, $T$- and $vw$-points for $v$.  
     491$u$ and $v$ at the centre of each face of $u$- and $v$-cells, \ie\ at the $T$-, $f$-, 
     492and $uw$-points for $u$ and at the $f$-, $T$- and $vw$-points for $v$. 
    493493 
    494494%------------------------------------------------------------- 
     
    508508    \end{aligned} 
    509509  \right. 
    510 \end{equation}  
    511  
    512 The scheme is non diffusive (\ie conserves the kinetic energy) but dispersive (\ie it may create false extrema). 
     510\end{equation} 
     511 
     512The scheme is non diffusive (\ie\ conserves the kinetic energy) but dispersive (\ie\ it may create false extrema). 
    513513It is therefore notoriously noisy and must be used in conjunction with an explicit diffusion operator to 
    514514produce a sensible solution. 
     
    535535\end{equation} 
    536536where $u"_{i+1/2} =\delta_{i+1/2} \left[ {\delta_i \left[ u \right]} \right]$. 
    537 This results in a dissipatively dominant (\ie hyper-diffusive) truncation error 
     537This results in a dissipatively dominant (\ie\ hyper-diffusive) truncation error 
    538538\citep{shchepetkin.mcwilliams_OM05}. 
    539539The overall performance of the advection scheme is similar to that reported in \citet{farrow.stevens_JPO95}. 
     
    541541It is not a \emph{positive} scheme, meaning that false extrema are permitted. 
    542542But the amplitudes of the false extrema are significantly reduced over those in the centred second order method. 
    543 As the scheme already includes a diffusion component, it can be used without explicit lateral diffusion on momentum  
    544 (\ie \np{ln\_dynldf\_lap}\forcode{ = }\np{ln\_dynldf\_bilap}\forcode{ = .false.}), 
     543As the scheme already includes a diffusion component, it can be used without explicit lateral diffusion on momentum 
     544(\ie\ \np{ln\_dynldf\_lap}\forcode{ = }\np{ln\_dynldf\_bilap}\forcode{ = .false.}), 
    545545and it is recommended to do so. 
    546546 
    547547The UBS scheme is not used in all directions. 
    548 In the vertical, the centred $2^{nd}$ order evaluation of the advection is preferred, \ie $u_{uw}^{ubs}$ and 
     548In the vertical, the centred $2^{nd}$ order evaluation of the advection is preferred, \ie\ $u_{uw}^{ubs}$ and 
    549549$u_{vw}^{ubs}$ in \autoref{eq:dynadv_cen2} are used. 
    550 UBS is diffusive and is associated with vertical mixing of momentum. \gmcomment{ gm  pursue the  
     550UBS is diffusive and is associated with vertical mixing of momentum. \gmcomment{ gm  pursue the 
    551551sentence:Since vertical mixing of momentum is a source term of the TKE equation...  } 
    552552 
     
    578578%------------------------------------------nam_dynhpg--------------------------------------------------- 
    579579 
    580 \nlst{namdyn_hpg}  
     580\nlst{namdyn_hpg} 
    581581%------------------------------------------------------------------------------------------------------------- 
    582582 
    583 Options are defined through the \ngn{namdyn\_hpg} namelist variables. 
     583Options are defined through the \nam{dyn\_hpg} namelist variables. 
    584584The key distinction between the different algorithms used for 
    585585the hydrostatic pressure gradient is the vertical coordinate used, 
    586 since HPG is a \emph{horizontal} pressure gradient, \ie computed along geopotential surfaces. 
     586since HPG is a \emph{horizontal} pressure gradient, \ie\ computed along geopotential surfaces. 
    587587As a result, any tilt of the surface of the computational levels will require a specific treatment to 
    588588compute the hydrostatic pressure gradient. 
    589589 
    590590The hydrostatic pressure gradient term is evaluated either using a leapfrog scheme, 
    591 \ie the density appearing in its expression is centred in time (\emph{now} $\rho$), 
     591\ie\ the density appearing in its expression is centred in time (\emph{now} $\rho$), 
    592592or a semi-implcit scheme. 
    593593At the lateral boundaries either free slip, no slip or partial slip boundary conditions are applied. 
     
    616616    \end{aligned} 
    617617  \right. 
    618 \end{equation}  
     618\end{equation} 
    619619 
    620620for $1<k<km$ (interior layer) 
     
    631631    \end{aligned} 
    632632  \right. 
    633 \end{equation}  
     633\end{equation} 
    634634 
    635635Note that the $1/2$ factor in (\autoref{eq:dynhpg_zco_surf}) is adequate because of the definition of $e_{3w}$ as 
    636636the vertical derivative of the scale factor at the surface level ($z=0$). 
    637 Note also that in case of variable volume level (\key{vvl} defined), 
     637Note also that in case of variable volume level (\texttt{vvl?} defined), 
    638638the surface pressure gradient is included in \autoref{eq:dynhpg_zco_surf} and 
    639639\autoref{eq:dynhpg_zco} through the space and time variations of the vertical scale factor $e_{3w}$. 
     
    649649Before taking horizontal gradients between these tracer points, 
    650650a linear interpolation is used to approximate the deeper tracer as if 
    651 it actually lived at the depth of the shallower tracer point.  
     651it actually lived at the depth of the shallower tracer point. 
    652652 
    653653Apart from this modification, 
     
    668668 
    669669Pressure gradient formulations in an $s$-coordinate have been the subject of a vast number of papers 
    670 (\eg, \citet{song_MWR98, shchepetkin.mcwilliams_OM05}).  
     670(\eg, \citet{song_MWR98, shchepetkin.mcwilliams_OM05}). 
    671671A number of different pressure gradient options are coded but the ROMS-like, 
    672672density Jacobian with cubic polynomial method is currently disabled whilst known bugs are under investigation. 
     
    683683    \end{aligned} 
    684684  \right. 
    685 \end{equation}  
     685\end{equation} 
    686686 
    687687Where the first term is the pressure gradient along coordinates, 
    688688computed as in \autoref{eq:dynhpg_zco_surf} - \autoref{eq:dynhpg_zco}, 
    689 and $z_T$ is the depth of the $T$-point evaluated from the sum of the vertical scale factors at the $w$-point  
     689and $z_T$ is the depth of the $T$-point evaluated from the sum of the vertical scale factors at the $w$-point 
    690690($e_{3w}$). 
    691   
     691 
    692692$\bullet$ Traditional coding with adaptation for ice shelf cavities (\np{ln\_dynhpg\_isf}\forcode{ = .true.}). 
    693693This scheme need the activation of ice shelf cavities (\np{ln\_isfcav}\forcode{ = .true.}). 
     
    695695$\bullet$ Pressure Jacobian scheme (prj) (a research paper in preparation) (\np{ln\_dynhpg\_prj}\forcode{ = .true.}) 
    696696 
    697 $\bullet$ Density Jacobian with cubic polynomial scheme (DJC) \citep{shchepetkin.mcwilliams_OM05}  
     697$\bullet$ Density Jacobian with cubic polynomial scheme (DJC) \citep{shchepetkin.mcwilliams_OM05} 
    698698(\np{ln\_dynhpg\_djc}\forcode{ = .true.}) (currently disabled; under development) 
    699699 
    700700Note that expression \autoref{eq:dynhpg_sco} is commonly used when the variable volume formulation is activated 
    701 (\key{vvl}) because in that case, even with a flat bottom, 
     701(\texttt{vvl?}) because in that case, even with a flat bottom, 
    702702the coordinate surfaces are not horizontal but follow the free surface \citep{levier.treguier.ea_rpt07}. 
    703703The pressure jacobian scheme (\np{ln\_dynhpg\_prj}\forcode{ = .true.}) is available as 
    704 an improved option to \np{ln\_dynhpg\_sco}\forcode{ = .true.} when \key{vvl} is active. 
     704an improved option to \np{ln\_dynhpg\_sco}\forcode{ = .true.} when \texttt{vvl?} is active. 
    705705The pressure Jacobian scheme uses a constrained cubic spline to 
    706706reconstruct the density profile across the water column. 
     
    723723 
    724724The pressure gradient due to ocean load is computed using the expression \autoref{eq:dynhpg_sco} described in 
    725 \autoref{subsec:DYN_hpg_sco}.  
     725\autoref{subsec:DYN_hpg_sco}. 
    726726 
    727727%-------------------------------------------------------------------------------------------------------------- 
     
    742742It involves the evaluation of the hydrostatic pressure gradient as 
    743743an average over the three time levels $t-\rdt$, $t$, and $t+\rdt$ 
    744 (\ie \textit{before}, \textit{now} and  \textit{after} time-steps), 
    745 rather than at the central time level $t$ only, as in the standard leapfrog scheme.  
     744(\ie\ \textit{before}, \textit{now} and  \textit{after} time-steps), 
     745rather than at the central time level $t$ only, as in the standard leapfrog scheme. 
    746746 
    747747$\bullet$ leapfrog scheme (\np{ln\_dynhpg\_imp}\forcode{ = .true.}): 
     
    795795%-----------------------------------------nam_dynspg---------------------------------------------------- 
    796796 
    797 \nlst{namdyn_spg}  
     797\nlst{namdyn_spg} 
    798798%------------------------------------------------------------------------------------------------------------ 
    799799 
    800 Options are defined through the \ngn{namdyn\_spg} namelist variables. 
     800Options are defined through the \nam{dyn\_spg} namelist variables. 
    801801The surface pressure gradient term is related to the representation of the free surface (\autoref{sec:PE_hor_pg}). 
    802802The main distinction is between the fixed volume case (linear free surface) and 
    803 the variable volume case (nonlinear free surface, \key{vvl} is defined). 
     803the variable volume case (nonlinear free surface, \texttt{vvl?} is defined). 
    804804In the linear free surface case (\autoref{subsec:PE_free_surface}) 
    805805the vertical scale factors $e_{3}$ are fixed in time, 
    806806while they are time-dependent in the nonlinear case (\autoref{subsec:PE_free_surface}). 
    807 With both linear and nonlinear free surface, external gravity waves are allowed in the equations,  
     807With both linear and nonlinear free surface, external gravity waves are allowed in the equations, 
    808808which imposes a very small time step when an explicit time stepping is used. 
    809 Two methods are proposed to allow a longer time step for the three-dimensional equations:  
    810 the filtered free surface, which is a modification of the continuous equations (see \autoref{eq:PE_flt?}),  
     809Two methods are proposed to allow a longer time step for the three-dimensional equations: 
     810the filtered free surface, which is a modification of the continuous equations (see \autoref{eq:PE_flt?}), 
    811811and the split-explicit free surface described below. 
    812 The extra term introduced in the filtered method is calculated implicitly,  
     812The extra term introduced in the filtered method is calculated implicitly, 
    813813so that the update of the next velocities is done in module \mdl{dynspg\_flt} and not in \mdl{dynnxt}. 
    814814 
     
    819819an explicit formulation which requires a small time step; 
    820820a filtered free surface formulation which allows a larger time step by 
    821 adding a filtering term into the momentum equation;  
     821adding a filtering term into the momentum equation; 
    822822and a split-explicit free surface formulation, described below, which also allows a larger time step. 
    823823 
     
    829829% Explicit free surface formulation 
    830830%-------------------------------------------------------------------------------------------------------------- 
    831 \subsection[Explicit free surface (\texttt{\textbf{key\_dynspg\_exp}})] 
    832 {Explicit free surface (\protect\key{dynspg\_exp})} 
     831\subsection[Explicit free surface (\texttt{ln\_dynspg\_exp}\forcode{ = .true.})] 
     832{Explicit free surface (\protect\np{ln\_dynspg\_exp}\forcode{ = .true.})} 
    833833\label{subsec:DYN_spg_exp} 
    834834 
    835 In the explicit free surface formulation (\key{dynspg\_exp} defined), 
     835In the explicit free surface formulation (\np{ln\_dynspg\_exp} set to true), 
    836836the model time step is chosen to be small enough to resolve the external gravity waves 
    837837(typically a few tens of seconds). 
    838 The surface pressure gradient, evaluated using a leap-frog scheme (\ie centered in time), 
     838The surface pressure gradient, evaluated using a leap-frog scheme (\ie\ centered in time), 
    839839is thus simply given by : 
    840840\begin{equation} 
     
    846846    \end{aligned} 
    847847  \right. 
    848 \end{equation}  
    849  
    850 Note that in the non-linear free surface case (\ie \key{vvl} defined), 
     848\end{equation} 
     849 
     850Note that in the non-linear free surface case (\ie\ \texttt{vvl?} defined), 
    851851the surface pressure gradient is already included in the momentum tendency through 
    852852the level thickness variation allowed in the computation of the hydrostatic pressure gradient. 
     
    856856% Split-explict free surface formulation 
    857857%-------------------------------------------------------------------------------------------------------------- 
    858 \subsection[Split-explicit free surface (\texttt{\textbf{key\_dynspg\_ts}})] 
    859 {Split-explicit free surface (\protect\key{dynspg\_ts})} 
     858\subsection[Split-explicit free surface (\texttt{ln\_dynspg\_ts}\forcode{ = .true.})] 
     859{Split-explicit free surface (\protect\np{ln\_dynspg\_ts}\forcode{ = .true.})} 
    860860\label{subsec:DYN_spg_ts} 
    861861%------------------------------------------namsplit----------------------------------------------------------- 
     
    864864%------------------------------------------------------------------------------------------------------------- 
    865865 
    866 The split-explicit free surface formulation used in \NEMO (\key{dynspg\_ts} defined), 
     866The split-explicit free surface formulation used in \NEMO\ (\np{ln\_dynspg\_ts} set to true), 
    867867also called the time-splitting formulation, follows the one proposed by \citet{shchepetkin.mcwilliams_OM05}. 
    868868The general idea is to solve the free surface equation and the associated barotropic velocity equations with 
     
    897897Temporal discretization of the system above follows a three-time step Generalized Forward Backward algorithm 
    898898detailed in \citet{shchepetkin.mcwilliams_OM05}. 
    899 AB3-AM4 coefficients used in \NEMO follow the second-order accurate, 
     899AB3-AM4 coefficients used in \NEMO\ follow the second-order accurate, 
    900900"multi-purpose" stability compromise as defined in \citet{shchepetkin.mcwilliams_ibk09} 
    901 (see their figure 12, lower left).  
     901(see their figure 12, lower left). 
    902902 
    903903%>   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   >   > 
     
    935935provide time filtered quantities. 
    936936These are used for the subsequent initialization of the barotropic mode in the following baroclinic step. 
    937 Since external mode equations written at baroclinic time steps finally follow a forward time stepping scheme,  
     937Since external mode equations written at baroclinic time steps finally follow a forward time stepping scheme, 
    938938asselin filtering is not applied to barotropic quantities.\\ 
    939939Alternatively, one can choose to integrate barotropic equations starting from \textit{before} time step 
     
    963963 
    964964One can eventually choose to feedback instantaneous values by not using any time filter 
    965 (\np{ln\_bt\_av}\forcode{ = .false.}).  
     965(\np{ln\_bt\_av}\forcode{ = .false.}). 
    966966In that case, external mode equations are continuous in time, 
    967 \ie they are not re-initialized when starting a new sub-stepping sequence. 
     967\ie\ they are not re-initialized when starting a new sub-stepping sequence. 
    968968This is the method used so far in the POM model, the stability being maintained by 
    969969refreshing at (almost) each barotropic time step advection and horizontal diffusion terms. 
    970 Since the latter terms have not been added in \NEMO for computational efficiency, 
     970Since the latter terms have not been added in \NEMO\ for computational efficiency, 
    971971removing time filtering is not recommended except for debugging purposes. 
    972972This may be used for instance to appreciate the damping effect of the standard formulation on 
     
    976976 
    977977%>>>>>=============== 
    978 \gmcomment{               %%% copy from griffies Book  
     978\gmcomment{               %%% copy from griffies Book 
    979979 
    980980\textbf{title: Time stepping the barotropic system } 
     
    983983Hence, we can update the surface height and vertically integrated velocity with a leap-frog scheme using 
    984984the small barotropic time step $\rdt$. 
    985 We have  
     985We have 
    986986 
    987987\[ 
     
    10061006and total depth of the ocean $H(\tau)$ are held for the duration of the barotropic time stepping over 
    10071007a single cycle. 
    1008 This is also the time that sets the barotropic time steps via  
     1008This is also the time that sets the barotropic time steps via 
    10091009\[ 
    10101010  % \label{eq:DYN_spg_ts_t} 
     
    10121012\] 
    10131013with $n$ an integer. 
    1014 The density scaled surface pressure is evaluated via  
     1014The density scaled surface pressure is evaluated via 
    10151015\[ 
    10161016  % \label{eq:DYN_spg_ts_ps} 
     
    10211021  \end{cases} 
    10221022\] 
    1023 To get started, we assume the following initial conditions  
     1023To get started, we assume the following initial conditions 
    10241024\[ 
    10251025  % \label{eq:DYN_spg_ts_eta} 
     
    10291029  \end{split} 
    10301030\] 
    1031 with  
     1031with 
    10321032\[ 
    10331033  % \label{eq:DYN_spg_ts_etaF} 
     
    10351035\] 
    10361036the time averaged surface height taken from the previous barotropic cycle. 
    1037 Likewise,  
     1037Likewise, 
    10381038\[ 
    10391039  % \label{eq:DYN_spg_ts_u} 
     
    10411041  \textbf{U}(\tau,t_{n=1}) = \textbf{U}^{(b)}(\tau,t_{n=0}) + \rdt \ \text{RHS}_{n=0} 
    10421042\] 
    1043 with  
     1043with 
    10441044\[ 
    10451045  % \label{eq:DYN_spg_ts_u} 
     
    10471047\] 
    10481048the time averaged vertically integrated transport. 
    1049 Notably, there is no Robert-Asselin time filter used in the barotropic portion of the integration.  
     1049Notably, there is no Robert-Asselin time filter used in the barotropic portion of the integration. 
    10501050 
    10511051Upon reaching $t_{n=N} = \tau + 2\rdt \tau$ , 
    10521052the vertically integrated velocity is time averaged to produce the updated vertically integrated velocity at 
    1053 baroclinic time $\tau + \rdt \tau$  
     1053baroclinic time $\tau + \rdt \tau$ 
    10541054\[ 
    10551055  % \label{eq:DYN_spg_ts_u} 
     
    10571057\] 
    10581058The surface height on the new baroclinic time step is then determined via a baroclinic leap-frog using 
    1059 the following form  
     1059the following form 
    10601060 
    10611061\begin{equation} 
    10621062  \label{eq:DYN_spg_ts_ssh} 
    1063   \eta(\tau+\Delta) - \eta^{F}(\tau-\Delta) = 2\rdt \ \left[ - \nabla \cdot \textbf{U}(\tau) + \text{EMP}_w \right]   
     1063  \eta(\tau+\Delta) - \eta^{F}(\tau-\Delta) = 2\rdt \ \left[ - \nabla \cdot \textbf{U}(\tau) + \text{EMP}_w \right] 
    10641064\end{equation} 
    10651065 
    10661066The use of this "big-leap-frog" scheme for the surface height ensures compatibility between 
    10671067the mass/volume budgets and the tracer budgets. 
    1068 More discussion of this point is provided in Chapter 10 (see in particular Section 10.2).  
    1069   
     1068More discussion of this point is provided in Chapter 10 (see in particular Section 10.2). 
     1069 
    10701070In general, some form of time filter is needed to maintain integrity of the surface height field due to 
    10711071the leap-frog splitting mode in equation \autoref{eq:DYN_spg_ts_ssh}. 
     
    10781078  \eta^{F}(\tau-\Delta) =  \overline{\eta^{(b)}(\tau)} 
    10791079\end{equation} 
    1080 Another approach tried was  
     1080Another approach tried was 
    10811081 
    10821082\[ 
     
    10911091eliminating tracer and surface height time filtering (see ?? for more complete discussion). 
    10921092However, in the general case with a non-zero $\alpha$, 
    1093 the filter \autoref{eq:DYN_spg_ts_sshf} was found to be more conservative, and so is recommended.  
     1093the filter \autoref{eq:DYN_spg_ts_sshf} was found to be more conservative, and so is recommended. 
    10941094 
    10951095}            %%end gm comment (copy of griffies book) 
     
    11011101% Filtered free surface formulation 
    11021102%-------------------------------------------------------------------------------------------------------------- 
    1103 \subsection[Filtered free surface (\texttt{\textbf{key\_dynspg\_flt}})] 
    1104 {Filtered free surface (\protect\key{dynspg\_flt})} 
     1103\subsection[Filtered free surface (\texttt{dynspg\_flt?})] 
     1104{Filtered free surface (\protect\texttt{dynspg\_flt?})} 
    11051105\label{subsec:DYN_spg_fltp} 
    11061106 
    1107 The filtered formulation follows the \citet{roullet.madec_JGR00} implementation.  
    1108 The extra term introduced in the equations (see \autoref{subsec:PE_free_surface}) is solved implicitly.  
     1107The filtered formulation follows the \citet{roullet.madec_JGR00} implementation. 
     1108The extra term introduced in the equations (see \autoref{subsec:PE_free_surface}) is solved implicitly. 
    11091109The elliptic solvers available in the code are documented in \autoref{chap:MISC}. 
    11101110 
    11111111%% gm %%======>>>>   given here the discrete eqs provided to the solver 
    1112 \gmcomment{               %%% copy from chap-model basics  
     1112\gmcomment{               %%% copy from chap-model basics 
    11131113  \[ 
    11141114    % \label{eq:spg_flt} 
     
    11231123}   %end gmcomment 
    11241124 
    1125 Note that in the linear free surface formulation (\key{vvl} not defined), 
     1125Note that in the linear free surface formulation (\texttt{vvl?} not defined), 
    11261126the ocean depth is time-independent and so is the matrix to be inverted. 
    1127 It is computed once and for all and applies to all ocean time steps.  
     1127It is computed once and for all and applies to all ocean time steps. 
    11281128 
    11291129% ================================================================ 
     
    11351135%------------------------------------------nam_dynldf---------------------------------------------------- 
    11361136 
    1137 \nlst{namdyn_ldf}  
     1137\nlst{namdyn_ldf} 
    11381138%------------------------------------------------------------------------------------------------------------- 
    11391139 
    1140 Options are defined through the \ngn{namdyn\_ldf} namelist variables. 
     1140Options are defined through the \nam{dyn\_ldf} namelist variables. 
    11411141The options available for lateral diffusion are to use either laplacian (rotated or not) or biharmonic operators. 
    11421142The coefficients may be constant or spatially variable; 
    11431143the description of the coefficients is found in the chapter on lateral physics (\autoref{chap:LDF}). 
    11441144The lateral diffusion of momentum is evaluated using a forward scheme, 
    1145 \ie the velocity appearing in its expression is the \textit{before} velocity in time, 
     1145\ie\ the velocity appearing in its expression is the \textit{before} velocity in time, 
    11461146except for the pure vertical component that appears when a tensor of rotation is used. 
    11471147This latter term is solved implicitly together with the vertical diffusion term (see \autoref{chap:STP}). 
     
    11591159  In finite difference methods, 
    11601160  the biharmonic operator is frequently the method of choice to achieve this scale selective dissipation since 
    1161   its damping time (\ie its spin down time) scale like $\lambda^{-4}$ for disturbances of wavelength $\lambda$ 
     1161  its damping time (\ie\ its spin down time) scale like $\lambda^{-4}$ for disturbances of wavelength $\lambda$ 
    11621162  (so that short waves damped more rapidelly than long ones), 
    11631163  whereas the Laplace operator damping time scales only like $\lambda^{-2}$. 
     
    11691169\label{subsec:DYN_ldf_lap} 
    11701170 
    1171 For lateral iso-level diffusion, the discrete operator is:  
     1171For lateral iso-level diffusion, the discrete operator is: 
    11721172\begin{equation} 
    11731173  \label{eq:dynldf_lap} 
     
    11751175    \begin{aligned} 
    11761176      D_u^{l{\mathrm {\mathbf U}}} =\frac{1}{e_{1u} }\delta_{i+1/2} \left[ {A_T^{lm} 
    1177           \;\chi } \right]-\frac{1}{e_{2u} {\kern 1pt}e_{3u} }\delta_j \left[  
     1177          \;\chi } \right]-\frac{1}{e_{2u} {\kern 1pt}e_{3u} }\delta_j \left[ 
    11781178        {A_f^{lm} \;e_{3f} \zeta } \right] \\ \\ 
    11791179      D_v^{l{\mathrm {\mathbf U}}} =\frac{1}{e_{2v} }\delta_{j+1/2} \left[ {A_T^{lm} 
    1180           \;\chi } \right]+\frac{1}{e_{1v} {\kern 1pt}e_{3v} }\delta_i \left[  
     1180          \;\chi } \right]+\frac{1}{e_{1v} {\kern 1pt}e_{3v} }\delta_i \left[ 
    11811181        {A_f^{lm} \;e_{3f} \zeta } \right] 
    11821182    \end{aligned} 
    11831183  \right. 
    1184 \end{equation}  
     1184\end{equation} 
    11851185 
    11861186As explained in \autoref{subsec:PE_ldf}, 
    11871187this formulation (as the gradient of a divergence and curl of the vorticity) preserves symmetry and 
    1188 ensures a complete separation between the vorticity and divergence parts of the momentum diffusion.  
     1188ensures a complete separation between the vorticity and divergence parts of the momentum diffusion. 
    11891189 
    11901190%-------------------------------------------------------------------------------------------------------------- 
     
    12301230                -e_{2f} \; r_{1f} \,\overline{\overline {\delta_{k+1/2}[v]}}^{\,i+1/2,\,k}} 
    12311231            \right)} \right]}    \right. \\ 
    1232     & \qquad +\ \delta_j \left[ {A_T^{lm} \left( {\frac{e_{1t}\,e_{3t} }{e_{2t}  
     1232    & \qquad +\ \delta_j \left[ {A_T^{lm} \left( {\frac{e_{1t}\,e_{3t} }{e_{2t} 
    12331233            }\,\delta_{j} [v] - e_{1t}\, r_{2t} 
    12341234            \,\overline{\overline {\delta_{k+1/2} [v]}} ^{\,j,\,k}} 
    12351235        \right)} \right] \\ 
    1236     & \qquad +\ \delta_k \left[ {A_{vw}^{lm} \left( {-e_{2v} \, r_{1vw} \,\overline{\overline  
     1236    & \qquad +\ \delta_k \left[ {A_{vw}^{lm} \left( {-e_{2v} \, r_{1vw} \,\overline{\overline 
    12371237              {\delta_{i+1/2} [v]}}^{\,i+1/2,\,k+1/2} }\right.} \right. \\ 
    12381238    &  \ \qquad \qquad \qquad \quad\ 
    12391239    - e_{1v} \, r_{2vw} \,\overline{\overline {\delta_{j+1/2} [v]}} ^{\,j+1/2,\,k+1/2} \\ 
    1240     & \left. {\left. { \ \qquad \qquad \qquad \ \ \ \left. {\  
     1240    & \left. {\left. { \ \qquad \qquad \qquad \ \ \ \left. {\ 
    12411241                +\frac{e_{1v}\, e_{2v} }{e_{3vw} }\,\left( {r_{1vw}^2+r_{2vw}^2} 
    1242                 \right)\,\delta_{k+1/2} [v]} \right)} \right]\;\;\;} \right\}  
     1242                \right)\,\delta_{k+1/2} [v]} \right)} \right]\;\;\;} \right\} 
    12431243  \end{split} 
    12441244\end{equation} 
    12451245where $r_1$ and $r_2$ are the slopes between the surface along which the diffusion operator acts and 
    1246 the surface of computation ($z$- or $s$-surfaces).  
     1246the surface of computation ($z$- or $s$-surfaces). 
    12471247The way these slopes are evaluated is given in the lateral physics chapter (\autoref{chap:LDF}). 
    12481248 
     
    12701270%----------------------------------------------namzdf------------------------------------------------------ 
    12711271 
    1272 \nlst{namzdf}  
     1272\nlst{namzdf} 
    12731273%------------------------------------------------------------------------------------------------------------- 
    12741274 
    1275 Options are defined through the \ngn{namzdf} namelist variables. 
     1275Options are defined through the \nam{zdf} namelist variables. 
    12761276The large vertical diffusion coefficient found in the surface mixed layer together with high vertical resolution implies that in the case of explicit time stepping there would be too restrictive a constraint on the time step. 
    12771277Two time stepping schemes can be used for the vertical diffusion term: 
     
    12801280$(b)$ a backward (or implicit) time differencing scheme (\np{ln\_zdfexp}\forcode{ = .false.}) 
    12811281(see \autoref{chap:STP}). 
    1282 Note that namelist variables \np{ln\_zdfexp} and \np{nn\_zdfexp} apply to both tracers and dynamics.  
     1282Note that namelist variables \np{ln\_zdfexp} and \np{nn\_zdfexp} apply to both tracers and dynamics. 
    12831283 
    12841284The formulation of the vertical subgrid scale physics is the same whatever the vertical coordinate is. 
     
    13091309where $\left( \tau_u ,\tau_v \right)$ are the two components of the wind stress vector in 
    13101310the (\textbf{i},\textbf{j}) coordinate system. 
    1311 The high mixing coefficients in the surface mixed layer ensure that the surface wind stress is distributed in  
     1311The high mixing coefficients in the surface mixed layer ensure that the surface wind stress is distributed in 
    13121312the vertical over the mixed layer depth. 
    13131313If the vertical mixing coefficient is small (when no mixed layer scheme is used) 
     
    13261326Besides the surface and bottom stresses (see the above section) 
    13271327which are introduced as boundary conditions on the vertical mixing, 
    1328 three other forcings may enter the dynamical equations by affecting the surface pressure gradient.  
     1328three other forcings may enter the dynamical equations by affecting the surface pressure gradient. 
    13291329 
    13301330(1) When \np{ln\_apr\_dyn}\forcode{ = .true.} (see \autoref{sec:SBC_apr}), 
     
    13351335 
    13361336(3) When \np{nn\_ice\_embd}\forcode{ = 2} and LIM or CICE is used 
    1337 (\ie when the sea-ice is embedded in the ocean), 
     1337(\ie\ when the sea-ice is embedded in the ocean), 
    13381338the snow-ice mass is taken into account when computing the surface pressure gradient. 
    13391339 
     
    13431343 
    13441344% ================================================================ 
    1345 % Wetting and drying  
     1345% Wetting and drying 
    13461346% ================================================================ 
    13471347\section{Wetting and drying } 
     
    13591359 
    13601360The following terminology is used. The depth of the topography (positive downwards) 
    1361 at each $(i,j)$ point is the quantity stored in array $\mathrm{ht\_wd}$ in the NEMO code. 
     1361at each $(i,j)$ point is the quantity stored in array $\mathrm{ht\_wd}$ in the \NEMO\ code. 
    13621362The height of the free surface (positive upwards) is denoted by $ \mathrm{ssh}$. Given the sign 
    13631363conventions used, the water depth, $h$, is the height of the free surface plus the depth of the 
     
    13671367covered by water. They require the topography specified with a model 
    13681368configuration to have negative depths at points where the land is higher than the 
    1369 topography's reference sea-level. The vertical grid in NEMO is normally computed relative to an 
     1369topography's reference sea-level. The vertical grid in \NEMO\ is normally computed relative to an 
    13701370initial state with zero sea surface height elevation. 
    13711371The user can choose to compute the vertical grid and heights in the model relative to 
     
    13861386All these configurations have used pure sigma coordinates. It is expected that 
    13871387the wetting and drying code will work in domains with more general s-coordinates provided 
    1388 the coordinates are pure sigma in the region where wetting and drying actually occurs.  
     1388the coordinates are pure sigma in the region where wetting and drying actually occurs. 
    13891389 
    13901390The next sub-section descrbies the directional limiter and the following sub-section the iterative limiter. 
     
    13991399\label{subsec:DYN_wd_directional_limiter} 
    14001400The principal idea of the directional limiter is that 
    1401 water should not be allowed to flow out of a dry tracer cell (i.e. one whose water depth is less than rn\_wdmin1). 
     1401water should not be allowed to flow out of a dry tracer cell (i.e. one whose water depth is less than \np{rn\_wdmin1}). 
    14021402 
    14031403All the changes associated with this option are made to the barotropic solver for the non-linear 
     
    14091409 
    14101410The flux across each $u$-face of a tracer cell is multiplied by a factor zuwdmask (an array which depends on ji and jj). 
    1411 If the user sets ln\_wd\_dl\_ramp = .False. then zuwdmask is 1 when the 
    1412 flux is from a cell with water depth greater than rn\_wdmin1 and 0 otherwise. If the user sets 
    1413 ln\_wd\_dl\_ramp = .True. the flux across the face is ramped down as the water depth decreases 
    1414 from 2 * rn\_wdmin1 to rn\_wdmin1. The use of this ramp reduced grid-scale noise in idealised test cases. 
     1411If the user sets \np{ln\_wd\_dl\_ramp}\forcode{ = .false.} then zuwdmask is 1 when the 
     1412flux is from a cell with water depth greater than \np{rn\_wdmin1} and 0 otherwise. If the user sets 
     1413\np{ln\_wd\_dl\_ramp}\forcode{ = .true.} the flux across the face is ramped down as the water depth decreases 
     1414from 2 * \np{rn\_wdmin1} to \np{rn\_wdmin1}. The use of this ramp reduced grid-scale noise in idealised test cases. 
    14151415 
    14161416At the point where the flux across a $u$-face is multiplied by zuwdmask , we have chosen 
     
    14281428fields (tracers independent of $x$, $y$ and $z$). Our scheme conserves constant tracers because 
    14291429the velocities used at the tracer cell faces on the baroclinic timesteps are carefully calculated by dynspg\_ts 
    1430 to equal their mean value during the barotropic steps. If the user sets ln\_wd\_dl\_bc = .True., the 
    1431 baroclinic velocities are also multiplied by a suitably weighted average of zuwdmask.   
     1430to equal their mean value during the barotropic steps. If the user sets \np{ln\_wd\_dl\_bc}\forcode{ = .true.}, the 
     1431baroclinic velocities are also multiplied by a suitably weighted average of zuwdmask. 
    14321432 
    14331433%----------------------------------------------------------------------------------------- 
     
    14551455 
    14561456\begin{align} \label{dyn_wd_continuity_2} 
    1457 \frac{e_1 e_2}{\Delta t} ( h_{i,j}(t_{n+1}) - h_{i,j}(t_e) )  
     1457\frac{e_1 e_2}{\Delta t} ( h_{i,j}(t_{n+1}) - h_{i,j}(t_e) ) 
    14581458&= - ( \mathrm{flxu}_{i+1,j} - \mathrm{flxu}_{i,j}  + \mathrm{flxv}_{i,j+1} - \mathrm{flxv}_{i,j} ) \\ 
    14591459&= \mathrm{zzflx}_{i,j} . 
     
    14711471 
    14721472\begin{equation} \label{dyn_wd_zzflx_p_n_1} 
    1473 \mathrm{zzflx}_{i,j} = \mathrm{zzflxp}_{i,j} + \mathrm{zzflxn}_{i,j} .   
     1473\mathrm{zzflx}_{i,j} = \mathrm{zzflxp}_{i,j} + \mathrm{zzflxn}_{i,j} . 
    14741474\end{equation} 
    14751475 
     
    14951495 
    14961496\begin{equation} \label{dyn_wd_zzflx_initial} 
    1497 \mathrm{zzflxp^{(0)}}_{i,j} = \mathrm{zzflxp}_{i,j} , \quad  \mathrm{zzflxn^{(0)}}_{i,j} = \mathrm{zzflxn}_{i,j} .  
     1497\mathrm{zzflxp^{(0)}}_{i,j} = \mathrm{zzflxp}_{i,j} , \quad  \mathrm{zzflxn^{(0)}}_{i,j} = \mathrm{zzflxn}_{i,j} . 
    14981498\end{equation} 
    14991499 
     
    15251525\begin{split} 
    15261526\mathrm{zcoef}^{(m+1)}_{i,j} = \Big[ (h_{i,j}(t_e) & - \mathrm{rn\_wdmin1} - \mathrm{rn\_wdmin2})  \frac{e_1 e_2}{\Delta t} \phantom{]} \\ 
    1527 \phantom{[} & -  \mathrm{zzflxn}^{(m)}_{i,j} \Big] \frac{1}{ \mathrm{zzflxp}^{(0)}_{i,j} }  
     1527\phantom{[} & -  \mathrm{zzflxn}^{(m)}_{i,j} \Big] \frac{1}{ \mathrm{zzflxp}^{(0)}_{i,j} } 
    15281528\end{split} 
    15291529\end{equation} 
     
    16351635 
    16361636% ================================================================ 
    1637 % Time evolution term  
     1637% Time evolution term 
    16381638% ================================================================ 
    16391639\section[Time evolution term (\textit{dynnxt.F90})] 
     
    16431643%----------------------------------------------namdom---------------------------------------------------- 
    16441644 
    1645 \nlst{namdom}  
     1645\nlst{namdom} 
    16461646%------------------------------------------------------------------------------------------------------------- 
    16471647 
    1648 Options are defined through the \ngn{namdom} namelist variables. 
     1648Options are defined through the \nam{dom} namelist variables. 
    16491649The general framework for dynamics time stepping is a leap-frog scheme, 
    1650 \ie a three level centred time scheme associated with an Asselin time filter (cf. \autoref{chap:STP}). 
     1650\ie\ a three level centred time scheme associated with an Asselin time filter (cf. \autoref{chap:STP}). 
    16511651The scheme is applied to the velocity, except when 
    16521652using the flux form of momentum advection (cf. \autoref{sec:DYN_adv_cor_flux}) 
    1653 in the variable volume case (\key{vvl} defined), 
    1654 where it has to be applied to the thickness weighted velocity (see \autoref{sec:A_momentum})   
     1653in the variable volume case (\texttt{vvl?} defined), 
     1654where it has to be applied to the thickness weighted velocity (see \autoref{sec:A_momentum}) 
    16551655 
    16561656$\bullet$ vector invariant form or linear free surface 
    1657 (\np{ln\_dynhpg\_vec}\forcode{ = .true.} ; \key{vvl} not defined): 
     1657(\np{ln\_dynhpg\_vec}\forcode{ = .true.} ; \texttt{vvl?} not defined): 
    16581658\[ 
    16591659  % \label{eq:dynnxt_vec} 
     
    16671667 
    16681668$\bullet$ flux form and nonlinear free surface 
    1669 (\np{ln\_dynhpg\_vec}\forcode{ = .false.} ; \key{vvl} defined): 
     1669(\np{ln\_dynhpg\_vec}\forcode{ = .false.} ; \texttt{vvl?} defined): 
    16701670\[ 
    16711671  % \label{eq:dynnxt_flux} 
Note: See TracChangeset for help on using the changeset viewer.