Skip to content

Commit

Permalink
+*Use visc%h_ML in tracer diffusion routines
Browse files Browse the repository at this point in the history
  Pass visc%h_ML to applyBoundaryFluxesInOut, which avoids the need for the
thickness conversions inside of that routine.  Answers are bitwise identical for
Boussinesq cases, but they will change in non-Boussinesq cases because the layer
specific volumes have changed between the time the boundary layer thicknesses
have been calculated and when they are being used in the brine plume
parameterization.

  Also use visc%h_ML in place of calls to KPP_get_BLD or energetic_PBL_get_MLD
in step_MOM_dyn_split_RK2, hor_bnd_diffusion and neutral_diffusion_calc_coeffs.
This change requires a new vertvisc_type argument to tracer_hordiff,
hor_bnd_diffusion and neutral_diffusion_calc_coeffs.  Boussinesq answers are
bitwise identical, but non-Boussinesq answers change because they now use the
actual model specific volumes rather than some prescribed constant value to to
the relevant unit conversions.

  The logic in set_visc_register_restarts was also updated so that visc%MLD and
visc%h_ML are allocated and registered for restarts in the cases where they will
be used.

  All answers are bitwise identical in Boussinesq mode, but in non-Boussinesq
mode there are changes in answers in cases that use neutral tracer diffusion
that excludes the boundary layer, horizontal tracer diffusion in the boundary
layer or FPMIX.  There are also changes to the arguments of several publicly
visible routines.
  • Loading branch information
