Loading...
Searching...
No Matches
primitiveMeshGeometry Class Reference

Updateable mesh geometry + checking routines. More...

#include <primitiveMeshGeometry.H>

Public Member Functions

 ClassName ("primitiveMeshGeometry")
 primitiveMeshGeometry (const primitiveMesh &)
 Construct from mesh.
const primitiveMeshmesh () const
const vectorFieldfaceAreas () const
const vectorFieldfaceCentres () const
const vectorFieldcellCentres () const
const scalarFieldcellVolumes () const
void correct ()
 Take over properties from mesh.
void correct (const pointField &p, const labelList &changedFaces)
 Recalculate on selected faces. Recalculates cell properties.
labelList affectedCells (const labelList &changedFaces) const
 Helper function: get affected cells from faces.
bool checkFaceDotProduct (const bool report, const scalar orthWarn, const labelList &checkFaces, labelHashSet *setPtr) const
bool checkFacePyramids (const bool report, const scalar minPyrVol, const pointField &p, const labelList &checkFaces, labelHashSet *setPtr) const
bool checkFaceSkewness (const bool report, const scalar internalSkew, const scalar boundarySkew, const labelList &checkFaces, labelHashSet *setPtr) const
bool checkFaceWeights (const bool report, const scalar warnWeight, const labelList &checkFaces, 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 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 bool checkFaceDotProduct (const bool report, const scalar orthWarn, const primitiveMesh &, const vectorField &cellCentres, const vectorField &faceAreas, const labelList &checkFaces, labelHashSet *setPtr)
static bool checkFacePyramids (const bool report, const scalar minPyrVol, const primitiveMesh &, const vectorField &cellCentres, const pointField &p, const labelList &checkFaces, labelHashSet *)
static bool checkFaceSkewness (const bool report, const scalar internalSkew, const scalar boundarySkew, const primitiveMesh &mesh, const vectorField &cellCentres, const vectorField &faceCentres, const vectorField &faceAreas, const labelList &checkFaces, labelHashSet *setPtr)
static bool checkFaceWeights (const bool report, const scalar warnWeight, const primitiveMesh &mesh, const vectorField &cellCentres, const vectorField &faceCentres, const vectorField &faceAreas, const labelList &checkFaces, labelHashSet *setPtr)
static bool checkFaceAngles (const bool report, const scalar maxDeg, const primitiveMesh &mesh, const vectorField &faceAreas, const pointField &p, const labelList &checkFaces, labelHashSet *setPtr)
static bool checkFaceTwist (const bool report, const scalar minTwist, const primitiveMesh &, const vectorField &faceAreas, const vectorField &faceCentres, const pointField &p, const labelList &checkFaces, labelHashSet *setPtr)
static bool checkFaceArea (const bool report, const scalar minArea, const primitiveMesh &, const vectorField &faceAreas, const labelList &checkFaces, labelHashSet *setPtr)
static bool checkCellDeterminant (const bool report, const scalar minDet, const primitiveMesh &, const vectorField &faceAreas, const labelList &checkFaces, const labelList &affectedCells, labelHashSet *setPtr)

Detailed Description

Updateable mesh geometry + checking routines.

Source files

Definition at line 47 of file primitiveMeshGeometry.H.

Constructor & Destructor Documentation

◆ primitiveMeshGeometry()

primitiveMeshGeometry ( const primitiveMesh & mesh)

Construct from mesh.

Definition at line 206 of file primitiveMeshGeometry.C.

References correct(), and mesh().

Here is the call graph for this function:

Member Function Documentation

◆ ClassName()

ClassName ( "primitiveMeshGeometry" )

◆ mesh()

const primitiveMesh & mesh ( ) const
inline

◆ faceAreas()

const vectorField & faceAreas ( ) const
inline

Definition at line 118 of file primitiveMeshGeometry.H.

Referenced by checkCellDeterminant(), checkFaceAngles(), checkFaceArea(), checkFaceDotProduct(), checkFaceSkewness(), checkFaceTwist(), and checkFaceWeights().

Here is the caller graph for this function:

◆ faceCentres()

const vectorField & faceCentres ( ) const
inline

Definition at line 122 of file primitiveMeshGeometry.H.

Referenced by checkFaceSkewness(), checkFaceTwist(), and checkFaceWeights().

Here is the caller graph for this function:

◆ cellCentres()

const vectorField & cellCentres ( ) const
inline

Definition at line 126 of file primitiveMeshGeometry.H.

Referenced by checkFaceDotProduct(), checkFacePyramids(), checkFaceSkewness(), and checkFaceWeights().

Here is the caller graph for this function:

◆ cellVolumes()

const scalarField & cellVolumes ( ) const
inline

Definition at line 130 of file primitiveMeshGeometry.H.

◆ correct() [1/2]

void correct ( )

Take over properties from mesh.

Definition at line 219 of file primitiveMeshGeometry.C.

Referenced by primitiveMeshGeometry().

Here is the caller graph for this function:

◆ correct() [2/2]

void correct ( const pointField & p,
const labelList & changedFaces )

Recalculate on selected faces. Recalculates cell properties.

on owner and neighbour of these cells.

Definition at line 228 of file primitiveMeshGeometry.C.

References affectedCells(), and p.

Here is the call graph for this function:

◆ affectedCells()

Foam::labelList affectedCells ( const labelList & changedFaces) const

Helper function: get affected cells from faces.

Definition at line 181 of file primitiveMeshGeometry.C.

References affectedCells(), and UList< T >::size().

Referenced by affectedCells(), checkCellDeterminant(), checkCellDeterminant(), and correct().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkFaceDotProduct() [1/2]

bool checkFaceDotProduct ( const bool report,
const scalar orthWarn,
const primitiveMesh & mesh,
const vectorField & cellCentres,
const vectorField & faceAreas,
const labelList & checkFaces,
labelHashSet * setPtr )
static

◆ checkFacePyramids() [1/2]

bool checkFacePyramids ( const bool report,
const scalar minPyrVol,
const primitiveMesh & mesh,
const vectorField & cellCentres,
const pointField & p,
const labelList & checkFaces,
labelHashSet * setPtr )
static

Definition at line 381 of file primitiveMeshGeometry.C.

References cellCentres(), Foam::endl(), f(), Foam::Info, HashSet< Key, Hash >::insert(), pyramid< Point, PointRef, PolygonRef >::mag(), mesh(), p, Foam::Pout, Foam::reduce(), and SeriousErrorInFunction.

Referenced by checkFacePyramids().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkFaceSkewness() [1/2]

bool checkFaceSkewness ( const bool report,
const scalar internalSkew,
const scalar boundarySkew,
const primitiveMesh & mesh,
const vectorField & cellCentres,
const vectorField & faceCentres,
const vectorField & faceAreas,
const labelList & checkFaces,
labelHashSet * setPtr )
static

Definition at line 489 of file primitiveMeshGeometry.C.

References cellCentres(), Foam::endl(), faceAreas(), faceCentres(), Foam::Info, HashSet< Key, Hash >::insert(), Foam::mag(), mesh(), Foam::nl, Foam::normalised(), Foam::Pout, Foam::reduce(), and WarningInFunction.

Referenced by checkFaceSkewness().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkFaceWeights() [1/2]

bool checkFaceWeights ( const bool report,
const scalar warnWeight,
const primitiveMesh & mesh,
const vectorField & cellCentres,
const vectorField & faceCentres,
const vectorField & faceAreas,
const labelList & checkFaces,
labelHashSet * setPtr )
static

Definition at line 624 of file primitiveMeshGeometry.C.

References cellCentres(), Foam::endl(), faceAreas(), faceCentres(), Foam::Info, HashSet< Key, Hash >::insert(), Foam::mag(), mesh(), Foam::min(), Foam::nl, Foam::Pout, Foam::reduce(), and WarningInFunction.

Referenced by checkFaceWeights().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkFaceAngles() [1/2]

bool checkFaceAngles ( const bool report,
const scalar maxDeg,
const primitiveMesh & mesh,
const vectorField & faceAreas,
const pointField & p,
const labelList & checkFaces,
labelHashSet * setPtr )
static

◆ checkFaceTwist() [1/2]

bool checkFaceTwist ( const bool report,
const scalar minTwist,
const primitiveMesh & mesh,
const vectorField & faceAreas,
const vectorField & faceCentres,
const pointField & p,
const labelList & checkFaces,
labelHashSet * setPtr )
static

◆ checkFaceArea() [1/2]

bool checkFaceArea ( const bool report,
const scalar minArea,
const primitiveMesh & mesh,
const vectorField & faceAreas,
const labelList & checkFaces,
labelHashSet * setPtr )
static

Definition at line 1063 of file primitiveMeshGeometry.C.

References Foam::endl(), faceAreas(), Foam::Info, HashSet< Key, Hash >::insert(), Foam::mag(), mesh(), Foam::nl, Foam::reduce(), and WarningInFunction.

Referenced by checkFaceArea().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkCellDeterminant() [1/2]

bool checkCellDeterminant ( const bool report,
const scalar minDet,
const primitiveMesh & mesh,
const vectorField & faceAreas,
const labelList & checkFaces,
const labelList & affectedCells,
labelHashSet * setPtr )
static

Definition at line 1120 of file primitiveMeshGeometry.C.

References affectedCells(), cells, Foam::det(), Foam::endl(), faceAreas(), forAll, Foam::Info, HashSet< Key, Hash >::insert(), Foam::mag(), mesh(), Foam::min(), Foam::nl, Foam::reduce(), WarningInFunction, and Foam::Zero.

Referenced by checkCellDeterminant().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ checkFaceDotProduct() [2/2]

bool checkFaceDotProduct ( const bool report,
const scalar orthWarn,
const labelList & checkFaces,
labelHashSet * setPtr ) const

Definition at line 1219 of file primitiveMeshGeometry.C.

References checkFaceDotProduct().

Here is the call graph for this function:

◆ checkFacePyramids() [2/2]

bool checkFacePyramids ( const bool report,
const scalar minPyrVol,
const pointField & p,
const labelList & checkFaces,
labelHashSet * setPtr ) const

Definition at line 1240 of file primitiveMeshGeometry.C.

References checkFacePyramids(), and p.

Here is the call graph for this function:

◆ checkFaceSkewness() [2/2]

bool checkFaceSkewness ( const bool report,
const scalar internalSkew,
const scalar boundarySkew,
const labelList & checkFaces,
labelHashSet * setPtr ) const

Definition at line 1262 of file primitiveMeshGeometry.C.

References checkFaceSkewness().

Here is the call graph for this function:

◆ checkFaceWeights() [2/2]

bool checkFaceWeights ( const bool report,
const scalar warnWeight,
const labelList & checkFaces,
labelHashSet * setPtr ) const

Definition at line 1286 of file primitiveMeshGeometry.C.

References checkFaceWeights().

Here is the call graph for this function:

◆ checkFaceAngles() [2/2]

bool checkFaceAngles ( const bool report,
const scalar maxDeg,
const pointField & p,
const labelList & checkFaces,
labelHashSet * setPtr ) const

Definition at line 1308 of file primitiveMeshGeometry.C.

References checkFaceAngles(), and p.

Here is the call graph for this function:

◆ checkFaceTwist() [2/2]

bool checkFaceTwist ( const bool report,
const scalar minTwist,
const pointField & p,
const labelList & checkFaces,
labelHashSet * setPtr ) const

Definition at line 1353 of file primitiveMeshGeometry.C.

References checkFaceTwist(), and p.

Here is the call graph for this function:

◆ checkFaceArea() [2/2]

bool checkFaceArea ( const bool report,
const scalar minArea,
const labelList & checkFaces,
labelHashSet * setPtr ) const

Definition at line 1376 of file primitiveMeshGeometry.C.

References checkFaceArea().

Here is the call graph for this function:

◆ checkCellDeterminant() [2/2]

bool checkCellDeterminant ( const bool report,
const scalar warnDet,
const labelList & checkFaces,
const labelList & affectedCells,
labelHashSet * setPtr ) const

Definition at line 1396 of file primitiveMeshGeometry.C.

References affectedCells(), and checkCellDeterminant().

Here is the call graph for this function:

The documentation for this class was generated from the following files: