Updateable mesh geometry and checking routines. More...
#include <dynamicMesh/polyMeshGeometry.H>
Updateable mesh geometry and checking routines.
- non-ortho done across coupled faces.
Definition at line 53 of file polyMeshGeometry.H.
Collaboration diagram for polyMeshGeometry:Public Member Functions | |
| ClassName ("polyMeshGeometry") | |
| polyMeshGeometry (const polyMesh &) | |
| Construct from mesh.
| |
| const polyMesh & | mesh () const |
| const vectorField & | faceAreas () const |
| const vectorField & | faceCentres () const |
| const vectorField & | cellCentres () const |
| const scalarField & | cellVolumes () const |
| void | correct () |
| Take over properties from mesh.
| |
| void | correct (const pointField &p, const labelList &changedFaces) |
| Recalculate on selected faces. Recalculates cell properties.
| |
| bool | checkFaceDotProduct (const bool report, const scalar orthWarn, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *setPtr) const |
| bool | checkFacePyramids (const bool report, const scalar minPyrVol, const pointField &p, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *setPtr) const |
| bool | checkFaceSkewness (const bool report, const scalar internalSkew, const scalar boundarySkew, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *setPtr) const |
| bool | checkFaceWeights (const bool report, const scalar warnWeight, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *setPtr) const |
| bool | checkVolRatio (const bool report, const scalar warnRatio, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *setPtr) const |
| bool | checkFaceAngles (const bool report, const scalar maxDeg, const pointField &p, const labelList &checkFaces, labelHashSet *setPtr) const |
| bool | checkFaceTwist (const bool report, const scalar minTwist, const pointField &p, const labelList &checkFaces, labelHashSet *setPtr) const |
| bool | checkTriangleTwist (const bool report, const scalar minTwist, const pointField &p, const labelList &checkFaces, labelHashSet *setPtr) const |
| bool | checkFaceArea (const bool report, const scalar minArea, const labelList &checkFaces, labelHashSet *setPtr) const |
| bool | checkCellDeterminant (const bool report, const scalar warnDet, const labelList &checkFaces, const labelList &affectedCells, labelHashSet *setPtr) const |
Static Public Member Functions | |
| static labelList | affectedCells (const polyMesh &, const labelList &changedFaces) |
| Helper function: get affected cells from faces.
| |
| 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.
| |
| 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 | checkFaceSkewness (const bool report, const scalar internalSkew, const scalar boundarySkew, const polyMesh &mesh, const vectorField &cellCentres, const vectorField &faceCentres, const vectorField &faceAreas, const labelList &checkFaces, const List< labelPair > &baffles, labelHashSet *setPtr) |
| See primitiveMesh.
| |
| 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 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.
| |
| 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 | 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.
| |
| static bool | checkFaceArea (const bool report, const scalar minArea, const polyMesh &, const vectorField &faceAreas, const labelList &checkFaces, labelHashSet *setPtr) |
| Small faces.
| |
| static bool | checkCellDeterminant (const bool report, const scalar minDet, const polyMesh &, const vectorField &faceAreas, const labelList &checkFaces, const labelList &affectedCells, labelHashSet *setPtr) |
| polyMeshGeometry | ( | const polyMesh & | mesh ) |
Construct from mesh.
Definition at line 312 of file polyMeshGeometry.C.
References polyMeshGeometry::correct().
| ClassName | ( | "polyMeshGeometry" | ) |
| const polyMesh& mesh | ( | ) | const [inline]
|
Definition at line 125 of file polyMeshGeometry.H.
Referenced by motionSmoother::checkMesh().
| const vectorField& faceAreas | ( | ) | const [inline]
|
Definition at line 130 of file polyMeshGeometry.H.
| const vectorField& faceCentres | ( | ) | const [inline]
|
Definition at line 134 of file polyMeshGeometry.H.
| const vectorField& cellCentres | ( | ) | const [inline]
|
Definition at line 138 of file polyMeshGeometry.H.
| const scalarField& cellVolumes | ( | ) | const [inline]
|
Definition at line 142 of file polyMeshGeometry.H.
| void correct | ( | ) |
Take over properties from mesh.
Definition at line 326 of file polyMeshGeometry.C.
Referenced by polyMeshGeometry::polyMeshGeometry().
| void correct | ( | const pointField & | p, |
| const labelList & | changedFaces | ||
| ) |
Recalculate on selected faces. Recalculates cell properties.
Recalculate on selected faces.
on owner and neighbour of these cells.
Definition at line 337 of file polyMeshGeometry.C.
| Foam::labelList affectedCells | ( | const polyMesh & | mesh, |
| const labelList & | changedFaces | ||
| ) | [static]
|
Helper function: get affected cells from faces.
Definition at line 190 of file polyMeshGeometry.C.
References polyMesh::faceNeighbour(), polyMesh::faceOwner(), forAll, primitiveMesh::isInternalFace(), and List< T >::size().
Referenced by motionSmoother::checkMesh().
| bool checkFaceDotProduct | ( | const bool | report, |
| const scalar | orthWarn, | ||
| const polyMesh & | mesh, | ||
| const vectorField & | cellCentres, | ||
| const vectorField & | faceAreas, | ||
| const labelList & | checkFaces, | ||
| const List< labelPair > & | baffles, | ||
| labelHashSet * | setPtr | ||
| ) | [static]
|
See primitiveMesh.
Definition at line 350 of file polyMeshGeometry.C.
References Foam::acos(), polyMesh::boundaryMesh(), Foam::cos(), Foam::endl(), polyMesh::faceNeighbour(), polyMesh::faceOwner(), forAll, Foam::Info, primitiveMesh::isInternalFace(), primitiveMesh::nFaces(), primitiveMesh::nInternalFaces(), patches, Foam::mathematicalConstant::pi(), Foam::reduce(), SeriousErrorIn, syncTools::swapBoundaryFaceList(), and polyBoundaryMesh::whichPatch().
Referenced by motionSmoother::checkMesh().
| bool checkFacePyramids | ( | const bool | report, |
| const scalar | minPyrVol, | ||
| const polyMesh & | mesh, | ||
| const vectorField & | cellCentres, | ||
| const pointField & | p, | ||
| const labelList & | checkFaces, | ||
| const List< labelPair > & | baffles, | ||
| labelHashSet * | setPtr | ||
| ) | [static]
|
See primitiveMesh.
Definition at line 538 of file polyMeshGeometry.C.
References primitiveMesh::cells(), Foam::endl(), polyMesh::faceNeighbour(), polyMesh::faceOwner(), polyMesh::faces(), forAll, Foam::Info, HashSet< Key, Hash >::insert(), primitiveMesh::isInternalFace(), Foam::Pout, Foam::reduce(), and SeriousErrorIn.
Referenced by motionSmoother::checkMesh().
| bool checkFaceSkewness | ( | const bool | report, |
| const scalar | internalSkew, | ||
| const scalar | boundarySkew, | ||
| const polyMesh & | mesh, | ||
| const vectorField & | cellCentres, | ||
| const vectorField & | faceCentres, | ||
| const vectorField & | faceAreas, | ||
| const labelList & | checkFaces, | ||
| const List< labelPair > & | baffles, | ||
| labelHashSet * | setPtr | ||
| ) | [static]
|
See primitiveMesh.
Definition at line 723 of file polyMeshGeometry.C.
References polyMesh::boundaryMesh(), Foam::endl(), polyMesh::faceNeighbour(), polyMesh::faceOwner(), forAll, Foam::Info, HashSet< Key, Hash >::insert(), primitiveMesh::isInternalFace(), Foam::mag(), Foam::max(), primitiveMesh::nFaces(), primitiveMesh::nInternalFaces(), Foam::nl, patches, Foam::Pout, Foam::reduce(), syncTools::swapBoundaryFaceList(), WarningIn, and polyBoundaryMesh::whichPatch().
Referenced by motionSmoother::checkMesh().
| 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 | ||
| ) | [static]
|
Interpolation weights (0.5 for regular mesh)
Definition at line 933 of file polyMeshGeometry.C.
References polyMesh::boundaryMesh(), Foam::endl(), polyMesh::faceNeighbour(), polyMesh::faceOwner(), forAll, Foam::Info, HashSet< Key, Hash >::insert(), primitiveMesh::isInternalFace(), Foam::mag(), Foam::min(), primitiveMesh::nFaces(), primitiveMesh::nInternalFaces(), Foam::nl, patches, Foam::Pout, Foam::reduce(), syncTools::swapBoundaryFaceList(), WarningIn, and polyBoundaryMesh::whichPatch().
Referenced by motionSmoother::checkMesh().
| bool checkVolRatio | ( | const bool | report, |
| const scalar | warnRatio, | ||
| const polyMesh & | mesh, | ||
| const scalarField & | cellVolumes, | ||
| const labelList & | checkFaces, | ||
| const List< labelPair > & | baffles, | ||
| labelHashSet * | setPtr | ||
| ) | [static]
|
Cell volume ratio of neighbouring cells (1 for regular mesh)
Definition at line 1092 of file polyMeshGeometry.C.
References polyMesh::boundaryMesh(), Foam::endl(), polyMesh::faceNeighbour(), polyMesh::faceOwner(), forAll, Foam::Info, HashSet< Key, Hash >::insert(), primitiveMesh::isInternalFace(), Foam::mag(), Foam::max(), Foam::min(), primitiveMesh::nFaces(), primitiveMesh::nInternalFaces(), Foam::nl, patches, Foam::Pout, Foam::reduce(), syncTools::swapBoundaryFaceList(), WarningIn, and polyBoundaryMesh::whichPatch().
Referenced by motionSmoother::checkMesh().
| bool checkFaceAngles | ( | const bool | report, |
| const scalar | maxDeg, | ||
| const polyMesh & | mesh, | ||
| const vectorField & | faceAreas, | ||
| const pointField & | p, | ||
| const labelList & | checkFaces, | ||
| labelHashSet * | setPtr | ||
| ) | [static]
|
See primitiveMesh.
Definition at line 1238 of file polyMeshGeometry.C.
References Foam::abort(), Foam::asin(), Foam::endl(), polyMesh::faces(), Foam::FatalError, FatalErrorIn, UList< T >::fcIndex(), forAll, Foam::Info, HashSet< Key, Hash >::insert(), Foam::mag(), Foam::max(), Foam::min(), Foam::mathematicalConstant::pi(), Foam::reduce(), Foam::sin(), List< T >::size(), and WarningIn.
Referenced by motionSmoother::checkMesh().
| bool checkFaceTwist | ( | const bool | report, |
| const scalar | minTwist, | ||
| const polyMesh & | mesh, | ||
| const vectorField & | cellCentres, | ||
| const vectorField & | faceAreas, | ||
| const vectorField & | faceCentres, | ||
| const pointField & | p, | ||
| const labelList & | checkFaces, | ||
| labelHashSet * | setPtr | ||
| ) | [static]
|
Triangle (from face-centre decomposition) normal v.s.
average face normal
Definition at line 1380 of file polyMeshGeometry.C.
References Foam::abort(), polyMesh::boundaryMesh(), Foam::endl(), polyMesh::faceNeighbour(), polyMesh::faceOwner(), polyMesh::faces(), Foam::FatalError, FatalErrorIn, forAll, Foam::Info, HashSet< Key, Hash >::insert(), primitiveMesh::isInternalFace(), Foam::mag(), face::nextLabel(), primitiveMesh::nFaces(), primitiveMesh::nInternalFaces(), Foam::nl, patches, Foam::reduce(), List< T >::size(), syncTools::swapBoundaryFaceList(), WarningIn, polyBoundaryMesh::whichPatch(), and Vector< Cmpt >::zero.
Referenced by motionSmoother::checkMesh().
| bool checkTriangleTwist | ( | const bool | report, |
| const scalar | minTwist, | ||
| const polyMesh & | mesh, | ||
| const vectorField & | faceAreas, | ||
| const vectorField & | faceCentres, | ||
| const pointField & | p, | ||
| const labelList & | checkFaces, | ||
| labelHashSet * | setPtr | ||
| ) | [static]
|
Consecutive triangle (from face-centre decomposition) normals.
Definition at line 1575 of file polyMeshGeometry.C.
References Foam::abort(), Foam::endl(), polyMesh::faces(), Foam::FatalError, FatalErrorIn, UList< T >::fcIndex(), forAll, Foam::Info, HashSet< Key, Hash >::insert(), Foam::mag(), face::nextLabel(), Foam::nl, Foam::reduce(), List< T >::size(), and WarningIn.
Referenced by motionSmoother::checkMesh().
| bool checkFaceArea | ( | const bool | report, |
| const scalar | minArea, | ||
| const polyMesh & | mesh, | ||
| const vectorField & | faceAreas, | ||
| const labelList & | checkFaces, | ||
| labelHashSet * | setPtr | ||
| ) | [static]
|
Small faces.
Definition at line 1733 of file polyMeshGeometry.C.
References Foam::endl(), forAll, Foam::Info, HashSet< Key, Hash >::insert(), Foam::mag(), Foam::nl, Foam::reduce(), and WarningIn.
Referenced by motionSmoother::checkMesh().
| bool checkCellDeterminant | ( | const bool | report, |
| const scalar | minDet, | ||
| const polyMesh & | mesh, | ||
| const vectorField & | faceAreas, | ||
| const labelList & | checkFaces, | ||
| const labelList & | affectedCells, | ||
| labelHashSet * | setPtr | ||
| ) | [static]
|
Definition at line 1798 of file polyMeshGeometry.C.
References primitiveMesh::cells(), cells, Foam::det(), Foam::endl(), forAll, Foam::Info, HashSet< Key, Hash >::insert(), Foam::mag(), Foam::min(), Foam::nl, Foam::reduce(), WarningIn, and Tensor< scalar >::zero.
Referenced by motionSmoother::checkMesh().
| bool checkFaceDotProduct | ( | const bool | report, |
| const scalar | orthWarn, | ||
| const labelList & | checkFaces, | ||
| const List< labelPair > & | baffles, | ||
| labelHashSet * | setPtr | ||
| ) | const |
Definition at line 1904 of file polyMeshGeometry.C.
| bool checkFacePyramids | ( | const bool | report, |
| const scalar | minPyrVol, | ||
| const pointField & | p, | ||
| const labelList & | checkFaces, | ||
| const List< labelPair > & | baffles, | ||
| labelHashSet * | setPtr | ||
| ) | const |
Definition at line 1927 of file polyMeshGeometry.C.
| bool checkFaceSkewness | ( | const bool | report, |
| const scalar | internalSkew, | ||
| const scalar | boundarySkew, | ||
| const labelList & | checkFaces, | ||
| const List< labelPair > & | baffles, | ||
| labelHashSet * | setPtr | ||
| ) | const |
Definition at line 1951 of file polyMeshGeometry.C.
| bool checkFaceWeights | ( | const bool | report, |
| const scalar | warnWeight, | ||
| const labelList & | checkFaces, | ||
| const List< labelPair > & | baffles, | ||
| labelHashSet * | setPtr | ||
| ) | const |
Definition at line 1977 of file polyMeshGeometry.C.
| bool checkVolRatio | ( | const bool | report, |
| const scalar | warnRatio, | ||
| const labelList & | checkFaces, | ||
| const List< labelPair > & | baffles, | ||
| labelHashSet * | setPtr | ||
| ) | const |
Definition at line 2001 of file polyMeshGeometry.C.
| bool checkFaceAngles | ( | const bool | report, |
| const scalar | maxDeg, | ||
| const pointField & | p, | ||
| const labelList & | checkFaces, | ||
| labelHashSet * | setPtr | ||
| ) | const |
Definition at line 2023 of file polyMeshGeometry.C.
| bool checkFaceTwist | ( | const bool | report, |
| const scalar | minTwist, | ||
| const pointField & | p, | ||
| const labelList & | checkFaces, | ||
| labelHashSet * | setPtr | ||
| ) | const |
Definition at line 2045 of file polyMeshGeometry.C.
| bool checkTriangleTwist | ( | const bool | report, |
| const scalar | minTwist, | ||
| const pointField & | p, | ||
| const labelList & | checkFaces, | ||
| labelHashSet * | setPtr | ||
| ) | const |
Definition at line 2069 of file polyMeshGeometry.C.
| bool checkFaceArea | ( | const bool | report, |
| const scalar | minArea, | ||
| const labelList & | checkFaces, | ||
| labelHashSet * | setPtr | ||
| ) | const |
Definition at line 2092 of file polyMeshGeometry.C.
| bool checkCellDeterminant | ( | const bool | report, |
| const scalar | warnDet, | ||
| const labelList & | checkFaces, | ||
| const labelList & | affectedCells, | ||
| labelHashSet * | setPtr | ||
| ) | const |
Definition at line 2112 of file polyMeshGeometry.C.