From 77bb53e5b9841d5b40340dbe495dfe6be3ae2192 Mon Sep 17 00:00:00 2001 From: Dom Heinzeller Date: Thu, 5 Dec 2019 21:08:33 -0700 Subject: [PATCH] allow for radiation being called on physics timestep for first nhfrad timesteps --- ccpp/physics | 2 +- gfsphysics/GFS_layer/GFS_typedefs.F90 | 23 +++++++++++++++++++++++ gfsphysics/GFS_layer/GFS_typedefs.meta | 6 ++++++ 3 files changed, 30 insertions(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index e81ee3683..32e245a44 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit e81ee3683d61d557404543f59c4a70949cdf2f45 +Subproject commit 32e245a44f372f3f17517548c7604cb57443783f diff --git a/gfsphysics/GFS_layer/GFS_typedefs.F90 b/gfsphysics/GFS_layer/GFS_typedefs.F90 index 6b2402039..ff1d0184e 100644 --- a/gfsphysics/GFS_layer/GFS_typedefs.F90 +++ b/gfsphysics/GFS_layer/GFS_typedefs.F90 @@ -590,6 +590,9 @@ module GFS_typedefs real(kind=kind_phys) :: fhlwr !< frequency for longwave radiation (secs) integer :: nsswr !< integer trigger for shortwave radiation integer :: nslwr !< integer trigger for longwave radiation +#ifdef CCPP + integer :: nhfrad !< number of timesteps for which to call radiation on physics timestep (coldstarts) +#endif integer :: levr !< number of vertical levels for radiation calculations #ifdef CCPP integer :: levrp1 !< number of vertical levels for radiation calculations plus one @@ -2703,6 +2706,9 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & !--- radiation parameters real(kind=kind_phys) :: fhswr = 3600. !< frequency for shortwave radiation (secs) real(kind=kind_phys) :: fhlwr = 3600. !< frequency for longwave radiation (secs) +#ifdef CCPP + integer :: nhfrad = 0 !< number of timesteps for which to call radiation on physics timestep (coldstarts) +#endif integer :: levr = -99 !< number of vertical levels for radiation calculations integer :: nfxr = 39+6 !< second dimension of input/output array fluxr logical :: aero_in = .false. !< flag for initializing aero data @@ -3072,6 +3078,9 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & fhswr, fhlwr, levr, nfxr, aero_in, iflip, isol, ico2, ialb, & isot, iems, iaer, icliq_sw, iovr_sw, iovr_lw, ictm, isubc_sw,& isubc_lw, crick_proof, ccnorm, lwhtr, swhtr, & +#ifdef CCPP + nhfrad, & +#endif ! IN CCN forcing iccn, & !--- microphysical parameterizations @@ -3277,6 +3286,17 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & Model%fhlwr = fhlwr Model%nsswr = nint(fhswr/Model%dtp) Model%nslwr = nint(fhlwr/Model%dtp) +#ifdef CCPP + if (restart) then + Model%nhfrad = 0 + if (Model%me == Model%master .and. nhfrad>0) & + write(*,'(a)') 'Disable high-frequency radiation calls for restart run' + else + Model%nhfrad = nhfrad + if (Model%me == Model%master .and. nhfrad>0) & + write(*,'(a,i0)') 'Number of high-frequency radiation calls for coldstart run: ', nhfrad + endif +#endif if (levr < 0) then Model%levr = levs else @@ -4384,6 +4404,9 @@ subroutine control_print(Model) print *, ' fhlwr : ', Model%fhlwr print *, ' nsswr : ', Model%nsswr print *, ' nslwr : ', Model%nslwr +#ifdef CCPP + print *, ' nhfrad : ', Model%nhfrad +#endif print *, ' levr : ', Model%levr print *, ' nfxr : ', Model%nfxr print *, ' aero_in : ', Model%aero_in diff --git a/gfsphysics/GFS_layer/GFS_typedefs.meta b/gfsphysics/GFS_layer/GFS_typedefs.meta index b6c5cead2..872cb56ca 100644 --- a/gfsphysics/GFS_layer/GFS_typedefs.meta +++ b/gfsphysics/GFS_layer/GFS_typedefs.meta @@ -2025,6 +2025,12 @@ dimensions = () type = real kind = kind_phys +[nhfrad] + standard_name = number_of_timesteps_for_radiation_calls_on_physics_timestep + long_name = number of timesteps for radiation calls on physics timestep (coldstarts only) + units = count + dimensions = () + type = integer [levr] standard_name = number_of_vertical_layers_for_radiation_calculations long_name = number of vertical levels for radiation calculations