CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

Boundary conditions for outlet

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 11, 2005, 02:13
Default Does anyone have the experienc
  #1
New Member
 
Kim Sung
Join Date: Mar 2009
Posts: 12
Rep Power: 17
sung is on a distinguished road
Does anyone have the experience dealing with outlet boundary condition by setting zero pressure gradient and zero velocity gradient. Some sigular point always arise and my job gets killed.
sung is offline   Reply With Quote

Old   April 11, 2005, 04:32
Default How are you setting the pressu
  #2
Senior Member
 
Join Date: Mar 2009
Posts: 854
Rep Power: 22
henry is on a distinguished road
How are you setting the pressure-level given that the outlet no longer sets it? Do you have a reference cell in the domain? What code are you running?
henry is offline   Reply With Quote

Old   April 11, 2005, 14:09
Default I create a solver based on ico
  #3
New Member
 
Kim Sung
Join Date: Mar 2009
Posts: 12
Rep Power: 17
sung is on a distinguished road
I create a solver based on icoFoam.C by adding a piece of code before the pressure solution used to scale the flux on the outlet boundary to satisfy
global continuity (refered to Dr. Hrvoje Jasak's dissertation, thanks Hrv!).

I do not use reference cell in the domain.
sung is offline   Reply With Quote

Old   April 11, 2005, 14:15
Default If you have zero-gradient boun
  #4
Senior Member
 
Join Date: Mar 2009
Posts: 854
Rep Power: 22
henry is on a distinguished road
If you have zero-gradient boundary conditions for p over all the boundaries and you are not using a reference cell how are you stopping the pressure level float?
henry is offline   Reply With Quote

Old   April 11, 2005, 14:36
Default Thanks Henry, Probably this
  #5
New Member
 
Kim Sung
Join Date: Mar 2009
Posts: 12
Rep Power: 17
sung is on a distinguished road
Thanks Henry,
Probably this is the reason my job get killed. Is there any similar code in the OpenFoam package I could follow to set the reference cell?
sung is offline   Reply With Quote

Old   April 11, 2005, 14:41
Default All the solvers include code l
  #6
Senior Member
 
Join Date: Mar 2009
Posts: 854
Rep Power: 22
henry is on a distinguished road
All the solvers include code like:

fvScalarMatrix::reference pRef = pEqn.setReference(pRefCell, pRefValue);
pEqn.solve();
pEqn.unsetReference(pRef);

Which sets the pressure reference if necessary as dictated by the set of pressure boundary conditions.
henry is offline   Reply With Quote

Old   April 11, 2005, 16:01
Default Oh, I do keep this part of cod
  #7
New Member
 
Kim Sung
Join Date: Mar 2009
Posts: 12
Rep Power: 17
sung is on a distinguished road
Oh, I do keep this part of code from icoFoam.C. So the problem is where should I provide the reference cell label and value? Is it in the file of 0/p or some where else? The default values seem to be pRefCell=0 and pRefValue=0.
sung is offline   Reply With Quote

Old   April 11, 2005, 16:16
Default The default is 0 and 0 but it
  #8
Senior Member
 
Join Date: Mar 2009
Posts: 854
Rep Power: 22
henry is on a distinguished road
The default is 0 and 0 but it shouldn't matter what location or value you choose if the purpose is simply to stop the pressure level floating. However you can change them if you wish to; they are read from the PISO or SIMPLE sub-dictionaries of fvSolution.
henry is offline   Reply With Quote

Old   April 11, 2005, 16:41
Default Hi Henry, Yes, I do not reall
  #9
New Member
 
Kim Sung
Join Date: Mar 2009
Posts: 12
Rep Power: 17
sung is on a distinguished road
Hi Henry,
Yes, I do not really care where is the reference zero pressure. I will just keep it to be default value. When I apply my solver to a simple 3 dimensional straight duct flow problem with one inlet and one outlet, it always get stuck when set the outlet to be zero pressure gradient.
sung is offline   Reply With Quote

Old   April 11, 2005, 16:52
Default You might find it useful to st
  #10
Senior Member
 
Join Date: Mar 2009
Posts: 854
Rep Power: 22
henry is on a distinguished road
You might find it useful to study the operation of the adjustPhi(phi, U, p) call in simpleFoam which I implemented to adjust the inlet and outlet fluxes to obey continuity during the solution of stready-state cases when the outlet pressure BC is not fixed-value. You will probably find it can be included directly into your icoFoam-based code for your case in the same way as it is used for simpleFoam. If you would like to look at the source for this function it is in OpenFOAM-1.1/src/cfdTools/adjustPhi.
henry is offline   Reply With Quote

Old   April 12, 2005, 14:30
Default Hi Henry, Thanks for offering
  #11
New Member
 
Kim Sung
Join Date: Mar 2009
Posts: 12
Rep Power: 17
sung is on a distinguished road
Hi Henry,
Thanks for offering me so much help.

In the tutorial's simpleFoam directory, there is a sample case "pitzDaily", the geometry is quite similar to my problem. The outlet pressure BC is "fixedValue, uniform 0" in the tutorial, it runs perfect with simpleFoam. Now I change it to be zeroGradient, it get stuck. Here is the erro message:
--> FOAM FATAL ERROR : Continuity error cannot be removed by adjusting the outflow.
Please check the velocity boundary conditions and/or run potentialFoam to initialise the outflow.

Function: adjustPhi(surfaceScalarField& phi, const volVectorField& U,const volScalarField& p
in file: adjustPhi/adjustPhi.C at line: 108.

FOAM exiting
sung is offline   Reply With Quote

Old   April 12, 2005, 14:47
Default What is the initial value for
  #12
Senior Member
 
Join Date: Mar 2009
Posts: 854
Rep Power: 22
henry is on a distinguished road
What is the initial value for U? If it is (0 0 0) try either restarting from the solution you obtained with the fixedValue p outlet or set it to the inlet value.
henry is offline   Reply With Quote

Old   April 12, 2005, 15:25
Default Yes, the initial U was (0 0 0)
  #13
New Member
 
Kim Sung
Join Date: Mar 2009
Posts: 12
Rep Power: 17
sung is on a distinguished road
Yes, the initial U was (0 0 0). After I restart it from the solution of fixedValue p, it works;) So, can we conclude that the zeroGradient pressure BC is quite sensitive to the initial condition? Now a new problem arise;( if I have a multi-outlet domain, eventually, all of the outlets need to be set as zeroGradient pressure. How can I set the fixed pressure value for every outlets to get "predictor solution", all to be the same of zero?
sung is offline   Reply With Quote

Old   April 12, 2005, 15:30
Default The problem is that the outlet
  #14
Senior Member
 
Join Date: Mar 2009
Posts: 854
Rep Power: 22
henry is on a distinguished road
The problem is that the outlet flux cannot be scaled to obey continuity if it's value is zero. If you want to use a continuity-adjusted outlet condition you need a sensible flow-field on which it can operate and a sensible choice is to start from is the potential-flow solution or at the very least some kind of mean value or the inlet value.
henry is offline   Reply With Quote

Old   April 19, 2005, 16:18
Default Hi Henry Thanks for so many i
  #15
New Member
 
Kim Sung
Join Date: Mar 2009
Posts: 12
Rep Power: 17
sung is on a distinguished road
Hi Henry
Thanks for so many informative responses.
I am running the simpleFoam for a pipe with multiple outlets. Can I still set all of the outlets to be zeroGradient pressure and velocity? Some strange result is obtained when I do that. One outlet branch's flux is almost zero which is wrong.
sung is offline   Reply With Quote

Old   April 19, 2005, 19:45
Default I am not sure if the problem i
  #16
Senior Member
 
Join Date: Mar 2009
Posts: 854
Rep Power: 22
henry is on a distinguished road
I am not sure if the problem is well-posed if you specify zeroGradient pressure and velocity on multiple outlets without further specification. I seem to remember people also specifying the outflow split for multiple outflows, are you familar with doing this? Have you run such cases with other codes?
henry is offline   Reply With Quote

Old   April 20, 2005, 02:35
Default I have not done the outflow sp
  #17
New Member
 
Kim Sung
Join Date: Mar 2009
Posts: 12
Rep Power: 17
sung is on a distinguished road
I have not done the outflow split stuff before. We run the same geometry with Fidap, it works. However, in Fidap, users only need to specify the velocity BCs for inlet and outlets (fixed flux for inlet and zeroGradient for outlets in our case).
sung is offline   Reply With Quote

Old   April 20, 2005, 02:40
Default You definitely need the outflo
  #18
Senior Member
 
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33
hjasak will become famous soon enough
You definitely need the outflow split, otherwise the split from the first iteration of the solver will be preserved. Since the solution after the first iteration is pretty bad, your solution probably looks silly.

Specifying just inlet and outlet gives you a class of equivalent solutions and nothing to correct it so you need additional specification. Other codes behave in various ways: Star uses outflow split and I am pretty sure Fidap uses pressure outlet oundary where this issue does not occur.

Enjoy,

Hrv
__________________
Hrvoje Jasak
Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk
hjasak is offline   Reply With Quote

Old   April 20, 2005, 03:35
Default Hi Hrv, Thanks. Could you poi
  #19
New Member
 
Kim Sung
Join Date: Mar 2009
Posts: 12
Rep Power: 17
sung is on a distinguished road
Hi Hrv,
Thanks. Could you point out a reference dealing with the outflow split for me?
sung is offline   Reply With Quote

Old   April 20, 2005, 04:11
Default Could you please explain in mo
  #20
Senior Member
 
Join Date: Mar 2009
Posts: 854
Rep Power: 22
henry is on a distinguished road
Could you please explain in more detail the outlet boundary conditions you used in Fidap for both velocity and pressure because it is not clear from what you have written.
henry is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Outlet Boundary Conditions benbru Siemens 2 October 2, 2007 08:46
Outlet Boundary Conditions for LES garni FLUENT 1 November 29, 2006 14:52
Boundary conditions at outlet bajjal FLUENT 0 July 13, 2006 09:16
outlet Boundary conditions sivasamy Main CFD Forum 2 December 19, 2005 02:01
Outlet boundary conditions hicham FATNASSI Main CFD Forum 8 February 9, 2000 03:58


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