diff --git a/physics/rrtmgp_sw_gas_optics.F90 b/physics/rrtmgp_sw_gas_optics.F90 index d4db0d2d7..506fd47c3 100644 --- a/physics/rrtmgp_sw_gas_optics.F90 +++ b/physics/rrtmgp_sw_gas_optics.F90 @@ -1,6 +1,6 @@ module rrtmgp_sw_gas_optics use machine, only: kind_phys - use GFS_typedefs, only: GFS_control_type, GFS_interstitial_type + use GFS_typedefs, only: GFS_control_type use module_radiation_gases, only: NF_VGAS use mo_rte_kind, only: wl use mo_gas_optics_rrtmgp, only: ty_gas_optics_rrtmgp @@ -405,15 +405,13 @@ end subroutine rrtmgp_sw_gas_optics_init !! \section arg_table_rrtmgp_sw_gas_optics_run !! \htmlinclude rrtmgp_sw_gas_optics.html !! - subroutine rrtmgp_sw_gas_optics_run(Model, Interstitial, sw_gas_props, ncol, nday, idxday,& - p_lay, p_lev, t_lay, t_lev, gas_concentrations, lsswr, solcon, & - sw_optical_props_clrsky, errmsg, errflg) + subroutine rrtmgp_sw_gas_optics_run(Model, sw_gas_props, ncol, nday, idxday, p_lay, p_lev,& + toa_src_sw, t_lay, t_lev, gas_concentrations, lsswr, solcon, sw_optical_props_clrsky,& + errmsg, errflg) ! Inputs type(GFS_control_type), intent(in) :: & Model ! DDT: FV3-GFS model control parameters - type(GFS_Interstitial_type),intent(inout) :: & - Interstitial ! DDT: FV3-GFS Interstitial arrays type(ty_gas_optics_rrtmgp),intent(in) :: & sw_gas_props ! RRTMGP DDT: spectral information for RRTMGP SW radiation scheme integer,intent(in) :: & @@ -441,6 +439,8 @@ subroutine rrtmgp_sw_gas_optics_run(Model, Interstitial, sw_gas_props, ncol, nda errflg ! Error code type(ty_optical_props_2str),intent(out) :: & sw_optical_props_clrsky ! RRTMGP DDT: clear-sky shortwave optical properties, spectral (tau,ssa,g) + real(kind_phys), dimension(ncol,sw_gas_props%get_ngpt()), intent(out) :: & + toa_src_sw ! TOA incident spectral flux (W/m2) ! Local variables integer :: ij,iGas @@ -476,11 +476,11 @@ subroutine rrtmgp_sw_gas_optics_run(Model, Interstitial, sw_gas_props, ncol, nda sw_optical_props_clrsky, & ! OUT - RRTMGP DDT: Shortwave optical properties, by ! spectral point (tau,ssa,g) toa_src_sw_temp)) ! OUT - TOA incident shortwave radiation (spectral) - Interstitial%toa_src_sw(idxday(1:nday),:) = toa_src_sw_temp + toa_src_sw(idxday(1:nday),:) = toa_src_sw_temp ! Scale incident flux do ij=1,nday - Interstitial%toa_src_sw(idxday(ij),:) = Interstitial%toa_src_sw(idxday(ij),:)*solcon/ & - sum(Interstitial%toa_src_sw(idxday(ij),:)) + toa_src_sw(idxday(ij),:) = toa_src_sw(idxday(ij),:)*solcon/ & + sum(toa_src_sw(idxday(ij),:)) enddo endif diff --git a/physics/rrtmgp_sw_gas_optics.meta b/physics/rrtmgp_sw_gas_optics.meta index 1ec914d63..7ee8e9edc 100644 --- a/physics/rrtmgp_sw_gas_optics.meta +++ b/physics/rrtmgp_sw_gas_optics.meta @@ -79,14 +79,6 @@ type = GFS_control_type intent = in optional = F -[Interstitial] - standard_name = GFS_interstitial_type_instance - long_name = derived type GFS_interstitial_type in FV3 - units = DDT - dimensions = () - type = GFS_interstitial_type - intent = inout - optional = F [sw_gas_props] standard_name = coefficients_for_sw_gas_optics long_name = DDT containing spectral information for RRTMGP SW radiation scheme @@ -119,6 +111,15 @@ type = integer intent = in optional = F +[toa_src_sw] + standard_name = toa_incident_sw_flux_by_spectral_point + long_name = TOA shortwave incident flux at each spectral points + units = W m-2 + dimensions = (horizontal_dimension,number_of_sw_spectral_points_rrtmgp) + type = real + kind = kind_phys + intent = out + optional = F [p_lay] standard_name = air_pressure_at_layer_for_RRTMGP_in_hPa long_name = air pressure layer diff --git a/physics/rrtmgp_sw_rte.F90 b/physics/rrtmgp_sw_rte.F90 index a88f4eda9..4a612ccce 100644 --- a/physics/rrtmgp_sw_rte.F90 +++ b/physics/rrtmgp_sw_rte.F90 @@ -93,6 +93,8 @@ subroutine rrtmgp_sw_rte_run(Model, Radtend, Statein, ncol, sw_gas_props, p_lay, ! visdf - downward uv+vis diffused flux (W/m2) ! Local variables + real(kind_phys), dimension(sw_gas_props%get_nband(),nday) :: & + sfc_alb_dir,sfc_alb_dif type(ty_fluxes_byband) :: & flux_allsky, & ! All-sky flux (W/m2) flux_clrsky ! Clear-sky flux (W/m2) @@ -154,6 +156,10 @@ subroutine rrtmgp_sw_rte_run(Model, Radtend, Statein, ncol, sw_gas_props, p_lay, flux_clrsky%bnd_flux_up => fluxSW_up_clrsky flux_clrsky%bnd_flux_dn => fluxSW_dn_clrsky + ! In RRTMG, the near-IR and uv-visible surface albedos are averaged. + sfc_alb_dir = 0.5_kind_phys*(sfc_alb_nir_dir(:,idxday(1:nday)) + sfc_alb_uvvis_dir(:,idxday(1:nday))) + sfc_alb_dif = 0.5_kind_phys*(sfc_alb_nir_dif(:,idxday(1:nday)) + sfc_alb_uvvis_dif(:,idxday(1:nday))) + ! Compute clear-sky fluxes (if requested) ! Clear-sky fluxes (gas+aerosol) call check_error_msg('rrtmgp_sw_rte_run',sw_optical_props_aerosol%increment(sw_optical_props_clrsky)) @@ -165,8 +171,8 @@ subroutine rrtmgp_sw_rte_run(Model, Radtend, Statein, ncol, sw_gas_props, p_lay, top_at_1, & ! IN - veritcal ordering flag Radtend%coszen(idxday(1:nday)), & ! IN - Cosine of solar zenith angle toa_src_sw(idxday(1:nday),:), & ! IN - incident solar flux at TOA - sfc_alb_nir_dir(:,idxday(1:nday)), & ! IN - Shortwave surface albedo (direct) - sfc_alb_nir_dif(:,idxday(1:nday)), & ! IN - Shortwave surface albedo (diffuse) + sfc_alb_dir, & ! IN - Shortwave surface albedo (direct) + sfc_alb_dif, & ! IN - Shortwave surface albedo (diffuse) flux_clrsky)) ! OUT - Fluxes, clear-sky, 3D (nCol,Model%levs,nBand) ! Store fluxes fluxswUP_clrsky(idxday(1:nday),:) = sum(flux_clrsky%bnd_flux_up,dim=3) @@ -183,8 +189,8 @@ subroutine rrtmgp_sw_rte_run(Model, Radtend, Statein, ncol, sw_gas_props, p_lay, top_at_1, & ! IN - veritcal ordering flag Radtend%coszen(idxday(1:nday)), & ! IN - Cosine of solar zenith angle toa_src_sw(idxday(1:nday),:), & ! IN - incident solar flux at TOA - sfc_alb_nir_dir(:,idxday(1:nday)), & ! IN - Shortwave surface albedo (direct) - sfc_alb_nir_dif(:,idxday(1:nday)), & ! IN - Shortwave surface albedo (diffuse) + sfc_alb_dir, & ! IN - Shortwave surface albedo (direct) + sfc_alb_dif, & ! IN - Shortwave surface albedo (diffuse) flux_allsky)) ! OUT - Fluxes, clear-sky, 3D (nCol,Model%levs,nBand) ! Store fluxes fluxswUP_allsky(idxday(1:nday),:) = sum(flux_allsky%bnd_flux_up,dim=3) diff --git a/physics/rrtmgp_sw_rte.meta b/physics/rrtmgp_sw_rte.meta index 2509cf0c6..81575e6f4 100644 --- a/physics/rrtmgp_sw_rte.meta +++ b/physics/rrtmgp_sw_rte.meta @@ -138,7 +138,7 @@ optional = F [toa_src_sw] standard_name = toa_incident_sw_flux_by_spectral_point - long_name = TOA shortwave incident flux at each spectral points (Radtend%toa_src_sw) + long_name = TOA shortwave incident flux at each spectral points units = W m-2 dimensions = (horizontal_dimension,number_of_sw_spectral_points_rrtmgp) type = real