Specialized implementation of the Random functions based on the GSL library.
These will work onlmy with a GSLRandomEngine type
Definition at line 43 of file GSLRandomFunctions.h.
Public Member Functions | |
RandomFunctions () | |
RandomFunctions (EngineType &rng) | |
double | Beta (double a, double b) |
Beta distribution. | |
unsigned int | Binomial (unsigned int ntot, double prob) |
Binomial distribution. | |
double | BreitWigner (double mean=0., double gamma=1) |
Breit Wigner distribution. | |
double | ChiSquare (double nu) |
Chi square distribution. | |
void | Circle (double &x, double &y, double r=1) |
generate random numbers in a 2D circle of radious 1 | |
EngineType & | Engine () |
double | Exp (double tau) |
Exponential distribution. | |
double | FDist (double nu1, double nu2) |
F distribution. | |
double | Gamma (double a, double b) |
Gamma distribution. | |
double | Gaus (double mean=0, double sigma=1) |
Gaussian distribution. | |
double | GausBM (double mean=0, double sigma=1) |
Gaussian distribution (Box-Muller method) | |
double | GausR (double mean=0, double sigma=1) |
Gaussian distribution (Ratio Method) | |
void | Gaussian2D (double sigmaX, double sigmaY, double rho, double &x, double &y) |
Bivariate Gaussian distribution with correlation. | |
void | GaussianND (size_t n, const double *meanVec, const double *covMatrix, double *x, double *lmat=nullptr) |
Multi-variate Gaussian distribution with correlation. | |
double | GaussianTail (double a, double sigma=1) |
Gaussian Tail distribution. | |
double | GausZig (double mean, double sigma) |
double | Landau (double mean=0, double sigma=1) |
Landau distribution. | |
double | Logistic (double a) |
Logistic distribution. | |
double | LogNormal (double zeta, double sigma) |
Log Normal distribution. | |
std::vector< unsigned int > | Multinomial (unsigned int ntot, const std::vector< double > &p) |
Multinomial distribution. | |
unsigned int | NegativeBinomial (double n, double prob) |
Negative Binomial distribution First parameter is n, second is probability To be consistent with Random::Binomial. | |
double | Pareto (double a, double b) |
Pareto distribution. | |
unsigned int | Poisson (double mu) |
Poisson distribution. | |
double | Rayleigh (double sigma) |
Rayleigh distribution. | |
void | Sphere (double &x, double &y, double &z, double r=1) |
generate random numbers in a 3D sphere of radious 1 | |
double | tDist (double nu) |
t student distribution | |
Public Member Functions inherited from ROOT::Math::RandomFunctions< EngineType, DefaultEngineType > | |
RandomFunctions (EngineType &rng) | |
~RandomFunctions () | |
destructor (no op) we do not maintain the engine) | |
double | Beta (double, double) |
int | Binomial (int ntot, double prob) |
Generate binomial numbers. | |
double | BreitWigner (double mean, double gamma) |
Return a number distributed following a BreitWigner function with mean and gamma. | |
double | ChiSquare (double) |
void | Circle (double &x, double &y, double r) |
Generates random vectors, uniformly distributed over a circle of given radius. | |
double | Exp (double tau) |
Returns an exponential deviate. | |
double | FDist (double, double) |
double | Gamma (double, double) |
methods which are only for GSL random generators | |
double | Gaus (double mean, double sigma) |
generate Gaussian number using default method | |
double | GausACR (double mean, double sigma) |
generate random numbers according to the Acceptance-Complement-Ratio method | |
double | GausBM (double mean, double sigma) |
generate Gaussian number using Box-Muller method | |
double | Landau (double mu, double sigma) |
Generate a random number following a Landau distribution with location parameter mu and scale parameter sigma: Landau( (x-mu)/sigma ) | |
double | Logistic (double) |
double | LogNormal (double, double) |
std::vector< unsigned int > | MultiNomial (unsigned int, const std::vector< double > &) |
unsigned int | NegativeBinomial (double, double) |
double | operator() () |
non-virtual method | |
double | Pareto (double, double) |
int | Poisson (double mean) |
Generates a random integer N according to a Poisson law. | |
double | PoissonD (double mean) |
void | Rannor (double &a, double &b) |
Generate numbers distributed following a gaussian with mean=0 and sigma=1. | |
double | Rayleigh (double) |
void | Sphere (double &x, double &y, double &z, double r) |
Generates random vectors, uniformly distributed over the surface of a sphere of given radius. | |
double | tDist (double) |
double | Uniform (double a) |
generate random numbers following a Uniform distribution in the [0,a] interval | |
double | Uniform (double a, double b) |
generate random numbers following a Uniform distribution in the [a,b] interval | |
Additional Inherited Members | |
Protected Member Functions inherited from ROOT::Math::RandomFunctions< EngineType, DefaultEngineType > | |
double | Rndm_impl () |
Internal implementation to return random number Since this one is not a virtual function is faster than Rndm. | |
EngineType & | Rng () |
#include <Math/GSLRandomFunctions.h>
|
inline |
Definition at line 50 of file GSLRandomFunctions.h.
|
inline |
Definition at line 52 of file GSLRandomFunctions.h.
|
inline |
Beta distribution.
Definition at line 141 of file GSLRandomFunctions.h.
|
inline |
Binomial distribution.
Definition at line 222 of file GSLRandomFunctions.h.
|
inline |
Breit Wigner distribution.
Definition at line 120 of file GSLRandomFunctions.h.
|
inline |
Chi square distribution.
Definition at line 155 of file GSLRandomFunctions.h.
|
inline |
generate random numbers in a 2D circle of radious 1
Definition at line 196 of file GSLRandomFunctions.h.
|
inline |
Definition at line 55 of file GSLRandomFunctions.h.
|
inline |
Exponential distribution.
Definition at line 114 of file GSLRandomFunctions.h.
|
inline |
F distribution.
Definition at line 162 of file GSLRandomFunctions.h.
|
inline |
Gamma distribution.
Definition at line 134 of file GSLRandomFunctions.h.
|
inline |
Gaussian distribution.
Default method (use Ziggurat)
Definition at line 68 of file GSLRandomFunctions.h.
|
inline |
Gaussian distribution (Box-Muller method)
Definition at line 75 of file GSLRandomFunctions.h.
|
inline |
Gaussian distribution (Ratio Method)
Definition at line 82 of file GSLRandomFunctions.h.
|
inline |
Bivariate Gaussian distribution with correlation.
Definition at line 96 of file GSLRandomFunctions.h.
|
inline |
Multi-variate Gaussian distribution with correlation.
The covMatrix is a pointer to the covcariance matrix (NxN) Lmat is a pointer to store the factorized Cholesky decomposition C = LL^T of the covariance matrix If the generator is to be called again with the same covariance one can provide a null CovMAtrix and only lmat
Definition at line 107 of file GSLRandomFunctions.h.
|
inline |
Gaussian Tail distribution.
Definition at line 89 of file GSLRandomFunctions.h.
|
inline |
Definition at line 57 of file GSLRandomFunctions.h.
|
inline |
Landau distribution.
Definition at line 127 of file GSLRandomFunctions.h.
|
inline |
Logistic distribution.
Definition at line 182 of file GSLRandomFunctions.h.
|
inline |
Log Normal distribution.
Definition at line 148 of file GSLRandomFunctions.h.
|
inline |
Multinomial distribution.
Definition at line 238 of file GSLRandomFunctions.h.
|
inline |
Negative Binomial distribution First parameter is n, second is probability To be consistent with Random::Binomial.
Definition at line 231 of file GSLRandomFunctions.h.
|
inline |
Pareto distribution.
Definition at line 189 of file GSLRandomFunctions.h.
|
inline |
Poisson distribution.
Definition at line 215 of file GSLRandomFunctions.h.
|
inline |
Rayleigh distribution.
Definition at line 175 of file GSLRandomFunctions.h.
|
inline |
generate random numbers in a 3D sphere of radious 1
Definition at line 205 of file GSLRandomFunctions.h.
|
inline |
t student distribution
Definition at line 169 of file GSLRandomFunctions.h.