nextInt32 (3) - Linux Manuals

nextInt32: Uniform random number generator.

NAME

QuantLib::MersenneTwisterUniformRng - Uniform random number generator.

SYNOPSIS


#include <ql/math/randomnumbers/mt19937uniformrng.hpp>

Public Types


typedef Sample< Real > sample_type

Public Member Functions


MersenneTwisterUniformRng (unsigned long seed=0)

MersenneTwisterUniformRng (const std::vector< unsigned long > &seeds)

sample_type next () const

unsigned long nextInt32 () const
return a random number on [0,0xffffffff]-interval

Detailed Description

Uniform random number generator.

Mersenne Twister random number generator of period 2**19937-1

For more details see http://www.math.keio.ac.jp/matumoto/emt.html

Tests

the correctness of the returned values is tested by checking them against known good results.

Constructor & Destructor Documentation

MersenneTwisterUniformRng (unsigned long seed = 0) [explicit]

if the given seed is 0, a random seed will be chosen based on clock()

Member Function Documentation

sample_type next () const

returns a sample with weight 1.0 containing a random number on (0.0, 1.0)-real-interval

Author

Generated automatically by Doxygen for QuantLib from the source code.