Go to the documentation of this file.
44 void Foam::enrichedPatch::calcMeshPoints()
const
49 <<
"Mesh points already calculated."
60 void Foam::enrichedPatch::calcLocalFaces()
const
65 <<
"Local faces already calculated."
72 Map<label> mpLookup(2*
mp.size());
76 mpLookup.insert(
mp[mpI], mpI);
79 const faceList& faces = enrichedFaces();
81 localFacesPtr_ =
new faceList(faces.size());
86 const face&
f = faces[facei];
88 face& curlf = lf[facei];
94 curlf[pointi] = mpLookup.cfind(
f[pointi])();
100 void Foam::enrichedPatch::calcLocalPoints()
const
105 <<
"Local points already calculated."
116 lp[i] = pointMap().cfind(
mp[i])();
121 void Foam::enrichedPatch::clearOut()
137 Foam::enrichedPatch::enrichedPatch
146 masterPatch_(masterPatch),
147 slavePatch_(slavePatch),
150 masterPatch_.meshPoints().size()
151 + slavePatch_.meshPoints().size()
153 pointMapComplete_(
false),
154 pointMergeMap_(2*slavePatch_.meshPoints().size()),
155 slavePointPointHits_(slavePointPointHits),
156 slavePointEdgeHits_(slavePointEdgeHits),
157 slavePointFaceHits_(slavePointFaceHits),
158 enrichedFacesPtr_(
nullptr),
159 meshPointsPtr_(
nullptr),
160 localFacesPtr_(
nullptr),
161 localPointsPtr_(
nullptr),
162 pointPointsPtr_(
nullptr),
163 masterPointFacesPtr_(
nullptr),
164 cutFacesPtr_(
nullptr),
165 cutFaceMasterPtr_(
nullptr),
166 cutFaceSlavePtr_(
nullptr)
187 return *meshPointsPtr_;
198 return *localFacesPtr_;
204 if (!localPointsPtr_)
209 return *localPointsPtr_;
215 if (!pointPointsPtr_)
220 return *pointPointsPtr_;
226 const faceList& faces = enrichedFaces();
232 const face& curFace = faces[facei];
236 if (!pointMap().
found(curFace[pointi]))
239 <<
"Point " << pointi <<
" of face " << facei
240 <<
" global point index: " << curFace[pointi]
241 <<
" not supported in point map. This is not allowed."
259 const faceList& faces = localFaces();
261 for (
const face&
f : faces)
List< label > labelList
A List of labels.
vectorField pointField
pointField is a vectorField.
const dimensionedScalar mp
Proton mass.
const labelList & meshPoints() const
Return mesh points.
A class for handling file names.
Template functions to aid in the implementation of demand driven data.
Ostream & endl(Ostream &os)
Add newline and flush stream.
void writeOBJ(const fileName &fName) const
Debugging: dump graphical representation to obj format file.
const pointField & localPoints() const
Return local points.
bool checkSupport() const
Check if the patch is fully supported.
#define forAll(list, i)
Loop across all elements in list.
void deleteDemandDrivenData(DataPtr &dataPtr)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
errorManip< error > abort(error &err)
const faceList & localFaces() const
Return local faces.
const labelListList & pointPoints() const
Return point-point addressing.
~enrichedPatch()
Destructor.
Output to file stream, using an OSstream.
const Map< point > & pointMap() const
Return map of points.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
List< face > faceList
A List of faces.
A face is a list of labels corresponding to mesh vertices.
void setSize(const label newSize)
Alias for resize(const label)
defineTypeNameAndDebug(combustionModel, 0)
#define WarningInFunction
Report a warning using Foam::Warning.
Class to handle errors and exceptions in a simple, consistent stream-based manner.
A list of faces which address into the list of points.