40 const DimensionedField<scalar, volMesh>& iF
43 fixedValueFvPatchScalarField(p, iF),
54 const DimensionedField<scalar, volMesh>& iF,
55 const dictionary&
dict 58 fixedValueFvPatchScalarField(p, iF, dict),
59 q_(
"q", dict, p.size()),
60 relax_(dict.lookupOrDefault<scalar>(
"relax", 1.0)),
61 Tmin_(dict.lookupOrDefault<scalar>(
"Tmin", 273))
68 const fixedMultiPhaseHeatFluxFvPatchScalarField& psf,
70 const DimensionedField<scalar, volMesh>& iF,
71 const fvPatchFieldMapper& mapper
74 fixedValueFvPatchScalarField(psf, p, iF, mapper),
84 const fixedMultiPhaseHeatFluxFvPatchScalarField& psf,
85 const DimensionedField<scalar, volMesh>& iF
88 fixedValueFvPatchScalarField(psf, iF),
106 const phaseSystem& fluid =
117 const phaseModel& phase = fluid.phases()[
phasei];
118 const fluidThermo& thermo = phase.thermo();
121 phase.boundaryField()[patch().index()];
124 thermo.T().boundaryField()[patch().index()];
126 const scalarField kappaEff(phase.kappaEff(patch().index()));
133 Info<< patch().name() <<
" " << phase.name()
134 <<
": Heat flux " <<
gMin(q0) <<
" - " <<
gMax(q0) <<
endl;
137 A += T.patchInternalField()*alpha*kappaEff*patch().deltaCoeffs();
138 B += alpha*kappaEff*patch().deltaCoeffs();
143 Info<< patch().name() <<
" " <<
": overall heat flux " 144 <<
gMin(Q) <<
" - " <<
gMax(Q) <<
" W/m2, power: " 145 <<
gSum(patch().magSf()*Q) <<
" W" <<
endl;
148 operator==((1 - relax_)*Tp + relax_*
max(Tmin_,(q_ + A)/(B)));
150 fixedValueFvPatchScalarField::updateCoeffs();
156 const fvPatchFieldMapper& m
159 fixedValueFvPatchScalarField::autoMap(m);
170 fixedValueFvPatchScalarField::rmap(ptf, addr);
172 const fixedMultiPhaseHeatFluxFvPatchScalarField& mptf =
173 refCast<const fixedMultiPhaseHeatFluxFvPatchScalarField>(ptf);
175 q_.rmap(mptf.q_, addr);
184 fixedValueFvPatchScalarField::reset(ptf);
186 const fixedMultiPhaseHeatFluxFvPatchScalarField& mptf =
187 refCast<const fixedMultiPhaseHeatFluxFvPatchScalarField>(ptf);
209 fixedMultiPhaseHeatFluxFvPatchScalarField
static const word propertiesName
Default name of the phase properties dictionary.
#define forAll(list, i)
Loop across all elements in list.
layerAndWeight max(const layerAndWeight &a, const layerAndWeight &b)
Type gMin(const FieldField< Field, Type > &f)
virtual void autoMap(const fvPatchFieldMapper &)
Map (and resize as needed) from self given a mapping object.
Ostream & endl(Ostream &os)
Add newline and flush stream.
virtual void write(Ostream &) const
Write.
Macros for easy insertion into run-time selection tables.
Type gSum(const FieldField< Field, Type > &f)
fixedMultiPhaseHeatFluxFvPatchScalarField(const fvPatch &, const DimensionedField< scalar, volMesh > &)
Construct from patch and internal field.
fvPatchField< scalar > fvPatchScalarField
tmp< fvMatrix< Type > > operator==(const fvMatrix< Type > &, const fvMatrix< Type > &)
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
List< label > labelList
A List of labels.
virtual void rmap(const fvPatchScalarField &, const labelList &)
Reverse map the given fvPatchField onto this fvPatchField.
virtual void updateCoeffs()
Update the coefficients associated with the patch field.
virtual void reset(const fvPatchScalarField &)
Reset the fvPatchField to the given fvPatchField.
Type gMax(const FieldField< Field, Type > &f)
void writeEntry(Ostream &os, const HashTable< T, Key, Hash > &ht)
virtual void write(Ostream &) const
Write.
makePatchTypeField(fvPatchScalarField, atmBoundaryLayerInletEpsilonFvPatchScalarField)