From 603af4c2f505bd7c01ecaef1ef3ceef3351dd167 Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Fri, 11 Nov 2022 11:12:36 -0700 Subject: [PATCH 01/25] point ccpp-physics fork --- .gitmodules | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitmodules b/.gitmodules index 22c723ac1..ad9e50004 100644 --- a/.gitmodules +++ b/.gitmodules @@ -8,8 +8,8 @@ branch = main [submodule "ccpp/physics"] path = ccpp/physics - url = https://github.com/ufs-community/ccpp-physics - branch = ufs/dev + url = https://github.com/uturuncoglu/ccpp-physics + branch = feature/noahmp [submodule "upp"] path = upp url = https://github.com/NOAA-EMC/UPP From 3a3253a4c94bc66a8b325fe7a384d5d4673d147c Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Thu, 12 Jan 2023 10:47:34 -0700 Subject: [PATCH 02/25] more work for fully coupled atm+lnd --- atmos_model.F90 | 144 ++++++++++++++++++++++++++- ccpp/config/ccpp_prebuild_config.py | 1 + ccpp/data/GFS_typedefs.F90 | 37 ++++++- ccpp/data/GFS_typedefs.meta | 62 ++++++++++++ ccpp/physics | 2 +- ccpp/suites/suite_FV3_GFS_v17_p8.xml | 1 + cpl/module_cplfields.F90 | 12 ++- 7 files changed, 252 insertions(+), 7 deletions(-) diff --git a/atmos_model.F90 b/atmos_model.F90 index 81a5272c3..fbcb8bc77 100644 --- a/atmos_model.F90 +++ b/atmos_model.F90 @@ -175,8 +175,8 @@ module atmos_model_mod integer :: blocksize = 1 logical :: chksum_debug = .false. logical :: dycore_only = .false. -logical :: debug = .false. -!logical :: debug = .true. +!logical :: debug = .false. +logical :: debug = .true. logical :: sync = .false. real :: avg_max_length=3600. logical :: ignore_rst_cksum = .false. @@ -2340,6 +2340,146 @@ subroutine assign_importdata(jdat, rc) endif endif +! get surface snow area fraction: over land (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'mean_snow_area_fraction_lnd' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%sncovr1_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get snow_area_fraction for land' + endif + endif + +! get latent heat flux: over land (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'mean_laten_heat_flx_lnd' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%evap_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get laten_heat for land' + endif + endif + +! get sensible heat flux: over land (if cpllnd=true and cpllnd2atm=true) +!-------------------------------------------------- + fldname = 'mean_sensi_heat_flx_lnd' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%hflx_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get sensi_heat for land' + endif + endif + +! get surface upward potential latent heat flux: over land (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'mean_potential_laten_heat_flx_lnd' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%ep_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get potential_laten_heat_flx for land' + endif + endif + +! get 2m air temperature: over land (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'inst_temp_height2m_lnd' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%t2mmp_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get temp_height2m for land' + endif + endif + +! get 2m specific humidity: over land (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'inst_spec_humid_height2m_lnd' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%q2mp_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get spec_humid_height2m for land' + endif + endif + +! get specific humidity: over land (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'inst_spec_humid_lnd' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%qsurf_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get spec_humid for land' + endif + endif + endif ! if (datar8(isc,jsc) > -99999.0) then !------------------------------------------------------- diff --git a/ccpp/config/ccpp_prebuild_config.py b/ccpp/config/ccpp_prebuild_config.py index 2d848c1eb..998d6acd5 100755 --- a/ccpp/config/ccpp_prebuild_config.py +++ b/ccpp/config/ccpp_prebuild_config.py @@ -202,6 +202,7 @@ 'physics/physics/sfc_diag_post.F90', 'physics/physics/lsm_ruc.F90', 'physics/physics/sfc_cice.f', + 'physics/physics/sfc_land.f', 'physics/physics/sfc_diff.f', 'physics/physics/lsm_noah.f', 'physics/physics/noahmpdrv.F90', diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index fdbeddb9b..e6ef89fce 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -466,6 +466,14 @@ module GFS_typedefs real (kind=kind_phys), pointer :: dtsfcin_med(:) => null() !< sfc latent heat flux over ocean real (kind=kind_phys), pointer :: dqsfcin_med(:) => null() !< sfc sensible heat flux over ocean real (kind=kind_phys), pointer :: ulwsfcin_med(:) => null() !< sfc upward lw flux over ocean + !--- variables needed for cpllnd = .TRUE. and cpllnd2atm=.TRUE. + real (kind=kind_phys), pointer :: sncovr1_lnd(:) => null() !< sfc snow area fraction over land + real (kind=kind_phys), pointer :: qsurf_lnd(:) => null() !< sfc specific humidity + real (kind=kind_phys), pointer :: evap_lnd(:) => null() !< sfc latent heat flux over land + real (kind=kind_phys), pointer :: hflx_lnd(:) => null() !< sfc sensible heat flux over land + real (kind=kind_phys), pointer :: ep_lnd(:) => null() !< sfc up pot latent heat flux over land + real (kind=kind_phys), pointer :: t2mmp_lnd(:) => null() !< 2 meter temperature over land + real (kind=kind_phys), pointer :: q2mp_lnd(:) => null() !< 2 meter spec humidity over land !--- outgoing accumulated quantities real (kind=kind_phys), pointer :: rain_cpl (:) => null() !< total rain precipitation @@ -675,6 +683,7 @@ module GFS_typedefs logical :: cplaqm !< default no cplaqm collection logical :: cplchm !< default no cplchm collection logical :: cpllnd !< default no cpllnd collection + logical :: cpllnd2atm !< default no lnd->atm coupling logical :: rrfs_smoke !< default no rrfs_smoke collection integer :: dust_smoke_rrtmg_band_number !< band number to affect in rrtmg_pre from smoke and dust logical :: use_cice_alb !< default .false. - i.e. don't use albedo imported from the ice model @@ -2691,7 +2700,26 @@ subroutine coupling_create (Coupling, IM, Model) Coupling%slmsk_cpl = clear_val !< pointer to sfcprop%slmsk endif - !-- cellular automata + ! -- Coupling options to retrive land fluxes from external land component + if (Model%cpllnd .and. Model%cpllnd2atm) then + allocate (Coupling%sncovr1_lnd (IM)) + allocate (Coupling%qsurf_lnd (IM)) + allocate (Coupling%evap_lnd (IM)) + allocate (Coupling%hflx_lnd (IM)) + allocate (Coupling%ep_lnd (IM)) + allocate (Coupling%t2mmp_lnd (IM)) + allocate (Coupling%q2mp_lnd (IM)) + + Coupling%sncovr1_lnd = clear_val + Coupling%qsurf_lnd = clear_val + Coupling%evap_lnd = clear_val + Coupling%hflx_lnd = clear_val + Coupling%ep_lnd = clear_val + Coupling%t2mmp_lnd = clear_val + Coupling%q2mp_lnd = clear_val + end if + + !-- cellular automata allocate (Coupling%condition(IM)) if (Model%do_ca) then allocate (Coupling%ca1 (IM)) @@ -2940,6 +2968,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & logical :: cplaqm = .false. !< default no cplaqm collection logical :: cplchm = .false. !< default no cplchm collection logical :: cpllnd = .false. !< default no cpllnd collection + logical :: cpllnd2atm = .false. !< default no cpllnd2atm coupling logical :: rrfs_smoke = .false. !< default no rrfs_smoke collection integer :: dust_smoke_rrtmg_band_number = 10!< band number to affect in rrtmg_pre from smoke and dust logical :: use_cice_alb = .false. !< default no cice albedo @@ -3468,8 +3497,8 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & thermodyn_id, sfcpress_id, & !--- coupling parameters cplflx, cplice, cplocn2atm, cplwav, cplwav2atm, cplaqm, & - cplchm, cpllnd, cpl_imp_mrg, cpl_imp_dbg, rrfs_smoke, & - use_cice_alb, dust_smoke_rrtmg_band_number, & + cplchm, cpllnd, cpllnd2atm, cpl_imp_mrg, cpl_imp_dbg, & + rrfs_smoke, use_cice_alb, dust_smoke_rrtmg_band_number, & #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, & @@ -3791,6 +3820,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & Model%cplaqm = cplaqm Model%cplchm = cplchm .or. cplaqm Model%cpllnd = cpllnd + Model%cpllnd2atm = cpllnd2atm Model%use_cice_alb = use_cice_alb Model%cpl_imp_mrg = cpl_imp_mrg Model%cpl_imp_dbg = cpl_imp_dbg @@ -5726,6 +5756,7 @@ subroutine control_print(Model) print *, ' cplaqm : ', Model%cplaqm print *, ' cplchm : ', Model%cplchm print *, ' cpllnd : ', Model%cpllnd + print *, ' cpllnd2atm : ', Model%cpllnd2atm print *, ' rrfs_smoke : ', Model%rrfs_smoke print *, ' use_cice_alb : ', Model%use_cice_alb print *, ' cpl_imp_mrg : ', Model%cpl_imp_mrg diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index 38be8e94e..ad057ca46 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -2370,6 +2370,62 @@ type = real kind = kind_phys active = (flag_for_surface_flux_coupling .and. do_mediator_atmosphere_ocean_fluxes) +[sncovr1_lnd] + standard_name = surface_snow_area_fraction_over_land_from_land + long_name = surface snow area fraction over land for coupling + units = frac + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[qsurf_lnd] + standard_name = surface_specific_humidity_over_land_from_land + long_name = surface air saturation specific humidity over land + units = kg kg-1 + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[hflx_lnd] + standard_name = surface_upward_sensible_heat_flux_over_land_from_land + long_name = sfc sensible heat flux input over land for coupling + units = K m s-1 + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[evap_lnd] + standard_name = surface_upward_latent_heat_flux_over_land_from_land + long_name = sfc latent heat flux input over land for coupling + units = kg kg-1 m s-1 + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[ep_lnd] + standard_name = surface_upward_potential_latent_heat_flux_over_land_from_land + long_name = surface upward potential latent heat flux over land for coupling + units = W m-2 + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[t2mmp_lnd] + standard_name = temperature_at_2m_over_land_from_land + long_name = 2 meter temperature over land for coupling + units = K + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[q2mp_lnd] + standard_name = specific_humidity_at_2m_over_land_from_land + long_name = 2 meter specific humidity over land for coupling + units = kg kg-1 + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) [hsnoin_cpl] standard_name = lwe_surface_snow_from_coupled_process long_name = sfc snow depth in meters over sea ice for coupling @@ -3010,6 +3066,12 @@ units = flag dimensions = () type = logical +[cpllnd2atm] + standard_name = flag_for_one_way_land_coupling_to_atmosphere + long_name = flag controlling land coupling to the atmosphere (default off) + units = flag + dimensions = () + type = logical [rrfs_smoke] standard_name = do_smoke_coupling long_name = flag controlling rrfs_smoke collection (default off) diff --git a/ccpp/physics b/ccpp/physics index 688c7715a..d2900143f 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 688c7715a026b1faeba8fc2350ddcd7a51b3cabf +Subproject commit d2900143f7de8c3fe79e8135a0bab5f3267267b9 diff --git a/ccpp/suites/suite_FV3_GFS_v17_p8.xml b/ccpp/suites/suite_FV3_GFS_v17_p8.xml index c4b295a6d..2362d6d84 100644 --- a/ccpp/suites/suite_FV3_GFS_v17_p8.xml +++ b/ccpp/suites/suite_FV3_GFS_v17_p8.xml @@ -44,6 +44,7 @@ sfc_nst sfc_nst_post noahmpdrv + sfc_land sfc_sice GFS_surface_loop_control_part2 diff --git a/cpl/module_cplfields.F90 b/cpl/module_cplfields.F90 index 56eb372ad..8ccbe808e 100644 --- a/cpl/module_cplfields.F90 +++ b/cpl/module_cplfields.F90 @@ -156,7 +156,7 @@ module module_cplfields FieldInfo("t2m ", "s") ] ! Import Fields ---------------------------------------- - integer, public, parameter :: NimportFields = 48 + integer, public, parameter :: NimportFields = 56 logical, public :: importFieldsValid(NimportFields) type(ESMF_Field), target, public :: importFields(NimportFields) @@ -187,6 +187,16 @@ module module_cplfields FieldInfo("mean_sensi_heat_flx_atm_into_ocn ", "s"), & FieldInfo("mean_up_lw_flx_ocn ", "s"), & + ! For receiving fluxes from external land component + FieldInfo("land_fraction ", "s"), & + FieldInfo("mean_snow_area_fraction_lnd ", "s"), & + FieldInfo("inst_spec_humid_lnd ", "s"), & + FieldInfo("mean_laten_heat_flx_lnd ", "s"), & + FieldInfo("mean_sensi_heat_flx_lnd ", "s"), & + FieldInfo("mean_potential_laten_heat_flx_lnd ", "s"), & + FieldInfo("inst_temp_height2m_lnd ", "s"), & + FieldInfo("inst_spec_humid_height2m_lnd ", "s"), & + ! For JEDI ! dynamics FieldInfo("u ", "l"), & From 474702916f80aa1e6ff3581174d9a35c67d53347 Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Tue, 7 Feb 2023 15:16:38 -0700 Subject: [PATCH 03/25] add gflux --- atmos_model.F90 | 21 +++++++++++++++++++++ ccpp/data/GFS_typedefs.F90 | 3 +++ ccpp/data/GFS_typedefs.meta | 8 ++++++++ cpl/module_cplfields.F90 | 3 ++- 4 files changed, 34 insertions(+), 1 deletion(-) diff --git a/atmos_model.F90 b/atmos_model.F90 index fbcb8bc77..9e5528a72 100644 --- a/atmos_model.F90 +++ b/atmos_model.F90 @@ -2480,6 +2480,27 @@ subroutine assign_importdata(jdat, rc) endif endif +! get upward heat flux in soil (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'mean_upward_heat_flux_lnd' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%gflux_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get spec_humid for land' + endif + endif + + endif ! if (datar8(isc,jsc) > -99999.0) then !------------------------------------------------------- diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index e6ef89fce..7c6c6bdcc 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -474,6 +474,7 @@ module GFS_typedefs real (kind=kind_phys), pointer :: ep_lnd(:) => null() !< sfc up pot latent heat flux over land real (kind=kind_phys), pointer :: t2mmp_lnd(:) => null() !< 2 meter temperature over land real (kind=kind_phys), pointer :: q2mp_lnd(:) => null() !< 2 meter spec humidity over land + real (kind=kind_phys), pointer :: gflux_lnd(:) => null() !< soil heat flux over land !--- outgoing accumulated quantities real (kind=kind_phys), pointer :: rain_cpl (:) => null() !< total rain precipitation @@ -2709,6 +2710,7 @@ subroutine coupling_create (Coupling, IM, Model) allocate (Coupling%ep_lnd (IM)) allocate (Coupling%t2mmp_lnd (IM)) allocate (Coupling%q2mp_lnd (IM)) + allocate (Coupling%gflux_lnd (IM)) Coupling%sncovr1_lnd = clear_val Coupling%qsurf_lnd = clear_val @@ -2717,6 +2719,7 @@ subroutine coupling_create (Coupling, IM, Model) Coupling%ep_lnd = clear_val Coupling%t2mmp_lnd = clear_val Coupling%q2mp_lnd = clear_val + Coupling%gflux_lnd = clear_val end if !-- cellular automata diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index ad057ca46..227220d2b 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -2426,6 +2426,14 @@ type = real kind = kind_phys active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[gflux_lnd] + standard_name = upward_heat_flux_in_soil_over_land_from_land + long_name = soil heat flux over land for coupling + units = W m-2 + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) [hsnoin_cpl] standard_name = lwe_surface_snow_from_coupled_process long_name = sfc snow depth in meters over sea ice for coupling diff --git a/cpl/module_cplfields.F90 b/cpl/module_cplfields.F90 index 8ccbe808e..4c3ef8011 100644 --- a/cpl/module_cplfields.F90 +++ b/cpl/module_cplfields.F90 @@ -156,7 +156,7 @@ module module_cplfields FieldInfo("t2m ", "s") ] ! Import Fields ---------------------------------------- - integer, public, parameter :: NimportFields = 56 + integer, public, parameter :: NimportFields = 57 logical, public :: importFieldsValid(NimportFields) type(ESMF_Field), target, public :: importFields(NimportFields) @@ -196,6 +196,7 @@ module module_cplfields FieldInfo("mean_potential_laten_heat_flx_lnd ", "s"), & FieldInfo("inst_temp_height2m_lnd ", "s"), & FieldInfo("inst_spec_humid_height2m_lnd ", "s"), & + FieldInfo("mean_upward_heat_flux_lnd ", "s"), & ! For JEDI ! dynamics From 0b36923ec7769c10bbd5c20c990c24bb6a027e30 Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Tue, 7 Feb 2023 15:22:19 -0700 Subject: [PATCH 04/25] update components --- atmos_cubed_sphere | 2 +- ccpp/framework | 2 +- ccpp/physics | 2 +- upp | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/atmos_cubed_sphere b/atmos_cubed_sphere index a839395d5..3f7b57a28 160000 --- a/atmos_cubed_sphere +++ b/atmos_cubed_sphere @@ -1 +1 @@ -Subproject commit a839395d542ab860ae0afa7601e35b37d68d773e +Subproject commit 3f7b57a28b334c7f2485b26c29f1d5b9f3c1cd7d diff --git a/ccpp/framework b/ccpp/framework index 4daaa246d..1b6352fb2 160000 --- a/ccpp/framework +++ b/ccpp/framework @@ -1 +1 @@ -Subproject commit 4daaa246d1a3bce8eca60d314eeef44332f47e26 +Subproject commit 1b6352fb24f053b738bde72eed0ddf0b60ec7c0f diff --git a/ccpp/physics b/ccpp/physics index d2900143f..079e47a1d 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit d2900143f7de8c3fe79e8135a0bab5f3267267b9 +Subproject commit 079e47a1d885c5da80eb4c282b110ec058e3fce0 diff --git a/upp b/upp index e22724738..2b2c84a60 160000 --- a/upp +++ b/upp @@ -1 +1 @@ -Subproject commit e22724738fd104327fee7c3c7ffc805ccabd619f +Subproject commit 2b2c84a609f575fc293a4f90238391681bc383f0 From 54f6d287b31564885af1c1a577d4bcd970325b94 Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Thu, 23 Feb 2023 14:29:25 -0700 Subject: [PATCH 05/25] add runoff and drain to land coupling --- atmos_model.F90 | 40 +++++++++++++++++++++++++++++++++++++ ccpp/data/GFS_typedefs.F90 | 8 +++++++- ccpp/data/GFS_typedefs.meta | 16 +++++++++++++++ ccpp/physics | 2 +- cpl/module_cplfields.F90 | 4 +++- 5 files changed, 67 insertions(+), 3 deletions(-) diff --git a/atmos_model.F90 b/atmos_model.F90 index 70927d680..7f2597bb6 100644 --- a/atmos_model.F90 +++ b/atmos_model.F90 @@ -2498,6 +2498,46 @@ subroutine assign_importdata(jdat, rc) endif endif +! get surface runoff in soil (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'mean_runoff_rate_lnd' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%runoff_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get spec_humid for land' + endif + endif + +! get subsurface runoff in soil (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'mean_subsurface_runoff_rate_lnd' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%drain_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get spec_humid for land' + endif + endif + endif ! if (datar8(isc,jsc) > -99999.0) then diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index d72cc5513..833bffc97 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -474,7 +474,9 @@ module GFS_typedefs real (kind=kind_phys), pointer :: ep_lnd(:) => null() !< sfc up pot latent heat flux over land real (kind=kind_phys), pointer :: t2mmp_lnd(:) => null() !< 2 meter temperature over land real (kind=kind_phys), pointer :: q2mp_lnd(:) => null() !< 2 meter spec humidity over land - real (kind=kind_phys), pointer :: gflux_lnd(:) => null() !< soil heat flux over land + real (kind=kind_phys), pointer :: gflux_lnd(:) => null() !< soil heat flux over land + real (kind=kind_phys), pointer :: runoff_lnd(:) => null() !< surface runoff over land + real (kind=kind_phys), pointer :: drain_lnd(:) => null() !< subsurface runoff over land !--- outgoing accumulated quantities real (kind=kind_phys), pointer :: rain_cpl (:) => null() !< total rain precipitation @@ -2721,6 +2723,8 @@ subroutine coupling_create (Coupling, IM, Model) allocate (Coupling%t2mmp_lnd (IM)) allocate (Coupling%q2mp_lnd (IM)) allocate (Coupling%gflux_lnd (IM)) + allocate (Coupling%runoff_lnd (IM)) + allocate (Coupling%drain_lnd (IM)) Coupling%sncovr1_lnd = clear_val Coupling%qsurf_lnd = clear_val @@ -2730,6 +2734,8 @@ subroutine coupling_create (Coupling, IM, Model) Coupling%t2mmp_lnd = clear_val Coupling%q2mp_lnd = clear_val Coupling%gflux_lnd = clear_val + Coupling%runoff_lnd = clear_val + Coupling%drain_lnd = clear_val end if !-- cellular automata diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index 195980810..5b45bce0b 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -2434,6 +2434,22 @@ type = real kind = kind_phys active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[runoff_lnd] + standard_name = surface_runoff_flux_from_land + long_name = surface runoff flux over land for coupling + units = kg m-2 s-1 + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[drain_lnd] + standard_name = subsurface_runoff_flux_from_land + long_name = subsurface runoff flux over land for coupling + units = kg m-2 s-1 + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) [hsnoin_cpl] standard_name = lwe_surface_snow_from_coupled_process long_name = sfc snow depth in meters over sea ice for coupling diff --git a/ccpp/physics b/ccpp/physics index 079e47a1d..40e092d0d 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 079e47a1d885c5da80eb4c282b110ec058e3fce0 +Subproject commit 40e092d0d92d0c78848acc47ae83629908375a6c diff --git a/cpl/module_cplfields.F90 b/cpl/module_cplfields.F90 index 4c3ef8011..e7efd21c7 100644 --- a/cpl/module_cplfields.F90 +++ b/cpl/module_cplfields.F90 @@ -156,7 +156,7 @@ module module_cplfields FieldInfo("t2m ", "s") ] ! Import Fields ---------------------------------------- - integer, public, parameter :: NimportFields = 57 + integer, public, parameter :: NimportFields = 59 logical, public :: importFieldsValid(NimportFields) type(ESMF_Field), target, public :: importFields(NimportFields) @@ -197,6 +197,8 @@ module module_cplfields FieldInfo("inst_temp_height2m_lnd ", "s"), & FieldInfo("inst_spec_humid_height2m_lnd ", "s"), & FieldInfo("mean_upward_heat_flux_lnd ", "s"), & + FieldInfo("mean_runoff_rate_lnd ", "s"), & + FieldInfo("mean_subsurface_runoff_rate_lnd ", "s"), & ! For JEDI ! dynamics From c513865244a8e8934f1c788a7b4e994412513afa Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Tue, 7 Mar 2023 11:00:57 -0700 Subject: [PATCH 06/25] add exchange coefficents --- atmos_model.F90 | 59 ++++++++++++++++++++++++++++++------- ccpp/data/GFS_typedefs.F90 | 6 ++++ ccpp/data/GFS_typedefs.meta | 16 ++++++++++ ccpp/physics | 2 +- cpl/module_cplfields.F90 | 4 ++- 5 files changed, 75 insertions(+), 12 deletions(-) diff --git a/atmos_model.F90 b/atmos_model.F90 index 7f2597bb6..37a32cede 100644 --- a/atmos_model.F90 +++ b/atmos_model.F90 @@ -2354,7 +2354,7 @@ subroutine assign_importdata(jdat, rc) endif enddo enddo - if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get snow_area_fraction for land' + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get snow area fraction from land' endif endif @@ -2374,7 +2374,7 @@ subroutine assign_importdata(jdat, rc) endif enddo enddo - if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get laten_heat for land' + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get latent heat flux from land' endif endif @@ -2394,7 +2394,7 @@ subroutine assign_importdata(jdat, rc) endif enddo enddo - if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get sensi_heat for land' + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get sensible heat flux from land' endif endif @@ -2414,7 +2414,7 @@ subroutine assign_importdata(jdat, rc) endif enddo enddo - if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get potential_laten_heat_flx for land' + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get potential latent heat flux from land' endif endif @@ -2434,7 +2434,7 @@ subroutine assign_importdata(jdat, rc) endif enddo enddo - if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get temp_height2m for land' + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get temperature at 2m from land' endif endif @@ -2454,7 +2454,7 @@ subroutine assign_importdata(jdat, rc) endif enddo enddo - if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get spec_humid_height2m for land' + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get specific humidity at 2m from land' endif endif @@ -2474,7 +2474,7 @@ subroutine assign_importdata(jdat, rc) endif enddo enddo - if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get spec_humid for land' + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get specific humidity from land' endif endif @@ -2494,7 +2494,7 @@ subroutine assign_importdata(jdat, rc) endif enddo enddo - if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get spec_humid for land' + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get upward heat flux from land' endif endif @@ -2514,7 +2514,7 @@ subroutine assign_importdata(jdat, rc) endif enddo enddo - if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get spec_humid for land' + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get surface runoff from land' endif endif @@ -2534,10 +2534,49 @@ subroutine assign_importdata(jdat, rc) endif enddo enddo - if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get spec_humid for land' + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get subsurface runoff from land' endif endif +! get momentum exchange coefficient (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'inst_drag_wind_speed_for_momentum' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%cmm_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get drag wind speed for momentum from land' + endif + endif + +! get thermal exchange coefficient (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'inst_drag_mass_flux_for_heat_and_moisture' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%chh_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get thermal exchange coefficient form land' + endif + endif endif ! if (datar8(isc,jsc) > -99999.0) then diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index 833bffc97..66044a006 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -477,6 +477,8 @@ module GFS_typedefs real (kind=kind_phys), pointer :: gflux_lnd(:) => null() !< soil heat flux over land real (kind=kind_phys), pointer :: runoff_lnd(:) => null() !< surface runoff over land real (kind=kind_phys), pointer :: drain_lnd(:) => null() !< subsurface runoff over land + real (kind=kind_phys), pointer :: cmm_lnd(:) => null() !< surface drag wind speed for momentum + real (kind=kind_phys), pointer :: chh_lnd(:) => null() !< surface drag mass flux for heat and moisture !--- outgoing accumulated quantities real (kind=kind_phys), pointer :: rain_cpl (:) => null() !< total rain precipitation @@ -2725,6 +2727,8 @@ subroutine coupling_create (Coupling, IM, Model) allocate (Coupling%gflux_lnd (IM)) allocate (Coupling%runoff_lnd (IM)) allocate (Coupling%drain_lnd (IM)) + allocate (Coupling%cmm_lnd (IM)) + allocate (Coupling%chh_lnd (IM)) Coupling%sncovr1_lnd = clear_val Coupling%qsurf_lnd = clear_val @@ -2736,6 +2740,8 @@ subroutine coupling_create (Coupling, IM, Model) Coupling%gflux_lnd = clear_val Coupling%runoff_lnd = clear_val Coupling%drain_lnd = clear_val + Coupling%cmm_lnd = clear_val + Coupling%chh_lnd = clear_val end if !-- cellular automata diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index 5b45bce0b..73bf3432c 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -2450,6 +2450,22 @@ type = real kind = kind_phys active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[cmm_lnd] + standard_name = surface_drag_wind_speed_for_momentum_in_air_over_land_from_land + long_name = momentum exchange coefficient over land for coupling + units = m s-1 + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[chh_lnd] + standard_name = surface_drag_mass_flux_for_heat_and_moisture_in_air_over_land_from_land + long_name = thermal exchange coefficient over land for coupling + units = kg m-2 s-1 + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) [hsnoin_cpl] standard_name = lwe_surface_snow_from_coupled_process long_name = sfc snow depth in meters over sea ice for coupling diff --git a/ccpp/physics b/ccpp/physics index 40e092d0d..64fdd5aa5 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 40e092d0d92d0c78848acc47ae83629908375a6c +Subproject commit 64fdd5aa53672132bf1295701a9d7844232f336b diff --git a/cpl/module_cplfields.F90 b/cpl/module_cplfields.F90 index e7efd21c7..bb8931e21 100644 --- a/cpl/module_cplfields.F90 +++ b/cpl/module_cplfields.F90 @@ -156,7 +156,7 @@ module module_cplfields FieldInfo("t2m ", "s") ] ! Import Fields ---------------------------------------- - integer, public, parameter :: NimportFields = 59 + integer, public, parameter :: NimportFields = 61 logical, public :: importFieldsValid(NimportFields) type(ESMF_Field), target, public :: importFields(NimportFields) @@ -199,6 +199,8 @@ module module_cplfields FieldInfo("mean_upward_heat_flux_lnd ", "s"), & FieldInfo("mean_runoff_rate_lnd ", "s"), & FieldInfo("mean_subsurface_runoff_rate_lnd ", "s"), & + FieldInfo("inst_drag_wind_speed_for_momentum ", "s"), & + FieldInfo("inst_drag_mass_flux_for_heat_and_moisture", "s"), & ! For JEDI ! dynamics From e9540ec7891a938d8c35e4bc5d8a13f1ead5a227 Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Tue, 7 Mar 2023 22:41:46 -0700 Subject: [PATCH 07/25] add zvfun to land coupling --- atmos_model.F90 | 20 ++++++++++++++++++++ ccpp/data/GFS_typedefs.F90 | 3 +++ ccpp/data/GFS_typedefs.meta | 8 ++++++++ ccpp/physics | 2 +- cpl/module_cplfields.F90 | 3 ++- 5 files changed, 34 insertions(+), 2 deletions(-) diff --git a/atmos_model.F90 b/atmos_model.F90 index 37a32cede..3363a0546 100644 --- a/atmos_model.F90 +++ b/atmos_model.F90 @@ -2578,6 +2578,26 @@ subroutine assign_importdata(jdat, rc) endif endif +! get function of surface roughness length and green vegetation fraction (if cpllnd=true and cpllnd2atm=true) +!------------------------------------------------ + fldname = 'inst_func_of_roughness_length_and_vfrac' + if (trim(impfield_name) == trim(fldname)) then + findex = queryImportFields(fldname) + if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then +!$omp parallel do default(shared) private(i,j,nb,ix) + do j=jsc,jec + do i=isc,iec + nb = Atm_block%blkno(i,j) + ix = Atm_block%ixp(i,j) + if (GFS_data(nb)%Sfcprop%landfrac(ix) > zero) then + GFS_data(nb)%Coupling%zvfun_lnd(ix) = datar8(i,j) + endif + enddo + enddo + if (mpp_pe() == mpp_root_pe() .and. debug) print *,'fv3 assign_import: get func. of roughness length and vfrac form land' + endif + endif + endif ! if (datar8(isc,jsc) > -99999.0) then !------------------------------------------------------- diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index 66044a006..638ea9adb 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -479,6 +479,7 @@ module GFS_typedefs real (kind=kind_phys), pointer :: drain_lnd(:) => null() !< subsurface runoff over land real (kind=kind_phys), pointer :: cmm_lnd(:) => null() !< surface drag wind speed for momentum real (kind=kind_phys), pointer :: chh_lnd(:) => null() !< surface drag mass flux for heat and moisture + real (kind=kind_phys), pointer :: zvfun_lnd(:) => null() !< function of surface roughness length and green vegetation fraction !--- outgoing accumulated quantities real (kind=kind_phys), pointer :: rain_cpl (:) => null() !< total rain precipitation @@ -2729,6 +2730,7 @@ subroutine coupling_create (Coupling, IM, Model) allocate (Coupling%drain_lnd (IM)) allocate (Coupling%cmm_lnd (IM)) allocate (Coupling%chh_lnd (IM)) + allocate (Coupling%zvfun_lnd (IM)) Coupling%sncovr1_lnd = clear_val Coupling%qsurf_lnd = clear_val @@ -2742,6 +2744,7 @@ subroutine coupling_create (Coupling, IM, Model) Coupling%drain_lnd = clear_val Coupling%cmm_lnd = clear_val Coupling%chh_lnd = clear_val + Coupling%zvfun_lnd = clear_val end if !-- cellular automata diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index 73bf3432c..7cdfca8f2 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -2466,6 +2466,14 @@ type = real kind = kind_phys active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) +[zvfun_lnd] + standard_name = function_of_surface_roughness_length_and_green_vegetation_fraction_from_land + long_name = function of surface roughness length and green vegetation fraction + units = none + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (flag_for_land_coupling .and. flag_for_one_way_land_coupling_to_atmosphere) [hsnoin_cpl] standard_name = lwe_surface_snow_from_coupled_process long_name = sfc snow depth in meters over sea ice for coupling diff --git a/ccpp/physics b/ccpp/physics index 64fdd5aa5..91a9b44ea 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 64fdd5aa53672132bf1295701a9d7844232f336b +Subproject commit 91a9b44eac42dfaf047cfc79718fa0332db0979d diff --git a/cpl/module_cplfields.F90 b/cpl/module_cplfields.F90 index bb8931e21..90e3a6ea4 100644 --- a/cpl/module_cplfields.F90 +++ b/cpl/module_cplfields.F90 @@ -156,7 +156,7 @@ module module_cplfields FieldInfo("t2m ", "s") ] ! Import Fields ---------------------------------------- - integer, public, parameter :: NimportFields = 61 + integer, public, parameter :: NimportFields = 62 logical, public :: importFieldsValid(NimportFields) type(ESMF_Field), target, public :: importFields(NimportFields) @@ -201,6 +201,7 @@ module module_cplfields FieldInfo("mean_subsurface_runoff_rate_lnd ", "s"), & FieldInfo("inst_drag_wind_speed_for_momentum ", "s"), & FieldInfo("inst_drag_mass_flux_for_heat_and_moisture", "s"), & + FieldInfo("inst_func_of_roughness_length_and_vfrac ", "s"), & ! For JEDI ! dynamics From 8a358f8775c665fb7b25789f1571e035505047f4 Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Thu, 6 Apr 2023 13:29:03 -0600 Subject: [PATCH 08/25] minor fix in GFS type definitions --- ccpp/data/GFS_typedefs.F90 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index 6c968f90e..8ca590f42 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -3698,7 +3698,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & !--- coupling parameters cplflx, cplice, cplocn2atm, cplwav, cplwav2atm, cplaqm, & cplchm, cpllnd, cpllnd2atm, cpl_imp_mrg, cpl_imp_dbg, & - rrfs_sd, use_cice_alb, + rrfs_sd, 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, & From a0332ea43caf9e32e3a9b5ee60eab43cf27e5d97 Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Tue, 25 Jul 2023 11:23:36 -0600 Subject: [PATCH 09/25] sync component --- atmos_cubed_sphere | 2 +- ccpp/physics | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/atmos_cubed_sphere b/atmos_cubed_sphere index 9d5bed8e9..49f15ecbb 160000 --- a/atmos_cubed_sphere +++ b/atmos_cubed_sphere @@ -1 +1 @@ -Subproject commit 9d5bed8e932a188d714c8c8a770e44801dab4750 +Subproject commit 49f15ecbbc16405025fae8d672dced19c2073d9e diff --git a/ccpp/physics b/ccpp/physics index 87bd714dc..1afb8fc3d 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 87bd714dc74dca061b1a70e8c96dba44284a7ac1 +Subproject commit 1afb8fc3d4b1a52041c80bccdc3f73b5153f9509 From 3d9e3565177be38bb3e1cd50f10741dc77d657c2 Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Mon, 31 Jul 2023 11:50:45 -0600 Subject: [PATCH 10/25] update ccpp physics --- ccpp/physics | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index 1afb8fc3d..70038f6f5 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 1afb8fc3d4b1a52041c80bccdc3f73b5153f9509 +Subproject commit 70038f6f5f70572f09489732e3563f1d11066a1f From ff581ddd5753aade280f413e4e4c3a1c654a4e6c Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Mon, 31 Jul 2023 16:22:15 -0600 Subject: [PATCH 11/25] update sfc_land --- ccpp/config/ccpp_prebuild_config.py | 2 +- ccpp/physics | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ccpp/config/ccpp_prebuild_config.py b/ccpp/config/ccpp_prebuild_config.py index 1961ff70b..8dd53524f 100755 --- a/ccpp/config/ccpp_prebuild_config.py +++ b/ccpp/config/ccpp_prebuild_config.py @@ -179,7 +179,7 @@ 'physics/physics/sfc_diag_post.F90', 'physics/physics/lsm_ruc.F90', 'physics/physics/sfc_cice.f', - 'physics/physics/sfc_land.f', + 'physics/physics/sfc_land.F90', 'physics/physics/sfc_diff.f', 'physics/physics/lsm_noah.f', 'physics/physics/noahmpdrv.F90', diff --git a/ccpp/physics b/ccpp/physics index 70038f6f5..6ec72e918 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 70038f6f5f70572f09489732e3563f1d11066a1f +Subproject commit 6ec72e918d2f2d04f78a9afaf5b58968370a44a4 From 2818486748dd172821af0b70dcef37bac3dcb433 Mon Sep 17 00:00:00 2001 From: Ufuk Turuncoglu Date: Thu, 10 Aug 2023 10:51:17 -0500 Subject: [PATCH 12/25] update description of the field --- ccpp/data/GFS_typedefs.F90 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index edfbf3a7a..1f7944723 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -544,7 +544,7 @@ module GFS_typedefs !--- variables needed for cpllnd = .TRUE. and cpllnd2atm=.TRUE. real (kind=kind_phys), pointer :: sncovr1_lnd(:) => null() !< sfc snow area fraction over land real (kind=kind_phys), pointer :: qsurf_lnd(:) => null() !< sfc specific humidity - real (kind=kind_phys), pointer :: evap_lnd(:) => null() !< sfc latent heat flux over land + real (kind=kind_phys), pointer :: evap_lnd(:) => null() !< sfc latent heat flux over land, converted to evaporative flux real (kind=kind_phys), pointer :: hflx_lnd(:) => null() !< sfc sensible heat flux over land real (kind=kind_phys), pointer :: ep_lnd(:) => null() !< sfc up pot latent heat flux over land real (kind=kind_phys), pointer :: t2mmp_lnd(:) => null() !< 2 meter temperature over land From 6700190ee8625a989b2a871a03f794350a7540fd Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Thu, 12 Oct 2023 00:14:42 -0600 Subject: [PATCH 13/25] sync subcomponents with upstream --- atmos_cubed_sphere | 2 +- ccpp/physics | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/atmos_cubed_sphere b/atmos_cubed_sphere index 52bf918c1..caba092f6 160000 --- a/atmos_cubed_sphere +++ b/atmos_cubed_sphere @@ -1 +1 @@ -Subproject commit 52bf918c194b7d906776447c6324bc75558133db +Subproject commit caba092f682c9713a485e782b8f9ba6480adaca2 diff --git a/ccpp/physics b/ccpp/physics index aaff49fb8..cd678c6cd 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit aaff49fb8b80f7e6a4c2109630fc0063d9a502d3 +Subproject commit cd678c6cdf36b52e3d484f0bd1824acb9d2e021d From 1d0c099cf8a69e8043d213a791aeca5b5ffdc3c4 Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Thu, 12 Oct 2023 15:56:57 -0600 Subject: [PATCH 14/25] remove Sa_ua and Sa_va from couling fields --- atmos_model.F90 | 6 ------ cpl/module_cplfields.F90 | 4 +--- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/atmos_model.F90 b/atmos_model.F90 index f87482573..b423d7d91 100644 --- a/atmos_model.F90 +++ b/atmos_model.F90 @@ -3332,12 +3332,6 @@ subroutine setup_exportdata(rc) ! bottom layer meridional wind (v) case('inst_merid_wind_height_lowest') call block_data_copy_or_fill(datar82d, DYCORE_data(nb)%coupling%v_bot, zeror8, Atm_block, nb, rc=localrc) - ! bottom layer zonal wind (u) from physics - case('inst_zonal_wind_height_lowest_from_phys') - call block_data_copy_or_fill(datar82d, GFS_data(nb)%Statein%ugrs, 1, zeror8, Atm_block, nb, rc=localrc) - ! bottom layer meridional wind (v) from physics - case('inst_merid_wind_height_lowest_from_phys') - call block_data_copy_or_fill(datar82d, GFS_data(nb)%Statein%vgrs, 1, zeror8, Atm_block, nb, rc=localrc) ! surface friction velocity case('surface_friction_velocity') call block_data_copy_or_fill(datar82d, GFS_data(nb)%Sfcprop%uustar, zeror8, Atm_block, nb, rc=localrc) diff --git a/cpl/module_cplfields.F90 b/cpl/module_cplfields.F90 index 3bbaffa1b..e6a12a94a 100644 --- a/cpl/module_cplfields.F90 +++ b/cpl/module_cplfields.F90 @@ -26,7 +26,7 @@ module module_cplfields ! l : model levels (3D) ! s : surface (2D) ! t : tracers (4D) - integer, public, parameter :: NexportFields = 121 + integer, public, parameter :: NexportFields = 119 type(ESMF_Field), target, public :: exportFields(NexportFields) type(FieldInfo), dimension(NexportFields), public, parameter :: exportFieldsInfo = [ & @@ -118,8 +118,6 @@ module module_cplfields FieldInfo("leaf_area_index ", "s"), & FieldInfo("temperature_of_soil_layer ", "g"), & FieldInfo("height ", "s"), & - FieldInfo("inst_zonal_wind_height_lowest_from_phys ", "s"), & - FieldInfo("inst_merid_wind_height_lowest_from_phys ", "s"), & FieldInfo("inst_pres_height_lowest_from_phys ", "s"), & FieldInfo("inst_spec_humid_height_lowest_from_phys ", "s"), & FieldInfo("inst_prec_rate_conv ", "s"), & From ccd8ffde915211ae1f0ba084d1baa3c9d17635a6 Mon Sep 17 00:00:00 2001 From: Ufuk Turuncoglu Date: Mon, 8 Jan 2024 11:50:24 -0600 Subject: [PATCH 15/25] update ccpp/physics --- ccpp/physics | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index d75c657f1..36fc7d974 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit d75c657f14b78b676e5bfa84e62d879172a570c5 +Subproject commit 36fc7d9748741f6ce9cf46aaca13a171c11caf80 From 2d9e08f1f871a1387a0e4c7777e652474a9ad807 Mon Sep 17 00:00:00 2001 From: Ufuk Turuncoglu Date: Tue, 9 Jan 2024 10:38:29 -0600 Subject: [PATCH 16/25] fix prefix of snow area fraction standard name --- atmos_model.F90 | 2 +- cpl/module_cplfields.F90 | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/atmos_model.F90 b/atmos_model.F90 index 1eb739dc8..d3213e751 100644 --- a/atmos_model.F90 +++ b/atmos_model.F90 @@ -2351,7 +2351,7 @@ subroutine assign_importdata(jdat, rc) ! get surface snow area fraction: over land (if cpllnd=true and cpllnd2atm=true) !------------------------------------------------ - fldname = 'mean_snow_area_fraction_lnd' + fldname = 'inst_snow_area_fraction_lnd' if (trim(impfield_name) == trim(fldname)) then findex = queryImportFields(fldname) if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then diff --git a/cpl/module_cplfields.F90 b/cpl/module_cplfields.F90 index e6a12a94a..7aec1179b 100644 --- a/cpl/module_cplfields.F90 +++ b/cpl/module_cplfields.F90 @@ -189,7 +189,7 @@ module module_cplfields ! For receiving fluxes from external land component FieldInfo("land_fraction ", "s"), & - FieldInfo("mean_snow_area_fraction_lnd ", "s"), & + FieldInfo("inst_snow_area_fraction_lnd ", "s"), & FieldInfo("inst_spec_humid_lnd ", "s"), & FieldInfo("mean_laten_heat_flx_lnd ", "s"), & FieldInfo("mean_sensi_heat_flx_lnd ", "s"), & From f4cbc079d41d4c7933fec39c0f03ba8db2d14f9c Mon Sep 17 00:00:00 2001 From: Ufuk Turuncoglu Date: Tue, 9 Jan 2024 14:44:41 -0600 Subject: [PATCH 17/25] rename exchange fields to follow inst convention --- atmos_model.F90 | 12 ++++++------ cpl/module_cplfields.F90 | 12 ++++++------ 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/atmos_model.F90 b/atmos_model.F90 index d3213e751..7e19fee3d 100644 --- a/atmos_model.F90 +++ b/atmos_model.F90 @@ -2371,7 +2371,7 @@ subroutine assign_importdata(jdat, rc) ! get latent heat flux: over land (if cpllnd=true and cpllnd2atm=true) !------------------------------------------------ - fldname = 'mean_laten_heat_flx_lnd' + fldname = 'inst_laten_heat_flx_lnd' if (trim(impfield_name) == trim(fldname)) then findex = queryImportFields(fldname) if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then @@ -2391,7 +2391,7 @@ subroutine assign_importdata(jdat, rc) ! get sensible heat flux: over land (if cpllnd=true and cpllnd2atm=true) !-------------------------------------------------- - fldname = 'mean_sensi_heat_flx_lnd' + fldname = 'inst_sensi_heat_flx_lnd' if (trim(impfield_name) == trim(fldname)) then findex = queryImportFields(fldname) if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then @@ -2411,7 +2411,7 @@ subroutine assign_importdata(jdat, rc) ! get surface upward potential latent heat flux: over land (if cpllnd=true and cpllnd2atm=true) !------------------------------------------------ - fldname = 'mean_potential_laten_heat_flx_lnd' + fldname = 'inst_potential_laten_heat_flx_lnd' if (trim(impfield_name) == trim(fldname)) then findex = queryImportFields(fldname) if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then @@ -2491,7 +2491,7 @@ subroutine assign_importdata(jdat, rc) ! get upward heat flux in soil (if cpllnd=true and cpllnd2atm=true) !------------------------------------------------ - fldname = 'mean_upward_heat_flux_lnd' + fldname = 'inst_upward_heat_flux_lnd' if (trim(impfield_name) == trim(fldname)) then findex = queryImportFields(fldname) if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then @@ -2511,7 +2511,7 @@ subroutine assign_importdata(jdat, rc) ! get surface runoff in soil (if cpllnd=true and cpllnd2atm=true) !------------------------------------------------ - fldname = 'mean_runoff_rate_lnd' + fldname = 'inst_runoff_rate_lnd' if (trim(impfield_name) == trim(fldname)) then findex = queryImportFields(fldname) if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then @@ -2531,7 +2531,7 @@ subroutine assign_importdata(jdat, rc) ! get subsurface runoff in soil (if cpllnd=true and cpllnd2atm=true) !------------------------------------------------ - fldname = 'mean_subsurface_runoff_rate_lnd' + fldname = 'inst_subsurface_runoff_rate_lnd' if (trim(impfield_name) == trim(fldname)) then findex = queryImportFields(fldname) if (importFieldsValid(findex) .and. GFS_control%cpllnd .and. GFS_control%cpllnd2atm) then diff --git a/cpl/module_cplfields.F90 b/cpl/module_cplfields.F90 index 7aec1179b..58f31236f 100644 --- a/cpl/module_cplfields.F90 +++ b/cpl/module_cplfields.F90 @@ -191,14 +191,14 @@ module module_cplfields FieldInfo("land_fraction ", "s"), & FieldInfo("inst_snow_area_fraction_lnd ", "s"), & FieldInfo("inst_spec_humid_lnd ", "s"), & - FieldInfo("mean_laten_heat_flx_lnd ", "s"), & - FieldInfo("mean_sensi_heat_flx_lnd ", "s"), & - FieldInfo("mean_potential_laten_heat_flx_lnd ", "s"), & + FieldInfo("inst_laten_heat_flx_lnd ", "s"), & + FieldInfo("inst_sensi_heat_flx_lnd ", "s"), & + FieldInfo("inst_potential_laten_heat_flx_lnd ", "s"), & FieldInfo("inst_temp_height2m_lnd ", "s"), & FieldInfo("inst_spec_humid_height2m_lnd ", "s"), & - FieldInfo("mean_upward_heat_flux_lnd ", "s"), & - FieldInfo("mean_runoff_rate_lnd ", "s"), & - FieldInfo("mean_subsurface_runoff_rate_lnd ", "s"), & + FieldInfo("inst_upward_heat_flux_lnd ", "s"), & + FieldInfo("inst_runoff_rate_lnd ", "s"), & + FieldInfo("inst_subsurface_runoff_rate_lnd ", "s"), & FieldInfo("inst_drag_wind_speed_for_momentum ", "s"), & FieldInfo("inst_drag_mass_flux_for_heat_and_moisture", "s"), & FieldInfo("inst_func_of_roughness_length_and_vfrac ", "s"), & From e84c233e72ac489e0a77c8fb329a7450565553e3 Mon Sep 17 00:00:00 2001 From: "Haiqin.Li" Date: Fri, 19 Jan 2024 18:35:12 +0000 Subject: [PATCH 18/25] "Supplementary physics updates for RRFS code freeze" --- .gitmodules | 4 +- ccpp/data/GFS_typedefs.F90 | 42 +++--- ccpp/data/GFS_typedefs.meta | 56 +++++++- ccpp/driver/GFS_diagnostics.F90 | 225 ++++++++++++++++++++++++++++++-- ccpp/driver/GFS_restart.F90 | 24 +--- ccpp/physics | 2 +- 6 files changed, 306 insertions(+), 47 deletions(-) diff --git a/.gitmodules b/.gitmodules index 22c723ac1..8aac7d579 100644 --- a/.gitmodules +++ b/.gitmodules @@ -8,8 +8,8 @@ branch = main [submodule "ccpp/physics"] path = ccpp/physics - url = https://github.com/ufs-community/ccpp-physics - branch = ufs/dev + url = https://github.com/haiqinli/ccpp-physics + branch = ufs/dev-smoke-dust [submodule "upp"] path = upp url = https://github.com/NOAA-EMC/UPP diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index 5a8368a40..ee5bd0e84 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -459,11 +459,14 @@ module GFS_typedefs !--- Smoke. These 2 arrays are input smoke emission and frp real (kind=kind_phys), pointer :: ebb_smoke_in(:) => null() !< input smoke emission - real (kind=kind_phys), pointer :: frp_input (:) => null() !< input FRP - + real (kind=kind_phys), pointer :: frp_output (:) => null() !< output FRP !--- For fire diurnal cycle real (kind=kind_phys), pointer :: fhist (:) => null() !< instantaneous fire coef_bb real (kind=kind_phys), pointer :: coef_bb_dc (:) => null() !< instantaneous fire coef_bb + integer, pointer :: fire_type_out (:) => null() !< fire type + real (kind=kind_phys), pointer :: peak_hr_out (:) => null() !< peak hour of fire emissions + real (kind=kind_phys), pointer :: lu_nofire_out (:) =>null() !null() ! null() !< heat flux from wildfire real (kind=kind_phys), pointer :: frac_grid_burned_out (:) => null() !< fraction of grid cell burning @@ -616,10 +619,6 @@ module GFS_typedefs !--- For fire diurnal cycle real (kind=kind_phys), pointer :: ebu_smoke (:,:) => null() !< 3D ebu array - !--- For smoke and dust optical extinction - real (kind=kind_phys), pointer :: smoke_ext (:,:) => null() !< 3D aod array - real (kind=kind_phys), pointer :: dust_ext (:,:) => null() !< 3D aod array - !--- For MYNN PBL transport of smoke and dust real (kind=kind_phys), pointer :: chem3d (:,:,:) => null() !< 3D aod array real (kind=kind_phys), pointer :: ddvel (:,: ) => null() !< 2D dry deposition velocity @@ -633,6 +632,8 @@ module GFS_typedefs !--- Fire plume rise diagnostics real (kind=kind_phys), pointer :: min_fplume (:) => null() !< minimum plume rise level real (kind=kind_phys), pointer :: max_fplume (:) => null() !< maximum plume rise level + real (kind=kind_phys), pointer :: uspdavg (:) => null() !< BL average wind speed + real (kind=kind_phys), pointer :: hpbl_thetav (:) => null() !< BL depth parcel method !--- hourly fire potential index real (kind=kind_phys), pointer :: rrfs_hwp (:) => null() !< hourly fire potential index real (kind=kind_phys), pointer :: rrfs_hwp_ave (:) => null() !< *Average* hourly fire potential index @@ -1528,6 +1529,7 @@ module GFS_typedefs logical :: do_plumerise integer :: addsmoke_flag integer :: plumerisefire_frq + integer :: n_dbg_lines integer :: smoke_forecast logical :: aero_ind_fdb ! WFA/IFA indirect logical :: aero_dir_fdb ! smoke/dust direct @@ -2805,9 +2807,13 @@ subroutine sfcprop_create (Sfcprop, IM, Model) allocate (Sfcprop%emseas (IM)) allocate (Sfcprop%emanoc (IM)) allocate (Sfcprop%ebb_smoke_in (IM)) - allocate (Sfcprop%frp_input (IM)) + allocate (Sfcprop%frp_output (IM)) allocate (Sfcprop%fhist (IM)) allocate (Sfcprop%coef_bb_dc(IM)) + allocate (Sfcprop%fire_type_out (IM)) + allocate (Sfcprop%peak_hr_out(IM)) + allocate (Sfcprop%lu_nofire_out(IM)) + allocate (Sfcprop%lu_qfire_out(IM)) allocate (Sfcprop%fire_in (IM,Model%fire_aux_data_levels)) ! IMPORTANT: This initialization must match rrfs_sd_fill_data @@ -2815,10 +2821,14 @@ subroutine sfcprop_create (Sfcprop, IM, Model) Sfcprop%emseas = clear_val Sfcprop%emanoc = clear_val Sfcprop%ebb_smoke_in = clear_val - Sfcprop%frp_input = clear_val + Sfcprop%frp_output = clear_val Sfcprop%fhist = 1. Sfcprop%coef_bb_dc = clear_val + Sfcprop%fire_type_out = 0 Sfcprop%fire_in = clear_val + Sfcprop%peak_hr_out = clear_val + Sfcprop%lu_nofire_out = clear_val + Sfcprop%lu_qfire_out = clear_val endif end subroutine sfcprop_create @@ -3157,8 +3167,6 @@ subroutine coupling_create (Coupling, IM, Model) if(Model%rrfs_sd) then !--- needed for smoke aerosol option allocate (Coupling%ebu_smoke (IM,Model%levs)) - allocate (Coupling%smoke_ext (IM,Model%levs)) - allocate (Coupling%dust_ext (IM,Model%levs)) allocate (Coupling%chem3d (IM,Model%levs,Model%nchem)) allocate (Coupling%ddvel (IM,Model%ndvel)) allocate (Coupling%wetdpc_flux(IM,Model%nchem)) @@ -3166,11 +3174,11 @@ subroutine coupling_create (Coupling, IM, Model) allocate (Coupling%drydep_flux(IM,Model%ndvel)) allocate (Coupling%min_fplume(IM)) allocate (Coupling%max_fplume(IM)) + allocate (Coupling%uspdavg(IM)) + allocate (Coupling%hpbl_thetav(IM)) allocate (Coupling%rrfs_hwp (IM)) allocate (Coupling%rrfs_hwp_ave (IM)) Coupling%ebu_smoke = clear_val - Coupling%smoke_ext = clear_val - Coupling%dust_ext = clear_val Coupling%chem3d = clear_val Coupling%ddvel = clear_val Coupling%wetdpc_flux = clear_val @@ -3178,6 +3186,8 @@ subroutine coupling_create (Coupling, IM, Model) Coupling%drydep_flux = clear_val Coupling%min_fplume = clear_val Coupling%max_fplume = clear_val + Coupling%uspdavg = clear_val + Coupling%hpbl_thetav = clear_val Coupling%rrfs_hwp = clear_val Coupling%rrfs_hwp_ave = clear_val endif @@ -3865,11 +3875,11 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & real(kind=kind_phys) :: dust_moist_correction = 1.0 real(kind=kind_phys) :: dust_alpha = 0. real(kind=kind_phys) :: dust_gamma = 0. - real(kind=kind_phys) :: wetdep_ls_alpha = 0. + real(kind=kind_phys) :: wetdep_ls_alpha = 0.5 integer :: dust_moist_opt = 1 ! fecan :1 else shao integer :: ebb_dcycle = 1 ! 1:retro; 2:forecast integer :: seas_opt = 2 - integer :: dust_opt = 5 + integer :: dust_opt = 1 integer :: drydep_opt = 1 integer :: coarsepm_settling = 1 integer :: plume_wind_eff = 1 @@ -3878,6 +3888,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & logical :: do_plumerise = .false. integer :: addsmoke_flag = 1 integer :: plumerisefire_frq = 60 + integer :: n_dbg_lines = 3 integer :: smoke_forecast = 0 ! RRFS-sd read in ebb_smoke logical :: aero_ind_fdb = .false. ! RRFS-sd wfa/ifa emission logical :: aero_dir_fdb = .false. ! RRFS-sd smoke/dust radiation feedback @@ -4049,7 +4060,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & wetdep_ls_opt, smoke_forecast, aero_ind_fdb, aero_dir_fdb, & rrfs_smoke_debug, do_plumerise, plumerisefire_frq, & addsmoke_flag, enh_mix, mix_chem, smoke_dir_fdb_coef, & - do_smoke_transport,smoke_conv_wet_coef, & + do_smoke_transport,smoke_conv_wet_coef,n_dbg_lines, & !--- C3/GF closures ichoice,ichoicem,ichoice_s, & !--- (DFI) time ranges with radar-prescribed microphysics tendencies @@ -4282,6 +4293,7 @@ subroutine control_initialize (Model, nlunit, fn_nml, me, master, & Model%extended_sd_diags = extended_sd_diags Model%wetdep_ls_opt = wetdep_ls_opt Model%do_plumerise = do_plumerise + Model%n_dbg_lines = n_dbg_lines Model%plumerisefire_frq = plumerisefire_frq Model%addsmoke_flag = addsmoke_flag Model%smoke_forecast = smoke_forecast diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index ebaa9af7f..a02abae55 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -2288,7 +2288,7 @@ type = real kind = kind_phys active = (do_smoke_coupling) -[frp_input] +[frp_output] standard_name = frp_hourly long_name = hourly fire radiative power units = MW @@ -2312,6 +2312,37 @@ type = real kind = kind_phys active = (do_smoke_coupling) +[fire_type_out] + standard_name = fire_type_out + long_name = type of fire + units = none + dimensions = (horizontal_loop_extent) + type = integer + active = (do_smoke_coupling) +[peak_hr_out] + standard_name = peak_hr_fire + long_name = hour of peak fire emissions + units = none + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (do_smoke_coupling) +[lu_nofire_out] + standard_name = lu_nofire_out + long_name = land use of no fire pixels for type + units = frac + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (do_smoke_coupling) +[lu_qfire_out] + standard_name = lu_qfire_out + long_name = land use of fire pixels for type + units = frac + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (do_smoke_coupling) [fire_in] standard_name = smoke_fire_auxiliary_input long_name = smoke fire auxiliary input variables @@ -3052,6 +3083,22 @@ type = real kind = kind_phys active = (do_smoke_coupling) +[uspdavg] + standard_name = bl_averaged_wind_speed + long_name = average wind speed within the boundary layer + units = none + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (do_smoke_coupling) +[hpbl_thetav] + standard_name = pbl_height_thetav + long_name = pbl height based on modified parcel method + units = none + dimensions = (horizontal_loop_extent) + type = real + kind = kind_phys + active = (do_smoke_coupling) [rrfs_hwp] standard_name = hourly_wildfire_potential long_name = rrfs hourly fire weather potential @@ -6678,6 +6725,13 @@ dimensions = () type = integer active = (do_smoke_coupling) +[n_dbg_lines] + standard_name = smoke_debug_lines + long_name = rrfs smoke add smoke option + units = index + dimensions = () + type = integer + active = (do_smoke_coupling) [addsmoke_flag] standard_name = control_for_smoke_biomass_burning_emissions long_name = rrfs smoke add smoke option diff --git a/ccpp/driver/GFS_diagnostics.F90 b/ccpp/driver/GFS_diagnostics.F90 index 3bbd300d5..7b0ca752f 100644 --- a/ccpp/driver/GFS_diagnostics.F90 +++ b/ccpp/driver/GFS_diagnostics.F90 @@ -3761,6 +3761,18 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop enddo if (Model%lsm == Model%lsm_ruc) then + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'sfalb' + ExtDiag(idx)%desc = 'surface albedo over land' + ExtDiag(idx)%unit = 'fraction' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%sfalb_lnd(:) + enddo + idx = idx + 1 ExtDiag(idx)%axes = 2 ExtDiag(idx)%name = 'rhofr' @@ -4077,7 +4089,7 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop ExtDiag(idx)%name = 'nirbmdi' ExtDiag(idx)%desc = 'sfc nir beam sw downward flux' ExtDiag(idx)%unit = 'W/m**2' - ExtDiag(idx)%mod_name = 'gfs_sfc' + ExtDiag(idx)%mod_name = 'gfs_phys' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%nirbmdi(:) @@ -4088,7 +4100,7 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop ExtDiag(idx)%name = 'nirdfdi' ExtDiag(idx)%desc = 'sfc nir diff sw downward flux' ExtDiag(idx)%unit = 'W/m**2' - ExtDiag(idx)%mod_name = 'gfs_sfc' + ExtDiag(idx)%mod_name = 'gfs_phys' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%nirdfdi(:) @@ -4099,7 +4111,7 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop ExtDiag(idx)%name = 'visbmdi' ExtDiag(idx)%desc = 'sfc uv+vis beam sw downward flux' ExtDiag(idx)%unit = 'W/m**2' - ExtDiag(idx)%mod_name = 'gfs_sfc' + ExtDiag(idx)%mod_name = 'gfs_phys' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%visbmdi(:) @@ -4110,7 +4122,7 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop ExtDiag(idx)%name = 'visdfdi' ExtDiag(idx)%desc = ' sfc uv+vis diff sw downward flux' ExtDiag(idx)%unit = 'W/m**2' - ExtDiag(idx)%mod_name = 'gfs_sfc' + ExtDiag(idx)%mod_name = 'gfs_phys' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%visdfdi(:) @@ -4669,6 +4681,96 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%rrfs_hwp_ave enddo + extended_smoke_dust_diagnostics: if ( Model%extended_sd_diags ) then + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'uspdavg' + ExtDiag(idx)%desc = 'BL average wind speed' + ExtDiag(idx)%unit = '' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%uspdavg + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'hpbl_thetav' + ExtDiag(idx)%desc = 'BL depth modified parcel method' + ExtDiag(idx)%unit = '' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%hpbl_thetav + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'drydep_smoke' + ExtDiag(idx)%desc = 'dry deposition smoke' + ExtDiag(idx)%unit = ' ' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%drydep_flux(:,1) + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'drydep_dust' + ExtDiag(idx)%desc = 'dry deposition dust' + ExtDiag(idx)%unit = ' ' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%drydep_flux(:,2) + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'drydep_coarsepm' + ExtDiag(idx)%desc = 'dry deposition coarsepm' + ExtDiag(idx)%unit = ' ' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%drydep_flux(:,3) + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'wetdpr_smoke' + ExtDiag(idx)%desc = 'resolved wet deposition smoke' + ExtDiag(idx)%unit = ' ' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%wetdpr_flux(:,1) + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'wetdpr_dust' + ExtDiag(idx)%desc = 'resolved wet deposition dust' + ExtDiag(idx)%unit = ' ' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%wetdpr_flux(:,2) + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'wetdpr_coarsepm' + ExtDiag(idx)%desc = 'resolved wet deposition coarsepm' + ExtDiag(idx)%unit = ' ' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Coupling(nb)%wetdpr_flux(:,3) + enddo + idx = idx + 1 ExtDiag(idx)%axes = 2 ExtDiag(idx)%name = 'wetdpc_smoke' @@ -4704,13 +4806,46 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop idx = idx + 1 ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'ebb_smoke_in' - ExtDiag(idx)%desc = 'input smoke emission' - ExtDiag(idx)%unit = 'ug m-2 s-1' + ExtDiag(idx)%name = 'peak_hr_out' + ExtDiag(idx)%desc = 'hour of peak smoke emissions' + ExtDiag(idx)%unit = ' ' ExtDiag(idx)%mod_name = 'gfs_sfc' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%ebb_smoke_in + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%peak_hr_out + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'fire_type_out' + ExtDiag(idx)%desc = 'fire type' + ExtDiag(idx)%unit = '' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%int2 => Sfcprop(nb)%fire_type_out + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'lu_nofire_out' + ExtDiag(idx)%desc = 'lu nofire pixes' + ExtDiag(idx)%unit = '' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%lu_nofire_out + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'lu_qfire_out' + ExtDiag(idx)%desc = 'lu qfire pixes' + ExtDiag(idx)%unit = '' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%lu_qfire_out enddo idx = idx + 1 @@ -4724,17 +4859,85 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%fhist enddo + if (Model%ebb_dcycle == 2 ) then + idx = idx + 1 ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'frp_input' - ExtDiag(idx)%desc = 'input frp' + ExtDiag(idx)%name = 'fire_end_hr' + ExtDiag(idx)%desc = 'Hours since fire was last detected' + ExtDiag(idx)%unit = 'hrs' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%smoke2d_RRFS(:,3) + enddo + + endif + + endif extended_smoke_dust_diagnostics + + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'ebb_smoke_in' + ExtDiag(idx)%desc = 'input smoke emission' + ExtDiag(idx)%unit = 'ug m-2 s-1' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%ebb_smoke_in + enddo + + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'frp_output' + ExtDiag(idx)%desc = 'output frp' + ExtDiag(idx)%unit = 'mw' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%frp_output + enddo + + smoke_forecast_mode: if (Model%ebb_dcycle == 2 ) then + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'ebb_rate' + ExtDiag(idx)%desc = 'Total EBB Emissions' + ExtDiag(idx)%unit = 'ug m-2 s-1' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%smoke2d_RRFS(:,1) + enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'frp_davg' + ExtDiag(idx)%desc = 'Daily mean Fire Radiative Power' ExtDiag(idx)%unit = 'mw' ExtDiag(idx)%mod_name = 'gfs_sfc' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%frp_input + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%smoke2d_RRFS(:,2) enddo + + idx = idx + 1 + ExtDiag(idx)%axes = 2 + ExtDiag(idx)%name = 'hwp_davg' + ExtDiag(idx)%desc = 'Daily mean Hourly Wildfire Potential' + ExtDiag(idx)%unit = ' ' + ExtDiag(idx)%mod_name = 'gfs_sfc' + allocate (ExtDiag(idx)%data(nblks)) + do nb = 1,nblks + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%smoke2d_RRFS(:,4) + enddo + + endif smoke_forecast_mode + idx = idx + 1 ExtDiag(idx)%axes = 3 ExtDiag(idx)%name = 'ebu_smoke' diff --git a/ccpp/driver/GFS_restart.F90 b/ccpp/driver/GFS_restart.F90 index 9abf926de..890aeb9fb 100644 --- a/ccpp/driver/GFS_restart.F90 +++ b/ccpp/driver/GFS_restart.F90 @@ -152,7 +152,7 @@ subroutine GFS_restart_populate (Restart, Model, Statein, Stateout, Sfcprop, & Restart%num2d = Restart%num2d + Model%num_dfi_radar endif if (Model%rrfs_sd) then - Restart%num2d = Restart%num2d + 5 + Restart%num2d = Restart%num2d + 6 endif Restart%num3d = Model%ntot3d @@ -179,7 +179,7 @@ subroutine GFS_restart_populate (Restart, Model, Statein, Stateout, Sfcprop, & Restart%num3d = Restart%num3d + 9 endif if (Model%rrfs_sd) then - Restart%num3d = Restart%num3d + 7 + Restart%num3d = Restart%num3d + 4 endif !Prognostic area fraction if (Model%progsigma) then @@ -515,6 +515,11 @@ subroutine GFS_restart_populate (Restart, Model, Statein, Stateout, Sfcprop, & do nb = 1,nblks Restart%data(nb,num)%var2p => Coupling(nb)%rrfs_hwp(:) enddo + num = num + 1 + Restart%name2d(num) = 'rrfs_hwp_ave' + do nb = 1,nblks + Restart%data(nb,num)%var2p => Coupling(nb)%rrfs_hwp_ave(:) + enddo endif !--- phy_f3d variables @@ -669,21 +674,6 @@ subroutine GFS_restart_populate (Restart, Model, Statein, Stateout, Sfcprop, & endif if(Model%rrfs_sd) then - num = num + 1 - Restart%name3d(num) = 'ebu_smoke' - do nb = 1,nblks - Restart%data(nb,num)%var3p => Coupling(nb)%ebu_smoke(:,:) - enddo - num = num + 1 - Restart%name3d(num) = 'smoke_ext' - do nb = 1,nblks - Restart%data(nb,num)%var3p => Coupling(nb)%smoke_ext(:,:) - enddo - num = num + 1 - Restart%name3d(num) = 'dust_ext' - do nb = 1,nblks - Restart%data(nb,num)%var3p => Coupling(nb)%dust_ext(:,:) - enddo num = num + 1 Restart%name3d(num) = 'chem3d_1' do nb = 1,nblks diff --git a/ccpp/physics b/ccpp/physics index a492addf8..02b344037 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit a492addf860d29d797bca488f53d39b260584924 +Subproject commit 02b3440378e5bb04ddc4ba50b44f2532eb7cab08 From a514c76b407cf720d14c859ffded837e8dd92043 Mon Sep 17 00:00:00 2001 From: Ufuk Turuncoglu Date: Fri, 19 Jan 2024 17:13:14 -0600 Subject: [PATCH 19/25] sync atmos_cubed_sphere --- atmos_cubed_sphere | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/atmos_cubed_sphere b/atmos_cubed_sphere index caba092f6..eeb4a714d 160000 --- a/atmos_cubed_sphere +++ b/atmos_cubed_sphere @@ -1 +1 @@ -Subproject commit caba092f682c9713a485e782b8f9ba6480adaca2 +Subproject commit eeb4a714d946f554da6b16800da436e1ce66a092 From 28d13511e13e3bc7f18ce2b5694f53c5ce73d1db Mon Sep 17 00:00:00 2001 From: "Haiqin.Li" Date: Tue, 23 Jan 2024 16:15:43 +0000 Subject: [PATCH 20/25] "update to address UFS code managers' comments" --- ccpp/data/GFS_typedefs.F90 | 40 ++++++++++++++++----------------- ccpp/data/GFS_typedefs.meta | 32 +++++++++++++------------- ccpp/driver/GFS_diagnostics.F90 | 20 ++++++++--------- ccpp/physics | 2 +- 4 files changed, 47 insertions(+), 47 deletions(-) diff --git a/ccpp/data/GFS_typedefs.F90 b/ccpp/data/GFS_typedefs.F90 index ee5bd0e84..615f983ba 100644 --- a/ccpp/data/GFS_typedefs.F90 +++ b/ccpp/data/GFS_typedefs.F90 @@ -458,18 +458,18 @@ module GFS_typedefs real (kind=kind_phys), pointer :: emanoc (:) => null() !< instantaneous anthro. oc emission !--- Smoke. These 2 arrays are input smoke emission and frp - real (kind=kind_phys), pointer :: ebb_smoke_in(:) => null() !< input smoke emission - real (kind=kind_phys), pointer :: frp_output (:) => null() !< output FRP + real (kind=kind_phys), pointer :: ebb_smoke_in(:) => null() !< input smoke emission + real (kind=kind_phys), pointer :: frp_output (:) => null() !< output FRP !--- For fire diurnal cycle real (kind=kind_phys), pointer :: fhist (:) => null() !< instantaneous fire coef_bb real (kind=kind_phys), pointer :: coef_bb_dc (:) => null() !< instantaneous fire coef_bb - integer, pointer :: fire_type_out (:) => null() !< fire type - real (kind=kind_phys), pointer :: peak_hr_out (:) => null() !< peak hour of fire emissions - real (kind=kind_phys), pointer :: lu_nofire_out (:) =>null() !null() ! null() !< fire type + real (kind=kind_phys), pointer :: peak_hr (:) => null() !< peak hour of fire emissions + real (kind=kind_phys), pointer :: lu_nofire (:) => null() ! null() ! null() !< heat flux from wildfire - real (kind=kind_phys), pointer :: frac_grid_burned_out (:) => null() !< fraction of grid cell burning + real (kind=kind_phys), pointer :: fire_heat_flux (:) => null() !< heat flux from wildfire + real (kind=kind_phys), pointer :: frac_grid_burned (:) => null() !< fraction of grid cell burning !--- For smoke and dust auxiliary inputs real (kind=kind_phys), pointer :: fire_in (:,:) => null() !< fire auxiliary inputs @@ -2690,8 +2690,8 @@ subroutine sfcprop_create (Sfcprop, IM, Model) allocate (Sfcprop%acsnow_land (IM)) allocate (Sfcprop%acsnow_ice (IM)) allocate (Sfcprop%xlaixy (IM)) - allocate (Sfcprop%fire_heat_flux_out (IM)) - allocate (Sfcprop%frac_grid_burned_out (IM)) + allocate (Sfcprop%fire_heat_flux (IM)) + allocate (Sfcprop%frac_grid_burned(IM)) ! Sfcprop%wetness = clear_val @@ -2712,8 +2712,8 @@ subroutine sfcprop_create (Sfcprop, IM, Model) Sfcprop%acsnow_land = clear_val Sfcprop%acsnow_ice = clear_val Sfcprop%xlaixy = clear_val - Sfcprop%fire_heat_flux_out = clear_val - Sfcprop%frac_grid_burned_out = clear_val + Sfcprop%fire_heat_flux = clear_val + Sfcprop%frac_grid_burned= clear_val ! end if @@ -2810,10 +2810,10 @@ subroutine sfcprop_create (Sfcprop, IM, Model) allocate (Sfcprop%frp_output (IM)) allocate (Sfcprop%fhist (IM)) allocate (Sfcprop%coef_bb_dc(IM)) - allocate (Sfcprop%fire_type_out (IM)) - allocate (Sfcprop%peak_hr_out(IM)) - allocate (Sfcprop%lu_nofire_out(IM)) - allocate (Sfcprop%lu_qfire_out(IM)) + allocate (Sfcprop%fire_type (IM)) + allocate (Sfcprop%peak_hr (IM)) + allocate (Sfcprop%lu_nofire (IM)) + allocate (Sfcprop%lu_qfire (IM)) allocate (Sfcprop%fire_in (IM,Model%fire_aux_data_levels)) ! IMPORTANT: This initialization must match rrfs_sd_fill_data @@ -2824,11 +2824,11 @@ subroutine sfcprop_create (Sfcprop, IM, Model) Sfcprop%frp_output = clear_val Sfcprop%fhist = 1. Sfcprop%coef_bb_dc = clear_val - Sfcprop%fire_type_out = 0 + Sfcprop%fire_type = 0 Sfcprop%fire_in = clear_val - Sfcprop%peak_hr_out = clear_val - Sfcprop%lu_nofire_out = clear_val - Sfcprop%lu_qfire_out = clear_val + Sfcprop%peak_hr = clear_val + Sfcprop%lu_nofire = clear_val + Sfcprop%lu_qfire = clear_val endif end subroutine sfcprop_create diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index a02abae55..1f5ff7c55 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -979,7 +979,7 @@ type = real kind = kind_phys active = (control_for_land_surface_scheme == identifier_for_ruc_land_surface_scheme) -[fire_heat_flux_out] +[fire_heat_flux] standard_name = surface_fire_heat_flux long_name = heat flux of fire at the surface units = W m-2 @@ -987,7 +987,7 @@ type = real kind = kind_phys active = (control_for_land_surface_scheme == identifier_for_ruc_land_surface_scheme) -[frac_grid_burned_out] +[frac_grid_burned] standard_name = fraction_of_grid_cell_burning long_name = ration of the burnt area to the grid cell area units = frac @@ -2312,31 +2312,31 @@ type = real kind = kind_phys active = (do_smoke_coupling) -[fire_type_out] - standard_name = fire_type_out +[fire_type] + standard_name = fire_type long_name = type of fire - units = none + units = 1 dimensions = (horizontal_loop_extent) type = integer active = (do_smoke_coupling) -[peak_hr_out] +[peak_hr] standard_name = peak_hr_fire - long_name = hour of peak fire emissions - units = none + long_name = time_of_peak_fire_emissions + units = s dimensions = (horizontal_loop_extent) type = real kind = kind_phys active = (do_smoke_coupling) -[lu_nofire_out] - standard_name = lu_nofire_out +[lu_nofire] + standard_name = sum_of_land_use_fractions_for_no_fire_pixels long_name = land use of no fire pixels for type units = frac dimensions = (horizontal_loop_extent) type = real kind = kind_phys active = (do_smoke_coupling) -[lu_qfire_out] - standard_name = lu_qfire_out +[lu_qfire] + standard_name = sum_of_land_use_fractions_for_cropland_fire_pixels long_name = land use of fire pixels for type units = frac dimensions = (horizontal_loop_extent) @@ -3084,17 +3084,17 @@ kind = kind_phys active = (do_smoke_coupling) [uspdavg] - standard_name = bl_averaged_wind_speed + standard_name = mean_wind_speed_in_boundary_layer long_name = average wind speed within the boundary layer - units = none + units = m s-1 dimensions = (horizontal_loop_extent) type = real kind = kind_phys active = (do_smoke_coupling) [hpbl_thetav] - standard_name = pbl_height_thetav + standard_name = atmosphere_boundary_layer_thickness_from_modified_parcel long_name = pbl height based on modified parcel method - units = none + units = m dimensions = (horizontal_loop_extent) type = real kind = kind_phys diff --git a/ccpp/driver/GFS_diagnostics.F90 b/ccpp/driver/GFS_diagnostics.F90 index 7b0ca752f..def71566d 100644 --- a/ccpp/driver/GFS_diagnostics.F90 +++ b/ccpp/driver/GFS_diagnostics.F90 @@ -4580,7 +4580,7 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop ExtDiag(idx)%mod_name = 'gfs_sfc' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%fire_heat_flux_out + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%fire_heat_flux enddo idx = idx + 1 @@ -4591,7 +4591,7 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop ExtDiag(idx)%mod_name = 'gfs_sfc' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%frac_grid_burned_out + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%frac_grid_burned enddo idx = idx + 1 @@ -4806,46 +4806,46 @@ subroutine GFS_externaldiag_populate (ExtDiag, Model, Statein, Stateout, Sfcprop idx = idx + 1 ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'peak_hr_out' + ExtDiag(idx)%name = 'peak_hr' ExtDiag(idx)%desc = 'hour of peak smoke emissions' ExtDiag(idx)%unit = ' ' ExtDiag(idx)%mod_name = 'gfs_sfc' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%peak_hr_out + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%peak_hr enddo idx = idx + 1 ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'fire_type_out' + ExtDiag(idx)%name = 'fire_type' ExtDiag(idx)%desc = 'fire type' ExtDiag(idx)%unit = '' ExtDiag(idx)%mod_name = 'gfs_sfc' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks - ExtDiag(idx)%data(nb)%int2 => Sfcprop(nb)%fire_type_out + ExtDiag(idx)%data(nb)%int2 => Sfcprop(nb)%fire_type enddo idx = idx + 1 ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'lu_nofire_out' + ExtDiag(idx)%name = 'lu_nofire' ExtDiag(idx)%desc = 'lu nofire pixes' ExtDiag(idx)%unit = '' ExtDiag(idx)%mod_name = 'gfs_sfc' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%lu_nofire_out + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%lu_nofire enddo idx = idx + 1 ExtDiag(idx)%axes = 2 - ExtDiag(idx)%name = 'lu_qfire_out' + ExtDiag(idx)%name = 'lu_qfire' ExtDiag(idx)%desc = 'lu qfire pixes' ExtDiag(idx)%unit = '' ExtDiag(idx)%mod_name = 'gfs_sfc' allocate (ExtDiag(idx)%data(nblks)) do nb = 1,nblks - ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%lu_qfire_out + ExtDiag(idx)%data(nb)%var2 => Sfcprop(nb)%lu_qfire enddo idx = idx + 1 diff --git a/ccpp/physics b/ccpp/physics index 02b344037..c0544c218 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 02b3440378e5bb04ddc4ba50b44f2532eb7cab08 +Subproject commit c0544c218776d4a94169d45cb7dae102800594a1 From 5d8b3b2103bea0f0068407f01b6143aa9e96034a Mon Sep 17 00:00:00 2001 From: Ufuk Turuncoglu Date: Tue, 23 Jan 2024 11:53:36 -0600 Subject: [PATCH 21/25] sync atmos_cubed_sphere --- atmos_cubed_sphere | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/atmos_cubed_sphere b/atmos_cubed_sphere index eeb4a714d..65301dd7c 160000 --- a/atmos_cubed_sphere +++ b/atmos_cubed_sphere @@ -1 +1 @@ -Subproject commit eeb4a714d946f554da6b16800da436e1ce66a092 +Subproject commit 65301dd7c6b29c755a1f31b1a8e94562d3bd920c From 3009def68140af1b424a13a1866df1232f1b7b7c Mon Sep 17 00:00:00 2001 From: "Haiqin.Li" Date: Wed, 24 Jan 2024 16:37:31 +0000 Subject: [PATCH 22/25] "update to resolve code managers' comments" --- ccpp/data/GFS_typedefs.meta | 4 ++-- ccpp/physics | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ccpp/data/GFS_typedefs.meta b/ccpp/data/GFS_typedefs.meta index 1f5ff7c55..87dcfe885 100644 --- a/ccpp/data/GFS_typedefs.meta +++ b/ccpp/data/GFS_typedefs.meta @@ -2330,7 +2330,7 @@ [lu_nofire] standard_name = sum_of_land_use_fractions_for_no_fire_pixels long_name = land use of no fire pixels for type - units = frac + units = 1 dimensions = (horizontal_loop_extent) type = real kind = kind_phys @@ -2338,7 +2338,7 @@ [lu_qfire] standard_name = sum_of_land_use_fractions_for_cropland_fire_pixels long_name = land use of fire pixels for type - units = frac + units = 1 dimensions = (horizontal_loop_extent) type = real kind = kind_phys diff --git a/ccpp/physics b/ccpp/physics index c0544c218..a0acaedeb 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit c0544c218776d4a94169d45cb7dae102800594a1 +Subproject commit a0acaedeb7512f9c3cc062922b83466ffdfc2478 From 49fada688be749a2861b418cad2d064839bf8c98 Mon Sep 17 00:00:00 2001 From: uturuncoglu Date: Wed, 24 Jan 2024 13:46:13 -0700 Subject: [PATCH 23/25] update ccpp/physics by merging #161 --- ccpp/physics | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index ca1a6e3f1..042d156a7 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit ca1a6e3f10188c2f480ee58d4a487698ffc9234b +Subproject commit 042d156a7b8e3d94fd3dbca4e97ea22e974cb2d7 From 43fe0eed1aff62453e09f3dbc1aa2a4399e6eb34 Mon Sep 17 00:00:00 2001 From: Ufuk Turuncoglu Date: Fri, 26 Jan 2024 07:58:25 -0600 Subject: [PATCH 24/25] update git module file --- .gitmodules | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitmodules b/.gitmodules index ad9e50004..22c723ac1 100644 --- a/.gitmodules +++ b/.gitmodules @@ -8,8 +8,8 @@ branch = main [submodule "ccpp/physics"] path = ccpp/physics - url = https://github.com/uturuncoglu/ccpp-physics - branch = feature/noahmp + url = https://github.com/ufs-community/ccpp-physics + branch = ufs/dev [submodule "upp"] path = upp url = https://github.com/NOAA-EMC/UPP From 970bcab88b81c26ee3d7f6d916b9619f7812fbda Mon Sep 17 00:00:00 2001 From: Ufuk Turuncoglu Date: Fri, 26 Jan 2024 08:11:56 -0600 Subject: [PATCH 25/25] update ccpp physics --- ccpp/physics | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ccpp/physics b/ccpp/physics index 042d156a7..d0c3294c7 160000 --- a/ccpp/physics +++ b/ccpp/physics @@ -1 +1 @@ -Subproject commit 042d156a7b8e3d94fd3dbca4e97ea22e974cb2d7 +Subproject commit d0c3294c7efa1531f489dcacff676b92acdab5a1