-
Notifications
You must be signed in to change notification settings - Fork 41
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
DivU constraint with arbitrary sources #428
DivU constraint with arbitrary sources #428
Conversation
…forces on density.
…divergence constraint.
After further review, it appears that the current |
@dmontgomeryNREL can you add a comment in the @drummerdoc - here is the derivation from @dmontgomeryNREL and I that supports this, can you take a quick look and make sure you also agree because it's an important point. |
|
In (23) above, Ym is the mass fraction of the local gas (same as the Ym in (32)), correct? Note that this says that mass is added at the local composition. Where do you account for mass being added at a different composition (like an evaporating fuel) - if that's even possible.... taking a minute to wrap my head around this. |
The physical meaning is more apparent in Equation 24, which is the complete equation for Consider an H2O drop evaporating into pure N2, so |
The subtlety is the blending that occurs between the ambient composition and that of the source, yet the sum of the mass fractions has to remain 1. In chemical reactions, a preferential loss of a given species occurs while respecting a conservation of atoms, so nothing really vanishes or appears, just switches bonds. Here, like at an inflow boundary, we are adding specific atoms, and then we re-normalize so that the sum of the new Ym's again equal 1. The head-hurting part is how to do that consistently as a volumetric source and make sure that when we get to the end of the time step that you have properly accounted for the injection of all the added atoms. Maybe there's nothing weird here, but I can certainly imagine some sanity checks to ensure detailed conservation is being satisfied properly. Let's try to add something like that in zero or one dimension as a regression test - maybe as a later PR. |
I think the bookkeeping should all be fine because we do things in terms sources of rhoYs for the actual effect on the transported species. In testing this PR out I didn't see any issues with species conservation, just stuff relating to divu as described in #429. So I think this PR is good to go, although we may need to revisit some aspects. |
This PR updates the divu constraint to be compatible with arbitrary source terms. This is necessary for system closure in any model that introduces external sources on density (e.g. Spray). This should be consistent with the user defined sources proposed in PR #427.