|
[Sponsors] |
February 22, 2021, 04:30 |
Implementing equation with two unknowns
|
#1 |
New Member
anonymous
Join Date: Dec 2018
Posts: 4
Rep Power: 7 |
Hi,
I´m struggling with the implementation of an equation into my own OpenFoam-Solver. I´ve got two equations like this: ddt(X) + div(n1) = -Q ddt(Y) + div(n2) = Q X, Y and Q are unknowks; n1 and n2 are knows. To avoid the calculation of Q I would like to equalize the equations ddt(X) + ddt(Y) + div(n1) + div (n2) = 0 this gives me an equation with the two unknows X and Y. Now I would like to solve this equation by inserting a value for X, calculate Y and repeate this procedure till I have a result of this equation. Is there a way to do something like this in OpenFoam? Actual I have no Idea how to type in an equation with two unknows and I´m not sure if this plan is a good idea, because I think this could result in an instable solver. I will be glad, if you have some tips for me. |
|
February 22, 2021, 07:45 |
|
#2 |
Senior Member
Join Date: Apr 2020
Location: UK
Posts: 670
Rep Power: 14 |
I think that you have a problem here - you have 2 equations and 3 unknowns ... or 1 equation and 2 unknowns if you get rid of Q. You can't solve this! You need another equation.
You can solve Y for a given value of X, or vice versa, but there is no single solution of X and Y given just one equation. |
|
February 22, 2021, 08:35 |
|
#3 |
Senior Member
Join Date: Apr 2020
Location: UK
Posts: 670
Rep Power: 14 |
<for some reason the same message posted twice ... can't delete this duplicate one>
Last edited by Tobermory; February 23, 2021 at 04:06. |
|
February 22, 2021, 12:08 |
|
#4 | |
New Member
Giovanni Luddeni
Join Date: Jan 2021
Posts: 14
Rep Power: 5 |
Quote:
Find the criterion, write it as an equation and you can close the system. Hope it helps! |
||
February 23, 2021, 01:34 |
|
#5 |
New Member
anonymous
Join Date: Dec 2018
Posts: 4
Rep Power: 7 |
Thanks Tobermory and gionni,
I´m going to look for the relation of X and Y to close the system. Your completely right that I need the third equation to make sure that the pair of X and Y are the correct pair that I need. Thanks for your help and the food of thought. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
mass flow in is not equal to mass flow out | saii | CFX | 12 | March 19, 2018 05:21 |
Problem with Velocity Poisson Equation and Vector Potential Poisson Equation | mykkujinu2201 | Main CFD Forum | 1 | August 12, 2017 13:15 |
implementing this equation | sambatra | OpenFOAM Running, Solving & CFD | 9 | August 27, 2009 08:55 |
Need help:about energy equation in CFX | Stein | CFX | 4 | July 2, 2009 22:31 |
Diffusion Equation | izardy amiruddin | Main CFD Forum | 2 | July 4, 2002 08:14 |