14#ifndef OPENSWMMVIS_MESH_MESHBOUNDARYGRAPH_H
15#define OPENSWMMVIS_MESH_MESHBOUNDARYGRAPH_H
40 const QVector<bool> &isBoundary);
51 [[nodiscard]] QVector<int>
shortestPath(
int startSlot,
int endSlot)
const;
55 [[nodiscard]]
bool isEmpty()
const {
return m_edges.isEmpty(); }
58 [[nodiscard]]
int edgeCount()
const {
return int(m_edges.size()); }
62 {
return m_slotToEdge.contains(slot); }
73 QVector<Edge> m_edges;
74 QHash<int,int> m_slotToEdge;
78 QVector<int> m_vertPtr;
79 QVector<int> m_vertEdge;
Undirected graph whose nodes are mesh vertices and whose arcs are boundary edge slots (mesh::edgeSlot...
Definition meshboundarygraph.h:34
static MeshBoundaryGraph build(const MeshResult &mesh, const QVector< bool > &isBoundary)
Build from mesh and the flat per-slot boundary flags (isBoundary[mesh::edgeSlot(cell,...
Definition meshboundarygraph.cpp:19
bool contains(int slot) const
True when slot (mesh::edgeSlot(cell, edgeLocal)) is one of them.
Definition meshboundarygraph.h:61
QVector< int > shortestPath(int startSlot, int endSlot) const
Shortest chain of boundary edge slots from startSlot to endSlot, inclusive of both terminal slots.
Definition meshboundarygraph.cpp:84
int edgeCount() const
Number of boundary edge slots in the graph.
Definition meshboundarygraph.h:58
bool isEmpty() const
True when the mesh contributed no boundary edges (also the state of a default-constructed graph).
Definition meshboundarygraph.h:55
std::vector< double > len
Definition mesh2dresultsexport.cpp:448
int b
local residual indices, a < b
Definition meshquadmatch.cpp:46
int a
Definition meshquadmatch.cpp:46
Definition meshcommands.h:302
Result of MeshGenerator::generate.
Definition meshresult.h:116