virtual | ~TUnuranDiscrDist() |
double | Cdf(int x) const |
static TClass* | Class() |
virtual TUnuranDiscrDist* | Clone() const |
bool | GetDomain(int& xmin, int& xmax) const |
bool | HasCdf() const |
bool | HasMode() const |
bool | HasProbSum() const |
virtual TClass* | IsA() const |
int | Mode() const |
TUnuranDiscrDist& | operator=(const TUnuranDiscrDist& rhs) |
double | Pmf(int x) const |
double | ProbSum() const |
const vector<double>& | ProbVec() const |
void | SetCdf(const ROOT::Math::IGenFunction& cdf) |
void | SetCdf(TF1* cdf) |
void | SetDomain(int xmin, int xmax) |
void | SetMode(int mode) |
void | SetProbSum(double sum) |
virtual void | ShowMembers(TMemberInspector& insp) const |
virtual void | Streamer(TBuffer&) |
void | StreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b) |
TUnuranDiscrDist(TF1* func) | |
TUnuranDiscrDist(const TUnuranDiscrDist&) | |
TUnuranDiscrDist(const ROOT::Math::IGenFunction& func, bool copyFunc = false) |
const ROOT::Math::IGenFunction* | fCdf | pointer to the cumulative distribution function |
bool | fHasDomain | flag to control if distribution has a defined domain (otherwise is [0,INT_MAX]) |
bool | fHasMode | flag to control if distribution has a pre-computed mode |
bool | fHasSum | flag to control if distribution has a pre-computed sum of the probabilities |
int | fMode | mode of the distribution |
bool | fOwnFunc | flag to control if distribution owns the funcitno pointers |
vector<double> | fPVec | Vector of the probabilities |
vector<double> | fPVecSum | Vector of the sum of the probabilities |
const ROOT::Math::IGenFunction* | fPmf | pointer to a function calculating the probability |
double | fSum | total sum of the probabilities in the given domain |
int | fXmax | upper value of the domain |
int | fXmin | lower value of the domain |
Inheritance Chart: | |||||||||
|
Constructor from a generic function object
set cdf distribution using a generic function interface
evaluate the cumulative distribution otherwise evaluate from the sum of the probabilities
Clone (required by base class)
{ return new TUnuranDiscrDist(*this); }
Set the distribution domain, by default the domain is [0,INT_MAX] If xmin >= xmax a domain is removed
check if distribution has domain and return in case its domain
flag to control if distribution provides the total area of the probability function
{ return fHasSum; }
retrieve a reference to the vector of the probabilities : Prob(i) If the distribution is defined from a function (i.e. for distribution with undefined domain) the vector is empty.
{ return fPVec; }