CFD Online Discussion Forums

CFD Online Discussion Forums (
-   CFX (
-   -   Computation of Y+ is not correct (

Lukas90 January 27, 2014 05:07

Computation of Y+ is not correct
1 Attachment(s)
Hello CFD-users,

My task is a comparison between low-Re- and high-Re-models for some test cases. For my first case (asymmetric plane diffuser 2D) I've chosen the SST-model with an automatic wall treatment in ansys. So I used two different meshes, first with Y+ = 1 and second with Y+ = 50.
In CFD- Post I exported my data for some CUT-Lines and wanted to plot u+ / log y+ as you can see in the attachment. Attachment 28283
The export-data includes only the first y+ -value, so I have to compute the next manually.
But here is my Problem and I hope somebody could help me, the value of computed y+ by myself differs from the value of export data.
e.g. Y+ = 52 (Post export)
Y+ = 42 (manually computed)
For the computation I used following equation:
Y+ = (u_tau*delta_y) / nu

I tried a lot of different things, but I think the problem is the chosen wall distance delta_y. For this I exported the values x,y,z and wall distance in Post but all of them doesn't bring me to the right y+ value.
Does anyone know how to calculate the right wall distance by the exported data of CFD post???

I hope somebody could help me.

p.s. sorry for my bad english ;)

ghorrocks January 27, 2014 18:07

Have you read the discussion in the documentation on y+? It describes the calculation of y+ and some things to be careful of.

Lukas90 January 28, 2014 05:44

At first, thank you for your answer.

Of course I read a lot about the estimation of y+. I tried to solve my problem with books like "turbulence modeling [wilcox]" or "grenzschicht-theorie [schlichting]" but I didn't find the solution. Also I tried every possible estimation I found out, but only with moderate success.

That's why i hope for any help by this forum. ;)

I will try to explain my problem some more detailed:

For my mesh in ICEM i estimated the value of y (spacing 1 and 2 for my pre-mesh params) approximately by the given equations. Therefore i get good results for y+ around 50 in post. Then i exported some data at different locations (cut-lines) in post and there is my first problem:

The second and not the first point of exported y / wall distance is equal to the defined value in ICEM (spacing 1/2). In this point i don't understand ANSYS and the estimation.
I hope you understand my confused explanation ;)

p.s. please send me a link, which discussion about y+ you mean, i read a lot but i didn't find out the right one :(

Lukas90 January 28, 2014 05:53

1 Attachment(s)
Perhaps this part of my data could help for understanding my problem.
Y is the vertical direction of my coordinate frame. But i think i have to use the value "wall distance" for the estimation...

Attachment 28314

flotus1 January 28, 2014 06:21

Maybe the difference between "hybrid" and "conservative" values in CFX causes the difference.
How did you determine the value of u_tau?
BTW are you sure that your wall has y=0? It is kind of strange that the wall distance does not match the value of y.

ghorrocks January 28, 2014 06:35

I think Alex might be on the right track. Are you sure you are correctly handling the hybrid and conservative values? For instance, are you aware that the control volume which contains the wall has its centroid away from the wall so it has a non-zero value of velocity? The difference you are seeing could be that you are using conservative values of the control volume centroid when the true y+ exists at the wall.

Lukas90 January 28, 2014 07:24

I determined u_tau -> u_tau = sqrt(wallshearX/rho)

I'm not sure if i understand all of them right. I was also surprised by the difference of y and wall distance but my academic advisor said it could be and i should find out how to calculate the true wall distance right.
I thought the option "no slip wall" gives the boundary condition U=0 at the wall?!

Where i have to choose between hybrid and conservative? I have this option e.g. for export the data in CFX Post. I tried that, but there were also the same discrepancies for both options.

Sorry for my lack of knowledge...

flotus1 January 28, 2014 08:39

It is unusual that YPlus and the wall shear stress are even defined at the second node off the wall.

I guess we should take one step back and see how you defined the line to export your data. As always, a picture would be nice.

Lukas90 January 28, 2014 09:31

1 Attachment(s)
Ich habe mich mal auf Grund ihres Standortes entschieden auf deutsch zu schreiben ;)

Hier das Bild mit den eingefügten Lines:
Attachment 28330

