37 { operatingMode::VELOCITY,
"velocity" },
38 { operatingMode::UNIFORM_VELOCITY,
"uniformVelocity" },
39 { operatingMode::VOL_FLOW_RATE,
"volumeFlowRate" },
40 { operatingMode::NON_DIMENSIONAL,
"nonDimensional" },
47void Foam::fanFvPatchField<Type>::calcFanJump()
49 if (this->cyclicPatch().owner())
51 this->jump_ = this->jumpTable_->value(this->db().time().value());
62 const DimensionedField<Type, volMesh>& iF
65 uniformJumpFvPatchField<Type>(
p, iF),
66 operatingMode_(operatingMode::VELOCITY),
85 operatingModeNames_.getOrDefault(
"mode",
dict, operatingMode::VELOCITY)
87 phiName_(
dict.getOrDefault<
word>(
"phi",
"phi")),
88 rhoName_(
dict.getOrDefault<
word>(
"rho",
"rho")),
95 bool nonDimCompat =
dict.getOrDefault(
"nonDimensional",
false);
102 bool uniformCompat =
dict.getOrDefault(
"uniformJump",
false);
114 rpm_.reset(Function1<scalar>::New(
"rpm",
dict, &this->
db()));
115 dm_.reset(Function1<scalar>::New(
"dm",
dict, &this->
db()));
133 const fanFvPatchField<Type>&
rhs,
135 const DimensionedField<Type, volMesh>& iF,
136 const fvPatchFieldMapper& mapper
139 uniformJumpFvPatchField<Type>(
rhs,
p, iF, mapper),
140 operatingMode_(
rhs.operatingMode_),
141 phiName_(
rhs.phiName_),
155 operatingMode_(
rhs.operatingMode_),
156 phiName_(
rhs.phiName_),
171 operatingMode_(
rhs.operatingMode_),
172 phiName_(
rhs.phiName_),
173 rhoName_(
rhs.rhoName_),
174 rpm_(
rhs.rpm_.clone()),
200 os.writeEntryIfDifferent<
word>(
"phi",
"phi", phiName_);
201 os.writeEntryIfDifferent<
word>(
"rho",
"rho", rhoName_);
203 os.writeEntry(
"mode", operatingModeNames_[operatingMode_]);
205 if (operatingMode_ == operatingMode::NON_DIMENSIONAL)
Field with dimensions and associated with geometry type GeoMesh which is used to size the field and a...
Enum is a wrapper around a list of names/values that represent particular enumeration (or int) values...
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
@ buffered
"buffered" : (MPI_Bsend, MPI_Recv)
virtual void evaluate(const Pstream::commsTypes commsType)
Evaluate the patch field.
const cyclicFvPatch & cyclicPatch() const
Return local reference cast into the cyclic patch.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
This boundary condition provides a jump condition, using the cyclic condition as a base.
operatingMode
Enumeration defining the operating modes.
@ NON_DIMENSIONAL
non-dimensional-based lookup
@ UNIFORM_VELOCITY
uniform velocity-based lookup
@ VELOCITY
velocity-based lookup
fanFvPatchField(const fvPatch &, const DimensionedField< Type, volMesh > &)
Construct from patch and internal field.
virtual void write(Ostream &os) const
Write.
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
virtual tmp< fvPatchField< Type > > clone() const
Return a clone.
static const Enum< operatingMode > operatingModeNames_
Names for the operating modes.
const objectRegistry & db() const
The associated objectRegistry.
bool updated() const noexcept
True if the boundary condition has already been updated.
A FieldMapper for finite-volume patch fields.
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
bool readValueEntry(const dictionary &dict, IOobjectOption::readOption readOpt=IOobjectOption::LAZY_READ)
Read the "value" entry into *this.
A finiteVolume patch using a polyPatch and a fvBoundaryMesh.
A class for handling words, derived from Foam::string.
OBJstream os(runTime.globalPath()/outputName)
void rhs(fvMatrix< typename Expr::value_type > &m, const Expr &expression)