51 (KsPlus - 2.25)/87.75 + Cs*KsPlus,
52 sin(0.4258*(
log(KsPlus) - 0.811))
57 return (1.0 + Cs*KsPlus);
71 internalField().
group()
87 label faceCelli = patch().faceCells()[facei];
89 scalar uStar = Cmu25*
sqrt(k[faceCelli]);
90 scalar
yPlus = uStar*y[facei]/nuw[facei];
91 scalar KsPlus = uStar*
Ks_[facei]/nuw[facei];
99 scalar limitingNutw =
max(nutw[facei], nuw[facei]);
116 Info<<
"yPlus = " << yPlus
117 <<
", KsPlus = " << KsPlus
118 <<
", Edash = " << Edash
119 <<
", nutw = " << nutw[facei]
199 nutkWallFunctionFvPatchScalarField::autoMap(m);
211 nutkWallFunctionFvPatchScalarField::rmap(ptf, addr);
214 refCast<const nutkRoughWallFunctionFvPatchScalarField>(ptf);
227 writeEntry(
"value", os);
virtual scalar fnRough(const scalar KsPlus, const scalar Cs) const
Compute the roughness function.
const char *const group
Group name for atomic constants.
virtual void rmap(const fvPatchScalarField &, const labelList &)
Reverse map the given fvPatchField onto this fvPatchField.
#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)
const double e
Elementary charge.
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 > &)
virtual tmp< volScalarField > nu() const =0
Return the laminar viscosity.
dimensionedScalar sqrt(const dimensionedScalar &ds)
Ostream & endl(Ostream &os)
Add newline and flush stream.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
dimensionedScalar pow025(const dimensionedScalar &ds)
This boundary condition provides a turbulent kinematic viscosity condition when using wall functions ...
void writeEntry(const word &keyword, Ostream &os) const
Write the field as a dictionary entry.
Abstract base class with a fat-interface to all derived classes covering all possible ways in which t...
virtual void autoMap(const fvPatchFieldMapper &)
Map (and resize as needed) from self given a mapping object.
label k
Boltzmann constant.
Abstract base class for turbulence models (RAS, LES and laminar).
Macros for easy insertion into run-time selection tables.
virtual tmp< volScalarField > k() const =0
Return the turbulence kinetic energy.
virtual void writeLocalEntries(Ostream &) const
Write local wall function variables.
makePatchTypeField(fvPatchVectorField, SRFFreestreamVelocityFvPatchVectorField)
virtual tmp< scalarField > yPlus() const
Calculate and return the yPlus at the boundary.
static const word propertiesName
Default name of the turbulence properties dictionary.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
static word groupName(Name name, const word &group)
Foam::fvPatchFieldMapper.
virtual label size() const
Return size.
scalar kappa_
Von Karman constant.
scalarField Cs_
Roughness constant.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
dimensionedScalar sin(const dimensionedScalar &ds)
nutkRoughWallFunctionFvPatchScalarField(const fvPatch &, const DimensionedField< scalar, volMesh > &)
Construct from patch and internal field.
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
void autoMap(const FieldMapper &map, const bool applyFlip=true)
Map from self.
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
void rmap(const UList< Type > &mapF, const labelUList &mapAddressing)
1 to 1 reverse-map from the given field
scalar Cmu_
Cmu coefficient.
scalarField Ks_
Roughness height.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
virtual void write(Ostream &) const
Write.
A class for managing temporary objects.
T & ref() const
Return non-const reference or generate a fatal error.
virtual tmp< scalarField > calcNut() const
Calculate the turbulence viscosity.
const nearWallDist & y() const
Return the near wall distances.
nutkWallFunctionFvPatchScalarField(const fvPatch &, const DimensionedField< scalar, volMesh > &)
Construct from patch and internal field.
virtual void write(Ostream &) const
Write.