Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make surface emissivity over water a persistent variable #434

Merged
6 changes: 3 additions & 3 deletions ccpp/data/GFS_typedefs.F90
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,7 @@ module GFS_typedefs
real (kind=kind_phys), pointer :: sfalb_ice (:) => null() !< surface albedo over ice for LSM
real (kind=kind_phys), pointer :: emis_lnd (:) => null() !< surface emissivity over land for LSM
real (kind=kind_phys), pointer :: emis_ice (:) => null() !< surface emissivity over ice for LSM
real (kind=kind_phys), pointer :: emis_wat (:) => null() !< surface emissivity over water
real (kind=kind_phys), pointer :: sfalb_lnd_bck (:) => null() !< snow-free albedo over land

!--- In (radiation only)
Expand Down Expand Up @@ -2020,7 +2021,6 @@ module GFS_typedefs
real (kind=kind_phys), pointer :: save_v(:,:) => null() !<
real (kind=kind_phys), pointer :: sbsno(:) => null() !<
type (cmpfsw_type), pointer :: scmpsw(:) => null() !<
real (kind=kind_phys), pointer :: semis_water(:) => null() !<
real (kind=kind_phys), pointer :: sfcalb(:,:) => null() !<
real (kind=kind_phys), pointer :: sigma(:) => null() !<
real (kind=kind_phys), pointer :: sigmaf(:) => null() !<
Expand Down Expand Up @@ -2335,6 +2335,7 @@ subroutine sfcprop_create (Sfcprop, IM, Model)
allocate(Sfcprop%albdifnir_lnd (IM))
allocate (Sfcprop%emis_lnd (IM))
allocate (Sfcprop%emis_ice (IM))
allocate (Sfcprop%emis_wat (IM))

Sfcprop%slmsk = clear_val
Sfcprop%oceanfrac = clear_val
Expand Down Expand Up @@ -2364,6 +2365,7 @@ subroutine sfcprop_create (Sfcprop, IM, Model)
Sfcprop%albdifnir_lnd = clear_val
Sfcprop%emis_lnd = clear_val
Sfcprop%emis_ice = clear_val
Sfcprop%emis_wat = clear_val

!--- In (radiation only)
allocate (Sfcprop%snoalb (IM))
Expand Down Expand Up @@ -7098,7 +7100,6 @@ subroutine interstitial_create (Interstitial, IM, Model)
allocate (Interstitial%save_v (IM,Model%levs))
allocate (Interstitial%sbsno (IM))
allocate (Interstitial%scmpsw (IM))
allocate (Interstitial%semis_water (IM))
allocate (Interstitial%sfcalb (IM,NF_ALBD))
allocate (Interstitial%sigma (IM))
allocate (Interstitial%sigmaf (IM))
Expand Down Expand Up @@ -7776,7 +7777,6 @@ subroutine interstitial_phys_reset (Interstitial, Model)
Interstitial%save_u = clear_val
Interstitial%save_v = clear_val
Interstitial%sbsno = clear_val
Interstitial%semis_water = clear_val
Interstitial%sigma = clear_val
Interstitial%sigmaf = clear_val
Interstitial%sigmafrac = clear_val
Expand Down
15 changes: 7 additions & 8 deletions ccpp/data/GFS_typedefs.meta
Original file line number Diff line number Diff line change
Expand Up @@ -671,7 +671,13 @@
dimensions = (horizontal_loop_extent)
type = real
kind = kind_phys
active = (control_for_land_surface_scheme == identifier_for_ruc_land_surface_scheme)
[emis_wat]
standard_name = surface_longwave_emissivity_over_water
long_name = surface lw emissivity in fraction over water
units = frac
dimensions = (horizontal_loop_extent)
type = real
kind = kind_phys
[sfalb_lnd]
standard_name = surface_diffused_shortwave_albedo_over_land
long_name = mean surface diffused sw albedo over land
Expand Down Expand Up @@ -8149,13 +8155,6 @@
dimensions = (horizontal_loop_extent)
type = real
kind = kind_phys
[semis_water]
standard_name = surface_longwave_emissivity_over_water
long_name = surface lw emissivity in fraction over water
units = frac
dimensions = (horizontal_loop_extent)
type = real
kind = kind_phys
[ep1d]
standard_name = surface_upward_potential_latent_heat_flux
long_name = surface upward potential latent heat flux
Expand Down
2 changes: 1 addition & 1 deletion ccpp/physics
Submodule physics updated 1 files
+2 −11 physics/GFS_debug.F90
28 changes: 25 additions & 3 deletions io/module_wrt_grid_comp.F90
Original file line number Diff line number Diff line change
Expand Up @@ -537,17 +537,39 @@ subroutine wrt_initialize(wrt_comp, imp_state_write, exp_state_write, clock, rc)
endif
wrt_int_state%latstart = lat(1)
wrt_int_state%latlast = lat(jmo)
do j=1,imo
lon(j) = 360.d0/real(imo,8) *real(j-1,8)
do i=1,imo
lon(i) = 360.d0/real(imo,8) *real(i-1,8)
enddo
wrt_int_state%lonstart = lon(1)
wrt_int_state%lonlast = lon(imo)
do j=lbound(latPtr,2),ubound(latPtr,2)
do i=lbound(lonPtr,1),ubound(lonPtr,1)
lonPtr(i,j) = 360.d0/real(imo,8) * real(i-1,8)
lonPtr(i,j) = lon(i)
latPtr(i,j) = lat(j)
enddo
enddo
wrt_int_state%lat_start = lbound(latPtr,2)
wrt_int_state%lat_end = ubound(latPtr,2)
wrt_int_state%lon_start = lbound(lonPtr,1)
wrt_int_state%lon_end = ubound(lonPtr,1)
allocate( wrt_int_state%lat_start_wrtgrp(wrt_int_state%petcount))
allocate( wrt_int_state%lat_end_wrtgrp (wrt_int_state%petcount))
call mpi_allgather(wrt_int_state%lat_start,1,MPI_INTEGER, &
wrt_int_state%lat_start_wrtgrp, 1, MPI_INTEGER, wrt_mpi_comm, rc)
call mpi_allgather(wrt_int_state%lat_end, 1,MPI_INTEGER, &
wrt_int_state%lat_end_wrtgrp, 1, MPI_INTEGER, wrt_mpi_comm, rc)
if( lprnt ) print *,'aft wrtgrd, latlon, dimj_start=',wrt_int_state%lat_start_wrtgrp, &
'dimj_end=',wrt_int_state%lat_end_wrtgrp, 'wrt_group=',n_group
allocate( wrt_int_state%latPtr(wrt_int_state%lon_start:wrt_int_state%lon_end, &
wrt_int_state%lat_start:wrt_int_state%lat_end))
allocate( wrt_int_state%lonPtr(wrt_int_state%lon_start:wrt_int_state%lon_end, &
wrt_int_state%lat_start:wrt_int_state%lat_end))
do j=wrt_int_state%lat_start,wrt_int_state%lat_end
do i=wrt_int_state%lon_start,wrt_int_state%lon_end
wrt_int_state%latPtr(i,j) = latPtr(i,j)
wrt_int_state%lonPtr(i,j) = lonPtr(i,j)
enddo
enddo
wrt_int_state%im = imo
wrt_int_state%jm = jmo
wrt_int_state%post_maptype = 0
Expand Down