Logo ROOT  
Reference Guide
RooBernstein.h
Go to the documentation of this file.
1/*****************************************************************************
2 * Project: RooFit *
3 * Package: RooFitModels *
4 * File: $Id$
5 * Authors: *
6 * Kyle Cranmer
7 * *
8 * *
9 * Redistribution and use in source and binary forms, *
10 * with or without modification, are permitted according to the terms *
11 * listed in LICENSE (http://roofit.sourceforge.net/license.txt) *
12 *****************************************************************************/
13#ifndef ROO_BERNSTEIN
14#define ROO_BERNSTEIN
15
16#include "RooAbsPdf.h"
17#include "RooTemplateProxy.h"
18#include "RooRealVar.h"
19#include "RooListProxy.h"
20#include "RooAbsRealLValue.h"
21
22class RooRealVar;
23class RooArgList ;
24
25class RooBernstein : public RooAbsPdf {
26public:
27
28 RooBernstein() ;
29 RooBernstein(const char *name, const char *title,
31
32 RooBernstein(const RooBernstein& other, const char* name = 0);
33 virtual TObject* clone(const char* newname) const { return new RooBernstein(*this, newname); }
34 inline virtual ~RooBernstein() { }
35
36 Int_t getAnalyticalIntegral(RooArgSet& allVars, RooArgSet& analVars, const char* rangeName=0) const ;
37 Double_t analyticalIntegral(Int_t code, const char* rangeName=0) const ;
38 void selectNormalizationRange(const char* rangeName=0, Bool_t force=kFALSE) ;
39
40private:
41
44 std::string _refRangeName ;
45
46 Double_t evaluate() const;
47 RooSpan<double> evaluateBatch(std::size_t begin, std::size_t batchSize) const;
48
49
50 ClassDef(RooBernstein,2) // Bernstein polynomial PDF
51};
52
53#endif
const Bool_t kFALSE
Definition: RtypesCore.h:90
double Double_t
Definition: RtypesCore.h:57
#define ClassDef(name, id)
Definition: Rtypes.h:322
char name[80]
Definition: TGX11.cxx:109
RooAbsRealLValue is the common abstract base class for objects that represent a real value that may a...
RooArgList is a container object that can hold multiple RooAbsArg objects.
Definition: RooArgList.h:21
RooArgSet is a container object that can hold multiple RooAbsArg objects.
Definition: RooArgSet.h:28
Bernstein basis polynomials are positive-definite in the range [0,1].
Definition: RooBernstein.h:25
Double_t analyticalIntegral(Int_t code, const char *rangeName=0) const
Implements the actual analytical integral(s) advertised by getAnalyticalIntegral.
virtual TObject * clone(const char *newname) const
Definition: RooBernstein.h:33
virtual ~RooBernstein()
Definition: RooBernstein.h:34
std::string _refRangeName
Definition: RooBernstein.h:44
Int_t getAnalyticalIntegral(RooArgSet &allVars, RooArgSet &analVars, const char *rangeName=0) const
Interface function getAnalyticalIntergral advertises the analytical integrals that are supported.
RooSpan< double > evaluateBatch(std::size_t begin, std::size_t batchSize) const
Evaluate function for a batch of input data points.
RooTemplateProxy< RooAbsRealLValue > _x
Definition: RooBernstein.h:42
void selectNormalizationRange(const char *rangeName=0, Bool_t force=kFALSE)
Force use of a given normalisation range.
Double_t evaluate() const
Evaluate this PDF / function / constant. Needs to be overridden by all derived classes.
RooListProxy _coefList
Definition: RooBernstein.h:43
RooListProxy is the concrete proxy for RooArgList objects.
Definition: RooListProxy.h:25
RooRealVar represents a variable that can be changed from the outside.
Definition: RooRealVar.h:35
A simple container to hold a batch of data values.
Definition: RooSpan.h:32
Mother of all ROOT objects.
Definition: TObject.h:37