y+ calculation on rough walls

Questions and remarks about code_saturne usage
Forum rules
Please read the forum usage recommendations before posting.
Post Reply
MaximeO
Posts: 4
Joined: Wed Jul 02, 2025 9:37 am

y+ calculation on rough walls

Post by MaximeO »

Hello,

Does anyone knows how exactly is calculated the y+ on a rough wall (on code_saturne v8.0) ?

I have searched in the theory guide (https://www.code-saturne.org/documentat ... theory.pdf p.58-60) but the rough wall part doesn't really answer this question.

The thing is, when I'm looking at my results, the y+ computed by code_saturne doesn't correspond to the y+ I have calculated with the theoretical formula and the computed wall shear-stress, and there is a huge difference ( on code_saturne while I calculated ), but I may be missing a point here ?

Best regards,
Maxime
Yvan Fournier
Posts: 4235
Joined: Mon Feb 20, 2012 3:25 pm

Re: y+ calculation on rough walls

Post by Yvan Fournier »

Hello,

This is probably computed in src/base/clptrg.f90. So it may be interesting to check/log/print the intermediate values used in its computation.

I'm not sure about the theory part, as there is both a legacy rough wall model, and a new one (continuous "smooth/rough" model). The newer model should be mostly equivalent to the old one in rough wall regions, but some details might change.

Best regards,

Yvan
MaximeO
Posts: 4
Joined: Wed Jul 02, 2025 9:37 am

Re: y+ calculation on rough walls

Post by MaximeO »

Hello Yvan,

Thank you for your response.

I've checked the clptrg file, and apparently for rough walls it is computed as : (where is the distance from the centre of the wall-adjacent cell to the wall, and is the aerodynamic roughness length). This explain why I had such a low constant value of y+ along my coputational domain.

So now my question is : when we use wall functions, we need in theory to respect a y+ value of at least 20-30 to ensure having the second cell in the log-region. But as I said, the y+ computed by code_saturne is way smaller than the theoretical one (). So which one I should refer to ? This computed y+ isn't it finally just here for coding purposes and don't have any real physical meaning ?

Best regards,

Maxime
Post Reply