51 void Foam::fv::patchMeanVelocityForce::readCoeffs()
58 <<
"Cannot find patch " << patch_
68 const word& sourceName,
69 const word& modelType,
83 Foam::scalar Foam::fv::patchMeanVelocityForce::magUbarAve
88 const label patchi = mesh().boundaryMesh().findIndex(patch_);
109 forAll(processorCyclicPatches, pcpi)
123 mesh().reduce(sumA, sumOp<scalar>());
124 mesh().reduce(sumAmagU, sumOp<scalar>());
126 return sumAmagU/sumA;
#define forAll(list, i)
Loop across all elements in list.
Macros for easy insertion into run-time selection tables.
Generic GeometricField class.
static bool & parRun()
Is this a parallel run?
A list of keyword definitions, which are a keyword followed by any number of values (e....
ITstream & lookup(const word &, bool recursive=false, bool patternMatch=true) const
Find and return an entry data stream.
Finite volume options abstract base class.
const dictionary & coeffs() const
Return dictionary.
const fvMesh & mesh() const
Return const access to the mesh database.
Mesh data needed to do the Finite Volume discretisation.
Calculates and applies the force necessary to maintain the specified mean velocity.
virtual bool read(const dictionary &dict)
Read source dictionary.
Calculates and applies the force necessary to maintain the specified mean velocity averaged over the ...
virtual bool read(const dictionary &dict)
Read dictionary.
patchMeanVelocityForce(const word &sourceName, const word &modelType, const fvMesh &mesh, const dictionary &dict)
Construct from explicit source name and mesh.
label findIndex(const word &patchName) const
Find patch index given a name.
const polyBoundaryMesh & boundaryMesh() const
Return boundary mesh.
static labelList patchIDs(const word &cyclicPolyPatchName, const polyBoundaryMesh &bm)
Return the indices of a processorCyclicPolyPatchs.
A class for handling words, derived from string.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
const fvPatchList & patches
addToRunTimeSelectionTable(fvConstraint, bound, dictionary)
defineTypeNameAndDebug(bound, 0)
errorManipArg< error, int > exit(error &err, const int errNo=1)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
dimensioned< Type > sum(const DimensionedField< Type, GeoMesh > &df)
dimensionSet normalised(const dimensionSet &)
faceListList boundary(nPatches)
dimensionedVector Ubar("Ubar", dimVelocity, viscosity)