Loading...
Searching...
No Matches
OppositeFaceCellWave< Type, TrackingData > Class Template Reference

Version of FaceCellWave that walks through prismatic cells only. More...

#include <OppositeFaceCellWave.H>

Inheritance diagram for OppositeFaceCellWave< Type, TrackingData >:
Collaboration diagram for OppositeFaceCellWave< Type, TrackingData >:

Public Member Functions

 OppositeFaceCellWave (const polyMesh &, const labelList &initialChangedFaces, const List< Type > &changedFacesInfo, UList< Type > &allFaceInfo, UList< Type > &allCellInfo, const label maxIter, TrackingData &td=FaceCellWaveBase::dummyTrackData_)
 Construct from mesh and list of changed faces with the Type for these faces.
virtual ~OppositeFaceCellWave ()=default
 Destructor.
virtual label faceToCell ()
 Propagate from face to cell. Returns total number of cells.
virtual label cellToFace ()
 Propagate from cell to face. Returns total number of faces.
Public Member Functions inherited from FaceCellWave< Type, int >
virtual ~FaceCellWave ()=default
 Destructor.
UList< Type > & allFaceInfo () noexcept
 Access allFaceInfo.
UList< Type > & allCellInfo () noexcept
 Access allCellInfo.
const int & data () const noexcept
 Additional data to be passed into container.
void setFaceInfo (const label facei, const Type &faceInfo)
 Set single initial changed face.
virtual label iterate (const label maxIter)
 Iterate until no changes or maxIter reached.
Public Member Functions inherited from FaceCellWaveBase
 ClassName ("FaceCellWave")
 Runtime type information.
 FaceCellWaveBase (const polyMesh &mesh)
 Construct with mesh reference and set initial sizes.
const polyMeshmesh () const noexcept
 Return access to the mesh.
label nChangedCells () const noexcept
 Current number of changed cells.
label nChangedFaces () const noexcept
 Current number of changed faces.
label nUnvisitedCells () const noexcept
 Get number of unvisited cells, i.e. cells that were not (yet) reached from walking across mesh.
label nUnvisitedFaces () const noexcept
 Get number of unvisited faces.
Public Member Functions inherited from OppositeFaceCellWaveBase
 ClassName ("OppositeFaceCellWave")
 Runtime type information.
 OppositeFaceCellWaveBase (const polyMesh &mesh)
 Construct with mesh reference (for sizing).

Protected Member Functions

void opposingFaceLabels (const label celli, const label facei, DynamicList< label > &) const
 Determine 'opposite' faces (= faces not sharing a vertex) on cell.
Protected Member Functions inherited from FaceCellWave< Type, int >
bool updateCell (const label celli, const label neighbourFacei, const Type &neighbourInfo, const scalar tol, Type &cellInfo)
 Updates cellInfo with information from neighbour.
bool updateFace (const label facei, const label neighbourCelli, const Type &neighbourInfo, const scalar tol, Type &faceInfo)
 Updates faceInfo with information from neighbour.
void checkCyclic (const polyPatch &pPatch) const
 Debugging: check info on both sides of cyclic.
bool hasPatch () const
 Has cyclic patch?
void mergeFaceInfo (const polyPatch &patch, const label nFaces, const labelUList &changedFaces, const UList< Type > &changedFacesInfo)
 Merge received patch data into global data.
label getChangedPatchFaces (const polyPatch &patch, const label startFacei, const label nFaces, labelUList &changedPatchFaces, UList< Type > &changedPatchFacesInfo) const
 Extract info for single patch only.
void leaveDomain (const polyPatch &patch, const label nFaces, const labelUList &faceLabels, UList< Type > &faceInfo) const
 Handle leaving domain. Implementation referred to Type.
void enterDomain (const polyPatch &patch, const label nFaces, const labelUList &faceLabels, UList< Type > &faceInfo) const
 Handle leaving domain. Implementation referred to Type.
void transform (const tensorField &rotTensor, const label nFaces, UList< Type > &faceInfo)
 Apply transformation to Type.
void handleProcPatches ()
 Merge data from across processor boundaries.
void handleCyclicPatches ()
 Merge data from across cyclics.
void handleAMICyclicPatches ()
 Merge data from across AMI cyclics.
void handleExplicitConnections ()
 Merge data across explicitly provided local connections.
 FaceCellWave (const FaceCellWave &)=delete
 No copy construct.
void operator= (const FaceCellWave &)=delete
 No copy assignment.

Additional Inherited Members

