60 void seed(
unsigned long long int seed);
61 unsigned long long int seed(
void)
const;
62 unsigned long int int32(
void);
63 unsigned long long int int64(
void);
66 double exp(
const double& lambda);
67 double poisson(
const double& lambda);
69 int cdf(
const std::vector<double>&
cdf);
double chisq2(void)
Returns Chi2 deviates for 2 degrees of freedom.
double m_exp_lambda
exp(-lambda)
std::string print(const GChatter &chatter=NORMAL) const
Print random number generator information.
double m_sqrt_lambda
sqrt(2*lambda)
unsigned long long int int64(void)
Return 64-bit random unsigned integer.
void copy_members(const GRan &ran)
Copy class members.
GRan(void)
Void constructor.
int cdf(const std::vector< double > &cdf)
Random sampling from a cumulative density function.
Definition of interface for all GammaLib classes.
unsigned long long int m_value2
Value 2.
Random number generator class.
void free_members(void)
Delete class members.
double m_old_lambda
Old lambda value.
unsigned long long int m_value1
Value 1.
unsigned long int int32(void)
Return 32-bit random unsigned integer.
Interface class for all GammaLib classes.
unsigned long long int m_value3
Value 3.
double uniform(void)
Returns random double precision floating value in range 0 to 1.
GRan * clone(void) const
Clone random number generator.
unsigned long long int seed(void) const
Return seed value.
Vector class interface definition.
double normal(void)
Returns normal deviates.
unsigned long long int m_seed
Random number generator seed.
void init_members(unsigned long long int seed=41L)
Initialise class members.
GRan & operator=(const GRan &ran)
Assignment operator.
virtual ~GRan(void)
Destructor.
double m_log_lambda
log(lambda)
double poisson(const double &lambda)
Returns Poisson deviates.
std::string classname(void) const
Return class name.
void clear(void)
Clear random number generator.
double exp(const double &lambda)
Returns exponential deviates.