49 label newCelli = map[oldCelli];
73 label newMaster = map[iter.key()];
79 newSlave = map[iter()];
82 if ((newMaster != iter.key()) || (newSlave != iter()))
97 label newMaster = map[iter.key()];
103 newSlave = map[iter()];
109 <<
"master cell:" << iter.key()
110 <<
" has disappeared" <<
endl;
114 newCellPairs.
insert(newMaster, newSlave);
118 cellPairs = newCellPairs;
132 bool changed =
false;
136 const label newCelli = map[iter.key()];
138 if (newCelli != iter.key())
153 const label newCelli = map[iter.key()];
157 newCells.
insert(newCelli);
177 if (isEdge(mesh, cut))
179 const edge&
e = mesh.
edges()[getEdge(mesh, cut)];
181 return weight*pts[
e.end()] + (1-weight)*pts[
e.start()];
185 return pts[getVertex(mesh, cut)];
197 if (!isEdge(mesh, cut0) && !isEdge(mesh, cut1))
202 getVertex(mesh, cut0),
203 getVertex(mesh, cut1)
222 label edgeI = getEdge(cut);
224 const edge&
e = mesh().edges()[edgeI];
226 os <<
"edge:" << edgeI <<
e <<
' ' << coord(cut, weight);
230 label vertI = getVertex(cut);
232 os <<
"vertex:" << vertI <<
' ' << coord(cut, weight);
251 writeCut(os, cuts[cutI], weights[cutI]);
#define forAll(list, i)
Loop across all elements in list.
#define forAllConstIter(Container, container, iter)
Iterate across all elements in the container object of type.
bool insert(const Key &key)
Insert a new entry.
label size() const
Return number of elements in table.
bool insert(const Key &, const T &newElmt)
Insert a new hashedEntry.
void size(const label)
Override size to be inconsistent with allocated storage.
void setSize(const label)
Reset size of List.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
Ostream & writeCuts(Ostream &os, const labelList &, const scalarField &) const
Write cut descriptions to Ostream.
static point coord(const primitiveMesh &, const label cut, const scalar weight)
Return coordinate of cut (uses weight if edgeCut)
static void updateLabels(const labelList &map, List< refineCell > &)
Update refine list from map. Used to update cell/face labels.
Ostream & writeCut(Ostream &os, const label cut, const scalar) const
Write cut description to Ostream.
static label cutPairToEdge(const primitiveMesh &, const label cut0, const label cut1)
Find mesh edge (or -1) between two cuts.
An edge is a list of two point labels. The functionality it provides supports the discretisation on a...
Cell-face mesh analysis engine.
const edgeList & edges() const
Return mesh edges. Uses calcEdges.
virtual const pointField & points() const =0
Return mesh points.
Container with cells to refine. Refinement given as single direction.
const vector & direction() const
#define WarningInFunction
Report a warning using Foam::Warning.
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
Ostream & endl(Ostream &os)
Add newline and flush stream.