Skip to content

Complete CCPPization of CAM5 UW (diag_TKE) PBL scheme; cleanup to vertical_diffusion_tend#1445

Open
jimmielin wants to merge 22 commits into
ESCOMP:cam_developmentfrom
jimmielin:hplin/diag_tke
Open

Complete CCPPization of CAM5 UW (diag_TKE) PBL scheme; cleanup to vertical_diffusion_tend#1445
jimmielin wants to merge 22 commits into
ESCOMP:cam_developmentfrom
jimmielin:hplin/diag_tke

Conversation

@jimmielin
Copy link
Copy Markdown
Member

@jimmielin jimmielin commented Dec 3, 2025

Companion PR: ESCOMP/atmospheric_physics#370

Purpose of changes (include the issue number and title text for each relevant GitHub issue):

Describe any changes made to build system: added bretherton_park folder to atmos_phys

Describe any changes made to the namelist: update to descriptions only.

List any changes to the defaults for the boundary datasets: N/A

Describe any substantial timing or memory changes: None

Code reviewed by:

List all files eliminated:

D       src/physics/cam/eddy_diff.F90
  - moved to atmos_phys

D       src/physics/cam/pbl_utils.F90
  - only remaining subroutine now in atmos_phys bretherton_park_diff.F90

List all files added and what they do:

List all existing files that have been modified, and describe the changes:

M       bld/configure
  - add bretherton_park subdir for atmos_phys

M       bld/namelist_files/namelist_definition.xml
  - fix description

M       src/control/cam_snapshot_common.F90
  - populate units for pbuf_ksrftms, pbuf_WSEDL

M       src/physics/cam/eddy_diff_cam.F90
  - moved most of existing logic in eddy_diff_tend to new CCPP scheme bretherton_park_diff_run
  - what remains is just CAM-specific code for history and code to interface with the underlying run phase.

M       src/physics/cam/vertical_diffusion.F90
  - move kinematic fluxes and obklen calculation to common interstitial scheme.
  - move input preparation (vert coord for vdiff, potential temp) to common interstitial scheme.
  - rearrange data flow for HB, UW to share as much code as possible.

@cacraigucar cacraigucar marked this pull request as draft February 10, 2026 16:23
@jimmielin jimmielin changed the title Phase 1 of UW PBL CCPPization, cleanup to vertical_diffusion_tend Complete CCPPization of CAM5 UW (diag_TKE) PBL scheme; cleanup to vertical_diffusion_tend Mar 9, 2026
Copy link
Copy Markdown
Collaborator

@nusbaume nusbaume left a comment

Choose a reason for hiding this comment

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

Thanks for the necessary CAM updates @jimmielin! I have some comment update requests/questions, but hopefully nothing too difficult.

Comment thread src/physics/cam/eddy_diff_cam.F90 Outdated
Comment thread src/physics/cam/eddy_diff_cam.F90 Outdated
Comment thread src/physics/cam/eddy_diff_cam.F90 Outdated
Comment thread src/physics/cam/vertical_diffusion.F90 Outdated
@jimmielin jimmielin requested a review from nusbaume April 24, 2026 18:36
Copy link
Copy Markdown
Collaborator

@nusbaume nusbaume left a comment

Choose a reason for hiding this comment

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

Thanks @jimmielin! Everything looks good to me now.

@nusbaume nusbaume requested review from peverwhee and removed request for peverwhee April 27, 2026 15:19
Copy link
Copy Markdown
Collaborator

@cacraigucar cacraigucar left a comment

Choose a reason for hiding this comment

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

Need to update atmospheric_physics external

jimmielin added a commit to ESCOMP/atmospheric_physics that referenced this pull request May 19, 2026
Tag name (The PR title should also include the tag name):
Originator(s): @jimmielin 

Companion PR in CAM - ESCOMP/CAM#1445

