Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
FruchtermanReingold.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>
36#include <ogdf/basic/geometry.h>
37
39class NodeAttributes;
40} // namespace ogdf::energybased::fmmm
41
42namespace ogdf {
43namespace energybased {
44namespace fmmm {
45
47public:
50
53 NodeArray<DPoint>& F_rep);
54
57 NodeArray<DPoint>& F_rep);
58
60 void make_initialisations(double boxlength, DPoint down_left_corner, int grid_quotient);
61
64 boxlength = b_l;
65 down_left_corner = d_l_c;
66 }
67
68private:
71 double boxlength;
73
76 void grid_quotient(int p) { _grid_quotient = ((0 <= p) ? p : 2); }
77
78 int grid_quotient() const { return _grid_quotient; }
79};
80
81}
82}
83}
Includes declaration of graph class.
Declaration of classes GenericPoint, GenericPolyline, GenericLine, GenericSegment,...
Basic declarations, included by all source files.
Data type for general directed graphs (adjacency list representation).
Definition Graph_d.h:866
int max_gridindex
maximum index of a grid row/column
DPoint down_left_corner
down left corner of drawing box
int _grid_quotient
for coarsening the FrRe-grid
void update_boxlength_and_cornercoordinate(double b_l, DPoint d_l_c)
Import updated information of the drawing area.
void calculate_approx_repulsive_forces(const Graph &G, NodeArray< NodeAttributes > &A, NodeArray< DPoint > &F_rep)
Grid approximation of rep.forces for each node.
void make_initialisations(double boxlength, DPoint down_left_corner, int grid_quotient)
Make all initialisations that are needed for FruchtermanReingold.
void grid_quotient(int p)
The number k of rows and colums of the grid is sqrt(|V|) / frGridQuotient() (Note that in [FrRe] frGr...
void calculate_exact_repulsive_forces(const Graph &G, NodeArray< NodeAttributes > &A, NodeArray< DPoint > &F_rep)
Calculate exact rep. forces for each node.
RegisteredArray for nodes, edges and adjEntries of a graph.
Definition Graph_d.h:659
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF dynamic library (shared object / DLL),...
Definition config.h:117
The namespace for all OGDF objects.