43 solidBodyMotionSolver,
62 transform_(SBMFPtr_().transformation())
65 coeffDict().lookupOrDefault<
word>(
"cellZone",
"none");
68 coeffDict().lookupOrDefault<
word>(
"cellSet",
"none");
70 if ((cellZoneName !=
"none") && (cellSetName !=
"none"))
73 <<
"Either cellZone OR cellSet can be supplied, but not both. " 74 <<
"If neither is supplied, all cells will be included" 79 if (cellZoneName !=
"none")
81 Info<<
"Applying solid body motion to cellZone " << cellZoneName
89 <<
"Unable to find cellZone " << cellZoneName
90 <<
". Valid cellZones are:" 98 if (cellSetName !=
"none")
100 Info<<
"Applying solid body motion to cellSet " << cellSetName
109 moveAllCells_ = nCells == 0;
113 Info<<
"Applying solid body motion to entire mesh" <<
endl;
123 label celli = cellIDs[i];
131 movePts[pointi] =
true;
147 pointIDs_.transfer(ptIDs);
162 transform_ = SBMFPtr_().transformation();
179 return ttransformedPts;
198 forAll(newPoints0, pointi)
206 if (masterPointi == pointi)
208 newPoints0[pointi] = points0_[oldPointi];
213 transform_.invTransformPoint(points[pointi]);
219 <<
"Cannot determine co-ordinates of introduced vertices." 220 <<
" New vertex " << pointi <<
" at co-ordinate " 225 twoDCorrectPoints(newPoints0);
227 points0_.transfer(newPoints0);
label findZoneID(const word &zoneName) const
Find zone index given a name.
#define forAll(list, i)
Loop across all elements in list.
virtual void topoChange(const polyTopoChangeMap &)
Update local data for topology changes.
errorManipArg< error, int > exit(error &err, const int errNo=1)
A face is a list of labels corresponding to mesh vertices.
const meshCellZones & cellZones() const
Return cell zones.
A list of keyword definitions, which are a keyword followed by any number of values (e...
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
T & ref() const
Return non-const reference or generate a fatal error.
void size(const label)
Override size to be inconsistent with allocated storage.
bool hasMotionPoints() const
Has valid preMotionPoints?
const labelList & pointMap() const
Old point map.
Ostream & endl(Ostream &os)
Add newline and flush stream.
const cellList & cells() const
label k
Boltzmann constant.
const dimensionedScalar c
Speed of light in a vacuum.
Macros for easy insertion into run-time selection tables.
virtual const pointField & points() const
Return raw points.
wordList names() const
Return a list of zone names.
solidBodyMotionSolver(const word &name, const polyMesh &, const dictionary &)
Construct from mesh and dictionary.
vectorField pointField
pointField is a vectorField.
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects...
A class for handling words, derived from string.
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
static autoPtr< solidBodyMotionFunction > New(const dictionary &SBMFCoeffs, const Time &runTime)
Select constructed from the SBMFCoeffs dictionary and Time.
const labelList & reversePointMap() const
Reverse point map.
virtual const faceList & faces() const
Return raw faces.
addToRunTimeSelectionTable(ensightPart, ensightPartCells, istream)
const Time & time() const
Return time.
defineTypeNameAndDebug(combustionModel, 0)
const pointField & preMotionPoints() const
Pre-motion point positions.
#define FatalIOErrorInFunction(ios)
Report an error message using Foam::FatalIOError.
A cell is defined as a list of faces with extra functionality.
A collection of cell labels.
Virtual base class for displacement motion solvers.
A List with indirect addressing.
void transformPoints(vectorField &, const spatialTransform &, const vectorField &)
Transform given vectorField of coordinates with the given spatialTransform.
T returnReduce(const T &Value, const BinaryOp &bop, const int tag=Pstream::msgType(), const label comm=UPstream::worldComm)
Mesh consisting of general polyhedral cells.
A class for managing temporary objects.
~solidBodyMotionSolver()
Destructor.
virtual tmp< pointField > curPoints() const
Return point location obtained from the current motion field.