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.
trdicp_oce.F90 in trunk/NEMO/OPA_SRC/TRD – NEMO

source: trunk/NEMO/OPA_SRC/TRD/trdicp_oce.F90 @ 1129

Last change on this file since 1129 was 1129, checked in by ctlod, 16 years ago

trunk: compilation error when key_trddyn is active related to the dynamics advection flux formulation, see ticket: #211

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
File size: 4.8 KB
Line 
1MODULE trdicp_oce
2   !!======================================================================
3   !!                   ***  MODULE trdicp_oce  ***
4   !! Ocean trends :   set tracer and momentum trend variables
5   !!======================================================================
6
7   !!----------------------------------------------------------------------
8   !!   'key_trdtra'   or                         tracer trends diagnostics
9   !!   'key_trddyn'                            momentum trends diagnostics
10   !!----------------------------------------------------------------------
11   USE par_oce                 ! ocean parameters
12
13   IMPLICIT NONE
14   PUBLIC
15
16   !! * Shared module variables
17#if  defined key_trdtra   &&   defined key_trddyn    ||   defined key_esopa
18   LOGICAL, PARAMETER ::   lk_trdtra = .TRUE.    !: tracers  trend flag
19   LOGICAL, PARAMETER ::   lk_trddyn = .TRUE.    !: momentum trend flag
20#elif  defined key_trdtra
21   LOGICAL, PARAMETER ::   lk_trdtra = .TRUE.    !: tracers  trend flag
22   LOGICAL, PARAMETER ::   lk_trddyn = .FALSE.   !: momentum trend flag
23#elif  defined key_trddyn
24   LOGICAL, PARAMETER ::   lk_trdtra = .FALSE.   !: tracers  trend flag
25   LOGICAL, PARAMETER ::   lk_trddyn = .TRUE.    !: momentum trend flag
26#else
27   LOGICAL, PARAMETER ::   lk_trdtra = .FALSE.   !: tracers  trend flag
28   LOGICAL, PARAMETER ::   lk_trddyn = .FALSE.   !: momentum trend flag
29#endif
30
31   !! Tracers trends diagnostics parameters
32   !!---------------------------------------------------------------------
33   INTEGER, PARAMETER ::   &  !: => tracer trends indexes <=
34        jpicpt_xad =  1,   &  !: x- horizontal advection
35        jpicpt_yad =  2,   &  !: y- horizontal advection
36        jpicpt_zad =  3,   &  !: z- vertical   advection
37        jpicpt_ldf =  4,   &  !: lateral       diffusion
38        jpicpt_zdf =  5,   &  !: vertical diffusion (Kz)
39        jpicpt_bbc =  6,   &  !: Bottom Boundary Condition (geoth. flux)
40        jpicpt_bbl =  7,   &  !: Bottom Boundary Layer (diffusive/convective)
41        jpicpt_npc =  8,   &  !: static instability mixing
42        jpicpt_dmp =  9,   &  !: damping
43        jpicpt_qsr = 10,   &  !: penetrative solar radiation
44        jpicpt_nsr = 11,   &  !: non solar radiation
45        jpicpt_zl1 = 12       !: first level vertical flux
46
47   INTEGER, PARAMETER ::   &  !: => Total tracer trends indexes <=
48        jptot_tra = 12        !: change it when adding/removing one indice above
49   
50   !! Momentum trends diagnostics parameters
51   !!---------------------------------------------------------------------
52   INTEGER, PARAMETER ::   &  !: => dynamic trends indexes <=
53        jpicpd_hpg =  1,   &  !: hydrostatic pressure gradient
54        jpicpd_keg =  2,   &  !: kinetic energy gradient
55        jpicpd_rvo =  3,   &  !: relative vorticity
56        jpicpd_pvo =  4,   &  !: planetary vorticity
57        jpicpd_ldf =  5,   &  !: lateral diffusion
58        jpicpd_had =  6,   &  !: horizontal advection
59        jpicpd_zad =  7,   &  !: vertical advection
60        jpicpd_zdf =  8,   &  !: vertical diffusion
61        jpicpd_spg =  9,   &  !: surface pressure gradient
62        jpicpd_dat = 10,   &  !: damping term
63        jpicpd_swf = 11,   &  !: surface wind forcing
64        jpicpd_bfr = 12       !: bottom friction
65
66   INTEGER, PARAMETER ::   &  !: => Total dynamic trends indexes <=
67        jptot_dyn = 12        !: change it when adding/removing one indice above
68   
69#if   defined key_trdtra   ||   defined key_trddyn   ||   defined key_esopa
70
71   !! Variables used for diagnostics
72   !!---------------------------------------------------------------------
73   REAL(wp) ::   tvolt        !: volume of the whole ocean computed at t-points
74   REAL(wp) ::   tvolu        !: volume of the whole ocean computed at u-points
75   REAL(wp) ::   tvolv        !: volume of the whole ocean computed at v-points
76
77   !! Tracers trends diagnostics variables
78   !!---------------------------------------------------------------------
79   REAL(wp), DIMENSION(jptot_tra) ::   tmo, smo         !: tracers trends average
80   REAL(wp), DIMENSION(jptot_tra) ::   t2, s2           !: tracers square trends average
81   
82   !! Momentum trends diagnostics variables
83   !!---------------------------------------------------------------------
84   REAL(wp), DIMENSION(jptot_dyn) ::   umo, vmo         !: momentum trends average
85   REAL(wp), DIMENSION(jptot_dyn) ::   hke              !: momentum square trends average
86   REAL(wp) ::   rpktrd   !: potential to kinetic energy conversion
87   REAL(wp) ::   peke     !: conversion potential energy - kinetic energy trend
88
89#endif
90   !!----------------------------------------------------------------------
91   !!  OPA 9.0 , LOCEAN-IPSL (2005)
92   !! $Header$
93   !! Software governed by the CeCILL licence (modipsl/doc/NEMO_CeCILL.txt)
94   !!======================================================================
95END MODULE trdicp_oce
Note: See TracBrowser for help on using the repository browser.