CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   velocity cyclic BC-groovyBC (http://www.cfd-online.com/Forums/openfoam/97463-velocity-cyclic-bc-groovybc.html)

zxj160 February 17, 2012 11:51

velocity cyclic BC-groovyBC
 
Hi,

1 How to set a fixedvalue of velocity to the cyclic BC?
2 But the pressure is not cyclic, how to set a fixedgradient of pressure?

--> FOAM FATAL IO ERROR:
inconsistent patch and patchField types for

I want to set the following fixedvalue using groovyBC. How to do that?

inlet
{
type cyclic;
type groovyBC;
//type fixedValue
// log-law expression
uniform (0 0 0);
variables "u_f=0.23;z0=0.9;z_f=pos().z-10;vel=u_f*log(z_f/z0);";
valueExpression "vector (vel,0,0)";
}

outlet
{
type cyclic;
type groovyBC;
//type fixedValue
// log-law expression
uniform (0 0 0);
variables "u_f=0.23;z0=0.9;z_f=pos().z-10;vel=u_f*log(z_f/z0);";
valueExpression "vector (vel,0,0)";
}

nimasam February 18, 2012 08:47

i think its impossible, you should write your BC, with existing BC you can not!

zxj160 February 18, 2012 11:12

But I have installed the groovyBC. You mean I should write another BC? I donot know how to do that.

1 How to set a fixedvalue of velocity to the cyclic BC (inlet and outlet)?
2 But the pressure is not cyclic, how to set a fixedgradient of pressure?

nimasam February 18, 2012 12:48

i think you should write new BC
however try this, may be it works
1) use funkySetFields and define your velocity function in whole domain at time 0
2) uses a fan boundary condition with one constant ( constant value is the fixed pressure gradient * pipe length)

gschaider February 19, 2012 19:40

Quote:

Originally Posted by zxj160 (Post 344970)
Hi,

1 How to set a fixedvalue of velocity to the cyclic BC?
2 But the pressure is not cyclic, how to set a fixedgradient of pressure?

--> FOAM FATAL IO ERROR:
inconsistent patch and patchField types for

I want to set the following fixedvalue using groovyBC. How to do that?

inlet
{
type cyclic;
type groovyBC;
//type fixedValue
// log-law expression
uniform (0 0 0);
variables "u_f=0.23;z0=0.9;z_f=pos().z-10;vel=u_f*log(z_f/z0);";
valueExpression "vector (vel,0,0)";
}

outlet
{
type cyclic;
type groovyBC;
//type fixedValue
// log-law expression
uniform (0 0 0);
variables "u_f=0.23;z0=0.9;z_f=pos().z-10;vel=u_f*log(z_f/z0);";
valueExpression "vector (vel,0,0)";
}

Basically the problem is that a patch defined in the mesh as cyclic will accept no other boundary type than cyclic for fields (no groovyBC, no fixedValue, no ...).

zxj160 July 2, 2012 11:30

Quote:

Originally Posted by gschaider (Post 345218)
Basically the problem is that a patch defined in the mesh as cyclic will accept no other boundary type than cyclic for fields (no groovyBC, no fixedValue, no ...).

Hi gschaider,

Could you give me some idea of how to set fixedValue and zeroGradient for cyclic inlet and outlet patches respectively? Is it possible to achieve that?

Best regards,
Jian


All times are GMT -4. The time now is 21:36.