42#ifndef Foam_polyPatch_H
43#define Foam_polyPatch_H
86 mutable std::unique_ptr<labelList::subList> faceCellsPtr_;
89 mutable std::unique_ptr<labelList> mePtr_;
92 std::unique_ptr<scalarField> areaFractionPtr_;
153 const word& patchType
168 const word& patchType
184 const word& patchType
206 const word& patchType
255 virtual autoPtr<polyPatch>
clone
268 virtual autoPtr<polyPatch>
clone
277 (*
this, bm,
index, mapAddressing, newStart);
284 static autoPtr<polyPatch>
New
286 const word& patchType,
374 labelRange
range()
const
376 return labelRange(start_, this->
size());
483 label
whichFace(
const label facei)
const noexcept
485 return facei - start_;
uindirectPrimitivePatch pp(UIndirectList< face >(mesh.faces(), faceLabels), mesh.points())
Generic templated field type that is much like a Foam::List except that it is expected to hold numeri...
SubField< Type > subField
Declare type of subField.
SubList< T > subList
Declare type of subList.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
const Field< point_type > & points() const noexcept
virtual void movePoints(const Field< point_type > &)
Buffers for inter-processor communications streams (UOPstream, UIPstream).
A list of pointers to objects of type <T>, with allocation/deallocation management of the pointers....
A List with indirect addressing. Like IndirectList but does not store addressing.
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
static const UList< label > & null() noexcept
label size() const noexcept
Pointer management similar to std::unique_ptr, with some additional methods and type checking.
static autoPtr< T > New(Args &&... args)
Construct autoPtr with forwarding arguments.
A list of keyword definitions, which are a keyword followed by a number of values (eg,...
A range or interval of labels defined by a start and a size.
const word & physicalType() const noexcept
The (optional) physical type of the patch.
const wordList & inGroups() const noexcept
The (optional) groups that the patch belongs to.
label index() const noexcept
The index of this patch in the boundaryMesh.
const word & name() const noexcept
The patch name.
patchIdentifier(const patchIdentifier &)=default
Copy construct.
A polyBoundaryMesh is a polyPatch list with registered IO, a reference to the associated polyMesh,...
A patch is a list of labels that address the faces in the global face list.
virtual autoPtr< polyPatch > clone(const polyBoundaryMesh &bm) const
Construct and return a clone, resetting the boundary mesh.
static wordList constraintTypes()
Return a list of all the constraint patch types.
virtual void updateMesh(PstreamBuffers &)
Update of the patch topology.
const vectorField::subField faceAreas() const
Return face normals.
static autoPtr< polyPatch > New(const word &patchType, const word &name, const label size, const label start, const label index, const polyBoundaryMesh &bm)
Return pointer to a new patch created on freestore from components.
virtual void newInternalProcFaces(label &, label &) const
Return number of new internal of this polyPatch faces.
label whichFace(const label facei) const noexcept
Return label of face in patch from global face label.
TypeName("patch")
Runtime type information.
friend class polyBoundaryMesh
virtual label neighbPolyPatchID() const
Return nbr patchID.
declareRunTimeSelectionTable(autoPtr, polyPatch, word,(const word &name, const label size, const label start, const label index, const polyBoundaryMesh &bm, const word &patchType),(name, size, start, index, bm, patchType))
const UIndirectList< T > patchInternalList(const UList< T > &internalValues) const
Extract face cell data.
virtual bool coupled() const
Return true if this patch is geometrically coupled (i.e. faces and.
friend Ostream & operator<<(Ostream &, const polyPatch &)
virtual bool masterImplicit() const
Return implicit master.
virtual void initGeometry(PstreamBuffers &)
Initialise the calculation of the patch geometry.
virtual autoPtr< polyPatch > clone(const labelList &faceCells) const
Construct and return a clone, setting faceCells.
virtual void clearGeom()
Clear geometry.
void operator=(const polyPatch &p)
Copy assignment.
label offset() const noexcept
The offset where this patch starts in the boundary face list.
const faceList::subList faces() const
Return mesh faces for the patch.
virtual void initOrder(PstreamBuffers &, const primitivePatch &) const
Initialize ordering for primitivePatch. Does not.
virtual autoPtr< polyPatch > clone(const polyBoundaryMesh &bm, const label index, const label newSize, const label newStart) const
Construct and return a clone, resetting the face list and boundary mesh.
virtual const labelUList & nbrCells() const
Return nbrCells.
const vectorField::subField faceCentres() const
Return face centres.
virtual void movePoints(PstreamBuffers &, const pointField &p)
Correct patches after moving points.
virtual ~polyPatch()
Destructor.
virtual bool setTopology(polyTopoChange &)
Collect topology changes in a polyTopoChange object.
virtual bool changeTopology() const
For dynamic mesh cases - return true if this patch will change the topology.
virtual refPtr< labelListList > mapCollocatedFaces() const
Return mapped collocated faces.
const polyBoundaryMesh & boundaryMesh() const noexcept
Return boundaryMesh reference.
labelRange range() const
Return start/size range of this patch.
virtual autoPtr< polyPatch > clone(const polyBoundaryMesh &bm, const label index, const labelUList &mapAddressing, const label newStart) const
Construct and return a clone, resetting the face list and boundary mesh.
virtual void initUpdateMesh(PstreamBuffers &)
Initialise the update of the patch topology.
const Field< T >::subField patchSlice(const Field< T > &values) const
Slice Field to patch, using the number of patch faces.
virtual bool order(PstreamBuffers &, const primitivePatch &, labelList &faceMap, labelList &rotation) const
Return new ordering for primitivePatch.
virtual void clearAddressing()
Clear addressing.
polyPatch(const word &name, const label size, const label start, const label index, const polyBoundaryMesh &bm, const word &patchType)
Construct from components.
static int disallowGenericPolyPatch
Debug switch to disallow the use of genericPolyPatch.
label start() const noexcept
Return start label of this patch in the polyMesh face list.
const List< T >::subList patchSlice(const UList< T > &values) const
This patch slice from the complete list, which has size mesh::nFaces(), using the number of patch fac...
virtual void calcGeometry(PstreamBuffers &)
Calculate the patch geometry.
tmp< vectorField > faceCellCentres() const
Return face cell centres.
const List< T >::subList boundarySlice(const UList< T > &values) const
This patch slice from the list of boundary values, which has size mesh::nBoundaryFaces(),...
const labelList::subList faceOwner() const
Return face owner for the patch.
virtual word neighbRegionID() const
Return neighbour region name.
virtual void initMovePoints(PstreamBuffers &, const pointField &)
Initialise the patches for moving points.
declareRunTimeSelectionTable(autoPtr, polyPatch, dictionary,(const word &name, const dictionary &dict, const label index, const polyBoundaryMesh &bm, const word &patchType),(name, dict, index, bm, patchType))
static bool constraintType(const word &patchType)
Return true if the given type is a constraint type.
const labelUList & faceCells() const
Return face-cell addressing.
const labelList & meshEdges() const
Return global edge index for local edges.
tmp< scalarField > areaFraction() const
Return the cached area fraction. Usually only set for the non-overlap patches on ACMI.
Direct mesh changes based on v1.3 polyTopoChange syntax.
A class for managing references or pointers (no reference counting).
A class for managing temporary objects.
A class for handling words, derived from Foam::string.
#define NotImplemented
Issue a FatalErrorIn for a function not currently implemented.
OBJstream os(runTime.globalPath()/outputName)
Pair< int > faceMap(const label facePi, const face &faceP, const label faceNi, const face &faceN)
PtrList< polyPatch > polyPatchList
Store lists of polyPatch as a PtrList.
List< word > wordList
List of word.
List< label > labelList
A List of labels.
PrimitivePatch< SubList< face >, const pointField & > primitivePatch
A PrimitivePatch with a SubList addressing for the faces, const reference for the point field.
Ostream & operator<<(Ostream &, const boundaryPatch &p)
Write boundaryPatch as dictionary entries (without surrounding braces).
word name(const expressions::valueTypeCode typeCode)
A word representation of a valueTypeCode. Empty for expressions::valueTypeCode::INVALID.
vectorField pointField
pointField is a vectorField.
UList< label > labelUList
A UList of labels.
Macros to ease declaration of run-time selection tables.
#define declareRunTimeSelectionTable(ptrWrapper, baseType, argNames, argList, parList)
Declare a run-time selection (variables and adder classes).
labelRange operator()(const polyPatch &pp) const
Conversion/extraction to labelRange operation (functor).
Basic run-time type information using word as the type's name. Used to enhance the standard RTTI to c...
#define TypeName(TypeNameString)
Declare a ClassName() with extra virtual type info.