113 bool Init(
const std::string & distr,
const std::string & method);
167 bool InitPoisson(
double mu,
const std::string & method =
"dstd");
177 bool InitBinomial(
unsigned int ntot,
double prob,
const std::string & method =
"dstd");
222 void SetSeed(
unsigned int seed);
264 std::unique_ptr<TUnuranBaseDist>
fDist;
struct unur_urng UNUR_URNG
struct unur_distr UNUR_DISTR
TH1 is the base class of all histogram classes in ROOT.
This is the base class for the ROOT Random number generators.
TUnuranContDist class describing one dimensional continuous distribution.
TUnuranDiscrDist class for one dimensional discrete distribution.
TUnuranEmpDist class for describing empiral distributions.
TUnuranMultiContDist class describing multi dimensional continuous distributions.
bool SetMethodAndInit()
change the method and initialize Unuran with the previously given distribution
int SampleDiscr()
Sample discrete distributions User is responsible for having previously correctly initialized with TU...
bool SetLogStream()
set stream for log and error (not yet implemented)
const std::string & MethodName() const
used Unuran method
std::unique_ptr< TUnuranBaseDist > fDist
bool SetDiscreteDistribution(const TUnuranDiscrDist &dist)
bool InitBinomial(unsigned int ntot, double prob, const std::string &method="dstd")
Initialize method for the Binomial distribution Used to generate poisson numbers for a constant param...
bool SetContDistribution(const TUnuranContDist &dist)
bool SampleMulti(double *x)
Sample multidimensional distributions User is responsible for having previously correctly initialized...
bool ReInitDiscrDist(unsigned int npar, double *params)
Reinitialize UNURAN by changing the distribution parameters but mantaining same distribution and meth...
bool Init(const std::string &distr, const std::string &method)
initialize with Unuran string interface
bool SetRandomGenerator()
bool SetLogLevel(unsigned int iflag=1)
set log level
bool SetMultiDistribution(const TUnuranMultiContDist &dist)
double Sample()
Sample 1D distribution User is responsible for having previously correctly initialized with TUnuran::...
bool SetEmpiricalDistribution(const TUnuranEmpDist &dist)
TRandom * GetRandom()
return instance of the random engine used
bool InitPoisson(double mu, const std::string &method="dstd")
Initialize method for the Poisson distribution Used to generate poisson numbers for a constant parame...
TUnuran & operator=(const TUnuran &rhs)
Assignment operator.
void SetSeed(unsigned int seed)
set the seed for the random number generator
void SetRandom(TRandom *r)
set the random engine.