Skip to content

Commit

Permalink
deprecate old ridging participation and redistribution functions
Browse files Browse the repository at this point in the history
  • Loading branch information
eclare108213 committed Jul 28, 2022
1 parent 1dad4f9 commit 8aa2f36
Show file tree
Hide file tree
Showing 9 changed files with 214 additions and 61 deletions.
144 changes: 120 additions & 24 deletions columnphysics/icepack_mechred.F90

Large diffs are not rendered by default.

83 changes: 59 additions & 24 deletions columnphysics/icepack_parameters.F90
Original file line number Diff line number Diff line change
Expand Up @@ -219,13 +219,17 @@ module icepack_parameters
!-----------------------------------------------------------------------

integer (kind=int_kind), public :: & ! defined in namelist
#ifdef UNDEPRECATE_KRDG0
kstrength = 1, & ! 0 for simple Hibler (1979) formulation
! 1 for Rothrock (1975) pressure formulation
krdg_partic = 1, & ! 0 for Thorndike et al. (1975) formulation
! 1 for exponential participation function
krdg_redist = 1 ! 0 for Hibler (1980) formulation
! 1 for exponential redistribution function

#else
kstrength = 1 ! 0 for simple Hibler (1979) formulation
! 1 for Rothrock (1975) pressure formulation
#endif
real (kind=dbl_kind), public :: &
Cf = 17._dbl_kind ,&! ratio of ridging work to PE change in ridging
Pstar = 2.75e4_dbl_kind ,&! constant in Hibler strength formula
Expand All @@ -236,9 +240,12 @@ module icepack_parameters
thickness_ocn_layer1 = 2.0_dbl_kind,&! thickness of first ocean level (m)
iceruf_ocn = 0.03_dbl_kind ,&! under-ice roughness (m)
gravit = 9.80616_dbl_kind ,&! gravitational acceleration (m/s^2)
#ifdef UNDEPRECATE_KRDG0
mu_rdg = 3.0_dbl_kind ! e-folding scale of ridged ice, krdg_partic=1 (m^0.5)
! (krdg_redist = 1)

#else
mu_rdg = 3.0_dbl_kind ! e-folding scale of ridged ice (m^0.5)
#endif
logical (kind=log_kind), public :: &
calc_dragio = .false. ! if true, calculate dragio from iceruf_ocn and thickness_ocn_layer1

Expand Down Expand Up @@ -459,7 +466,11 @@ subroutine icepack_init_parameters( &
phi_i_mushy_in, shortwave_in, albedo_type_in, albsnowi_in, &
albicev_in, albicei_in, albsnowv_in, &
ahmax_in, R_ice_in, R_pnd_in, R_snw_in, dT_mlt_in, rsnw_mlt_in, &
#ifdef UNDEPRECATE_KRDG0
kalg_in, kstrength_in, krdg_partic_in, krdg_redist_in, mu_rdg_in, &
#else
kalg_in, kstrength_in, mu_rdg_in, &
#endif
atmbndy_in, calc_strair_in, formdrag_in, highfreq_in, natmiter_in, &
atmiter_conv_in, calc_dragio_in, &
tfrz_option_in, kitd_in, kcatbound_in, hs0_in, frzpnd_in, &
Expand Down Expand Up @@ -633,26 +644,33 @@ subroutine icepack_init_parameters( &
!-----------------------------------------------------------------------

real(kind=dbl_kind), intent(in), optional :: &
Cf_in, & ! ratio of ridging work to PE change in ridging
Pstar_in, & ! constant in Hibler strength formula
Cstar_in, & ! constant in Hibler strength formula
Cf_in, & ! ratio of ridging work to PE change in ridging
Pstar_in, & ! constant in Hibler strength formula
Cstar_in, & ! constant in Hibler strength formula
dragio_in, & ! ice-ocn drag coefficient
thickness_ocn_layer1_in, & ! thickness of first ocean level (m)
iceruf_ocn_in, & ! under-ice roughness (m)
gravit_in, & ! gravitational acceleration (m/s^2)
iceruf_in ! ice surface roughness (m)

integer (kind=int_kind), intent(in), optional :: & ! defined in namelist
kstrength_in , & ! 0 for simple Hibler (1979) formulation
! 1 for Rothrock (1975) pressure formulation
krdg_partic_in, & ! 0 for Thorndike et al. (1975) formulation
! 1 for exponential participation function
krdg_redist_in ! 0 for Hibler (1980) formulation
! 1 for exponential redistribution function
#ifdef UNDEPRECATE_KRDG0
kstrength_in , & ! 0 for simple Hibler (1979) formulation
! 1 for Rothrock (1975) pressure formulation
krdg_partic_in, & ! 0 for Thorndike et al. (1975) formulation
! 1 for exponential participation function
krdg_redist_in ! 0 for Hibler (1980) formulation
! 1 for exponential redistribution function
#else
kstrength_in ! 0 for simple Hibler (1979) formulation
! 1 for Rothrock (1975) pressure formulation
#endif

real (kind=dbl_kind), intent(in), optional :: &
mu_rdg_in ! gives e-folding scale of ridged ice (m^.5)
! (krdg_redist = 1)
mu_rdg_in ! gives e-folding scale of ridged ice (m^.5)
#ifdef UNDEPRECATE_KRDG0
! (krdg_redist = 1)
#endif

logical (kind=log_kind), intent(in), optional :: &
calc_dragio_in ! if true, calculate dragio from iceruf_ocn and thickness_ocn_layer1
Expand Down Expand Up @@ -928,8 +946,10 @@ subroutine icepack_init_parameters( &
if (present(rsnw_mlt_in) ) rsnw_mlt = rsnw_mlt_in
if (present(kalg_in) ) kalg = kalg_in
if (present(kstrength_in) ) kstrength = kstrength_in
#ifdef UNDEPRECATE_KRDG0
if (present(krdg_partic_in) ) krdg_partic = krdg_partic_in
if (present(krdg_redist_in) ) krdg_redist = krdg_redist_in
#endif
if (present(mu_rdg_in) ) mu_rdg = mu_rdg_in
if (present(atmbndy_in) ) atmbndy = atmbndy_in
if (present(calc_strair_in) ) calc_strair = calc_strair_in
Expand Down Expand Up @@ -1150,7 +1170,11 @@ subroutine icepack_query_parameters( &
albedo_type_out, albicev_out, albicei_out, albsnowv_out, &
albsnowi_out, ahmax_out, R_ice_out, R_pnd_out, R_snw_out, dT_mlt_out, &
rsnw_mlt_out, dEdd_algae_out, &
#ifdef UNDEPRECATE_KRDG0
kalg_out, kstrength_out, krdg_partic_out, krdg_redist_out, mu_rdg_out, &
#else
kalg_out, kstrength_out, mu_rdg_out, &
#endif
atmbndy_out, calc_strair_out, formdrag_out, highfreq_out, natmiter_out, &
atmiter_conv_out, calc_dragio_out, &
tfrz_option_out, kitd_out, kcatbound_out, hs0_out, frzpnd_out, &
Expand Down Expand Up @@ -1333,26 +1357,33 @@ subroutine icepack_query_parameters( &
!-----------------------------------------------------------------------

real(kind=dbl_kind), intent(out), optional :: &
Cf_out, & ! ratio of ridging work to PE change in ridging
Pstar_out, & ! constant in Hibler strength formula
Cstar_out, & ! constant in Hibler strength formula
Cf_out, & ! ratio of ridging work to PE change in ridging
Pstar_out, & ! constant in Hibler strength formula
Cstar_out, & ! constant in Hibler strength formula
dragio_out, & ! ice-ocn drag coefficient
thickness_ocn_layer1_out, & ! thickness of first ocean level (m)
iceruf_ocn_out, & ! under-ice roughness (m)
gravit_out, & ! gravitational acceleration (m/s^2)
iceruf_out ! ice surface roughness (m)

integer (kind=int_kind), intent(out), optional :: & ! defined in namelist
kstrength_out , & ! 0 for simple Hibler (1979) formulation
! 1 for Rothrock (1975) pressure formulation
krdg_partic_out, & ! 0 for Thorndike et al. (1975) formulation
! 1 for exponential participation function
krdg_redist_out ! 0 for Hibler (1980) formulation
! 1 for exponential redistribution function
#ifdef UNDEPRECATE_KRDG0
kstrength_out , & ! 0 for simple Hibler (1979) formulation
! 1 for Rothrock (1975) pressure formulation
krdg_partic_out, & ! 0 for Thorndike et al. (1975) formulation
! 1 for exponential participation function
krdg_redist_out ! 0 for Hibler (1980) formulation
! 1 for exponential redistribution function
#else
kstrength_out ! 0 for simple Hibler (1979) formulation
! 1 for Rothrock (1975) pressure formulation
#endif

real (kind=dbl_kind), intent(out), optional :: &
mu_rdg_out ! gives e-folding scale of ridged ice (m^.5)
! (krdg_redist = 1)
mu_rdg_out ! gives e-folding scale of ridged ice (m^.5)
#ifdef UNDEPRECATE_KRDG0
! (krdg_redist = 1)
#endif

logical (kind=log_kind), intent(out), optional :: &
calc_dragio_out ! if true, compute dragio from iceruf_ocn and thickness_ocn_layer1
Expand Down Expand Up @@ -1668,8 +1699,10 @@ subroutine icepack_query_parameters( &
if (present(rsnw_mlt_out) ) rsnw_mlt_out = rsnw_mlt
if (present(kalg_out) ) kalg_out = kalg
if (present(kstrength_out) ) kstrength_out = kstrength
#ifdef UNDEPRECATE_KRDG0
if (present(krdg_partic_out) ) krdg_partic_out = krdg_partic
if (present(krdg_redist_out) ) krdg_redist_out = krdg_redist
#endif
if (present(mu_rdg_out) ) mu_rdg_out = mu_rdg
if (present(atmbndy_out) ) atmbndy_out = atmbndy
if (present(calc_strair_out) ) calc_strair_out = calc_strair
Expand Down Expand Up @@ -1876,8 +1909,10 @@ subroutine icepack_write_parameters(iounit)
write(iounit,*) " rsnw_mlt = ", rsnw_mlt
write(iounit,*) " kalg = ", kalg
write(iounit,*) " kstrength = ", kstrength
#ifdef UNDEPRECATE_KRDG0
write(iounit,*) " krdg_partic = ", krdg_partic
write(iounit,*) " krdg_redist = ", krdg_redist
#endif
write(iounit,*) " mu_rdg = ", mu_rdg
write(iounit,*) " atmbndy = ", atmbndy
write(iounit,*) " calc_strair = ", calc_strair
Expand Down
18 changes: 18 additions & 0 deletions configuration/driver/icedrv_init.F90
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,11 @@ subroutine input_data
rsnw_fall, rsnw_tmax, rhosnew, rhosmin, rhosmax, &
windmin, drhosdwind, snwlvlfac

#ifdef UNDEPRECATE_KRDG0
integer (kind=int_kind) :: ktherm, kstrength, krdg_partic, krdg_redist, &
#else
integer (kind=int_kind) :: ktherm, kstrength, &
#endif
natmiter, kitd, kcatbound

character (len=char_len) :: shortwave, albedo_type, conduct, fbot_xfer_type, &
Expand Down Expand Up @@ -143,8 +147,12 @@ subroutine input_data
floediam, hfrazilmin

namelist /dynamics_nml/ &
#ifdef UNDEPRECATE_KRDG0
kstrength, krdg_partic, krdg_redist, mu_rdg, &
Cf
#else
kstrength, mu_rdg, Cf
#endif

namelist /shortwave_nml/ &
shortwave, albedo_type, &
Expand Down Expand Up @@ -199,8 +207,12 @@ subroutine input_data
atmiter_conv_out = atmiter_conv, calc_dragio_out=calc_dragio, &
albedo_type_out=albedo_type, R_ice_out=R_ice, R_pnd_out=R_pnd, &
R_snw_out=R_snw, dT_mlt_out=dT_mlt, rsnw_mlt_out=rsnw_mlt, &
#ifdef UNDEPRECATE_KRDG0
kstrength_out=kstrength, krdg_partic_out=krdg_partic, &
krdg_redist_out=krdg_redist, mu_rdg_out=mu_rdg, &
#else
kstrength_out=kstrength, mu_rdg_out=mu_rdg, &
#endif
atmbndy_out=atmbndy, calc_strair_out=calc_strair, &
formdrag_out=formdrag, highfreq_out=highfreq, &
emissivity_out=emissivity, &
Expand Down Expand Up @@ -654,11 +666,13 @@ subroutine input_data
kcatbound
write(nu_diag,1020) ' ndtd = ', ndtd
write(nu_diag,1020) ' kstrength = ', kstrength
#ifdef UNDEPRECATE_KRDG0
write(nu_diag,1020) ' krdg_partic = ', &
krdg_partic
write(nu_diag,1020) ' krdg_redist = ', &
krdg_redist
if (krdg_redist == 1) &
#endif
write(nu_diag,1000) ' mu_rdg = ', mu_rdg
if (kstrength == 1) &
write(nu_diag,1000) ' Cf = ', Cf
Expand Down Expand Up @@ -938,8 +952,12 @@ subroutine input_data
atmiter_conv_in = atmiter_conv, calc_dragio_in=calc_dragio, &
albedo_type_in=albedo_type, R_ice_in=R_ice, R_pnd_in=R_pnd, &
R_snw_in=R_snw, dT_mlt_in=dT_mlt, rsnw_mlt_in=rsnw_mlt, &
#ifdef UNDEPRECATE_KRDG0
kstrength_in=kstrength, krdg_partic_in=krdg_partic, &
krdg_redist_in=krdg_redist, mu_rdg_in=mu_rdg, &
#else
kstrength_in=kstrength, mu_rdg_in=mu_rdg, &
#endif
atmbndy_in=atmbndy, calc_strair_in=calc_strair, &
formdrag_in=formdrag, highfreq_in=highfreq, &
emissivity_in=emissivity, &
Expand Down
2 changes: 0 additions & 2 deletions configuration/scripts/icepack_in
Original file line number Diff line number Diff line change
Expand Up @@ -133,8 +133,6 @@

&dynamics_nml
kstrength = 1
krdg_partic = 1
krdg_redist = 1
mu_rdg = 3
Cf = 17.
/
Expand Down
2 changes: 0 additions & 2 deletions configuration/scripts/options/set_nml.alt04
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@
sw_dtemp = 0.02d0
tfrz_option = 'linear_salt'
conduct = 'bubbly'
krdg_partic = 0
krdg_redist = 0
calc_Tsfc = .true.
highfreq = .true.
update_ocn_f = .true.
Expand Down
2 changes: 0 additions & 2 deletions configuration/scripts/options/set_nml.dyn
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
ndtd = 2
kstrength = 0
krdg_partic = 0
krdg_redist = 0
formdrag = .false.
atmbndy = 'constant'
highfreq = .false.
14 changes: 9 additions & 5 deletions doc/source/icepack_index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ either Celsius or Kelvin units).
"**G**", "", ""
"gravit", "gravitational acceleration", "9.80616 m/s\ :math:`^2`"
"grow_net", "specific biogeochemistry growth rate per grid cell", "s :math:`^{-1}`"
"Gstar", "piecewise-linear ridging participation function parameter", "0.15"
"Gstar", "DEPRECATED", ""
"**H**", "", ""
"H2_16O_ocn", "concentration of H2_16O isotope in ocean", "kg/kg"
"H2_18O_ocn", "concentration of H2_18O isotope in ocean", "kg/kg"
Expand All @@ -221,7 +221,7 @@ either Celsius or Kelvin units).
"hs0", ":math:`\bullet` snow depth at which transition to ice occurs (dEdd)", "0.03 m"
"hs1", ":math:`\bullet` snow depth of transition to pond ice", "0.03 m"
"hs_ssl", "snow surface scattering layer thickness", "0.04 m"
"Hstar", "determines mean thickness of ridged ice", "25. m"
"Hstar", "DEPRECATED", ""
"**I**", "", ""
"i0vis","fraction of penetrating visible solar radiation", "0.70"
"ice_ic", ":math:`\bullet` choice of initial conditions", ""
Expand All @@ -247,8 +247,8 @@ either Celsius or Kelvin units).
"kg_to_g", "kg to g conversion factor", "1000."
"kice", "thermal conductivity of fresh ice (:cite:`Bitz99`)", "2.03 W/m/deg"
"kitd", ":math:`\bullet` type of itd conversions (0 = delta function, 1 = linear remap)", "1"
"krdg_partic", ":math:`\bullet` ridging participation function", "1"
"krdg_redist", ":math:`\bullet` ridging redistribution function", "1"
"krdg_partic", "DEPRECATED", ""
"krdg_redist", "DEPRECATED", ""
"krdgn", "mean ridge thickness per thickness of ridging ice", ""
"kseaice", "DEPRECATED", ""
"ksno", "thermal conductivity of snow", "0.30 W/m/deg"
Expand Down Expand Up @@ -533,6 +533,10 @@ either Celsius or Kelvin units).
"heat_capacity", ":math:`\bullet` if true, use salinity-dependent thermodynamics", "T"
"kseaice", "thermal conductivity of ice for zero-layer thermodynamics", "2.0 W/m/deg"
"ktherm", ":math:`\bullet` thermodynamic formulation (0 = zero-layer, 1 = :cite:`Bitz99`, 2 = mushy)", ""
old ridging participation and redistribution functions are being deprecated
"krdg_partic", ":math:`\bullet` ridging participation function", "1"
"krdg_redist", ":math:`\bullet` ridging redistribution function", "1"
"Gstar", "piecewise-linear ridging participation function parameter", "0.15"
"Hstar", "determines mean thickness of ridged ice", "25. m"

2 changes: 2 additions & 0 deletions doc/source/science_guide/sg_mechanical.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ ice and is applied after horizontal transport. When the ice is
converging, enough ice ridges to ensure that the ice area does not
exceed the grid cell area.

*Note that the older ridging and participation functions (``krdg_partic`` = 0 and ``krdg_redist`` = 0) have been deprecated.*

First we specify the participation function: the thickness distribution
:math:`a_P(h) = b(h) \, g(h)` of the ice participating in ridging. (We
use "ridging" as shorthand for all forms of mechanical redistribution,
Expand Down
8 changes: 6 additions & 2 deletions doc/source/user_guide/ug_case_settings.rst
Original file line number Diff line number Diff line change
Expand Up @@ -230,12 +230,16 @@ dynamics_nml
"``Cf``", "real", "ratio of ridging work to PE change in ridging", "17.0"
"``kstrength``", "``0``", "ice strength formulation :cite:`Hibler79`", "1"
"", "``1``", "ice strength formulation :cite:`Rothrock75`", ""
"``mu_rdg``", "real", "e-folding scale of ridged ice in m^0.5", "3.0"
"", "", "", ""

..
krdg_partic=0 and krdg_redist=0 are being deprecated.
Both flags are being removed using their values = 1 as the default.
"``krdg_partic``", "``0``", "old ridging participation function", "1"
"", "``1``", "new ridging participation function", ""
"``krdg_redist``", "``0``", "old ridging redistribution function", "1"
"", "``1``", "new ridging redistribution function", ""
"``mu_rdg``", "real", "e-folding scale of ridged ice for ``krdg_partic`` = 1 in m^0.5", "3.0"
"", "", "", ""
shortwave_nml
~~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down

0 comments on commit 8aa2f36

Please sign in to comment.