Loading...
Searching...
No Matches
geomCellLooper Class Reference

Implementation of cellLooper. Does pure geometric cut through cell. More...

#include <geomCellLooper.H>

Inheritance diagram for geomCellLooper:
Collaboration diagram for geomCellLooper:

Public Member Functions

 TypeName ("geomCellLooper")
 Runtime type information.
 geomCellLooper (const polyMesh &mesh)
 Construct from mesh.
virtual ~geomCellLooper ()=default
 Destructor.
virtual bool cut (const vector &refDir, const label celli, const boolList &vertIsCut, const boolList &edgeIsCut, const scalarField &edgeWeight, labelList &loop, scalarField &loopWeights) const
 Create cut along circumference of celli. Gets current mesh cuts.
virtual bool cut (const plane &cutPlane, const label celli, const boolList &vertIsCut, const boolList &edgeIsCut, const scalarField &edgeWeight, labelList &loop, scalarField &loopWeights) const
 Same but now also base point of cut provided (instead of always.
Public Member Functions inherited from cellLooper
 TypeName ("cellLooper")
 Runtime type information.
 declareRunTimeSelectionTable (autoPtr, cellLooper, word,(const polyMesh &mesh),(mesh))
 cellLooper (const polyMesh &mesh)
 Construct from mesh.
autoPtr< cellLooperclone () const
 Clone.
virtual ~cellLooper ()=default
 Destructor.
Public Member Functions inherited from edgeVertex
 edgeVertex (const polyMesh &mesh)
 Construct from mesh.
const polyMeshmesh () const
bool isEdge (const label eVert) const
label getEdge (const label eVert) const
label getVertex (const label eVert) const
label vertToEVert (const label vertI) const
label edgeToEVert (const label edgeI) const
point coord (const label cut, const scalar weight) const
label cutPairToEdge (const label cut0, const label cut1) const
OstreamwriteCut (Ostream &os, const label cut, const scalar) const
 Write cut description to Ostream.
OstreamwriteCuts (Ostream &os, const labelList &, const scalarField &) const
 Write cut descriptions to Ostream.

Static Public Member Functions

static scalar snapTol ()
static void setSnapTol (const scalar tol)
Static Public Member Functions inherited from cellLooper
static autoPtr< cellLooperNew (const word &type, const polyMesh &mesh)
 Return a reference to the selected cellLooper.
Static Public Member Functions inherited from edgeVertex
static void updateLabels (const labelList &map, List< refineCell > &)
 Update refine list from map. Used to update cell/face labels.
static void updateLabels (const labelList &map, Map< label > &)
 Update map from map. Used to update cell/face labels.
static void updateLabels (const labelList &map, labelHashSet &)
 Update map from map. Used to update cell/face labels.
static bool isEdge (const primitiveMesh &mesh, const label eVert)
 Is eVert an edge?
static label getEdge (const primitiveMesh &mesh, const label eVert)
 Convert eVert to edge label.
static label getVertex (const primitiveMesh &mesh, const label eVert)
 Convert eVert to vertex label.
static label vertToEVert (const primitiveMesh &mesh, const label vertI)
 Convert pointi to eVert.
static label edgeToEVert (const primitiveMesh &mesh, const label edgeI)
 Convert edgeI to eVert.
static point coord (const primitiveMesh &, const label cut, const scalar weight)
 Return coordinate of cut (uses weight if edgeCut).
static label cutPairToEdge (const primitiveMesh &, const label cut0, const label cut1)
 Find mesh edge (or -1) between two cuts.

Additional Inherited Members

Protected Member Functions inherited from cellLooper
labelList getVertFacesNonEdge (const label celli, const label edgeI, const label vertI) const
 Get faces (on cell) connected to vertI which are not using edgeI.
label getFirstVertEdge (const label facei, const label vertI) const
 Get first edge connected to vertI and on facei.
labelList getVertEdgesNonFace (const label celli, const label facei, const label vertI) const
 Get edges (on cell) connected to vertI which are not on facei.
label getMisAlignedEdge (const vector &refDir, const label celli) const
 Return edge from cellEdges that is most perpendicular.
 cellLooper (const cellLooper &)=delete
 No copy construct.
void operator= (const cellLooper &)=delete
 No copy assignment.

Detailed Description

Implementation of cellLooper. Does pure geometric cut through cell.

Handles all cell shapes in the same way: cut edges with plane through cell centre and normal in direction of provided direction. Snaps cuts close to edge endpoints (close = snapTol * minEdgeLen) to vertices.

Currently determines cuts through edges (and edge endpoints close to plane) in random order and then sorts them acc. to angle. Could be converted to use walk but problem is that face can be cut multiple times (since does not need to be convex). Another problem is that edges parallel to plane might not be cut. So these are handled by looking at the distance from edge endpoints to the plane.

Source files

Definition at line 62 of file geomCellLooper.H.

Constructor & Destructor Documentation

◆ geomCellLooper()

geomCellLooper ( const polyMesh & mesh)
explicit

Construct from mesh.

Definition at line 201 of file geomCellLooper.C.

References cellLooper::cellLooper(), and edgeVertex::mesh().

Here is the call graph for this function:

◆ ~geomCellLooper()

virtual ~geomCellLooper ( )
virtualdefault

Destructor.

References cut().

Here is the call graph for this function:

Member Function Documentation

◆ TypeName()

TypeName ( "geomCellLooper" )

Runtime type information.

◆ snapTol()

scalar snapTol ( )
inlinestatic

Definition at line 151 of file geomCellLooper.H.

◆ setSnapTol()

void setSnapTol ( const scalar tol)
inlinestatic

Definition at line 156 of file geomCellLooper.H.

◆ cut() [1/2]

bool cut ( const vector & refDir,
const label celli,
const boolList & vertIsCut,
const boolList & edgeIsCut,
const scalarField & edgeWeight,
labelList & loop,
scalarField & loopWeights ) const
virtual

Create cut along circumference of celli. Gets current mesh cuts.

Cut along circumference is expressed as loop of cuts plus weights for cuts along edges (only valid for edge cuts). Return true if successful cut.

Implements cellLooper.

Reimplemented in hexCellLooper, and topoCellLooper.

Definition at line 209 of file geomCellLooper.C.

References cut(), and mesh.

Referenced by cut(), cut(), hexCellLooper::cut(), hexCellLooper::cut(), and ~geomCellLooper().

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

◆ cut() [2/2]


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