Skip to content

Commit 310e962

Browse files
committed
Merge branch 'bugfix_t2tv' into hotfix-v7.1 (PR #829)
When calculating moist air density in the real-data initialization case, virtual temperature, rather than temperature, should be used: Tv = T * ((1 - qv) + Rv/Rd * qv) = T * (1 + (Rv/Rd - 1) * qv)
2 parents b62a763 + 6e1401b commit 310e962

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/core_init_atmosphere/mpas_init_atm_cases.F

+2-1
Original file line numberDiff line numberDiff line change
@@ -4773,7 +4773,8 @@ subroutine init_atm_case_gfs(block, mesh, nCells, nEdges, nVertLevels, fg, state
47734773
t(k,iCell) = t(k,iCell) * (p0 / pressure(k,iCell)) ** (rgas / cp)
47744774
47754775
! RHO_ZZ
4776-
rho_zz(k,iCell) = pressure(k,iCell) / rgas / (p(k,iCell) * t(k,iCell))
4776+
rho_zz(k,iCell) = pressure(k,iCell) / rgas / (p(k,iCell) * t(k,iCell) &
4777+
* (1.0 + (rvord - 1.0) * scalars(index_qv,k,iCell)))
47774778
rho_zz(k,iCell) = rho_zz(k,iCell) / (1.0 + scalars(index_qv,k,iCell))
47784779
end do
47794780
end do

0 commit comments

Comments
 (0)