Ich hoffe das hier kein Fehler vorliegt, da ich darauf extra von meinem Betreuer hingewiesen wurde, eine CUT-Line zu verwenden.

Die berechnete Wandschubspannung für den zweiten Knoten erfolgt in der Regel nicht, in 90% der Fälle nur für den ersten Knoten. Allerdings ist mir das wie in diesem Fall auch schon aufgefallen, allerdings konnte ich es mir nicht erklären und hab es erstmal so hingenommen.

Vielen Dank für Ihr bisheriges Interesse und ihre Hilfe

flotus1 January 28, 2014 10:37

Damit das auch für alle nachvollziehbar bleibt und weil wir auch auf die Hilfe Anderer nicht verzichten wollen würde ich vorschlagen dass wir bei Englisch bleiben. So schlecht ist es ja nun auch wieder nicht.

A line type "Cut" is the right choice, dont worry.
Does your mesh have more than one element in z-direction? And did you use prism layers near the wall? If you did not, that is the only way I can think of that produces this kind of result.
Post a picture.

Lukas90 January 28, 2014 11:51

1 Attachment(s)
I have 2 nodes in z-direction, i wanted to do it with only one but ICEM automatically reset it to 2 nodes. Could this be a problem? It should be only a 2-dimensional simulation.

No i didn't use any prism layer near the wall. I only meshed with hexa cells and modified the distance to the wall about pre-mesh-params -> spacing.

Here is the picture for my mesh at the beginning of the diffuser next to the wall: (in this case for y+ = 1)

Attachment 28333

ghorrocks January 28, 2014 17:56


I thought the option "no slip wall" gives the boundary condition U=0 at the wall?!
It does. See FAQ:

Lukas90 January 29, 2014 03:55

Thanks for this link. It gave me an answer to some general questions :)

But i have one more question to this point. Is there only a difference between "hybrid" and "conservative" at the first control volume near to the wall or is it for all nodes over the whole geometry?

I think i will try the export of my data with both options again and will compare. However yesterday there was no really difference, but it could always be that i'm doing something wrong.

To the answer of flotus1:
Is it always necessary to use prism layers near to the wall?

flotus1 January 29, 2014 04:27

I just wanted to make sure that you did not use a tetrahedral mesh near the wall, which could have caused some of the weird results we have seen.
Please dont get irritated by the expression "prism layers", a mesh that only consists of hexahedrons like the one you used is even better.

At least from the explanation in the manual, hybrid and conservative values only affect the first node.

ghorrocks January 29, 2014 06:11

Hybrid and conservative only changes the control volume adjacent to the wall. Internal nodes are the same.

Prism/hex/inflation layers on the wall are not essential for all types of flow. Low Reynolds number flows do not need them, neither do flows where the boundary layer is not important. In both of these cases you can just use tets all the way to the wall. However most CFD work is for high Reynolds number flows where the boundary layer is of some significance. In this case inflation layers are important.

Lukas90 January 30, 2014 16:54

Thanks for both of your answers.

Today i tried the export with "hybrid" and "conservative" boundary data, but in no case the velocity at the first node was zero.
The Wall distance of the first node is also given for example as 0.00007 and not 0. May be this is due to the tolerances in Ansys?!

ghorrocks January 30, 2014 17:42

What location object are you exporting? Are you using a cut or sample approach?

Lukas90 January 31, 2014 04:24

I used a CUT-Line at different locations.

ghorrocks January 31, 2014 04:43

I suspect you cannot do hybrid variables on arbitrary lines, only the original mesh objects. So I suspect you are seeing the conservative values, even when you select hybrid.

Lukas90 February 28, 2014 04:07

2 Attachment(s)
Thanks for your answers.
I have one more question to this topic and hope someone could help me.

I exported my data for the channel in front of my asymmetric plane diffuser and calculated the y+ and u+ value. Attachment 28973

When I plot the values y+ and u+ I get the left behaviour of the curve. But in a channel flow the curves of DNS and RANS (black curve = low-Re / red curve - high-Re with wall-function) should match each other. I think in the viscous sublayer u+ = y+ and so I modified my list (y+ modified) and get good results for all of my results. The uploaded picture is a comparison between both methods but I'm not sure if it is right to do so?

Thanks for your opinions.

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