Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

CliqueFinderHeuristic.h
Go to the documentation of this file.
1 
32 #pragma once
33 
36 
37 namespace ogdf {
38 
40 
48 public:
50  explicit CliqueFinderHeuristic();
51 
57  inline void setPostProcessing(bool postProcess) { m_postProcess = postProcess; }
58 
68  void setDensity(double density) {
69  if (density < 0.0) {
70  m_density = 0.0;
71  } else if (density > 1.0) {
72  m_density = 1.0;
73  } else {
74  m_density = density;
75  }
76  }
77 
78 protected:
80  void doCall() override;
81 
86  void preProcess();
87 
95  void postProcessCliques(List<List<node>*>& cliqueList);
96 
108  bool allAdjacent(node v, List<node>* vList) const;
109 
117  int evaluate(node v);
118 
128  void findClique(node v, List<node>& neighbours);
129 
130 private:
131  double m_density;
132 
134 
136 
138 };
139 
140 }
ogdf
The namespace for all OGDF objects.
Definition: AugmentationModule.h:36
AdjacencyOracle.h
Declaration of ogdf::AdjacencyOracle class.
ogdf::CliqueFinderHeuristic::setPostProcessing
void setPostProcessing(bool postProcess)
Sets whether postprocessing should be activated.
Definition: CliqueFinderHeuristic.h:57
ogdf::CliqueFinderHeuristic::m_adjOracle
AdjacencyOracle * m_adjOracle
Adjacency oracle for m_pCopy.
Definition: CliqueFinderHeuristic.h:135
CliqueFinderModule.h
Declares ogdf::CliqueFinderModule class.
ogdf::CliqueFinderHeuristic::m_usedNode
NodeArray< bool > m_usedNode
Whether the node is already assigned to a clique.
Definition: CliqueFinderHeuristic.h:137
ogdf::List
Doubly linked lists (maintaining the length of the list).
Definition: List.h:42
ogdf::internal::GraphRegisteredArray
RegisteredArray for nodes, edges and adjEntries of a graph.
Definition: Graph_d.h:651
ogdf::CliqueFinderHeuristic::setDensity
void setDensity(double density)
Sets the density needed for subgraphs to be detected.
Definition: CliqueFinderHeuristic.h:68
ogdf::CliqueFinderHeuristic::m_postProcess
bool m_postProcess
Whether postprocessing should be activated.
Definition: CliqueFinderHeuristic.h:133
ogdf::CliqueFinderModule
Finds cliques.
Definition: CliqueFinderModule.h:46
OGDF_EXPORT
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:101
ogdf::CliqueFinderHeuristic::m_density
double m_density
Value in [0,1] defining how dense subgraphs need to be.
Definition: CliqueFinderHeuristic.h:131
ogdf::CliqueFinderHeuristic
Finds cliques and dense subgraphs using a heuristic.
Definition: CliqueFinderHeuristic.h:47
ogdf::AdjacencyOracle
Tells you in constant time if two nodes are adjacent.
Definition: AdjacencyOracle.h:45
ogdf::NodeElement
Class for the representation of nodes.
Definition: Graph_d.h:233