bool operator==(const ArcGraphPart &p) const
tests whether two ArcGraphParts contain the same arcs
ArcGraphPart & operator=(const ArcGraphPart &s)
copy operator
void clearArcs()
removes all the arcs from the ArcGraphPart
void unvirtualizedEraseChildren(NodeId id)
same function as eraseChildren but without any virtual call to an erase
void unvirtualizedEraseParents(NodeId id)
same function as eraseParents but without any virtual call to an erase
void unvirtualizedEraseNeighbours(NodeId id)
same function as eraseNeighbours but without any virtual call to an erase
EdgeGraphPart & operator=(const EdgeGraphPart &s)
copy operator
bool operator==(const EdgeGraphPart &p) const
tests whether two EdgeGraphParts contain the same edges
virtual void clearEdges()
removes all the edges from the EdgeGraphPart
NodeProperty< NodeId > chainComponents() const
returns a property {node:id of chain component} (edges only)
bool hasMixedOrientedPath(NodeId node1, NodeId node2) const
returns true if a mixed edge/directed arc path from node1 to node2 in the arc/edge set exists.
void eraseNode(const NodeId node) override
remove a node as well as its adjacent arcs and edges from the graph
MixedGraph & operator=(const MixedGraph &g)
copy operator
NodeSet chainComponent(NodeId node) const
returns the set of nodes reachable by undirected path
NodeSet boundary(NodeId node) const
returns the set of node adjacent to a given node
std::optional< std::vector< NodeId > > mixedOrientedPath(NodeId node1, NodeId node2) const
returns a mixed edge/directed arc path from node1 to node2 in the arc/edge set
void clear() override
removes all the nodes, arcs and edges from the graph
MixedGraph(Size nodes_size=HashTableConst::default_size, bool nodes_resize_policy=true, Size arcs_size=HashTableConst::default_size, bool arcs_resize_policy=true, Size edges_size=HashTableConst::default_size, bool edges_resize_policy=true)
default constructor
bool operator==(const MixedGraph &g) const
tests whether two MixedGraphs are identical (same nodes, arcs and edges)
NodeProperty< NodeId > connectedComponents() const
returns a property {node:id of weakly connected component}
std::optional< std::vector< NodeId > > mixedUnorientedPath(NodeId node1, NodeId node2) const
returns a mixed/directed path from node1 to node2 in the arc/edge set
virtual void eraseNode(const NodeId id)
erase the node with the given id
NodeGraphPart & operator=(const NodeGraphPart &p)
copy operator
virtual void clearNodes()
remove all the nodes from the NodeGraphPart
bool operator==(const NodeGraphPart &p) const
check whether two NodeGraphParts contain the same nodes
Size NodeId
Type for node ids.
HashTable< NodeId, VAL > NodeProperty
Property on graph elements.
Set< NodeId > NodeSet
Some typdefs and define for shortcuts ...
Base classes for mixed directed/undirected graphs.
NodeSet boundary(const G &g, NodeId node)
Returns the boundary of node: neighbours ∪ parents ∪ children.
NodeProperty< NodeId > chainComponents(const G &g)
Returns a node-to-component-id mapping for the chain components of g (connected components of the edg...
bool hasMixedOrientedPath(const G &g, NodeId n1, NodeId n2)
Returns true if a mixed-oriented path from n1 to n2 exists.
NodeSet chainComponent(const G &g, NodeId node)
Returns the chain component of node in g.
std::optional< std::vector< NodeId > > mixedUnorientedPath(const G &g, NodeId n1, NodeId n2)
Shortest path ignoring all orientations in a mixed graph.
std::optional< std::vector< NodeId > > mixedOrientedPath(const G &g, NodeId n1, NodeId n2)
Shortest mixed-oriented path from n1 to n2.
NodeProperty< NodeId > connectedComponents(const G &g)
Returns a node-to-component-id mapping for the (weakly) connected components of g.
gum is the global namespace for all aGrUM entities
Generic BFS-based path-finding algorithms for aGrUM graphs.
Generic node-reachability algorithms for aGrUM graphs.