35Foam::label Foam::directionInfo::findEdge
37 const primitiveMesh&
mesh,
38 const labelList& edgeLabels,
43 forAll(edgeLabels, edgeLabelI)
45 label edgeI = edgeLabels[edgeLabelI];
54 <<
"Cannot find an edge among " << edgeLabels <<
endl
55 <<
"that uses vertices " << v0
63Foam::label Foam::directionInfo::lowest
71 label a1 = (a + 1) % size;
79 label b1 = (
b + 1) % size;
84 <<
"Problem : a:" << a <<
" b:" <<
b <<
" size:" << size
106 <<
"Illegal edge label:" << edgeI
107 <<
" when projecting cut edge from cell " << celli
108 <<
" to face " << facei
121 label fpA =
f.
find(
e.start());
128 return lowest(
f.
size(), fpA, fpB);
167 if ((fpA != -1) && (fpB != -1))
169 return lowest(
f.
size(), fpA, fpB);
185 if ((fpA != -1) && (fpB != -1))
187 return lowest(
f.
size(), fpA, fpB);
191 <<
"Found connected faces " <<
mesh.
faces()[f0I] <<
" and "
193 <<
"But none seems to be connected to face " << facei
213 os << rhs.index_ << rhs.n_;
219 reinterpret_cast<const char*
>(&rhs.index_),
237 is >> rhs.index_ >> rhs.n_;
239 else if (!is.checkLabelSize<>() || !is.checkScalarSize<>())
253 reinterpret_cast<char*
>(&rhs.index_),
streamFormat format() const noexcept
Get the current stream format.
virtual bool check(const char *operation) const
Check IOstream status for given operation.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)....
virtual bool beginRawRead()=0
Start of low-level raw binary read.
virtual Ostream & write(const char c)
Write character.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
iterator end() noexcept
Return an iterator to end traversing the UList.
label find(const T &val, label pos=0) const
Find index of the first occurrence of the value.
void size(const label n)
Older name for setAddressableSize.
Holds direction in which to split cell (in fact a local coordinate axes). Information is a label and ...
static label edgeToFaceIndex(const primitiveMesh &mesh, const label celli, const label facei, const label edgeI)
Given edge on hex cell find corresponding edge on face. Is either.
An edge is a list of two point labels. The functionality it provides supports the discretisation on a...
label end() const
Return end (last/second) vertex label.
label start() const
Return start (first) vertex label.
A face is a list of labels corresponding to mesh vertices.
static constexpr direction nComponents
Number of components in bool is 1.
virtual const faceList & faces() const
Return raw faces.
Cell-face mesh analysis engine.
const edgeList & edges() const
Return mesh edges. Uses calcEdges.
label nEdges() const
Number of mesh edges.
#define FatalErrorInFunction
Report an error message using Foam::FatalError.
OBJstream os(runTime.globalPath()/outputName)
Ostream & endl(Ostream &os)
Add newline and flush stream.
label readRawLabel(Istream &is)
Read raw label from binary stream.
errorManip< error > abort(error &err)
#define forAll(list, i)
Loop across all elements in list.