42 dynamicMultiMotionSolverFvMesh,
48 dynamicMultiMotionSolverFvMesh,
56 Foam::dynamicMultiMotionSolverFvMesh::dynamicMultiMotionSolverFvMesh
90 const dictionary& dynamicMeshCoeffs = dynDict.subDict(typeName +
"Coeffs");
92 motionPtr_.resize(dynamicMeshCoeffs.size());
93 pointIDs_.resize(dynamicMeshCoeffs.size());
99 for (
const entry& dEntry : dynamicMeshCoeffs)
103 const dictionary& subDict = dEntry.dict();
106 subDict.readEntry(
"cellZone", cellZoneName);
114 <<
"No matching cellZones: " << cellZoneName <<
nl 131 IOdictionary(
io, subDict)
141 for (
const label zoneID :
zoneIDs)
143 for (
const label celli : cellZones()[zoneID])
145 for (
const label facei :
cells()[celli])
147 movePts.set(faces()[facei]);
154 *
this, movePts, orEqOp<unsigned int>(), 0u
157 pointIDs_[zonei] = movePts.sortedToc();
159 Info<<
"Applying motionSolver " << motionPtr_[zonei].type()
161 <<
returnReduce(pointIDs_[zonei].size(), sumOp<label>())
162 <<
" points of cellZone " << cellZoneName <<
endl;
168 motionPtr_.resize(zonei);
169 pointIDs_.resize(zonei);
184 const labelList& zonePoints = pointIDs_[zonei];
186 const pointField newPoints(motionPtr_[zonei].newPoints());
188 for (
const label pointi : zonePoints)
190 transformedPts[pointi] = newPoints[pointi];
196 static bool hasWarned =
false;
209 <<
"Did not find volVectorField U." 210 <<
" Not updating U boundary conditions." <<
endl;
const labelIOList & zoneIDs
List< word > names(const UPtrList< T > &list, const UnaryMatchPredicate &matcher)
List of names generated by calling name() for each list item and filtered for matches.
errorManipArg< error, int > exit(error &err, const int errNo=1)
constexpr char nl
The newline '\n' character (0x0a)
bool empty() const noexcept
True if List is empty (ie, size() is zero)
Ostream & endl(Ostream &os)
Add newline and flush stream.
virtual bool movePoints()
Do what is necessary if the mesh has moved.
virtual bool init(const bool doInit)
Initialise all non-demand-driven data.
static autoPtr< motionSolver > New(const polyMesh &)
Select constructed from polyMesh.
Ignore writing from objectRegistry::writeObject()
GeometricField< vector, fvPatchField, volMesh > volVectorField
T returnReduce(const T &value, const BinaryOp &bop, const int tag=UPstream::msgType(), const label comm=UPstream::worldComm)
Perform reduction on a copy, using specified binary operation.
Macros for easy insertion into run-time selection tables.
#define forAll(list, i)
Loop across all elements in list.
defineTypeNameAndDebug(combustionModel, 0)
addToRunTimeSelectionTable(decompositionMethod, kahipDecomp, dictionary)
#define WarningInFunction
Report a warning using Foam::Warning.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
Abstract base class for geometry and/or topology changing fvMesh.
void correctBoundaryConditions()
Correct boundary field.
messageStream Info
Information stream (stdout output on master, null elsewhere)
virtual bool update()
Update the mesh for both mesh motion and topology change.
List< label > labelList
A List of labels.
IOobject io("surfaceFilmProperties", mesh.time().constant(), mesh, IOobject::READ_IF_PRESENT, IOobject::NO_WRITE, IOobject::NO_REGISTER)
virtual bool init(const bool doInit)
Initialise all non-demand-driven data.
Defines the attributes of an object for which implicit objectRegistry management is supported...
Do not request registration (bool: false)
FlatOutput::OutputAdaptor< Container, Delimiters > flatOutput(const Container &obj, Delimiters delim)
Global flatOutput() function with specified output delimiters.
IOerror FatalIOError
Error stream (stdout output on all processes), with additional 'FOAM FATAL IO ERROR' header text and ...