The basic RNG for NS-3.Note: The underlying random number generation method used by NS-3 is the RngStream code by Pierre L'Ecuyer at the University of Montreal. More...
#include <random-variable.h>
Public Member Functions | |
double | GetValue (void) const |
Returns a random double from the underlying distribution. | |
uint32_t | GetInteger (void) const |
Returns a random integer integer from the underlying distribution. |
The basic RNG for NS-3.
Note: The underlying random number generation method used by NS-3 is the RngStream code by Pierre L'Ecuyer at the University of Montreal.
NS-3 has a rich set of random number generators. Class RandomVariable defines the base class functionalty required for all random number generators. By default, the underlying generator is seeded with the time of day, and then deterministically creates a sequence of seeds for each subsequent generator that is created. The rest of the documentation outlines how to change this behavior.
uint32_t ns3::RandomVariable::GetInteger | ( | void | ) | const |
Returns a random integer integer from the underlying distribution.
double ns3::RandomVariable::GetValue | ( | void | ) | const |
Returns a random double from the underlying distribution.
Reimplemented in ns3::UniformVariable.