diff --git a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/nutWallFunctions/nutSpalartAllmarasWallFunction/nutSpalartAllmarasWallFunctionFvPatchScalarField.C b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/nutWallFunctions/nutSpalartAllmarasWallFunction/nutSpalartAllmarasWallFunctionFvPatchScalarField.C index 9fcdbc8a5..b53cb284b 100644 --- a/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/nutWallFunctions/nutSpalartAllmarasWallFunction/nutSpalartAllmarasWallFunctionFvPatchScalarField.C +++ b/src/turbulenceModels/incompressible/RAS/derivedFvPatchFields/wallFunctions/nutWallFunctions/nutSpalartAllmarasWallFunction/nutSpalartAllmarasWallFunctionFvPatchScalarField.C @@ -52,9 +52,9 @@ nutSpalartAllmarasWallFunctionFvPatchScalarField::calcNut() const const scalarField magGradU = mag(Uw.snGrad()); const scalarField& nuw = turbModel.nu().boundaryField()[patchI]; - return max + return Foam::max ( - 0.0, + scalar(0), sqr(calcUTau(magGradU))/(magGradU + ROOTVSMALL) - nuw ); }