Go to the documentation of this file.
133 #ifndef faceCoupleInfo_H
134 #define faceCoupleInfo_H
137 #include "indirectPrimitivePatch.H"
138 #include "primitiveFacePatch.H"
212 template<
template<
class>
class FaceList>
215 const FaceList<face>&,
227 const bool compact =
true
266 const bool patchDivision,
270 const label edgeStart,
291 const bool sameOrientation
302 const bool sameOrientation,
370 const bool patchDivision,
395 const bool perfectMatch
416 const bool perfectMatch,
417 const bool orderedFaces,
418 const bool patchDivision
autoPtr< indirectPrimitivePatch > masterPatchPtr_
Master patch.
static scalar maxDistance(const face &cutF, const pointField &cutPoints, const face &masterF, const pointField &masterPoints)
Returns max distance to masterF of any point on cutF.
autoPtr< indirectPrimitivePatch > slavePatchPtr_
Slave patch.
static void findSlavesCoveringMaster(const primitiveMesh &mesh0, const primitiveMesh &mesh1, const scalar absTol, labelList &mesh0Faces, labelList &mesh1Faces)
Find matching (boundary)faces. Matching if slave is on top of.
A class for handling file names.
label mostAlignedCutEdge(const bool report, const polyMesh &slaveMesh, const bool patchDivision, const labelList &cutToMasterEdges, const labelList &cutToSlaveEdges, const label pointI, const label edgeStart, const label edgeEnd) const
Finds edge connected to point most aligned with master edge.
void writePointsFaces() const
Write connections between corresponding points and faces.
labelList cutToSlaveFaces_
slave
const labelList & cutToMasterFaces() const
Master face for every face on cut. Will always be at least.
static void writeOBJ(const fileName &fName, const edgeList &edges, const pointField &points, const bool compact=true)
Write edges.
static const scalar angleTol_
Angle matching tolerance.
edgeLookup cutEdgeToPoints_
For edges originating from splitting of edges:
A HashTable to objects of type <T> with a label key.
~faceCoupleInfo()
Destructor.
void setCutEdgeToPoints(const labelList &cutToMasterEdges)
From (many-to-one) map of cut edges to master edges determine.
labelList slaveToCutPoints_
const edgeLookup & cutEdgeToPoints() const
From two cut points (original edge) to list of inserted.
labelList patchFaces(const polyBoundaryMesh &patches, const wordList &names)
HashTable< labelList, edge, Hash< edge > > edgeLookup
Mesh consisting of general polyhedral cells.
labelList masterToCutPoints_
static void findPerfectMatchingFaces(const primitiveMesh &mesh0, const primitiveMesh &mesh1, const scalar absTol, labelList &mesh0Faces, labelList &mesh1Faces)
Finds matching (boundary)face centres.
const indirectPrimitivePatch & slavePatch() const
Addressing engine for coupled faces on mesh1.
void checkMatch(const labelList &cutToMasterEdges) const
const labelList & masterToCutPoints() const
void writeEdges(const labelList &, const labelList &) const
Write connections between corresponding edges as .obj files.
static labelList faceLabels(const polyPatch &)
Utility functions.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Pre-declare SubField and related Field type.
void subDivisionMatch(const polyMesh &slaveMesh, const bool patchDivision, const scalar absTol)
Find point and edge correspondence for slaves being subdivision of.
A patch is a list of labels that address the faces in the global face list.
faceCoupleInfo(const polyMesh &mesh0, const polyMesh &mesh1, const scalar absTol, const bool perfectMatch)
Construct from two meshes and absolute tolerance.
label growCutFaces(const labelList &, Map< labelList > &)
Grow cutToMasterFace across 'internal' edges.
static pointField calcFaceCentres(const FaceList< face > &, const pointField &, const label start, const label size)
Calculate face centres from (subset of) faces.
static bool matchPointsThroughFaces(const scalar absTol, const pointField &cutPoints, const faceList &cutFaces, const pointField &patchPoints, const faceList &patchFaces, const bool sameOrientation, labelList &patchToCutPoints, labelList &cutToCompact, labelList &compactToCut)
Matches points on patch to points on cut.
ClassName("faceCoupleInfo")
Runtime type information.
static label matchFaces(const scalar absTol, const pointField &points0, const face &f0, const pointField &points1, const face &f1, const bool sameOrientation)
Matches two faces.Determines rotation for f1 to match up.
void perfectPointMatch(const scalar absTol, const bool)
Find point and edge correspondence for perfect matching faces.
An STL-conforming hash table.
An auto-pointer similar to the STL auto_ptr but with automatic casting to a reference to the type and...
const labelList & cutToSlaveFaces() const
A 1D array of objects of type <T>, where the size of the vector is known and used for subscript bound...
bool regionEdge(const polyMesh &, const label slaveEdgeI) const
Check if edge on slavePatch corresponds to an edge between faces.
label geometricMatchEdgeFaces(Map< labelList > &candidates)
Gets a list of cutFaces (that use a master edge) and the.
Container for information needed to couple to meshes. When constructed from two meshes and a geometri...
A face is a list of labels corresponding to mesh vertices.
labelList findMappedEdges(const edgeList &edges, const labelList &pointMap, const indirectPrimitivePatch &)
Find corresponding edges on patch when having only a map for.
const primitiveFacePatch & cutFaces() const
Addressing engine for combined set of faces.
static Map< label > makeMap(const labelList &)
Create Map from List.
const indirectPrimitivePatch & masterPatch() const
Addressing engine for coupled faces on mesh0.
pointField cutPoints_
Description of cut.
autoPtr< primitiveFacePatch > cutFacesPtr_
labelList cutToMasterFaces_
Additional point coupling information. Is between points on.
label matchEdgeFaces(const labelList &, Map< labelList > &candidates)
Gets a list of cutFaces (that use a master edge) and the.
void perfectSlavePointMatch(const scalar absTol)
Used by perfectPointMatch. Determine match from cut points to.
const pointField & cutPoints() const
Points for combined set of faces.
A list of faces which address into the list of points.
const labelList & slaveToCutPoints() const
Cell-face mesh analysis engine.