CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM (https://www.cfd-online.com/Forums/openfoam/)
-   -   Bondary conditions in OpemFOAM (https://www.cfd-online.com/Forums/openfoam/76102-bondary-conditions-opemfoam.html)

P.Satish May 14, 2010 05:36

Bondary conditions in OpemFOAM
 
Hi All!

I am new to this openfoam and coming across small small doubts.

In fluent, if there is a simple pipe flow, with inlet velocity and pressure outlet boundary case. we specify directly the velocity value at inlet and pressure value(for example o Pa) at the outlet.

In Openfoam, for the input boundaries we have two different files U and P.

velocity (U) file
WALL
{
type fixedValue;
value uniform (0 0 0);
}
INLET
{
type fixedValue;
value uniform (50 0 0);
}
OUTLET
{
type zeroGradient;
}

Pressure (p) file

WALL
{
type zeroGradient;
}
INLET
{
type zeroGradient;
}
OUTLET
{
type fixedValue;
value 0;
}
}


here we are giving the info of pressure and velocity at all the boundaries in both U and p files.

Instead can I cant give this way?

velocity (U) file
WALL
{
type fixedValue;
value uniform (0 0 0);
}
INLET
{
type fixedValue;
value uniform (50 0 0);
}

Pressure (p) file

WALL
{
type zeroGradient;
}
OUTLET
{
type fixedValue;
value 0;
}

Giving only velocity data at inlet and pressure data at outlet?

Is it compulsory that we have to give the boundary conditions in U and p files at all the boundaries? or can I specify in the second way directly?

Please clarify my query.

rieuk May 14, 2010 08:46

Are you sure that in Fluent when you don't specify a boundary value for p that it is not just assuming a boundary condition for you?

For my cases if I don't know the boundary value either set it to zeroGradient or free stream depending on the boundary.

P.Satish May 14, 2010 08:57

In fluent, u enter the velocity at inlet and pressre value at outlet..it cacculate the values...we no need to specify the pressure and velocity values at all boundaries..

in Openfoam, we are specifying the values of pressure and velocity(whether its a fixed value or gradients) at all the boundaries...

my question is that compuslory that we define the values of p and U(a fixed value or gradient) at all boundaries?

Robat May 14, 2010 10:18

Without identifing the walls the case is not completely defined, even Fluent needs to know the walls. So the programm assumes zeroGradient pressure and fixedValue(0) velocity. But may be inside it's blackBox without telling you.

You need to define every variable for every boundary in OpenFoam in respect to the manifoldness of variables you should create and their different behaviour.
e.g.: a wall is something different for heat transfer in compare to mass flux.

P.Satish May 14, 2010 10:27

wall boundaries are ok..but I am referring to the inlet and outlet boundaries....

Robat May 14, 2010 10:38

Inlet velocity and outlet pressure is well defined.
This way is often recommended in this forum.


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