68 label edgeI = pEdges[pEdgeI];
79 <<
"Cannot find edge between mesh points " << v0 <<
" and " << v1
94 <<
"Cannot find patch " << name <<
nl 95 <<
"It should be present but of zero size" << endl
96 <<
"Valid patches are " << bMesh.
names()
100 if (bMesh[patchi].size())
103 <<
"Patch " << name <<
" is present but non-zero size" 110 int main(
int argc,
char *argv[])
121 runTime.functionObjects().off();
123 const word oldInstance = mesh.pointsInstance();
131 faceSet facesSet(mesh, setName);
133 Info<<
"Read " << facesSet.size() <<
" faces to split" << endl <<
endl;
145 <<
"Face " << faces[i] <<
" in faceSet " << setName
146 <<
" is not an internal face." 153 checkPatch(mesh.boundaryMesh(), masterPatch);
154 checkPatch(mesh.boundaryMesh(), slavePatch);
176 const labelList& meshPoints = fPatch.meshPoints();
184 forAll(allEdgeFaces, patchEdgeI)
186 if (allEdgeFaces[patchEdgeI].size() == 1)
188 const edge& e = fPatch.edges()[patchEdgeI];
194 meshPoints[e.
start()],
198 fenceEdges.insert(edgeI);
203 label startFacei = faces[0];
219 zoneFlip[i] = !regionInfo.sideOwner().found(faces[i]);
238 Info<<
"Adding point and face zones" <<
endl;
239 mesh.addZones(pz, fz, cz);
261 Info<<
nl <<
"Constructed topologyModifier:" <<
endl;
262 splitter[0].writeDict(
Info);
273 mesh.setInstance(oldInstance);
277 mesh.setInstance(runTime.timeName());
280 Info<<
"Writing mesh to " << runTime.timeName() <<
endl;
284 <<
"Failed writing polyMesh."
#define forAll(list, i)
Loop across all elements in list.
errorManipArg< error, int > exit(error &err, const int errNo=1)
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
const labelListList & pointEdges() const
Cell-face mesh analysis engine.
Ostream & endl(Ostream &os)
Add newline and flush stream.
bool optionFound(const word &opt) const
Return true if the named option is found.
virtual const pointField & points() const =0
Return mesh points.
label findPatchID(const word &patchName) const
Find patch index given a name.
static void noParallel()
Remove the parallel options.
static SLList< string > validArgs
A list of valid (mandatory) arguments.
label otherVertex(const label a) const
Given one vertex, return the other.
A list of faces which address into the list of points.
Determines the 'side' for every face and connected to a singly-connected (through edges) region of fa...
An edge is a list of two point labels. The functionality it provides supports the discretisation on a...
A class for handling words, derived from string.
Field< scalar > scalarField
Specialisation of Field<T> for scalar.
wordList names() const
Return a list of patch names.
errorManip< error > abort(error &err)
This class is derived from polyMesh and serves as a tool for statically connecting pieces of a mesh b...
bool isInternalFace(const label faceIndex) const
Return true if given face label is internal to the mesh.
Attach/detach boundary mesh modifier. This modifier takes a set of internal faces and converts them i...
const edgeList & edges() const
Return mesh edges. Uses calcEdges.
label end() const
Return end vertex label.
A List with indirect addressing.
virtual const faceList & faces() const =0
Return faces.
virtual const labelList & faceOwner() const =0
Face face-owner addressing.
A subset of mesh faces organised as a primitive patch.
Foam::argList args(argc, argv)
label start() const
Return start vertex label.