Back to home page




File indexing completed on 2023-08-29 05:10:28 UTC

view on githubraw file Latest commit b038e3cc on 2023-08-28 16:15:16 UTC
89474f9a5c Mart*0001 #ifdef ALLOW_GGL90
                0003 CBOP
                0004 C !ROUTINE: GGL90.h
                0006 C !DESCRIPTION: \bv
9293d3c672 Hajo*0007 C     *==========================================================*
89474f9a5c Mart*0008 C     | GGL90.h                                                  |
                0009 C     | o Basic header for Garpar et al. (1990)                  |
                0010 C     |   vertical mixing parameterization. Implementation       |
                0011 C     |   follows OPA implementation of Blanke+Delecuse (1993)   |
                0012 C     |   Contains all GGL90 field declarations.                 |
9293d3c672 Hajo*0013 C     *==========================================================*
89474f9a5c Mart*0014 
                0015 C-----------------------------------------------------------------------
                0016 C
                0017 C Parameters that can be set in data.ggl90
a8850cd0fd Jean*0018 C     unless otherwise noted, equation numbers refer to Gaspar et al.
89474f9a5c Mart*0019 C     (1990), JGR, 95(C9) pp. 16,179ff.
a8850cd0fd Jean*0020 C
89474f9a5c Mart*0021 C     GGL90ck         - constant in viscosity coefficient (eq.10)
                0022 C     GGL90ceps       - dissipation constant according to Kolmogorov (1942)
                0023 C     GGL90m2         - constant relating wind stress to vertical stress of TKE
                0024 C                      in K [d(TKE)/dz](0)=m2*ustar^3
                0025 C     GGL90alpha      - constant relating viscosity to GGL90 diffusivity
                0026 C                      (default=1 in Gaspar etal.)
6ab314cf42 Mart*0027 C     GGL90TKEsurfmin - minimum of surface kinetic energy boundary condition
                0028 C                      (default=GGL90TKEmin)
b038e3cc4f Mart*0029 C     GGL90TKEmin     - minimum kinetic energy, both numerical regularisation
                0030 C                       and source of due to unresolved processes,
                0031 C                       e.g. internal gravity waves
a8850cd0fd Jean*0032 C     GGL90TKEbottom  - bottom bounardy condition for kinetic energy
89474f9a5c Mart*0033 C                      (default=GGL90TKEmin)
                0034 C     GGL90TKEFile    - File with initial field of TKE
ab33ce9f77 Gael*0035 C     GGL90mixingLengthMin - Mininum mixing length
                0036 C     mxlMaxFlag      - Flag for limiting mixing-length method (default=0)
b038e3cc4f Mart*0037 C     adMxlMaxFlag    - in AD-mode, use adMxlMaxFlag instead of mxlMaxFlag
                0038 C                       (default=mxlMaxFlag)
1d389ab3d9 Jean*0039 C     mxlSurfFlag     - Flag to force mixing near ocean surface (default= F )
                0040 C     calcMeanVertShear :: calculate the mean (@ grid-cell center) of vertical
31f96e9372 Jean*0041 C                          shear compon. (instead of vert. shear of mean flow);
                0042 C                          also applies to surface stress (uStarSquare)
89474f9a5c Mart*0043 C
31a3206180 Mart*0044 C     useIDEMIX       - turn on internal wave mixing contribution modeled by
57a618d609 Mart*0045 C                       IDEMIX version 1:
                0046 C                     - Olbers, D. and Eden, C. (2013), J. Phys. Oceano.
31a3206180 Mart*0047 C                       doi:10.1175/JPO-D-12-0207.1
                0048 C
9293d3c672 Hajo*0049 C     useLANGMUIR     - turn on the parameterization of Langmuir circulation
                0050 C                       by Tak, Song et al. (2022), Ocean Modelling
                0051 C
89474f9a5c Mart*0052 C     GGL90dumpFreq   - analogue of dumpFreq (= default)
                0053 C     GGL90mixingMaps - output to standard out (default = .FALSE.)
                0054 C     GGL90writeState - output to files        (default = .FALSE.)
                0055 C
0320e25227 Mart*0056 C Time varying parameters computed by subroutine ggl90_calc, defined at
                0057 C interface (wVel-like)
89474f9a5c Mart*0058 C     GGL90TKE    - prognostic variable stepped forward in time ((m/s)^2)
                0059 C     GGL90viscAr - Vertical eddy viscosity coefficient         (m^2/s)
