-
Notifications
You must be signed in to change notification settings - Fork 700
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix vertical indices of c1h and c2h in ideal case init of ph_1 #1280
Conversation
TYPE: bug fix KEYWORDS: ideal case, initialization SOURCE: Tim Raupach (UNSW CCRC) DESCRIPTION OF CHANGES: Problem: In ideal case initialization routines, incorrect indices were used in the calculation of ph_1 after a perturbation bubble was added. Solution: The indices were corrected in the calculations of ph_1. ISSUE: LIST OF MODIFIED FILES: M dyn_em/module_initialize_ideal.F TESTS CONDUCTED: None. RELEASE NOTE: Fixed incorrect vertical indices in ideal case initialization of ph_1.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with this change.
My understanding is that this won't affect results unless the hybrid option is used which is off by default for these cases. Can the PR proposer confirm this and add some text in the PR on the impact? Thanks. |
Yes, hybrid_opt = 0 for these cases by default. When the hybrid option is off, only the top-most model level is affected by the incorrect indices. For vertical indices 1 to kde-1, c1h is set to 1 and c2h is set to 0 on lines 875 and 876 of module_initialize_ideal.F. However ph_1 is calculated for vertical indices k=2 to k=kte, and with the incorrect vertical indices c1h(kte) and c2h(kte) are used in the calculation of ph_1 for the top-most level (since kte == kde). c1h(kte) and c2h(kte) are unmodified by module_initialize_ideal.F and are both set to 0 (or possibly uninitialized?). I've added a note about the impact in the PR. |
Thanks fro including the impact in the PR message. Looks fine to me. |
@traupach |
Please find result of the WRF regression test cases in the attachment. This build is for Commit ID: 17f29b2, requested by: traupach for PR: #1280. For any query please send e-mail to David Gill.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree with this change.
@traupach You are now officially a WRF contributor. |
TYPE: bug fix
KEYWORDS: ideal case, initialization
SOURCE: Tim Raupach (UNSW CCRC)
DESCRIPTION OF CHANGES:
Problem:
In ideal case initialization routines, incorrect indices were used in the calculation of ph_1 after a perturbation bubble was added.
Impact:
The calculation of perturbation geopotential ph_1 (perturbation geopotential) and Z_BASE (idealized base state height)
were affected.
in the indexing of c1h and c2h (half levels vs full levels).
Solution:
The vertical indices were corrected in the calculations of ph_1 in the idealized initialization routine.
ISSUE:
LIST OF MODIFIED FILES:
M dyn_em/module_initialize_ideal.F
TESTS CONDUCTED:
RELEASE NOTE: In the ideal case initialization routines, incorrect indices were used in the calculation of ph_1 after a perturbation bubble was added. For the idealized cases that do not use the hybrid vertical coordinate by default, there is no impact at all. The ideal cases with a hill had the correct hybrid formulation.