Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

ClusterPQContainer.h
Go to the documentation of this file.
1 
36 #pragma once
37 
38 #include <ogdf/basic/EdgeArray.h>
39 #include <ogdf/basic/NodeArray.h>
41 
42 namespace ogdf {
43 
44 class CconnectClusterPlanarEmbed;
45 
46 namespace cluster_planarity {
47 
51 
52  // Definition
53  // incoming edge of v: an edge e = (v,w) with number(v) < number(w)
54 
55  // Stores for every node v the keys corresponding to the incoming edges of v
57 
58  // Stores for every node v the keys corresponding to the outgoing edges of v
60 
61  // Stores for every node v the sequence of incoming edges of v according
62  // to the embedding
64 
65  // Stores for every node v the nodes corresponding to the
66  // opposed sink indicators found in the frontier of v.
68 
69  // Stores for every node v the nodes corresponding to the
70  // non opposed sink indicators found in the frontier of v.
72 
73  // Table to acces for every edge its corresponding key in the PQTree
75 
76  // Stores for every node its st-number
78 
79  // Stores for every st-number the node
81 
83 
84  // the subgraph that contains the biconnected component
85  // NOT THE COPY OF THE BICONNECTED COMPONENT THAT WAS CONSTRUCTED
86  // DURING PLANARITY TESTING. THIS HAS BEEN DELETED.
88  // corresponding PQTree
90  // The leaf correpsonding to the edge (s,t).
92 
93 public:
95  : m_inLeaves(nullptr)
96  , m_outLeaves(nullptr)
97  , m_frontier(nullptr)
98  , m_opposed(nullptr)
99  , m_nonOpposed(nullptr)
100  , m_edge2Key(nullptr)
101  , m_numbering(nullptr)
102  , m_tableNumber2Node(nullptr)
103  , m_superSink(nullptr)
104  , m_subGraph(nullptr)
105  , m_T(nullptr)
106  , m_stEdgeLeaf(nullptr) { }
107 
109 
110  void init(Graph* subGraph) {
111  m_subGraph = subGraph;
113 
115 
116  m_frontier = new NodeArray<SListPure<edge>>(*subGraph);
117 
118  m_opposed = new NodeArray<SListPure<node>>(*subGraph);
119 
120  m_nonOpposed = new NodeArray<SListPure<node>>(*subGraph);
121 
122  m_edge2Key = new EdgeArray<InfoLeafPtr>(*subGraph);
123 
124  m_numbering = new NodeArray<int>(*subGraph);
125 
126  m_tableNumber2Node = new Array<node>(subGraph->numberOfNodes() + 1);
127  }
128 
129  void Cleanup() {
130  delete m_inLeaves;
131  if (m_outLeaves) {
132  for (node v : m_subGraph->nodes) {
133  while (!(*m_outLeaves)[v].empty()) {
134  InfoLeafPtr L = (*m_outLeaves)[v].popFrontRet();
135  delete L;
136  }
137  }
138  delete m_outLeaves;
139  }
140  delete m_frontier;
141  delete m_opposed;
142  delete m_nonOpposed;
143  delete m_edge2Key;
144  if (m_T) {
146  delete m_T;
147  }
148  delete m_numbering;
149  delete m_tableNumber2Node;
150  }
151 };
152 
153 }
154 }
ogdf
The namespace for all OGDF objects.
Definition: AugmentationModule.h:36
ogdf::cluster_planarity::ClusterPQContainer::m_nonOpposed
NodeArray< SListPure< node > > * m_nonOpposed
Definition: ClusterPQContainer.h:71
ogdf::cluster_planarity::ClusterPQContainer::m_stEdgeLeaf
InfoLeafPtr m_stEdgeLeaf
Definition: ClusterPQContainer.h:91
ogdf::cluster_planarity::ClusterPQContainer
Definition: ClusterPQContainer.h:48
ogdf::CconnectClusterPlanarEmbed
C-planarity test and embedding by Cohen, Feng and Eades.
Definition: CconnectClusterPlanarEmbed.h:46
ogdf::cluster_planarity::ClusterPQContainer::m_subGraph
Graph * m_subGraph
Definition: ClusterPQContainer.h:87
ogdf::cluster_planarity::ClusterPQContainer::m_superSink
node m_superSink
Definition: ClusterPQContainer.h:82
ogdf::cluster_planarity::ClusterPQContainer::m_frontier
NodeArray< SListPure< edge > > * m_frontier
Definition: ClusterPQContainer.h:63
ogdf::cluster_planarity::ClusterPQContainer::~ClusterPQContainer
~ClusterPQContainer()
Definition: ClusterPQContainer.h:108
ogdf::cluster_planarity::ClusterPQContainer::m_T
booth_lueker::EmbedPQTree * m_T
Definition: ClusterPQContainer.h:89
ogdf::cluster_planarity::ClusterPQContainer::m_opposed
NodeArray< SListPure< node > > * m_opposed
Definition: ClusterPQContainer.h:67
ogdf::cluster_planarity::ClusterPQContainer::ClusterPQContainer
ClusterPQContainer()
Definition: ClusterPQContainer.h:94
ogdf::cluster_planarity::ClusterPQContainer::Cleanup
void Cleanup()
Definition: ClusterPQContainer.h:129
ogdf::Graph::nodes
internal::GraphObjectContainer< NodeElement > nodes
The container containing all node objects.
Definition: Graph_d.h:924
ogdf::Array< node >
EdgeArray.h
Declaration and implementation of EdgeArray class.
ogdf::cluster_planarity::ClusterPQContainer::m_edge2Key
EdgeArray< InfoLeafPtr > * m_edge2Key
Definition: ClusterPQContainer.h:74
ogdf::booth_lueker::EmbedPQTree
Definition: EmbedPQTree.h:43
ogdf::internal::GraphRegisteredArray
RegisteredArray for nodes, edges and adjEntries of a graph.
Definition: Graph_d.h:651
ogdf::Graph
Data type for general directed graphs (adjacency list representation).
Definition: Graph_d.h:862
ogdf::cluster_planarity::ClusterPQContainer::m_tableNumber2Node
Array< node > * m_tableNumber2Node
Definition: ClusterPQContainer.h:80
ogdf::cluster_planarity::ClusterPQContainer::m_outLeaves
NodeArray< SListPure< InfoLeafPtr > > * m_outLeaves
Definition: ClusterPQContainer.h:59
NodeArray.h
Declaration and implementation of NodeArray class.
ogdf::cluster_planarity::ClusterPQContainer::m_numbering
NodeArray< int > * m_numbering
Definition: ClusterPQContainer.h:77
ogdf::booth_lueker::EmbedPQTree::emptyAllPertinentNodes
virtual void emptyAllPertinentNodes() override
Cleans up all flags that have been set in the pertinent nodes during the reduction process.
ogdf::cluster_planarity::ClusterPQContainer::m_inLeaves
NodeArray< SListPure< InfoLeafPtr > > * m_inLeaves
Definition: ClusterPQContainer.h:56
EmbedPQTree.h
Declaration of the class EmbedPQTree.
ogdf::booth_lueker::PlanarLeafKey
Definition: PlanarLeafKey.h:41
ogdf::NodeElement
Class for the representation of nodes.
Definition: Graph_d.h:233
ogdf::cluster_planarity::ClusterPQContainer::init
void init(Graph *subGraph)
Definition: ClusterPQContainer.h:110
ogdf::internal::EdgeArrayBase2
RegisteredArray for edges of a graph, specialized for EdgeArray<edge>.
Definition: Graph_d.h:709