Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions dependencies.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ casim:
ref: 2026.07.1

jules:
source: git@github.com:MetOffice/jules.git
ref: 2026.07.1
source: git@github.com:DanCopsey/jules.git
ref: zenith_angle_seaice

lfric_apps:
source:
Expand Down
1 change: 1 addition & 0 deletions interfaces/jules_interface/build/extract.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ jules:
- src/science/params/veg_param_mod.F90
- src/science/radiation/Jin11_osa_mod.F90
- src/science/radiation/albpft_jls_mod.F90
- src/science/radiation/albpond_mod.F90
- src/science/radiation/albsnow_jls_mod.F90
- src/science/radiation/albsnow_ts_jls_mod.F90
- src/science/radiation/calc_direct_albsoil_mod.F90
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,10 @@ module jules_physics_init_mod
i_high_wind_drag_null, &
i_high_wind_drag_limited, &
i_high_wind_drag_reduced_v1, &
buddy_sea_on
buddy_sea_on, &
meltpond_alb_vn_none, &
meltpond_alb_vn_cice, &
meltpond_alb_vn_malinka
use jules_snow_config_mod, only : &
i_basal_melting_opt_none, &
i_basal_melting_opt_instant, &
Expand Down Expand Up @@ -128,13 +131,16 @@ subroutine jules_physics_init(config)
ip_ss_coare_mq, a_chrn_coare, b_chrn_coare, u10_max_coare, &
l_10m_neut, alpham, dtice, l_iceformdrag_lupkes, &
l_stability_lupkes, l_use_dtstar_sea, hcap_sea, beta_evap, &
l_sice_meltponds, l_sice_meltponds_cice, &
l_sice_meltponds, i_meltpond_alb_vn, l_zenith_albedo, &
snow_grain_size_min, snow_grain_size_max, snowpatch, &
l_cice_alb, l_saldep_freeze, l_sice_multilayers, &
l_sice_scattering, l_sice_swpen, l_ssice_albedo, &
pen_rad_frac_cice, sw_beta_cice, &
buddy_sea, cdn_hw_sea, cdn_max_sea, u_cdn_hw, u_cdn_max, &
i_high_wind_drag, ip_hwdrag_null, ip_hwdrag_limited, &
ip_hwdrag_reduced_v1
ip_hwdrag_reduced_v1, &
ip_meltpond_alb_vn_none, ip_meltpond_alb_vn_cice, &
ip_meltpond_alb_vn_malinka
use jules_snow_mod, only: check_jules_snow, &
cansnowpft, nsmax, a_snow_et, b_snow_et, c_snow_et, can_clump, &
dzsnow, frac_snow_subl_melt, i_snow_cond_parm, l_et_metamorph, &
Expand Down Expand Up @@ -295,12 +301,25 @@ subroutine jules_physics_init(config)
z0h_z0m_miz = 0.2_r_um
z0h_z0m_sice = 0.2_r_um
z0sice = 5.0e-4_r_um
l_zenith_albedo = config%jules_sea_seaice%l_zenith_albedo()
snow_grain_size_min = real(config%jules_sea_seaice%snow_grain_size_min(), r_um)
snow_grain_size_max = real(config%jules_sea_seaice%snow_grain_size_max(), r_um)
snowpatch = real(config%jules_sea_seaice%snowpatch(), r_um)

! Setup the melt pond albedo scheme
select case (config%jules_sea_seaice%meltpond_alb_vn())
case(meltpond_alb_vn_none)
i_meltpond_alb_vn = ip_meltpond_alb_vn_none
case(meltpond_alb_vn_cice)
i_meltpond_alb_vn = ip_meltpond_alb_vn_cice
case(meltpond_alb_vn_malinka)
i_meltpond_alb_vn = ip_meltpond_alb_vn_malinka
end select

! Setup switches that vary depending if the model is
! coupled to an ocean/sea-ice model or not.
if (l_couple_sea_ice) then
l_sice_meltponds = .true.
l_sice_meltponds_cice = .true.
l_tstar_sice_new = .false.
l_cice_alb = .true.
l_sice_multilayers = .true.
Expand All @@ -311,7 +330,6 @@ subroutine jules_physics_init(config)
sw_beta_cice = 0.3_r_um
else
l_sice_meltponds = .false.
l_sice_meltponds_cice = .false.
l_tstar_sice_new = .true.
l_cice_alb = .false.
l_sice_multilayers = .false.
Expand Down
25 changes: 25 additions & 0 deletions science/shared/rose-meta/lfric-shared/versions.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,28 @@ def upgrade(self, config, meta_config=None):
# Add settings
return config, self.reports
"""


class vn31_t400(MacroUpgrade):
"""Upgrade macro for ticket #400 by Dan Copsey."""

BEFORE_TAG = "vn3.2"
AFTER_TAG = "vn3.2_t400"

def upgrade(self, config, meta_config=None):

# Is this a coupled model? The easiest way to get this is from the number of sea ice categories.
nice = int(self.get_setting_value(config, ["namelist:jules_sea_seaice", "nice"]))
is_coupled = nice > 1

# Add the new namelist settings
self.add_setting(config, ["namelist:jules_sea_seaice", "l_zenith_albedo"], ".true.")
if is_coupled:
self.add_setting(config, ["namelist:jules_sea_seaice", "meltpond_alb_vn"], "'malinka'")
else:
self.add_setting(config, ["namelist:jules_sea_seaice", "meltpond_alb_vn"], "'none'")
self.add_setting(config, ["namelist:jules_sea_seaice", "snow_grain_size_max"], "140.0")
self.add_setting(config, ["namelist:jules_sea_seaice", "snow_grain_size_min"], "70.0")
self.add_setting(config, ["namelist:jules_sea_seaice", "snowpatch"], "0.02")

return config, self.reports
Loading