49 std::log(std::numeric_limits<double>::epsilon()));
73 _x(
"x",
"Observable", this, xpdf),
94 _x(
"x", this, other.
_x),
143 inline bool operator()(
const struct Data&
a,
const struct Data&
b)
const
144 {
return a.x <
b.x; }
152 std::vector<Data> tmp;
160 for (
Int_t i = 0; i < data.numEntries(); ++i) {
162 const double x = real.
getVal();
163 const double w = data.weight();
182 std::sort(tmp.begin(), tmp.end(), cmp());
188 for (
unsigned i = 0; i < tmp.size(); ++i) {
194 std::vector<Data> tmp2;
199 double sigmav=std::sqrt(x2/x0-meanv*meanv);
200 double h=std::pow(
double(4)/
double(3),0.2)*std::pow(
_sumWgt,-0.2)*
_rho;
201 double hmin=
h*sigmav*std::sqrt(2.)/10;
202 double norm=
h*std::sqrt(sigmav *
_sumWgt)/(2.0*std::sqrt(3.0));
216 const double xlo = std::min(
_hi,
218 const double xhi = std::max(
_lo,
220 if (xlo >= xhi)
continue;
228 for (
Int_t k = binlo; k <= binhi; ++k, chi += chi2incr) {
234 const double xlo = std::min(
_hi,
236 const double xhi = std::max(
_lo,
238 if (xlo >= xhi)
continue;
246 for (
Int_t k = binlo; k <= binhi; ++k, chi += chi2incr) {
253 const double xlo = std::min(
_hi,
255 const double xhi = std::max(
_lo,
257 if (xlo >= xhi)
continue;
265 for (
Int_t k = binlo; k <= binhi; ++k, chi += chi2incr) {
270 static const double sqrt2pi(std::sqrt(2*
TMath::Pi()));
312 const double xmin = std::max(
_lo,
_x.min(rangeName));
313 const double xmax = std::min(
_hi,
_x.max(rangeName));
321 for (
Int_t i = imin + 2; i < imax; ++i)
336 }
else if (imin == imax) {
356 double max = -std::numeric_limits<double>::max();
373 for ( ; it < iend; ++it) {
374 const double r = (
x - *it) / sigmav;
375 y += std::exp(-0.5 *
r *
r);
378 static const double sqrt2pi(std::sqrt(2*
TMath::Pi()));
379 return y/(sigmav*sqrt2pi);
int Int_t
Signed integer 4 bytes (int).
#define R__ASSERT(e)
Checks condition e and reports a fatal error if it's false.
TRObject operator()(const T1 &t1) const
bool contains(const char *name) const
Check if collection contains an argument with a specific name.
RooAbsPdf()
Default constructor.
double getVal(const RooArgSet *normalisationSet=nullptr) const
Evaluate object.
bool matchArgs(const RooArgSet &allDeps, RooArgSet &analDeps, const RooArgProxy &a, const Proxies &... proxies) const
RooArgSet is a container object that can hold multiple RooAbsArg objects.
static constexpr int _nPoints
RooKeysPdf()
coverity[UNINIT_CTOR]
double _lookupTable[_nPoints+1]
double maxVal(Int_t code) const override
Return maximum value for set of observables identified by code assigned in getMaxVal.
double g(double x, double sigma) const
void LoadDataSet(RooDataSet &data)
Int_t getAnalyticalIntegral(RooArgSet &allVars, RooArgSet &analVars, const char *rangeName=nullptr) const override
Interface function getAnalyticalIntergral advertises the analytical integrals that are supported.
double analyticalIntegral(Int_t code, const char *rangeName=nullptr) const override
Implements the actual analytical integral(s) advertised by getAnalyticalIntegral.
double evaluate() const override
Evaluate this PDF / function / constant. Needs to be overridden by all derived classes.
static const double _nSigma
!
Int_t getMaxVal(const RooArgSet &vars) const override
Advertise capability to determine maximum value of function for given set of observables.
Variable that can be changed from the outside.
const char * GetName() const override
Returns name of object.
static uint64_t sum(uint64_t i)