VR-Forces 4.3.1 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions | Private Member Functions | Private Attributes
makVrv::DtGaussianDistributionGenerator Class Reference

Implementation independent random number generator with a normal (Gaussian) distribution. More...

Public Member Functions

 DtGaussianDistributionGenerator ()
 Default CTOR.
 DtGaussianDistributionGenerator (const DtGaussianDistributionGenerator &other)
 Copy CTOR.
 ~DtGaussianDistributionGenerator ()
 DTOR.
void setSeed (int seed)
 Set the seed of the random number generator.
float generate (float mn=0.0f, float sd=1.0f) const
 Generate a new random number.
double generate (double mn=0.0f, double sd=1.0f) const
float generateHalfCurve (float mn=0.0f, float sd=1.0f) const
 Generate a new random number which lies within the half of the distribution curve that is greater than the mean.
double generateHalfCurve (double mn=0.0f, double sd=1.0f) const

Private Member Functions

DtGaussianDistributionGeneratoroperator= (const DtGaussianDistributionGenerator &)
 Assignment Operator.

Private Attributes

LocalPrivate * myMutablePrivate

Detailed Description

Implementation independent random number generator with a normal (Gaussian) distribution.

Constructor & Destructor Documentation

makVrv::DtGaussianDistributionGenerator::DtGaussianDistributionGenerator ( )

Default CTOR.

makVrv::DtGaussianDistributionGenerator::DtGaussianDistributionGenerator ( const DtGaussianDistributionGenerator other)

Copy CTOR.

makVrv::DtGaussianDistributionGenerator::~DtGaussianDistributionGenerator ( )

DTOR.

Member Function Documentation

void makVrv::DtGaussianDistributionGenerator::setSeed ( int  seed)

Set the seed of the random number generator.

Parameters
[in]seedis the seed to set the generator.
float makVrv::DtGaussianDistributionGenerator::generate ( float  mn = 0.0f,
float  sd = 1.0f 
) const

Generate a new random number.

Parameters
[in]mnis the mean value of the normal distribution.
[in]sdis the standard deviation of the normal distribution.
Returns
A random number with a ~68% chance to be within one standard deviation of the mean, ~95% chance to be within two standard deviations of the mean, ~99% chance to be within three standard deviations of the mean, etc.
double makVrv::DtGaussianDistributionGenerator::generate ( double  mn = 0.0f,
double  sd = 1.0f 
) const
float makVrv::DtGaussianDistributionGenerator::generateHalfCurve ( float  mn = 0.0f,
float  sd = 1.0f 
) const

Generate a new random number which lies within the half of the distribution curve that is greater than the mean.

Parameters
[in]mnis the mean value of the normal distribution.
[in]sdis the standard deviation of the normal distribution.
Returns
A random number with a ~68% chance to be within one standard deviation of the mean, ~95% chance to be within two standard deviations of the mean, ~99% chance to be within three standard deviations of the mean, etc.
double makVrv::DtGaussianDistributionGenerator::generateHalfCurve ( double  mn = 0.0f,
double  sd = 1.0f 
) const
DtGaussianDistributionGenerator& makVrv::DtGaussianDistributionGenerator::operator= ( const DtGaussianDistributionGenerator )
private

Assignment Operator.

Note
Not implemented

Member Data Documentation

LocalPrivate* makVrv::DtGaussianDistributionGenerator::myMutablePrivate
mutableprivate

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

Document ID: Generated on Wed Jul 29 00:55:00 EDT 2015 from SVN revision 155257
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)