28 #include "BlendedInterfacialModel.H" 29 #include "dragModel.H" 30 #include "virtualMassModel.H" 31 #include "liftModel.H" 32 #include "wallLubricationModel.H" 33 #include "turbulentDispersionModel.H" 39 namespace functionObjects
49 template<
class modelType>
53 const BlendedInterfacialModel<modelType>& model =
54 fluid_.lookupBlendedSubModel<modelType>(pair);
56 if (&pair.phase1() == &phase_)
58 return model.template F<vector>();
62 return -model.template F<vector>();
73 const dictionary& dict
76 fvMeshFunctionObject(name, runTime, dict),
79 mesh_.lookupObject<phaseModel>
81 IOobject::groupName(
"alpha", dict.
lookup(
"phase"))
84 fluid_(mesh_.lookupObject<phaseSystem>(
"phaseProperties"))
95 const phasePair& pair = iter();
97 if (pair.contains(phase_) && !pair.ordered())
99 if (fluid_.foundBlendedSubModel<dragModel>(pair))
109 mesh_.time().timeName(),
118 if (fluid_.foundBlendedSubModel<virtualMassModel>(pair))
122 virtualMassModel::typeName,
132 mesh_.time().timeName(),
141 if (fluid_.foundBlendedSubModel<liftModel>(pair))
151 mesh_.time().timeName(),
160 if (fluid_.foundBlendedSubModel<wallLubricationModel>(pair))
164 wallLubricationModel::typeName,
171 "wallLubricationForce",
174 mesh_.time().timeName(),
183 if (fluid_.foundBlendedSubModel<turbulentDispersionModel>(pair))
187 turbulentDispersionModel::typeName,
194 "turbulentDispersionForce",
197 mesh_.time().timeName(),
230 HashPtrTable<volVectorField>,
235 const word& type = iter.key();
247 const phasePair& pair = iter2();
249 if (pair.contains(phase_) && !pair.ordered())
251 if (type ==
"dragModel")
254 fluid_.lookupBlendedSubModel<dragModel>(pair).
K()
255 *(pair.otherPhase(phase_).U() - phase_.U());
258 if (type ==
"virtualMassModel")
261 fluid_.lookupBlendedSubModel<virtualMassModel>(pair).
K()
263 pair.otherPhase(phase_).DUDt()
268 if (type ==
"liftModel")
270 force = nonDragForce<liftModel>(pair);
273 if (type ==
"wallLubricationModel")
275 force = nonDragForce<wallLubricationModel>(pair);
278 if (type ==
"turbulentDispersionModel")
280 force = nonDragForce<turbulentDispersionModel>(pair);
294 HashPtrTable<volVectorField>,
299 writeObject(iter()->
name());
virtual bool read(const dictionary &dict)
Read the input data.
HashTable< autoPtr< phasePair >, phasePairKey, phasePairKey::hash > phasePairTable
#define forAllIter(Container, container, iter)
Iterate across all elements in the container object of type.
addToRunTimeSelectionTable(functionObject, Qdot, dictionary)
dimensioned< vector > dimensionedVector
Dimensioned vector obtained from generic dimensioned type.
GeometricField< vector, fvPatchField, volMesh > volVectorField
CGAL::Exact_predicates_exact_constructions_kernel K
Macros for easy insertion into run-time selection tables.
const dimensionSet dimVolume(pow3(dimLength))
bool read(const char *, int32_t &)
stressControl lookup("compactNormalStress") >> compactNormalStress
virtual ~phaseForces()
Destructor.
static word groupName(Name name, const word &group)
forAllConstIter(PtrDictionary< phaseModel >, mixture.phases(), phase)
virtual bool execute()
Calculate the force fields.
const dimensionSet dimForce
word name(const complex &)
Return a string representation of a complex.
defineTypeNameAndDebug(Qdot, 0)
tmp< volVectorField > nonDragForce(const phasePair &key) const
Evaluate and return non-drag force.
A class for managing temporary objects.
phaseForces(const word &name, const Time &runTime, const dictionary &)
Construct from Time and dictionary.
virtual bool write()
Write the force fields.