CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   CFX (https://www.cfd-online.com/Forums/cfx/)
-   -   Setting Pressure Condition (https://www.cfd-online.com/Forums/cfx/109347-setting-pressure-condition.html)

marcoymarc November 15, 2012 10:24

Setting Pressure Condition
 
Hi, first of all, thank you for your help.
I am a cfx newbie; but i guess the problem i am looking help for, is very simple. The fact is i can't find any tutorials/doc to solve it.

I've modeled a cylinder, which is my porous domain, that stands in a parallelepiped, which is my fluid domain. The fluid domain is filled with Resin, at start, while my porous domain is empty. I tried to model the void defining a new gas material whose viscosity and density are almost 0. OFC, this is a multiphase sim.
First question: Is it correct to model the void this way? If not, how to?

Let's come to my real concern: i'd like to set the pressure equal to 0 Pa (which is my reference pressure also) in the finite volumes in which void volume fraction is = 1; this has to be a continuos condition and not an initial one.

i mean something like:
If in "finite volume", void.volume fraction == 1;
set pressure = 0 Pa
end

where the finite volume is every single finite volume of my mesh.
Can i do this in someway?
Can you help me since i don't even know Fortran?
Thank you anyway and sorry for my English.

ghorrocks November 15, 2012 17:57

No need for fortran for this, it can be done entirely in CEL.

I cannot comment on whether your approach is valid as I do not understand what you are trying to model. Some images would help.

marcoymarc November 15, 2012 19:06

Ghorrocks, thanks Very much for your reply. I have not my notebook nearby but i will check the robustness of my approach later. First, i'd like to set the pressure codition i spoke about; unluckily i am a newbie at CEL too. Can you tell me where to find some tutorials, or better how to set it, if you like :) sorry to bother

ghorrocks November 15, 2012 20:36

Several of the tutorials which come with CFX use CEL. Have a look at help/CFX/tutorials.

marcoymarc November 29, 2012 09:31

Hi Guys,
i am still here.
I have got the basics of CEL now. But i can't yet see how to set a Phase Pressure equal to 0, throughout the sim. I mean i want that Ansys sets the pressure for a phase (air for example) = 0 during all the simulation, and not ONLY as initial condition. Is it possibile to achieve that? Thank you

brunoc November 29, 2012 12:12

Hi Marco,

What *exactly* are you trying to model? What do you want as an output? I'm asking this because at first sight fixing the pressure doesn't make much sense, unless you don't want to solve the domain with a fixed pressure.

marcoymarc November 29, 2012 12:40

Quote:

Originally Posted by brunoc (Post 394884)
Hi Marco,

What *exactly* are you trying to model? What do you want as an output? I'm asking this because at first sight fixing the pressure doesn't make much sense, unless you don't want to solve the domain with a fixed pressure.

Brunoc thanks for your reply.
Imagine a cylinder whose basis are "inlet and outlet" boundaries while the remaining surface is a free slip wall. I want a multiphase sim in which resin flows inside the cylinder and Air flows out. Cylinder is airfilled at start. I want the Air.pressure to be always 0 PA because, in truth, it has to work as if it were void. Imagine you generate void into the cylinder and then you let the resin flow trough it. It will move forward due to depression we have in void. Do you Think is it correct to Think that void pressure will be costant during all the sim? Or will it change during the resin filling, growing bigger and slowing resin flow? If the assumption in the first question is right, how can i set the air(void) pressure to be 0 everywhere and everytime? Thanks for your patience

brunoc November 29, 2012 13:09

If the resin's viscosity is much larger then the air's (I think it probably is) then the air pressure should be much lower than the pressure inside the resin. Also, if the resin's properties are not dependent on pressure and the air is free to escape do domain (meaning it is not contained in it) than you don't need to worry about the air pressure level. It should be approximately equal to the level set at the outlet.

marcoymarc November 29, 2012 13:24

Well the fact is that my cylinder is a porous media standing in a fluid domain. Guess the low permeability (10^-13) is not letting Air flow out so easily and its pressure grows. Any ideas on making it work as if it was void?

ghorrocks November 29, 2012 17:15

I think Marco has missed a fundamental point here. You cannot set pressure to zero because you need pressure to drive a flow. The pressure difference to drive the small flow of air away from the resin might be tiny, but it needs to be there to get out of the way of the resin. So Marco's idea of fixing pressure to zero will not work and is fundamentally flawed.

Having said that, I know Flow-3D uses a unique VOF approach ideally suited for these applications where the free surface is modelled as a zero pressure boundary which can move. This means VOF simulations can be done with explicit modelling of the low density phase... it is a very nice approach but not available in CFX.

Anyway, back to the point. You will have very small pressure gradients in this model to push the air out of the way. Why is this not suitable for your model?

marcoymarc December 3, 2012 11:20

Quote:

Originally Posted by ghorrocks (Post 394924)
I think Marco has missed a fundamental point here. You cannot set pressure to zero because you need pressure to drive a flow. The pressure difference to drive the small flow of air away from the resin might be tiny, but it needs to be there to get out of the way of the resin. So Marco's idea of fixing pressure to zero will not work and is fundamentally flawed.

Having said that, I know Flow-3D uses a unique VOF approach ideally suited for these applications where the free surface is modelled as a zero pressure boundary which can move. This means VOF simulations can be done with explicit modelling of the low density phase... it is a very nice approach but not available in CFX.

Anyway, back to the point. You will have very small pressure gradients in this model to push the air out of the way. Why is this not suitable for your model?

Hi Ghorrocks.
Sorry for replying this late but i had some connection issues during last few days.
Well, i am not fixing pressure 0 everywhere.
I have got 2 phases, resin (liquid) and something i want to behave like if it was void. While i'll set a pressure different from 0 at inlet for the resin(and so for resin everywhere in the domain), i want the void pressure (air pressure say) to stay always 0.
To understand if my approach is right, i'd like you to answer a question.
If i create vacuum in a bottle, say -50 Pa, what will happen when i let some water flow inside it? Will the vacuum pressure during the transient stay at -50Pa or will it change? Please can you help me with this doubt?

marcoymarc December 3, 2012 12:00

http://img7.imageshack.us/img7/6184/immaginekth.jpg



This is my model.
Parallelepiped is my fluid domain, the other one is my porous domain. At inlet i've got resin VF = 1 and a pressure of 500 pa. At outlet resin VF = 0 and pressure = 250 Pa. The initialization for fluid domain is Resin VF = 1 and pressure = 500 pa; in the porous media i've got Void VF = 1 at start and pressure = 0 Pascal. I want Void pressure to be always 0. i defined void as a new material with low density (10^-5kg/m^3) and no viscosity. What happens as i start the sim is that Void pressure grows and this bounds my resin flow trough the porous media to be very small during time. In reality i guess the void pressure stays at 0. How can i model a new gas to be used as void to have exactly that behavior?

Can you defenately help me to set pressure at 0 wherever Gas phase is? Thank you.

ghorrocks December 3, 2012 17:02

Quote:

Well, i am not fixing pressure 0 everywhere.
I have got 2 phases, resin (liquid) and something i want to behave like if it was void. While i'll set a pressure different from 0 at inlet for the resin(and so for resin everywhere in the domain), i want the void pressure (air pressure say) to stay always 0.
To understand if my approach is right, i'd like you to answer a question.
If i create vacuum in a bottle, say -50 Pa, what will happen when i let some water flow inside it? Will the vacuum pressure during the transient stay at -50Pa or will it change? Please can you help me with this doubt?
From what I understant of your problem you are trying to fix pressure=0 everywhere where the VF=0. You cannot do this, it will not work. You need to allow the pressure gradients in the air to generate the flows to push the air out of the way. These pressure gradients will be small - if your overall resin pressure gradient is 500Pa then the air pressure gradients could well be 0.001Pa or something tiny like that, but these small gradients are necessary for the air to flow.

If you put water in a bottle at -50Pa (or any pressure for that water) then as long as there is fluid motion there will be small pressure gradients along with it. And a hydrostatic head as well, if applicable.

marcoymarc December 4, 2012 07:09

I completely agree. The pressure gradient in air should be very small compared to that in resin. And here we come to my concern.
Look at pressure on a XZ plane compared to ResinVf after few timesteps O(10^-4):
http://img62.imageshack.us/img62/9732/pcontour2.jpg
This is ResinVF:
http://img32.imageshack.us/img32/7711/vf2q.jpg
And this is Pressure at start:
http://img203.imageshack.us/img203/3161/pressure1.jpg

How comes the pressure in Air grows up and becomes comparable to resin's one? Any ideas? Thank you...

ghorrocks December 4, 2012 18:07

To sustain a pressure difference across the resin/air interface there needs to be some physics - maybe surface tension, or a transient compressible flow or a solid skin forming. But two fluids with an interface and no other physics will equalise pressure. So it looks like you are seeing this equalisation process, at least an early part of the transient flow which ends up in the equalisation.

marcoymarc December 5, 2012 09:28

Ghorrocks, using Air ideal gas (=compressible flow), brings to pressure expected results. Thank you very very much. :)


All times are GMT -4. The time now is 09:42.