Error in implementation of blending wall functions in nutkWallFunction and nutUWallFunction
Summary
When the blending weights are applied to turbulent wall function to find the effective turbulent viscosity at the wall (like in nutkWallFunction or nutkWallFunction classes), the final result is not coherent with the one reported in the reference papers (for example, see eq. 33 in Popovac, M., & Hanjalić, K. (2007), "Compound wall treatment for RANS computation of complex turbulent flows and heat transfer" or eq. 34 in Knopp, T., Alrutz, T., & Schwamborn, D. (2006) "A grid and flow adaptive wall-function method for RANS turbulence modelling"). This is because of incorrect implementation of the equations.
Steps to reproduce
Example case
What is the current bug behaviour?
The blending weights are applied to relative viscosities (nu - nu_molecular, in the code: nutVis = 0, nutLog = nuEff - nuw) instead of effective viscosities of the sub-regions. This works well only with the STEPWISE and MAX methods, while with the other methods (BINOMIAL, EXPONENTIAL and TANH) the contribution of the viscous sub-layer and of the log-law layer are not weighted as expected.
What is the expected correct behavior?
Relevant logs and/or images
Environment information
- OpenFOAM version : v2212
- Operating system : Mint 21.1
- Hardware info :
- Compiler :
Possible fixes
The blending weights should be applied to effective viscosities of the viscous sub-layer and of the log-law layer. Then, the molecular viscosity should be removed from the result of the weighting process before returning the final value of nutw. In this way, the expected effective viscosity at the wall is correctly recovered.