a8850cd0fd Jean*0060 C     GGL90diffKr - Vertical diffusion coefficient for heat,
89474f9a5c Mart*0061 C                salt and tracers                            (m^2/s)
                0062 C
                0063 C-----------------------------------------------------------------------
                0064 C \ev
                0065 CEOP
                0066       _RL    SQRTTWO
                0067       PARAMETER ( SQRTTWO = 1.41421356237310D0 )
                0068       _RL    GGL90eps
                0069       PARAMETER ( GGL90eps = 2.23D-16 )
                0071       CHARACTER*(MAX_LEN_FNAM) GGL90TKEFile
                0072       COMMON /GGL90_PARMS_C/ GGL90TKEFile
                0074       _RL    GGL90ck, GGL90ceps
                0075       _RL    GGL90alpha, GGL90m2
76f580e1f0 Mart*0076       _RL    GGL90diffTKEh
89474f9a5c Mart*0077       _RL    GGL90mixingLengthMin
6ab314cf42 Mart*0078       _RL    GGL90TKEmin, GGL90TKEsurfMin, GGL90TKEbottom
89474f9a5c Mart*0079       _RL    GGL90viscMax, GGL90diffMax
016b84c482 Mart*0080       _RL    GGL90dumpFreq
004d5ee949 Davi*0081       INTEGER mxlMaxFlag
b038e3cc4f Mart*0082       INTEGER adMxlMaxFlag
a8850cd0fd Jean*0083       COMMON /GGL90_PARMS_R/
89474f9a5c Mart*0084      &     GGL90ck, GGL90ceps,
                0085      &     GGL90alpha, GGL90m2,
76f580e1f0 Mart*0086      &     GGL90diffTKEh,
89474f9a5c Mart*0087      &     GGL90mixingLengthMin,
6ab314cf42 Mart*0088      &     GGL90TKEmin, GGL90TKEsurfMin, GGL90TKEbottom,
89474f9a5c Mart*0089      &     GGL90viscMax, GGL90diffMax,
b038e3cc4f Mart*0090      &     GGL90dumpFreq, mxlMaxFlag, adMxlMaxFlag
89474f9a5c Mart*0091 
f6b150f7f1 Gael*0092       _RL GGL90TKE    (1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr,nSx,nSy)
                0093       _RL GGL90viscArU(1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr,nSx,nSy)
                0094       _RL GGL90viscArV(1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr,nSx,nSy)
                0095       _RL GGL90diffKr (1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr,nSx,nSy)
89474f9a5c Mart*0096       COMMON /GGL90_FIELDS/ GGL90TKE,
f6b150f7f1 Gael*0097      &     GGL90viscArU, GGL90viscArV, GGL90diffKr
89474f9a5c Mart*0098 
                0099       LOGICAL GGL90isOn, GGL90mixingMaps, GGL90writeState
1d389ab3d9 Jean*0100       LOGICAL GGL90_dirichlet, mxlSurfFlag, calcMeanVertShear
                0101       LOGICAL useIDEMIX
9293d3c672 Hajo*0102       LOGICAL useLANGMUIR
89474f9a5c Mart*0103       COMMON /GGL90_PARMS_L/
ab33ce9f77 Gael*0104      &     GGL90isOn, GGL90mixingMaps, GGL90writeState,
1d389ab3d9 Jean*0105      &     GGL90_dirichlet, mxlSurfFlag, calcMeanVertShear,
9293d3c672 Hajo*0106      &     useIDEMIX, useLANGMUIR
89474f9a5c Mart*0107 
004d5ee949 Davi*0108 #ifdef ALLOW_GGL90_SMOOTH
f6b150f7f1 Gael*0109       COMMON /GGL90_CORNER/ mskCor
004d5ee949 Davi*0110       _RL mskCor(1-OLx:sNx+OLx,1-OLy:sNy+OLy,nSx,nSy)
                0111 #endif
31a3206180 Mart*0113 #ifdef ALLOW_GGL90_IDEMIX
0320e25227 Mart*0114 C-----------------------------------------------------------------------
31f96e9372 Jean*0115 C
0320e25227 Mart*0116 C     IDEMIX parameters
                0117 C     IDEMIX_tau_v :: time scale for vertical symmetrisation (s), def: 1d
                0118 C     IDEMIX_tau_h :: time scale for horizontal symmetrisation (s), def: 10d
                0119 C     IDEMIX_gamma :: scaling factor (see Olbers and Eden 2013, App) def: 1.57
                0120 C     IDEMIX_jstar :: spectral bandwidth in modes (default=10.)
