From ce03b796b16e00734010eab210673919a7badb1d Mon Sep 17 00:00:00 2001 From: hertneky <39317287+hertneky@users.noreply.github.com> Date: Sat, 18 Jan 2020 18:45:48 -0700 Subject: [PATCH] Develop mods 20200114 (#50) * Fix ID index in WRF-CHEM SMOKE block, which currently causes failed build in debug mode * Propose fix for filling a handful of 2d variables currently causing a divide-by-zero error when run in debug mode. Currently filled with 'k' which fills with zeros Needs to fill with 'll' which is what's being filled within the larger loop and different index value than 'k' Co-authored-by: WenMeng-NOAA <48260754+WenMeng-NOAA@users.noreply.github.com> --- sorc/ncep_post.fd/INITPOST_GFS_NEMS_MPIIO.f | 12 ++++++------ sorc/ncep_post.fd/MDL2P.f | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/sorc/ncep_post.fd/INITPOST_GFS_NEMS_MPIIO.f b/sorc/ncep_post.fd/INITPOST_GFS_NEMS_MPIIO.f index 104eee42b3..7f7153cca0 100644 --- a/sorc/ncep_post.fd/INITPOST_GFS_NEMS_MPIIO.f +++ b/sorc/ncep_post.fd/INITPOST_GFS_NEMS_MPIIO.f @@ -987,12 +987,12 @@ SUBROUTINE INITPOST_GFS_NEMS_MPIIO(iostatusAER) do j=jsta,jend do k=1,lm do i=1,im - p2d(i,k) = pmid(i,j,k)*0.01 - t2d(i,k) = t(i,j,k) - q2d(i,k) = q(i,j,k) - cw2d(i,k) = cwm(i,j,k) - es = min(fpvsnew(t(i,j,k)),pmid(i,j,k)) - qs2d(i,k) = eps*es/(pmid(i,j,k)+epsm1*es)!saturation q for GFS + p2d(i,k) = pmid(i,j,ll)*0.01 + t2d(i,k) = t(i,j,ll) + q2d(i,k) = q(i,j,ll) + cw2d(i,k) = cwm(i,j,ll) + es = min(fpvsnew(t(i,j,ll)),pmid(i,j,ll)) + qs2d(i,k) = eps*es/(pmid(i,j,ll)+epsm1*es)!saturation q for GFS enddo enddo call progcld1 & diff --git a/sorc/ncep_post.fd/MDL2P.f b/sorc/ncep_post.fd/MDL2P.f index 76e929114b..3f4ce004ab 100644 --- a/sorc/ncep_post.fd/MDL2P.f +++ b/sorc/ncep_post.fd/MDL2P.f @@ -2092,7 +2092,7 @@ SUBROUTINE MDL2P(iostatusD3D) if(grib == 'grib1')then ID(1:25)=0 ID(02)=141 ! Parameter Table 141 - !ID(36)=2 + CALL GRIBIT(IGET(738),LP,GRID1,IM,JM) elseif(grib == 'grib2') then cfld = cfld + 1