CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM (https://www.cfd-online.com/Forums/openfoam/)
-   -   nutWallFunction (https://www.cfd-online.com/Forums/openfoam/86157-nutwallfunction.html)

 kurne March 16, 2011 01:57

nutWallFunction

Dear All
I am using k − ω-SST in which i am unable to understand the wall functions i.e. nutWallFunction,nutRoughWallFunction etc.Will anybody tell me what it is,How to calculate and for what it is.

 kurne March 17, 2011 03:56

Dear All
Got the answer thanks to all.

 idrama March 18, 2011 07:52

Hey kurne,

wall functions are used to model the velocity profile at the first node to the wall. Model based on magnitudes such as k, epsilon, nut, wall shear stress, friction velocity and so on. Therefore, the implemented function, e.g. epsilonWallFunction, provide the computation of the law of the wall.
Instead using them, you need to resolve the boundary layer such that the transition from laminar to turbulent can be captured.

Cheers

 kurne March 18, 2011 08:05

Dear Claus Meister

Thank you very much for the answer, in the real sense i understood the meaning of wall function but i stuck up with the nut wall function but after going through the forum and upon your reply i got the correct concept.

Well, want to ask you one silly question do you know how to calculate the nutWallFunction at the inlet if we are having the data at inlet say velocity,turbulence intensity,turbulence kinetic energy and turbulence energy dissipation rate.If you know then please tell me.But i got the information from the forum that initial value of 0 is generally used.

Thanks Once Again.

 idrama March 18, 2011 09:06

The wall function are only used at the wall and not at a inlet or outlet patch. Since the nut value is composed of k and epsilon, you should set a "calculated" BC at the inlet and the outlet, respectively. A "calculated" BC means that the values at the respective patch are computed by other magnitudes.

Cheers

 kurne March 19, 2011 00:05

Dear Claus Yes thats right but when i go through the tutorials of OpenFOAM 1.7.1 of mixer in simpleSRFFoam solver. I found the nut directory in 0 file.When i remove the nut file from the 0 directory the solver wont run.
It means that the value of nut is required at 0 directory with the value at inlet,outlet and other patches too,Correct me if i am wrong.So i asked that how to calculate the value of nut at inlet and outlet.

 idrama March 20, 2011 19:15

You dont have to calculate the nut values for inlet and outlet. You just have to set:

inlet
{
type calculated;
value uniform 0;
}

wall
{
type nutWallFunction;
value uniform 0;
}

etc.

hope that helps

 kurne March 21, 2011 01:23

Dear Claus

Thank you very much for answering to my query.Well, is it possible to calculate the value of nutWallFunction at the patches other than inlet and outlet.If yes will you please tell me how.

I know that my queries are silly hence sorry for it.

 Anne Lincke October 28, 2011 06:01

Quote:
 Originally Posted by kurne (Post 299790) Dear All Got the answer thanks to all.

Hey Kurne,

I am investigating about the nutWallFunction and I do not really understand the formula used in OpenFOAM in nutWallFunction which reads

nutw[faceI] = nuw[faceI]*(yPlus*kappa_/log(E_*yPlus) - 1.0);

Can you please explain your findings? I found this question in some threads so I think me and other users will be very grateful.

 idrama October 28, 2011 07:06

Loop up in Versteeg pp. 275ff; there is a description about the entire procedure. I used by my self yesterday.

Cheers

 Anne Lincke November 2, 2011 04:00

Thank you very much. I borrowed the book and will post my findings here as soon as possible.

 sam1364 November 25, 2011 23:26

nutkwallfunction

Hello everyone :)

I have recently started working with OpenFoam. I am now solving cavity problem in 3D. for turbulence model, I selected RANS and k-epsilon. for wall function, I selected nutkwallfunction. However, I could not find type of wall functions (how the wall function is defined) anywhere except from the c++ documentary which was not clear to me. I would be grateful if you could tell me what specific wall functions are used in nutkwallfunction.

Thanks,

 Anne Lincke November 28, 2011 04:18

You can have a look at

~/OpenFOAM/OpenFOAM-1.7.0/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions>

There you will find all kind of wall functions.
Especially for your wall function it is written in the .H file

Class
Foam::incompressible::RASModels::nutkWallFunctionF vPatchScalarField

Description
Boundary condition for turbulent (kinematic) viscosity when using wall
functions, based on turbulence kinetic energy.
- replicates OpenFOAM v1.5 (and earlier) behaviour

At first glance I could not see any differences between nutWallFunction and nutkWallFunction....

 romant November 28, 2011 04:20

Quote:
 Originally Posted by sam1364 (Post 333613) Hello everyone :) I have recently started working with OpenFoam. I am now solving cavity problem in 3D. for turbulence model, I selected RANS and k-epsilon. for wall function, I selected nutkwallfunction. However, I could not find type of wall functions (how the wall function is defined) anywhere except from the c++ documentary which was not clear to me. I would be grateful if you could tell me what specific wall functions are used in nutkwallfunction. Thanks,
