CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Wall fuction in openFoam (https://www.cfd-online.com/Forums/openfoam-solving/144705-wall-fuction-openfoam.html)

Alessandro89 November 19, 2014 17:21

Wall fuction in openFoam
 
hello guys,
I wanted clarification on the use of wall function in OpenFOAM. I have indeed performed a simulation of flow around two cylinders in tandem at Re = 200, using the k-wSST model. I used the wall function and the results are good, but I found an anomaly as running the command yplusRAS the output is <3, and as I read the WF in this region should not work: how does Openfoam behaves with wall function?
Then i run a simulation with the same conditions without using the wall function but results are bad..have you got any idea?
thanks

Phil_ November 20, 2014 07:34

Hello Alessandro,

for the highRe-approach (wall functions) the y+ of your first cell should be indeed between 30 and 200, preferably close to 30.

What do you mean by "without using the wall functions"?
Do you use a lowRe-approach instead with the correct boundary conditions
(U=0, k=1e-12, omega=omegaWallFunction, nut=calculated or 1e-12)?
For the lowRe approach y+ should be smaller than 1 for your first cell and you need enough cells in the boundary layer.

Best regards

Philip

Alessandro89 November 20, 2014 08:27

Hi Philip,
i know that for the highRe-approach (wall functions) the y+ of your first cell should be indeed between 30 and 200, why does yPlusRAS provide between 2-3?

In lowRe-approach ("without wall function") i used k=1e-5 e omega=1e-5..why does it need to used omegawallFunction?
Thanks
Best Regards

Alessandro

RodriguezFatz November 20, 2014 08:59

Alessandro, yPlusRAS calculates the y+ that is actually there. So if it says 2-3, than y+ is between 2 and 3. If you want to use wall functions in that case, your mesh is much to fine at the wall.

In lowRe approach (as always), omega needs to be high at the wall, not low as you state. Theoretically, it goes to infinity at the wall. For numerical simulations, this doesn't work, so some very high values are chosen. The actual value differs from paper to paper, but one regular way is provided by "omegWallFunction". It automatically switches from high- to low-Re boundary condition, depending on the y+ of your flow.

Alessandro89 November 20, 2014 09:57

I used the wall function in that case and the results are good, I do not understand this: the wall function will work even if I yplus <30..why?

Thanks

RodriguezFatz November 20, 2014 10:01

Well, since the omega wall function automatically switches from high to low-Re mode it won't make any problems in that case. But I guess your k-wall function will be a wrong boundary condition. Using a wrong b.c. doesn't mean your case can't converge... also the result can be coincidentally correct.
What means "the results are good"?

Alessandro89 November 20, 2014 10:17

Means that the results are in agreement with those reported in literature;
now i read in other posts that yPlusRAS calculates y* instead y+..is it true?what is the difference?

this is k' Bc:

boundaryField
{
In
{
type fixedValue;
value uniform $turbulentKE;
}
Out
{
type inletOutlet;
inletValue $internalField;
value $internalField;
}
Left&Right
{
type empty;

}
Wall
{
type kqRWallFunction;
value $internalField;
}
}

turbulentKE= 6.9646e-1

RodriguezFatz November 20, 2014 10:36

Quote:

Originally Posted by Alessandro89 (Post 520201)
Means that the results are in agreement with those reported in literature;

Yes, but which results? What value? You did not write what you are looking for with your simulations.

Alessandro89 November 20, 2014 10:43

Time course of Cd and Cl, and Strouhal number

RodriguezFatz November 21, 2014 04:19

1 Attachment(s)
Just an idea: Have a look at the picture. It shows "k" over "y" for a channel flow, with low-Re k-omega-sst model. My boundary condition was of course k=0, but as you can see, the gradient of k at y=0 is also very low. So maybe your boundary condition (zeroGradient) for k was not that bad at all.
Attachment 35371
Looks like you unintentionally made low-Re simulations. Anyone likes that idea?:confused:


All times are GMT -4. The time now is 09:51.