CFD Online Discussion Forums

CFD Online Discussion Forums (
-   CFX (
-   -   Buoyant flow (

brunorgs May 11, 2010 14:03

Buoyant flow
anyone know the correct way to set up a buoyant flow simulation with static pressure boundary conditions? The problem is how to set the correct pressure profile along a boundary, since (if the fluid is compressible) it will depend on height and on fluid state equation.
In case of air ideal gas, I tried p(z)=k*(z-z_ref)+p0 (z is the coordinate parallel to the gravity vector) as the CFX manual recommends, but I was not able to figure out how to chose the constant k.
Any idea of whats happening?

stumpy May 11, 2010 17:20

I have used the following in the past for compressible fluids:
Zref = 2 [m]
Tref = 300 [K]
Pref = 101325 [Pa]
mwair = 28.96 [kg kmol^-1]
Denref = Pref*mwair/(R*Tref)
Phydrostatic = Pref*exp(mwair*g*(Zref-z)/(R*Tref)) - Pref - Denref*g*(Zref-z)

brunorgs May 17, 2010 13:11

I just tested it, and it worked fine for the vertical boundaries. But I'd like to use an opening condition on the superior boundary as well (perpendicular to gravity), but the flow (over a flat plate) that should run paralel to x, "falls" from the top and then leaves the control volume by the lateral and frontal faces of it.
In this case, should I apply a velocity profile on the top boundary?


ghorrocks May 17, 2010 18:41

You cannot define both the pressure and velocity at a boundary. This is over-defining the boundary.

If the opening is perpendicular to gravity then it just has a constant pressure applied. No need for hydrostatic. Alternately if you know the velocity/flow rate then you can apply a velocity/flow rate boundary.

brunorgs May 17, 2010 20:46

I have one vertical and one horizontal opening boundaries (it is intentional, for testing). I appied the relation that the guy stumpy suggested on both boundaries. Of course in the horizontal, constant z boundary, it results in a constant pressure, so I could directly set a value for the pressure there, but the big question, I think, is what's the right pressure value, at the vertical boundary, that will keep the flow horizontal, instead of sucking the fluid out or blowing fluid in. That is why I'm wondering if it is better to set a velocity profile instead of a pressure profile.

ghorrocks May 17, 2010 22:28

If you don't want to suck or blow fluid then why not just use a wall?

brunorgs May 18, 2010 10:15

Because it is open to the atmosphere.

brunorgs May 18, 2010 10:35

In short, I'm running a test simulation of flow over a flat plate. I'd like to set correctly a simulation using openings with static pressure condition on the left, right, top and forward boundaries (wall on the bottom and inlet with prescribed velocity on the backward boundary), and buoyant air ideal gas.
It must be buoyant because later I'll release heavy gas at some point in the domain.

ghorrocks May 18, 2010 19:12

I would still recommend you consider using walls on the sides, or making the inlet include the side walls. Pressure boundaries where the flow goes tangent to the boundary are always convergence nightmares.

brunorgs May 19, 2010 13:14

Do you mean free slip wall? And what about opening with prescribed velocity (at least for the horizontal boundary?

ghorrocks May 19, 2010 18:37

Slip walls are better than no slip, but as long as the outer walls are far enough away it probably won't matter much.

Can you post an image of what you are trying to do? Otherwise I will be guessing.

brunorgs May 25, 2010 15:46

Sorry for the late response, but the link for the CFX-Pre figure is below:

ghorrocks May 25, 2010 19:08

Consider making the side walls periodic boundaries. Also be aware this simulation is almost certainly transient and 3D and if you want to model it correctly you will have to get adequate width to capture these features.

brunorgs May 26, 2010 10:05

For now I don't wanna capture the 3D effects of the flow, only to chose the most adequate boundary conditions. So, why should I use a periodic boundary condition in the side walls instead of, for example, outlet or opening conditions?

ghorrocks May 26, 2010 18:16

But if the flow is 3D then there is no valid 2D model of it. You are over constraining the model into an incorrect solution.

brunorgs May 27, 2010 13:22

Ok, but once I use a more adequate width, why do you recommend a periodic boundary conditions on the side walls?

ghorrocks May 27, 2010 19:02

Because a periodic side boundary is the least constraining. It is also very simple to do (no need to specify anything) and very numerically stable.

brunorgs May 28, 2010 09:37

Ok. I'll try it out. Thanks!

All times are GMT -4. The time now is 01:17.