Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.
How to couple a cubic equation solution to a phase field fluid flow model?
Posted 22 avr. 2016, 06:09 UTC−4 Computational Fluid Dynamics (CFD) Version 5.0 0 Replies
Please login with a confirmed email address before reporting spam
How to solve a cubic equation by using a previous pressure value comes from the fluid flow model and use the root solution as a new density value to feed back the next time step fluid flow calculation?
I follow an instruction from COMSOL Blog “Solving Algebraic Field Equations” and successfully use “ Domain ODE and DAE Interface (dode) ” to find out the density roots I want by using and artificial pressure input.
www.comsol.com/blogs/solving-algebraic-field-equations/
However, even though the blog describes an exactly same problem that I want to solve at the front, it only shows an example by using “dode” physics alone to solve a cubic equation without showing how to couple the solution to the actual flow model.
After I successfully solve the cubic equation by using“dode” to get the result I want. I try to add the same “dode” physics into my “Two-phase flow, phase field” model and set my fluid 1 density as this new dependent variable comes from “dode”. As for the pressure input, in the “dode” part, I use symbol “p” as the input argument of the cubic equation to represent the pressure field values.
The simulation does show a pressure change for the compressible gas bubble (fluid 1) but the density field I extract is remaining constant instead of changing along with the pressure value.
I guess I still need to modify the model tree in order to couple this two physics correctly. I would be very appreciated if anyone could help me figure this out. Thank you.
Di Shen
Hello Di Shen
Your Discussion has gone 30 days without a reply. If you still need help with COMSOL and have an on-subscription license, please visit our Support Center for help.
If you do not hold an on-subscription license, you may find an answer in another Discussion or in the Knowledge Base.