Description (include issue title and the keyword ['closes', 'fixes',
'resolves'] and issue number):
- Completes #330 - CCPPizes UW PBL scheme (diag_TKE)
- CCPPize UW interstitial to adjust diffusivity above PBL
- Rearranging of interstitials for vertical diffusion, to accommodate
for using either HB or UW PBL: new interstitial for handling Coords1D
and potential temperature; new interstitial for computing kinematic
water vapor flux and Obklen.
- New stub to only zero out Beljaars, not TMS - used for CAM5 snapshot
tests (TMS on, Beljaars off)

List all namelist files that were added or changed:
```
A       schemes/bretherton_park/bretherton_park_diff_namelist.xml
A       schemes/bretherton_park/eddy_diffusivity_adjustment_above_pbl_namelist.xml
  - for UW PBL
```

List all files eliminated and why: N/A

List all files added and what they do:
```
A       schemes/bretherton_park/bretherton_park_diff.F90
A       schemes/bretherton_park/bretherton_park_diff_namelist.xml
  - initial CCPPized subroutines for UW PBL

A       schemes/bretherton_park/eddy_diff.F90
  - moved from CAM (main driver module for UW PBL)

A       schemes/bretherton_park/eddy_diffusivity_adjustment_above_pbl.F90
A       schemes/bretherton_park/eddy_diffusivity_adjustment_above_pbl.meta
A       schemes/bretherton_park/eddy_diffusivity_adjustment_above_pbl_namelist.xml
  - mini-scheme used by the end of UW PBL

A       schemes/vertical_diffusion/vertical_diffusion_interstitials.F90
A       schemes/vertical_diffusion/vertical_diffusion_interstitials.meta
  - new interstitial for common vertical diffusion schemes
  - new interstitial for computing kinematic fluxes and Obukhov length

A       test/test_suites/suite_vdiff_bretherton_park.xml
  - SDF file

A       schemes/sima_diagnostics/bretherton_park_diff_diagnostics.F90
A       schemes/sima_diagnostics/bretherton_park_diff_diagnostics.meta
  - diagnostics for UW PBL
```

List all existing files that have been modified, and describe the
changes:
(Helpful git command: `git diff --name-status
development...<your_branch_name>`)
```
M       schemes/holtslag_boville/holtslag_boville_diff.F90
M       schemes/holtslag_boville/holtslag_boville_diff.meta
M       schemes/holtslag_boville/holtslag_boville_diff_interstitials.F90
M       schemes/holtslag_boville/holtslag_boville_diff_interstitials.meta
  - rearrange interstitials

M       schemes/sima_diagnostics/diffusion_solver_diagnostics.F90
  - comment update to clarify which surface stress is used here

M       schemes/vertical_diffusion/diffusion_solver.F90
M       schemes/vertical_diffusion/diffusion_solver.meta
  - init phase: changes for dropmixnuc (ndrop vertical mixing)-handled species to skip diffusion solver for tracers

M       schemes/vertical_diffusion/diffusion_stubs.F90
M       schemes/vertical_diffusion/diffusion_stubs.meta
  - new stub to only zero out Beljaars, not TMS
  - new stub for handling surface fluxes for dropmixnuc (ndrop vertical mixing)-handled species

M       suites/suite_cam4.xml
M       test/test_suites/suite_vdiff_holtslag_boville.xml
  - rearrange interstitials

M       schemes/sima_diagnostics/diffusion_solver_diagnostics.F90
M       schemes/sima_diagnostics/diffusion_solver_diagnostics.meta
  - standard name update for clarity
```

List all automated tests that failed, as well as an explanation for why
they weren't fixed:

Is this an answer-changing PR? If so, is it a new physics package,
algorithm change, tuning change, etc?

If yes to the above question, describe how this code was validated with
the new/modified features:

---------

Co-authored-by: Jesse Nusbaumer <nusbaume@ucar.edu>
@jimmielin jimmielin requested a review from cacraigucar May 19, 2026 21:05
@jimmielin
Copy link
Copy Markdown
Member Author

Thanks @cacraigucar - now updated to atmos_phys0_22_000. It's ready to wait for a tag

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

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

3 participants