Fixes for PUMAS bfb with QPC7 and FHISTC_LTso CAM snapshot - #1
Conversation
Assisted-by: claude-opus:4.8[1m]
|
My My https://github.com/jimmielin/CAM-SIMA/blob/hplin/temp_pumas/src/data/registry.xml My CAM-SIMA code |
| ! PUMAS uses total stratiform fraction for both liquid and ice stratus. | ||
| ! Mirrors CAM micro_pumas_cam.F90: alst_mic => ast; aist_mic => ast. | ||
| pumas_strat_liq_cldfrc(:ncol,:) = real(strat_cldfrc_in(:,:), pumas_r8) | ||
| pumas_strat_ice_cldfrc(:ncol,:) = real(strat_cldfrc_in(:,:), pumas_r8) |
There was a problem hiding this comment.
Thanks for finding this one. That was a tricky one!
| pumas_naai(:,:) = 0._pumas_r8 | ||
| pumas_npccn(:,:) = 0._pumas_r8 | ||
| pumas_qsatfac(:,:) = 0._pumas_r8 | ||
| pumas_frzimm(:ncol,:) = real(frzimm_in(:,:), pumas_r8) |
There was a problem hiding this comment.
Why did you get rid of these variables being set to zero? I seem to remember needing to do that a while back for a reason.
There was a problem hiding this comment.
NAAI, NPCCN, and QSATFAC are required inputs passed in from microp_aero into PUMAS.
The first two don't matter for QPC7 but matter for FHISTC_LTso. They're NaNs in QPC7 but that appears to be fine.
QSATFAC's default value is 1, not 0, so if set to 0 here it will certainly introduce answer differences. See micro_pumas_cam.F90 in cam7:
! The null value for qsatfac is 1, not zero
qsatfac(:ncol,:top_lev-1) = 1._r8There was a problem hiding this comment.
When I get to the diagnostic's step, will the NAAI and NPCCN need to have values if they are written out. I wish I could remember why I needed to add these.
There was a problem hiding this comment.
I think they are inputs to PUMAS so there's no diagnostic output for NAAI and NPCCN. I don't think microp_aero writes them out either, but I can add that in my PR.
Before I lose this in the terminal scrollback, here's the dropsonde output without the fix: it can be seen that SIMA has all these set to zeroes but CAM has values being read in from the snapshot:
[INPUTS DIFFER] micro_pumas_ccpp [step 1] (hit 0) arg pumas_qsatfac: 28188/28188 elements differ, max |diff| 1.000e+00 at (1,1): sima=0 cam=1
[INPUTS DIFFER] micro_pumas_ccpp [step 1] (hit 0) arg pumas_naai: 812/28188 elements differ, max |diff| 1.031e+02 at (289,29): sima=0 cam=103.07385026541536
[INPUTS DIFFER] micro_pumas_ccpp [step 1] (hit 0) arg pumas_npccn: 28188/28188 elements differ, max |diff| 3.610e+04 at (208,36): sima=0 cam=-36099.379900846732
There was a problem hiding this comment.
Interestingly, this was the section which impacted the numbers the most.
I brought in two items from my house-of-cards:
hetfrz_classnuc_stubstub - this is so I can setdo_hetfrz_classnucin namelist to true for aFHISTC_LTsosnapshot.clamp_number_concentrationswas updated to remove graupel