[2030] | 1 | MODULE trdmod_trc_oce |
---|
| 2 | !!====================================================================== |
---|
| 3 | !! *** MODULE trdmod_trc_oce *** |
---|
| 4 | !! Ocean trends : set tracer and momentum trend variables |
---|
| 5 | !!====================================================================== |
---|
| 6 | !!---------------------------------------------------------------------- |
---|
| 7 | !! OPA 9.0 , LOCEAN-IPSL (2005) |
---|
| 8 | !! $Header: /home/opalod/NEMOCVSROOT/NEMO/OPA_SRC/TRD/trdmld_oce.F90,v 1.2 2005/03/27 18:35:23 opalod Exp $ |
---|
| 9 | !! Software governed by the CeCILL licence (modipsl/doc/NEMO_CeCILL.txt) |
---|
| 10 | !!---------------------------------------------------------------------- |
---|
| 11 | #if defined key_top |
---|
| 12 | !!---------------------------------------------------------------------- |
---|
| 13 | !! 'key_top' TOP models |
---|
| 14 | !!---------------------------------------------------------------------- |
---|
| 15 | |
---|
| 16 | USE par_oce ! ocean parameters |
---|
| 17 | USE par_trc ! passive tracers parameters |
---|
| 18 | |
---|
| 19 | IMPLICIT NONE |
---|
| 20 | PUBLIC |
---|
| 21 | |
---|
| 22 | !!* Namelist namtoptrd: diagnostics on passive tracers trends |
---|
| 23 | INTEGER :: nn_trd_trc !: time step frequency dynamics and tracers trends |
---|
| 24 | INTEGER :: nn_ctls_trc !: control surface type for trends vertical integration |
---|
| 25 | REAL(wp) :: rn_ucf_trc !: unit conversion factor (for netCDF trends outputs) |
---|
| 26 | LOGICAL :: ln_trdmld_trc_instant !: flag to diagnose inst./mean ML trc trends |
---|
| 27 | LOGICAL :: ln_trdmld_trc_restart !: flag to restart mixed-layer trc diagnostics |
---|
| 28 | CHARACTER(len=50) :: cn_trdrst_trc_in !: suffix of pass. tracer restart name (input) |
---|
| 29 | CHARACTER(len=50) :: cn_trdrst_trc_out !: suffix of pass. tracer restart name (output) |
---|
| 30 | LOGICAL, DIMENSION (jptra) :: ln_trdtrc !: large trends diagnostic to write or not (namelist) |
---|
| 31 | |
---|
| 32 | # if defined key_trdtrc && defined key_iomput |
---|
| 33 | LOGICAL, PARAMETER :: lk_trdtrc = .TRUE. |
---|
| 34 | #else |
---|
| 35 | LOGICAL, PARAMETER :: lk_trdtrc = .FALSE. !: ML trend flag |
---|
| 36 | #endif |
---|
| 37 | |
---|
| 38 | #if defined key_trdmld_trc |
---|
| 39 | !!---------------------------------------------------------------------- |
---|
| 40 | !! 'key_trdmld_trc' mixed layer trends diagnostics |
---|
| 41 | !!---------------------------------------------------------------------- |
---|
| 42 | |
---|
| 43 | LOGICAL, PARAMETER :: lk_trdmld_trc = .TRUE. !: ML trend flag |
---|
| 44 | |
---|
| 45 | INTEGER, PARAMETER :: & !: mixed layer trends indices |
---|
| 46 | jpmld_trc_xad = 1, & !: zonal \ |
---|
| 47 | jpmld_trc_yad = 2, & !: meridonal > advection |
---|
| 48 | jpmld_trc_zad = 3, & !: vertical / |
---|
| 49 | jpmld_trc_ldf = 4, & !: lateral diffusion (geopot. or iso-neutral) |
---|
| 50 | jpmld_trc_zdf = 5, & !: vertical diffusion (TKE) |
---|
| 51 | jpmld_trc_bbl = 6, & !: bottom boundary layer (advective/diffusive) |
---|
| 52 | jpmld_trc_dmp = 7, & !: internal restoring trend |
---|
| 53 | jpmld_trc_sbc = 8, & !: forcing |
---|
| 54 | jpmld_trc_sms = 9, & !: sources minus sinks trend |
---|
| 55 | ! jpmld_trc_xxx = xx, & !: add here any additional trend (** AND UPDATE JPLTRD_TRC BELOW **) |
---|
| 56 | jpmld_trc_radn = 10, & !: corr. trn<0 in trcrad |
---|
| 57 | jpmld_trc_radb = 11, & !: corr. trb<0 in trcrad (like atf) (** MUST BE BEFORE THE LAST ONE **) |
---|
| 58 | jpmld_trc_atf = 12 !: asselin trend (** MUST BE THE LAST ONE**) |
---|
| 59 | |
---|
| 60 | !! Trends diagnostics parameters |
---|
| 61 | !!--------------------------------------------------------------------- |
---|
| 62 | INTEGER, PARAMETER :: & |
---|
| 63 | jpltrd_trc = 12, & !: number of mixed-layer trends arrays |
---|
| 64 | jpktrd_trc = jpk !: max level for mixed-layer trends diag. |
---|
| 65 | |
---|
| 66 | !! Arrays used for diagnosing mixed-layer trends |
---|
| 67 | !!--------------------------------------------------------------------- |
---|
| 68 | CHARACTER(LEN=80) :: clname_trc, ctrd_trc(jpltrd_trc+1,2) |
---|
| 69 | |
---|
| 70 | INTEGER, DIMENSION(jpi,jpj) :: & |
---|
| 71 | nmld_trc , & !: mixed layer depth indexes |
---|
| 72 | nbol_trc !: mixed-layer depth indexes when read from file |
---|
| 73 | |
---|
| 74 | REAL(wp), DIMENSION(jpi,jpj,jpk) :: wkx_trc !: |
---|
| 75 | |
---|
| 76 | REAL(wp), DIMENSION(jpi,jpj) :: rmld_trc !: ML depth (m) corresponding to nmld_trc |
---|
| 77 | REAL(wp), DIMENSION(jpi,jpj) :: rmld_sum_trc !: needed to compute the leap-frog time mean of ML depth |
---|
| 78 | REAL(wp), DIMENSION(jpi,jpj) :: rmldbn_trc !: idem |
---|
| 79 | |
---|
| 80 | REAL(wp), DIMENSION(jpi,jpj,jptra) :: & |
---|
| 81 | tml_trc , & !: \ "now" mixed layer temperature/salinity |
---|
| 82 | tmlb_trc , & !: / and associated "before" fields |
---|
| 83 | tmlbb_trc , & !: \ idem, but valid at the 1rst time step of the |
---|
| 84 | tmlbn_trc , & !: / current analysis window |
---|
| 85 | tml_sum_trc, & !: mixed layer T, summed over the current analysis period |
---|
| 86 | tml_sumb_trc, & !: idem, but from the previous analysis period |
---|
| 87 | tmltrd_atf_sumb_trc, & !: Asselin trends, summed over the previous analysis period |
---|
| 88 | tmltrd_rad_sumb_trc !: trends due to trb correction in trcrad.F90, summed over the |
---|
| 89 | !: previous analysis period |
---|
| 90 | |
---|
| 91 | REAL(wp), DIMENSION(jpi,jpj,jptra) :: & |
---|
| 92 | tmlatfb_trc, tmlatfn_trc , & !: "before" Asselin contrib. at beginning of the averaging |
---|
| 93 | !: period (i.e. last contrib. from previous such period) |
---|
| 94 | !: and "now" Asselin contrib. to the ML trc. trends |
---|
| 95 | tmlatfm_trc, & !: accumulator for Asselin trends (needed for storage only) |
---|
| 96 | tmlradb_trc, tmlradn_trc , & !: similar to Asselin above, but for the trend due to trb |
---|
| 97 | !: correction in trcrad.F90 |
---|
| 98 | tmlradm_trc !: accumulator for the previous trcrad trend |
---|
| 99 | |
---|
| 100 | REAL(wp), DIMENSION(jpi,jpj,jpltrd_trc,jptra) :: & |
---|
| 101 | tmltrd_trc, & !: \ physical contributions to the total trend (for T/S), |
---|
| 102 | !: / cumulated over the current analysis window |
---|
| 103 | tmltrd_sum_trc, & !: sum of these trends over the analysis period |
---|
| 104 | tmltrd_csum_ln_trc, & !: now cumulated sum of trends over the "lower triangle" |
---|
| 105 | tmltrd_csum_ub_trc !: before (prev. analysis period) cumulated sum over the |
---|
| 106 | !: upper triangle |
---|
| 107 | REAL(wp), DIMENSION(jpi,jpj,jptra) :: & |
---|
| 108 | tmltrdm_trc !: total cumulative trends over the analysis window |
---|
| 109 | |
---|
| 110 | #else |
---|
| 111 | LOGICAL, PARAMETER :: lk_trdmld_trc = .FALSE. !: ML trend flag |
---|
| 112 | #endif |
---|
| 113 | |
---|
| 114 | #if defined key_lobster |
---|
| 115 | CHARACTER(LEN=80) :: clname_bio, ctrd_bio(jpdiabio,2) |
---|
| 116 | REAL(wp), DIMENSION(jpi,jpj,jpdiabio) :: & |
---|
| 117 | tmltrd_bio, & !: \ biological contributions to the total trend , |
---|
| 118 | !: / cumulated over the current analysis window |
---|
| 119 | tmltrd_sum_bio, & !: sum of these trends over the analysis period |
---|
| 120 | tmltrd_csum_ln_bio, & !: now cumulated sum of trends over the "lower triangle" |
---|
| 121 | tmltrd_csum_ub_bio !: before (prev. analysis period) cumulated sum over the |
---|
| 122 | !: upper triangle |
---|
| 123 | #endif |
---|
| 124 | |
---|
| 125 | #else |
---|
| 126 | !!---------------------------------------------------------------------- |
---|
| 127 | !! Empty module : No passive tracer |
---|
| 128 | !!---------------------------------------------------------------------- |
---|
| 129 | #endif |
---|
| 130 | |
---|
| 131 | |
---|
| 132 | END MODULE trdmod_trc_oce |
---|