Skip to content

Implement CCPPized MCSP parameterization - #1719

Open
jimmielin wants to merge 10 commits into
ESCOMP:cam_developmentfrom
jimmielin:hplin/mcsp
Open

jimmielin wants to merge 10 commits into
ESCOMP:cam_developmentfrom
jimmielin:hplin/mcsp

Conversation

@jimmielin

@jimmielin jimmielin commented Oct 13, 2026 •

Copy link
Copy Markdown
Collaborator

Closes #603
Closes #1474

Based off original PR #1632 from Jack Chen et al. now code fully CCPPized and moved to atmospheric_physics.

Companion PR ESCOMP/atmospheric_physics#453

hplin-ucar and others added 7 commits October 13, 2026 17:34
Verbatim copy of ESCOMP/CAM PR ESCOMP#1632 (chihchen24/CAM commits d7c57b7
"MCSP added" and 6542168 "MCSP mods added"), rebased onto
cam_development at cam6_4_206. The atmos_phys submodule bump in that PR
(36a6608) is not carried over; the MCSP sources are taken from the copies
the PR placed under src/physics/cam.

Imported unchanged as the baseline for the release cleanup that follows in
this branch: decoupling from zm_conv_intr, thread safety, namelist and
metadata cleanup, and moving the portable scheme to atmospheric_physics.

Co-authored-by: Jack Chen <cchen@ucar.edu>
Replaces the imported wiring with a CAM interface, mcsp_cam.F90, around
the portable scheme now compiled from src/atmos_phys/schemes/mcsp (the
copies under src/physics/cam are removed; bld/configure gains the
Filepath entry).

- The module-level arrays ttend_s (zm_conv_intr) and jctop1
  (convect_deep) are gone; they were written per chunk and read later in
  tphysbc, a race under OpenMP. MCSP now reads CLDTOP and two new pbuf
  fields, TTEND_DP_CORE and QTEND_DP_CORE, holding the core ZM heating
  and moistening (after zm_convr_run, before precipitation evaporation
  and momentum transport), which is what E3SM feeds MCSP. mcsp_cam
  registers the two fields only when MCSP is active and zm_conv_intr
  fills them when they exist, so ZM has no compile-time dependency on
  MCSP.
  The imported branch fed MCSP the core heating but the full
  convect_deep water vapor tendency (including evaporation); both are
  now core-only, matching E3SM.
- MCSP is active only when a coefficient in mcsp_nl is positive; when
  inactive nothing is registered or called, so answers are unchanged.
  It requires deep_scheme = ZM.
- MCSP runs as its own tphysbc block after the deep convection energy
  check, with snapshot points (mcsp_cam_tend) and its own
  check_energy_cam_chng with zero fluxes.
- Namelist ids are lowercase (mcsp_heat_coeff, ...); the MCSP_DU and
  MCSP_DV history units are m/s2 (the values were never per day).

Assisted-by: claude-fable:5.1
Comment thread .gitmodules
path = src/atmos_phys
url = https://github.com/ESCOMP/atmospheric_physics
fxtag = atmos_phys0_31_000
url = https://github.com/jimmielin/atmospheric_physics

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Just a reminder that this needs to be updated before we assign a tag

Comment thread src/physics/cam/zm_conv_intr.F90 Outdated
Comment thread src/physics/cam/zm_conv_intr.F90 Outdated
Comment thread src/physics/cam/zm_conv_intr.F90 Outdated
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

3 participants