Go to the documentation of this file.
43 fixedValueFvPatchScalarField(
p, iF),
61 fixedValueFvPatchScalarField(ptf,
p, iF, mapper),
62 outletPatchName_(ptf.outletPatchName_),
63 phiName_(ptf.phiName_),
78 fixedValueFvPatchScalarField(
p, iF,
dict),
79 outletPatchName_(
dict.get<
word>(
"outletPatch")),
80 phiName_(
dict.getOrDefault<
word>(
"phi",
"phi")),
81 Q_(
dict.get<scalar>(
"Q")),
82 TMin_(
dict.getOrDefault<scalar>(
"TMin", 0)),
83 TMax_(
dict.getOrDefault<scalar>(
"TMax", 5000))
94 fixedValueFvPatchScalarField(ptf),
95 outletPatchName_(ptf.outletPatchName_),
96 phiName_(ptf.phiName_),
111 fixedValueFvPatchScalarField(ptf, iF),
112 outletPatchName_(ptf.outletPatchName_),
113 phiName_(ptf.phiName_),
137 label outletPatchID =
140 if (outletPatchID < 0)
143 <<
"Unable to find outlet patch " << outletPatchName_
155 const scalarField& outletPatchPhi =
phi.boundaryField()[outletPatchID];
156 scalar sumOutletPatchPhi =
gSum(outletPatchPhi);
158 if (sumOutletPatchPhi > SMALL)
166 scalar averageOutletField =
167 gSum(outletPatchPhi*outletPatchField)/sumOutletPatchPhi;
177 scalar averageOutletField =
178 gSum(outletPatch.
magSf()*outletPatchField)
184 fixedValueFvPatchScalarField::updateCoeffs();
194 os.
writeEntry(
"outletPatch", outletPatchName_);
200 this->writeEntry(
"value", os);
virtual void write(Ostream &) const
Write.
Ostream & writeEntryIfDifferent(const word &key, const T &value1, const T &value2)
Write a keyword/value entry only when the two values differ.
A class for handling words, derived from Foam::string.
Type gAverage(const FieldField< Field, Type > &f)
Basic thermodynamics type based on the use of fitting functions for cp, h, s obtained from the templa...
Abstract base-class for fluid and solid thermodynamic properties.
Type gSum(const FieldField< Field, Type > &f)
label min(const labelHashSet &set, label minValue=labelMax)
Find the min value in labelHashSet, optionally limited by second argument.
const fvBoundaryMesh & boundaryMesh() const
Return boundaryMesh reference.
tmp< faMatrix< Type > > operator==(const faMatrix< Type > &, const faMatrix< Type > &)
const polyBoundaryMesh & boundaryMesh() const
Return boundaryMesh reference.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
label findPatchID(const word &patchName, const bool allowNotFound=true) const
Find patch index given a name, return -1 if not found.
label max(const labelHashSet &set, label maxValue=labelMin)
Find the max value in labelHashSet, optionally limited by second argument.
word dictName() const
The local dictionary name (final part of scoped name)
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
Macros for easy insertion into run-time selection tables.
errorManip< error > abort(error &err)
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
const std::string patch
OpenFOAM patch number as a std::string.
Ostream & writeEntry(const keyType &key, const T &value)
Write a keyword/value entry.
const polyPatch & patch() const
Return the polyPatch.
Foam::fvPatchFieldMapper.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
makePatchTypeField(fvPatchScalarField, atmBoundaryLayerInletEpsilonFvPatchScalarField)
const scalarField & magSf() const
Return face area magnitudes.
const Boundary & boundaryField() const
Return const-reference to the boundary field.
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...