Go to the documentation of this file. 1 #ifndef GRAPH_ANALYSIS_PERCOLATION_STRATEGIES_RANDOM_DRAW_HPP
2 #define GRAPH_ANALYSIS_PERCOLATION_STRATEGIES_RANDOM_DRAW_HPP
6 #include "../../GraphElement.hpp"
10 class RandomNumberGenerator;
12 namespace strategies {
24 std::map<GraphElementId, double> mProbabilityDensity;
29 mutable double mProbabilityDensitySum;
75 #endif // GRAPH_ANALYSIS_PERCOLATION_STRATEGIES_RANDOM_DRAW_HPP
double getProbability(GraphElementId id) const
Definition: RandomDraw.cpp:46
void setProbabilityDensity(GraphElementId id, double density)
Definition: RandomDraw.cpp:24
Main namespace of the graph analysis library.
Definition: BFS.cpp:3
Randomly draws items from a given set, based on given probability densities. Uses RandomNumberGenerat...
Definition: RandomDraw.hpp:21
~RandomDraw()
Definition: RandomDraw.cpp:19
Definition: RandomNumberGenerator.hpp:14
RandomDraw(uint32_t seed=0)
Definition: RandomDraw.cpp:12
Percolation deals with a changing graph, i.e., nodes and edges that disappear from the graph.
double getProbabilityDensitySum() const
Definition: RandomDraw.cpp:30
void removeItem(GraphElementId id)
Definition: RandomDraw.cpp:68
uint32_t GraphElementId
Definition: GraphElement.hpp:21
GraphElementId drawItem() const
Definition: RandomDraw.cpp:83