Open
Graph Drawing
Framework

 v. 2020.02 (Catalpa)
 

UpwardPlanaritySingleSource.h
Go to the documentation of this file.
1 
34 #pragma once
35 
37 #include <ogdf/basic/NodeArray.h>
38 #include <ogdf/basic/SList.h>
43 
44 namespace ogdf {
45 
48 {
49 public:
50 
51  // test and compute adjacency lists of embedding
52  static bool testAndFindEmbedding(
53  const Graph &G,
54  bool embed,
55  NodeArray<SListPure<adjEntry> > &adjacentEdges);
56 
57  // embed and compute st-augmentation (new implementation - inserts only
58  // one new node into G which is the super sink)
59  static void embedAndAugment(
60  Graph &G,
61  NodeArray<SListPure<adjEntry> > &adjacentEdges,
62  bool augment,
63  node &superSink,
64  SList<edge> &augmentedEdges);
65 
66 private:
67 
68  struct DegreeInfo {
73  };
74 
75  // classes defined and used in UpwardPlanaritySingleSource.cpp
76  class OGDF_EXPORT SkeletonInfo;
77 
79  class ConstraintRooting;
80 
81 
82  // performs the actual test (and computation of sorted adjacency lists) for
83  // each biconnected component
84  static bool testBiconnectedComponent(
85  ExpansionGraph &exp,
86  node sG,
87  int parentBlock,
88  bool embed,
89  NodeArray<SListPure<adjEntry> > &adjacentEdges);
90 
93 
94  // compute sT-skeletons
95  // test for upward-planarity, build constraints for rooting, and find a
96  // rooting of the tree satisfying all constraints
97  // returns true iff such a rooting exists
98  static edge directSkeletons(
99  SPQRTree &T,
100  NodeArray<SkeletonInfo> &skInfo);
101 
102  // precompute information: in-/outdegrees in pertinent graph, contains
103  // pertinent graph the source?
104  static void computeDegreesInPertinent(
105  const SPQRTree &T,
106  node s,
107  NodeArray<SkeletonInfo> &skInfo,
108  node vT);
109 
113 
114  static bool initFaceSinkGraph(const Graph &M, SkeletonInfo &skInfo);
115 
116  static void embedSkeleton(
117  Graph &G,
119  NodeArray<SkeletonInfo> &skInfo,
120  node vT,
121  bool extFaceIsLeft);
122 
126 
127  static void assignSinks(
128  FaceSinkGraph &F,
129  face extFace,
130  NodeArray<face> &assignedFace);
131 
132  static node dfsAssignSinks(
133  FaceSinkGraph &F,
134  node v, // current node
135  node parent, // its parent
136  NodeArray<face> &assignedFace);
137 
141 
142  static bool checkDegrees(
143  SPQRTree &T,
144  node s,
145  NodeArray<SkeletonInfo> &skInfo);
146 
147  static bool virtualEdgesDirectedEqually(const SPQRTree &T);
148 
150 };
151 
152 }
Declaration of singly linked lists and iterators.
Data type for general directed graphs (adjacency list representation).
Definition: Graph_d.h:492
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:99
Represents expansion graph of each biconnected component of a given digraph, i.e., each vertex v with in- and outdegree greater than 1 is expanded into two vertices x and y connected by an edge x->y such that all incoming edges are moved from v to x and all outgoing edges from v to y.
Singly linked lists.
Definition: SList.h:38
Declaration of class FaceSinkGraph.
Declaration of CombinatorialEmbedding and face.
Singly linked lists (maintaining the length of the list).
Definition: SList.h:773
Declaration of class StaticPlanarSPQRTree.
Performs upward planarity testing and embedding for single-source digraphs.
Dynamic arrays indexed with nodes.
Definition: Graph_d.h:438
Declares class ExpansionGraph...
Faces in a combinatorial embedding.
Class for the representation of edges.
Definition: Graph_d.h:292
Class for the representation of nodes.
Definition: Graph_d.h:169
Declaration of class SPQRTree.
Declaration and implementation of NodeArray class.
Linear-time implementation of static SPQR-trees.
Definition: SPQRTree.h:71
The namespace for all OGDF objects.
SPQR-trees of planar graphs.