Skip to content
Snippets Groups Projects
Commit 776f31b9 authored by Andrew Heather's avatar Andrew Heather
Browse files

correct incorrect use of wall distance

parent 3b0dc6e9
Branches
Tags
No related merge requests found
...@@ -162,10 +162,10 @@ void omegaWallFunctionFvPatchScalarField::updateCoeffs() ...@@ -162,10 +162,10 @@ void omegaWallFunctionFvPatchScalarField::updateCoeffs()
label faceCellI = patch().faceCells()[faceI]; label faceCellI = patch().faceCells()[faceI];
scalar yPlus = scalar yPlus =
Cmu25*y[faceCellI]*sqrt(k[faceCellI]) Cmu25*y[faceI]*sqrt(k[faceCellI])
/(muw[faceI]/rhow[faceI]); /(muw[faceI]/rhow[faceI]);
omega[faceCellI] = sqrt(k[faceCellI])/(Cmu25*kappa*y[faceCellI]); omega[faceCellI] = sqrt(k[faceCellI])/(Cmu25*kappa*y[faceI]);
if (yPlus > yPlusLam) if (yPlus > yPlusLam)
{ {
...@@ -173,7 +173,11 @@ void omegaWallFunctionFvPatchScalarField::updateCoeffs() ...@@ -173,7 +173,11 @@ void omegaWallFunctionFvPatchScalarField::updateCoeffs()
(mutw[faceI] + muw[faceI]) (mutw[faceI] + muw[faceI])
*magGradUw[faceI] *magGradUw[faceI]
*Cmu25*sqrt(k[faceCellI]) *Cmu25*sqrt(k[faceCellI])
/(kappa*y[faceCellI]); /(kappa*y[faceI]);
}
else
{
G[faceCellI] = 0.0;
} }
} }
......
...@@ -158,7 +158,7 @@ void omegaWallFunctionFvPatchScalarField::updateCoeffs() ...@@ -158,7 +158,7 @@ void omegaWallFunctionFvPatchScalarField::updateCoeffs()
{ {
label faceCellI = patch().faceCells()[faceI]; label faceCellI = patch().faceCells()[faceI];
scalar yPlus = Cmu25*y[faceCellI]*sqrt(k[faceCellI])/nuw[faceI]; scalar yPlus = Cmu25*y[faceI]*sqrt(k[faceCellI])/nuw[faceI];
omega[faceCellI] = sqrt(k[faceCellI])/(Cmu25*kappa*y[faceCellI]); omega[faceCellI] = sqrt(k[faceCellI])/(Cmu25*kappa*y[faceCellI]);
...@@ -170,6 +170,10 @@ void omegaWallFunctionFvPatchScalarField::updateCoeffs() ...@@ -170,6 +170,10 @@ void omegaWallFunctionFvPatchScalarField::updateCoeffs()
*Cmu25*sqrt(k[faceCellI]) *Cmu25*sqrt(k[faceCellI])
/(kappa*y[faceCellI]); /(kappa*y[faceCellI]);
} }
else
{
G[faceCellI] = 0.0;
}
} }
// TODO: perform averaging for cells sharing more than one boundary face // TODO: perform averaging for cells sharing more than one boundary face
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment