CVR-Lib last update 20 Sep 2009

cvr::randomDistribution::randomDistribution::rndMinStd Class Reference

Linear Congruency Random Number Generator. More...

#include <cvrRandomDistribution.h>

Inheritance diagram for cvr::randomDistribution::randomDistribution::rndMinStd:

Inheritance graph
[legend]
Collaboration diagram for cvr::randomDistribution::randomDistribution::rndMinStd:

Collaboration graph
[legend]

List of all members.

Public Member Functions

 rndMinStd ()
virtual ~rndMinStd ()
virtual uint32 draw ()
virtual void setSeed (const uint32 seed)
uint32 max () const
virtual bool write (ioHandler &handler, const bool complete=true) const
virtual bool read (ioHandler &handler, const bool complete=true)

Protected Attributes

uint32 state_

Static Protected Attributes

static const uint32 a_ = 16807
static const uint32 m_ = 2147483647


Detailed Description

Linear Congruency Random Number Generator.

Constructor & Destructor Documentation

cvr::randomDistribution::randomDistribution::rndMinStd::rndMinStd (  ) 

Constructor.

virtual cvr::randomDistribution::randomDistribution::rndMinStd::~rndMinStd (  )  [virtual]

Destructor.


Member Function Documentation

virtual uint32 cvr::randomDistribution::randomDistribution::rndMinStd::draw (  )  [virtual]

Get a single number.

Implements cvr::randomDistribution::randomDistribution::rndBase.

uint32 cvr::randomDistribution::randomDistribution::rndMinStd::max (  )  const [virtual]

Return the maximal obtainable number (inclusive).

Implements cvr::randomDistribution::randomDistribution::rndBase.

virtual bool cvr::randomDistribution::randomDistribution::rndMinStd::read ( ioHandler handler,
const bool  complete = true 
) [virtual]

Read the parameters from the given ioHandler.

Parameters:
handler the ioHandler to be used
complete if true (the default) the enclosing begin/end will be also written, otherwise only the data block will be written.
Returns:
true if write was successful

Implements cvr::randomDistribution::randomDistribution::rndBase.

virtual void cvr::randomDistribution::randomDistribution::rndMinStd::setSeed ( const uint32  seed  )  [virtual]

Set the seed for the generator.

Implements cvr::randomDistribution::randomDistribution::rndBase.

virtual bool cvr::randomDistribution::randomDistribution::rndMinStd::write ( ioHandler handler,
const bool  complete = true 
) const [virtual]

Write the parameters in the given ioHandler.

Parameters:
handler the ioHandler to be used
complete if true (the default) the enclosing begin/end will be also written, otherwise only the data block will be written.
Returns:
true if write was successful

Implements cvr::randomDistribution::randomDistribution::rndBase.


Member Data Documentation

const uint32 cvr::randomDistribution::randomDistribution::rndMinStd::a_ = 16807 [static, protected]

Constant a.

const uint32 cvr::randomDistribution::randomDistribution::rndMinStd::m_ = 2147483647 [static, protected]

Constant m.

uint32 cvr::randomDistribution::randomDistribution::rndMinStd::state_ [protected]

Current state.


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

Generated on Sun Sep 20 22:09:03 2009 for CVR-Lib by Doxygen 1.5.8