Skip to content

Commit

Permalink
Merge pull request NOAA-EMC#16 from climbfuji/mynnsfclay_from_joe_in_…
Browse files Browse the repository at this point in the history
…latest_code

Update to MYNN Surface Layer Scheme and related modules (NOAA-EMC#14 - based on latest code)
  • Loading branch information
DomHeinzeller authored Apr 3, 2020
2 parents 2a05c53 + 544cbe5 commit 5b6a22d
Show file tree
Hide file tree
Showing 8 changed files with 236 additions and 50 deletions.
2 changes: 1 addition & 1 deletion atmos_model.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1443,7 +1443,7 @@ subroutine update_atmos_chemistry(state, rc)
ib = i + Atm_block%isc - 1
nb = Atm_block%blkno(ib,jb)
ix = Atm_block%ixp(ib,jb)
hpbl(i,j) = IPD_Data(nb)%IntDiag%hpbl(ix)
hpbl(i,j) = IPD_Data(nb)%Tbd%hpbl(ix)
area(i,j) = IPD_Data(nb)%Grid%area(ix)
stype(i,j) = IPD_Data(nb)%Sfcprop%stype(ix)
rainc(i,j) = IPD_Data(nb)%Coupling%rainc_cpl(ix)
Expand Down
2 changes: 1 addition & 1 deletion ccpp/physics
92 changes: 92 additions & 0 deletions ccpp/suites/suite_FV3_GSD_noah_mynnsfc.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
<?xml version="1.0" encoding="UTF-8"?>

<suite name="FV3_GSD_noah_mynnsfc" lib="ccppphys" ver="3">
<!-- <init></init> -->
<group name="time_vary">
<subcycle loop="1">
<scheme>GFS_time_vary_pre</scheme>
<scheme>GFS_rrtmg_setup</scheme>
<scheme>GFS_rad_time_vary</scheme>
<scheme>GFS_phys_time_vary</scheme>
</subcycle>
</group>
<group name="radiation">
<subcycle loop="1">
<scheme>GFS_suite_interstitial_rad_reset</scheme>
<scheme>sgscloud_radpre</scheme>
<scheme>GFS_rrtmg_pre</scheme>
<scheme>rrtmg_sw_pre</scheme>
<scheme>rrtmg_sw</scheme>
<scheme>rrtmg_sw_post</scheme>
<scheme>rrtmg_lw_pre</scheme>
<scheme>rrtmg_lw</scheme>
<scheme>sgscloud_radpost</scheme>
<scheme>rrtmg_lw_post</scheme>
<scheme>GFS_rrtmg_post</scheme>
</subcycle>
</group>
<group name="physics">
<subcycle loop="1">
<scheme>GFS_suite_interstitial_phys_reset</scheme>
<scheme>GFS_suite_stateout_reset</scheme>
<scheme>get_prs_fv3</scheme>
<scheme>GFS_suite_interstitial_1</scheme>
<scheme>GFS_surface_generic_pre</scheme>
<scheme>GFS_surface_composites_pre</scheme>
<scheme>dcyc2t3</scheme>
<scheme>GFS_surface_composites_inter</scheme>
<scheme>GFS_suite_interstitial_2</scheme>
</subcycle>
<!-- Surface iteration loop -->
<subcycle loop="2">
<scheme>mynnsfc_wrapper</scheme>
<scheme>GFS_surface_loop_control_part1</scheme>
<scheme>sfc_nst_pre</scheme>
<scheme>sfc_nst</scheme>
<scheme>sfc_nst_post</scheme>
<scheme>lsm_noah</scheme>
<scheme>sfc_sice</scheme>
<scheme>GFS_surface_loop_control_part2</scheme>
</subcycle>
<!-- End of surface iteration loop -->
<subcycle loop="1">
<scheme>GFS_surface_composites_post</scheme>
<scheme>dcyc2t3_post</scheme>
<scheme>sfc_diag</scheme>
<scheme>sfc_diag_post</scheme>
<scheme>GFS_surface_generic_post</scheme>
<scheme>mynnedmf_wrapper</scheme>
<scheme>GFS_GWD_generic_pre</scheme>
<scheme>cires_ugwp</scheme>
<scheme>cires_ugwp_post</scheme>
<scheme>GFS_GWD_generic_post</scheme>
<scheme>rayleigh_damp</scheme>
<scheme>GFS_suite_stateout_update</scheme>
<scheme>ozphys_2015</scheme>
<scheme>h2ophys</scheme>
<scheme>get_phi_fv3</scheme>
<scheme>GFS_suite_interstitial_3</scheme>
<scheme>GFS_DCNV_generic_pre</scheme>
<scheme>cu_gf_driver_pre</scheme>
<scheme>cu_gf_driver</scheme>
<scheme>GFS_DCNV_generic_post</scheme>
<scheme>GFS_SCNV_generic_pre</scheme>
<scheme>GFS_SCNV_generic_post</scheme>
<scheme>GFS_suite_interstitial_4</scheme>
<scheme>cnvc90</scheme>
<scheme>GFS_MP_generic_pre</scheme>
<scheme>mp_thompson_pre</scheme>
<scheme>mp_thompson</scheme>
<scheme>mp_thompson_post</scheme>
<scheme>GFS_MP_generic_post</scheme>
<scheme>cu_gf_driver_post</scheme>
<scheme>maximum_hourly_diagnostics</scheme>
</subcycle>
</group>
<group name="stochastics">
<subcycle loop="1">
<scheme>GFS_stochastics</scheme>
</subcycle>
</group>
<!-- <finalize></finalize> -->
</suite>
94 changes: 94 additions & 0 deletions ccpp/suites/suite_FV3_GSD_v0_mynnsfc.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
<?xml version="1.0" encoding="UTF-8"?>

<suite name="FV3_GSD_v0_mynnsfc" lib="ccppphys" ver="3">
<!-- <init></init> -->
<group name="time_vary">
<subcycle loop="1">
<scheme>GFS_time_vary_pre</scheme>
<scheme>GFS_rrtmg_setup</scheme>
<scheme>GFS_rad_time_vary</scheme>
<scheme>GFS_phys_time_vary</scheme>
</subcycle>
</group>
<group name="radiation">
<subcycle loop="1">
<scheme>GFS_suite_interstitial_rad_reset</scheme>
<scheme>sgscloud_radpre</scheme>
<scheme>GFS_rrtmg_pre</scheme>
<scheme>rrtmg_sw_pre</scheme>
<scheme>rrtmg_sw</scheme>
<scheme>rrtmg_sw_post</scheme>
<scheme>rrtmg_lw_pre</scheme>
<scheme>rrtmg_lw</scheme>
<scheme>sgscloud_radpost</scheme>
<scheme>rrtmg_lw_post</scheme>
<scheme>GFS_rrtmg_post</scheme>
</subcycle>
</group>
<group name="physics">
<subcycle loop="1">
<scheme>GFS_suite_interstitial_phys_reset</scheme>
<scheme>GFS_suite_stateout_reset</scheme>
<scheme>get_prs_fv3</scheme>
<scheme>GFS_suite_interstitial_1</scheme>
<scheme>GFS_surface_generic_pre</scheme>
<scheme>GFS_surface_composites_pre</scheme>
<scheme>dcyc2t3</scheme>
<scheme>GFS_surface_composites_inter</scheme>
<scheme>GFS_suite_interstitial_2</scheme>
</subcycle>
<!-- Surface iteration loop -->
<subcycle loop="2">
<scheme>mynnsfc_wrapper</scheme>
<scheme>GFS_surface_loop_control_part1</scheme>
<scheme>sfc_nst_pre</scheme>
<scheme>sfc_nst</scheme>
<scheme>sfc_nst_post</scheme>
<scheme>lsm_ruc</scheme>
<scheme>lsm_ruc_sfc_sice_pre</scheme>
<scheme>sfc_sice</scheme>
<scheme>lsm_ruc_sfc_sice_post</scheme>
<scheme>GFS_surface_loop_control_part2</scheme>
</subcycle>
<!-- End of surface iteration loop -->
<subcycle loop="1">
<scheme>GFS_surface_composites_post</scheme>
<scheme>dcyc2t3_post</scheme>
<scheme>sfc_diag</scheme>
<scheme>sfc_diag_post</scheme>
<scheme>GFS_surface_generic_post</scheme>
<scheme>mynnedmf_wrapper</scheme>
<scheme>GFS_GWD_generic_pre</scheme>
<scheme>cires_ugwp</scheme>
<scheme>cires_ugwp_post</scheme>
<scheme>GFS_GWD_generic_post</scheme>
<scheme>rayleigh_damp</scheme>
<scheme>GFS_suite_stateout_update</scheme>
<scheme>ozphys_2015</scheme>
<scheme>h2ophys</scheme>
<scheme>get_phi_fv3</scheme>
<scheme>GFS_suite_interstitial_3</scheme>
<scheme>GFS_DCNV_generic_pre</scheme>
<scheme>cu_gf_driver_pre</scheme>
<scheme>cu_gf_driver</scheme>
<scheme>GFS_DCNV_generic_post</scheme>
<scheme>GFS_SCNV_generic_pre</scheme>
<scheme>GFS_SCNV_generic_post</scheme>
<scheme>GFS_suite_interstitial_4</scheme>
<scheme>cnvc90</scheme>
<scheme>GFS_MP_generic_pre</scheme>
<scheme>mp_thompson_pre</scheme>
<scheme>mp_thompson</scheme>
<scheme>mp_thompson_post</scheme>
<scheme>GFS_MP_generic_post</scheme>
<scheme>cu_gf_driver_post</scheme>
<scheme>maximum_hourly_diagnostics</scheme>
</subcycle>
</group>
<group name="stochastics">
<subcycle loop="1">
<scheme>GFS_stochastics</scheme>
</subcycle>
</group>
<!-- <finalize></finalize> -->
</suite>
2 changes: 1 addition & 1 deletion gfsphysics/GFS_layer/GFS_diagnostics.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1535,7 +1535,7 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop
ExtDiag(idx)%intpl_method = 'bilinear'
allocate (ExtDiag(idx)%data(nblks))
do nb = 1,nblks
ExtDiag(idx)%data(nb)%var2 => IntDiag(nb)%hpbl(:)
ExtDiag(idx)%data(nb)%var2 => Tbd(nb)%hpbl(:)
enddo

idx = idx + 1
Expand Down
30 changes: 15 additions & 15 deletions gfsphysics/GFS_layer/GFS_typedefs.F90
Original file line number Diff line number Diff line change
Expand Up @@ -258,6 +258,9 @@ module GFS_typedefs
real (kind=kind_phys), pointer :: uustar (:) => null() !< boundary layer parameter
real (kind=kind_phys), pointer :: oro (:) => null() !< orography
real (kind=kind_phys), pointer :: oro_uf (:) => null() !< unfiltered orography
real (kind=kind_phys), pointer :: evap (:) => null() !<
real (kind=kind_phys), pointer :: hflx (:) => null() !<
real (kind=kind_phys), pointer :: qss (:) => null() !<

!-- In/Out
#ifdef CCPP
Expand Down Expand Up @@ -1193,6 +1196,9 @@ module GFS_typedefs
real (kind=kind_phys), pointer :: phy_f2d (:,:) => null() !< 2d arrays saved for restart
real (kind=kind_phys), pointer :: phy_f3d (:,:,:) => null() !< 3d arrays saved for restart

!--- Diagnostic that needs to be carried over to the next time step (removed from diag_type)
real (kind=kind_phys), pointer :: hpbl (:) => null() !< Planetary boundary layer height

#ifndef CCPP
!--- for explicit data blocking
integer :: blkno !< block number of this block
Expand Down Expand Up @@ -1417,7 +1423,6 @@ module GFS_typedefs
real (kind=kind_phys), pointer :: dpt2m (:) => null() !< 2 meter dew point temperature
real (kind=kind_phys), pointer :: zlvl (:) => null() !< layer 1 height (m)
real (kind=kind_phys), pointer :: psurf (:) => null() !< surface pressure (Pa)
real (kind=kind_phys), pointer :: hpbl (:) => null() !< pbl height (m)
real (kind=kind_phys), pointer :: pwat (:) => null() !< precipitable water
real (kind=kind_phys), pointer :: t1 (:) => null() !< layer 1 temperature (K)
real (kind=kind_phys), pointer :: q1 (:) => null() !< layer 1 specific humidity (kg/kg)
Expand Down Expand Up @@ -1667,7 +1672,6 @@ module GFS_typedefs
real (kind=kind_phys), pointer :: ep1d_ice(:) => null() !<
real (kind=kind_phys), pointer :: ep1d_land(:) => null() !<
real (kind=kind_phys), pointer :: ep1d_ocean(:) => null() !<
real (kind=kind_phys), pointer :: evap(:) => null() !<
real (kind=kind_phys), pointer :: evap_ice(:) => null() !<
real (kind=kind_phys), pointer :: evap_land(:) => null() !<
real (kind=kind_phys), pointer :: evap_ocean(:) => null() !<
Expand Down Expand Up @@ -1713,7 +1717,6 @@ module GFS_typedefs
real (kind=kind_phys), pointer :: gwdcv(:,:) => null() !<
integer :: h2o_coeff !<
real (kind=kind_phys), pointer :: h2o_pres(:) => null() !<
real (kind=kind_phys), pointer :: hflx(:) => null() !<
real (kind=kind_phys), pointer :: hflx_ice(:) => null() !<
real (kind=kind_phys), pointer :: hflx_land(:) => null() !<
real (kind=kind_phys), pointer :: hflx_ocean(:) => null() !<
Expand Down Expand Up @@ -1784,7 +1787,6 @@ module GFS_typedefs
real (kind=kind_phys), pointer :: qlyr(:,:) => null() !<
real (kind=kind_phys), pointer :: qrn(:,:) => null() !<
real (kind=kind_phys), pointer :: qsnw(:,:) => null() !<
real (kind=kind_phys), pointer :: qss(:) => null() !<
real (kind=kind_phys), pointer :: qss_ice(:) => null() !<
real (kind=kind_phys), pointer :: qss_land(:) => null() !<
real (kind=kind_phys), pointer :: qss_ocean(:) => null() !<
Expand Down Expand Up @@ -2121,6 +2123,9 @@ subroutine sfcprop_create (Sfcprop, IM, Model)
allocate (Sfcprop%uustar (IM))
allocate (Sfcprop%oro (IM))
allocate (Sfcprop%oro_uf (IM))
allocate (Sfcprop%evap (IM))
allocate (Sfcprop%hflx (IM))
allocate (Sfcprop%qss (IM))

Sfcprop%slope = clear_val
Sfcprop%shdmin = clear_val
Expand All @@ -2133,6 +2138,9 @@ subroutine sfcprop_create (Sfcprop, IM, Model)
Sfcprop%uustar = clear_val
Sfcprop%oro = clear_val
Sfcprop%oro_uf = clear_val
Sfcprop%evap = clear_val
Sfcprop%hflx = clear_val
Sfcprop%qss = clear_val

!--- In/Out
allocate (Sfcprop%hice (IM))
Expand Down Expand Up @@ -4907,6 +4915,9 @@ subroutine tbd_create (Tbd, IM, Model)
! if (Model%do_shoc) Tbd%phy_f3d(:,1,Model%ntot3d-1) = 3.0
! if (Model%do_shoc) Tbd%phy_f3d(:,:,Model%ntot3d-1) = 1.0

allocate (Tbd%hpbl (IM))
Tbd%hpbl = clear_val

#ifndef CCPP
Tbd%blkno = BLKNO
#endif
Expand Down Expand Up @@ -5142,7 +5153,6 @@ subroutine diag_create (Diag, IM, Model)
allocate (Diag%dpt2m (IM))
allocate (Diag%zlvl (IM))
allocate (Diag%psurf (IM))
allocate (Diag%hpbl (IM))
allocate (Diag%pwat (IM))
allocate (Diag%t1 (IM))
allocate (Diag%q1 (IM))
Expand Down Expand Up @@ -5442,7 +5452,6 @@ subroutine diag_phys_zero (Diag, Model, linit, iauwindow_center)
Diag%dpt2m = zero
Diag%zlvl = zero
Diag%psurf = zero
Diag%hpbl = zero
Diag%pwat = zero
Diag%t1 = zero
Diag%q1 = zero
Expand Down Expand Up @@ -5784,7 +5793,6 @@ subroutine interstitial_create (Interstitial, IM, Model)
allocate (Interstitial%ep1d_ice (IM))
allocate (Interstitial%ep1d_land (IM))
allocate (Interstitial%ep1d_ocean (IM))
allocate (Interstitial%evap (IM))
allocate (Interstitial%evap_ice (IM))
allocate (Interstitial%evap_land (IM))
allocate (Interstitial%evap_ocean (IM))
Expand Down Expand Up @@ -5827,7 +5835,6 @@ subroutine interstitial_create (Interstitial, IM, Model)
allocate (Interstitial%gwdcu (IM,Model%levs))
allocate (Interstitial%gwdcv (IM,Model%levs))
allocate (Interstitial%h2o_pres (levh2o))
allocate (Interstitial%hflx (IM))
allocate (Interstitial%hflx_ice (IM))
allocate (Interstitial%hflx_land (IM))
allocate (Interstitial%hflx_ocean (IM))
Expand Down Expand Up @@ -5855,7 +5862,6 @@ subroutine interstitial_create (Interstitial, IM, Model)
allocate (Interstitial%prnum (IM,Model%levs))
allocate (Interstitial%qlyr (IM,Model%levr+LTP))
allocate (Interstitial%prcpmp (IM))
allocate (Interstitial%qss (IM))
allocate (Interstitial%qss_ice (IM))
allocate (Interstitial%qss_land (IM))
allocate (Interstitial%qss_ocean (IM))
Expand Down Expand Up @@ -6328,7 +6334,6 @@ subroutine interstitial_phys_reset (Interstitial, Model)
Interstitial%ep1d_ice = huge
Interstitial%ep1d_land = huge
Interstitial%ep1d_ocean = huge
Interstitial%evap = clear_val
Interstitial%evap_ice = huge
Interstitial%evap_land = huge
Interstitial%evap_ocean = huge
Expand Down Expand Up @@ -6367,7 +6372,6 @@ subroutine interstitial_phys_reset (Interstitial, Model)
Interstitial%gflx_ocean = zero
Interstitial%gwdcu = clear_val
Interstitial%gwdcv = clear_val
Interstitial%hflx = clear_val
Interstitial%hflx_ice = huge
Interstitial%hflx_land = huge
Interstitial%hflx_ocean = huge
Expand All @@ -6387,7 +6391,6 @@ subroutine interstitial_phys_reset (Interstitial, Model)
Interstitial%oc = clear_val
Interstitial%prcpmp = clear_val
Interstitial%prnum = clear_val
Interstitial%qss = clear_val
Interstitial%qss_ice = huge
Interstitial%qss_land = huge
Interstitial%qss_ocean = huge
Expand Down Expand Up @@ -6639,7 +6642,6 @@ subroutine interstitial_print(Interstitial, Model, mpirank, omprank, blkno)
write (0,*) 'sum(Interstitial%ep1d_ice ) = ', sum(Interstitial%ep1d_ice )
write (0,*) 'sum(Interstitial%ep1d_land ) = ', sum(Interstitial%ep1d_land )
write (0,*) 'sum(Interstitial%ep1d_ocean ) = ', sum(Interstitial%ep1d_ocean )
write (0,*) 'sum(Interstitial%evap ) = ', sum(Interstitial%evap )
write (0,*) 'sum(Interstitial%evap_ice ) = ', sum(Interstitial%evap_ice )
write (0,*) 'sum(Interstitial%evap_land ) = ', sum(Interstitial%evap_land )
write (0,*) 'sum(Interstitial%evap_ocean ) = ', sum(Interstitial%evap_ocean )
Expand Down Expand Up @@ -6682,7 +6684,6 @@ subroutine interstitial_print(Interstitial, Model, mpirank, omprank, blkno)
write (0,*) 'sum(Interstitial%gflx_ocean ) = ', sum(Interstitial%gflx_ocean )
write (0,*) 'sum(Interstitial%gwdcu ) = ', sum(Interstitial%gwdcu )
write (0,*) 'sum(Interstitial%gwdcv ) = ', sum(Interstitial%gwdcv )
write (0,*) 'sum(Interstitial%hflx ) = ', sum(Interstitial%hflx )
write (0,*) 'sum(Interstitial%hflx_ice ) = ', sum(Interstitial%hflx_ice )
write (0,*) 'sum(Interstitial%hflx_land ) = ', sum(Interstitial%hflx_land )
write (0,*) 'sum(Interstitial%hflx_ocean ) = ', sum(Interstitial%hflx_ocean )
Expand Down Expand Up @@ -6713,7 +6714,6 @@ subroutine interstitial_print(Interstitial, Model, mpirank, omprank, blkno)
write (0,*) 'sum(Interstitial%prcpmp ) = ', sum(Interstitial%prcpmp )
write (0,*) 'sum(Interstitial%prnum ) = ', sum(Interstitial%prnum )
write (0,*) 'sum(Interstitial%qlyr ) = ', sum(Interstitial%qlyr )
write (0,*) 'sum(Interstitial%qss ) = ', sum(Interstitial%qss )
write (0,*) 'sum(Interstitial%qss_ice ) = ', sum(Interstitial%qss_ice )
write (0,*) 'sum(Interstitial%qss_land ) = ', sum(Interstitial%qss_land )
write (0,*) 'sum(Interstitial%qss_ocean ) = ', sum(Interstitial%qss_ocean )
Expand Down
Loading

0 comments on commit 5b6a22d

Please sign in to comment.