MDSTk Libraries  1.1.0
Medical Data Segmentation Toolkit
Public Types | Public Member Functions | Static Public Attributes | Protected Attributes | Static Protected Attributes
mds::math::CNormalPRNG Class Reference

Pseudo-Random Number Generator (PRNG) having the normal (gaussian) distribution. More...

#include <mdsRandom.h>

Inheritance diagram for mds::math::CNormalPRNG:
Inheritance graph
[legend]

List of all members.

Public Types

typedef mds::sys::tInt32 tSeed
 Type of the PRNG seed.

Public Member Functions

void changeSeed (tSeed Seed)
 Changes the PRNG seed.
 CNormalPRNG ()
 Default constructor.
 CNormalPRNG (tSeed Seed)
 Constructor.
double random ()
 Returns random value in the range <0..1).
double random (double dMean, double dSigma)
 Returns random numbers having normal distribution.
virtual ~CNormalPRNG ()
 Destructor.

Static Public Attributes

static const tSeed DEFAULT_SEED = 1537
 Default seed.

Protected Attributes

tSeed m_Seed
 Current PRNG seed.

Static Protected Attributes

static const tSeed MAX_VALUE = 0x7fffffff
static const tSeed MULTIPLE_CONST = 1220703125
 Algorithm constants.
static const tSeed SIGN_BIT = 0x80000000

Detailed Description

Pseudo-Random Number Generator (PRNG) having the normal (gaussian) distribution.


Member Typedef Documentation

typedef mds::sys::tInt32 mds::math::CPseudoRNG::tSeed [inherited]

Type of the PRNG seed.


Constructor & Destructor Documentation

Default constructor.

Constructor.

virtual mds::math::CNormalPRNG::~CNormalPRNG ( ) [virtual]

Destructor.


Member Function Documentation

void mds::math::CPseudoRNG::changeSeed ( tSeed  Seed) [inherited]

Changes the PRNG seed.

double mds::math::CPseudoRNG::random ( ) [inherited]

Returns random value in the range <0..1).

double mds::math::CNormalPRNG::random ( double  dMean,
double  dSigma 
)

Returns random numbers having normal distribution.


Member Data Documentation

const tSeed mds::math::CPseudoRNG::DEFAULT_SEED = 1537 [static, inherited]

Default seed.

tSeed mds::math::CPseudoRNG::m_Seed [protected, inherited]

Current PRNG seed.

const tSeed mds::math::CPseudoRNG::MAX_VALUE = 0x7fffffff [static, protected, inherited]
const tSeed mds::math::CPseudoRNG::MULTIPLE_CONST = 1220703125 [static, protected, inherited]

Algorithm constants.

const tSeed mds::math::CPseudoRNG::SIGN_BIT = 0x80000000 [static, protected, inherited]

The documentation for this class was generated from the following file: