Go to the documentation of this file.
38 #ifndef polyMeshGeometry_H
39 #define polyMeshGeometry_H
93 const scalar severeNonorthogonalityThreshold,
116 const scalar minTetQuality,
189 const scalar orthWarn,
202 const scalar minPyrVol,
215 const scalar minPyrVol,
229 const scalar internalSkew,
230 const scalar boundarySkew,
231 const polyMesh&
mesh,
245 const scalar warnWeight,
246 const polyMesh&
mesh,
259 const scalar warnRatio,
260 const polyMesh&
mesh,
272 const polyMesh&
mesh,
284 const scalar minTwist,
298 const scalar minTwist,
311 const scalar minFlatness,
324 const scalar minArea,
350 const scalar orthWarn,
359 const scalar minPyrVol,
369 const scalar minTetQuality,
379 const scalar warnWeight,
388 const scalar warnRatio,
406 const scalar minTwist,
415 const scalar minTwist,
424 const scalar minFlatness,
433 const scalar minArea,
441 const scalar warnDet,
scalarField cellVolumes_
Uptodate copy of cell volumes.
vectorField cellCentres_
Uptodate copy of cell centres.
vectorField pointField
pointField is a vectorField.
static bool checkFaceDotProduct(const bool report, const scalar orthWarn, const polyMesh &, const vectorField &cellCentres, const vectorField &faceAreas, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *setPtr)
See primitiveMesh.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
ClassName("polyMeshGeometry")
const vectorField & faceAreas() const
List< label > labelList
A List of labels.
const scalarField & cellVolumes() const
void updateCellCentresAndVols(const labelList &changedCells, const labelList &changedFaces)
Update cell volumes and centres on selected cells. Requires.
static bool checkFaceWeights(const bool report, const scalar warnWeight, const polyMesh &mesh, const vectorField &cellCentres, const vectorField &faceCentres, const vectorField &faceAreas, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *setPtr)
Interpolation weights (0.5 for regular mesh)
static scalar checkNonOrtho(const polyMesh &mesh, const bool report, const scalar severeNonorthogonalityThreshold, const label faceI, const vector &s, const vector &d, label &severeNonOrth, label &errorNonOrth, labelHashSet *setPtr)
Detect&report non-ortho error for single face.
void correct()
Take over properties from mesh.
static bool checkFaceTets(const bool report, const scalar minPyrVol, const polyMesh &, const vectorField &cellCentres, const vectorField &faceCentres, const pointField &p, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *)
See primitiveMesh.
polyMeshGeometry(const polyMesh &)
Construct from mesh.
static bool checkFaceTet(const polyMesh &, const bool report, const scalar minTetQuality, const pointField &p, const label faceI, const point &fc, const point &cc, labelHashSet *setPtr)
Detect&report incorrect face-triangle orientation.
Mesh consisting of general polyhedral cells.
vectorField faceCentres_
Uptodate copy of face centres.
const vectorField & faceCentres() const
static bool checkFaceSkewness(const bool report, const scalar internalSkew, const scalar boundarySkew, const polyMesh &mesh, const pointField &points, const vectorField &cellCentres, const vectorField &faceCentres, const vectorField &faceAreas, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *setPtr)
See primitiveMesh.
Field< vector > vectorField
Specialisation of Field<T> for vector.
vectorField faceAreas_
Uptodate copy of face areas.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
static labelList affectedCells(const polyMesh &, const labelList &changedFaces)
Helper function: get affected cells from faces.
static bool checkFaceArea(const bool report, const scalar minArea, const polyMesh &, const vectorField &faceAreas, const labelList &checkFaces, labelHashSet *setPtr)
Small faces.
Pre-declare SubField and related Field type.
const polyMesh & mesh() const
void updateFaceCentresAndAreas(const pointField &p, const labelList &changedFaces)
Update face areas and centres on selected faces.
gmvFile<< "tracers "<< particles.size()<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().x()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().y()<< " ";}gmvFile<< nl;forAllConstIter(Cloud< passiveParticle >, particles, iter){ gmvFile<< iter().position().z()<< " ";}gmvFile<< nl;forAll(lagrangianScalarNames, i){ word name=lagrangianScalarNames[i];IOField< scalar > s(IOobject(name, runTime.timeName(), cloud::prefix, mesh, IOobject::MUST_READ, IOobject::NO_WRITE))
static bool checkFaceTwist(const bool report, const scalar minTwist, const polyMesh &, const vectorField &cellCentres, const vectorField &faceAreas, const vectorField &faceCentres, const pointField &p, const labelList &checkFaces, labelHashSet *setPtr)
Triangle (from face-centre decomposition) normal v.s.
static bool checkFaceFlatness(const bool report, const scalar minFlatness, const polyMesh &, const vectorField &faceAreas, const vectorField &faceCentres, const pointField &p, const labelList &checkFaces, labelHashSet *setPtr)
Area of faces v.s. sum of triangle areas.
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
const polyMesh & mesh_
Reference to polyMesh.
Updateable mesh geometry and checking routines.
static scalar calcSkewness(const point &ownCc, const point &neiCc, const point &fc)
Calculate skewness given two cell centres and one face centre.
static bool checkFacePyramids(const bool report, const scalar minPyrVol, const polyMesh &, const vectorField &cellCentres, const pointField &p, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *)
See primitiveMesh.
static bool checkCellDeterminant(const bool report, const scalar minDet, const polyMesh &, const vectorField &faceAreas, const labelList &checkFaces, const labelList &affectedCells, labelHashSet *setPtr)
Area of internal faces v.s. boundary faces.
HashSet< label, Hash< label > > labelHashSet
A HashSet with label keys.
static bool checkTriangleTwist(const bool report, const scalar minTwist, const polyMesh &, const vectorField &faceAreas, const vectorField &faceCentres, const pointField &p, const labelList &checkFaces, labelHashSet *setPtr)
Consecutive triangle (from face-centre decomposition) normals.
const vectorField & cellCentres() const
static bool checkVolRatio(const bool report, const scalar warnRatio, const polyMesh &mesh, const scalarField &cellVolumes, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *setPtr)
Cell volume ratio of neighbouring cells (1 for regular mesh)
static bool checkFaceAngles(const bool report, const scalar maxDeg, const polyMesh &mesh, const vectorField &faceAreas, const pointField &p, const labelList &checkFaces, labelHashSet *setPtr)
See primitiveMesh.