Go to the documentation of this file.
45 #include "primitiveMesh.H"
67 class polyMeshTetDecomposition;
69 template<
class Type>
class indexedOctree;
231 label& defaultPatchStart,
245 const bool detailedReport,
257 const bool detailedReport,
283 const scalar minWeight,
291 const scalar minRatio,
327 const bool syncPar =
true
338 const bool syncPar =
true
350 const word& defaultBoundaryPatchName,
351 const word& defaultBoundaryPatchType,
352 const wordList& boundaryPatchPhysicalTypes,
353 const bool syncPar =
true
366 const word& defaultBoundaryPatchName,
367 const word& defaultBoundaryPatchType,
368 const bool syncPar =
true
558 const bool validBoundary =
true
590 const bool validBoundary =
true
626 const bool report =
false,
633 const bool report =
false,
655 const bool report =
false,
656 const bool detailedReport =
false
663 const scalar minWeight = 0.05,
671 const scalar minRatio = 0.01,
bool checkCellDeterminant(const vectorField &faceAreas, const bool report, labelHashSet *setPtr, const Vector< label > &meshD) const
bool changing() const
Is mesh changing (topology changing and/or moving)
virtual const pointField & points() const
Return raw points.
bool topoChanging() const
Is mesh topology changing.
IOobject defines the attributes of an object for which implicit objectRegistry management is supporte...
void calcCellShapes() const
Calculate the cell shapes from the primitive.
bool checkVolRatio(const scalarField &cellVols, const bool report, const scalar minRatio, labelHashSet *setPtr) const
void resetMotion() const
Reset motion.
cellDecomposition
Enumeration defining the decomposition of the cell for.
A class for handling words, derived from string.
A class for handling file names.
static word defaultRegion
Return the default region name.
void clearAddressing()
Clear topological data.
bool topoChanging(const bool c)
Set the mesh topology to be changing.
A class for managing temporary objects.
faceCompactIOList faces_
Faces.
bool moving(const bool m)
Set the mesh to be moving.
label nGeometricD() const
Return the number of valid geometric dimensions in the mesh.
virtual tmp< scalarField > movePoints(const pointField &)
Move points, returns volumes swept by faces in motion.
polyBoundaryMesh BoundaryMesh
const labelList & tetBasePtIs() const
Return the tetBasePtIs.
labelList facePatchFaceCells(const faceList &patchFaces, const labelListList &pointCells, const faceListList &cellsFaceShapes, const label patchID) const
bool moving() const
Is mesh moving.
virtual const fileName & dbDir() const
Override the objectRegistry dbDir for a single-region case.
labelListList cellShapePointCells(const cellShapeList &) const
static word meshSubDir
Return the mesh sub-directory name (usually "polyMesh")
void clearCellTree()
Clear cell tree data.
faceZoneMesh faceZones_
Face zones.
autoPtr< indexedOctree< treeDataCell > > cellTreePtr_
Search tree to allow spatial cell searching.
const cellList & cells() const
labelIOList neighbour_
Face neighbour.
const fileName & facesInstance() const
Return the current instance directory for faces.
const cellZoneMesh & cellZones() const
Return cell zone mesh.
label comm() const
Return communicator used for parallel communication.
boundBox bounds_
Mesh bounding-box.
const polyBoundaryMesh & boundaryMesh() const
Return boundary mesh.
void clearOut()
Clear all geometry and addressing unnecessary for CFD.
void operator=(const polyMesh &)
Disallow default bitwise assignment.
const Vector< label > & solutionD() const
Return the vector of solved-for directions in mesh.
void removeFiles() const
Remove all files from mesh instance()
Vector< label > geometricD_
Vector of non-constrained directions in mesh.
Set of directions for each cell in the mesh. Either uniform and size=1 or one set of directions per c...
labelList patchFaces(const polyBoundaryMesh &patches, const wordList &names)
const Vector< label > & geometricD() const
Return the vector of geometric directions in mesh.
bool pointInCell(const point &p, label celli, const cellDecomposition=CELL_TETS) const
Test if point p is in the celli.
autoPtr< globalMeshData > globalMeshDataPtr_
Parallel info.
A simple container for copying or transferring objects of type <T>.
Mesh consisting of general polyhedral cells.
void setTopology(const cellShapeList &cellsAsShapes, const faceListList &boundaryFaces, const wordList &boundaryPatchNames, labelList &patchSizes, labelList &patchStarts, label &defaultPatchStart, label &nFaces, cellList &cells)
Set faces_, calculate cells and patchStarts.
const faceZoneMesh & faceZones() const
Return face zone mesh.
bool topoChanging_
Is the mesh topology changing.
void clearAdditionalGeom()
Clear geometry not used for CFD (cellTree, tetBasePtIs)
Registry of regIOobjects.
cellZoneMesh & cellZones()
Return non-const access to the cellZones.
const fileName & pointsInstance() const
Return the current instance directory for points.
labelIOList owner_
Face owner.
label comm_
Communicator used for parallel communication.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Pre-declare SubField and related Field type.
void clearPrimitives()
Clear primitive data (points, faces and cells)
const pointZoneMesh & pointZones() const
Return point zone mesh.
faceZoneMesh & faceZones()
Return non-const access to the faceZones.
virtual void updateMesh(const mapPolyMesh &mpm)
Update the mesh corresponding to given map.
virtual const labelList & faceOwner() const
Return face owner.
polyBoundaryMesh boundary_
Boundary mesh.
Non-pointer based hierarchical recursive searching.
A List of objects of type <T> with automated input and output using a compact storage....
label curMotionTimeIndex_
Current time index for mesh motion.
const objectRegistry & thisDb() const
Return the object registry.
const scalarField & cellVols
A templated 1D list of pointers to objects of type <T>, where the size of the array is known and used...
virtual const pointField & oldPoints() const
Return old points for mesh motion.
pointZoneMesh pointZones_
Point zones.
void resetPrimitives(const Xfer< pointField > &points, const Xfer< faceList > &faces, const Xfer< labelList > &owner, const Xfer< labelList > &neighbour, const labelList &patchSizes, const labelList &patchStarts, const bool validBoundary=true)
Reset mesh primitive data. Assumes all patch info correct.
pointIOField points_
Points.
Various mesh related information for a parallel run. Upon construction, constructs all info using par...
bool checkFaceSkewness(const pointField &points, const vectorField &fCtrs, const vectorField &fAreas, const vectorField &cellCtrs, const bool report, const bool detailedReport, labelHashSet *setPtr) const
Check face skewness.
void findCellFacePt(const point &p, label &celli, label &tetFacei, label &tetPti) const
Find the cell, tetFacei and tetPti for point p.
virtual bool upToDatePoints(const regIOobject &io) const
Return true if io is up-to-date with points.
autoPtr< pointField > oldPointsPtr_
Old points (for the last mesh motion)
bool checkFaceOrthogonality(const vectorField &fAreas, const vectorField &cellCtrs, const bool report, const bool detailedReport, labelHashSet *setPtr) const
Check non-orthogonality.
fileName meshDir() const
Return the local mesh directory (dbDir()/meshSubDir)
void removeBoundary()
Remove boundary patches.
void clearGeom()
Clear geometry.
readUpdateState
Enumeration defining the state of the mesh after a read update.
label nSolutionD() const
Return the number of valid solved-for dimensions in the mesh.
void setInstance(const fileName &)
Set the instance for mesh files.
const boundBox & bounds() const
Return mesh bounding box.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
const indexedOctree< treeDataCell > & cellTree() const
Return the cell search tree.
virtual ~polyMesh()
Destructor.
regIOobject is an abstract class derived from IOobject to handle automatic object registration with t...
label findCell(const point &p, const cellDecomposition=CELL_TETS) const
Find cell enclosing this location and return index.
virtual const faceList & faces() const
Return raw faces.
autoPtr< labelList > tetBasePtIsPtr_
Base point for face decomposition into tets.
pointZoneMesh & pointZones()
Return non-const access to the pointZones.
void calcDirections() const
Calculate the valid directions in the mesh from the boundaries.
TypeName("polyMesh")
Runtime type information.
void addPatches(const List< polyPatch * > &, const bool validBoundary=true)
Add boundary patches.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
const labelListList & pointCells() const
bool moving_
Is the mesh moving.
A bounding box defined in terms of the points at its extremities.
bool checkEdgeAlignment(const pointField &p, const bool report, const Vector< label > &directions, labelHashSet *setPtr) const
Class containing mesh-to-mesh mapping information after a change in polyMesh topology.
const dimensionedScalar c
Speed of light in a vacuum.
Vector< label > solutionD_
Vector of valid directions in mesh.
cellZoneMesh cellZones_
Cell zones.
virtual bool checkMeshMotion(const pointField &newPoints, const bool report=false, const bool detailedReport=false) const
Check mesh motion for correctness given motion points.
bool checkFaceWeight(const vectorField &fCtrs, const vectorField &fAreas, const vectorField &cellCtrs, const bool report, const scalar minWeight, labelHashSet *setPtr) const
const globalMeshData & globalData() const
Return parallel info.
void findTetFacePt(const label celli, const point &p, label &tetFacei, label &tetPti) const
Find the tetFacei and tetPti for point p in celli.
void addZones(const List< pointZone * > &pz, const List< faceZone * > &fz, const List< cellZone * > &cz)
Add mesh zones.
virtual void setUpToDatePoints(regIOobject &io) const
Set io to be up-to-date with points.
polyMesh(const polyMesh &)
Disallow construct as copy.
virtual const labelList & faceNeighbour() const
Return face neighbour.
virtual readUpdateState readUpdate()
Update the mesh based on the mesh files saved in.
void initMesh()
Initialise the polyMesh from the primitive data.
bool clearedPrimitives_
Have the primitives been cleared.
const vectorField & faceAreas() const
Cell-face mesh analysis engine.