Go to the documentation of this file.
50 (KsPlus - 2.25)/87.75 +
Cs*KsPlus,
51 sin(0.4258*(
log(KsPlus) - 0.811))
56 return (1.0 +
Cs*KsPlus);
64 const label patchi =
patch().index();
71 internalField().
group()
87 const label celli =
patch().faceCells()[facei];
89 const scalar uStar = Cmu25*
sqrt(
k[celli]);
90 const scalar
yPlus = uStar*
y[facei]/nuw[facei];
91 const scalar KsPlus = uStar*
Ks_[facei]/nuw[facei];
99 const scalar limitingNutw =
max(
nutw[facei], nuw[facei]);
117 <<
", KsPlus = " << KsPlus
118 <<
", Edash = " << Edash
119 <<
", nutw = " <<
nutw[facei]
153 Ks_(ptf.
Ks_, mapper),
167 Ks_(
"Ks",
dict,
p.size()),
168 Cs_(
"Cs",
dict,
p.size())
204 nutkWallFunctionFvPatchScalarField::autoMap(m);
216 nutkWallFunctionFvPatchScalarField::rmap(ptf, addr);
219 refCast<const nutkRoughWallFunctionFvPatchScalarField>(ptf);
221 Ks_.rmap(nrwfpsf.
Ks_, addr);
222 Cs_.rmap(nrwfpsf.
Cs_, addr);
232 writeLocalEntries(os);
233 Cs_.writeEntry(
"Cs", os);
234 Ks_.writeEntry(
"Ks", os);
235 writeEntry(
"value", os);
int debug
Static debugging option.
virtual void write(Ostream &) const
Write.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
virtual tmp< volScalarField > nu() const =0
Return the laminar viscosity.
virtual void write(Ostream &) const
Write.
constexpr const char *const group
Group name for atomic constants.
A class for managing temporary objects.
static constexpr const zero Zero
Global zero (0)
dimensionedScalar sin(const dimensionedScalar &ds)
virtual scalar fnRough(const scalar KsPlus, const scalar Cs) const
Compute the roughness function.
static const word propertiesName
Default name of the turbulence properties dictionary.
Ostream & endl(Ostream &os)
Add newline and flush stream.
const nearWallDist & y() const
Return the near wall distances.
virtual void rmap(const fvPatchScalarField &, const labelList &)
Reverse map the given fvPatchField onto this fvPatchField.
label min(const labelHashSet &set, label minValue=labelMax)
Find the min value in labelHashSet, optionally limited by second argument.
#define forAll(list, i)
Loop across all elements in list.
scalar kappa_
von Kármán constant
dimensionedScalar pow025(const dimensionedScalar &ds)
messageStream Info
Information stream (uses stdout - output is on the master only)
nutkRoughWallFunctionFvPatchScalarField(const fvPatch &, const DimensionedField< scalar, volMesh > &)
Construct from patch and internal field.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
virtual void autoMap(const fvPatchFieldMapper &)
Map (and resize as needed) from self given a mapping object.
virtual tmp< scalarField > yPlus() const
Calculate and return the yPlus at the boundary.
dimensionedScalar pow(const dimensionedScalar &ds, const dimensionedScalar &expt)
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
Abstract base class for turbulence models (RAS, LES and laminar).
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
scalar E_
Wall roughness parameter.
dimensionedScalar log(const dimensionedScalar &ds)
Macros for easy insertion into run-time selection tables.
scalarField Ks_
Roughness height.
scalar Cmu_
Empirical model coefficient.
virtual tmp< volScalarField > k() const =0
Return the turbulence kinetic energy.
This boundary condition provides a wall constraint on the turbulent viscosity, i.e....
const std::string patch
OpenFOAM patch number as a std::string.
static const nutWallFunctionFvPatchScalarField & nutw(const turbulenceModel &turbModel, const label patchi)
Return the nut patchField for the given wall patch.
dimensionedScalar sqrt(const dimensionedScalar &ds)
label k
Boltzmann constant.
const dimensionedScalar e
Elementary charge.
virtual tmp< scalarField > calcNut() const
Calculate the turbulent viscosity.
scalarField Cs_
Roughness constant.
Foam::fvPatchFieldMapper.
static word groupName(StringType base, const word &group)
Create dot-delimited name.group string.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
makePatchTypeField(fvPatchScalarField, atmBoundaryLayerInletEpsilonFvPatchScalarField)
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
This boundary condition provides a wall constraint on the turbulent viscosity, i.e....