CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM Pre-Processing (http://www.cfd-online.com/Forums/openfoam-pre-processing/)
-   -   How to use non-uniform boundary condition (http://www.cfd-online.com/Forums/openfoam-pre-processing/108816-how-use-non-uniform-boundary-condition.html)

turbfoam November 2, 2012 02:26

How to use non-uniform boundary condition
 
Hi all,

I need to specify an inlet velocity to the flow inlet (the case is a simple cuboid with flow entering the left and leaving the right side). I considered using the traditional inlet BC openfoam has, but I need to apply cyclic BCs for the inlet and outlet.And if I understand it right, the cyclic BC is applied as

inlet
{
type cyclic;
nFaces 256;
startFace 11520;
matchTolerance 0.0001;
neighbourPatch outlet;
}

outlet
{
type cyclic;
nFaces 256;
startFace 11776;
matchTolerance 0.0001;
neighbourPatch inlet;
}


There is no way I can specify the initial velocity (which is a constant 10 m/s throughout the inlet surface) to the inlet in the above definitions?


So is it that the only option I have is to specify the values of velocity at the inlet is to create a non-uniform field and assign individual velocity values throughout the domain in the form

internalField nonuniform <List>;
{
.....
.....
}

This approach is ok, but I have almost 5 million cells in my mesh and I really have no idea as to which cells correspond to the inlet.

Please guide me what to do here, since I am very new to openfoam..

Thanks in advance!

duongquaphim November 12, 2012 10:27

Hi,

I do not think you can specify velocity with cyclic boundary condition. The driving force will be the pressure. So what you might want to do is to apply a pressure difference between the 'inlet' and 'outlet' of your domain. Then it will be fine, I think.

Duong

chegdan November 12, 2012 13:45

Why not try the mapped patch instead of cyclic? This way you could define an inflow velocity. Otherwise, create or use a solver that has a way to drive the flow at a constant flow rate in a particular direction...like channelFoam.

turbfoam December 18, 2012 17:59

Thank you all for replies. You are right, i cant apply velocity in periodic bc...and channelFoam looks apprppriate for me.


All times are GMT -4. The time now is 18:02.