From 1b6b7050742b6f2662e7e6503559ab48a098cc23 Mon Sep 17 00:00:00 2001 From: XiaqiongZhou-NOAA <48254930+XiaqiongZhou-NOAA@users.noreply.github.com> Date: Wed, 27 Oct 2021 08:28:30 -0400 Subject: [PATCH 1/9] Add a WAM regression test with the MULTI_GASES and MOLECULAR_DIFFUSION options on (#354) Add a WAM regression test with the MULTI_GASES and MOLECULAR_DIFFUSION options on Co-authored-by: Sajal.Kar --- CMakeLists.txt | 4 +++ atmos_cubed_sphere | 2 +- ccpp/CMakeLists.txt | 3 ++ ccpp/data/GFS_typedefs.F90 | 31 +++++++++++++------ ccpp/physics | 2 +- ...v3wam.xml => suite_FV3_GFS_v16_fv3wam.xml} | 13 ++++---- io/FV3GFS_io.F90 | 4 +++ io/post_gfs.F90 | 4 +++ 8 files changed, 45 insertions(+), 18 deletions(-) rename ccpp/suites/{suite_FV3_GFS_2017_fv3wam.xml => suite_FV3_GFS_v16_fv3wam.xml} (93%) diff --git a/CMakeLists.txt b/CMakeLists.txt index 986b5fd2f..03ec1411a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -60,6 +60,10 @@ set_target_properties(fv3atm PROPERTIES Fortran_MODULE_DIRECTORY ${CMAKE_CURRENT target_include_directories(fv3atm INTERFACE $ $) +if(MULTI_GASES) + list(APPEND _fv3atm_defs_private MULTI_GASES) +endif() + target_link_libraries(fv3atm PUBLIC fv3 fv3ccpp stochastic_physics diff --git a/atmos_cubed_sphere b/atmos_cubed_sphere index 02c3bac34..8a3a75903 160000 --- a/atmos_cubed_sphere +++ b/atmos_cubed_sphere @@ -1 +1 @@ -Subproject commit 02c3bac346792e9e974b55f256465138a9f69d8e +Subproject commit 8a3a75903de68ae15527f116087ff2020e86d717 diff --git a/ccpp/CMakeLists.txt b/ccpp/CMakeLists.txt index eda2180d7..3ebc40edc 100644 --- a/ccpp/CMakeLists.txt +++ b/ccpp/CMakeLists.txt @@ -89,6 +89,9 @@ if(MULTI_GASES) add_definitions(-DMULTI_GASES) endif() +if(IDEA_PHYS) + add_definitions(-DIDEA_PHYS) +endif() #------------------------------------------------------------------------------ # Build CCPP framework and physics diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index 242834936..c7a76e39e 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -1,4 +1,3 @@ -#undef MULTI_GASES module GFS_typedefs @@ -2185,10 +2184,10 @@ module GFS_typedefs type(ty_source_func_lw) :: sources !< RRTMGP DDT !-- GSL drag suite - real (kind=kind_phys), pointer :: varss(:) => null() !< - real (kind=kind_phys), pointer :: ocss(:) => null() !< - real (kind=kind_phys), pointer :: oa4ss(:,:) => null() !< - real (kind=kind_phys), pointer :: clxss(:,:) => null() !< + real (kind=kind_phys), pointer :: varss(:) => null() !< + real (kind=kind_phys), pointer :: ocss(:) => null() !< + real (kind=kind_phys), pointer :: oa4ss(:,:) => null() !< + real (kind=kind_phys), pointer :: clxss(:,:) => null() !< !-- 3D diagnostics integer :: rtg_ozone_index, rtg_tke_index @@ -3572,7 +3571,14 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & !--- coupling parameters cplflx, cplice, cplocn2atm, cplwav, cplwav2atm, cplchm, & cpl_imp_mrg, cpl_imp_dbg, & - use_cice_alb, lsidea, & + use_cice_alb, & +#ifdef IDEA_PHYS + lsidea, weimer_model, f107_kp_size, f107_kp_interval, & + f107_kp_skip_size, f107_kp_data_size, f107_kp_read_in_start, & + ipe_to_wam_coupling, & +#else + lsidea, & +#endif !--- radiation parameters fhswr, fhlwr, levr, nfxr, iaerclm, iflip, isol, ico2, ialb, & isot, iems, iaer, icliq_sw, iovr, ictm, isubc_sw, & @@ -3872,6 +3878,10 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & print *,' LSIDEA is active but needs to be reworked for FV3 - shutting down' stop endif +#ifdef IDEA_PHYS +!--- integrated dynamics through earth's atmosphere + Model%weimer_model = weimer_model +#endif !--- calendars and time parameters and activation triggers Model%dtp = dt_phys @@ -4472,11 +4482,13 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & Model%tracer_names(:) = tracer_names(:) Model%ntqv = 1 #ifdef MULTI_GASES - Model%nto = get_tracer_index(Model%tracer_names, 'spfo', Model%me, Model%master, Model%debug) - Model%nto2 = get_tracer_index(Model%tracer_names, 'spfo2', Model%me, Model%master, Model%debug) - Model%ntoz = get_tracer_index(Model%tracer_names, 'spfo3', Model%me, Model%master, Model%debug) + Model%nto = get_tracer_index(Model%tracer_names, 'spo', Model%me, Model%master, Model%debug) + Model%nto2 = get_tracer_index(Model%tracer_names, 'spo2', Model%me, Model%master, Model%debug) + Model%ntoz = get_tracer_index(Model%tracer_names, 'spo3', Model%me, Model%master, Model%debug) #else Model%ntoz = get_tracer_index(Model%tracer_names, 'o3mr', Model%me, Model%master, Model%debug) + if( Model%ntoz <= 0 ) & + Model%ntoz = get_tracer_index(Model%tracer_names, 'spo3', Model%me, Model%master, Model%debug) #endif Model%ntcw = get_tracer_index(Model%tracer_names, 'liq_wat', Model%me, Model%master, Model%debug) Model%ntiw = get_tracer_index(Model%tracer_names, 'ice_wat', Model%me, Model%master, Model%debug) @@ -5482,7 +5494,6 @@ subroutine control_print(Model) print *, ' cpl_imp_mrg : ', Model%cpl_imp_mrg print *, ' cpl_imp_dbg : ', Model%cpl_imp_dbg print *, ' ' - print *, 'integrated dynamics through earth atmosphere' print *, ' lsidea : ', Model%lsidea print *, ' ' print *, 'calendars and time parameters and activation triggers' diff --git a/ccpp/physics b/ccpp/physics index 7d7b3bcc4..4da495062 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 7d7b3bcc4b8009ef3491bd230b31bf5af5910bb5 +Subproject commit 4da4950625c4e6bf7cb938070c94fc4032985827 diff --git a/ccpp/suites/suite_FV3_GFS_2017_fv3wam.xml b/ccpp/suites/suite_FV3_GFS_v16_fv3wam.xml similarity index 93% rename from ccpp/suites/suite_FV3_GFS_2017_fv3wam.xml rename to ccpp/suites/suite_FV3_GFS_v16_fv3wam.xml index 7769613a2..b3de0328d 100644 --- a/ccpp/suites/suite_FV3_GFS_2017_fv3wam.xml +++ b/ccpp/suites/suite_FV3_GFS_v16_fv3wam.xml @@ -1,6 +1,6 @@ - + @@ -52,14 +52,15 @@ sfc_diag_post GFS_surface_generic_post GFS_PBL_generic_pre - hedmf + satmedmfvdifq GFS_PBL_generic_post GFS_GWD_generic_pre cires_ugwp cires_ugwp_post GFS_GWD_generic_post GFS_suite_stateout_update - ozphys + ozphys_2015 + h2ophys get_phi_fv3 GFS_suite_interstitial_3 GFS_DCNV_generic_pre @@ -71,17 +72,17 @@ GFS_suite_interstitial_4 cnvc90 GFS_MP_generic_pre - zhaocarr_gscond - zhaocarr_precpd + gfdl_cloud_microphys GFS_MP_generic_post maximum_hourly_diagnostics - phys_tend GFS_stochastics + phys_tend + diff --git a/io/FV3GFS_io.F90 b/io/FV3GFS_io.F90 index f0f82d264..6dfe29a46 100644 --- a/io/FV3GFS_io.F90 +++ b/io/FV3GFS_io.F90 @@ -2831,7 +2831,11 @@ subroutine fv3gfs_diag_output(time, diag, atm_block, nx, ny, levs, ntcw, ntoz, & used=send_data(Diag(idx)%id, var3, Time, is_in=is_in, js_in=js_in, ks_in=1) endif !--- ozone mixing ration tendency +#ifdef MULTI_GASES + if (trim(Diag(idx)%name) == 'dspo3_dt') then +#else if (trim(Diag(idx)%name) == 'do3mr_dt') then +#endif var3(1:nx,1:ny,1:levs) = RESHAPE(Statein%qgrs(1:ngptc,levs:1:-1,ntoz:ntoz), (/nx,ny,levs/)) var3(1:nx,1:ny,1:levs) = (RESHAPE(Stateout%gq0(1:ngptc,levs:1:-1,ntoz:ntoz), (/nx,ny,levs/)) & - var3(1:nx,1:ny,1:levs))*rdt diff --git a/io/post_gfs.F90 b/io/post_gfs.F90 index 105172a86..9cca1521b 100644 --- a/io/post_gfs.F90 +++ b/io/post_gfs.F90 @@ -2172,7 +2172,11 @@ subroutine set_postvars_gfs(wrt_int_state,mpicomp,setvar_atmfile, & endif ! model level ozone mixing ratio +#ifdef MULTI_GASES + if(trim(fieldname)=='spo3') then +#else if(trim(fieldname)=='o3mr') then +#endif !$omp parallel do default(none) private(i,j,l) shared(lm,jsta,jend,ista,iend,o3,arrayr43d) do l=1,lm do j=jsta,jend From b27507aea81188e39ec55c9adde70152e8f73894 Mon Sep 17 00:00:00 2001 From: RuiyuSun <42656044+RuiyuSun@users.noreply.github.com> Date: Thu, 28 Oct 2021 15:37:32 -0400 Subject: [PATCH 2/9] Thompson semi lag rain (#382) * Add semi-Lagrangian sedimentation of rain to Thompson MP as an option --- ccpp/data/GFS_typedefs.F90 | 16 ++++++++++++++++ ccpp/data/GFS_typedefs.meta | 24 ++++++++++++++++++++++++ ccpp/physics | 2 +- 3 files changed, 41 insertions(+), 1 deletion(-) diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index c7a76e39e..5a6ee2898 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -826,6 +826,9 @@ module GFS_typedefs logical :: ext_diag_thompson !< flag for extended diagnostic output from Thompson integer :: thompson_ext_ndiag3d=37 !< number of 3d arrays for extended diagnostic output from Thompson real(kind=kind_phys) :: dt_inner !< time step for the inner loop in s + logical :: sedi_semi !< flag for semi Lagrangian sedi of rain + logical :: sedi_semi_update!< flag for v update in semi Lagrangian sedi of rain + logical :: sedi_semi_decfl !< flag for interation with semi Lagrangian sedi of rain !--- GFDL microphysical paramters logical :: lgfdlmprad !< flag for GFDL mp scheme and radiation consistency @@ -3236,6 +3239,9 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & real(kind=kind_phys) :: ttendlim = -999.0 !< temperature tendency limiter, set to <0 to deactivate logical :: ext_diag_thompson = .false. !< flag for extended diagnostic output from Thompson real(kind=kind_phys) :: dt_inner = -999.0 !< time step for the inner loop + logical :: sedi_semi = .false. !< flag for semi Lagrangian sedi of rain + logical :: sedi_semi_update = .false. !< flag for v update in semi Lagrangian sedi of rain + logical :: sedi_semi_decfl = .false. !< flag for interation with semi Lagrangian sedi of rain !--- GFDL microphysical parameters logical :: lgfdlmprad = .false. !< flag for GFDLMP radiation interaction @@ -3604,6 +3610,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & mg_alf, mg_qcmin, mg_do_ice_gmao, mg_do_liq_liu, & ltaerosol, lradar, nsradar_reset, lrefres, ttendlim, & ext_diag_thompson, dt_inner, lgfdlmprad, & + sedi_semi, sedi_semi_update, sedi_semi_decfl, & !--- max hourly avg_max_length, & !--- land/surface model control @@ -4078,6 +4085,9 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & else Model%dt_inner = Model%dtp endif + Model%sedi_semi = sedi_semi + Model%sedi_semi_update = sedi_semi_update + Model%sedi_semi_decfl = sedi_semi_decfl !--- F-A MP parameters Model%rhgrd = rhgrd Model%spec_adv = spec_adv @@ -5165,6 +5175,9 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & ' ttendlim =',Model%ttendlim, & ' ext_diag_thompson =',Model%ext_diag_thompson, & ' dt_inner =',Model%dt_inner, & + ' sedi_semi=',Model%sedi_semi, & + ' sedi_semi_update=',sedi_semi_update, & + ' sedi_semi_decfl=',sedi_semi_decfl, & ' effr_in =',Model%effr_in, & ' lradar =',Model%lradar, & ' nsradar_reset =',Model%nsradar_reset, & @@ -5582,6 +5595,9 @@ subroutine control_print(Model) print *, ' ttendlim : ', Model%ttendlim print *, ' ext_diag_thompson : ', Model%ext_diag_thompson print *, ' dt_inner : ', Model%dt_inner + print *, ' sedi_semi : ', Model%sedi_semi + print *, ' sedi_semi_update : ', Model%sedi_semi_update + print *, ' sedi_semi_decfl : ', Model%sedi_semi_decfl print *, ' ' endif if (Model%imp_physics == Model%imp_physics_mg) then diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index 847c20884..bbba06ca4 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -3514,6 +3514,30 @@ dimensions = () type = real kind = kind_phys +[sedi_semi] + standard_name = flag_for_semi_Lagrangian_sedi_rain + long_name = flag for semi Lagrangian sedi of rain + units = flag + dimensions = () + type = logical + intent = in + optional = F +[sedi_semi_update] + standard_name = flag_for_v_update_in_semi_Lagrangian_sedi + long_name = flag for v update in semi Lagrangian sedi of rain + units = flag + dimensions = () + type = logical + intent = in + optional = F +[sedi_semi_decfl] + standard_name = flag_for_iteration_with_semi_Lagrangian_sedi + long_name = flag for interation with semi Lagrangian sedi of rain + units = flag + dimensions = () + type = logical + intent = in + optional = F [lgfdlmprad] standard_name = flag_for_GFDL_microphysics_radiation_interaction long_name = flag for GFDL microphysics-radiation interaction diff --git a/ccpp/physics b/ccpp/physics index 4da495062..530f597d3 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 4da4950625c4e6bf7cb938070c94fc4032985827 +Subproject commit 530f597d34a4dab2bedf590480474e86a2e9bac1 From 4214e6d23d63af231521b1a6064d34a967dfd87c Mon Sep 17 00:00:00 2001 From: Dom Heinzeller Date: Fri, 29 Oct 2021 10:56:24 -0600 Subject: [PATCH 3/9] Remove Noah-WRFv4, contains "reduce memory required by MERRA2 data" (#410) (#398) * Remove Noah WRFv4 and all variables required only by this scheme; remove suite FV3_HAFS_v0_hwrf * Reduce memory required by MERRA2 data Co-authored-by: Denise Worthen --- ccpp/config/ccpp_prebuild_config.py | 2 - ccpp/data/GFS_typedefs.F90 | 303 ++++++------------ ccpp/data/GFS_typedefs.meta | 204 ------------ ccpp/physics | 2 +- ccpp/suites/suite_FV3_HAFS_v0_hwrf.xml | 91 ------ .../suite_FV3_HAFS_v0_hwrf_thompson.xml | 4 +- io/FV3GFS_io.F90 | 18 +- 7 files changed, 101 insertions(+), 523 deletions(-) delete mode 100644 ccpp/suites/suite_FV3_HAFS_v0_hwrf.xml diff --git a/ccpp/config/ccpp_prebuild_config.py b/ccpp/config/ccpp_prebuild_config.py index 771e53b04..8fbaae737 100755 --- a/ccpp/config/ccpp_prebuild_config.py +++ b/ccpp/config/ccpp_prebuild_config.py @@ -180,8 +180,6 @@ 'physics/physics/sfc_cice.f', 'physics/physics/sfc_diff.f', 'physics/physics/sfc_drv.f', - 'physics/physics/sfc_noah_wrfv4_interstitial.F90', - 'physics/physics/sfc_noah_wrfv4.F90', 'physics/physics/sfc_noahmp_drv.F90', 'physics/physics/flake_driver.F90', 'physics/physics/sfc_nst.f', diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index 5a6ee2898..7067b6431 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -242,7 +242,6 @@ module GFS_typedefs real (kind=kind_phys), pointer :: weasdl (:) => null() !< weasd over land real (kind=kind_phys), pointer :: snodi (:) => null() !< snow depth over ice real (kind=kind_phys), pointer :: weasdi (:) => null() !< weasd over ice -! real (kind=kind_phys), pointer :: hprim (:) => null() !< topographic standard deviation in m real (kind=kind_phys), pointer :: hprime (:,:) => null() !< orographic metrics real (kind=kind_phys), pointer :: z0base (:) => null() !< background or baseline surface roughness length in m real (kind=kind_phys), pointer :: semisbase(:) => null() !< background surface emissivity @@ -348,9 +347,6 @@ module GFS_typedefs real (kind=kind_phys), pointer :: smoiseq (:,:) => null() !< real (kind=kind_phys), pointer :: zsnsoxy (:,:) => null() !< -! -- In/Out for HWRF NOAH LSM - real (kind=kind_phys), pointer :: snotime (:) => null() - !--- NSSTM variables (only allocated when [Model%nstf_name(1) > 0]) real (kind=kind_phys), pointer :: tref (:) => null() !< nst_fld%Tref - Reference Temperature real (kind=kind_phys), pointer :: z_c (:) => null() !< nst_fld%z_c - Sub layer cooling thickness @@ -841,7 +837,6 @@ module GFS_typedefs integer :: lsm_noah=1 !< flag for NOAH land surface model integer :: lsm_noahmp=2 !< flag for NOAH land surface model integer :: lsm_ruc=3 !< flag for RUC land surface model - integer :: lsm_noah_wrfv4 = 4 !< flag for NOAH land surface from WRF v4.0 integer :: lsoil !< number of soil layers integer :: ivegsrc !< ivegsrc = 0 => USGS, !< ivegsrc = 1 => IGBP (20 category) @@ -1812,7 +1807,6 @@ module GFS_typedefs real (kind=kind_phys), pointer :: alb1d(:) => null() !< real (kind=kind_phys), pointer :: alpha(:,:) => null() !< real (kind=kind_phys), pointer :: bexp1d(:) => null() !< - real (kind=kind_phys), pointer :: canopy_save(:) => null() !< real (kind=kind_phys), pointer :: cd(:) => null() !< real (kind=kind_phys), pointer :: cd_ice(:) => null() !< real (kind=kind_phys), pointer :: cd_land(:) => null() !< @@ -1825,7 +1819,6 @@ module GFS_typedefs real (kind=kind_phys), pointer :: chh_ice(:) => null() !< real (kind=kind_phys), pointer :: chh_land(:) => null() !< real (kind=kind_phys), pointer :: chh_water(:) => null() !< - real (kind=kind_phys), pointer :: chk_land(:) => null() !< real (kind=kind_phys), pointer :: clcn(:,:) => null() !< real (kind=kind_phys), pointer :: cldf(:) => null() !< real (kind=kind_phys), pointer :: cldsa(:,:) => null() !< @@ -1835,7 +1828,6 @@ module GFS_typedefs real (kind=kind_phys), pointer :: clouds(:,:,:) => null() !< real (kind=kind_phys), pointer :: clw(:,:,:) => null() !< real (kind=kind_phys), pointer :: clx(:,:) => null() !< - real (kind=kind_phys), pointer :: cmc(:) => null() !< real (kind=kind_phys), pointer :: cmm_ice(:) => null() !< real (kind=kind_phys), pointer :: cmm_land(:) => null() !< real (kind=kind_phys), pointer :: cmm_water(:) => null() !< @@ -1856,10 +1848,8 @@ module GFS_typedefs real (kind=kind_phys), pointer :: delr(:,:) => null() !< real (kind=kind_phys), pointer :: dlength(:) => null() !< real (kind=kind_phys), pointer :: dqdt(:,:,:) => null() !< - real (kind=kind_phys), pointer :: dqsdt2(:) => null() !< real (kind=kind_phys), pointer :: dqsfc1(:) => null() !< real (kind=kind_phys), pointer :: drain(:) => null() !< - real (kind=kind_phys), pointer :: drain_in_m_sm1(:) => null() !< real (kind=kind_phys), pointer :: dtdt(:,:) => null() !< real (kind=kind_phys), pointer :: dtsfc1(:) => null() !< real (kind=kind_phys), pointer :: dtzm(:) => null() !< @@ -1894,8 +1884,6 @@ module GFS_typedefs logical, pointer :: flag_cice(:) => null() !< logical, pointer :: flag_guess(:) => null() !< logical, pointer :: flag_iter(:) => null() !< - logical, pointer :: flag_lsm(:) => null() !< - logical, pointer :: flag_lsm_glacier(:)=> null() !< real (kind=kind_phys), pointer :: ffmm_ice(:) => null() !< real (kind=kind_phys), pointer :: ffmm_land(:) => null() !< real (kind=kind_phys), pointer :: ffmm_water(:) => null() !< @@ -2001,8 +1989,6 @@ module GFS_typedefs real (kind=kind_phys), pointer :: qss_ice(:) => null() !< real (kind=kind_phys), pointer :: qss_land(:) => null() !< real (kind=kind_phys), pointer :: qss_water(:) => null() !< - real (kind=kind_phys), pointer :: qs1(:) => null() !< - real (kind=kind_phys), pointer :: qv1(:) => null() !< logical :: radar_reset !< real (kind=kind_phys) :: raddt !< real (kind=kind_phys), pointer :: rainmp(:) => null() !< @@ -2017,9 +2003,7 @@ module GFS_typedefs logical :: max_hourly_reset !< logical :: ext_diag_thompson_reset !< real (kind=kind_phys), pointer :: rhc(:,:) => null() !< - real (kind=kind_phys), pointer :: rho1(:) => null() !< real (kind=kind_phys), pointer :: runoff(:) => null() !< - real (kind=kind_phys), pointer :: runoff_in_m_sm1(:) => null() !< real (kind=kind_phys), pointer :: save_q(:,:,:) => null() !< real (kind=kind_phys), pointer :: save_t(:,:) => null() !< real (kind=kind_phys), pointer :: save_tcp(:,:) => null() !< @@ -2034,34 +2018,21 @@ module GFS_typedefs real (kind=kind_phys), pointer :: sigmafrac(:,:) => null() !< real (kind=kind_phys), pointer :: sigmatot(:,:) => null() !< logical :: skip_macro !< - real (kind=kind_phys), pointer :: slc_save(:,:) => null() !< - real (kind=kind_phys), pointer :: smcmax(:) => null() !< - real (kind=kind_phys), pointer :: smc_save(:,:) => null() !< real (kind=kind_phys), pointer :: snowc(:) => null() !< -! real (kind=kind_phys), pointer :: snowd_ice(:) => null() !< - real (kind=kind_phys), pointer :: snowd_land_save(:) => null() !< - real (kind=kind_phys), pointer :: snow_depth(:) => null() !< real (kind=kind_phys), pointer :: snohf(:) => null() !< - real (kind=kind_phys), pointer :: snohf_snow(:) => null() !< - real (kind=kind_phys), pointer :: snohf_frzgra(:) => null() !< - real (kind=kind_phys), pointer :: snohf_snowmelt(:) => null() !< real (kind=kind_phys), pointer :: snowmp(:) => null() !< real (kind=kind_phys), pointer :: snowmt(:) => null() !< - real (kind=kind_phys), pointer :: soilm_in_m(:) => null() !< - real (kind=kind_phys), pointer :: stc_save(:,:) => null() !< real (kind=kind_phys), pointer :: stress(:) => null() !< real (kind=kind_phys), pointer :: stress_ice(:) => null() !< real (kind=kind_phys), pointer :: stress_land(:) => null() !< real (kind=kind_phys), pointer :: stress_water(:) => null() !< real (kind=kind_phys), pointer :: t2mmp(:) => null() !< real (kind=kind_phys), pointer :: theta(:) => null() !< - real (kind=kind_phys), pointer :: th1(:) => null() !< real (kind=kind_phys), pointer :: tlvl(:,:) => null() !< real (kind=kind_phys), pointer :: tlyr(:,:) => null() !< real (kind=kind_phys), pointer :: tprcp_ice(:) => null() !< real (kind=kind_phys), pointer :: tprcp_land(:) => null() !< real (kind=kind_phys), pointer :: tprcp_water(:) => null() !< - real (kind=kind_phys), pointer :: tprcp_rate_land(:) => null() !< integer :: tracers_start_index !< integer :: tracers_total !< integer :: tracers_water !< @@ -2069,8 +2040,6 @@ module GFS_typedefs real (kind=kind_phys), pointer :: trans(:) => null() !< real (kind=kind_phys), pointer :: tseal(:) => null() !< real (kind=kind_phys), pointer :: tsfa(:) => null() !< -! real (kind=kind_phys), pointer :: tsfc_ice(:) => null() !< - real (kind=kind_phys), pointer :: tsfc_land_save(:) => null() !< real (kind=kind_phys), pointer :: tsfc_water(:) => null() !< real (kind=kind_phys), pointer :: tsfg(:) => null() !< real (kind=kind_phys), pointer :: tsurf_ice(:) => null() !< @@ -2086,10 +2055,6 @@ module GFS_typedefs real (kind=kind_phys), pointer :: w_upi(:,:) => null() !< real (kind=kind_phys), pointer :: wcbmax(:) => null() !< -! real (kind=kind_phys), pointer :: weasd_water(:) => null() !< -! real (kind=kind_phys), pointer :: weasd_land(:) => null() !< - real (kind=kind_phys), pointer :: weasd_land_save(:) => null() !< -! real (kind=kind_phys), pointer :: weasd_ice(:) => null() !< real (kind=kind_phys), pointer :: wind(:) => null() !< real (kind=kind_phys), pointer :: work1(:) => null() !< real (kind=kind_phys), pointer :: work2(:) => null() !< @@ -2354,7 +2319,6 @@ subroutine sfcprop_create (Sfcprop, IM, Model) allocate (Sfcprop%weasdl (IM)) allocate (Sfcprop%snodi (IM)) allocate (Sfcprop%weasdi (IM)) -! allocate (Sfcprop%hprim (IM)) allocate (Sfcprop%hprime (IM,Model%nmtvr)) allocate(Sfcprop%albdirvis_lnd (IM)) allocate(Sfcprop%albdirnir_lnd (IM)) @@ -2384,7 +2348,6 @@ subroutine sfcprop_create (Sfcprop, IM, Model) Sfcprop%weasdl = clear_val Sfcprop%snodi = clear_val Sfcprop%weasdi = clear_val -! Sfcprop%hprim = clear_val Sfcprop%hprime = clear_val Sfcprop%albdirvis_lnd = clear_val Sfcprop%albdirnir_lnd = clear_val @@ -2458,7 +2421,6 @@ subroutine sfcprop_create (Sfcprop, IM, Model) allocate (Sfcprop%albdifvis_ice (IM)) allocate (Sfcprop%albdirnir_ice (IM)) allocate (Sfcprop%albdifnir_ice (IM)) -! allocate (Sfcprop%sfalb_ice (IM)) endif if (Model%lsm == Model%lsm_ruc) then allocate (Sfcprop%sfalb_lnd (IM)) @@ -2484,7 +2446,6 @@ subroutine sfcprop_create (Sfcprop, IM, Model) Sfcprop%albdifvis_ice = clear_val Sfcprop%albdirnir_ice = clear_val Sfcprop%albdifnir_ice = clear_val -! Sfcprop%sfalb_ice = clear_val endif if (Model%lsm == Model%lsm_ruc) then Sfcprop%sfalb_lnd = clear_val @@ -2566,106 +2527,98 @@ subroutine sfcprop_create (Sfcprop, IM, Model) ! if (Model%lsm == Model%lsm_noahmp ) then - allocate (Sfcprop%snowxy (IM)) - allocate (Sfcprop%tvxy (IM)) - allocate (Sfcprop%tgxy (IM)) - allocate (Sfcprop%canicexy (IM)) - allocate (Sfcprop%canliqxy (IM)) - allocate (Sfcprop%eahxy (IM)) - allocate (Sfcprop%tahxy (IM)) - allocate (Sfcprop%cmxy (IM)) - allocate (Sfcprop%chxy (IM)) - allocate (Sfcprop%fwetxy (IM)) - allocate (Sfcprop%sneqvoxy (IM)) - allocate (Sfcprop%alboldxy (IM)) - allocate (Sfcprop%qsnowxy (IM)) - allocate (Sfcprop%wslakexy (IM)) - allocate (Sfcprop%zwtxy (IM)) - allocate (Sfcprop%waxy (IM)) - allocate (Sfcprop%wtxy (IM)) - allocate (Sfcprop%lfmassxy (IM)) - allocate (Sfcprop%rtmassxy (IM)) - allocate (Sfcprop%stmassxy (IM)) - allocate (Sfcprop%woodxy (IM)) - allocate (Sfcprop%stblcpxy (IM)) - allocate (Sfcprop%fastcpxy (IM)) - allocate (Sfcprop%xsaixy (IM)) - allocate (Sfcprop%xlaixy (IM)) - allocate (Sfcprop%taussxy (IM)) - allocate (Sfcprop%smcwtdxy (IM)) - allocate (Sfcprop%deeprechxy (IM)) - allocate (Sfcprop%rechxy (IM)) - allocate (Sfcprop%snicexy (IM, Model%lsnow_lsm_lbound:Model%lsnow_lsm_ubound)) - allocate (Sfcprop%snliqxy (IM, Model%lsnow_lsm_lbound:Model%lsnow_lsm_ubound)) - allocate (Sfcprop%tsnoxy (IM, Model%lsnow_lsm_lbound:Model%lsnow_lsm_ubound)) - allocate (Sfcprop%smoiseq (IM, Model%lsoil_lsm)) - allocate (Sfcprop%zsnsoxy (IM, Model%lsnow_lsm_lbound:Model%lsoil_lsm)) - - Sfcprop%snowxy = clear_val - Sfcprop%tvxy = clear_val - Sfcprop%tgxy = clear_val - Sfcprop%canicexy = clear_val - Sfcprop%canliqxy = clear_val - Sfcprop%eahxy = clear_val - Sfcprop%tahxy = clear_val - Sfcprop%cmxy = clear_val - Sfcprop%chxy = clear_val - Sfcprop%fwetxy = clear_val - Sfcprop%sneqvoxy = clear_val - Sfcprop%alboldxy = clear_val - Sfcprop%qsnowxy = clear_val - Sfcprop%wslakexy = clear_val - Sfcprop%zwtxy = clear_val - Sfcprop%waxy = clear_val - Sfcprop%wtxy = clear_val - Sfcprop%lfmassxy = clear_val - Sfcprop%rtmassxy = clear_val - Sfcprop%stmassxy = clear_val - Sfcprop%woodxy = clear_val - Sfcprop%stblcpxy = clear_val - Sfcprop%fastcpxy = clear_val - Sfcprop%xsaixy = clear_val - Sfcprop%xlaixy = clear_val - Sfcprop%taussxy = clear_val - Sfcprop%smcwtdxy = clear_val - Sfcprop%deeprechxy = clear_val - Sfcprop%rechxy = clear_val - - Sfcprop%snicexy = clear_val - Sfcprop%snliqxy = clear_val - Sfcprop%tsnoxy = clear_val - Sfcprop%smoiseq = clear_val - Sfcprop%zsnsoxy = clear_val - - allocate(Sfcprop%draincprv (IM)) - allocate(Sfcprop%drainncprv (IM)) - allocate(Sfcprop%diceprv (IM)) - allocate(Sfcprop%dsnowprv (IM)) - allocate(Sfcprop%dgraupelprv(IM)) - - Sfcprop%draincprv = clear_val - Sfcprop%drainncprv = clear_val - Sfcprop%diceprv = clear_val - Sfcprop%dsnowprv = clear_val - Sfcprop%dgraupelprv = clear_val - - endif + allocate (Sfcprop%snowxy (IM)) + allocate (Sfcprop%tvxy (IM)) + allocate (Sfcprop%tgxy (IM)) + allocate (Sfcprop%canicexy (IM)) + allocate (Sfcprop%canliqxy (IM)) + allocate (Sfcprop%eahxy (IM)) + allocate (Sfcprop%tahxy (IM)) + allocate (Sfcprop%cmxy (IM)) + allocate (Sfcprop%chxy (IM)) + allocate (Sfcprop%fwetxy (IM)) + allocate (Sfcprop%sneqvoxy (IM)) + allocate (Sfcprop%alboldxy (IM)) + allocate (Sfcprop%qsnowxy (IM)) + allocate (Sfcprop%wslakexy (IM)) + allocate (Sfcprop%zwtxy (IM)) + allocate (Sfcprop%waxy (IM)) + allocate (Sfcprop%wtxy (IM)) + allocate (Sfcprop%lfmassxy (IM)) + allocate (Sfcprop%rtmassxy (IM)) + allocate (Sfcprop%stmassxy (IM)) + allocate (Sfcprop%woodxy (IM)) + allocate (Sfcprop%stblcpxy (IM)) + allocate (Sfcprop%fastcpxy (IM)) + allocate (Sfcprop%xsaixy (IM)) + allocate (Sfcprop%xlaixy (IM)) + allocate (Sfcprop%taussxy (IM)) + allocate (Sfcprop%smcwtdxy (IM)) + allocate (Sfcprop%deeprechxy (IM)) + allocate (Sfcprop%rechxy (IM)) + allocate (Sfcprop%snicexy (IM, Model%lsnow_lsm_lbound:Model%lsnow_lsm_ubound)) + allocate (Sfcprop%snliqxy (IM, Model%lsnow_lsm_lbound:Model%lsnow_lsm_ubound)) + allocate (Sfcprop%tsnoxy (IM, Model%lsnow_lsm_lbound:Model%lsnow_lsm_ubound)) + allocate (Sfcprop%smoiseq (IM, Model%lsoil_lsm)) + allocate (Sfcprop%zsnsoxy (IM, Model%lsnow_lsm_lbound:Model%lsoil_lsm)) + + Sfcprop%snowxy = clear_val + Sfcprop%tvxy = clear_val + Sfcprop%tgxy = clear_val + Sfcprop%canicexy = clear_val + Sfcprop%canliqxy = clear_val + Sfcprop%eahxy = clear_val + Sfcprop%tahxy = clear_val + Sfcprop%cmxy = clear_val + Sfcprop%chxy = clear_val + Sfcprop%fwetxy = clear_val + Sfcprop%sneqvoxy = clear_val + Sfcprop%alboldxy = clear_val + Sfcprop%qsnowxy = clear_val + Sfcprop%wslakexy = clear_val + Sfcprop%zwtxy = clear_val + Sfcprop%waxy = clear_val + Sfcprop%wtxy = clear_val + Sfcprop%lfmassxy = clear_val + Sfcprop%rtmassxy = clear_val + Sfcprop%stmassxy = clear_val + Sfcprop%woodxy = clear_val + Sfcprop%stblcpxy = clear_val + Sfcprop%fastcpxy = clear_val + Sfcprop%xsaixy = clear_val + Sfcprop%xlaixy = clear_val + Sfcprop%taussxy = clear_val + Sfcprop%smcwtdxy = clear_val + Sfcprop%deeprechxy = clear_val + Sfcprop%rechxy = clear_val + + Sfcprop%snicexy = clear_val + Sfcprop%snliqxy = clear_val + Sfcprop%tsnoxy = clear_val + Sfcprop%smoiseq = clear_val + Sfcprop%zsnsoxy = clear_val + + allocate(Sfcprop%draincprv (IM)) + allocate(Sfcprop%drainncprv (IM)) + allocate(Sfcprop%diceprv (IM)) + allocate(Sfcprop%dsnowprv (IM)) + allocate(Sfcprop%dgraupelprv(IM)) + + Sfcprop%draincprv = clear_val + Sfcprop%drainncprv = clear_val + Sfcprop%diceprv = clear_val + Sfcprop%dsnowprv = clear_val + Sfcprop%dgraupelprv = clear_val - ! HWRF NOAH LSM allocate and init when used - ! - if (Model%lsm == Model%lsm_noah_wrfv4 ) then - allocate(Sfcprop%snotime(IM)) - Sfcprop%snotime = clear_val - end if + endif - if (Model%do_myjsfc.or.Model%do_myjpbl.or.(Model%lsm == Model%lsm_noah_wrfv4)) then + if (Model%do_myjsfc .or. Model%do_myjpbl) then allocate(Sfcprop%z0base(IM)) Sfcprop%z0base = clear_val end if - !if (Model%lsm == Model%lsm_noah_wrfv4 .or. Model%lsm == Model%lsm_ruc) then - allocate(Sfcprop%semisbase(IM)) - Sfcprop%semisbase = clear_val - !end if + + allocate(Sfcprop%semisbase(IM)) + Sfcprop%semisbase = clear_val if (Model%lsm == Model%lsm_ruc) then ! For land surface models with different numbers of levels than the four NOAH levels @@ -4102,11 +4055,6 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & Model%lsm = lsm Model%lsoil = lsoil - ! Consistency check for HWRF Noah LSM - if (Model%lsm == Model%lsm_noah_wrfv4 .and. Model%nscyc>0) then - write(0,*) 'Logic error: NOAH WRFv4 LSM cannot be used with surface data cycling at this point (fhcyc>0)' - stop - end if ! Flag to read leaf area index from input files (initial conditions) Model%rdlai = rdlai if (Model%rdlai .and. .not. Model%lsm == Model%lsm_ruc) then @@ -4134,18 +4082,13 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & end if Model%zs = (/-0.1_kind_phys, -0.4_kind_phys, -1.0_kind_phys, -2.0_kind_phys/) Model%dzs = (/ 0.1_kind_phys, 0.3_kind_phys, 0.6_kind_phys, 1.0_kind_phys/) - elseif (Model%lsm==Model%lsm_ruc .or. Model%lsm==Model%lsm_noah_wrfv4) then + elseif (Model%lsm==Model%lsm_ruc) then Model%zs = clear_val Model%dzs = clear_val end if ! *DH - if (Model%lsm==Model%lsm_noah_wrfv4) then - if (Model%lsoil_lsm/=4) then - write(0,*) 'Error in GFS_typedefs.F90, number of soil layers must be 4 for Noah_WRFv4' - stop - end if - elseif (Model%lsm==Model%lsm_ruc) then + if (Model%lsm==Model%lsm_ruc) then if (Model%lsoil_lsm/=9) then write(0,*) 'Error in GFS_typedefs.F90, number of soil layers must be 9 for RUC' stop @@ -4155,7 +4098,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & ! Set number of ice model layers Model%kice = kice - if (Model%lsm==Model%lsm_noah .or. Model%lsm==Model%lsm_noahmp .or. Model%lsm==Model%lsm_noah_wrfv4) then + if (Model%lsm==Model%lsm_noah .or. Model%lsm==Model%lsm_noahmp) then if (kice/=2) then write(0,*) 'Error in GFS_typedefs.F90, number of ice model layers must be 2 for Noah/NoahMP/Noah_WRFv4' stop @@ -4938,8 +4881,6 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & print *,'iopt_stc = ', Model%iopt_stc elseif (Model%lsm == Model%lsm_ruc) then print *,' RUC Land Surface Model used' - elseif (Model%lsm == Model%lsm_noah_wrfv4) then - print *,' NOAH WRFv4 Land Surface Model used' else print *,' Unsupported LSM type - job aborted - lsm=',Model%lsm stop @@ -7136,7 +7077,6 @@ subroutine interstitial_create (Interstitial, IM, Model) allocate (Interstitial%sigmafrac (IM,Model%levs)) allocate (Interstitial%sigmatot (IM,Model%levs)) allocate (Interstitial%snowc (IM)) -! allocate (Interstitial%snowd_ice (IM)) allocate (Interstitial%snohf (IM)) allocate (Interstitial%snowmt (IM)) allocate (Interstitial%stress (IM)) @@ -7152,7 +7092,6 @@ subroutine interstitial_create (Interstitial, IM, Model) allocate (Interstitial%trans (IM)) allocate (Interstitial%tseal (IM)) allocate (Interstitial%tsfa (IM)) -! allocate (Interstitial%tsfc_ice (IM)) allocate (Interstitial%tsfc_water (IM)) allocate (Interstitial%tsfg (IM)) allocate (Interstitial%tsurf_ice (IM)) @@ -7165,9 +7104,6 @@ subroutine interstitial_create (Interstitial, IM, Model) allocate (Interstitial%vdftra (IM,Model%levs,Interstitial%nvdiff)) !GJF first dimension was set as 'IX' in GFS_physics_driver allocate (Interstitial%vegf1d (IM)) allocate (Interstitial%wcbmax (IM)) -! allocate (Interstitial%weasd_ice (IM)) -! allocate (Interstitial%weasd_land (IM)) -! allocate (Interstitial%weasd_water (IM)) allocate (Interstitial%wind (IM)) allocate (Interstitial%work1 (IM)) allocate (Interstitial%work2 (IM)) @@ -7365,33 +7301,6 @@ subroutine interstitial_create (Interstitial, IM, Model) allocate (Interstitial%t2mmp (IM)) allocate (Interstitial%q2mp (IM)) end if - if (Model%lsm == Model%lsm_noah_wrfv4) then - allocate (Interstitial%canopy_save (IM)) - allocate (Interstitial%chk_land (IM)) - allocate (Interstitial%cmc (IM)) - allocate (Interstitial%dqsdt2 (IM)) - allocate (Interstitial%drain_in_m_sm1 (IM)) - allocate (Interstitial%flag_lsm (IM)) - allocate (Interstitial%flag_lsm_glacier(IM)) - allocate (Interstitial%qs1 (IM)) - allocate (Interstitial%qv1 (IM)) - allocate (Interstitial%rho1 (IM)) - allocate (Interstitial%runoff_in_m_sm1 (IM)) - allocate (Interstitial%slc_save (IM,Model%lsoil)) - allocate (Interstitial%smcmax (IM)) - allocate (Interstitial%smc_save (IM,Model%lsoil)) - allocate (Interstitial%snowd_land_save (IM)) - allocate (Interstitial%snow_depth (IM)) - allocate (Interstitial%snohf_snow (IM)) - allocate (Interstitial%snohf_frzgra (IM)) - allocate (Interstitial%snohf_snowmelt (IM)) - allocate (Interstitial%soilm_in_m (IM)) - allocate (Interstitial%stc_save (IM,Model%lsoil)) - allocate (Interstitial%th1 (IM)) - allocate (Interstitial%tprcp_rate_land (IM)) - allocate (Interstitial%tsfc_land_save (IM)) - allocate (Interstitial%weasd_land_save (IM)) - end if ! ! Set components that do not change Interstitial%frain = Model%dtf/Model%dtp @@ -7833,7 +7742,6 @@ subroutine interstitial_phys_reset (Interstitial, Model) Interstitial%sigmafrac = clear_val Interstitial%sigmatot = clear_val Interstitial%snowc = clear_val -! Interstitial%snowd_ice = Model%huge Interstitial%snohf = clear_val Interstitial%snowmt = clear_val Interstitial%stress = clear_val @@ -7846,7 +7754,6 @@ subroutine interstitial_phys_reset (Interstitial, Model) Interstitial%tprcp_water = Model%huge Interstitial%trans = clear_val Interstitial%tseal = clear_val -! Interstitial%tsfc_ice = Model%huge Interstitial%tsfc_water = Model%huge Interstitial%tsurf_ice = Model%huge Interstitial%tsurf_land = Model%huge @@ -7859,9 +7766,6 @@ subroutine interstitial_phys_reset (Interstitial, Model) Interstitial%vegf1d = clear_val Interstitial%lndp_vgf = clear_val Interstitial%wcbmax = clear_val -! Interstitial%weasd_ice = Model%huge -! Interstitial%weasd_land = Model%huge -! Interstitial%weasd_water = Model%huge Interstitial%wind = Model%huge Interstitial%work1 = clear_val Interstitial%work2 = clear_val @@ -7942,33 +7846,6 @@ subroutine interstitial_phys_reset (Interstitial, Model) Interstitial%t2mmp = clear_val Interstitial%q2mp = clear_val end if - if (Model%lsm == Model%lsm_noah_wrfv4) then - Interstitial%canopy_save = clear_val - Interstitial%chk_land = Model%huge - Interstitial%cmc = clear_val - Interstitial%dqsdt2 = clear_val - Interstitial%drain_in_m_sm1 = clear_val - Interstitial%flag_lsm = .false. - Interstitial%flag_lsm_glacier= .false. - Interstitial%qs1 = Model%huge - Interstitial%qv1 = Model%huge - Interstitial%rho1 = clear_val - Interstitial%runoff_in_m_sm1 = clear_val - Interstitial%slc_save = clear_val - Interstitial%smcmax = clear_val - Interstitial%smc_save = clear_val - Interstitial%snowd_land_save = Model%huge - Interstitial%snow_depth = clear_val - Interstitial%snohf_snow = clear_val - Interstitial%snohf_frzgra = clear_val - Interstitial%snohf_snowmelt = clear_val - Interstitial%soilm_in_m = clear_val - Interstitial%stc_save = clear_val - Interstitial%th1 = clear_val - Interstitial%tprcp_rate_land = Model%huge - Interstitial%tsfc_land_save = Model%huge - Interstitial%weasd_land_save = Model%huge - end if ! ! Set flag for resetting maximum hourly output fields Interstitial%max_hourly_reset = mod(Model%kdt-1, nint(Model%avg_max_length/Model%dtp)) == 0 diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index bbba06ca4..d8bad3b03 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -1317,14 +1317,6 @@ type = real kind = kind_phys active = (control_for_land_surface_scheme == identifier_for_noahmp_land_surface_scheme) -[snotime] - standard_name = time_since_last_snowfall - long_name = elapsed time since last snowfall - units = s - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [albdirvis_lnd] standard_name = surface_albedo_direct_visible_over_land long_name = direct surface albedo visible band over land @@ -3568,12 +3560,6 @@ units = flag dimensions = () type = integer -[lsm_noah_wrfv4] - standard_name = identifier_for_noah_wrfv4_land_surface_scheme - long_name = flag for NOAH WRFv4 land surface model - units = flag - dimensions = () - type = integer [kice] standard_name = vertical_dimension_of_sea_ice long_name = vertical loop extent for ice levels, start at 1 @@ -7577,14 +7563,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[canopy_save] - standard_name = canopy_water_amount_save - long_name = canopy water amount before entering a physics scheme - units = kg m-2 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [cd] standard_name = surface_drag_coefficient_for_momentum_in_air long_name = surface exchange coeff for momentum @@ -7662,14 +7640,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[chk_land] - standard_name = surface_conductance_for_heat_and_moisture_in_air_over_land - long_name = surface conductance for heat & moisture over land - units = m s-1 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [cf_upi] standard_name = convective_cloud_fraction_for_microphysics long_name = convective cloud fraction for microphysics @@ -7819,14 +7789,6 @@ dimensions = (horizontal_loop_extent,4) type = real kind = kind_phys -[cmc] - standard_name = canopy_water_amount_in_m - long_name = canopy water amount in m - units = m - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [clxss] standard_name = fraction_of_grid_box_with_subgrid_orography_higher_than_critical_height_small_scale long_name = frac. of grid box with by subgrid height_above_mean_sea_level higher than critical height small scale @@ -8067,14 +8029,6 @@ dimensions = (horizontal_loop_extent,vertical_layer_dimension) type = real kind = kind_phys -[dqsdt2] - standard_name = saturation_specific_humidity_slope - long_name = saturation specific humidity slope at lowest model layer - units = K-1 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [dqsfc1] standard_name = instantaneous_surface_upward_latent_heat_flux long_name = surface upward latent heat flux @@ -8089,14 +8043,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[drain_in_m_sm1] - standard_name = subsurface_runoff_flux_in_m_sm1 - long_name = subsurface runoff flux in m s-1 - units = m s-1 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [dtdt] standard_name = process_split_cumulative_tendency_of_air_temperature long_name = air temperature tendency due to model physics @@ -8381,20 +8327,6 @@ units = flag dimensions = (horizontal_loop_extent) type = logical -[flag_lsm] - standard_name = flag_for_calling_land_surface_model - long_name = flag for calling land surface model - units = flag - dimensions = (horizontal_loop_extent) - type = logical - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) -[flag_lsm_glacier] - standard_name = flag_for_calling_land_surface_model_glacier - long_name = flag for calling land surface model over glacier - units = flag - dimensions = (horizontal_loop_extent) - type = logical - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [ffmm_water] standard_name = Monin_Obukhov_similarity_function_for_momentum_over_water long_name = Monin-Obukhov similarity function for momentum over water @@ -9172,22 +9104,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[qs1] - standard_name = saturation_specific_humidity_at_lowest_model_layer - long_name = saturation specific humidity at lowest model layer - units = kg kg-1 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) -[qv1] - standard_name = bounded_specific_humidity_at_lowest_model_layer_over_land - long_name = specific humidity at lowest model layer over land bounded between a nonzero epsilon and saturation - units = kg kg-1 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [radar_reset] standard_name = flag_for_resetting_radar_reflectivity_calculation long_name = flag for resetting radar reflectivity calculation @@ -9298,14 +9214,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[runoff_in_m_sm1] - standard_name = surface_runoff_flux_in_m_sm1 - long_name = surface runoff flux in m s-1 - units = m s-1 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [save_q(:,:,index_of_ozone_mixing_ratio_in_tracer_concentration_array)] standard_name = ozone_mixing_ratio_save long_name = ozone mixing ratio before entering a physics scheme @@ -9472,30 +9380,6 @@ units = flag dimensions = () type = logical -[slc_save] - standard_name = volume_fraction_of_unfrozen_soil_moisture_save - long_name = liquid soil moisture before entering a physics scheme - units = frac - dimensions = (horizontal_loop_extent,vertical_dimension_of_soil) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) -[smcmax] - standard_name = soil_porosity - long_name = volumetric soil porosity - units = frac - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) -[smc_save] - standard_name = volume_fraction_of_soil_moisture_save - long_name = total soil moisture before entering a physics scheme - units = frac - dimensions = (horizontal_loop_extent,vertical_dimension_of_soil) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [snowc] standard_name = surface_snow_area_fraction long_name = surface snow area fraction @@ -9503,22 +9387,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[snowd_land_save] - standard_name = surface_snow_thickness_water_equivalent_over_land_save - long_name = water equivalent snow depth over land before entering a physics scheme - units = mm - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) -[snow_depth] - standard_name = actual_snow_depth - long_name = actual snow depth - units = m - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [snohf] standard_name = snow_freezing_rain_upward_latent_heat_flux long_name = latent heat flux due to snow and frz rain @@ -9526,30 +9394,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[snohf_snow] - standard_name = latent_heat_flux_from_precipitating_snow - long_name = latent heat flux due to precipitating snow - units = W m-2 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) -[snohf_frzgra] - standard_name = latent_heat_flux_from_freezing_rain - long_name = latent heat flux due to freezing rain - units = W m-2 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) -[snohf_snowmelt] - standard_name = latent_heat_flux_due_to_snowmelt - long_name = latent heat flux due to snowmelt phase change - units = W m-2 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [snowmp] standard_name = lwe_thickness_of_snow_amount long_name = explicit snow fall on physics timestep @@ -9565,22 +9409,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[soilm_in_m] - standard_name = soil_moisture_content_in_m - long_name = soil moisture in meters - units = m - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) -[stc_save] - standard_name = soil_temperature_save - long_name = soil temperature before entering a physics scheme - units = K - dimensions = (horizontal_loop_extent,vertical_dimension_of_soil) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [stress] standard_name = surface_wind_stress long_name = surface wind stress @@ -9624,14 +9452,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[th1] - standard_name = potential_temperature_at_lowest_model_layer - long_name = potential_temperature_at_lowest_model_layer - units = K - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [tlvl] standard_name = air_temperature_at_interface_for_radiation long_name = air temperature at vertical interface for radiation calculation @@ -9667,14 +9487,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[tprcp_rate_land] - standard_name = total_precipitation_rate_on_dynamics_timestep_over_land - long_name = total precipitation rate in each time step over land - units = kg m-2 s-1 - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [tracers_start_index] standard_name = start_index_of_other_tracers long_name = beginning index of the non-water tracer species @@ -9721,14 +9533,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[tsfc_land_save] - standard_name = surface_skin_temperature_over_land_save - long_name = surface skin temperature over land before entering a physics scheme - units = K - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [tsfg] standard_name = surface_ground_temperature_for_radiation long_name = surface ground temperature for radiation @@ -9827,14 +9631,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys -[weasd_land_save] - standard_name = water_equivalent_accumulated_snow_depth_over_land_save - long_name = water equiv of acc snow depth over land before entering a physics scheme - units = mm - dimensions = (horizontal_loop_extent) - type = real - kind = kind_phys - active = (control_for_land_surface_scheme == identifier_for_noah_wrfv4_land_surface_scheme) [wind] standard_name = wind_speed_at_lowest_model_layer long_name = wind speed at lowest model level diff --git a/ccpp/physics b/ccpp/physics index 530f597d3..6912955bc 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 530f597d34a4dab2bedf590480474e86a2e9bac1 +Subproject commit 6912955bcb4e0437f725fe88726c55954abb4b87 diff --git a/ccpp/suites/suite_FV3_HAFS_v0_hwrf.xml b/ccpp/suites/suite_FV3_HAFS_v0_hwrf.xml deleted file mode 100644 index fbe105f67..000000000 --- a/ccpp/suites/suite_FV3_HAFS_v0_hwrf.xml +++ /dev/null @@ -1,91 +0,0 @@ - - - - - - - GFS_time_vary_pre - GFS_rrtmg_setup - GFS_rad_time_vary - GFS_phys_time_vary - - - - - GFS_suite_interstitial_rad_reset - GFS_rrtmg_pre - GFS_radiation_surface - rrtmg_lw_pre - rrtmg_lw - rrtmg_lw_post - rrtmg_sw_pre - rrtmg_sw - rrtmg_sw_post - GFS_rrtmg_post - - - - - GFS_suite_interstitial_phys_reset - GFS_suite_stateout_reset - get_prs_fv3 - GFS_suite_interstitial_1 - GFS_surface_generic_pre - GFS_surface_composites_pre - dcyc2t3 - GFS_surface_composites_inter - GFS_suite_interstitial_2 - - - - gfdl_sfc_layer - GFS_surface_loop_control_part1 - sfc_nst_pre - sfc_nst - sfc_nst_post - sfc_noah_wrfv4_pre - sfc_noah_wrfv4 - sfc_noah_wrfv4_post - sfc_sice - GFS_surface_loop_control_part2 - - - - GFS_surface_composites_post - sfc_diag - sfc_diag_post - GFS_surface_generic_post - GFS_PBL_generic_pre - hedmf - GFS_PBL_generic_post - GFS_GWD_generic_pre - cires_ugwp - cires_ugwp_post - GFS_GWD_generic_post - GFS_suite_stateout_update - ozphys_2015 - h2ophys - GFS_DCNV_generic_pre - get_phi_fv3 - GFS_suite_interstitial_3 - samfdeepcnv - GFS_DCNV_generic_post - GFS_SCNV_generic_pre - samfshalcnv - GFS_SCNV_generic_post - GFS_suite_interstitial_4 - cnvc90 - GFS_MP_generic_pre - mp_fer_hires - GFS_MP_generic_post - maximum_hourly_diagnostics - phys_tend - - - - - GFS_stochastics - - - - diff --git a/ccpp/suites/suite_FV3_HAFS_v0_hwrf_thompson.xml b/ccpp/suites/suite_FV3_HAFS_v0_hwrf_thompson.xml index 5d894c2f2..2bc2f8592 100644 --- a/ccpp/suites/suite_FV3_HAFS_v0_hwrf_thompson.xml +++ b/ccpp/suites/suite_FV3_HAFS_v0_hwrf_thompson.xml @@ -45,9 +45,7 @@ sfc_nst_pre sfc_nst sfc_nst_post - sfc_noah_wrfv4_pre - sfc_noah_wrfv4 - sfc_noah_wrfv4_post + noahmpdrv sfc_sice GFS_surface_loop_control_part2 diff --git a/io/FV3GFS_io.F90 b/io/FV3GFS_io.F90 index 6dfe29a46..7b1becf10 100644 --- a/io/FV3GFS_io.F90 +++ b/io/FV3GFS_io.F90 @@ -233,7 +233,7 @@ subroutine FV3GFS_GFS_checksum (Model, GFS_Data, Atm_block) temp2d(i,j,32) = GFS_Data(nb)%Sfcprop%f10m(ix) temp2d(i,j,33) = GFS_Data(nb)%Sfcprop%tprcp(ix) temp2d(i,j,34) = GFS_Data(nb)%Sfcprop%srflag(ix) - if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. Model%lsm == Model%lsm_noah_wrfv4) then + if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp) then temp2d(i,j,35) = GFS_Data(nb)%Sfcprop%slc(ix,1) temp2d(i,j,36) = GFS_Data(nb)%Sfcprop%slc(ix,2) temp2d(i,j,37) = GFS_Data(nb)%Sfcprop%slc(ix,3) @@ -775,7 +775,7 @@ subroutine sfc_prop_restart_read (Sfcprop, Atm_block, Model, fv_domain, warm_sta allocate(sfc_name3(0:nvar_s3+nvar_s3mp)) allocate(sfc_var2(nx,ny,nvar_s2m+nvar_s2o+nvar_s2mp+nvar_s2r),sfc_var3ice(nx,ny,Model%kice)) - if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. Model%lsm == Model%lsm_noah_wrfv4 .or. (.not.warm_start)) then + if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. (.not.warm_start)) then allocate(sfc_var3(nx,ny,Model%lsoil,nvar_s3)) else if (Model%lsm == Model%lsm_ruc) then allocate(sfc_var3(nx,ny,Model%lsoil_lsm,nvar_s3)) @@ -947,7 +947,7 @@ subroutine sfc_prop_restart_read (Sfcprop, Atm_block, Model, fv_domain, warm_sta call register_axis(Sfc_restart, 'yaxis_1', 'Y') call register_axis(Sfc_restart, 'zaxis_1', dimension_length=Model%kice) - if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. Model%lsm == Model%lsm_noah_wrfv4) then + if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp) then call register_axis(Sfc_restart, 'zaxis_2', dimension_length=Model%lsoil) else if(Model%lsm == Model%lsm_ruc) then call register_axis(Sfc_restart, 'zaxis_2', dimension_length=Model%lsoil_lsm) @@ -1031,7 +1031,7 @@ subroutine sfc_prop_restart_read (Sfcprop, Atm_block, Model, fv_domain, warm_sta endif ! if not allocated - if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. Model%lsm == Model%lsm_noah_wrfv4 .or. (.not.warm_start)) then + if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. (.not.warm_start)) then !--- names of the 3D variables to save sfc_name3(1) = 'stc' sfc_name3(2) = 'smc' @@ -1385,7 +1385,7 @@ subroutine sfc_prop_restart_read (Sfcprop, Atm_block, Model, fv_domain, warm_sta Sfcprop(nb)%rechxy(ix) = sfc_var2(i,j,nvar_s2m+47) endif - if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. Model%lsm == Model%lsm_noah_wrfv4 .or. (.not.warm_start)) then + if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. (.not.warm_start)) then !--- 3D variables do lsoil = 1,Model%lsoil Sfcprop(nb)%stc(ix,lsoil) = sfc_var3(i,j,lsoil,1) !--- stc @@ -1723,7 +1723,7 @@ subroutine sfc_prop_restart_write (Sfcprop, Atm_block, Model, fv_domain, timesta call write_data(Sfc_restart, 'zaxis_1', buffer) deallocate(buffer) - if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. Model%lsm == Model%lsm_noah_wrfv4) then + if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp) then call register_axis(Sfc_restart, 'zaxis_2', dimension_length=Model%lsoil) call register_field(Sfc_restart, 'zaxis_2', 'double', (/'zaxis_2'/)) call register_variable_attribute(Sfc_restart, 'zaxis_2', 'cartesian_axis', 'Z', str_len=1) @@ -1770,7 +1770,7 @@ subroutine sfc_prop_restart_write (Sfcprop, Atm_block, Model, fv_domain, timesta allocate(sfc_name2(nvar2m+nvar2o+nvar2mp+nvar2r)) allocate(sfc_name3(0:nvar3+nvar3mp)) allocate(sfc_var2(nx,ny,nvar2m+nvar2o+nvar2mp+nvar2r)) - if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. Model%lsm == Model%lsm_noah_wrfv4) then + if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp) then allocate(sfc_var3(nx,ny,Model%lsoil,nvar3)) elseif (Model%lsm == Model%lsm_ruc) then allocate(sfc_var3(nx,ny,Model%lsoil_lsm,nvar3)) @@ -1963,7 +1963,7 @@ subroutine sfc_prop_restart_write (Sfcprop, Atm_block, Model, fv_domain, timesta endif nullify(var2_p) - if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. Model%lsm == Model%lsm_noah_wrfv4) then + if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp) then !--- names of the 3D variables to save sfc_name3(1) = 'stc' sfc_name3(2) = 'smc' @@ -2168,7 +2168,7 @@ subroutine sfc_prop_restart_write (Sfcprop, Atm_block, Model, fv_domain, timesta if (sfc_var3ice(i,j,k) < one) sfc_var3ice(i,j,k) = zero enddo - if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp .or. Model%lsm == Model%lsm_noah_wrfv4) then + if (Model%lsm == Model%lsm_noah .or. Model%lsm == Model%lsm_noahmp) then !--- 3D variables do lsoil = 1,Model%lsoil sfc_var3(i,j,lsoil,1) = Sfcprop(nb)%stc(ix,lsoil) !--- stc From bb55c2c7f487b68a653ddaa4f32ed7d23d9b3a7c Mon Sep 17 00:00:00 2001 From: Bin Liu Date: Tue, 2 Nov 2021 08:21:15 -0500 Subject: [PATCH 4/9] Enable running regional telescopic nesting configuration under ufs-weather-model (#400) * Enable running regional telescopic nesting configuration under the ufs-weather-model framework. Enable outputting a grid from the write grid component, which is larger than the native computation grid of the nested/regional domain. a. Remove the limitation of the output grid being completely inside the model native compuation grid. b. Mask out the output grid points outside the computation grid with missing values. --- module_fcst_grid_comp.F90 | 83 +++++++++++++++++++++++++-------------- 1 file changed, 54 insertions(+), 29 deletions(-) diff --git a/module_fcst_grid_comp.F90 b/module_fcst_grid_comp.F90 index a6e69b13a..b9e6bdd9f 100644 --- a/module_fcst_grid_comp.F90 +++ b/module_fcst_grid_comp.F90 @@ -46,13 +46,13 @@ module module_fcst_grid_comp use fms_mod, only: error_mesg, fms_init, fms_end, & write_version_number, uppercase - use mpp_mod, only: mpp_init, mpp_pe, mpp_root_pe, & - mpp_error, FATAL, WARNING + use mpp_mod, only: mpp_init, mpp_pe, mpp_npes, mpp_root_pe, & + mpp_error, FATAL, WARNING, NOTE use mpp_mod, only: mpp_clock_id, mpp_clock_begin use mpp_io_mod, only: mpp_open, mpp_close, MPP_DELETE - use mpp_domains_mod, only: mpp_get_compute_domains, domain2D + use mpp_domains_mod, only: mpp_get_compute_domains, domain2D use sat_vapor_pres_mod, only: sat_vapor_pres_init use diag_manager_mod, only: diag_manager_init, diag_manager_end, & @@ -206,8 +206,8 @@ subroutine fcst_initialize(fcst_comp, importState, exportState, clock, rc) type(ESMF_Decomp_Flag) :: decompflagPTile(2,6) - integer :: globalTileLayout(2) - integer :: nestRootPet, peListSize(1) + integer :: TileLayout(2) + integer :: nestRootPet, npes(1), peListSize(1) integer, allocatable :: petMap(:) integer :: num_restart_interval, restart_starttime @@ -435,7 +435,7 @@ subroutine fcst_initialize(fcst_comp, importState, exportState, clock, rc) !*** first try: Create cubed sphere grid from file !----------------------------------------------------------------------- ! - if (mype == 0) write(0,*)'be create fcst grid' + call mpp_error(NOTE, 'before create fcst grid') gridfile = "grid_spec.nc" ! default @@ -443,7 +443,11 @@ subroutine fcst_initialize(fcst_comp, importState, exportState, clock, rc) call read_data("INPUT/grid_spec.nc", "atm_mosaic_file", gridfile) endif - if( atm_int_state%Atm%regional ) then + if (mpp_pe() == mpp_root_pe()) & + write(*, *) 'create fcst grid: mype,regional,nested=',mype,atm_int_state%Atm%regional,atm_int_state%Atm%nested + + ! regional-only without nests + if( atm_int_state%Atm%regional .and. .not. atm_int_state%Atm%nested ) then call atmosphere_control_data (isc, iec, jsc, jec, nlev) @@ -485,44 +489,63 @@ subroutine fcst_initialize(fcst_comp, importState, exportState, clock, rc) enddo enddo - ! add and define "corner" coordinate values - call ESMF_GridAddCoord(fcstGrid, staggerLoc=ESMF_STAGGERLOC_CORNER, & - rc=rc); ESMF_ERR_ABORT(rc) - call ESMF_GridGetCoord(fcstGrid, coordDim=1, staggerLoc=ESMF_STAGGERLOC_CORNER, & - totalLBound=tlb, totalUBound=tub, & - farrayPtr=glonPtr, rc=rc); ESMF_ERR_ABORT(rc) - glonPtr(tlb(1):tub(1),tlb(2):tub(2)) = & - atm_int_state%Atm%lon_bnd(tlb(1):tub(1),tlb(2):tub(2)) * dtor - call ESMF_GridGetCoord(fcstGrid, coordDim=2, staggerLoc=ESMF_STAGGERLOC_CORNER, & - totalLBound=tlb, totalUBound=tub, & - farrayPtr=glatPtr, rc=rc); ESMF_ERR_ABORT(rc) - glatPtr(tlb(1):tub(1),tlb(2):tub(2)) = & - atm_int_state%Atm%lat_bnd(tlb(1):tub(1),tlb(2):tub(2)) * dtor + ! add and define "corner" coordinate values + call ESMF_GridAddCoord(fcstGrid, staggerLoc=ESMF_STAGGERLOC_CORNER, & + rc=rc); ESMF_ERR_ABORT(rc) + call ESMF_GridGetCoord(fcstGrid, coordDim=1, staggerLoc=ESMF_STAGGERLOC_CORNER, & + totalLBound=tlb, totalUBound=tub, & + farrayPtr=glonPtr, rc=rc); ESMF_ERR_ABORT(rc) + glonPtr(tlb(1):tub(1),tlb(2):tub(2)) = & + atm_int_state%Atm%lon_bnd(tlb(1):tub(1),tlb(2):tub(2)) * dtor + call ESMF_GridGetCoord(fcstGrid, coordDim=2, staggerLoc=ESMF_STAGGERLOC_CORNER, & + totalLBound=tlb, totalUBound=tub, & + farrayPtr=glatPtr, rc=rc); ESMF_ERR_ABORT(rc) + glatPtr(tlb(1):tub(1),tlb(2):tub(2)) = & + atm_int_state%Atm%lat_bnd(tlb(1):tub(1),tlb(2):tub(2)) * dtor - else ! not regional + call mpp_error(NOTE, 'after create fcst grid for regional-only') - if ( .not. atm_int_state%Atm%nested ) then !! global only + else ! not regional only + + if (.not. atm_int_state%Atm%regional .and. .not. atm_int_state%Atm%nested ) then !! global only do tl=1,6 decomptile(1,tl) = atm_int_state%Atm%layout(1) decomptile(2,tl) = atm_int_state%Atm%layout(2) decompflagPTile(:,tl) = (/ESMF_DECOMP_SYMMEDGEMAX,ESMF_DECOMP_SYMMEDGEMAX/) enddo - fcstGrid = ESMF_GridCreateMosaic(filename="INPUT/"//trim(gridfile), & + fcstGrid = ESMF_GridCreateMosaic(filename="INPUT/"//trim(gridfile), & regDecompPTile=decomptile,tileFilePath="INPUT/", & decompflagPTile=decompflagPTile, & staggerlocList=(/ESMF_STAGGERLOC_CENTER, ESMF_STAGGERLOC_CORNER/), & name='fcst_grid', rc=rc) if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=__FILE__)) return - else !! nesting + call mpp_error(NOTE, 'after create fcst grid for global-only with INPUT/'//trim(gridfile)) + + else !! global-nesting or regional-nesting - if (mype==0) globalTileLayout = atm_int_state%Atm%layout - call ESMF_VMBroadcast(vm, bcstData=globalTileLayout, count=2, & + if (mype==0) TileLayout = atm_int_state%Atm%layout + call ESMF_VMBroadcast(vm, bcstData=TileLayout, count=2, & rootPet=0, rc=rc) if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=__FILE__)) return - nestRootPet = globalTileLayout(1) * globalTileLayout(2) * 6 + if (mype==0) npes(1) = mpp_npes() + call ESMF_VMBroadcast(vm, bcstData=npes, count=1, & + rootPet=0, rc=rc) + if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=__FILE__)) return + + if ( npes(1) == TileLayout(1) * TileLayout(2) * 6 ) then + ! global-nesting + nestRootPet = npes(1) + gridfile="grid.nest02.tile7.nc" + else if ( npes(1) == TileLayout(1) * TileLayout(2) ) then + ! regional-nesting + nestRootPet = npes(1) + gridfile="grid.nest02.tile2.nc" + else + call mpp_error(FATAL, 'Inconsistent nestRootPet and Atm%layout') + endif if (mype == nestRootPet) then if (nestRootPet /= atm_int_state%Atm%pelist(1)) then @@ -555,13 +578,15 @@ subroutine fcst_initialize(fcst_comp, importState, exportState, clock, rc) if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=__FILE__)) return ! create the nest Grid by reading it from file but use DELayout - fcstGrid = ESMF_GridCreate(filename='INPUT/grid.nest02.tile7.nc', & + fcstGrid = ESMF_GridCreate(filename="INPUT/"//trim(gridfile), & fileformat=ESMF_FILEFORMAT_GRIDSPEC, regDecomp=regDecomp, & decompflag=(/ESMF_DECOMP_SYMMEDGEMAX,ESMF_DECOMP_SYMMEDGEMAX/), & delayout=delayout, isSphere=.false., indexflag=ESMF_INDEX_DELOCAL, & - rc=rc) + rc=rc) if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=__FILE__)) return + call mpp_error(NOTE, 'after create fcst grid with INPUT/'//trim(gridfile)) + endif endif From c8140b21c4a7e6d294d8ac3183a6012e6c44dbb2 Mon Sep 17 00:00:00 2001 From: Dom Heinzeller Date: Wed, 3 Nov 2021 18:32:13 -0600 Subject: [PATCH 5/9] Wrapper PR for "Remove optional arguments from CCPP metadata, remove effective radii computation from Thompson MP" and "Fix/improve logic for convective transportable tracers, add GFS_checktracer debugging routine, correct spelling "janic" --> "janjic", fix inconsistent types related with noahmp and log functions" (#416) * Add missing active attribute for one variable in ccpp/data/GFS_typedefs.meta * Correct spelling of janic in CCPP standard names, must be janjic * Remove invalid optional and intent attributes from DDT metadata in ccpp/data/GFS_typedefs.meta * Remove support for optional arguments from CCPP framework/metadata --- ccpp/config/ccpp_prebuild_config.py | 80 ----------------------------- ccpp/data/GFS_typedefs.F90 | 1 - ccpp/data/GFS_typedefs.meta | 55 ++++++-------------- ccpp/framework | 2 +- ccpp/physics | 2 +- 5 files changed, 18 insertions(+), 122 deletions(-) diff --git a/ccpp/config/ccpp_prebuild_config.py b/ccpp/config/ccpp_prebuild_config.py index 8fbaae737..bbc7da433 100755 --- a/ccpp/config/ccpp_prebuild_config.py +++ b/ccpp/config/ccpp_prebuild_config.py @@ -236,86 +236,6 @@ # Directory where the suite definition files are stored SUITES_DIR = 'suites' -# Optional arguments - only required for schemes that use -# optional arguments. ccpp_prebuild.py will throw an exception -# if it encounters a scheme subroutine with optional arguments -# if no entry is made here. Possible values are: 'all', 'none', -# or a list of standard_names: [ 'var1', 'var3' ]. -OPTIONAL_ARGUMENTS = { - 'rrtmg_sw' : { - 'rrtmg_sw_run' : [ - 'tendency_of_air_temperature_due_to_shortwave_heating_assuming_clear_sky_on_radiation_time_step_and_radiation_levels', - 'components_of_surface_downward_shortwave_fluxes', - 'cloud_liquid_water_path', - 'mean_effective_radius_for_liquid_cloud', - 'cloud_ice_water_path', - 'mean_effective_radius_for_ice_cloud', - 'cloud_rain_water_path', - 'mean_effective_radius_for_rain_drop', - 'cloud_snow_water_path', - 'mean_effective_radius_for_snow_flake', - ], - }, - 'rrtmg_lw' : { - 'rrtmg_lw_run' : [ - 'tendency_of_air_temperature_due_to_longwave_heating_assuming_clear_sky_on_radiation_time_step_and_radiation_levels', - 'cloud_liquid_water_path', - 'mean_effective_radius_for_liquid_cloud', - 'cloud_ice_water_path', - 'mean_effective_radius_for_ice_cloud', - 'cloud_rain_water_path', - 'mean_effective_radius_for_rain_drop', - 'cloud_snow_water_path', - 'mean_effective_radius_for_snow_flake', - ], - }, - 'mp_thompson' : { - 'mp_thompson_init' : [ - 'mass_number_concentration_of_cloud_liquid_water_particles_in_air', - 'mass_number_concentration_of_hygroscopic_aerosols', - 'mass_number_concentration_of_nonhygroscopic_ice_nucleating_aerosols', - 'tendency_of_hygroscopic_aerosols_at_surface_adjacent_layer', - 'tendency_of_nonhygroscopic_ice_nucleating_aerosols_at_surface_adjacent_layer', - # DH* 2020-06-01: turn off calculation of effective radii, now done in GFS_rrtmg_pre - #'effective_radius_of_stratiform_cloud_liquid_water_particle', - #'effective_radius_of_stratiform_cloud_ice_particle', - #'effective_radius_of_stratiform_cloud_snow_particle', - # *DH 2020-06-01 - ], - 'mp_thompson_run' : [ - 'mass_number_concentration_of_cloud_liquid_water_particles_in_air_of_new_state', - 'mass_number_concentration_of_hygroscopic_aerosols_of_new_state', - 'mass_number_concentration_of_nonhygroscopic_ice_nucleating_aerosols_of_new_state', - 'tendency_of_hygroscopic_aerosols_at_surface_adjacent_layer', - 'tendency_of_nonhygroscopic_ice_nucleating_aerosols_at_surface_adjacent_layer', - # DH* 2020-06-01: turn off calculation of effective radii, now done in GFS_rrtmg_pre - #'effective_radius_of_stratiform_cloud_liquid_water_particle', - #'effective_radius_of_stratiform_cloud_ice_particle', - #'effective_radius_of_stratiform_cloud_snow_particle', - # *DH 2020-06-01 - ], - }, - 'rrtmgp_sw_rte' : { - 'rrtmgp_sw_rte_run' : [ - 'components_of_surface_downward_shortwave_fluxes', - ], - }, - 'GFS_rrtmgp_sw_post' : { - 'GFS_rrtmgp_sw_post_run' : [ - 'tendency_of_air_temperature_due_to_shortwave_heating_assuming_clear_sky_on_radiation_timestep', - 'components_of_surface_downward_shortwave_fluxes', - ], - }, - 'GFS_rrtmgp_lw_post' : { - 'GFS_rrtmgp_lw_post_run' : [ - 'tendency_of_air_temperature_due_to_longwave_heating_assuming_clear_sky_on_radiation_timestep', - ], - }, - #'subroutine_name_1' : 'all', - #'subroutine_name_2' : 'none', - #'subroutine_name_2' : [ 'var1', 'var3'], - } - # Directory where to write static API to STATIC_API_DIR = '{build_dir}/physics' STATIC_API_SRCFILE = '{build_dir}/physics/CCPP_STATIC_API.sh' diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index 7067b6431..177a920a3 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -7406,7 +7406,6 @@ subroutine interstitial_setup_tracers(Interstitial, Model) Interstitial%ntiwx = 0 endif endif - ! *DH if (Model%cplchm) then ! Only Zhao/Carr/Sundqvist and GFDL microphysics schemes are supported diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index d8bad3b03..e9860eecb 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -627,6 +627,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [semisbase] standard_name = baseline_surface_longwave_emissivity long_name = baseline surface lw emissivity in fraction @@ -678,7 +679,6 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - optional = F active = (control_for_land_surface_scheme == identifier_for_ruc_land_surface_scheme) [sfalb_ice] standard_name = surface_diffused_shortwave_albedo_over_ice @@ -3513,7 +3513,6 @@ dimensions = () type = logical intent = in - optional = F [sedi_semi_update] standard_name = flag_for_v_update_in_semi_Lagrangian_sedi long_name = flag for v update in semi Lagrangian sedi of rain @@ -3521,7 +3520,6 @@ dimensions = () type = logical intent = in - optional = F [sedi_semi_decfl] standard_name = flag_for_iteration_with_semi_Lagrangian_sedi long_name = flag for interation with semi Lagrangian sedi of rain @@ -3529,7 +3527,6 @@ dimensions = () type = logical intent = in - optional = F [lgfdlmprad] standard_name = flag_for_GFDL_microphysics_radiation_interaction long_name = flag for GFDL microphysics-radiation interaction @@ -5271,13 +5268,13 @@ dimensions = () type = logical [do_myjsfc] - standard_name = flag_for_mellor_yamada_janic_surface_layer_scheme + standard_name = flag_for_mellor_yamada_janjic_surface_layer_scheme long_name = flag to activate MYJ surface layer scheme units = flag dimensions = () type = logical [do_myjpbl] - standard_name = flag_for_mellor_yamada_janic_pbl_scheme + standard_name = flag_for_mellor_yamada_janjic_pbl_scheme long_name = flag to activate MYJ PBL scheme units = flag dimensions = () @@ -5429,72 +5426,54 @@ units = flag dimensions = () type = logical - intent = in - optional = F [do_ugwp_v0_orog_only] standard_name = flag_for_ugwp_version_0_orographic_gwd long_name = flag to activate ver 0 CIRES UGWP - orographic GWD only units = flag dimensions = () type = logical - intent = in - optional = F [do_ugwp_v0_nst_only] standard_name = flag_for_ugwp_version_0_nonorographic_gwd long_name = flag to activate ver 0 CIRES UGWP - non-stationary GWD only units = flag dimensions = () type = logical - intent = in - optional = F [do_gsl_drag_ls_bl] standard_name = flag_for_gsl_drag_suite_large_scale_orographic_and_blocking_drag long_name = flag to activate GSL drag suite - large-scale GWD and blocking units = flag dimensions = () type = logical - intent = in - optional = F [do_gsl_drag_ss] standard_name = flag_for_gsl_drag_suite_small_scale_orographic_drag long_name = flag to activate GSL drag suite - small-scale GWD units = flag dimensions = () type = logical - intent = in - optional = F [do_gsl_drag_tofd] standard_name = flag_for_gsl_drag_suite_turbulent_orographic_form_drag long_name = flag to activate GSL drag suite - turb orog form drag units = flag dimensions = () type = logical - intent = in - optional = F [do_ugwp_v1] standard_name = flag_for_ugwp_version_1 long_name = flag to activate ver 1 CIRES UGWP units = flag dimensions = () type = logical - intent = in - optional = F [do_ugwp_v1_orog_only] standard_name = flag_for_ugwp_version_1_orographic_gwd long_name = flag to activate ver 1 CIRES UGWP - orographic GWD only units = flag dimensions = () type = logical - intent = in - optional = F [do_ugwp_v1_w_gsldrag] standard_name = flag_for_ugwp_version_1_nonorographic_gwd long_name = flag to activate ver 1 CIRES UGWP - with OGWD of GSL units = flag dimensions = () type = logical - intent = in - optional = F [lmfdeep2] standard_name = flag_for_scale_aware_mass_flux_deep_convection_for_radiation long_name = flag for some scale-aware mass-flux convection scheme active @@ -6136,7 +6115,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_thz0] standard_name = air_potential_temperature_at_top_of_viscous_sublayer long_name = potential temperature at viscous sublayer top over water @@ -6144,7 +6123,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_qz0] standard_name = specific_humidity_at_top_of_viscous_sublayer long_name = specific humidity at_viscous sublayer top over water @@ -6152,7 +6131,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_uz0] standard_name = x_wind_at_top_of_viscous_sublayer long_name = u wind component at viscous sublayer top over water @@ -6160,7 +6139,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_vz0] standard_name = y_wind_at_top_of_viscous_sublayer long_name = v wind component at viscous sublayer top over water @@ -6168,7 +6147,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_akhs] standard_name = heat_exchange_coefficient_for_MYJ_schemes long_name = surface heat exchange_coefficient for MYJ schemes @@ -6176,7 +6155,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_akms] standard_name = momentum_exchange_coefficient_for_MYJ_schemes long_name = surface momentum exchange_coefficient for MYJ schemes @@ -6184,7 +6163,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_chkqlm] standard_name = control_for_surface_layer_evaporation long_name = surface layer evaporation switch @@ -6192,15 +6171,15 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_elflx] - standard_name = surface_upward_specific_humidity_flux_for_mellor_yamada_janic_surface_layer_scheme + standard_name = surface_upward_specific_humidity_flux_for_mellor_yamada_janjic_surface_layer_scheme long_name = kinematic surface latent heat flux units = m s-1 kg kg-1 dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_a1u] standard_name = weight_for_momentum_at_top_of_viscous_sublayer long_name = weight for momentum at viscous layer top @@ -6208,7 +6187,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_a1t] standard_name = weight_for_potental_temperature_at_top_of_viscous_sublayer long_name = weight for potental temperature at viscous layer top @@ -6216,7 +6195,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) [phy_myj_a1q] standard_name = weight_for_specific_humidity_at_top_of_viscous_sublayer long_name = weight for Specfic Humidity at viscous layer top @@ -6224,7 +6203,7 @@ dimensions = (horizontal_loop_extent) type = real kind = kind_phys - active = (flag_for_mellor_yamada_janic_surface_layer_scheme .or. flag_for_mellor_yamada_janic_pbl_scheme) + active = (flag_for_mellor_yamada_janjic_surface_layer_scheme .or. flag_for_mellor_yamada_janjic_pbl_scheme) ######################################################################## [ccpp-table-properties] @@ -9831,7 +9810,6 @@ dimensions = (horizontal_loop_extent,vertical_layer_dimension) type = real kind = kind_phys - optional = F active = (flag_for_rrtmgp_radiation_scheme) [q_lay] standard_name = water_vapor_mixing_ratio @@ -9840,7 +9818,6 @@ dimensions = (horizontal_loop_extent,vertical_layer_dimension) type = real kind = kind_phys - optional = F active = (flag_for_rrtmgp_radiation_scheme) [p_lay] standard_name = air_pressure_at_layer_for_RRTMGP diff --git a/ccpp/framework b/ccpp/framework index f7a4af8c4..47a5f65ae 160000 --- a/ccpp/framework +++ b/ccpp/framework @@ -1 +1 @@ -Subproject commit f7a4af8c4a322b0a75e0eb3896512522bca6cfa9 +Subproject commit 47a5f65ae6b760b513d7babfbe66138a8f4a23bc diff --git a/ccpp/physics b/ccpp/physics index 6912955bc..eb2875603 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 6912955bcb4e0437f725fe88726c55954abb4b87 +Subproject commit eb28756036b280c2c1a741112045fefd5639c6a9 From 699d1e2398ed28233912e54f424ff393aba17145 Mon Sep 17 00:00:00 2001 From: Raffaele Montuoro Date: Tue, 9 Nov 2021 10:58:54 -0600 Subject: [PATCH 6/9] Support implementation of TVD methods in PBL and cumulus convective schemes (#408) This PR implements changes supporting TVD methods for PBL and cumulus convective parameterizations introduced by ccpp/physics PR #754 (Jongil Han, NOAA/EMC). --- ccpp/data/GFS_typedefs.F90 | 28 +++++++++++++++++++--------- ccpp/data/GFS_typedefs.meta | 6 ++++++ ccpp/physics | 2 +- 3 files changed, 26 insertions(+), 10 deletions(-) diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index 177a920a3..74da764dc 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -1966,6 +1966,7 @@ module GFS_typedefs integer :: nspc1 !< integer :: ntcwx !< integer :: ntiwx !< + integer :: ntrwx !< integer :: ntk !< integer :: ntkev !< integer :: nvdiff !< @@ -7351,6 +7352,9 @@ subroutine interstitial_setup_tracers(Interstitial, Model) Interstitial%otspt(:,:) = .true. Interstitial%nsamftrac = 0 Interstitial%ncstrac = 0 + Interstitial%ntcwx = 0 + Interstitial%ntiwx = 0 + Interstitial%ntrwx = 0 ! perform aerosol convective transport and PBL diffusion Interstitial%trans_aero = Model%cplchm .and. Model%trans_trac @@ -7383,27 +7387,33 @@ subroutine interstitial_setup_tracers(Interstitial, Model) Interstitial%nscav = Model%ntrac - Model%ncnd + 2 - Interstitial%ntcwx = Model%ntcw if (Interstitial%nvdiff == Model%ntrac) then + Interstitial%ntcwx = Model%ntcw Interstitial%ntiwx = Model%ntiw + Interstitial%ntrwx = Model%ntrw else if (Model%imp_physics == Model%imp_physics_wsm6) then + Interstitial%ntcwx = 2 Interstitial%ntiwx = 3 elseif (Model%imp_physics == Model%imp_physics_thompson) then - if(Model%ltaerosol) then - Interstitial%ntiwx = 3 - else - Interstitial%ntiwx = 3 - endif + Interstitial%ntcwx = 2 + Interstitial%ntiwx = 3 + Interstitial%ntrwx = 4 elseif (Model%imp_physics == Model%imp_physics_gfdl) then + Interstitial%ntcwx = 2 Interstitial%ntiwx = 3 + Interstitial%ntrwx = 4 ! F-A MP scheme elseif (Model%imp_physics == Model%imp_physics_fer_hires) then - Interstitial%ntiwx = 3 ! total ice or total condensate + Interstitial%ntcwx = 2 + Interstitial%ntiwx = 3 + Interstitial%ntrwx = 4 elseif (Model%imp_physics == Model%imp_physics_mg) then + Interstitial%ntcwx = 2 Interstitial%ntiwx = 3 - else - Interstitial%ntiwx = 0 + Interstitial%ntrwx = 4 + elseif (Model%imp_physics == Model%imp_physics_zhao_carr) then + Interstitial%ntcwx = 2 endif endif diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index e9860eecb..0b5abf86e 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -8898,6 +8898,12 @@ units = index dimensions = () type = integer +[ntrwx] + standard_name = index_for_rain_water_vertical_diffusion_tracer + long_name = tracer index for rain water in the vertically diffused tracer array + units = index + dimensions = () + type = integer [ntk] standard_name = index_for_turbulent_kinetic_energy_convective_transport_tracer long_name = index for turbulent kinetic energy in the convectively transported tracer array diff --git a/ccpp/physics b/ccpp/physics index eb2875603..d18964278 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit eb28756036b280c2c1a741112045fefd5639c6a9 +Subproject commit d189642784545b7edfeebace7b972fea25f42e20 From b5bdf4c5912a6dbdafdf0c126fe0b7c65277ae60 Mon Sep 17 00:00:00 2001 From: lisa-bengtsson <54411948+lisa-bengtsson@users.noreply.github.com> Date: Wed, 10 Nov 2021 09:05:50 -0700 Subject: [PATCH 7/9] Namelist updates associated with new CA scales (#414) Improved scales of CA for P8 --- atmos_model.F90 | 2 +- ccpp/data/GFS_typedefs.F90 | 28 +++++++++---------- .../stochastic_physics_wrapper.F90 | 6 ++-- 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/atmos_model.F90 b/atmos_model.F90 index 6f89625c9..3ac2555e9 100644 --- a/atmos_model.F90 +++ b/atmos_model.F90 @@ -686,7 +686,7 @@ subroutine atmos_model_init (Atmos, Time_init, Time, Time_step) GFS_data%IntDiag, Init_parm, GFS_Diag) call FV3GFS_restart_read (GFS_data, GFS_restart_var, Atm_block, GFS_control, Atmos%domain, Atm(mygrid)%flagstruct%warm_start) if(GFS_control%do_ca .and. Atm(mygrid)%flagstruct%warm_start)then - call read_ca_restart (Atmos%domain,GFS_control%scells,GFS_control%nca,GFS_control%ncells_g,GFS_control%nca_g) + call read_ca_restart (Atmos%domain,GFS_control%ncells,GFS_control%nca,GFS_control%ncells_g,GFS_control%nca_g) endif ! Populate the GFS_data%Statein container with the prognostic state ! in Atm_block, which contains the initial conditions/restart data. diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index 74da764dc..a1a4db794 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -1113,8 +1113,8 @@ module GFS_typedefs !---cellular automata control parameters integer :: nca !< number of independent cellular automata - integer :: tlives !< cellular automata lifetime - integer :: scells !< cellular automata finer grid + integer :: nlives !< cellular automata lifetime + integer :: ncells !< cellular automata finer grid integer :: nca_g !< number of independent cellular automata integer :: nlives_g !< cellular automata lifetime integer :: ncells_g !< cellular automata finer grid @@ -1127,7 +1127,6 @@ module GFS_typedefs logical :: ca_smooth !< switch for gaussian spatial filter integer(kind=kind_dbl_prec) :: iseed_ca !< seed for random number generation in ca scheme integer :: nspinup !< number of iterations to spin up the ca - real(kind=kind_phys) :: rcell !< threshold used for CA scheme real(kind=kind_phys) :: nthresh !< threshold used for convection coupling real :: ca_amplitude !< amplitude of ca trigger perturbation integer :: nsmooth !< number of passes through smoother @@ -3465,8 +3464,9 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & !---Cellular automaton options integer :: nca = 1 - integer :: scells = 2600 - integer :: tlives = 1800 + integer :: ncells = 5 + integer :: nlives = 12 + integer :: nca_g = 1 integer :: ncells_g = 1 integer :: nlives_g = 100 @@ -3479,7 +3479,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & logical :: ca_sgs = .false. logical :: ca_global = .false. logical :: ca_smooth = .false. - real(kind=kind_phys) :: rcell = 0.72 + real(kind=kind_phys) :: nthresh = 18 real :: ca_amplitude = 0.35 integer :: nsmooth = 100 logical :: ca_closure = .false. @@ -3628,8 +3628,8 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & !--- canopy heat storage parameterization h0facu, h0facs, & !--- cellular automata - nca, scells, tlives, nca_g, ncells_g, nlives_g, nfracseed, & - nseed, nseed_g, rcell, do_ca, & + nca, ncells, nlives, nca_g, ncells_g, nlives_g, nfracseed, & + nseed, nseed_g, nthresh, do_ca, & ca_sgs, ca_global,iseed_ca,ca_smooth, & nspinup,ca_amplitude,nsmooth,ca_closure,ca_entr,ca_trigger, & !--- IAU @@ -4393,8 +4393,8 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & if ( .not. ca_sgs ) nca=0 Model%nca = nca - Model%scells = scells - Model%tlives = tlives + Model%ncells = ncells + Model%nlives = nlives Model%nca_g = nca_g Model%ncells_g = ncells_g Model%nlives_g = nlives_g @@ -4407,7 +4407,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & Model%iseed_ca = iseed_ca Model%ca_smooth = ca_smooth Model%nspinup = nspinup - Model%rcell = rcell + Model%nthresh = nthresh Model%ca_amplitude = ca_amplitude Model%nsmooth = nsmooth Model%ca_closure = ca_closure @@ -5757,8 +5757,8 @@ subroutine control_print(Model) print *, ' ' print *, 'cellular automata' print *, ' nca : ', Model%nca - print *, ' scells : ', Model%scells - print *, ' tlives : ', Model%tlives + print *, ' ncells : ', Model%ncells + print *, ' nlives : ', Model%nlives print *, ' nca_g : ', Model%nca_g print *, ' ncells_g : ', Model%ncells_g print *, ' nlives_g : ', Model%nlives_g @@ -5771,7 +5771,7 @@ subroutine control_print(Model) print *, ' iseed_ca : ', Model%iseed_ca print *, ' ca_smooth : ', Model%ca_smooth print *, ' nspinup : ', Model%nspinup - print *, ' rcell : ', Model%rcell + print *, ' nthresh : ', Model%nthresh print *, ' ca_amplitude : ', Model%ca_amplitude print *, ' nsmooth : ', Model%nsmooth print *, ' ca_closure : ', Model%ca_closure diff --git a/stochastic_physics/stochastic_physics_wrapper.F90 b/stochastic_physics/stochastic_physics_wrapper.F90 index 8a50eae9b..45e8532a8 100644 --- a/stochastic_physics/stochastic_physics_wrapper.F90 +++ b/stochastic_physics/stochastic_physics_wrapper.F90 @@ -307,7 +307,7 @@ subroutine stochastic_physics_wrapper (GFS_Control, GFS_Data, Atm_block, ierr) call cellular_automata_sgs(GFS_Control%kdt,GFS_control%dtp,GFS_control%restart,GFS_Control%first_time_step, & sst,lmsk,lake,condition,ca_deep_cpl,ca_turb_cpl,ca_shal_cpl, Atm(mygrid)%domain_for_coupler,nblks, & Atm_block%isc,Atm_block%iec,Atm_block%jsc,Atm_block%jec,Atm(mygrid)%npx,Atm(mygrid)%npy, levs, & - GFS_Control%nthresh,GFS_Control%rcell,GFS_Control%tile_num,GFS_Control%nca,GFS_Control%scells,GFS_Control%tlives, & + GFS_Control%nthresh,GFS_Control%tile_num,GFS_Control%nca,GFS_Control%ncells,GFS_Control%nlives, & GFS_Control%nfracseed, GFS_Control%nseed,GFS_Control%iseed_ca, & GFS_Control%nspinup,GFS_Control%ca_trigger,Atm_block%blksz(1),GFS_Control%master,GFS_Control%communicator) ! Copy contiguous data back as needed @@ -318,10 +318,10 @@ subroutine stochastic_physics_wrapper (GFS_Control, GFS_Data, Atm_block, ierr) enddo endif if(GFS_Control%ca_global)then - call cellular_automata_global(GFS_Control%kdt,GFS_control%restart,GFS_Control%first_time_step,ca1_cpl,ca2_cpl,ca3_cpl, & + call cellular_automata_global(GFS_Control%kdt,GFS_control%restart,GFS_Control%first_time_step,ca1_cpl,ca2_cpl,ca3_cpl, & Atm(mygrid)%domain_for_coupler, nblks,Atm_block%isc,Atm_block%iec,Atm_block%jsc,Atm_block%jec,Atm(mygrid)%npx,Atm(mygrid)%npy,levs, & GFS_Control%nca_g,GFS_Control%ncells_g,GFS_Control%nlives_g,GFS_Control%nfracseed,GFS_Control%nseed_g, & - GFS_Control%iseed_ca,GFS_control%tile_num,GFS_Control%ca_smooth,GFS_Control%nspinup,Atm_block%blksz(1), & + GFS_Control%iseed_ca,GFS_control%tile_num,GFS_Control%ca_smooth,GFS_Control%nspinup,Atm_block%blksz(1), & GFS_Control%nsmooth,GFS_Control%ca_amplitude,GFS_Control%master,GFS_Control%communicator) ! Copy contiguous data back do nb=1,nblks From 720d4a0695f94c2e007b68c40f5e62041b97d365 Mon Sep 17 00:00:00 2001 From: Dom Heinzeller Date: Fri, 12 Nov 2021 07:47:11 -0700 Subject: [PATCH 8/9] Register diagnostics from stochastic physics only if allocated, fix duplicate symbols error on macOS; ccpp-physics: cleanup CCPP cmake flags part 1; contains "fix the number of 2d fields nsfcprop2d" (#419) (#417) - Fixes a bug inGFS_diagnostics.F90 that registered several stochastic variables as diagnostic output even though th arrays are not allocated if the corresponding stochastic option is turned off - Fixes a problem that led to a "duplicate symbols" error on macOS with Intel by removing files from ccpp/CMakeLists.txt that get added automatically by CCPP - Updates the submodule pointer for ccpp-physics for the changes described in Cleanup CCPP cmake flags part 1, remove extra logic that reduces optimization for radiation_aerosols.f, update CODEOWNERS, update README.md NCAR/ccpp-physics#773 - Contains the changes in fix the number of 2d fields nsfcprop2d #419 from @HelinWei-NOAA - Updates the submodule pointer for GFDL_atmos_cubed_sphere to include latest JEDI control changes (contributed by @mark-a-potts) --- atmos_cubed_sphere | 2 +- ccpp/CMakeLists.txt | 4 - ccpp/data/GFS_typedefs.F90 | 2 +- ccpp/driver/GFS_diagnostics.F90 | 250 +++++++++++++++++--------------- ccpp/physics | 2 +- io/FV3GFS_io.F90 | 30 ++-- 6 files changed, 153 insertions(+), 137 deletions(-) diff --git a/atmos_cubed_sphere b/atmos_cubed_sphere index 8a3a75903..d6bfc1573 160000 --- a/atmos_cubed_sphere +++ b/atmos_cubed_sphere @@ -1 +1 @@ -Subproject commit 8a3a75903de68ae15527f116087ff2020e86d717 +Subproject commit d6bfc1573d34cb2df20fe658568d9cca5232565d diff --git a/ccpp/CMakeLists.txt b/ccpp/CMakeLists.txt index 3ebc40edc..2eafbd952 100644 --- a/ccpp/CMakeLists.txt +++ b/ccpp/CMakeLists.txt @@ -105,10 +105,6 @@ add_subdirectory(physics) add_library( fv3ccpp - data/CCPP_typedefs.F90 - data/GFS_typedefs.F90 - data/CCPP_data.F90 - driver/GFS_diagnostics.F90 driver/GFS_restart.F90 driver/GFS_init.F90 diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index a1a4db794..cd01dbbc8 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -2929,7 +2929,7 @@ subroutine coupling_create (Coupling, IM, Model) endif !--- stochastic physics option - if (Model%do_sppt .or. Model%ca_global)then + if (Model%do_sppt .or. Model%ca_global) then allocate (Coupling%sppt_wts (IM,Model%levs)) Coupling%sppt_wts = clear_val endif diff --git a/ccpp/driver/GFS_diagnostics.F90 b/ccpp/driver/GFS_diagnostics.F90 index be79b5963..529700ca9 100644 --- a/ccpp/driver/GFS_diagnostics.F90 +++ b/ccpp/driver/GFS_diagnostics.F90 @@ -2031,27 +2031,29 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop enddo endif - idx = idx + 1 - ExtDiag(idx)%axes = 3 - ExtDiag(idx)%name = 'skebu_wts' - ExtDiag(idx)%desc = 'perturbation velocity' - ExtDiag(idx)%unit = 'm/s' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var3 => Coupling(nb)%skebu_wts(:,:) - enddo + if (Model%do_skeb) then + idx = idx + 1 + ExtDiag(idx)%axes = 3 + ExtDiag(idx)%name = 'skebu_wts' + ExtDiag(idx)%desc = 'perturbation velocity' + ExtDiag(idx)%unit = 'm/s' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var3 => Coupling(nb)%skebu_wts(:,:) + enddo - idx = idx + 1 - ExtDiag(idx)%axes = 3 - ExtDiag(idx)%name = 'skebv_wts' - ExtDiag(idx)%desc = 'perturbation velocity' - ExtDiag(idx)%unit = 'm/s' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var3 => Coupling(nb)%skebv_wts(:,:) - enddo + idx = idx + 1 + ExtDiag(idx)%axes = 3 + ExtDiag(idx)%name = 'skebv_wts' + ExtDiag(idx)%desc = 'perturbation velocity' + ExtDiag(idx)%unit = 'm/s' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var3 => Coupling(nb)%skebv_wts(:,:) + enddo + endif idx = idx + 1 ExtDiag(idx)%axes = 2 @@ -2085,115 +2087,123 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop ExtDiag(idx)%data(nb)%var2 => IntDiag(nb)%refdmax263k(:) enddo - idx = idx + 1 - ExtDiag(idx)%axes = 3 - ExtDiag(idx)%name = 'sppt_wts' - ExtDiag(idx)%desc = 'perturbation velocity' - ExtDiag(idx)%unit = 'm/s' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var3 => Coupling(nb)%sppt_wts(:,:) - enddo + if (Model%do_sppt .or. Model%ca_global) then + idx = idx + 1 + ExtDiag(idx)%axes = 3 + ExtDiag(idx)%name = 'sppt_wts' + ExtDiag(idx)%desc = 'perturbation velocity' + ExtDiag(idx)%unit = 'm/s' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var3 => Coupling(nb)%sppt_wts(:,:) + enddo + endif - idx = idx + 1 - ExtDiag(idx)%axes = 3 - ExtDiag(idx)%name = 'shum_wts' - ExtDiag(idx)%desc = 'perturbation velocity' - ExtDiag(idx)%unit = 'm/s' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var3 => Coupling(nb)%shum_wts(:,:) - enddo + if (Model%do_shum) then + idx = idx + 1 + ExtDiag(idx)%axes = 3 + ExtDiag(idx)%name = 'shum_wts' + ExtDiag(idx)%desc = 'perturbation velocity' + ExtDiag(idx)%unit = 'm/s' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var3 => Coupling(nb)%shum_wts(:,:) + enddo + endif - idx = idx + 1 - ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'sfc_wts1' - ExtDiag(idx)%desc = 'perturbation amplitude' - ExtDiag(idx)%unit = 'none' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%sfc_wts(:,1) - enddo + if (Model%lndp_type /= 0) then + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'sfc_wts1' + ExtDiag(idx)%desc = 'perturbation amplitude' + ExtDiag(idx)%unit = 'none' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%sfc_wts(:,1) + enddo - idx = idx + 1 - ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'sfc_wts2' - ExtDiag(idx)%desc = 'perturbation amplitude' - ExtDiag(idx)%unit = 'none' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%sfc_wts(:,2) - enddo + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'sfc_wts2' + ExtDiag(idx)%desc = 'perturbation amplitude' + ExtDiag(idx)%unit = 'none' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%sfc_wts(:,2) + enddo + endif - idx = idx + 1 - ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'ca1' - ExtDiag(idx)%desc = 'Cellular Automata' - ExtDiag(idx)%unit = '%' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca1(:) - enddo + if (Model%do_ca) then + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'ca1' + ExtDiag(idx)%desc = 'Cellular Automata' + ExtDiag(idx)%unit = '%' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca1(:) + enddo - idx = idx + 1 - ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'ca_deep' - ExtDiag(idx)%desc = 'CA deep conv' - ExtDiag(idx)%unit = '%' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca_deep(:) - enddo + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'ca_deep' + ExtDiag(idx)%desc = 'CA deep conv' + ExtDiag(idx)%unit = '%' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca_deep(:) + enddo - idx = idx + 1 - ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'ca_turb' - ExtDiag(idx)%desc = 'CA turbulence' - ExtDiag(idx)%unit = '%' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca_turb(:) - enddo + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'ca_turb' + ExtDiag(idx)%desc = 'CA turbulence' + ExtDiag(idx)%unit = '%' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca_turb(:) + enddo - idx = idx + 1 - ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'ca_shal' - ExtDiag(idx)%desc = 'CA shallow conv' - ExtDiag(idx)%unit = '%' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca_shal(:) - enddo + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'ca_shal' + ExtDiag(idx)%desc = 'CA shallow conv' + ExtDiag(idx)%unit = '%' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca_shal(:) + enddo - idx = idx + 1 - ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'ca_rad' - ExtDiag(idx)%desc = 'CA radiation' - ExtDiag(idx)%unit = '%' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca_rad(:) - enddo + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'ca_rad' + ExtDiag(idx)%desc = 'CA radiation' + ExtDiag(idx)%unit = '%' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca_rad(:) + enddo - idx = idx + 1 - ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'ca_micro' - ExtDiag(idx)%desc = 'CA microphys' - ExtDiag(idx)%unit = '%' - ExtDiag(idx)%mod_name = 'gfs_phys' - allocate (ExtDiag(idx)%data(nblks)) - do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca_micro(:) - enddo + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'ca_micro' + ExtDiag(idx)%desc = 'CA microphys' + ExtDiag(idx)%unit = '%' + ExtDiag(idx)%mod_name = 'gfs_phys' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%ca_micro(:) + enddo + endif if (Model%ldiag_ugwp) THEN ! diff --git a/ccpp/physics b/ccpp/physics index d18964278..b8b7c3154 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit d189642784545b7edfeebace7b972fea25f42e20 +Subproject commit b8b7c3154b633a372c79a09c556e54743f0d2c7e diff --git a/io/FV3GFS_io.F90 b/io/FV3GFS_io.F90 index 7b1becf10..157e51102 100644 --- a/io/FV3GFS_io.F90 +++ b/io/FV3GFS_io.F90 @@ -175,15 +175,25 @@ subroutine FV3GFS_GFS_checksum (Model, GFS_Data, Atm_block) ntr = size(GFS_Data(1)%Statein%qgrs,3) + nsfcprop2d = 93 if (Model%lsm == Model%lsm_noahmp) then - nsfcprop2d = 156 + nsfcprop2d = nsfcprop2d + 49 + if (Model%use_cice_alb) then + nsfcprop2d = nsfcprop2d + 4 + endif elseif (Model%lsm == Model%lsm_ruc) then - nsfcprop2d = 125 + nsfcprop2d = nsfcprop2d + 4 + 12 if (Model%rdlai) then nsfcprop2d = nsfcprop2d + 1 endif else - nsfcprop2d = 107 + if (Model%use_cice_alb) then + nsfcprop2d = nsfcprop2d + 4 + endif + endif + + if (Model%nstf_name(1) > 0) then + nsfcprop2d = nsfcprop2d + 16 endif allocate (temp2d(isc:iec,jsc:jec,nsfcprop2d+Model%ntot3d+Model%nctp)) @@ -316,14 +326,14 @@ subroutine FV3GFS_GFS_checksum (Model, GFS_Data, Atm_block) temp2d(i,j,92) = GFS_Data(nb)%Sfcprop%emis_ice(ix) temp2d(i,j,93) = GFS_Data(nb)%Sfcprop%sncovr_ice(ix) - idx_opt = 93 + idx_opt = 94 if (Model%use_cice_alb .or. Model%lsm == Model%lsm_ruc) then - temp2d(i,j,idx_opt+1) = GFS_Data(nb)%Sfcprop%albdirvis_ice(ix) - temp2d(i,j,idx_opt+2) = GFS_Data(nb)%Sfcprop%albdirnir_ice(ix) - temp2d(i,j,idx_opt+3) = GFS_Data(nb)%Sfcprop%albdifvis_ice(ix) - temp2d(i,j,idx_opt+4) = GFS_Data(nb)%Sfcprop%albdifnir_ice(ix) + temp2d(i,j,idx_opt) = GFS_Data(nb)%Sfcprop%albdirvis_ice(ix) + temp2d(i,j,idx_opt+1) = GFS_Data(nb)%Sfcprop%albdirnir_ice(ix) + temp2d(i,j,idx_opt+2) = GFS_Data(nb)%Sfcprop%albdifvis_ice(ix) + temp2d(i,j,idx_opt+3) = GFS_Data(nb)%Sfcprop%albdifnir_ice(ix) + idx_opt = idx_opt + 4 endif - idx_opt = idx_opt + 5 if (Model%lsm == Model%lsm_noahmp) then temp2d(i,j,idx_opt) = GFS_Data(nb)%Sfcprop%snowxy(ix) @@ -390,7 +400,7 @@ subroutine FV3GFS_GFS_checksum (Model, GFS_Data, Atm_block) temp2d(i,j,idx_opt+9) = GFS_Data(nb)%Sfcprop%sfalb_lnd(ix) temp2d(i,j,idx_opt+10) = GFS_Data(nb)%Sfcprop%sfalb_lnd_bck(ix) temp2d(i,j,idx_opt+11) = GFS_Data(nb)%Sfcprop%sfalb_ice(ix) - idx_opt = idx_opt + 11 + idx_opt = idx_opt + 12 if (Model%rdlai) then temp2d(i,j,idx_opt+1) = GFS_Data(nb)%Sfcprop%xlaixy(ix) idx_opt = idx_opt + 1 From 43bb1bd0b22d5ff35ff92afb9e203517db599367 Mon Sep 17 00:00:00 2001 From: Dom Heinzeller Date: Thu, 18 Nov 2021 09:48:30 -0700 Subject: [PATCH 9/9] Revert change to .gitmodules and update submodule pointer for ccpp-physics --- .gitmodules | 6 ++---- ccpp/physics | 2 +- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.gitmodules b/.gitmodules index a1d32b437..554de3eb7 100644 --- a/.gitmodules +++ b/.gitmodules @@ -8,7 +8,5 @@ branch = main [submodule "ccpp/physics"] path = ccpp/physics - #url = https://github.com/NOAA-GSL/ccpp-physics - #branch = gsl/develop - url = https://github.com/climbfuji/ccpp-physics - branch = update_gsl_develop_from_main_20211116 \ No newline at end of file + url = https://github.com/NOAA-GSL/ccpp-physics + branch = gsl/develop diff --git a/ccpp/physics b/ccpp/physics index 12b0f91f7..ce40f9517 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 12b0f91f76bbcbf2ba1a9a03abf0bc1abe20e89a +Subproject commit ce40f95170d2d2cf014011e2071654a131fc7225