DUtils::Random Class Reference

Functions to generate pseudo-random numbers. More...

#include <Random.h>

List of all members.

Classes

class  UnrepeatedRandomizer
 Provides pseudo-random numbers with no repetitions. More...

Static Public Member Functions

static void SeedRand ()
static void SeedRandOnce ()
static void SeedRand (int seed)
static void SeedRandOnce (int seed)
template<class T >
static T RandomValue ()
template<class T >
static T RandomValue (T min, T max)
static int RandomInt (int min, int max)
template<class T >
static T RandomGaussianValue (T mean, T sigma)

Detailed Description

Functions to generate pseudo-random numbers.


Member Function Documentation

template<class T >
static T DUtils::Random::RandomGaussianValue ( mean,
sigma 
) [inline, static]

Returns a random number from a gaussian distribution

Parameters:
mean 
sigma standard deviation
int DUtils::Random::RandomInt ( int  min,
int  max 
) [static]

Returns a random int in the range [min..max]

Parameters:
min 
max 
Returns:
random int in [min..max]
template<class T >
static T DUtils::Random::RandomValue ( min,
max 
) [inline, static]

Returns a random number in the range [min..max]

Parameters:
min 
max 
Returns:
random T number in [min..max]
template<class T >
static T DUtils::Random::RandomValue (  )  [inline, static]

Returns a random number in the range [0..1]

Returns:
random T number in [0..1]
void DUtils::Random::SeedRand ( int  seed  )  [static]

Sets the given random number seed

Parameters:
seed 
void DUtils::Random::SeedRand (  )  [static]

Sets the random number seed to the current time

void DUtils::Random::SeedRandOnce ( int  seed  )  [static]

Sets the given random number seed only the first time this function is called

Parameters:
seed 
void DUtils::Random::SeedRandOnce (  )  [static]

Sets the random number seed to the current time only the first time this function is called


The documentation for this class was generated from the following files:
 All Classes Namespaces Functions Variables Enumerations Friends
Generated on Thu Feb 7 19:16:00 2013 by  doxygen 1.6.3