Adding Polvani Kushner setup to Isca, including polar heating options by Regan Mudhar - #308
Adding Polvani Kushner setup to Isca, including polar heating options by Regan Mudhar#308sit23 wants to merge 12 commits into
Conversation
Adds namelist options A, B and P_opt controlling an additional zonal-wavenumber jet-latitude forcing term applied to the equilibrium temperature profile, following Garfinkel et al. (2013). Defaults to A=B=0, which leaves teq unchanged from the existing Polvani_Kushner behaviour. Ported from rgnmudhar/Isca_rmudhar polvani_kushner_rm (e.g. commits 717f1bc, f9b2675), curated on top of the 2026 port of Will Seviour's original PK commits.
…ut file Ported from polar_heating()/heat_perturb()/combo_heat1() in rgnmudhar/Isca_rmudhar polvani_kushner_rm:input/input_files.py. Rather than committing the generated binary NetCDF (following the frierson_dry_heating precedent of generating local heating input files at run time), this generates the field from the repo's existing T42 grid file and ozone climatology file. Verified to reproduce the original committed input/asymmetry/w15a4p600f800g50_q6m2y45l800u200.nc from Isca_rmudhar to within float32 rounding (max relative difference ~5e-7).
era_land_t42.nc was committed locally in Will Seviour's original PK commit, but the test case script actually points at the shared input/land_masks/ copy that already exists on master, so the local copy was dead weight.
…r-2 heating) Ported from rgnmudhar/Isca_rmudhar polvani_kushner_rm:exp/test_cases/polvani_kushner/polvani_kushner_test_case.py (her PK_e0v4z13 configuration: eps=0, vtx_gamma=4, z_ozone=13, t_strat=216.65, T42L60, dt_atmos=240s, sponge on), adapted to: - generate the combined polar + midlatitude wavenumber-2 heating input file on the fly via create_pk_heating_input_file.py rather than requiring a committed binary NetCDF (matching this repo's frierson_dry_heating precedent), using the w15a4p600f800g50_q6m2y45l800u200 combo she generated via combo_heat1()'s defaults - shorten the run loop from her 504-month production length to a 12-month illustrative example, consistent with the other test cases in this repo
Follows the existing pattern (e.g. frierson/frierson_dry_heating) where the more specific name is checked after the general one so it can override input_files/nml_out/codebase_to_use.
Matches the existing frierson_dry_heating/input/*.nc entry - the heating input file is generated at test-case run time (see create_pk_heating_input_file.py), not committed.
|
Here is Claude's description of the P/R: Polvani-Kushner forcing: 2026 portThis branch ( Both original branches predate this:
Regan's branch had manually copied Will's original modifications rather than What's on this branchWill Seviour's PK core (5 commits, cherry-picked, authorship preserved)
Two of Will's original commits were excluded as out of scope: one HPC Regan Mudhar's extensions (2 commits, curated, authorship preserved)Her branch has ~100 commits, but it forked from a
Not ported: her postprocessing/plevel_interpolation workflow scripts and One thing worth noting for review: her tip-of-branch Also note: her version of Test cases (
|
| field | max abs diff | max relative diff |
|---|---|---|
ucomp |
9.5e-7 | 1.1e-7 |
vcomp |
9.5e-7 | 2.6e-7 |
temp |
3.1e-5 | 1.1e-7 |
teq |
3.1e-5 | 9.8e-8 |
local_heating |
3.6e-11 | 5.3e-7 |
ps |
7.8e-3 | 7.8e-8 |
height |
7.8e-3 | 8.7e-8 |
All differences are at or below float32 machine epsilon (~1.2e-7) — i.e. the
port reproduces her original results to within floating-point rounding, not
a meaningful physical difference.
The baseline polvani_kushner_test_case.py (Will's QBO-relaxation
configuration) was also smoke-tested for 2 days and runs without error.
The original Polvani & Kushner (2002) setup has no topography/land contrast and no QBO relaxation - both were extras Will Seviour's original commits added as options but the baseline test case shouldn't default to. Removing the era_land_t42.nc topography input and spectral_init_cond_nml block lets topography_option fall back to its 'flat' default; removing relax_to_qbo/ qbo_amp lets relax_to_qbo fall back to its default of False. Renamed the experiment from polvani_kushner_qbo3 to polvani_kushner_default to match. Smoke-tested for 2 days with no error.
|
Have made some modifications to the PK test script as it included the QBO relaxation and land, neither of which we want for a more vanilla PK test case. Also asked Claude to run trip tests with the following results: Update: baseline test case now matches Polvani & Kushner (2002) exactlyThe original P-K02 setup has no land/topography and no QBO relaxation -
Both options remain available in Update: full trip_test runRan the full 12 of 16 passed bit-identical. Of the 4 "failures":
|
|
So, this looks like it's pretty ready to be merged, with those edits pushed, which I'll do now. |
The Polvani-Kushner setup for a Newtonian-relaxation representation of the stratosphere has been a feature in Isca's branches for many years, but has yet to be incorporated into the master branch. The original code for PK was written by @wseviour, and was subsequently adapted by @rgnmudhar for her paper here:
https://doi.org/10.1029/2023JD040416
Getting this combination of commits into the master is slightly complicated, as I wanted to preserve as much of the history as possible, despite the original PK modifications being on Will's fork and the subsequent additions being on Regan's I've therefore asked Claude to pull these things together and create two new test cases for Isca:
Claude has verified that setup 2 produces the same results as the same experiments on Regan's fork - https://github.com/rgnmudhar/Isca_rmudhar/tree/polvani_kushner_rm.
Now going to run the trip tests to check this hasn't broken anything else, then will merge in.