0
Inlet Velocity

Hi
My inlet velocity profile is Ux=0.011451/((0.052458+y^2)^0.5), and Uy=0.05y/((0.052458+y^2)^0.5) for diffuser width 0.02 m.

I am using OPENFOAM in windows 10. Can you kindly tell me what should I do?


OpenFOAM 28-06-19, 6:23 p.m. moghimi4999
0

Please try this Boundary condition.

inlet
{
type codedFixedValue;
value uniform (0 0 0);
name varyinginletBC; //name of new BC
code
#{
const fvPatch& boundaryPatch = patch(); //get patch
const vectorField& Cf = boundaryPatch.Cf(); //get face center coordinates
vectorField& field = *this;

forAll(Cf,facel)
{
scalar y = Cf[facel].y();
field[facel] = vector(0.011451/(sqrt(0.052458+sqr(y))),0.05*y/(sqrt(0.052458+sqr(y))),0);
}
#};
}
07-05-20, 2:03 a.m. divyesh


0

There is another option available called groovyBC. Please check this:

http://openfoamwiki.net/index.php/Contrib/groovyBC

07-05-20, 2:28 a.m. divyesh


Log-in to answer to this question.