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_time_domain.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_time_domain.tex

    r11263 r11512  
    88\chapter{Time Domain (STP)} 
    99\label{chap:STP} 
    10 \minitoc 
     10\chaptertoc 
    1111 
    1212% Missing things: 
     
    2121Having defined the continuous equations in \autoref{chap:PE}, we need now to choose a time discretization, 
    2222a key feature of an ocean model as it exerts a strong influence on the structure of the computer code 
    23 (\ie on its flowchart). 
    24 In the present chapter, we provide a general description of the \NEMO  time stepping strategy and 
     23(\ie\ on its flowchart). 
     24In the present chapter, we provide a general description of the \NEMO\  time stepping strategy and 
    2525the consequences for the order in which the equations are solved. 
    2626 
     
    3131\label{sec:STP_environment} 
    3232 
    33 The time stepping used in \NEMO is a three level scheme that can be represented as follows: 
     33The time stepping used in \NEMO\ is a three level scheme that can be represented as follows: 
    3434\begin{equation} 
    3535  \label{eq:STP} 
    3636  x^{t + \rdt} = x^{t - \rdt} + 2 \, \rdt \ \text{RHS}_x^{t - \rdt, \, t, \, t + \rdt} 
    37 \end{equation}  
     37\end{equation} 
    3838where $x$ stands for $u$, $v$, $T$ or $S$; 
    3939RHS is the Right-Hand-Side of the corresponding time evolution equation; 
     
    5353is usually not the variable at the after time step; 
    5454but rather it is used to store the time derivative (RHS in \autoref{eq:STP}) prior to time-stepping the equation. 
    55 The time stepping itself is performed once at each time step where implicit vertical diffusion is computed, \ie in the \mdl{trazdf} and \mdl{dynzdf} modules. 
     55The time stepping itself is performed once at each time step where implicit vertical diffusion is computed, \ie\ in the \mdl{trazdf} and \mdl{dynzdf} modules. 
    5656 
    5757% ------------------------------------------------------------------------------------------------------------- 
     
    6464\citep{mesinger.arakawa_bk76}. 
    6565This scheme is widely used for advection processes in low-viscosity fluids. 
    66 It is a time centred scheme, \ie the RHS in \autoref{eq:STP} is evaluated at time step $t$, the now time step. 
     66It is a time centred scheme, \ie\ the RHS in \autoref{eq:STP} is evaluated at time step $t$, the now time step. 
    6767It may be used for momentum and tracer advection, pressure gradient, and Coriolis terms, 
    6868but not for diffusion terms. 
     
    9292Therefore, the LF-RA is a quasi second order accurate scheme. 
    9393The LF-RA scheme is preferred to other time differencing schemes such as predictor corrector or trapezoidal schemes, 
    94 because the user has an explicit and simple control of the magnitude of the time diffusion of the scheme.  
     94because the user has an explicit and simple control of the magnitude of the time diffusion of the scheme. 
    9595When used with the 2nd order space centred discretisation of the advection terms in 
    9696the momentum and tracer equations, LF-RA avoids implicit numerical diffusion: 
    97 diffusion is set explicitly by the user through the Robert-Asselin  
     97diffusion is set explicitly by the user through the Robert-Asselin 
    9898filter parameter and the viscosity and diffusion coefficients. 
    9999 
     
    128128 
    129129For the vertical diffusion terms, a forward time differencing scheme can be used, 
    130 but usually the numerical stability condition imposes a strong constraint on the time step. To overcome the stability constraint, a  
     130but usually the numerical stability condition imposes a strong constraint on the time step. To overcome the stability constraint, a 
    131131backward (or implicit) time differencing scheme is used. This scheme is unconditionally stable but diffusive and can be written as follows: 
    132132\begin{equation} 
     
    152152  -c(k + 1) \; T^{t + 1}(k + 1) + d(k) \; T^{t + 1}(k) - \; c(k) \; T^{t + 1}(k - 1) \equiv b(k) 
    153153\end{equation} 
    154 where  
    155 \begin{align*}  
     154where 
     155\begin{align*} 
    156156  c(k) &= A_w^{vT} (k) \, / \, e_{3w} (k)     \\ 
    157157  d(k) &= e_{3t}   (k)       \, / \, (2 \rdt) + c_k + c_{k + 1}    \\ 
     
    171171\label{sec:STP_spg_ts} 
    172172 
    173 The leapfrog environment supports a centred in time computation of the surface pressure, \ie evaluated  
    174 at \textit{now} time step. This refers to as the explicit free surface case in the code (\np{ln\_dynspg\_exp}\forcode{ = .true.}).  
    175 This choice however imposes a strong constraint on the time step which should be small enough to resolve the propagation  
    176 of external gravity waves. As a matter of fact, one rather use in a realistic setup, a split-explicit free surface  
    177 (\np{ln\_dynspg\_ts}\forcode{ = .true.}) in which barotropic and baroclinic dynamical equations are solved separately with ad-hoc  
    178 time steps. The use of the time-splitting (in combination with non-linear free surface) imposes some constraints on the design of  
     173The leapfrog environment supports a centred in time computation of the surface pressure, \ie\ evaluated 
     174at \textit{now} time step. This refers to as the explicit free surface case in the code (\np{ln\_dynspg\_exp}\forcode{ = .true.}). 
     175This choice however imposes a strong constraint on the time step which should be small enough to resolve the propagation 
     176of external gravity waves. As a matter of fact, one rather use in a realistic setup, a split-explicit free surface 
     177(\np{ln\_dynspg\_ts}\forcode{ = .true.}) in which barotropic and baroclinic dynamical equations are solved separately with ad-hoc 
     178time steps. The use of the time-splitting (in combination with non-linear free surface) imposes some constraints on the design of 
    179179the overall flowchart, in particular to ensure exact tracer conservation (see \autoref{fig:TimeStep_flowchart}). 
    180180 
    181 Compared to the former use of the filtered free surface in \NEMO v3.6 (\citet{roullet.madec_JGR00}), the use of a split-explicit free surface is advantageous  
    182 on massively parallel computers. Indeed, no global computations are anymore required by the elliptic solver which saves a substantial amount of communication  
    183 time. Fast barotropic motions (such as tides) are also simulated with a better accuracy.  
    184  
    185 %\gmcomment{  
     181Compared to the former use of the filtered free surface in \NEMO\ v3.6 (\citet{roullet.madec_JGR00}), the use of a split-explicit free surface is advantageous 
     182on massively parallel computers. Indeed, no global computations are anymore required by the elliptic solver which saves a substantial amount of communication 
     183time. Fast barotropic motions (such as tides) are also simulated with a better accuracy. 
     184 
     185%\gmcomment{ 
    186186%>>>>>>>>>>>>>>>>>>>>>>>>>>>> 
    187187\begin{figure}[!t] 
     
    190190    \caption{ 
    191191      \protect\label{fig:TimeStep_flowchart} 
    192       Sketch of the leapfrog time stepping sequence in \NEMO with split-explicit free surface. The latter combined 
    193        with non-linear free surface requires the dynamical tendency being updated prior tracers tendency to ensure  
    194        conservation. Note the use of time integrated fluxes issued from the barotropic loop  in subsequent calculations  
    195        of tracer advection and in the continuity equation. Details about the time-splitting scheme can be found  
     192      Sketch of the leapfrog time stepping sequence in \NEMO\ with split-explicit free surface. The latter combined 
     193       with non-linear free surface requires the dynamical tendency being updated prior tracers tendency to ensure 
     194       conservation. Note the use of time integrated fluxes issued from the barotropic loop  in subsequent calculations 
     195       of tracer advection and in the continuity equation. Details about the time-splitting scheme can be found 
    196196       in \autoref{subsec:DYN_spg_ts}. 
    197197    } 
     
    212212 
    213213In a classical LF-RA environment, the forcing term is centred in time, 
    214 \ie it is time-stepped over a $2 \rdt$ period: 
     214\ie\ it is time-stepped over a $2 \rdt$ period: 
    215215$x^t = x^t + 2 \rdt Q^t$ where $Q$ is the forcing applied to $x$, 
    216216and the time filter is given by \autoref{eq:STP_asselin} so that $Q$ is redistributed over several time step. 
     
    236236Second, the LF-RA becomes a truly quasi -second order scheme. 
    237237Indeed, \autoref{eq:STP_forcing} used in combination with a careful treatment of static instability 
    238 (\autoref{subsec:ZDF_evd}) and of the TKE physics (\autoref{subsec:ZDF_tke_ene})  
     238(\autoref{subsec:ZDF_evd}) and of the TKE physics (\autoref{subsec:ZDF_tke_ene}) 
    239239(the two other main sources of time step divergence), 
    240240allows a reduction by two orders of magnitude of the Asselin filter parameter. 
     
    280280  x^1 = x^0 + \rdt \ \text{RHS}^0 
    281281\] 
    282 This is done simply by keeping the leapfrog environment (\ie the \autoref{eq:STP} three level time stepping) but 
     282This is done simply by keeping the leapfrog environment (\ie\ the \autoref{eq:STP} three level time stepping) but 
    283283setting all $x^0$ (\textit{before}) and $x^1$ (\textit{now}) fields equal at the first time step and 
    284 using half the value of a leapfrog time step ($2 \rdt$).  
     284using half the value of a leapfrog time step ($2 \rdt$). 
    285285 
    286286It is also possible to restart from a previous computation, by using a restart file. 
     
    292292 
    293293Note that the time step $\rdt$, is also saved in the restart file. 
    294 When restarting, if the time step has been changed, or one of the prognostic variables at \textit{before} time step  
    295 is missing, an Euler time stepping scheme is imposed. A forward initial step can still be enforced by the user by setting  
    296 the namelist variable \np{nn\_euler}\forcode{=0}. Other options to control the time integration of the model  
    297 are defined through the  \ngn{namrun} namelist variables. 
     294When restarting, if the time step has been changed, or one of the prognostic variables at \textit{before} time step 
     295is missing, an Euler time stepping scheme is imposed. A forward initial step can still be enforced by the user by setting 
     296the namelist variable \np{nn\_euler}\forcode{=0}. Other options to control the time integration of the model 
     297are defined through the  \nam{run} namelist variables. 
    298298%%% 
    299299\gmcomment{ 
     
    302302add also the idea of writing several restart for seasonal forecast : how is it done ? 
    303303 
    304 verify that all namelist pararmeters are truly described  
     304verify that all namelist pararmeters are truly described 
    305305 
    306306a word on the check of restart  ..... 
     
    308308%%% 
    309309 
    310 \gmcomment{       % add a subsection here   
     310\gmcomment{       % add a subsection here 
    311311 
    312312%------------------------------------------------------------------------------------------------------------- 
     
    317317%--------------------------------------------namrun------------------------------------------- 
    318318 
    319 \nlst{namdom}          
     319\nlst{namdom} 
    320320%-------------------------------------------------------------------------------------------------------------- 
    321321 
    322 Options are defined through the  \ngn{namdom} namelist variables. 
     322Options are defined through the  \nam{dom} namelist variables. 
    323323 \colorbox{yellow}{add here a few word on nit000 and nitend} 
    324324 
     
    332332 
    333333%% 
    334 \gmcomment{       % add implicit in vvl case  and Crant-Nicholson scheme    
     334\gmcomment{       % add implicit in vvl case  and Crant-Nicholson scheme 
    335335 
    336336Implicit time stepping in case of variable volume thickness. 
Note: See TracChangeset for help on using the changeset viewer.