Skip to content
Merged
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 .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ fxDONOTUSEurl = https://github.com/ESCOMP/mizuRoute
[submodule "ccs_config"]
path = ccs_config
url = https://github.com/NorESMhub/ccs_config_noresm.git
fxtag = ccs_config_noresm0.0.55
fxtag = ccs_config_noresm0.0.56
fxrequired = ToplevelRequired
# Standard Fork to compare to with "git fleximod test" to ensure personal forks aren't committed
fxDONOTUSEurl = https://github.com/NorESMhub/ccs_config_noresm
Expand All @@ -92,7 +92,7 @@ fxDONOTUSEurl = https://github.com/NorESMhub/CMEPS.git
[submodule "cdeps"]
path = components/cdeps
url = https://github.com/NorESMhub/CDEPS.git
fxtag = cdeps1.0.83_noresm_v2
fxtag = cdeps1.0.88_noresm_v0
fxrequired = ToplevelRequired
# Standard Fork to compare to with "git fleximod test" to ensure personal forks aren't committed
fxDONOTUSEurl = https://github.com/NorESMhub/CDEPS.git
Expand Down
2 changes: 1 addition & 1 deletion components/cdeps
Submodule cdeps updated 74 files
+5 −5 .github/workflows/extbuild.yml
+2 −1 cime_config/stream_cdeps.py
+5 −1 datm/CMakeLists.txt
+150 −197 datm/atm_comp_nuopc.F90
+1 −1 datm/cime_config/buildnml
+10 −10 datm/cime_config/config_component.xml
+0 −18 datm/cime_config/namelist_definition_datm.xml
+159 −10 datm/cime_config/stream_definition_datm.xml
+223 −274 datm/datm_datamode_clmncep_mod.F90
+97 −100 datm/datm_datamode_core2_mod.F90
+148 −83 datm/datm_datamode_cplhist_mod.F90
+194 −47 datm/datm_datamode_era5_mod.F90
+136 −42 datm/datm_datamode_gefs_mod.F90
+73 −79 datm/datm_datamode_jra_mod.F90
+6 −19 datm/datm_datamode_simple_mod.F90
+172 −0 datm/datm_pres_aero_mod.F90
+98 −0 datm/datm_pres_co2_mod.F90
+113 −0 datm/datm_pres_ndep_mod.F90
+70 −0 datm/datm_pres_o3_mod.F90
+0 −2 dglc/cime_config/namelist_definition_dglc.xml
+0 −2 dglc/cime_config/stream_definition_dglc.xml
+12 −12 dglc/cime_config/testdefs/testlist_dglc.xml
+15 −16 dglc/dglc_datamode_noevolve_mod.F90
+16 −81 dglc/glc_comp_nuopc.F90
+4 −6 dice/cime_config/namelist_definition_dice.xml
+0 −2 dice/cime_config/stream_definition_dice.xml
+179 −34 dice/dice_datamode_cplhist_mod.F90
+25 −13 dice/dice_datamode_ssmi_mod.F90
+2 −2 dice/dice_flux_atmice_mod.F90
+42 −109 dice/ice_comp_nuopc.F90
+3 −13 dlnd/cime_config/config_component.xml
+0 −2 dlnd/cime_config/namelist_definition_dlnd.xml
+0 −2 dlnd/cime_config/stream_definition_dlnd.xml
+87 −79 dlnd/dlnd_datamode_glc_forcing_mod.F90
+156 −92 dlnd/dlnd_datamode_rof_forcing_mod.F90
+51 −60 dlnd/lnd_comp_nuopc.F90
+0 −88 dlnd/stream_definition_dlnd.xml
+36 −15 doc/source/docn.rst
+2 −3 docn/CMakeLists.txt
+1 −1 docn/cime_config/config_component.xml
+19 −27 docn/cime_config/namelist_definition_docn.xml
+1 −3 docn/cime_config/stream_definition_docn.xml
+2 −2 docn/docn_datamode_aquaplanet_mod.F90
+66 −20 docn/docn_datamode_cplhist_mod.F90
+0 −172 docn/docn_datamode_iaf_mod.F90
+61 −56 docn/docn_datamode_multilev_cplhist_mod.F90
+26 −29 docn/docn_datamode_multilev_mod.F90
+49 −46 docn/docn_datamode_multilev_sstdata_mod.F90
+74 −33 docn/docn_datamode_som_mod.F90
+35 −31 docn/docn_datamode_sstdata_mod.F90
+2 −2 docn/docn_import_data_mod.F90
+110 −181 docn/ocn_comp_nuopc.F90
+3 −1 drof/CMakeLists.txt
+41 −39 drof/cime_config/config_component.xml
+8 −7 drof/cime_config/namelist_definition_drof.xml
+39 −4 drof/cime_config/stream_definition_drof.xml
+8 −0 drof/cime_config/testdefs/testlist_drof.xml
+6 −0 drof/cime_config/testdefs/testmods_dirs/drof/cplhist_noresm/shell_commands
+123 −0 drof/drof_datamode_copyall.F90
+198 −0 drof/drof_datamode_cplhist.F90
+110 −107 drof/rof_comp_nuopc.F90
+11 −13 dshr/dshr_dfield_mod.F90
+3 −3 dshr/dshr_fldlist_mod.F90
+59 −59 dshr/dshr_mod.F90
+2 −1 dwav/CMakeLists.txt
+0 −2 dwav/cime_config/namelist_definition_dwav.xml
+0 −2 dwav/cime_config/stream_definition_dwav.xml
+108 −0 dwav/dwav_datamode_copyall.F90
+135 −193 dwav/wav_comp_nuopc.F90
+1 −0 share/CMakeLists.txt
+94 −0 share/shr_lnd2rof_tracers_mod.F90
+27 −3 streams/dshr_methods_mod.F90
+618 −298 streams/dshr_strdata_mod.F90
+399 −265 streams/dshr_stream_mod.F90
33 changes: 15 additions & 18 deletions src/biogeophys/SoilTemperatureMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ module SoilTemperatureMod
! !PRIVATE MEMBER FUNCTIONS:
private :: SoilThermProp ! Set therm conduct. and heat cap of snow/soil layers
private :: PhaseChangeH2osfc ! When surface water freezes move ice to bottom snow layer
private :: PhaseChange_beta ! Calculation of the phase change within snow and soil layers
private :: PhaseChange ! Calculation of the phase change within snow and soil layers
private :: BuildingHAC ! Building Heating and Cooling for simpler method (introduced in CLM4.5)

