Provides random number generators. More...
Functions | |
| double | ogdf::randomDouble (double low, double high) |
Returns a random double value from the interval [low, high). | |
| double | ogdf::randomDoubleExponential (double beta) |
| Returns a random double value from the exponential distribution. | |
| double | ogdf::randomDoubleNormal (double m, double sd) |
| Returns a random double value from the normal distribution with mean m and standard deviation sd. | |
| int | ogdf::randomNumber (int low, int high) |
| Returns random integer between low and high (including). | |
| long unsigned int | ogdf::randomSeed () |
| Returns a random value suitable as initial seed for a random number engine. | |
| void | ogdf::setSeed (int val) |
| Sets the seed for functions like randomSeed(), randomNumber(), randomDouble(). | |
Provides random number generators.
| double ogdf::randomDouble | ( | double | low, |
| double | high | ||
| ) |
Returns a random double value from the interval [low, high).
This functions is thread-safe.
| double ogdf::randomDoubleExponential | ( | double | beta | ) |
Returns a random double value from the exponential distribution.
This functions is thread-safe.
|
inline |
| int ogdf::randomNumber | ( | int | low, |
| int | high | ||
| ) |
Returns random integer between low and high (including).
This functions is thread-safe.
| long unsigned int ogdf::randomSeed | ( | ) |
Returns a random value suitable as initial seed for a random number engine.
This functions is thread-safe.
| void ogdf::setSeed | ( | int | val | ) |
Sets the seed for functions like randomSeed(), randomNumber(), randomDouble().