rhoPimpleFoam energy equation understanding problem he
Hey,I looked into rhoPimpleFoam source code and I wonder about the energy equation. I have some questions for that.
1) Why is he.name() == "e" necessary? 2) I applied an fvOptions scalarCodedSource term to it, what was only possible on "e" not on "he", but fvOptions(rho, he) is coded into the equation, and also the correction is called on "he" fvOptions.correct(he). Is that just because of 1) ? https://www.cfd-online.com/Forums/op...at-source.html 3) Where does the temperature field "T" gets calculated, since it does not even get created in "createFields"? ( I think it has to be somehow implemented in the "thermo" functionality what is for me whitchcraft until now, I would be very happy for some advice to begin my research about "thermo") Code:
{ |
In openfoam you can either solve an equation for the internal energy ("e") or enthalpy ("he").
This is the if else statement in the energy equation. Once solved the energy equation, the temperature is calculated in the termo package. For the latter see https://caefn.com/openfoam/temperature-calculation |
Isn't it quite confusing that there is not a dummy variable instead of "he" ? So for example "x" that get set to "e" or "he" .
|
he is the dummy variable. Enthalpy is "h". In he.name() it is store, what is actually solved (e or h) and then the energy equation is modified accordingly. See : https://cfd.direct/openfoam/energy-equation/
|
All times are GMT -4. The time now is 11:56. |