CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   bounding velocity (http://www.cfd-online.com/Forums/openfoam/91608-bounding-velocity.html)

Farshad_Noravesh August 16, 2011 16:27

bounding velocity
 
Hi,
I want to bound my velocity by the following commands:
volScalarField ux=U.component(0);
volScalarField uy=U.component(1);
volScalarField uz=U.component(2);
ux.max(5);
uy.max(10);
uz.max(0);

but when i monitor min/max of my velocity i see:
(18.58 27.6014 2.57e-15)

please tell me why openfoam does not obey my codes!

Kind Regards,
Farshad

nimasam August 16, 2011 21:39

forAll (U,celli){
U[celli].x()=max( U[celli].x() ,5);
...
}

Farshad_Noravesh August 17, 2011 05:48

problem remains
 
Hi,

Thanks for the code but velocity is still too high at some points inside domain and my problem still remains.

Thanks,

Farshad

nimasam August 17, 2011 14:46

dear farshad
where do u add this code in your solver?
maybe U rewrite again! so change the position of code for example put in pEqn.H

Farshad_Noravesh August 27, 2011 08:54

bounding problem
 
Dear Nima,

I put the code in many places to see if it works but the maximum velocity is still 18 that shoud be 9m/s .
If i dont extend the bounded region i would have the continuity problem and it does not converge.
The interesting thing is if i solve energy equation coupled with momentum equation i get less continuity problems.(maybe because of huge grad(p) in momentum equation)

Thanks,

Farshad

nimasam August 29, 2011 17:01

hi dear farshad
its some how sensible! when you bound the velocity!!! you will encounter continuity problem!!! if you want to reduce maximum velocity maybe you need change ur boundary condition, ur initial condition, even ur mesh size and ur mesh type!


All times are GMT -4. The time now is 05:10.