Static Public Member Functions inherited from FaceCellWaveBase
static scalar propagationTol () noexcept
 Access to propagation tolerance.
static scalar setPropagationTol (const scalar tol) noexcept
 Change propagation tolerance, return previous value.
Static Public Attributes inherited from FaceCellWaveBase
static int dummyTrackData_ = 12345
 Default trackData value (for default template argument).
Protected Types inherited from FaceCellWave< Type, int >
typedef std::pair< label, Type > taggedInfoType
 Information tagged with a source or destination id.
Static Protected Member Functions inherited from FaceCellWave< Type, int >
static void offset (const polyPatch &patch, const label off, const label nFaces, labelUList &faces)
 Offset face labels by constant value.
Protected Attributes inherited from FaceCellWave< Type, int >
const labelPairList explicitConnections_
 Optional boundary faces that information should travel through.
UList< Type > & allFaceInfo_
 Information for all faces.
UList< Type > & allCellInfo_
 Information for all cells.
int & td_
 Additional data to be passed into container.
DynamicList< taggedInfoTypechangedBaffles_
const bool hasCyclicPatches_
 Contains cyclics.
const bool hasCyclicAMIPatches_
 Contains cyclicAMI.
label nEvals_
 Number of evaluations.
Protected Attributes inherited from FaceCellWaveBase
const polyMeshmesh_
 Reference to mesh.
PstreamBuffers pBufs_
 Buffers when updating processor patches.
bitSet changedFace_
 Track if face has changed.
bitSet changedCell_
 Track if cell has changed.
DynamicList< label > changedFaces_
 List of changed faces.
DynamicList< label > changedCells_
 List of changed cells.
label nUnvisitedFaces_
 Current count of unvisited faces.
label nUnvisitedCells_
 Current count of unvisited cells.
Protected Attributes inherited from OppositeFaceCellWaveBase
DynamicList< label > changedOppositeFaces_
 For every entry in changedCells (i.e. the cell front) gives.
Static Protected Attributes inherited from FaceCellWaveBase
static const scalar geomTol_ = 1e-6
static scalar propagationTol_ = 0.01

Detailed Description

template<class Type, class TrackingData = int>
class Foam::OppositeFaceCellWave< Type, TrackingData >

Version of FaceCellWave that walks through prismatic cells only.

Used to determine mesh structure. In the front walking routines (faceToCell and faceToCell) it

  • walks across prismatic cells only
  • and only to a single opposite face

Notes: A cell with a split faces will be marked but not walked through (since there is no single opposite face.

Source files

Definition at line 92 of file OppositeFaceCellWave.H.

Constructor & Destructor Documentation

◆ OppositeFaceCellWave()

template<class Type, class TrackingData>
OppositeFaceCellWave ( const polyMesh & mesh,
const labelList & initialChangedFaces,
const List< Type > & changedFacesInfo,
UList< Type > & allFaceInfo,
UList< Type > & allCellInfo,
const label maxIter,
TrackingData & td = FaceCellWaveBase::dummyTrackData_ )

Construct from mesh and list of changed faces with the Type for these faces.

Iterates until nothing changes or maxIter reached. (maxIter can be 0)

Definition at line 71 of file OppositeFaceCellWave.C.

References FaceCellWave< Type, int >::allCellInfo(), FaceCellWave< Type, int >::allFaceInfo(), Foam::endl(), Foam::exit(), FaceCellWave< Type, int >::FaceCellWave(), Foam::FatalError, FatalErrorInFunction, FaceCellWave< Type, int >::iterate(), FaceCellWaveBase::mesh(), FaceCellWaveBase::nChangedCells(), FaceCellWaveBase::nChangedFaces(), OppositeFaceCellWaveBase::OppositeFaceCellWaveBase(), and td().

Here is the call graph for this function:

◆ ~OppositeFaceCellWave()

template<class Type, class TrackingData = int>
virtual ~OppositeFaceCellWave ( )
virtualdefault

Destructor.

Member Function Documentation

◆ opposingFaceLabels()

template<class Type, class TrackingData>
void opposingFaceLabels ( const label celli,
const label facei,
DynamicList< label > & oppositeFaceLabels ) const
protected

Determine 'opposite' faces (= faces not sharing a vertex) on cell.

Definition at line 28 of file OppositeFaceCellWave.C.

References DynamicList< T, SizeMin >::clear(), f(), FaceCellWaveBase::mesh_, and DynamicList< T, SizeMin >::push_back().

Referenced by faceToCell().

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

◆ faceToCell()

◆ cellToFace()


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