79 return m_coolingFunction;
84 m_coolingFunction = f;
143 double log2(
double x) {
return log(x) / log(2.0); }
159 double f_att(
double d) {
return d*d / m_idealEdgeLength; }
160 double f_rep(
double d) {
return m_idealEdgeLength*m_idealEdgeLength / d; }
163 double f_att(
double d) {
return 5.0 * d *
log2(d/m_idealEdgeLength); }
164 double f_rep(
double d) {
return 20.0 / d; }
168 void cool(
double &tx,
double &ty,
int &cF);
Declaration of singly linked lists and iterators.
CoolingFunction coolingFunction() const
Returns the current setting for the cooling function.
bool noise() const
Returns the current setting of nodes.
Fruchterman-Reingold algorithm with (exact) layout.
void minDistCC(double x)
Sets the minimum distance between connected components to x.
Declaration of class GraphAttributes which extends a Graph by additional attributes.
The parameterized class Array implements dynamic arrays of type E.
Declaration of interface for energy-based layout algorithms (class ForceLayoutModule) ...
NodeArray< int > m_mapNode
void pageRatio(double x)
Sets the page ration to x.
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
double m_idealEdgeLength
The ideal edge length.
int numberOfEdges() const
bool m_noise
Perform random perturbations?
Singly linked lists (maintaining the length of the list).
double m_pageRatio
The page ratio.
int iterations() const
Returns the current setting of iterations.
node original(int v) const
double idealEdgeLength() const
Returns the ideal edge length.
void idealEdgeLength(double len)
Sets the ideal edge length to len.
Stores additional attributes of a graph (like layout information).
T log2(T x)
Returns the logarithm of x to the base 2.
int m_iterations
The number of iterations.
void iterations(int i)
Sets the number of iterations to i.
Class for the representation of nodes.
const SList< node > & nodesInCC(int i) const
double pageRatio()
Returns the page ratio.
void nodeWeights(bool on)
Switches use of node weights given in GraphAttributtes.
int numberOfNodes() const
void coolingFunction(CoolingFunction f)
Sets the parameter coolingFunction to f.
void noise(bool on)
Sets the parameter noise to on.
Interface of general layout algorithms.
The namespace for all OGDF objects.
void convTolerance(double tol)
Array< SList< node > > m_nodesInCC
void checkConvergence(bool b)
double minDistCC() const
Returns the minimum distance between connected components.
double m_minDistCC
The minimal distance between connected components.
#define OGDF_ASSERT(expr)
Assert condition expr. See doc/build.md for more information.
CoolingFunction m_coolingFunction
The selected cooling function.