CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM (https://www.cfd-online.com/Forums/openfoam/)
-   -   Gradient Near the Wall (https://www.cfd-online.com/Forums/openfoam/68750-gradient-near-wall.html)

svens September 30, 2009 16:07

Gradient Near the Wall
 
Hello together

At the moment I'm controlling my OpenFOAM case set ups for turbulent channel flow with Launder-Gibson-RSTM and the turbFoam solver.

I'm using wall functions so I created a grid with first cell size: y+ > 30 (y+ = Tau_wall*y/nu). The evaluation of my results shows huge dependencies of the first cell size (all other conditions - boundaries, initials, etc. are constant - only difference is y+). Specially the plots of friction coefficient cf vs. channel length shows significant variety. Due to this reason I tried to figure out how OpenFOAM is calculation the wall shear stresses.

My search lead my from wallShearStress.C after recognizing that:
wallShearStress = (-mesh.Sf().boundaryField()[patchi]/mesh.magSf().boundaryField()[patchi]) & Reff.boundaryField()[patchi] [Line00076]

and REff is equal to devREff to LaunderGibsonRSTM.C. Here devREff is defined as:
devREff = R_ - nu()*dev(twoSymm(fvc::grad(U_))) [Line00262]

At that point I was asking myself how they specify devREff in the near wall region. Scrolling down in LaunderGibsonRSTM.C I found the code part where they correct the 'Correct the wall shear stresses' [Lines00437].

Am I right that OpenFOAM calculates the first gradient near the wall just with the snGrad() function? And that snGrad() returns an ordinary gradient in the normal direction of surface?

I'm more or less a beginner in CFD and OpenFOAM. Due to that it would be great to hear your comments and oppinions of my way of thinking. Am I wrong?

Thanks pretty much - Sven

svens September 30, 2009 18:53

Hey Stanley (don't wanted to annoy you^^)

But yes you're right - my previous post hadn't been well formulated...

-with '1. gradient near the wall' I want to express the gradient which is created at the 2. node in the internal field (counted in the way that the wall patch is 1. node).

-with 'ordinary gradient' I wanted to discribe a gradient which is created out of the difference between 2 nodes (U2-U1)/(y2-y1). I used 'ordinary' cause I think doing so is pretty coarse for the first cell at the wall. And with normal direction of surface I tried to express - normal direction of a contour surface...

-with am I wrong? I wanted to ask for some mistakes in the way I followed the trace to the interesting gradient.

I hope these additional comments leads to more clearaty and sorry again for my mental dearrangment.

regards - sven


All times are GMT -4. The time now is 02:00.