Skip to content

Now sum DELPDRY in the vertical instead of averaging it when regridding from 72 -> 47 layers#349

Merged
yantosca merged 1 commit intodev/3.12.0from
bugfix/met-delpdry-vert-regrid
Jan 21, 2026
Merged

Now sum DELPDRY in the vertical instead of averaging it when regridding from 72 -> 47 layers#349
yantosca merged 1 commit intodev/3.12.0from
bugfix/met-delpdry-vert-regrid

Conversation

@yantosca
Copy link
Contributor

@yantosca yantosca commented Jan 20, 2026

Name and Institution (Required)

Name: Bob Yantosca (Harvard) and Lee Murray (Rochester)

Describe the update

This is the companion PR to geoschem/geos-chem#3170, in which @ltmurray found that Met_DELPDRY field was being vertically averaged instead of summed during regridding from 72 -> 47 layers. This led to an incorrect initialization of the stratosphere.

Expected changes

delpdry

The figure above shows stratospheric zonal means for ozone taken from a 72-layer restart file (left), ozone concentrations with the incorrectly-initialized stratosphere (center), and ozone concentrations with the fix in this PR having been applied (right). As you can see, the fixed ozone concentrations in the right panel closely matches the ozone from the 72 layer restart file.

Related Github Issue

src/Core/hco_interp_mod.F90
- Added logical variable do_sum, which is set to T if "DELPDRY" is
  found in the variable name, or F otherwise
- Pass do_sum as the 8th argument to routine COLLAPSE
- In routine COLLAPSE, set the averaging weights (WGT) to 1 for all
  levels if do_sum = T.  This will sum the variable in the vertical
  rather than average it.

CHANGELOG.md
- Updated accordingly

Signed-off-by: Bob Yantosca <yantosca@seas.harvard.edu>
@yantosca yantosca added this to the 3.12.0 milestone Jan 20, 2026
@yantosca yantosca self-assigned this Jan 20, 2026
@yantosca yantosca added topic: Regridding or Interpolation Related to issues with time interpolation or horiziontal/vertical regridding category: Bug Fix Fixes a bug that was previously reported labels Jan 20, 2026
@yantosca yantosca changed the title Now sum DELPDRY in the vertical instead of averaging it Now sum DELPDRY in the vertical instead of averaging it when regridding from 72 -> 47 layers Jan 20, 2026
@yantosca
Copy link
Contributor Author

Integration tests are running

@yantosca
Copy link
Contributor Author

All GEOS-Chem Classic integration tests passed:

==============================================================================
GEOS-Chem Classic: Execution Test Results

CodeDir   : 4bddc5b GEOS-Chem & HEMCO updates: Merge PR #2946 & PR #336 (7 dust bins )
GEOS-Chem : d65b73ff5 Merge PR #2946 (Add 7 dust bins in GEOS-Chem)
HEMCO     : 4def204 Now sum DELPDRY in the vertical instead of averaging it
Cloud-J   : 1dff6fe Merge pull request #31 from geoschem/release/8.0.2
HETP      : 2a99b24 Merge pull request #2 from geoschem/bugfix/initialize_local_variables

Using 24 OpenMP threads
Number of execution tests: 38

Submitted as SLURM job: 56094459
==============================================================================

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%  All execution tests passed!  %%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

All GEOS-Chem Classic tests were zero-diff w/r/t 14.7.0-rc.0 except

  • gc_4x5_merra2_fullchem_APM
    • Expected diffs (parallelization error)
  • The updates in this PR caused expected diffs in:
    • gc_05x0625_NA_47L_merra2_fullchem
    • gc_4x5_47L_merra2_fullchem
    • gc_4x5_47L_merra2_fullchem_TOMAS15

@yantosca
Copy link
Contributor Author

All GCHP integration tests passed:

==============================================================================
GCHP: Execution Test Results

CodeDir       : eb66a42 GEOS-Chem & HEMCO updates: Merge PR #2946 & PR #336 (7 dust bins )
MAPL          : d1d528e5 Merge pull request #39 from geoschem/feature/mapl_2.55.0
GMAO_Shared   : 4ddb3ec Merge pull request #2 from geoschem/feature/mapl-upgrade
ESMA_cmake    : bd401dc Merge pull request #8 from yuanjianz/gchp/main
FMS           : 259759d1 Merge pull request #3 from geoschem/feature/update_gmao_libs
FVdycoreCubed : 348620f Merge PR #11 (Scale tracers by pressure ratio in first timestep)
geos-chem     : d65b73ff5 Merge PR #2946 (Add 7 dust bins in GEOS-Chem)
HEMCO         : 4def204 Now sum DELPDRY in the vertical instead of averaging it
Cloud-J       : 1dff6fe Merge pull request #31 from geoschem/release/8.0.2
HETP          : 2a99b24 Merge pull request #2 from geoschem/bugfix/initialize_local_variables
GFE           : bac529f Merge pull request #40 from Goddard-Fortran-Ecosystem/feature/mathomp4/update-gftl-1.15.2

Number of execution tests: 12

Submitted as SLURM job: 56116714
==============================================================================

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%  All execution tests passed!  %%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

All tests were zero-diff w/r/t gchp.14.7.0-alpha.17.

@yantosca yantosca requested a review from msulprizio January 21, 2026 16:02
@yantosca yantosca marked this pull request as ready for review January 21, 2026 16:02
Copy link
Contributor

@lizziel lizziel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to merge

@yantosca yantosca merged commit 16b499b into dev/3.12.0 Jan 21, 2026
12 of 14 checks passed
@yantosca yantosca deleted the bugfix/met-delpdry-vert-regrid branch January 21, 2026 19:02
@lizziel
Copy link
Contributor

lizziel commented Jan 21, 2026

One thing that pops out about the implementation we have (not the fix) is the verbose messages we have within ModelLev_Interpolate here and here. The message is:

Pressure-weighted vertical regridding was done - consider if this is appropriate for the variable units.

This bug crept in because this message was buried, and required looking closely at the log even if verbose was on. A robust solution would be to check the units, not the variable name, when determining whether do_sum is true, and also add a message if a variable is summed rather than pressure-weighted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

category: Bug Fix Fixes a bug that was previously reported topic: Regridding or Interpolation Related to issues with time interpolation or horiziontal/vertical regridding

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error in initializing stratosphere in 47-layer version of GCClassic leads to large photochemical errors in 14.6.*

3 participants