|
CAEN Utility
2.0.2
Utilities for CAEN projects
|
Pseudo-random number generator implemented on MT19937. More...
#include <CAENRandom.h>#include <math.h>#include <inttypes.h>#include <CAENLogger.h>#include <CAENMultiplatform.h>Go to the source code of this file.
Data Structures | |
| struct | _initializedstuff |
| struct | _librarystate |
| struct | _statevector |
| struct | _integer |
| struct | _internalstate |
Functions | |
| int32_t | c_rand32_init (void) |
| void | c_rand32_deinit (void) |
| int32_t | c_rand64_init (void) |
| void | c_rand64_deinit (void) |
| void | c_rand32_seed (uint32_t seed) |
| void | c_rand64_seed (uint64_t seed) |
| static void | _twist32 (void) |
| static void | _twist64 (void) |
| uint32_t | c_rand32_int (void) |
| uint64_t | c_rand64_int (void) |
| double | c_rand (void) |
| double | c_rand64 (void) |
| double | c_rand64_normal (void) |
Variables | |
| static const c_locallogger_t | __locallogger = { ( "CAENRandomLog.txt" ), ( "CAENRandom.c" ) } |
| static struct _librarystate | lState |
| Library state. More... | |
| static struct _internalstate | iState |
| Internal state. More... | |
| static const struct _integer | kW |
| The number of bits of each word in the state sequence. More... | |
| static const struct _integer | kM |
| The shift size used on twists to transform the values. More... | |
| static const struct _integer | kN |
| The number of elements in the state sequence (degree of recurrence). More... | |
| static const struct _integer | kA |
| The XOR mask applied as the linear function on each twist. More... | |
| static const struct _integer | kB |
The XOR mask used as parameter b in the tempering process of the generation algorithm. More... | |
| static const struct _integer | kC |
The XOR mask used as parameter c in the tempering process of the generation algorithm. More... | |
| static const struct _integer | kD |
The XOR mask used as parameter d in the tempering process of the generation algorithm. More... | |
| static const struct _integer | kS |
The shift size of parameter s used in the tempering process of the generation algorithm. More... | |
| static const struct _integer | kT |
The shift size of parameter t used in the tempering process of the generation algorithm. More... | |
| static const struct _integer | kU |
The shift size of parameter u used in the tempering process of the generation algorithm. More... | |
| static const struct _integer | kL |
The shift size of parameter l used in the tempering process of the generation algorithm. More... | |
| static const struct _integer | kF |
| The initialization multiplier used to seed the state sequence when a single value is used as seed. More... | |
| static const struct _integer | kDefaultSeed |
| The default seed used on construction or seeding. More... | |
| static const struct _integer | kLowerMask |
| The mask with 31 1's, where 31 is the number of bits that mark the separation point of words on each twist. More... | |
Pseudo-random number generator implemented on MT19937.
Definition in file CAENRandom.c.
|
static |
|
static |
|
static |
Definition at line 45 of file CAENRandom.c.
|
static |
Library state.
Definition at line 83 of file CAENRandom.c.
|
static |
Internal state.
Definition at line 84 of file CAENRandom.c.
|
static |
The number of bits of each word in the state sequence.
Definition at line 90 of file CAENRandom.c.
|
static |
The shift size used on twists to transform the values.
Definition at line 96 of file CAENRandom.c.
|
static |
The number of elements in the state sequence (degree of recurrence).
Definition at line 102 of file CAENRandom.c.
|
static |
The XOR mask applied as the linear function on each twist.
Definition at line 108 of file CAENRandom.c.
|
static |
The XOR mask used as parameter b in the tempering process of the generation algorithm.
Definition at line 114 of file CAENRandom.c.
|
static |
The XOR mask used as parameter c in the tempering process of the generation algorithm.
Definition at line 120 of file CAENRandom.c.
|
static |
The XOR mask used as parameter d in the tempering process of the generation algorithm.
Definition at line 126 of file CAENRandom.c.
|
static |
The shift size of parameter s used in the tempering process of the generation algorithm.
Definition at line 132 of file CAENRandom.c.
|
static |
The shift size of parameter t used in the tempering process of the generation algorithm.
Definition at line 138 of file CAENRandom.c.
|
static |
The shift size of parameter u used in the tempering process of the generation algorithm.
Definition at line 144 of file CAENRandom.c.
|
static |
The shift size of parameter l used in the tempering process of the generation algorithm.
Definition at line 150 of file CAENRandom.c.
|
static |
The initialization multiplier used to seed the state sequence when a single value is used as seed.
Definition at line 156 of file CAENRandom.c.
|
static |
The default seed used on construction or seeding.
Definition at line 162 of file CAENRandom.c.
|
static |
The mask with 31 1's, where 31 is the number of bits that mark the separation point of words on each twist.
Definition at line 168 of file CAENRandom.c.