Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

SeparatorLiptonTarjanFC.h
Go to the documentation of this file.
1 
32 #pragma once
33 
34 #include <ogdf/basic/Graph.h>
35 #include <ogdf/basic/basic.h>
37 
38 #include <memory>
39 #include <string>
40 
41 namespace ogdf {
42 class GraphCopy;
43 template<class E>
44 class List;
45 template<class E>
46 class SListPure;
47 
48 namespace planar_separators {
49 
54 public:
61  BFSTreeFC(GraphCopy& G, node rootNode) : ArrayBFSTree(G, rootNode) { construct(); }
62 
63  void construct();
64 };
65 
71 public:
78  TriangulatingBFSTree(GraphCopy& G, node rootNode) : ArrayBFSTree(G, rootNode) { construct(); }
79 
80  void construct();
81 
82  void visit(node v, node parent, adjEntry adj, SListPure<node>& bfs);
83 };
84 
85 }
86 
88 
95 public:
101  SeparatorLiptonTarjanFC(bool useTriBFS = false) : useTriangulatingBFS {useTriBFS} { }
102 
103  virtual double getMaxSeparatorSize(int n) const override { return -1; }
104 
105 protected:
106  virtual bool doSeparate(const Graph& G, List<node>& separator, List<node>& first,
107  List<node>& second) override;
108 
110  std::shared_ptr<ArrayBFSTree> tree;
111 
112  virtual std::string getSpecificName() const override {
113  std::string name = "LTFC";
114  if (useTriangulatingBFS) {
115  name += "-triBFS";
116  }
117  return name;
118  }
119 
128  virtual bool findCycle(List<node>& separator, List<node>& first, List<node>& second);
129 
135  edge chooseEdge() const;
136 };
137 
138 }
ogdf
The namespace for all OGDF objects.
Definition: multilevelmixer.cpp:39
Graph.h
Includes declaration of graph class.
ogdf::SeparatorLiptonTarjanFC::getMaxSeparatorSize
virtual double getMaxSeparatorSize(int n) const override
Provides the maximal separator size that this algorithm guarantees as a function of the number of nod...
Definition: SeparatorLiptonTarjanFC.h:103
ogdf::SeparatorLiptonTarjanFC::useTriangulatingBFS
bool useTriangulatingBFS
Definition: SeparatorLiptonTarjanFC.h:109
ogdf::SeparatorLiptonTarjanFC::getSpecificName
virtual std::string getSpecificName() const override
Returns the unique name of the core algorithm, to be combined with postprocessors later.
Definition: SeparatorLiptonTarjanFC.h:112
ogdf::planar_separators::ArrayBFSTree
Abstract BFSTree that is realized via NodeArrays.
Definition: PlanarSeparatorModule.h:132
ogdf::GraphCopy
Copies of graphs supporting edge splitting.
Definition: GraphCopy.h:391
ogdf::SeparatorLiptonTarjanFC::SeparatorLiptonTarjanFC
SeparatorLiptonTarjanFC(bool useTriBFS=false)
Constructor.
Definition: SeparatorLiptonTarjanFC.h:101
ogdf::AdjElement
Class for adjacency list elements.
Definition: Graph_d.h:142
ogdf::planar_separators::BFSTreeFC
Custom BFS Tree.
Definition: SeparatorLiptonTarjanFC.h:53
ogdf::PlanarSeparatorModule
Abstract description of all planar separator algorithms.
Definition: PlanarSeparatorModule.h:925
ogdf::SListPure
Singly linked lists.
Definition: SList.h:52
ogdf::planar_separators::TriangulatingBFSTree
Triangulating BFS tree that operates on a non-triangulated graph and constructs the triangulation tog...
Definition: SeparatorLiptonTarjanFC.h:70
ogdf::planar_separators::TriangulatingBFSTree::TriangulatingBFSTree
TriangulatingBFSTree(GraphCopy &G, node rootNode)
Constructor.
Definition: SeparatorLiptonTarjanFC.h:78
ogdf::List
Doubly linked lists (maintaining the length of the list).
Definition: DfsMakeBiconnected.h:40
ogdf::Graph
Data type for general directed graphs (adjacency list representation).
Definition: Graph_d.h:869
ogdf::planar_separators::BFSTreeFC::BFSTreeFC
BFSTreeFC(GraphCopy &G, node rootNode)
Constructor.
Definition: SeparatorLiptonTarjanFC.h:61
basic.h
Basic declarations, included by all source files.
OGDF_EXPORT
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:101
ogdf::EdgeElement
Class for the representation of edges.
Definition: Graph_d.h:363
ogdf::SeparatorLiptonTarjanFC
Computes planar separators using Fundamental Cycles.
Definition: SeparatorLiptonTarjanFC.h:94
ogdf::SeparatorLiptonTarjanFC::tree
std::shared_ptr< ArrayBFSTree > tree
Definition: SeparatorLiptonTarjanFC.h:110
ogdf::NodeElement
Class for the representation of nodes.
Definition: Graph_d.h:240
PlanarSeparatorModule.h
Declaration of base class of all planar separator algorithms.