Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

BoyerMyrvoldInit.h
Go to the documentation of this file.
1 
33 #pragma once
34 
35 #include <ogdf/basic/Array.h>
36 #include <ogdf/basic/Graph.h>
37 #include <ogdf/basic/List.h>
38 
39 #include <random>
40 
41 namespace ogdf {
42 class BoyerMyrvoldPlanar;
43 enum class BoyerMyrvoldEdgeType;
44 
45 namespace boyer_myrvold {
46 
48 
53 public:
55  explicit BoyerMyrvoldInit(BoyerMyrvoldPlanar* pBM);
56 
59 
61  void computeDFS();
62 
64  void computeLowPoints();
65 
67  void computeDFSChildLists();
68 
69  // avoid automatic creation of assignment operator
72 
73 private:
76 
78  const int& m_embeddingGrade;
79  const double& m_randomness;
81  std::minstd_rand m_rand;
82 
84 
87 
90 
93 
95 
97  NodeArray<adjEntry> (&m_link)[2];
98 
101 
103 
106 
109 
112 
115 
117 
120 
122 
125 
127  void createVirtualVertex(const adjEntry father);
128 };
129 
130 }
131 }
ogdf
The namespace for all OGDF objects.
Definition: multilevelmixer.cpp:39
Graph.h
Includes declaration of graph class.
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_rand
std::minstd_rand m_rand
Definition: BoyerMyrvoldInit.h:81
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_embeddingGrade
const int & m_embeddingGrade
Some parameters... see BoyerMyrvold.h for further instructions.
Definition: BoyerMyrvoldInit.h:78
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_leastAncestor
NodeArray< int > & m_leastAncestor
The DFI of the least ancestor node over all backedges.
Definition: BoyerMyrvoldInit.h:105
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_realVertex
NodeArray< node > & m_realVertex
Link to non-virtual vertex of a virtual Vertex.
Definition: BoyerMyrvoldInit.h:86
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_dfi
NodeArray< int > & m_dfi
The one and only DFI-Array.
Definition: BoyerMyrvoldInit.h:89
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_randomness
const double & m_randomness
Definition: BoyerMyrvoldInit.h:79
ogdf::boyer_myrvold::BoyerMyrvoldInit::computeDFSChildLists
void computeDFSChildLists()
Computes the list of separated DFS children for all nodes.
ogdf::boyer_myrvold::BoyerMyrvoldInit::BoyerMyrvoldInit
BoyerMyrvoldInit(BoyerMyrvoldPlanar *pBM)
Constructor, the parameter BoyerMyrvoldPlanar is needed.
ogdf::boyer_myrvold::BoyerMyrvoldInit::computeDFS
void computeDFS()
Creates the DFSTree.
ogdf::boyer_myrvold::BoyerMyrvoldInit::operator=
BoyerMyrvoldInit & operator=(const BoyerMyrvoldInit &)
Assignment operator is undefined!
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_separatedDFSChildList
NodeArray< ListPure< node > > & m_separatedDFSChildList
A list to all separated DFS-children of node.
Definition: BoyerMyrvoldInit.h:119
ogdf::AdjElement
Class for adjacency list elements.
Definition: Graph_d.h:142
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_pNodeInParent
NodeArray< ListIterator< node > > & m_pNodeInParent
Pointer to node contained in the DFSChildList of his parent, if exists.
Definition: BoyerMyrvoldInit.h:124
ogdf::Array< node >
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_nodeFromDFI
Array< node > & m_nodeFromDFI
Returns appropriate node from given DFI.
Definition: BoyerMyrvoldInit.h:92
ogdf::internal::GraphRegisteredArray
RegisteredArray for nodes, edges and adjEntries of a graph.
Definition: Graph_d.h:658
ogdf::Graph
Data type for general directed graphs (adjacency list representation).
Definition: Graph_d.h:869
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_edgeCosts
const EdgeArray< int > * m_edgeCosts
Definition: BoyerMyrvoldInit.h:80
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_lowPoint
NodeArray< int > & m_lowPoint
The lowpoint of each node.
Definition: BoyerMyrvoldInit.h:111
ogdf::boyer_myrvold::BoyerMyrvoldInit::createVirtualVertex
void createVirtualVertex(const adjEntry father)
Creates and links a virtual vertex of the node belonging to father.
Array.h
Declaration and implementation of Array class and Array algorithms.
ogdf::BoyerMyrvoldPlanar
This class implements the extended BoyerMyrvold planarity embedding algorithm.
Definition: BoyerMyrvoldPlanar.h:66
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_edgeType
EdgeArray< BoyerMyrvoldEdgeType > & m_edgeType
Contains the type of each edge.
Definition: BoyerMyrvoldInit.h:108
List.h
Declaration of doubly linked lists and iterators.
ogdf::BoyerMyrvoldEdgeType
BoyerMyrvoldEdgeType
Type of edge.
Definition: BoyerMyrvoldPlanar.h:49
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_g
Graph & m_g
The input graph.
Definition: BoyerMyrvoldInit.h:75
ogdf::boyer_myrvold::BoyerMyrvoldInit
This class is used in the Boyer-Myrvold planarity test for preprocessing purposes.
Definition: BoyerMyrvoldInit.h:52
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_highestSubtreeDFI
NodeArray< int > & m_highestSubtreeDFI
The highest DFI in a subtree with node as root.
Definition: BoyerMyrvoldInit.h:114
ogdf::boyer_myrvold::BoyerMyrvoldInit::~BoyerMyrvoldInit
~BoyerMyrvoldInit()
Destructor.
Definition: BoyerMyrvoldInit.h:58
ogdf::boyer_myrvold::BoyerMyrvoldInit::computeLowPoints
void computeLowPoints()
Computes lowpoint, highestSubtreeDFI and links virtual to nonvirtual vertices.
ogdf::internal::EdgeArrayBase2
RegisteredArray for edges of a graph, specialized for EdgeArray<edge>.
Definition: Graph_d.h:716
ogdf::boyer_myrvold::BoyerMyrvoldInit::m_adjParent
NodeArray< adjEntry > & m_adjParent
The adjEntry which goes from DFS-parent to current vertex.
Definition: BoyerMyrvoldInit.h:100