Hallberg-NOAA committed Apr 26, 2024
1 parent f2e63c2 commit df2e4b0
Show file tree
Hide file tree
Showing 10 changed files with 88 additions and 77 deletions.
8 changes: 4 additions & 4 deletions src/core/MOM.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1432,7 +1432,7 @@ subroutine step_MOM_tracer_dyn(CS, G, GV, US, h, Time_local)
call advect_tracer(h, CS%uhtr, CS%vhtr, CS%OBC, CS%t_dyn_rel_adv, G, GV, US, &
CS%tracer_adv_CSp, CS%tracer_Reg, x_first_in=x_first)
if (CS%debug) call MOM_tracer_chksum("Post-advect ", CS%tracer_Reg, G)
call tracer_hordiff(h, CS%t_dyn_rel_adv, CS%MEKE, CS%VarMix, G, GV, US, &
call tracer_hordiff(h, CS%t_dyn_rel_adv, CS%MEKE, CS%VarMix, CS%visc, G, GV, US, &
CS%tracer_diff_CSp, CS%tracer_Reg, CS%tv)
if (CS%debug) call MOM_tracer_chksum("Post-diffuse ", CS%tracer_Reg, G)
if (showCallTree) call callTree_waypoint("finished tracer advection/diffusion (step_MOM)")
Expand Down Expand Up @@ -1881,7 +1881,7 @@ subroutine step_offline(forces, fluxes, sfc_state, Time_start, time_interval, CS
call calc_depth_function(G, CS%VarMix)
call calc_slope_functions(CS%h, CS%tv, dt_offline, G, GV, US, CS%VarMix, OBC=CS%OBC)
endif
call tracer_hordiff(CS%h, dt_offline, CS%MEKE, CS%VarMix, G, GV, US, &
call tracer_hordiff(CS%h, dt_offline, CS%MEKE, CS%VarMix, CS%visc, G, GV, US, &
CS%tracer_diff_CSp, CS%tracer_Reg, CS%tv)
endif
endif
Expand All @@ -1908,7 +1908,7 @@ subroutine step_offline(forces, fluxes, sfc_state, Time_start, time_interval, CS
call calc_depth_function(G, CS%VarMix)
call calc_slope_functions(CS%h, CS%tv, dt_offline, G, GV, US, CS%VarMix, OBC=CS%OBC)
endif
call tracer_hordiff(CS%h, dt_offline, CS%MEKE, CS%VarMix, G, GV, US, &
call tracer_hordiff(CS%h, dt_offline, CS%MEKE, CS%VarMix, CS%visc, G, GV, US, &
CS%tracer_diff_CSp, CS%tracer_Reg, CS%tv)
endif
endif
Expand Down Expand Up @@ -1965,7 +1965,7 @@ subroutine step_offline(forces, fluxes, sfc_state, Time_start, time_interval, CS
CS%h, eatr, ebtr, uhtr, vhtr)
! Perform offline diffusion if requested
if (.not. skip_diffusion) then
call tracer_hordiff(h_end, dt_offline, CS%MEKE, CS%VarMix, G, GV, US, &
call tracer_hordiff(h_end, dt_offline, CS%MEKE, CS%VarMix, CS%visc, G, GV, US, &
CS%tracer_diff_CSp, CS%tracer_Reg, CS%tv)
endif

Expand Down
9 changes: 1 addition & 8 deletions src/core/MOM_dynamics_split_RK2.F90
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,6 @@ module MOM_dynamics_split_RK2
use MOM_verticalGrid, only : verticalGrid_type, get_thickness_units
use MOM_verticalGrid, only : get_flux_units, get_tr_flux_units
use MOM_wave_interface, only : wave_parameters_CS, Stokes_PGF
use MOM_CVMix_KPP, only : KPP_get_BLD, KPP_CS
use MOM_energetic_PBL, only : energetic_PBL_get_MLD, energetic_PBL_CS
use MOM_diabatic_driver, only : diabatic_CS, extract_diabatic_member

implicit none ; private

Expand Down Expand Up @@ -139,8 +136,6 @@ module MOM_dynamics_split_RK2
real ALLOCABLE_, dimension(NIMEM_,NJMEM_,NKMEM_) :: pbce !< pbce times eta gives the baroclinic pressure
!! anomaly in each layer due to free surface height
!! anomalies [L2 H-1 T-2 ~> m s-2 or m4 kg-1 s-2].
type(KPP_CS), pointer :: KPP_CSp => NULL() !< KPP control structure needed to ge
type(energetic_PBL_CS), pointer :: energetic_PBL_CSp => NULL() !< ePBL control structure

real, pointer, dimension(:,:) :: taux_bot => NULL() !< frictional x-bottom stress from the ocean
!! to the seafloor [R L Z T-2 ~> Pa]
Expand Down Expand Up @@ -717,9 +712,7 @@ subroutine step_MOM_dyn_split_RK2(u_inst, v_inst, h, tv, visc, Time_local, dt, f

if (CS%fpmix) then
hbl(:,:) = 0.0
if (ASSOCIATED(CS%KPP_CSp)) call KPP_get_BLD(CS%KPP_CSp, hbl, G, US, m_to_BLD_units=GV%m_to_H)
if (ASSOCIATED(CS%energetic_PBL_CSp)) &
call energetic_PBL_get_MLD(CS%energetic_PBL_CSp, hbl, G, US, m_to_MLD_units=GV%m_to_H)
if (associated(visc%h_ML)) hbl(:,:) = visc%h_ML(:,:)
call vertFPmix(up, vp, uold, vold, hbl, h, forces, &
dt_pred, G, GV, US, CS%vertvisc_CSp, CS%OBC)
call vertvisc(up, vp, h, forces, visc, dt_pred, CS%OBC, CS%ADp, CS%CDp, G, &
Expand Down
9 changes: 1 addition & 8 deletions src/core/MOM_dynamics_split_RK2b.F90
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,6 @@ module MOM_dynamics_split_RK2b
use MOM_verticalGrid, only : verticalGrid_type, get_thickness_units
use MOM_verticalGrid, only : get_flux_units, get_tr_flux_units
use MOM_wave_interface, only: wave_parameters_CS, Stokes_PGF
use MOM_CVMix_KPP, only : KPP_get_BLD, KPP_CS
use MOM_energetic_PBL, only : energetic_PBL_get_MLD, energetic_PBL_CS
use MOM_diabatic_driver, only : diabatic_CS, extract_diabatic_member

implicit none ; private

Expand Down Expand Up @@ -147,8 +144,6 @@ module MOM_dynamics_split_RK2b
real ALLOCABLE_, dimension(NIMEM_,NJMEMB_PTR_) :: dv_av_inst !< The barotropic meridional velocity increment
!! between filtered and instantaneous velocities
!! [L T-1 ~> m s-1]
type(KPP_CS), pointer :: KPP_CSp => NULL() !< KPP control structure needed to ge
type(energetic_PBL_CS), pointer :: energetic_PBL_CSp => NULL() !< ePBL control structure

real, pointer, dimension(:,:) :: taux_bot => NULL() !< frictional x-bottom stress from the ocean
!! to the seafloor [R L Z T-2 ~> Pa]
Expand Down Expand Up @@ -734,9 +729,7 @@ subroutine step_MOM_dyn_split_RK2b(u_av, v_av, h, tv, visc, Time_local, dt, forc

! if (CS%fpmix) then
! hbl(:,:) = 0.0
! if (ASSOCIATED(CS%KPP_CSp)) call KPP_get_BLD(CS%KPP_CSp, hbl, G, US, m_to_BLD_units=GV%m_to_H)
! if (ASSOCIATED(CS%energetic_PBL_CSp)) &
! call energetic_PBL_get_MLD(CS%energetic_PBL_CSp, hbl, G, US, m_to_MLD_units=GV%m_to_H)
! if (associated(visc%h_ML)) hbl(:,:) = visc%h_ML(:,:)
! call vertFPmix(up, vp, uold, vold, hbl, h, forces, &
! dt_pred, G, GV, US, CS%vertvisc_CSp, CS%OBC)
! call vertvisc(up, vp, h, forces, visc, dt_pred, CS%OBC, CS%ADp, CS%CDp, G, &
Expand Down
4 changes: 2 additions & 2 deletions src/parameterizations/vertical/MOM_CVMix_ddiff.F90
Original file line number Diff line number Diff line change
Expand Up @@ -245,8 +245,8 @@ subroutine compute_ddiff_coeffs(h, tv, G, GV, US, j, Kd_T, Kd_S, CS, R_rho)
iFaceHeight(k+1) = iFaceHeight(k) - dh
enddo

! gets index of the level and interface above hbl
!kOBL = CVmix_kpp_compute_kOBL_depth(iFaceHeight, cellHeight, GV%Z_to_H*hbl(i,j))
! gets index of the level and interface above hbl in [H ~> m or kg m-2]
!kOBL = CVmix_kpp_compute_kOBL_depth(iFaceHeight, cellHeight, hbl(i,j))

Kd1_T(:) = 0.0 ; Kd1_S(:) = 0.0
call CVMix_coeffs_ddiff(Tdiff_out=Kd1_T(:), &
Expand Down
39 changes: 14 additions & 25 deletions src/parameterizations/vertical/MOM_diabatic_aux.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1064,7 +1064,7 @@ end subroutine diagnoseMLDbyEnergy
subroutine applyBoundaryFluxesInOut(CS, G, GV, US, dt, fluxes, optics, nsw, h, tv, &
aggregate_FW_forcing, evap_CFL_limit, &
minimum_forcing_depth, cTKE, dSV_dT, dSV_dS, &
SkinBuoyFlux, MLD)
SkinBuoyFlux, MLD_h)
type(diabatic_aux_CS), pointer :: CS !< Control structure for diabatic_aux
type(ocean_grid_type), intent(in) :: G !< Grid structure
type(verticalGrid_type), intent(in) :: GV !< ocean vertical grid structure
Expand Down Expand Up @@ -1094,7 +1094,8 @@ subroutine applyBoundaryFluxesInOut(CS, G, GV, US, dt, fluxes, optics, nsw, h, t
!! salinity [R-1 S-1 ~> m3 kg-1 ppt-1].
real, dimension(SZI_(G),SZJ_(G)), &
optional, intent(out) :: SkinBuoyFlux !< Buoyancy flux at surface [Z2 T-3 ~> m2 s-3].
real, pointer, dimension(:,:), optional :: MLD !< Mixed layer depth for brine plumes [Z ~> m]
real, dimension(:,:), &
optional, pointer :: MLD_h !< Mixed layer thickness for brine plumes [H ~> m or kg m-2]

! Local variables
integer, parameter :: maxGroundings = 5
Expand Down Expand Up @@ -1137,8 +1138,6 @@ subroutine applyBoundaryFluxesInOut(CS, G, GV, US, dt, fluxes, optics, nsw, h, t
! [S H T-1 ~> ppt m s-1 or ppt kg m-2 s-1]
netMassInOut_rate, & ! netmassinout but for dt=1 [H T-1 ~> m s-1 or kg m-2 s-1]
mixing_depth, & ! The mixing depth for brine plumes [H ~> m or kg m-2]
MLD_H, & ! The mixed layer depth for brine plumes in thickness units [H ~> m or kg m-2]
MLD_Z, & ! Running sum of distance from the surface for finding MLD_H [Z ~> m]
total_h ! Total thickness of the water column [H ~> m or kg m-2]
real, dimension(SZI_(G), SZK_(GV)) :: &
h2d, & ! A 2-d copy of the thicknesses [H ~> m or kg m-2]
Expand Down Expand Up @@ -1204,11 +1203,15 @@ subroutine applyBoundaryFluxesInOut(CS, G, GV, US, dt, fluxes, optics, nsw, h, t
GoRho = US%L_to_Z**2*GV%g_Earth / GV%Rho0
endif

if (CS%do_brine_plume .and. .not. associated(MLD)) then
if (CS%do_brine_plume .and. .not.present(MLD_h)) then
call MOM_error(FATAL, "MOM_diabatic_aux.F90, applyBoundaryFluxesInOut(): "//&
"Brine plume parameterization requires a mixed-layer depth,\n"//&
"Brine plume parameterization requires a mixed-layer depth argument,\n"//&
"currently coming from the energetic PBL scheme.")
endif
if (CS%do_brine_plume .and. .not.associated(MLD_h)) then
call MOM_error(FATAL, "MOM_diabatic_aux.F90, applyBoundaryFluxesInOut(): "//&
"Brine plume parameterization requires an associated mixed-layer depth.")
endif
if (CS%do_brine_plume .and. .not. associated(fluxes%salt_left_behind)) then
call MOM_error(FATAL, "MOM_diabatic_aux.F90, applyBoundaryFluxesInOut(): "//&
"Brine plume parameterization requires DO_BRINE_PLUME\n"//&
Expand All @@ -1232,7 +1235,7 @@ subroutine applyBoundaryFluxesInOut(CS, G, GV, US, dt, fluxes, optics, nsw, h, t
!$OMP minimum_forcing_depth,evap_CFL_limit,dt,EOSdom, &
!$OMP calculate_buoyancy,netPen_rate,SkinBuoyFlux,GoRho,&
!$OMP calculate_energetics,dSV_dT,dSV_dS,cTKE,g_Hconv2, &
!$OMP EnthalpyConst,MLD) &
!$OMP EnthalpyConst,MLD_h) &
!$OMP private(opacityBand,h2d,T2d,netMassInOut,netMassOut, &
!$OMP netHeat,netSalt,Pen_SW_bnd,fractionOfForcing, &
!$OMP IforcingDepthScale,g_conv,dSpV_dT,dSpV_dS, &
Expand All @@ -1242,7 +1245,7 @@ subroutine applyBoundaryFluxesInOut(CS, G, GV, US, dt, fluxes, optics, nsw, h, t
!$OMP drhodt,drhods,pen_sw_bnd_rate, &
!$OMP pen_TKE_2d,Temp_in,Salin_in,RivermixConst, &
!$OMP mixing_depth,A_brine,fraction_left_brine, &
!$OMP plume_fraction,dK,MLD_H,MLD_Z,total_h) &
!$OMP plume_fraction,dK,total_h) &
!$OMP firstprivate(SurfPressure,plume_flux)
do j=js,je
! Work in vertical slices for efficiency
Expand Down Expand Up @@ -1368,24 +1371,10 @@ subroutine applyBoundaryFluxesInOut(CS, G, GV, US, dt, fluxes, optics, nsw, h, t
! C/ update temp due to penetrative SW
if (CS%do_brine_plume) then
! Find the plume mixing depth.
if (GV%Boussinesq .or. .not.allocated(tv%SpV_avg)) then
do i=is,ie ; MLD_H(i) = GV%Z_to_H * MLD(i,j) ; total_h(i) = 0.0 ; enddo
do k=1,nz ; do i=is,ie ; total_h(i) = total_h(i) + h(i,j,k) ; enddo ; enddo
else
do i=is,ie ; MLD_H(i) = 0.0 ; MLD_Z(i) = 0.0 ; total_h(i) = 0.0 ; enddo
do k=1,nz ; do i=is,ie
total_h(i) = total_h(i) + h(i,j,k)
if (MLD_Z(i) + GV%H_to_RZ * h(i,j,k) * tv%SpV_avg(i,j,k) < MLD(i,j)) then
MLD_H(i) = MLD_H(i) + h(i,j,k)
MLD_Z(i) = MLD_Z(i) + GV%H_to_RZ * h(i,j,k) * tv%SpV_avg(i,j,k)
elseif (MLD_Z(i) < MLD(i,j)) then ! This is the last layer in the mixed layer
MLD_H(i) = MLD_H(i) + GV%RZ_to_H * (MLD(i,j) - MLD_Z(i)) / tv%SpV_avg(i,j,k)
MLD_Z(i) = MLD(i,j)
endif
enddo ; enddo
endif
do i=is,ie ; total_h(i) = 0.0 ; enddo
do k=1,nz ; do i=is,ie ; total_h(i) = total_h(i) + h(i,j,k) ; enddo ; enddo
do i=is,ie
mixing_depth(i) = min( max(MLD_H(i) - minimum_forcing_depth, minimum_forcing_depth), &
mixing_depth(i) = min( max(MLD_h(i,j) - minimum_forcing_depth, minimum_forcing_depth), &
max(total_h(i), GV%angstrom_h) ) + GV%H_subroundoff
A_brine(i) = (CS%brine_plume_n + 1) / (mixing_depth(i) ** (CS%brine_plume_n + 1))
enddo
Expand Down
8 changes: 4 additions & 4 deletions src/parameterizations/vertical/MOM_diabatic_driver.F90
Original file line number Diff line number Diff line change
Expand Up @@ -830,7 +830,7 @@ subroutine diabatic_ALE_legacy(u, v, h, tv, BLD, fluxes, visc, ADp, CDp, dt, Tim
skinbuoyflux(:,:) = 0.0
call applyBoundaryFluxesInOut(CS%diabatic_aux_CSp, G, GV, US, dt, fluxes, CS%optics, &
optics_nbands(CS%optics), h, tv, CS%aggregate_FW_forcing, CS%evap_CFL_limit, &
CS%minimum_forcing_depth, cTKE, dSV_dT, dSV_dS, SkinBuoyFlux=SkinBuoyFlux, MLD=visc%MLD)
CS%minimum_forcing_depth, cTKE, dSV_dT, dSV_dS, SkinBuoyFlux=SkinBuoyFlux, MLD_h=visc%h_ML)

if (CS%debug) then
call hchksum(ent_t, "after applyBoundaryFluxes ent_t", G%HI, haloshift=0, scale=GV%H_to_mks)
Expand Down Expand Up @@ -890,7 +890,7 @@ subroutine diabatic_ALE_legacy(u, v, h, tv, BLD, fluxes, visc, ADp, CDp, dt, Tim
else
call applyBoundaryFluxesInOut(CS%diabatic_aux_CSp, G, GV, US, dt, fluxes, CS%optics, &
optics_nbands(CS%optics), h, tv, CS%aggregate_FW_forcing, &
CS%evap_CFL_limit, CS%minimum_forcing_depth, MLD=visc%MLD)
CS%evap_CFL_limit, CS%minimum_forcing_depth, MLD_h=visc%h_ML)

! Find the vertical distances across layers, which may have been modified by the net surface flux
call thickness_to_dz(h, tv, dz, G, GV, US)
Expand Down Expand Up @@ -1378,7 +1378,7 @@ subroutine diabatic_ALE(u, v, h, tv, BLD, fluxes, visc, ADp, CDp, dt, Time_end,
skinbuoyflux(:,:) = 0.0
call applyBoundaryFluxesInOut(CS%diabatic_aux_CSp, G, GV, US, dt, fluxes, CS%optics, &
optics_nbands(CS%optics), h, tv, CS%aggregate_FW_forcing, CS%evap_CFL_limit, &
CS%minimum_forcing_depth, cTKE, dSV_dT, dSV_dS, SkinBuoyFlux=SkinBuoyFlux, MLD=visc%MLD)
CS%minimum_forcing_depth, cTKE, dSV_dT, dSV_dS, SkinBuoyFlux=SkinBuoyFlux, MLD_h=visc%h_ML)

if (CS%debug) then
call hchksum(ent_t, "after applyBoundaryFluxes ent_t", G%HI, haloshift=0, scale=GV%H_to_MKS)
Expand Down Expand Up @@ -1424,7 +1424,7 @@ subroutine diabatic_ALE(u, v, h, tv, BLD, fluxes, visc, ADp, CDp, dt, Time_end,
else
call applyBoundaryFluxesInOut(CS%diabatic_aux_CSp, G, GV, US, dt, fluxes, CS%optics, &
optics_nbands(CS%optics), h, tv, CS%aggregate_FW_forcing, &
CS%evap_CFL_limit, CS%minimum_forcing_depth, MLD=visc%MLD)
CS%evap_CFL_limit, CS%minimum_forcing_depth, MLD_h=visc%h_ML)

endif ! endif for CS%use_energetic_PBL

Expand Down
29 changes: 24 additions & 5 deletions src/parameterizations/vertical/MOM_set_viscosity.F90
Original file line number Diff line number Diff line change
Expand Up @@ -2680,6 +2680,7 @@ subroutine set_visc_register_restarts(HI, G, GV, US, param_file, visc, restart_C
! Local variables
logical :: use_kappa_shear, KS_at_vertex
logical :: adiabatic, useKPP, useEPBL
logical :: do_brine_plume, use_hor_bnd_diff, use_neutral_diffusion, use_fpmix
logical :: use_CVMix_shear, MLE_use_PBL_MLD, MLE_use_Bodner, use_CVMix_conv
integer :: isd, ied, jsd, jed, nz
real :: hfreeze !< If hfreeze > 0 [Z ~> m], melt potential will be computed.
Expand Down Expand Up @@ -2743,25 +2744,43 @@ subroutine set_visc_register_restarts(HI, G, GV, US, param_file, visc, restart_C
call safe_alloc_ptr(visc%Kv_slow, isd, ied, jsd, jed, nz+1)
endif

! visc%MLD is used to communicate the state of the (e)PBL or KPP to the rest of the model
! visc%MLD and visc%h_ML are used to communicate the state of the (e)PBL or KPP to the rest of the model
call get_param(param_file, mdl, "MLE_USE_PBL_MLD", MLE_use_PBL_MLD, &
default=.false., do_not_log=.true.)
! visc%MLD needs to be allocated when melt potential is computed (HFREEZE>0)
! visc%h_ML needs to be allocated when melt potential is computed (HFREEZE>0) or one of
! several other parameterizations are in use.
call get_param(param_file, mdl, "HFREEZE", hfreeze, &
units="m", default=-1.0, scale=US%m_to_Z, do_not_log=.true.)
call get_param(param_file, mdl, "DO_BRINE_PLUME", do_brine_plume, &
"If true, use a brine plume parameterization from Nguyen et al., 2009.", &
default=.false., do_not_log=.true.)
call get_param(param_file, mdl, "USE_HORIZONTAL_BOUNDARY_DIFFUSION", use_hor_bnd_diff, &
default=.false., do_not_log=.true.)
call get_param(param_file, mdl, "USE_NEUTRAL_DIFFUSION", use_neutral_diffusion, &
default=.false., do_not_log=.true.)
if (use_neutral_diffusion) &
call get_param(param_file, mdl, "NDIFF_INTERIOR_ONLY", use_neutral_diffusion, &
default=.false., do_not_log=.true.)
call get_param(param_file, mdl, "FPMIX", use_fpmix, &
default=.false., do_not_log=.true.)

if (hfreeze >= 0.0 .or. MLE_use_PBL_MLD) then
if (MLE_use_PBL_MLD) then
call safe_alloc_ptr(visc%MLD, isd, ied, jsd, jed)
endif
if (hfreeze >= 0.0 .or. MLE_use_PBL_MLD) then
if ((hfreeze >= 0.0) .or. MLE_use_PBL_MLD .or. do_brine_plume .or. use_fpmix .or. &
use_neutral_diffusion .or. use_hor_bnd_diff) then
call safe_alloc_ptr(visc%h_ML, isd, ied, jsd, jed)
endif

if (MLE_use_PBL_MLD) then
call register_restart_field(visc%MLD, "MLD", .false., restart_CS, &
"Instantaneous active mixing layer depth", units="m", conversion=US%Z_to_m)
endif
if (MLE_use_PBL_MLD .or. do_brine_plume .or. use_fpmix .or. &
use_neutral_diffusion .or. use_hor_bnd_diff) then
call register_restart_field(visc%h_ML, "h_ML", .false., restart_CS, &
"Instantaneous active mixing layer thickness", units=get_thickness_units(GV), conversion=GV%H_to_mks)
"Instantaneous active mixing layer thickness", &
units=get_thickness_units(GV), conversion=GV%H_to_mks)
endif

! visc%sfc_buoy_flx is used to communicate the state of the (e)PBL or KPP to the rest of the model
Expand Down
Loading

0 comments on commit df2e4b0

Please sign in to comment.