epbl_lt_enhance Subroutine

public pure subroutine epbl_lt_enhance(scheme, coef, expo, max_enh, vonkar, lac1, lac2, lac3, lac4, lac5, la, b0, ustar, bld, absf, mstar)

Apply the Langmuir enhancement to mstar (Reichl & Li 2019; Li et al. 2016 stability modification). The modified Langmuir number folds the boundary-layer stability regime in via Ekman / Obukhov / MLD length-scale ratios, split by the sign of the surface buoyancy flux; all-zero lac coefficients give La_mod = La exactly.

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: scheme
real(kind=wp), intent(in) :: coef
real(kind=wp), intent(in) :: expo
real(kind=wp), intent(in) :: max_enh
real(kind=wp), intent(in) :: vonkar
real(kind=wp), intent(in) :: lac1
real(kind=wp), intent(in) :: lac2
real(kind=wp), intent(in) :: lac3
real(kind=wp), intent(in) :: lac4
real(kind=wp), intent(in) :: lac5
real(kind=wp), intent(in) :: la

Raw turbulent Langmuir number (> 0).

real(kind=wp), intent(in) :: b0

Surface buoyancy flux (m^2/s^3); > 0 stabilizing.

real(kind=wp), intent(in) :: ustar
real(kind=wp), intent(in) :: bld
real(kind=wp), intent(in) :: absf
real(kind=wp), intent(inout) :: mstar

Called by

proc~~epbl_lt_enhance~~CalledByGraph proc~epbl_lt_enhance epbl_lt_enhance proc~epbl_column_kernel epbl_column_kernel proc~epbl_column_kernel->proc~epbl_lt_enhance proc~epbl_compute epbl_compute proc~epbl_compute->proc~epbl_column_kernel proc~vmix_apply_in_stage vmix_apply_in_stage proc~vmix_apply_in_stage->proc~epbl_compute proc~run_stage run_stage proc~run_stage->proc~vmix_apply_in_stage proc~run_stage_split run_stage_split proc~run_stage_split->proc~vmix_apply_in_stage proc~ocean_dyn_step ocean_dyn_step proc~ocean_dyn_step->proc~run_stage proc~ocean_dyn_step_split ocean_dyn_step_split proc~ocean_dyn_step_split->proc~run_stage_split

Variables

Type Visibility Attributes Name Initial
real(kind=wp), private :: ek_ob
real(kind=wp), private :: enh
real(kind=wp), private :: la_mod
real(kind=wp), private :: mld_ek
real(kind=wp), private :: mld_ob

Source Code

   pure subroutine epbl_lt_enhance(scheme, coef, expo, max_enh, vonkar, &
                                   lac1, lac2, lac3, lac4, lac5, &
                                   la, b0, ustar, bld, absf, mstar)
      !! Apply the Langmuir enhancement to mstar (Reichl & Li 2019;
      !! Li et al. 2016 stability modification).  The modified
      !! Langmuir number folds the boundary-layer stability regime in
      !! via Ekman / Obukhov / MLD length-scale ratios, split by the
      !! sign of the surface buoyancy flux; all-zero lac coefficients
      !! give La_mod = La exactly.
      !$acc routine seq
      integer, intent(in) :: scheme
      real(wp), intent(in) :: coef, expo, max_enh, vonkar
      real(wp), intent(in) :: lac1, lac2, lac3, lac4, lac5
      real(wp), intent(in) :: la
         !! Raw turbulent Langmuir number (> 0).
      real(wp), intent(in) :: b0
         !! Surface buoyancy flux (m^2/s^3); > 0 stabilizing.
      real(wp), intent(in) :: ustar, bld, absf
      real(wp), intent(inout) :: mstar

      real(wp) :: mld_ek, ek_ob, mld_ob, la_mod, enh

      mld_ek = bld*absf/ustar
      ek_ob = abs(b0*vonkar)/(max(absf, 1.0e-20_wp)*ustar*ustar)
      mld_ob = abs(bld*b0*vonkar)/ustar**3
      if (b0 >= 0.0_wp) then
         la_mod = la*((1.0_wp + max(-0.5_wp, lac1*mld_ek)) + &
                      lac4*ek_ob + lac2*mld_ob)
      else
         la_mod = la*((1.0_wp + max(-0.5_wp, lac1*mld_ek)) + &
                      lac5*ek_ob + lac3*mld_ob)
      end if
      la_mod = max(la_mod, 1.0e-10_wp)

      if (scheme == EPBL_LT_ADDITIVE) then
         mstar = mstar + coef*la_mod**expo
      else
         enh = min(max_enh, 1.0_wp + coef*la_mod**expo)
         mstar = mstar*enh
      end if
   end subroutine epbl_lt_enhance