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 3318 for branches/2012/dev_r3309_LOCEAN12_Ediag/NEMOGCM/NEMO/OPA_SRC/TRD/trd_oce.F90 – NEMO

Ignore:
Timestamp:
2012-02-25T16:50:01+01:00 (12 years ago)
Author:
gm
Message:

Ediag branche: #927 split TRA/DYN trd computation

File:
1 moved

Legend:

Unmodified
Added
Removed
  • branches/2012/dev_r3309_LOCEAN12_Ediag/NEMOGCM/NEMO/OPA_SRC/TRD/trd_oce.F90

    r3317 r3318  
    1 MODULE trdmod_oce 
     1MODULE trd_oce 
    22   !!====================================================================== 
    3    !!                   ***  MODULE trdmod_oce  *** 
     3   !!                   ***  MODULE trd_oce  *** 
    44   !! Ocean trends :   set tracer and momentum trend variables 
    55   !!====================================================================== 
     
    1313   PUBLIC 
    1414 
    15 #if  defined key_trdtra   &&   defined key_trddyn    ||   defined key_esopa 
    16    LOGICAL, PARAMETER ::   lk_trdtra = .TRUE.    !: tracers  trend flag 
    17    LOGICAL, PARAMETER ::   lk_trddyn = .TRUE.    !: momentum trend flag 
    18 #elif  defined key_trdtra 
    19    LOGICAL, PARAMETER ::   lk_trdtra = .TRUE.    !: tracers  trend flag 
    20    LOGICAL, PARAMETER ::   lk_trddyn = .FALSE.   !: momentum trend flag 
    21 #elif  defined key_trddyn 
    22    LOGICAL, PARAMETER ::   lk_trdtra = .FALSE.   !: tracers  trend flag 
    23    LOGICAL, PARAMETER ::   lk_trddyn = .TRUE.    !: momentum trend flag 
    24 #else 
    25    LOGICAL, PARAMETER ::   lk_trdtra = .FALSE.   !: tracers  trend flag 
    26    LOGICAL, PARAMETER ::   lk_trddyn = .FALSE.   !: momentum trend flag 
    27 #endif 
     15   !                                                   !!* Namelist namtrd:  diagnostics on dynamics/tracer trends * 
     16   LOGICAL , PUBLIC  ::   ln_dyn_trd   = .FALSE.        !: (T) 3D momentum             trends or (F) not 
     17   LOGICAL , PUBLIC  ::   ln_tra_trd   = .FALSE.        !: (T) 3D tracer               trends or (F) not 
     18   LOGICAL , PUBLIC  ::   ln_KE_trd    = .FALSE.        !: (T) 3D Kinetic   Energy     trends or (F) not 
     19   LOGICAL , PUBLIC  ::   ln_PE_trd    = .FALSE.        !: (T) 3D Potential Energy     trends or (F) not 
     20   LOGICAL , PUBLIC  ::   ln_vor_trd   = .FALSE.        !: (T) 3D barotropic vorticity trends or (F) not 
     21   LOGICAL , PUBLIC  ::   ln_glo_trd   = .FALSE.        !: (T) global domain averaged diag for T, T^2, KE, and PE 
     22   LOGICAL , PUBLIC  ::   ln_dyn_mld   = .FALSE.        !: (T) 2D tracer   trends averaged over the mixed layer  
     23   LOGICAL , PUBLIC  ::   ln_tra_mld   = .FALSE.        !: (T) 2D momentum trends averaged over the mixed layer  
     24   INTEGER , PUBLIC  ::   nn_trd  = 10                  !: time step frequency for ln_glo_trd 
     25   INTEGER , PUBLIC  ::   nn_ctls =  0                  !: control surface type for trends vertical integration 
     26   REAL(wp), PUBLIC  ::   rn_ucf   = 1.                 !: unit conversion factor (for netCDF trends outputs) 
     27                                                        !: =1. (=86400.) for degC/s (degC/day) and psu/s (psu/day) 
     28   CHARACTER(len=32) ::   cn_trdrst_in  = "restart_mld" !: suffix of ocean restart name (input) 
     29   CHARACTER(len=32) ::   cn_trdrst_out = "restart_mld" !: suffix of ocean restart name (output) 
     30   LOGICAL , PUBLIC  ::   ln_trdmld_instant = .FALSE.   !: flag to diagnose inst./mean ML T/S trends 
     31   LOGICAL , PUBLIC  ::   ln_trdmld_restart = .FALSE.   !: flag to restart mixed-layer diagnostics 
    2832 
    29    !                                                     !!* Namelist namtrd:  diagnostics on dynamics/tracer trends * 
    30    LOGICAL , PUBLIC  ::   ln_3D_trd_d   = .FALSE.         !: (T) 3D momentum              trends or (F) not 
    31    LOGICAL , PUBLIC  ::   ln_3D_trd_t   = .FALSE.         !: (T) 3D tracer               trends or (F) not 
    32    LOGICAL , PUBLIC  ::   ln_PE_trd     = .FALSE.         !: (T) 3D Potential Energy     trends or (F) not 
    33    LOGICAL , PUBLIC  ::   ln_KE_trd     = .FALSE.         !: (T) 3D Kinetic   Energy     trends or (F) not 
    34    LOGICAL , PUBLIC  ::   ln_vor_trd    = .FALSE.         !: (T) 3D barotropic vorticity trends or (F) not 
    35    LOGICAL , PUBLIC  ::   ln_glo_trd    = .FALSE.         !: (T) global domain averaged diag for T, T^2, KE, and PE 
    36    LOGICAL , PUBLIC  ::   ln_ML_trd_t   = .FALSE.         !: (T) 2D tracer   trends averaged over the mixed layer  
    37    LOGICAL , PUBLIC  ::   ln_ML_trd_d   = .FALSE.         !: (T) 2D momentum trends averaged over the mixed layer  
    38    INTEGER , PUBLIC  ::   nn_trd  = 10                    !: time step frequency for ln_glo_trd 
    39    INTEGER , PUBLIC  ::   nn_ctls =  0                    !: control surface type for trends vertical integration 
    40    REAL(wp), PUBLIC  ::   rn_ucf   = 1.                   !: unit conversion factor (for netCDF trends outputs) 
    41                                                           !: =1. (=86400.) for degC/s (degC/day) and psu/s (psu/day) 
    42    CHARACTER(len=32) ::   cn_trdrst_in  = "restart_mld"   !: suffix of ocean restart name (input) 
    43    CHARACTER(len=32) ::   cn_trdrst_out = "restart_mld"   !: suffix of ocean restart name (output) 
    44    LOGICAL , PUBLIC  ::   ln_trdmld_instant = .FALSE.     !: flag to diagnose inst./mean ML T/S trends 
    45    LOGICAL , PUBLIC  ::   ln_trdmld_restart = .FALSE.     !: flag to restart mixed-layer diagnostics 
    46  
    47 # if defined key_trdtra   ||   defined key_trdmld 
    48    LOGICAL , PUBLIC ::   l_trdtra = .TRUE.                !: tracers  trend flag 
     33   LOGICAL , PUBLIC ::   l_trdtra        !: tracers  trend flag (set from namelist in trdini) 
     34   LOGICAL , PUBLIC ::   l_trddyn        !: momentum trend flag (set from namelist in trdini) 
     35    
     36# if ( defined key_trdtrc && defined key_iomput )  ||  defined key_trdmld_trc 
     37   LOGICAL , PUBLIC ::   l_trdtrc = .TRUE.        !: tracers  trend flag 
    4938# else 
    50    LOGICAL , PUBLIC ::   l_trdtra = .FALSE.               !: tracers  trend flag 
     39   LOGICAL , PUBLIC ::   l_trdtrc = .FALSE.       !: tracers  trend flag 
    5140# endif 
    52 # if defined key_trddyn   ||   defined key_trdvor 
    53    LOGICAL , PUBLIC ::   l_trddyn = .TRUE.                !: momentum trend flag 
    54 # else 
    55    LOGICAL , PUBLIC ::   l_trddyn = .FALSE.               !: momentum trend flag 
    56 # endif 
    57 # if ( defined key_trdtrc && defined key_iomput )  ||  defined key_trdmld_trc 
    58    LOGICAL , PUBLIC ::   l_trdtrc = .TRUE.                !: tracers  trend flag 
    59 # else 
    60    LOGICAL , PUBLIC ::   l_trdtrc = .FALSE.               !: tracers  trend flag 
    61 # endif 
    62    !                                                      !!!* Active tracers trends indexes 
    63    INTEGER, PUBLIC, PARAMETER ::   jptot_tra      = 14     !: Total trend nb: change it when adding/removing one indice below 
    64    !                               ===================     !   
    65    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_xad  =  1     !: x- horizontal advection 
    66    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_yad  =  2     !: y- horizontal advection 
    67    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_zad  =  3     !: z- vertical   advection 
    68    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_sad  =  4     !: z- vertical   advection 
    69    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_ldf  =  5     !: lateral       diffusion 
    70    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_zdf  =  6     !: vertical      diffusion 
    71    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_zdfp =  7     !: "PURE" vert.  diffusion (ln_traldf_iso=T) 
    72    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_bbc  =  8     !: Bottom Boundary Condition (geoth. heating)  
    73    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_bbl  =  9     !: Bottom Boundary Layer (diffusive and/or advective) 
    74    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_npc  = 10     !: non-penetrative convection treatment 
    75    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_dmp  = 11     !: internal restoring (damping) 
    76    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_qsr  = 12     !: penetrative solar radiation 
    77    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_nsr  = 13     !: non solar radiation / C/D on salinity  (+runoff if ln_rnf=T) 
    78    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_atf  = 14     !: Asselin time filter 
     41   !                                                  !!!* Active tracers trends indexes 
     42   INTEGER, PUBLIC, PARAMETER ::   jptot_tra  = 14     !: Total trend nb: change it when adding/removing one indice below 
     43   !                               ===============     !   
     44   INTEGER, PUBLIC, PARAMETER ::   jptra_xad  =  1     !: x- horizontal advection 
     45   INTEGER, PUBLIC, PARAMETER ::   jptra_yad  =  2     !: y- horizontal advection 
     46   INTEGER, PUBLIC, PARAMETER ::   jptra_zad  =  3     !: z- vertical   advection 
     47   INTEGER, PUBLIC, PARAMETER ::   jptra_sad  =  4     !: z- vertical   advection 
     48   INTEGER, PUBLIC, PARAMETER ::   jptra_ldf  =  5     !: lateral       diffusion 
     49   INTEGER, PUBLIC, PARAMETER ::   jptra_zdf  =  6     !: vertical      diffusion 
     50   INTEGER, PUBLIC, PARAMETER ::   jptra_zdfp =  7     !: "PURE" vert.  diffusion (ln_traldf_iso=T) 
     51   INTEGER, PUBLIC, PARAMETER ::   jptra_bbc  =  8     !: Bottom Boundary Condition (geoth. heating)  
     52   INTEGER, PUBLIC, PARAMETER ::   jptra_bbl  =  9     !: Bottom Boundary Layer (diffusive and/or advective) 
     53   INTEGER, PUBLIC, PARAMETER ::   jptra_npc  = 10     !: non-penetrative convection treatment 
     54   INTEGER, PUBLIC, PARAMETER ::   jptra_dmp  = 11     !: internal restoring (damping) 
     55   INTEGER, PUBLIC, PARAMETER ::   jptra_qsr  = 12     !: penetrative solar radiation 
     56   INTEGER, PUBLIC, PARAMETER ::   jptra_nsr  = 13     !: non solar radiation / C/D on salinity  (+runoff if ln_rnf=T) 
     57   INTEGER, PUBLIC, PARAMETER ::   jptra_atf  = 14     !: Asselin time filter 
    7958   ! 
    80    !                                                      !!!* Passive tracers trends indices (use if "key_top" defined) 
    81    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_sms  = 13     !: sources m. sinks 
    82    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_radn = 14     !: corr. trn<0 in trcrad 
    83    INTEGER, PUBLIC, PARAMETER ::   jptra_trd_radb = 15     !: corr. trb<0 in trcrad (like atf) 
     59   !                                                  !!!* Passive tracers trends indices (use if "key_top" defined) 
     60   INTEGER, PUBLIC, PARAMETER ::   jptra_sms  = 15     !: sources m. sinks 
     61   INTEGER, PUBLIC, PARAMETER ::   jptra_radn = 16     !: corr. trn<0 in trcrad 
     62   INTEGER, PUBLIC, PARAMETER ::   jptra_radb = 17     !: corr. trb<0 in trcrad (like atf) 
    8463   ! 
    85    !                                                      !!!* Momentum trends indices 
    86    INTEGER, PUBLIC, PARAMETER ::   jptot_dyn      = 11     !: Total trend nb: change it when adding/removing one indice below 
    87    !                               ===================     !   
    88    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_hpg  =  1     !: hydrostatic pressure gradient  
    89    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_spg  =  2     !: surface     pressure gradient 
    90    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_keg  =  3     !: kinetic energy gradient  or horizontal advection 
    91    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_rvo  =  4     !: relative  vorticity      or metric term 
    92    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_pvo  =  5     !: planetary vorticity 
    93    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_zad  =  6     !: vertical advection 
    94    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_ldf  =  7     !: horizontal diffusion    
    95    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_zdf  =  8     !: vertical   diffusion 
    96    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_tau  =  9     !: surface stress 
    97    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_bfr  = 10     !: bottom  stress  
    98    INTEGER, PUBLIC, PARAMETER ::   jpdyn_trd_atf  = 11     !: Asselin time filter 
     64   !                                                  !!!* Momentum trends indices 
     65   INTEGER, PUBLIC, PARAMETER ::   jptot_dyn  = 11     !: Total trend nb: change it when adding/removing one indice below 
     66   !                               ===============     !   
     67   INTEGER, PUBLIC, PARAMETER ::   jpdyn_hpg  =  1     !: hydrostatic pressure gradient  
     68   INTEGER, PUBLIC, PARAMETER ::   jpdyn_spg  =  2     !: surface     pressure gradient 
     69   INTEGER, PUBLIC, PARAMETER ::   jpdyn_keg  =  3     !: kinetic energy gradient  or horizontal advection 
     70   INTEGER, PUBLIC, PARAMETER ::   jpdyn_rvo  =  4     !: relative  vorticity      or metric term 
     71   INTEGER, PUBLIC, PARAMETER ::   jpdyn_pvo  =  5     !: planetary vorticity 
     72   INTEGER, PUBLIC, PARAMETER ::   jpdyn_zad  =  6     !: vertical advection 
     73   INTEGER, PUBLIC, PARAMETER ::   jpdyn_ldf  =  7     !: horizontal diffusion    
     74   INTEGER, PUBLIC, PARAMETER ::   jpdyn_zdf  =  8     !: vertical   diffusion 
     75   INTEGER, PUBLIC, PARAMETER ::   jpdyn_tau  =  9     !: surface stress 
     76   INTEGER, PUBLIC, PARAMETER ::   jpdyn_bfr  = 10     !: bottom  stress  
     77   INTEGER, PUBLIC, PARAMETER ::   jpdyn_atf  = 11     !: Asselin time filter 
    9978   ! 
    10079   !!---------------------------------------------------------------------- 
     
    10382   !! Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt) 
    10483   !!====================================================================== 
    105 END MODULE trdmod_oce 
     84END MODULE trd_oce 
Note: See TracChangeset for help on using the changeset viewer.