69 m_deleteGraph = !modifyG;
86 enum class CompType { bond, polygon, triconnected };
100 m_type = (m_edges.
size() >= 4) ? CompType::triconnected : CompType::polygon;
136 m_TSTACK_h[++m_top] = h;
137 m_TSTACK_a[m_top] = a;
138 m_TSTACK_b[m_top] = b;
192 int high(
node v) {
return (m_HIGHPT[v].empty()) ? 0 : m_HIGHPT[v].front(); }
Declaration and implementation of Array class and Array algorithms.
Declaration and implementation of ArrayBuffer class.
Includes declaration of graph class.
Declaration of graph copy classes.
Declaration of doubly linked lists and iterators.
Basic declarations, included by all source files.
An array that keeps track of the number of inserted elements; also usable as an efficient stack.
The parameterized class Array implements dynamic arrays of type E.
Class for the representation of edges.
node target() const
Returns the target node of the edge.
Copies of graphs with mapping between nodes and edges.
Data type for general directed graphs (adjacency list representation).
Doubly linked lists (maintaining the length of the list).
int size() const
Returns the number of elements in the list.
iterator pushBack(const E &x)
Adds element x at the end of the list.
Encapsulates a pointer to a list element.
bool valid() const
Returns true iff the iterator points to an element.
Class for the representation of nodes.
realizes Hopcroft/Tarjan algorithm for finding the triconnected components of a biconnected multi-gra...
bool afterRecursivePathSearch(const node v, const int vnum, const int outv, const edge e, const node w, const int wnum, node &s1, node &s2)
pathSearch() helper for the fail-fast version
EdgeArray< bool > m_START
edge starts a path
void splitMultiEdges()
splits bundles of multi-edges into bonds and creates a new virtual edge in GC.
void assembleTriconnectedComponents()
merges split-components into triconnected components
NodeArray< List< edge > > m_A
adjacency list of v
EdgeArray< ListIterator< int > > m_IN_HIGH
pointer to element in HIGHPT list containing e
NodeArray< int > m_LOWPT1
T GCoriginal(T n) const
returns m_pG.original(n) if m_pG is a GraphCopySimple, otherwise n itself
ArrayBuffer< edge > m_ESTACK
stack of currently active edges
Graph * m_pG
modifiable copy of G also containing virtual edges
node m_start
start node of dfs traversal
EdgeType
type of edges with respect to palm tree
Triconnectivity(Graph &G, bool modifyG=false)
Divides G into triconnected components.
EdgeArray< ListIterator< edge > > m_IN_ADJ
pointer to element in adjacency list containing e
bool m_deleteGraph
whether the Graph(Copy) was created by us and should thus be deleted in the destructor
CompStruct & newComp()
create a new empty component
NodeArray< int > m_DEGREE
degree of v
CompStruct & newComp(CompType t)
create a new empty component of type t
CompType
type of split-components / triconnected components
Triconnectivity(const Graph &G)
Divides G into triconnected components.
int m_numComp
number of components
bool checkSepPair(edge eVirt) const
void DFS1(node v, node u)
first dfs traversal
Triconnectivity(const Graph &G, bool &isTric, node &s1, node &s2)
Tests G for triconnectivity.
NodeArray< node > m_FATHER
father of v in palm tree
int m_numCount
counter for dfs-traversal
Triconnectivity(const Triconnectivity &)=delete
Triconnectivity(Graph *G)
void buildAcceptableAdjStruct()
constructs ordered adjaceny lists
void DFS2()
the second dfs traversal
bool TSTACK_notEOS()
returns true iff end-of-stack marker is not on top of TSTACK
Array< node > m_NODEAT
node with number i
int high(node v)
returns high(v) value
Array< CompStruct > m_component
array of components
bool pathSearch(node init_v, bool fail_fast, node &s1, node &s2)
finding of split components
NodeArray< int > m_NUMBER
(first) dfs-number of v
void TSTACK_push(int h, int a, int b)
push a triple on TSTACK
bool m_newPath
true iff we start a new path
void DFS1(node v, node u, node &s1)
special version for triconnectivity test
NodeArray< int > m_ND
number of descendants in palm tree
EdgeArray< EdgeType > m_TYPE
type of edge e
void TSTACK_pushEOS()
push end-of-stack marker on TSTACK
NodeArray< edge > m_TREE_ARC
tree arc entering v
bool checkComp() const
Checks if computed triconnected components are correct.
NodeArray< List< int > > m_HIGHPT
list of fronds entering v in the order they are visited
void afterRecursivePathSearch(const node v, const int vnum, const int outv, const ListIterator< edge > it, const edge e, const node w, int wnum)
pathSearch() helper for the non-fail-fast version
void printOs(edge e) const
debugging stuff
NodeArray< int > m_LOWPT2
NodeArray< int > m_NEWNUM
(second) dfs-number of v
RegisteredArray for edges of a graph, specialized for EdgeArray<edge>.
RegisteredArray for nodes, edges and adjEntries of a graph.
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF dynamic library (shared object / DLL),...
The namespace for all OGDF objects.
@ tree
for every hyperedge e a minimal subcubic tree connecting all hypernodes incident with e together is a...
std::ostream & operator<<(std::ostream &os, const ogdf::Array< E, INDEX > &a)
Prints array a to output stream os.
representation of a component
CompStruct & operator<<(edge e)
void finishTricOrPoly(edge e)