31f96e9372 Jean*0121 C     IDEMIX_mu0   :: dissipation parameter (wrong default=4/3, should be 1/3)
0320e25227 Mart*0122 C     IDEMIX_diff_min :: minimum diffusivity, not used (def: 1e-9)
                0123 C     IDEMIX_mixing_efficiency :: used for diagnosing Osborn diff (def: 0.1666)
                0124 C     IDEMIX_diff_max :: maximum Osborn diffusivity (def: 1)
                0125 C     IDEMIX_frac_F_b :: scaling factor for  bottom forcing (def: 1)
31f96e9372 Jean*0126 C     IDEMIX_frac_F_s :: scaling factor for surface forcing (def: 0.2,
                0127 C                        because only 20% of the surface wind energy input is
                0128 C                        assumed to reach the interior below the mixed layer.)
                0129 C     IDEMIX_tidal_file :: file containing tidal forcing
                0130 C     IDEMIX_wind_file  :: file containing surface wind forcing
                0131 C     IDEMIX_include_GM :: include eddy contribution parameterized by GMredi
                0132 C     IDEMIX_include_GM_bottom :: include eddy contribution only at the bottom
                0133 C
0320e25227 Mart*0134 C-----------------------------------------------------------------------
31f96e9372 Jean*0135       _RL IDEMIX_tau_v, IDEMIX_tau_h, IDEMIX_gamma, IDEMIX_jstar
0320e25227 Mart*0136       _RL IDEMIX_mu0, IDEMIX_diff_min
                0137       _RL IDEMIX_mixing_efficiency, IDEMIX_diff_max
                0138       _RL IDEMIX_frac_F_b, IDEMIX_frac_F_s
                0139 C-----------------------------------------------------------------------
31f96e9372 Jean*0140 C
0320e25227 Mart*0141 C     IDEMIX 3-d fields, defined at interfaces (wVel-like)
31f96e9372 Jean*0142 C     IDEMIX_E   :: total energy of internal waves
                0143 C
0320e25227 Mart*0144 C     IDEMIX 2-d fields
                0145 C     IDEMIX_F_B :: internal wave energy bottom forcing field (e.g., tides)
                0146 C     IDEMIX_F_S :: IW energy surface forcing field (e.g., wind stress)
31f96e9372 Jean*0147 C
0320e25227 Mart*0148 C-----------------------------------------------------------------------
31f96e9372 Jean*0149       _RL IDEMIX_E  (1-OLx:sNx+OLx,1-OLy:sNy+OLy,Nr,nSx,nSy)
                0150       _RL IDEMIX_F_B(1-OLx:sNx+OLx,1-OLy:sNy+OLy,   nSx,nSy)
                0151       _RL IDEMIX_F_S(1-OLx:sNx+OLx,1-OLy:sNy+OLy,   nSx,nSy)
31a3206180 Mart*0152 
31f96e9372 Jean*0153       COMMON /GGL90_IDEMIX_VARS/ IDEMIX_E, IDEMIX_F_b, IDEMIX_F_S
                0155       COMMON /GGL90_IDEMIX_R/
                0156      &     IDEMIX_tau_v, IDEMIX_tau_h, IDEMIX_gamma, IDEMIX_jstar,
                0157      &     IDEMIX_mu0, IDEMIX_mixing_efficiency, IDEMIX_diff_max,
                0158      &     IDEMIX_diff_min, IDEMIX_frac_F_b, IDEMIX_frac_F_s
31a3206180 Mart*0159 
a8850cd0fd Jean*0160       CHARACTER*(MAX_LEN_FNAM)
                0161      &            IDEMIX_tidal_file, IDEMIX_wind_file
0320e25227 Mart*0162       COMMON /GLL90_IDEMIX_C/
                0163      &            IDEMIX_tidal_file, IDEMIX_wind_file
a8850cd0fd Jean*0165       LOGICAL     IDEMIX_include_GM, IDEMIX_include_GM_bottom
0320e25227 Mart*0166       COMMON /GLL90_IDEMIX_L/
a8850cd0fd Jean*0167      &            IDEMIX_include_GM, IDEMIX_include_GM_bottom
31a3206180 Mart*0168 #endif /* ALLOW_GGL90_IDEMIX */
9293d3c672 Hajo*0170 #ifdef ALLOW_GGL90_LANGMUIR
                0171 C     LC_Gamma  :: mixing-length Amplification factor from Langmuir Circ.
                0172 C     LC_num    :: Value for the Langmuir number (no unit)
                0173 C     LC_lambda :: vertical scale for Stokes velocity profile ( m )
                0174       _RL LC_Gamma, LC_num, LC_lambda
                0175       COMMON /GGL90_LCPARA/ LC_Gamma, LC_num, LC_lambda
                0176 #endif /* ALLOW_GGL90_LANGMUIR */
89474f9a5c Mart*0178 #endif /* ALLOW_GGL90 */