CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   wall Function (http://www.cfd-online.com/Forums/openfoam/123701-wall-function.html)

sasanghomi September 19, 2013 04:05

wall Function
 
Hi Foamers,

I have a question about wall functions in openfoam.
I am using k-epsilon turbulence model and I am using kqRWallFunction and epsilonWalFunction . I think the range of Y+ should be between 30 and 300 30<Y+<300 . But in my case the range of yplus is Y+<10 . Please anybody guide me . Can I use another wallFunction with k-epsilon turbulence model? Is there enhanced wall treatment wall function in openfoam?? Can I change only wall function? Actually I want to use k-epsilon model But I want to have another wallFunction. Any idea?

I appreciate any help from you ,
Thanks and best regards,
Sasan.

cfdonline2mohsen September 19, 2013 06:19

Dear Sasan

Here is the source of all the incompressible RAS wall functions that are available in OF: wallFunctions

And they are only Standard wall functions.
So the easier way is to correct your mesh.

sasanghomi September 19, 2013 09:01

Dear Mohsen ,
Thank you very much for your reply.I need compressible wall Functions . Do you know the Y+<5 is a good range ? {for standard wall function} ?

Best regards,
Sasan.

cfdonline2mohsen September 19, 2013 13:22

Dear Sasan

You can find all compressible wall Functions available in OF in here: wallFunctions

As you told; the range of Y+ should be between 30 and 300 30<Y+<300 to use standard wall Functions. Coarsen the mesh in those zones where Y+ are less than 30 and refine the mesh where Y+ are more than 300.

There is another thing that you must notice when using yPlusRAS:
In the older versions of OF, this utility calculated yStar not yplus. I don't know if they fixed this bug or not.
see for example:
http://www.cfd-online.com/Forums/ope...earstress.html
http://www.cfd-online.com/Forums/ope...s-1-7-1-a.html

sasanghomi September 20, 2013 03:17

Dear mohsen,
Thank you very much for your useful reply.
Do you know which version of openfoam have this problem? I am using 1.6 ext (CAE linux) I think the value of Y+ is very low in my case.

cfdonline2mohsen September 20, 2013 04:00

Dear Sasan

Yeah, for OpenFOAMŪ-1.6-ext, it is Ystar not Yplus. have a look at:
https://github.com/Unofficial-Extend...RAS/yPlusRAS.C
and:
https://github.com/Unofficial-Extend...larField.C#L94
Code:

94      scalar yPlus = Cmu25*y[faceI]*sqrt(k[faceCellI])/nuw[faceI];
Which is the definition of Ysatr.

sasanghomi September 20, 2013 04:17

Can I fix this problem? Can you guide me for correction of code? Or Can you attach here the correct code?

I appreciate any help from you,
Thanks and best regards

cfdonline2mohsen September 20, 2013 04:48

As I told in post #4 see the below links for the correct code:

Problems with YPlusRAS and wallShearStress
Definition of y+ in yPlusRAS (1.7.1)

sasanghomi September 21, 2013 09:53

Hi Dear Mohsen,

I used the attached file in the #8 of below thread
http://www.cfd-online.com/Forums/ope...earstress.html

I am using OP 1.6 ext so I changed option file :
- lgenericPatchFields------>>> -lmeshTools \
-lsampling

after compiling the code (wmake) I used this utility for my case But unfortunately I got zero value for all yplus everywhere . Please help me for getting correct code .

I appreciate any help from you
Thanks and best regards,
Sasan.

P.S. Also the attached file in #5 doesn't work for compressible flow.


All times are GMT -4. The time now is 14:27.