-
Notifications
You must be signed in to change notification settings - Fork 5
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
Add consistent environmental buoyancy gradients using mean fields and quadratures. #405
Conversation
5b00de8
to
fadf69f
Compare
For the MSE, I will wait until we decide whether we want to keep |
7a01f50
to
b7772ce
Compare
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.
Looks great to me!
My only comments are about the notation. I would vote for:
- using some abbreviation of saturated/unsaturated instead of cloud/dry
- agreeing on some convention about the thetas so we don't confuse ourselves later. Maybe something like \theta, \theta_v, \theta_liq_ice
But if the others disagree, we can keep the notation we used. Don't want to block this PR
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.
LGTM
bors r+ |
Build succeeded: |
449: Bump version for new release r=charleskawczynski a=charleskawczynski Co-authored-by: Charles Kawczynski <[email protected]>
This PR modifies the
buoyancy_gradients
closure and the struct used to compute them in the following ways:buoyancy_gradients
are modified to be the buoyancy gradients in the environment, and its dry and cloudy parts. Before, a couple of partial derivatives were outputted that were not used by the model, or just added up in functions in the code. I output the dry and moist derivatives instead because I may use them to simplify the mixing length formulation in the near future.θ_liq_ice != θ
in the environment, just in the dry part of the environment. Third, it corrects the latent heat used to include effects of all condensate species.Quadratures
in the model. The derivatives are the same as in the previous case, therefore you will find that thebuoyancy_gradients
function is shared. The main distinction is in the arguments passed with theEnvBuoyGrad
struct. In this case, we make full use of the quadrature information to compute the gradients. Safeguards are included for gradients computed in vanishing cloudy or dry regions. In these regions, we resort to the environmental mean gradients.