bpp-core3
3.0.0
|
A uniform random number generator. More...
#include <Bpp/Numeric/Random/Uniform01WH.h>
Public Member Functions | |
Uniform01WH (long seed) | |
Create a Random Number Generator. More... | |
virtual | ~Uniform01WH () |
Destroy the generator. More... | |
void | setSeed (long seed) |
Set the seed for a new set of random numbers. More... | |
void | setSeeds (long seed1, long seed2=20356, long seed3=35412) |
Set the three seeds. More... | |
double | drawNumber () const |
Get a random number between 0.0 and 1.0 (exclusive of the end point values). More... | |
Private Attributes | |
long | ix |
long | iy |
long | iz |
A uniform random number generator.
This is a congruential uniform generator which draw double between 0 and 1 excluding the end points. This generator is based on a Fortan routine from Wichmann, B. A. and Hill, I. D. (1982). "An efficient and portable pseudorandom number generator," Applied Statistics, 31, 188-190
Definition at line 57 of file Uniform01WH.h.
|
inline |
Create a Random Number Generator.
seed | The seed for the random numbers. |
Definition at line 66 of file Uniform01WH.h.
|
virtual |
Destroy the generator.
|
virtual |
Get a random number between 0.0 and 1.0 (exclusive of the end point values).
Implements bpp::RandomFactory.
Definition at line 50 of file Uniform01WH.cpp.
|
inlinevirtual |
Set the seed for a new set of random numbers.
Implements bpp::RandomFactory.
Definition at line 77 of file Uniform01WH.h.
References setSeeds().
|
inline |
|
mutableprivate |
Definition at line 93 of file Uniform01WH.h.
Referenced by setSeeds().
|
private |
Definition at line 93 of file Uniform01WH.h.
Referenced by setSeeds().
|
private |
Definition at line 93 of file Uniform01WH.h.
Referenced by setSeeds().