Skip to content

Commit

Permalink
more updates for vegtype
Browse files Browse the repository at this point in the history
  • Loading branch information
bbakernoaa committed Nov 22, 2024
1 parent 64075a1 commit d68cb4b
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion atmos_model.F90
Original file line number Diff line number Diff line change
Expand Up @@ -1342,7 +1342,7 @@ subroutine update_atmos_chemistry(state, rc)
real(ESMF_KIND_R8), dimension(:,:), pointer :: aod, area, canopy, cmm, &
dqsfc, dtsfc, fice, flake, focn, fsnow, hpbl, nswsfc, oro, psfc, &
q2m, rain, rainc, rca, shfsfc, slmsk, stype, swet, t2m, tsfc, &
u10m, uustar, v10m, vfrac, xlai, zorl, vtype, nvegcat, fvtype
u10m, uustar, v10m, vfrac, xlai, zorl, vtype

! logical, parameter :: diag = .true.

Expand Down Expand Up @@ -1600,6 +1600,10 @@ subroutine update_atmos_chemistry(state, rc)
if (ESMF_LogFoundError(rcToCheck=localrc, msg=ESMF_LOGERR_PASSTHRU, &
line=__LINE__, file=__FILE__, rcToReturn=rc)) return

call cplFieldGet(state,'vegetation_type', farrayPtr2d=vtype, rc=localrc)
if (ESMF_LogFoundError(rcToCheck=localrc, msg=ESMF_LOGERR_PASSTHRU, &
line=__LINE__, file=__FILE__, rcToReturn=rc)) return

else

call cplFieldGet(state,'inst_liq_nonconv_tendency_levels', &
Expand Down Expand Up @@ -1725,6 +1729,7 @@ subroutine update_atmos_chemistry(state, rc)
! stype(i,j) = real(int( GFS_Data(nb)%Sfcprop%stype(ix)+0.5 ), kind=ESMF_KIND_R8)
!endif
stype = real(int(reshape(GFS_Sfcprop%stype, shape(stype))+0.5), kind=ESMF_KIND_R8)
vtype = real(int(reshape(GFS_Sfcprop%vtype, shape(vtype))+0.5), kind=ESMF_KIND_R8)
if (GFS_Control%isot == 1) then
where (slmsk == 2) stype = 16._ESMF_KIND_R8
else
Expand Down Expand Up @@ -1811,6 +1816,7 @@ subroutine update_atmos_chemistry(state, rc)
write(6,'("update_atmos: vfrac - min/max/avg",3g16.6)') minval(vfrac), maxval(vfrac), sum(vfrac)/size(vfrac)
write(6,'("update_atmos: xlai - min/max/avg",3g16.6)') minval(xlai), maxval(xlai), sum(xlai)/size(xlai)
write(6,'("update_atmos: stype - min/max/avg",3g16.6)') minval(stype), maxval(stype), sum(stype)/size(stype)
write(6,'("update_atmos: vtype - min/max/avg",3g16.6)') minval(vtype), maxval(vtype), sum(vtype)/size(vtype)
else
write(6,'("update_atmos: flake - min/max/avg",3g16.6)') minval(flake), maxval(flake), sum(flake)/size(flake)
write(6,'("update_atmos: focn - min/max/avg",3g16.6)') minval(focn), maxval(focn), sum(focn)/size(focn)
Expand Down

0 comments on commit d68cb4b

Please sign in to comment.