37 namespace incompressible
42 scalar alphatJayatillekeWallFunctionFvPatchScalarField::tolerance_ = 0.01;
43 label alphatJayatillekeWallFunctionFvPatchScalarField::maxIters_ = 10;
49 if (!isA<wallFvPatch>(patch()))
52 <<
"Invalid wall function specification" <<
nl 53 <<
" Patch type for patch " << patch().name()
54 <<
" must be wall" <<
nl 55 <<
" Current patch type is " << patch().type() <<
nl <<
endl 66 return 9.24*(
pow(Prat, 0.75) - 1.0)*(1.0 + 0.28*
exp(-0.007*Prat));
81 scalar df = 1.0 - 1.0/(ypt*
kappa_*Prat);
82 scalar yptNew = ypt - f/df;
111 fixedValueFvPatchScalarField(p, iF),
130 fixedValueFvPatchScalarField(ptf, p, iF, mapper),
148 fixedValueFvPatchScalarField(p, iF, dict),
164 fixedValueFvPatchScalarField(wfpsf),
181 fixedValueFvPatchScalarField(wfpsf, iF),
209 internalField().
group()
213 const scalar Cmu25 =
pow(
Cmu_, 0.25);
231 transportProperties.
lookup(
"Pr")
239 label celli = patch().faceCells()[facei];
242 scalar
yPlus = Cmu25*
sqrt(k[celli])*y[facei]/nuw[facei];
252 if (yPlus > yPlusTherm)
254 scalar nu = nuw[facei];
256 alphatw[facei] =
max(0.0, kt);
260 alphatw[facei] = 0.0;
275 writeEntry(
"value", os);
const char *const group
Group name for atomic constants.
dimensionedScalar Pr("Pr", dimless, laminarTransport)
#define forAll(list, i)
Loop across all elements in list.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
dimensionedScalar log(const dimensionedScalar &ds)
A list of keyword definitions, which are a keyword followed by any number of values (e...
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
const Boundary & boundaryField() const
Return const-reference to the boundary field.
virtual void write(Ostream &) const
Write.
scalar Cmu_
Cmu coefficient.
alphatJayatillekeWallFunctionFvPatchScalarField(const fvPatch &, const DimensionedField< scalar, volMesh > &)
Construct from patch and internal field.
dimensionedScalar sqrt(const dimensionedScalar &ds)
Ostream & endl(Ostream &os)
Add newline and flush stream.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
Abstract base class with a fat-interface to all derived classes covering all possible ways in which t...
scalar Psmooth(const scalar Prat) const
`P' function
label k
Boltzmann constant.
virtual void write(Ostream &) const
Write.
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
Macros for easy insertion into run-time selection tables.
virtual tmp< volScalarField > k() const =0
Return the turbulence kinetic energy.
IOdictionary is derived from dictionary and IOobject to give the dictionary automatic IO functionalit...
Templated abstract base class for single-phase incompressible turbulence models.
dimensionedScalar exp(const dimensionedScalar &ds)
scalar yPlusTherm(const scalar P, const scalar Prat) const
Calculate y+ at the edge of the thermal laminar sublayer.
static const word propertiesName
Default name of the turbulence properties dictionary.
static word groupName(Name name, const word &group)
This boundary condition provides a kinematic turbulent thermal conductivity for using wall functions...
Foam::fvPatchFieldMapper.
makePatchTypeField(fvPatchScalarField, alphatJayatillekeWallFunctionFvPatchScalarField)
const nearWallDist & y() const
Return the near wall distances.
bool readScalar(const char *buf, doubleScalar &s)
Read whole of buf as a scalar. Return true if succesful.
errorManip< error > abort(error &err)
An Ostream is an abstract base class for all output systems (streams, files, token lists...
Ostream & writeKeyword(const keyType &)
Write the keyword followed by an appropriate indentation.
virtual void checkType()
Check the type of the patch.
scalar Prt_
Turbulent Prandtl number.
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
const dimensionSet dimless(0, 0, 0, 0, 0, 0, 0)
T lookupOrDefault(const word &, const T &, bool recursive=false, bool patternMatch=true) const
Find and return a T,.
scalar kappa_
Von Karman constant.
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
dimensioned< scalar > mag(const dimensioned< Type > &)
A class for managing temporary objects.
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
virtual tmp< volScalarField > nu() const
Return the laminar viscosity.