subroutine register_ocean_ice(cfg, schema)
!! `&ocean_ice_nml`: sea-ice model switch + category/layer counts
!! (SIS2 port scaffold) + the PR-3c v1 restoring atmospheric-forcing
!! scalars. Default off ⇒ byte-identical.
type(config_t), target, intent(in) :: cfg
type(nml_schema_t), intent(inout) :: schema
type(nml_group_t) :: g
logical, pointer :: pl
integer, pointer :: pi
real(wp), pointer :: pr
real(wp), pointer :: pra(:)
g%name = "ocean_ice"
g%doc = "Sea-ice model (SIS2 port) master switch + category/layer counts."
pl => cfg%ocean%ice%enable
call g%add(nml_logical("enable", pl, &
"Master switch for the sea-ice slot (default off => byte-identical)"))
pi => cfg%ocean%ice%ncat
call g%add(nml_int("ncat", pi, &
"Number of ice thickness categories (cat 0 = open water)", min=1))
pra => cfg%ocean%ice%hlim
call g%add(nml_real_array("hlim", pra, &
"ITD category lower thickness edges; unset => SIS2 default table", &
units="m"))
pi => cfg%ocean%ice%nk_ice
call g%add(nml_int("nk_ice", pi, &
"Vertical ice layers per category (2 = Winton two-layer)", min=1))
pr => cfg%ocean%ice%air_temp
call g%add(nml_real("air_temp", pr, &
"Prescribed slab-atmosphere air temperature for the v1 restoring filler", &
units="degC"))
pr => cfg%ocean%ice%restore_lambda
call g%add(nml_real("restore_lambda", pr, &
"Surface-flux restoring coefficient dSF/dT (0 = passive column)", &
units="W/m^2/K", min=0.0_wp))
pr => cfg%ocean%ice%sw_down
call g%add(nml_real("sw_down", pr, &
"Downwelling shortwave into the ice top for the v1 filler", &
units="W/m^2", min=0.0_wp))
pr => cfg%ocean%ice%snowfall
call g%add(nml_real("snowfall", pr, &
"Uniform frozen-precipitation rate onto the ice top for the v1 filler", &
units="kg/m^2/s", min=0.0_wp))
pl => cfg%ocean%ice%snow_ice
call g%add(nml_logical("snow_ice", pl, &
"Enable Archimedes snow-ice flooding conversion "// &
"(SIS2 SN2IC; default off => byte-identical)"))
pl => cfg%ocean%ice%transport
call g%add(nml_logical("transport", pl, &
"Enable horizontal category ice/snow transport "// &
"(default off => byte-identical)"))
pi => cfg%ocean%ice%adv_substeps
call g%add(nml_int("adv_substeps", pi, &
"Advective sub-iterations per transport call (SIS2 NSTEPS_ADV)", min=1))
pr => cfg%ocean%ice%roll_factor
call g%add(nml_real("roll_factor", pr, &
"Thin-ice rolling floor factor (SIS2 SEA_ICE_ROLL_FACTOR); 0 disables rolling", &
min=0.0_wp))
pl => cfg%ocean%ice%dynamics
call g%add(nml_logical("dynamics", pl, &
"Enable C-grid EVP ice dynamics (default off => byte-identical)"))
pl => cfg%ocean%ice%a_face_stress
call g%add(nml_logical("a_face_stress", pl, &
"Weight EVP wind stress + ice-ocean drag by face ice "// &
"concentration (momentum-conserving; default off => byte-identical)"))
pr => cfg%ocean%ice%p0
call g%add(nml_real("p0", pr, &
"Ice-strength pressure constant (SIS2 ICE_STRENGTH_PSTAR)", &
units="Pa", min=0.0_wp))
pr => cfg%ocean%ice%c0
call g%add(nml_real("c0", pr, &
"Ice-strength exponent constant (SIS2 ICE_STRENGTH_CSTAR)", &
min=0.0_wp))
pr => cfg%ocean%ice%ec
call g%add(nml_real("ec", pr, &
"Yield-curve axis ratio (SIS2 ICE_YIELD_ELLIPTICITY); 0 = cavitating fluid", &
min=0.0_wp))
pr => cfg%ocean%ice%cdw
call g%add(nml_real("cdw", pr, &
"Ice-ocean drag coefficient (SIS2 ICE_CDRAG_WATER)", min=0.0_wp))
pr => cfg%ocean%ice%rho_ocean
call g%add(nml_real("rho_ocean", pr, &
"Ice-drag reference density (SIS2 RHO_OCEAN)", &
units="kg/m^3", min=0.0_wp))
pi => cfg%ocean%ice%evp_sub_steps
call g%add(nml_int("evp_sub_steps", pi, &
"EVP subcycles per slow step (SIS2 NSTEPS_DYN)", min=1))
pr => cfg%ocean%ice%del_sh_min_scale
call g%add(nml_real("del_sh_min_scale", pr, &
"Viscosity-floor scale (SIS2 ICE_DEL_SH_MIN_SCALE)", min=0.0_wp))
pr => cfg%ocean%ice%tdamp
call g%add(nml_real("tdamp", pr, &
"Elastic damping timescale rule (SIS2 ICE_TDAMP_ELASTIC): "// &
">0 seconds, ==0 auto (0.2*dt_slow), <0 fraction of dt_slow"))
pr => cfg%ocean%ice%cfl_trunc
call g%add(nml_real("cfl_trunc", pr, &
"Transport-CFL ceiling on the final ice velocity "// &
"(SIS2 CFL_TRUNCATE, default 0.5 there); 0 disables", min=0.0_wp))
pl => cfg%ocean%ice%cfl_trunc_dyn_its
call g%add(nml_logical("cfl_trunc_dyn_its", pl, &
"Also clip the ice velocity every EVP subcycle "// &
"(SIS2 CFL_TRUNC_DYN_ITS)"))
pl => cfg%ocean%ice%project_ci
call g%add(nml_logical("project_ci", pl, &
"Project ice concentration forward within the EVP "// &
"subcycle loop and recompute the ice strength "// &
"(SIS2 PROJECT_ICE_CONCENTRATION)"))
call schema%add_group(g)
end subroutine register_ocean_ice