|
[Sponsors] |
About the influence of the mass source term on the momentum equation and coding |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
May 16, 2023, 10:02 |
|
#21 |
New Member
DuanYabo
Join Date: Jul 2022
Posts: 16
Rep Power: 4 |
Thank you both for your answers, which really helped me a lot.
Now I know that adding only the mass source term will change the momentum of the system, but it will not change the momentum equation established for solving the problem, right? Thanks! |
|
May 17, 2023, 19:58 |
|
#22 |
Member
Hosein
Join Date: Nov 2011
Location: Germany
Posts: 94
Rep Power: 15 |
Hi all,
I found this discussion useful! And I checked up on literature a bit and this is my understanding... I think it largely depends on the nature of your source terms you want to consider. Assuming you are dealing with an incompressible flow which means that there are either no density variations or they are very negligible, the continuity equation is the so-called divergence free version. Now adding mass to your system will locally imbalance your continuity which in turn you can consider that by adding an additional term in your continuity equation. So the question is whether you should add another term in momentum conservation or not. And here I think is the point where the nature of your source term matters. If addition of that mass in your system is gonna largely change the density then you should also add another term representing the effect of that added mass on the momentum equation(note that is the momentum per unit volume). This way it also contradicts the first assumption of dealing with an incompressible flow! maybe one needs to switch to compressible formulation. On the other hand if addition of that mass has negligible effect on density variations (more compatible with incompressible flow assumption) one may not add an additional source term in momentum equation. Since you mentioned you are using simpleFoam, this means by default you are considering your flow to be incompressible and looking into simpleFoam solver you notice that the continuity equation is not solved directly but rather indirectly through the pressure equation. So in my opinion if the second scenario is of your interest, you should add your source term in pEqn.H and not change UEqn.H at all. As I said this is an assumption you are making that your mass source term will have negligible effects on density hence it could still be considered as incompressible flow. There might be another issue with your source term being explicit which will ruin the diagonal dominance of the resulting system of equations which in that case you may consider an implicit source term to treat that issue. Looking into combustion/reacting solvers in OF will give you a better image on that. hope this helps... |
|
May 19, 2023, 13:05 |
|
#23 | |
Senior Member
Join Date: Apr 2020
Location: UK
Posts: 745
Rep Power: 14 |
Quote:
The tricky bit is that there is no density equation to solve in the incompressible solver, and so there is no simple way of dropping in the mass source. Instead, you need to add the source term into the pressure-corrector expression, which clearly can't be done using an fvOptions source term ... you have to play with the pEqn instead. As regards the momentum equation - we are agreed - you can add mass without momentum, i.e. do not need to add any compensating source term in the momentum equation ... but you need to be aware that, by doing this, you will dilute the momentum in the rest of the flow and that adding mass with no momentum is often unphysical. The impact that this has on the conditions in the domain depends on your boundary conditions (constant pressure, constant velocity etc). |
||
May 21, 2023, 05:13 |
|
#24 |
New Member
DuanYabo
Join Date: Jul 2022
Posts: 16
Rep Power: 4 |
Hi Tobermory, Hosein and Zeinab:
After so many days of discussion with you and consulting relevant literature, I have gained a new understanding of this issue. Now please point out the mistakes in my understanding. All my current references are sourced from Moukalled's books. Due to the lack or rarity of similar problems in real life, it is difficult to solve them. Firstly, according to Reynolds transport theory, it can be inferred that Equation 1 is the derivation process of the continuity equation,where S is the mass source term, MV the material volume. So the momentum equation should be Because I am solving incompressible, steady, and inviscid problems, equations (1) and (2) are integrated and simplified I'm not sure if the formula we pushed is correct. Could you please help me take a look. If there are any errors, please help me point them out. Thanks very much , , and . |
|
October 20, 2023, 00:47 |
|
#25 |
New Member
DuanYabo
Join Date: Jul 2022
Posts: 16
Rep Power: 4 |
Now my teacher believes that my derivation is incorrect (even though I have already obtained good results using the above formula). He believes that d (mv)/d (t) in the momentum equation should be equal to the force acting on the control body.
The main basis is that if the momentum equation I derived is written in a non-conservative form, the v * div (v) on the left hand side exactly offsets the S * v on the right hand side, which is too coincidental. So he thinks that my momentum equation has two forms of the same thing on the left and right sides, which is incorrect. So I am currently searching for new literature to see if there are other methods to derive the correct momentum equation. Additionally, if only the continuity equation is modified without modifying the momentum equation, the program will report an error. |
|
October 20, 2023, 07:54 |
|
#26 |
Senior Member
Join Date: Apr 2020
Location: UK
Posts: 745
Rep Power: 14 |
Your teacher is right ... you have just proved in effect that 1=1.
I am not sure what your overall aim is, but if you want to derive a conservation expression for momentum, then just look in a basic Fluid Mechanics book and you will find a simple expression of Newton's 2nd law: force is the rate of change of momentum, e.g.: where is the Cauchy stress tensor (you can expand this out in terms of the normal and shear stresses) and is the body force. This should be your starting point rather than the continuity equation. If you want to add source terms to the equations, then there is a mass source term in the continuity equation, and a separate and unrelated momentum source in the momentum equation. Note that it is perfectly possible to inject mass into a domain with no momentum. You have to decide, when injecting the source mass, what momentum you want to give it. Hopefully you are clearer now ... |
|
October 20, 2023, 09:08 |
|
#27 |
New Member
DuanYabo
Join Date: Jul 2022
Posts: 16
Rep Power: 4 |
Thank you for your reply again and for following my question.
Can I assume that the momentum source term in my question is caused by increasing mass? To calculate the momentum source term,do you think my following ideas are correct? The premise of your above formula is that the mass in the material volume remains constant during dt time (which is also the meaning of dm/dt=0 in the continuity equation). For the momentum equation, d(mv)/dt=m * dv/dt+v * dm/dt. Due to the fact that for the vast majority of real-world problems, dm/dt=0, d (mv)/dt=ma=F (F refers to the pressure and body force in your formula). But in my problem, the quality is constantly increasing, i.e., dm/dt=S0. So in the momentum equation, the added momentum source term is (delta m) * v, right? (My question is not a practical one, it is an equivalent substitution to solve problems in other subject, but it is very important and involves whether I can graduate with a PhD.) Please help me check it again, as I believe this explanation is correct. THANKS THANKS THANKS !!! |
|
October 20, 2023, 12:06 |
|
#28 | |
Senior Member
Join Date: Apr 2020
Location: UK
Posts: 745
Rep Power: 14 |
Quote:
i.e. Now the first term (what you have called delta m . U) is the expression of the effect of adding the mass in the continuity equation ... but it is not itself a source term (i.e. it is not itself adding momentum). The momentum change comes from the force term and the S_mom term. I think that you get more understanding from leaving the momentum equation in its conservative form, integrating over the control volume and using the Gauss divergence theorem to get: in other words where the sums are over all the faces f of the control volume, is the face mass flux and is the projection of the face area in the i direction. As per one of my earlier posts, in a steady incompressible flow, like the one you are considering, the flow adjusts instantaneously to any changes and so the impact of a mass and momentum injection depends entirely on your boundary conditions - i.e. on what you do with velocity and pressure at the boundaries. The velocity and pressure in the field then react accordingly. |
||
October 21, 2023, 04:10 |
|
#29 |
New Member
DuanYabo
Join Date: Jul 2022
Posts: 16
Rep Power: 4 |
Thank you again for your answer, which made me a lot clearer.
So back to the initial question. The mass source term has no effect on the form of the momentum equation (at least in a conserved form), as the mass source term appears in div(ρUU) term, right? Additionally, does the momentum source term depend on the boundary conditions ? In this way, there should be no momentum source term in my problem. My problem only has two boundary, i.e., inlet and outlet. On the inlet, set U fixed value and p zerogradient; on the outlet, set U zerogradient and p fixed value. But I tried to modify only the continuity equation in simpleFoam, and this program always reported an error when solving U in the Time=2 step. It's a strange phenomenon, I'll delve deeper into it. If you know any helpful information for me, please reply to me. Thanks, thanks, thanks!!! |
|
Tags |
equation construction, mass source term, openfoam, simplefoam, source term |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Expanding an Implicit Scalar Source term to a Vector or Tensor | ScalarVectorTensor | OpenFOAM Running, Solving & CFD | 1 | October 18, 2023 03:31 |
Solve poisson equation just add a source term | nandiganavishal | OpenFOAM Running, Solving & CFD | 18 | November 14, 2022 10:12 |
Adding two terms in the momentum equation in in chtMultiRegionSimpleFoam | zahraa | OpenFOAM Pre-Processing | 0 | June 13, 2015 13:42 |
Mass flow rate boundary condition for continuity equation for oscillating flow | p07ip705 | Main CFD Forum | 0 | February 28, 2013 02:33 |
FEM fortran codes for coupled mass momentum energy | Amit | Main CFD Forum | 1 | May 17, 2005 21:38 |