Why we subtract continuity Eqn into momentum Eqn instead of adding it?
Hey guys,
This piece of code is quite common in OpenFOAM; Code:
fvm::ddt(alpha1, U1) //mom eqn Code:
fvm::ddt(alpha1, U1) //mom eqn |
I dont really know
normally we seek diagnal dominance, so i would say so but thats the contrary of what is done here ?????? |
Yep...Wish someone who can explain this. lol
|
Quote:
Yeah, The problem is why we want to solve the first Eqn in your posts. The reason why I ask this kind of problem is that: "openfoam22x is solving non-conservative equations but 23x is solving conservative eqns."for two-fluid model. So I think the thing deeper is : 1. Why we solve Eqn 2 instead of Eqn 1. I saw some posts that Hrv and Henry explain this, They just said the conservative eqn is stable and good. I dont know the reason. 2. Eqn 2 and Eqn 1 should predicts the same results rite? But sometimes it does not. Best, |
Hi Dongyue,
Eq 1 and Eq 2 are equivalent only if the continuity equation (equal to zero) is satisfy. I guess that since we deal with an operator-splitting scheme (first we solve the momentum, then the pressure, then the correction, then we iterate), the continuity equation is not fully respected, and that why we add to add this term, to avoid spurious momentum transfer due to an ill-evaluation of the continuity. Cheers, |
Quote:
Equation 1 and 2 are not equivalent numerically because they do not allow for the same Riemann invariant. If you take the example of a shockwave or any other type of discontinuity, as a Cauchy-Riemann classical problem, you find that the wave propagation / shock propagation/ discontinuity propagation will be at the wrong velocity if you do not formulate your problem using the conserved variables. I am not familiar with these issues in the context of two phases flows, but for compressible flows this is an extremely critical issue and you always need to formulate the problem in conservative variables (rho, rho * u, rho * e). I believe that since these multiphase flows contain large amount of discontinuity in the phases (like air on top of water or whatever), a conservative formulation is a lot more appropriate if you want to obtain the right propagation of the interface. There is a very very nice book by Euleterio Toro on hyperbolic systems that discusses these issues if I remember. |
Hi,
I am confused with these statements. Sharonyue refers to the alpha1Eq, not the momentum equation. In interDymFoam, I have the following code: Code:
fvScalarMatrix alpha1Eqn I changed to: Code:
fvScalarMatrix alpha1Eqn By the way, for compressible solvers, this code is wrong (div phi is not zero, but div rho phi. Regards, Daniel |
All times are GMT -4. The time now is 14:00. |