#include <Random.h>
Inheritance diagram for RandomNumberGenerator< RNG >:

Public Types | |
| typedef Ref< _State > | State |
| typedef unsigned long int | SeedType |
Public Methods | |
| virtual void | setSeed (SeedType seed) |
| Reseed the random number generator. | |
| virtual State | getState () const |
| Save the current state of the generator. | |
| virtual void | setState (State const &) |
| Restore the generator to a specific state saved with getState(). | |
| virtual double | unit () |
| Return a random floating point value in the range [0,1). | |
| virtual double | uniform (double, double) |
| Return a random floating point value in the range [lower,upper). | |
| virtual long | uniformInt (long lower, long upper) |
| Return a random integer in the range lower to upper-1 (inclusive). | |
| virtual long | uniformInt (long upper) |
| Equivalent to uniformInt(0, upper). | |
| virtual unsigned long | uniformUInt (unsigned long lower, unsigned long upper) |
| Return a random integer in the range lower to upper-1 (inclusive). | |
| virtual unsigned long | uniformUInt (unsigned long upper) |
| Equivalent to uniformUInt(0, upper). | |
| virtual std::string | getName () const |
| Get the name of this generator. | |
| RNG * | operator-> () |
| Direct access to the underlying generator. | |
| virtual void | setSeed (SeedType seed)=0 |
| Set the generator seed. | |
| virtual void | setState (State const &state)=0 |
| Set the generator state. | |
Random number generator wrapper, implementing the random number generator interface. These generics provide a uniform interface to the underlying generators and generator state data. The performance penalty relative to using the raw generators is typically about 20%.
|
|
|
|
|
|
|
|||||||||
|
Get the name of this generator.
Implements RandomInterface. |
|
|||||||||
|
Save the current state of the generator. The state can be restored at any time with setState(). Implements RandomInterface. |
|
|||||||||
|
Direct access to the underlying generator. Using the generator directly provides slightly faster access and generator-specific methods. |
|
|
Set the generator seed.
Implemented in RandomNumberGenerator< rng::Taus2 >. |
|
||||||||||
|
Reseed the random number generator.
|
|
|
Set the generator state.
Implemented in RandomNumberGenerator< rng::Taus2 >. |
|
||||||||||
|
Restore the generator to a specific state saved with getState(). The subsequent random numbers will be identical to the sequence following the corresponding getState() call. |
|
||||||||||||||||
|
Return a random floating point value in the range [lower,upper).
Implements RandomNumberGeneratorInterface. |
|
||||||||||
|
Equivalent to uniformInt(0, upper).
Implements RandomNumberGeneratorInterface. |
|
||||||||||||||||
|
Return a random integer in the range lower to upper-1 (inclusive).
Implements RandomNumberGeneratorInterface. |
|
||||||||||
|
Equivalent to uniformUInt(0, upper).
Implements RandomNumberGeneratorInterface. |
|
||||||||||||||||
|
Return a random integer in the range lower to upper-1 (inclusive).
Implements RandomNumberGeneratorInterface. |
|
|||||||||
|
Return a random floating point value in the range [0,1).
Implements RandomNumberGeneratorInterface. |
|
SimData version pre-0.4.0. For more information on SimData, visit the SimData Homepage. Generated on Tue Oct 14 12:06:42 2003, using Doxygen 1.2.18. |