the boundary condition nutkWallFunction sets the turbulent viscosity in the first node point based on the logarithmic law of the wall http://en.wikipedia.org/wiki/Law_of_the_wall . the difference between the nutUWallFunction and the nutkWallFunction lies in the way yPlus is calculated (in the first case based on the velocity close to the wall and in the latter case based on the turbulent kinetic energy close to the wall)

 Anne Lincke November 28, 2011 04:23

What version do you use?
I cannot find nutUWallFunction at OF-1.7.

When looking at the source code of nutWallFunction I see the same computation of yPlus like in nutkWallFunction, based on turbulent kinetic energy....

 romant November 28, 2011 04:25

Quote:
 Originally Posted by Anne Lincke (Post 333757) What version do you use? I cannot find nutUWallFunction at OF-1.7. When looking at the source code of nutWallFunction I see the same computation of yPlus like in nutkWallFunction, based on turbulent kinetic energy....
In 2.0 more nutWallFunction boundary conditions were introduced, one of them nutUWallFunction, where basically the way of how yPlus is calculated is changed.

 Anne Lincke November 28, 2011 04:28

Okay, thank you for this information!

Can you also explain the computation of nut at the wall function, especially this formula

nutw[faceI] = nuw[faceI]*(yPlus*kappa_/log(E_*yPlus) - 1.0);

Is it derived from the logLaw? How?

 romant November 28, 2011 05:36

log law in compact version

Hej,

I just found how this is derived and calculated it myself, http://www.cfd-online.com/Wiki/Two_e...wall_functions

if you see how the rho is eliminated, maybe you can post it here.

solution to eliminate rho:
Code:

```(mut+mu)Up/yP = (rho y uTau kappa )/(log(yPlus E)) =1/rho (mut+mu)Up/yP = ( y uTau kappa )/(log(yPlus E)) = (nut+nu)Up/yP = ( y uTau kappa )/(log(yPlus E))```
and then from there by using the definition of yPlus, one obtains equation (2)

 Anne Lincke November 28, 2011 06:40

Thank you so much!
Now I understand the derivation.
There is one typo on the site, the missing density at the definition of tau_w,
But there is no problem as the whole equation

rho (nut + nu) * up/yp = (rho *u_tau *kappa *u) / ln (E y+)

can simply be divided by rho.

 romant November 28, 2011 06:50

Quote:
 Originally Posted by Anne Lincke (Post 333783) Thank you so much! Now I understand the derivation. There is one typo on the site, the missing density at the definition of tau_w, But there is no problem as the whole equation rho (nut + nu) * up/yp = (rho *u_tau *kappa *u) / ln (E y+) can simply be divided by rho.
I changed it on the wiki page, it should be OK now

All times are GMT -4. The time now is 17:57.