#include <planck_rng.h>
Public Member Functions | |
planck_rng (unsigned int x1=123456789, unsigned int y1=362436069, unsigned int z1=521288629, unsigned int w1=88675123) | |
void | seed (unsigned int x1=123456789, unsigned int y1=362436069, unsigned int z1=521288629, unsigned int w1=88675123) |
unsigned int | int_rand_uni () |
double | rand_uni () |
double | rand_gauss () |
double | rand_exp () |
Definition at line 45 of file planck_rng.h.
planck_rng::planck_rng | ( | unsigned int | x1 = 123456789 , |
|
unsigned int | y1 = 362436069 , |
|||
unsigned int | z1 = 521288629 , |
|||
unsigned int | w1 = 88675123 | |||
) | [inline] |
Initializes the generator with 0 to 4 seed values.
Definition at line 80 of file planck_rng.h.
void planck_rng::seed | ( | unsigned int | x1 = 123456789 , |
|
unsigned int | y1 = 362436069 , |
|||
unsigned int | z1 = 521288629 , |
|||
unsigned int | w1 = 88675123 | |||
) | [inline] |
Re-initializes the generator with 0 to 4 seed values.
Definition at line 90 of file planck_rng.h.
unsigned int planck_rng::int_rand_uni | ( | ) | [inline] |
Returns uniformly distributed random integer numbers from the interval [0;0xFFFFFFFF].
Definition at line 100 of file planck_rng.h.
double planck_rng::rand_uni | ( | ) | [inline] |
Returns uniformly distributed random numbers from the interval [0;1[.
Definition at line 111 of file planck_rng.h.
double planck_rng::rand_gauss | ( | ) | [inline] |
Returns random numbers with Gaussian distribution (mean=0, sigma=1).
Uses rand_uni() internally.
Definition at line 118 of file planck_rng.h.
double planck_rng::rand_exp | ( | ) | [inline] |
Returns exponentially distributed random numbers (mean=1, nonnegative).
Uses rand_uni() internally.
Definition at line 145 of file planck_rng.h.