Skip to content

Commit

Permalink
icedrv_RunMod: add support for disabling thermodynamics
Browse files Browse the repository at this point in the history
As noted in the previous commit, 'ktherm = -1' is documented as
disabling the thermodynamics in the Icepack documentation since 2b27a78
(Update documentation including namelist tables (CICE-Consortium#322), 2020-06-05),
although this capability does not exist in Icepack standalone.

Update icedrv_RunMod::ice_step to call some subroutines only if the
thermodynamics is enabled ('ktherm >= 0'). Namely, let prep_radiation,
biogeochemistry, step_therm2 and step_radiation only be called when
thermodynamics is enabled, while letting the rest of the subroutines
always be called. As noted in the previous commit, 'step_therm1' in
particular has to be always called since the computation of the
atmospheric stresses are done in that subroutine.
  • Loading branch information
phil-blain committed Jan 24, 2024
1 parent 17f4b47 commit 7a62d2f
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions configuration/driver/icedrv_RunMod.F90
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ subroutine ice_step
use icedrv_flux, only: init_history_therm, init_history_bgc, &
daidtt, daidtd, dvidtt, dvidtd, dagedtt, dagedtd, init_history_dyn
use icedrv_history, only: history_format, history_write
use icepack_parameters, only: ktherm
use icedrv_restart, only: dumpfile, final_restart
use icedrv_restart_bgc, only: write_restart_bgc
use icedrv_step, only: prep_radiation, step_therm1, step_therm2, &
Expand Down Expand Up @@ -147,7 +148,7 @@ subroutine ice_step
! Scale radiation fields
!-----------------------------------------------------------------

if (calc_Tsfc) call prep_radiation ()
if (calc_Tsfc .and. ktherm >= 0) call prep_radiation ()

! call icedrv_diagnostics_debug ('post prep_radiation')

Expand All @@ -156,8 +157,10 @@ subroutine ice_step
!-----------------------------------------------------------------

call step_therm1 (dt) ! vertical thermodynamics
call biogeochemistry (dt) ! biogeochemistry
call step_therm2 (dt) ! ice thickness distribution thermo
if (ktherm >= 0) then
call biogeochemistry (dt) ! biogeochemistry
call step_therm2 (dt) ! ice thickness distribution thermo
endif

! clean up, update tendency diagnostics
offset = dt
Expand Down Expand Up @@ -206,7 +209,7 @@ subroutine ice_step
! albedo, shortwave radiation
!-----------------------------------------------------------------

call step_radiation (dt)
if (ktherm >= 0) call step_radiation (dt)

!-----------------------------------------------------------------
! get ready for coupling and the next time step
Expand Down

0 comments on commit 7a62d2f

Please sign in to comment.