Go to the documentation of this file.
30 #include "surfaceInterpolate.H"
40 inline tmp<Foam::volScalarField>
60 template<
class ModelType>
61 template<
class GeoField>
67 typename GeoField::Boundary& fieldBf =
field.boundaryFieldRef();
69 forAll(phase1_.phi()().boundaryField(), patchi)
73 isA<fixedValueFvsPatchScalarField>
75 phase1_.phi()().boundaryField()[patchi]
79 fieldBf[patchi] =
Zero;
85 template<
class ModelType>
89 template<
class>
class PatchField,
97 (ModelType::*method)(Args ...)
const,
109 if (model_.valid() || model1In2_.valid())
112 blendedInterfacialModel::interpolate<scalarGeoField>
114 blending_.f1(phase1_, phase2_)
118 if (model_.valid() || model2In1_.valid())
121 blendedInterfacialModel::interpolate<scalarGeoField>
123 blending_.f2(phase1_, phase2_)
133 ModelType::typeName +
":" +
name,
134 phase1_.mesh().time().timeName(),
150 <<
"Cannot treat an interfacial model with no distinction "
151 <<
"between continuous and dispersed phases as signed"
155 x.ref() += (model_().*method)(
args ...)*(scalar(1) - f1() - f2());
158 if (model1In2_.valid())
160 x.ref() += (model1In2_().*method)(
args ...)*f1;
163 if (model2In1_.valid())
180 && (model_.valid() || model1In2_.valid() || model2In1_.valid())
183 correctFixedFluxBCs(
x.ref());
192 template<
class ModelType>
201 const bool correctFixedFluxBCs
209 phase1.mesh().time().timeName(),
217 model1In2_(model1In2),
218 model2In1_(model2In1),
219 correctFixedFluxBCs_(correctFixedFluxBCs)
223 template<
class ModelType>
231 const bool correctFixedFluxBCs
238 IOobject::groupName(typeName, pair.
name()),
239 pair.
phase1().mesh().time().timeName(),
246 correctFixedFluxBCs_(correctFixedFluxBCs)
248 if (modelTable.
found(pair))
260 if (modelTable.
found(pair1In2))
266 modelTable[pair1In2],
272 if (modelTable.
found(pair2In1))
278 modelTable[pair2In1],
288 template<
class ModelType>
295 template<
class ModelType>
304 : model2In1_.valid();
308 template<
class ModelType>
314 return &
phase == &(phase1_) ? model1In2_ : model2In1_;
318 template<
class ModelType>
324 return evaluate(
k,
"K", ModelType::dimK,
false);
328 template<
class ModelType>
334 return evaluate(
k,
"K", ModelType::dimK,
false, residualAlpha);
338 template<
class ModelType>
342 return evaluate(&ModelType::Kf,
"Kf", ModelType::dimK,
false);
346 template<
class ModelType>
355 template<
class ModelType>
363 template<
class ModelType>
371 template<
class ModelType>
375 return evaluate(&ModelType::dmdt,
"dmdt", ModelType::dimDmdt,
false);
379 template<
class ModelType>
Single incompressible phase derived from the phase-fraction. Used as part of the multiPhaseMixture fo...
Defines the attributes of an object for which implicit objectRegistry management is supported,...
void subtract(FieldField< Field1, typename typeOfSum< Type1, Type2 >::type > &f, const FieldField< Field1, Type1 > &f1, const FieldField< Field2, Type2 > &f2)
Description for mass transfer between a pair of phases. The direction of the mass transfer is from th...
tmp< surfaceScalarField > Kf() const
Return the face blended force coefficient.
A class for handling words, derived from Foam::string.
Single incompressible phase derived from the phase-fraction. Used as part of the multiPhaseMixture fo...
static constexpr const zero Zero
Global zero (0)
tmp< volScalarField > dmdt() const
Return the blended mass transfer rate.
~BlendedInterfacialModel()
Destructor.
tmp< GeometricField< Type, fvPatchField, volMesh > > F() const
Return the blended force.
surfaceScalarField Ff(fluid.Ff())
volVectorField F(fluid.F())
Dimension set for the base types.
bool hasModel(const phaseModel &phase) const
Return true if a model is specified for the supplied phase.
#define forAll(list, i)
Loop across all elements in list.
CGAL::Exact_predicates_exact_constructions_kernel K
const dimensionSet dimArea(sqr(dimLength))
word name(const complex &c)
Return string representation of complex.
static tmp< GeoField > interpolate(tmp< volScalarField > f)
Convenience function to interpolate blending values. Needs to be.
Generic dimensioned Type class.
static tmp< GeometricField< Type, fvsPatchField, surfaceMesh > > interpolate(const GeometricField< Type, fvPatchField, volMesh > &tvf, const surfaceScalarField &faceFlux, Istream &schemeData)
Interpolate field onto faces using scheme given by Istream.
errorManipArg< error, int > exit(error &err, const int errNo=1)
A HashTable similar to std::unordered_map.
tmp< DimensionedField< TypeR, GeoMesh > > New(const tmp< DimensionedField< TypeR, GeoMesh >> &tdf1, const word &name, const dimensionSet &dimensions)
Global function forwards to reuseTmpDimensionedField::New.
tmp< volScalarField > K() const
Return the blended force coefficient.
regIOobject is an abstract class derived from IOobject to handle automatic object registration with t...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
tmp< surfaceScalarField > Ff() const
Return the face blended force.
virtual word name() const
Pair name.
label k
Boltzmann constant.
tmp< volScalarField > D() const
Return the blended diffusivity.
const dimensionedScalar & D
const phaseModel & phase2() const
Return phase 2.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
bool good() const
Return true if next operation might succeed.
bool found(const Key &key) const
Return true if hashed entry is found in table.
const phaseModel & phase1() const
Return phase 1.
Generic GeometricField class.
Foam::argList args(argc, argv)
const ModelType & model(const phaseModel &phase) const
Return the model for the supplied phase.
string evaluate(const std::string &s, size_t pos=0, size_t len=std::string::npos)
bool writeData(Ostream &os) const
Dummy write for regIOobject.