COPASI API
4.40.278
|
#include <Cmt19937.h>
Protected Member Functions | |
Cmt19937 (unsigned C_INT32 seed) | |
void | next_state () |
Protected Member Functions inherited from CRandom | |
CRandom () | |
void | setModulus (const unsigned C_INT32 &modulus) |
Private Attributes | |
C_INT | mLeft |
unsigned C_INT32 * | mNext |
unsigned C_INT32 | mState [624] |
Friends | |
CRandom * | CRandom::createGenerator (CRandom::Type type, unsigned C_INT32 seed) |
Additional Inherited Members | |
Public Types inherited from CRandom | |
enum | Type { r250 = 0 , mt19937 , mt19937HR , unkown } |
Static Public Member Functions inherited from CRandom | |
static CRandom * | createGenerator (CRandom::Type type=CRandom::mt19937, unsigned C_INT32 seed=0) |
static unsigned C_INT32 | getSystemSeed () |
Static Public Attributes inherited from CRandom | |
static const std::string | TypeName [] |
static const char * | XMLType [] |
Protected Attributes inherited from CRandom | |
C_FLOAT64 | mFloat |
unsigned C_INT32 | mModulus |
C_FLOAT64 | mModulusInv |
C_FLOAT64 | mModulusInv1 |
C_INT32 | mNumberS |
unsigned C_INT32 | mNumberU |
CRandom::Type | mType |
|
protected |
Default/Named constructor. Seeds the random number generator with the given seed.
C_INT32 | seed |
References initialize(), and CRandom::setModulus().
Cmt19937::~Cmt19937 | ( | ) |
The destructor.
C_FLOAT64 Cmt19937::genrand_res53 | ( | ) |
References C_INT32, getRandomU(), and CRandom::mFloat.
|
virtual |
Produces a uniformly distributed random number in 0 <= x <= 1.
Reimplemented from CRandom.
Reimplemented in Cmt19937HR.
References C_FLOAT64, mLeft, mNext, CRandom::mNumberU, and next_state().
|
virtual |
Produces a uniformly distributed random number in 0 <= x < 1. Note: 0 < x <= 1 may be achieved by 1.0 - getRandomCO().
Reimplemented from CRandom.
Reimplemented in Cmt19937HR.
References C_FLOAT64, mLeft, mNext, CRandom::mNumberU, and next_state().
|
virtual |
Produces a uniformly distributed random number in 0 < x < 1.
Reimplemented from CRandom.
Reimplemented in Cmt19937HR.
References C_FLOAT64, mLeft, mNext, CRandom::mNumberU, and next_state().
|
virtual |
Get a random number in 0 <= n <= (Modulus & 0x7ffffff)
Reimplemented from CRandom.
References mLeft, mNext, CRandom::mNumberU, and next_state().
|
virtual |
Get a random number in 0 <= n <= Modulus
Reimplemented from CRandom.
References mLeft, mNext, CRandom::mNumberU, and next_state().
Referenced by genrand_res53(), Cmt19937HR::getRandomCC(), Cmt19937HR::getRandomCO(), and Cmt19937HR::getRandomOO().
References Cmt19937_N, initialize(), mLeft, and mState.
|
virtual |
Initialize or reinitialize the random number generator with the given seed.
unsigned | C_INT32 seed (default system seed) |
Reimplemented from CRandom.
References Cmt19937_N, mLeft, and mState.
Referenced by Cmt19937(), and init_by_array().
|
protected |
References C_INT32, Cmt19937_M, Cmt19937_N, Cmt19937_TWIST, mLeft, mNext, and mState.
Referenced by getRandomCC(), getRandomCO(), getRandomOO(), getRandomS(), and getRandomU().
|
friend |
|
private |
Referenced by getRandomCC(), getRandomCO(), getRandomOO(), getRandomS(), getRandomU(), init_by_array(), initialize(), and next_state().
|
private |
Referenced by getRandomCC(), getRandomCO(), getRandomOO(), getRandomS(), getRandomU(), and next_state().
|
private |
Referenced by init_by_array(), initialize(), and next_state().