geoschem / GCHP

The "superproject" wrapper repository for GCHP, the high-performance instance of the GEOS-Chem chemical-transport model.
https://gchp.readthedocs.io
Other
23 stars 27 forks source link

Opposite sign of UpwardsMassflux diagnostic #455

Open yuanjianz opened 3 weeks ago

yuanjianz commented 3 weeks ago

Your name

Yuanjian Zhang

Your affiliation

WashU

What happened? What did you expect to happen?

UpwardsMassflux currently is positive = "down" instead of intuitively positive = "up".

Evidence from diagnostics

image

UpwardsMassflux diagnostic from a Jan 2019 transport tracer run shows negative values around the equator, which, according to Hadley Circulation, should be upwards.

Evidence from codes

We can derive the mass balance below:

$$Tendency\_of\_Mass\_Above\_Level\_K = BK(k)\times PIT = CONV(k) + UPWARDS\_MFZ(k)$$

where UPWARDS_MFZ is the UPWARDS mass flux, CONV is accumulative horizontal mass flux convergence from top to level k, BK is the hybrid parameter b, PIT is the surface pressure tendency.

FVdycoreCubed_GridComp/FV_StateMod.F90

! Compute the vertical mass flux
!
!   Compute Convergence of the horizontal Mass flux
    do k=1,npz
       do j=jsc,jec
          do i=isc,iec
             conv(i,j,k) = ( xfx(i,j,k) - xfx(i+1,j,k) +  &
                             yfx(i,j,k) - yfx(i,j+1,k) )
          enddo
       enddo
    enddo
!   Surface pressure tendency
    pit(:,:) = 0.0
    do k=1,npz
       do j=jsc,jec
          do i=isc,iec
             pit(i,j) = pit(i,j) + conv(i,j,k)
          enddo
       enddo
    enddo
!   Sum over levels
    do k=2,npz
       do j=jsc,jec
          do i=isc,iec
             conv(i,j,k) = conv(i,j,k) + conv(i,j,k-1)
          enddo
       enddo
    enddo
    mfz(:,:,:) = 0.0
    do k=2,npz
       do j=jsc,jec
          do i=isc,iec
             mfz(i,j,k) = ( conv(i,j,k-1)  - FV_Atm(1)%bk(k)*pit(i,j) )/(MAPL_GRAV*fv_atm(1)%gridstruct%area(i,j))  ! Kg/m^2/s
          enddo
       enddo
    enddo

In the codes above, however, mfz(k) = (conv(k) - bk(k)*pit)*unit_conv, proving mfz here is -upwards_mfz, in other words, downwards_mfz.

https://github.com/geoschem/GCHP/blob/e499969f3831261e1fd15774b9fc68d01d012ba2/src/GCHP_GridComp/GCHPctmEnv_GridComp/GCHPctmEnv_GridCompMod.F90#L956-L957

Here the flipping only converts the GMAO vertical conventions to GEOS-Chem vertical conventions, namely from level 1 being top to level 1 being surface.

lizziel commented 1 week ago

This makes sense. The fix will go into 14.5.1.