Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

FruchtermanReingold.h
Go to the documentation of this file.
1 
32 #pragma once
33 
34 #include <ogdf/basic/Graph.h>
35 #include <ogdf/basic/NodeArray.h>
36 #include <ogdf/basic/geometry.h>
39 
40 namespace ogdf {
41 namespace energybased {
42 namespace fmmm {
43 
45 public:
48 
50  void calculate_exact_repulsive_forces(const Graph& G, NodeArray<NodeAttributes>& A,
51  NodeArray<DPoint>& F_rep);
52 
54  void calculate_approx_repulsive_forces(const Graph& G, NodeArray<NodeAttributes>& A,
55  NodeArray<DPoint>& F_rep);
56 
58  void make_initialisations(double boxlength, DPoint down_left_corner, int grid_quotient);
59 
62  boxlength = b_l;
63  down_left_corner = d_l_c;
64  }
65 
66 private:
69  double boxlength;
71 
74  void grid_quotient(int p) { _grid_quotient = ((0 <= p) ? p : 2); }
75 
76  int grid_quotient() const { return _grid_quotient; }
77 };
78 
79 }
80 }
81 }
ogdf
The namespace for all OGDF objects.
Definition: AugmentationModule.h:36
Graph.h
Includes declaration of graph class.
ogdf::GenericPoint< double >
geometry.h
Declaration of classes GenericPoint, GenericPolyline, GenericLine, GenericSegment,...
EdgeAttributes.h
Declaration of class EdgeAttributes.
ogdf::whaType::A
@ A
ogdf::energybased::fmmm::FruchtermanReingold::down_left_corner
DPoint down_left_corner
down left corner of drawing box
Definition: FruchtermanReingold.h:70
NodeAttributes.h
Declaration of class NodeAttributes.
ogdf::energybased::fmmm::FruchtermanReingold::max_gridindex
int max_gridindex
maximum index of a grid row/column
Definition: FruchtermanReingold.h:68
ogdf::energybased::fmmm::FruchtermanReingold
Definition: FruchtermanReingold.h:44
ogdf::energybased::fmmm::FruchtermanReingold::grid_quotient
void grid_quotient(int p)
The number k of rows and colums of the grid is sqrt(|V|) / frGridQuotient() (Note that in [FrRe] frGr...
Definition: FruchtermanReingold.h:74
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
NodeArray.h
Declaration and implementation of NodeArray class.
OGDF_EXPORT
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
Definition: config.h:101
ogdf::energybased::fmmm::FruchtermanReingold::update_boxlength_and_cornercoordinate
void update_boxlength_and_cornercoordinate(double b_l, DPoint d_l_c)
Import updated information of the drawing area.
Definition: FruchtermanReingold.h:61
ogdf::energybased::fmmm::FruchtermanReingold::boxlength
double boxlength
length of drawing box
Definition: FruchtermanReingold.h:69
ogdf::energybased::fmmm::FruchtermanReingold::_grid_quotient
int _grid_quotient
for coarsening the FrRe-grid
Definition: FruchtermanReingold.h:67
ogdf::energybased::fmmm::FruchtermanReingold::grid_quotient
int grid_quotient() const
Definition: FruchtermanReingold.h:76