real(r8), private, parameter :: thin_sfclayer = 1.0e-6_r8 ! Threshold for thin surface layer
Expand Down Expand Up @@ -517,7 +517,7 @@ subroutine SoilTemperature(bounds, num_urbanl, filter_urbanl, num_urbanc, filter
dhsdT(bounds%begc:bounds%endc), &
waterstatebulk_inst, waterdiagnosticbulk_inst, waterfluxbulk_inst, temperature_inst,energyflux_inst)

call Phasechange_beta (bounds, num_nolakec, filter_nolakec, &
call Phasechange (bounds, num_nolakec, filter_nolakec, &
dhsdT(bounds%begc:bounds%endc), &
soilstate_inst, waterstatebulk_inst, waterdiagnosticbulk_inst, waterfluxbulk_inst, energyflux_inst, temperature_inst)

Expand Down Expand Up @@ -1131,7 +1131,7 @@ subroutine PhaseChangeH2osfc (bounds, num_nolakec, filter_nolakec, &
end subroutine PhaseChangeH2osfc

!-----------------------------------------------------------------------
subroutine Phasechange_beta (bounds, num_nolakec, filter_nolakec, dhsdT, &
subroutine Phasechange (bounds, num_nolakec, filter_nolakec, dhsdT, &
soilstate_inst, waterstatebulk_inst, waterdiagnosticbulk_inst, waterfluxbulk_inst, energyflux_inst, temperature_inst)
!
! !DESCRIPTION:
Expand Down Expand Up @@ -1187,7 +1187,7 @@ subroutine Phasechange_beta (bounds, num_nolakec, filter_nolakec, dhsdT, &

!-----------------------------------------------------------------------

call t_startf( 'PhaseChangebeta' )
call t_startf( 'PhaseChange' )

! Enforce expected array sizes
SHR_ASSERT_ALL_FL((ubound(dhsdT) == (/bounds%endc/)), sourcefile, __LINE__)
Expand Down Expand Up @@ -1280,7 +1280,6 @@ subroutine Phasechange_beta (bounds, num_nolakec, filter_nolakec, dhsdT, &
! If ice exists above melt point, melt some to liquid.
if (h2osoi_ice(c,j) > 0._r8 .and. t_soisno(c,j) > tfrz) then
imelt(c,j) = 1
! tinc(c,j) = t_soisno(c,j) - tfrz
tinc(c,j) = tfrz - t_soisno(c,j)
t_soisno(c,j) = tfrz
endif
Expand All @@ -1289,7 +1288,6 @@ subroutine Phasechange_beta (bounds, num_nolakec, filter_nolakec, dhsdT, &
! If liquid exists below melt point, freeze some to ice.
if (h2osoi_liq(c,j) > 0._r8 .AND. t_soisno(c,j) < tfrz) then
imelt(c,j) = 2
! tinc(c,j) = t_soisno(c,j) - tfrz
tinc(c,j) = tfrz - t_soisno(c,j)
t_soisno(c,j) = tfrz
endif
Expand All @@ -1311,7 +1309,6 @@ subroutine Phasechange_beta (bounds, num_nolakec, filter_nolakec, dhsdT, &

if (h2osoi_ice(c,j) > 0. .AND. t_soisno(c,j) > tfrz) then
imelt(c,j) = 1
! tinc(c,j) = t_soisno(c,j) - tfrz
tinc(c,j) = tfrz - t_soisno(c,j)
t_soisno(c,j) = tfrz
endif
Expand All @@ -1335,7 +1332,6 @@ subroutine Phasechange_beta (bounds, num_nolakec, filter_nolakec, dhsdT, &

if (h2osoi_liq(c,j) > supercool(c,j) .AND. t_soisno(c,j) < tfrz) then
imelt(c,j) = 2
! tinc(c,j) = t_soisno(c,j) - tfrz
tinc(c,j) = tfrz - t_soisno(c,j)
t_soisno(c,j) = tfrz
endif
Expand All @@ -1344,7 +1340,6 @@ subroutine Phasechange_beta (bounds, num_nolakec, filter_nolakec, dhsdT, &
if (h2osno_no_layers(c) > 0._r8 .AND. j == 1) then
if (t_soisno(c,j) > tfrz) then
imelt(c,j) = 1
! tincc,j) = t_soisno(c,j) - tfrz
tinc(c,j) = tfrz - t_soisno(c,j)
t_soisno(c,j) = tfrz
endif
Expand Down Expand Up @@ -1439,14 +1434,16 @@ subroutine Phasechange_beta (bounds, num_nolakec, filter_nolakec, dhsdT, &
heatr = 0._r8
if (xm(c,j) > 0._r8) then !if there is excess heat to melt the ice
h2osoi_ice(c,j) = max(0._r8, wice0(c,j)-xm(c,j))
heatr = hm(c,j) - hfus*(wice0(c,j)-h2osoi_ice(c,j))/dtime
xm2(c,j) = xm(c,j) - h2osoi_ice(c,j) !excess ice melting
if (h2osoi_ice(c,j) == 0._r8) then ! this might be redundant
if (excess_ice(c,j) >= 0._r8 .and. xm2(c,j)>0._r8 .and. j>=2) then ! if there is excess ice to melt
excess_ice(c,j) = max(0._r8,wexice0(c,j) - xm2(c,j))
heatr = hm(c,j) - hfus * (wexice0(c,j)-excess_ice(c,j)+wice0(c,j)-h2osoi_ice(c,j)) / dtime
xm2(c,j) = xm(c,j) - wice0(c,j) ! Leftover melt
if (j>=1) then ! soil
if (excess_ice(c,j) >= 0._r8 .and. xm2(c,j)>0._r8) then ! if there is excess ice to melt
excess_ice(c,j) = max(0._r8,wexice0(c,j) - xm2(c,j))
endif
endif !end of excess ice block
heatr = hm(c,j) - hfus * (wexice0(c,j)-excess_ice(c,j)+ &
wice0(c,j)-h2osoi_ice(c,j)) / dtime
else !snow
heatr = hm(c,j) - hfus * (wice0(c,j)-h2osoi_ice(c,j)) / dtime
endif
else if (xm(c,j) < 0._r8) then
if (j <= 0) then
h2osoi_ice(c,j) = min(wmass0(c,j), wice0(c,j)-xm(c,j)) ! snow
Expand Down Expand Up @@ -1536,10 +1533,10 @@ subroutine Phasechange_beta (bounds, num_nolakec, filter_nolakec, dhsdT, &
end if
end do

call t_stopf( 'PhaseChangebeta' )
call t_stopf( 'PhaseChange' )
end associate

end subroutine Phasechange_beta
end subroutine Phasechange

!-----------------------------------------------------------------------
subroutine ComputeGroundHeatFluxAndDeriv(bounds, &
Expand Down