44 namespace energybased {
54 void calculate_repulsive_forces(
const Graph &G,
59 void make_initialisations (
const Graph &G,
62 int particles_in_leaves,
68 void deallocate_memory();
71 void update_boxlength_and_cornercoordinate(
double b_l,
DPoint d_l_c);
101 int power_of_two(
int i);
104 int maxboxindex (
int level);
112 void calculate_repulsive_forces_by_exact_method(
const Graph &G,
120 void build_up_red_quad_tree_path_by_path(
const Graph& G,
157 bool in_lt_quad(
QuadTreeNodeNM* act_ptr,
double x_min,
double x_max,
double y_min,
double y_max);
158 bool in_rt_quad(
QuadTreeNodeNM* act_ptr,
double x_min,
double x_max,
double y_min,
double y_max);
159 bool in_lb_quad(
QuadTreeNodeNM* act_ptr,
double x_min,
double x_max,
double y_min,
double y_max);
160 bool in_rb_quad(
QuadTreeNodeNM* act_ptr,
double x_min,
double x_max,
double y_min,
double y_max);
161 bool quadHelper(
double x_min,
double x_max,
double y_min,
double y_max,
double l,
double r,
double b,
double t,
QuadTreeNodeNM* act_ptr);
168 void split_in_x_direction(
177 void split_in_y_direction(
190 void x_delete_right_subLists(
199 void x_delete_left_subLists(
210 void y_delete_right_subLists(
219 void y_delete_left_subLists(
230 void split_in_y_direction(
271 void build_up_red_quad_tree_subtree_by_subtree(
const Graph& G,
294 void construct_complete_subtree(
QuadTreeNM& T,
312 void set_particlenumber_in_subtree_entries(
QuadTreeNM& T);
331 bool check_and_delete_degenerated_node(
QuadTreeNM& T);
373 double x_min,
double x_max,
374 double y_min,
double y_max) {
375 switch (find_sm_cell()) {
377 find_small_cell_iteratively(act_ptr, x_min, x_max, y_min, y_max);
380 find_small_cell_by_formula(act_ptr, x_min, x_max, y_min, y_max);
386 void delete_red_quad_tree_and_count_treenodes(
QuadTreeNM& T);
412 void add_shifted_expansion_to_father_expansion(
QuadTreeNodeNM* act_ptr);
461 void add_rep_forces(
const Graph& G,
468 double f_rep_scalar (
double d);
471 void init_binko(
int t);
477 double binko(
int n,
int k);
483 _tree_construction_way = rtc;
491 _find_small_cell = scf;
499 void precision (
int p) { _precision = ((p >= 1 ) ? p : 1); }
FruchtermanReingold ExactMethod
needed in case that using_NMM == false
FMMMOptions::SmallestCellFinding find_sm_cell() const
Returns the way the smallest quadratic cell that surrounds the particles of a node in the reduced buc...
void find_small_cell(QuadTreeNodeNM *act_ptr, double x_min, double x_max, double y_min, double y_max)
Finds the small cell of the actual node using the selected algorithm.
helping data structure that stores the graphical attributes of a node that are needed for the force-d...
Data type for general directed graphs (adjacency list representation).
#define OGDF_EXPORT
Specifies that a function or class is exported by the OGDF DLL.
double ** BK
holds the binomial coefficients
ReducedTreeConstruction
Specifies how the reduced bucket quadtree is constructed.
FMMMOptions::ReducedTreeConstruction _tree_construction_way
int particles_in_leaves() const
int _precision
precision for p-term multipole expansion
bool using_NMM
Indicates whether the exact method or NMM is used for force calculation (value depends on MIN_NODE_NU...
Helping data structure that stores the information needed to represent a node of the reduced quad tre...
Dynamic arrays indexed with nodes.
According to formula by Aluru et al.
Declaration of Fast Multipole Multilevel Method (FM^3) options.
List< DPoint > rep_forces
stores the rep. forces of the last iteration needed for error calculation)
Helping data structure that stores the information needed to represent the modified quadtree in the N...
FMMMOptions::SmallestCellFinding _find_small_cell
The parameterized class Array2D implements dynamic two-dimensional arrays.
Encapsulates a pointer to a list element.
~NewMultipoleMethod()
destructor
double boxlength
length of drawing box
void find_sm_cell(FMMMOptions::SmallestCellFinding scf)
void particles_in_leaves(int b)
Max. number of particles that are contained in a leaf of the red. quadtree.
Includes declaration of graph class.
const int max_power_of_2_index
holds max.
Declaration of class FruchtermanReingold (computation of forces).
void precision(int p)
The precision p for the p-term multipole expansions.
FMMMOptions::ReducedTreeConstruction tree_construction_way() const
Returns the way to construct the reduced tree.
Iteratively (in constant time).
DPoint down_left_corner
down left corner of drawing box
Declaration of class QuadTreeNM.
The namespace for all OGDF objects.
Declaration of classes DPoint, DPolyline, DLine, DRect, DIntersectableRect, DScaler.
int _particles_in_leaves
max.
SmallestCellFinding
Specifies how to calculate the smallest quadratic cell that surrounds the particles of a node in the ...
int MIN_NODE_NUMBER
The minimum number of nodes for which the forces are calculated using NMM (for lower values the exact...
void tree_construction_way(FMMMOptions::ReducedTreeConstruction rtc)
Declaration of doubly linked lists and iterators.
Declaration and implementation of class Array2D which implements dynamic two dimensional arrays...