Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
RooMomentMorphFunc.h
Go to the documentation of this file.
1/*****************************************************************************
2 * Project: RooFit *
3 * *
4 * This code was autogenerated by RooClassFactory *
5 *****************************************************************************/
6
7#ifndef ROO_MOMENT_MORPH_FUNC
8#define ROO_MOMENT_MORPH_FUNC
9
10#include "RooAbsPdf.h"
11#include "RooRealProxy.h"
12#include "RooCategoryProxy.h"
13#include "RooAbsReal.h"
14#include "RooAbsCategory.h"
15#include "RooSetProxy.h"
16#include "RooListProxy.h"
17#include "RooArgList.h"
18
19#include "TMatrixD.h"
20#include "TVectorD.h"
21
22#include <list>
23
25
27public:
29
31
32 RooMomentMorphFunc(const char *name, const char *title, RooAbsReal &_m, const RooArgList &varList,
33 const RooArgList &pdfList, const RooArgList &mrefList, Setting setting = NonLinearPosFractions);
34 RooMomentMorphFunc(const char *name, const char *title, RooAbsReal &_m, const RooArgList &varList,
35 const RooArgList &pdfList, const TVectorD &mrefpoints, Setting setting = NonLinearPosFractions);
36 RooMomentMorphFunc(const RooMomentMorphFunc &other, const char *name = 0);
37 virtual TObject *clone(const char *newname) const { return new RooMomentMorphFunc(*this, newname); }
38 virtual ~RooMomentMorphFunc();
39
40 void setMode(const Setting &setting) { _setting = setting; }
41
42 void useHorizontalMorphing(bool val) { _useHorizMorph = val; }
43
44 virtual Bool_t selfNormalized() const
45 {
46 // P.d.f is self normalized
47 return kTRUE;
48 }
49
50 virtual Double_t getVal(const RooArgSet *set = 0) const;
51 RooAbsReal *sumFunc(const RooArgSet *nset);
52 const RooAbsReal *sumFunc(const RooArgSet *nset) const;
53
54 virtual std::list<Double_t> *plotSamplingHint(RooAbsRealLValue &obs, Double_t xlo, Double_t xhi) const;
55 virtual std::list<Double_t> *binBoundaries(RooAbsRealLValue & /*obs*/, Double_t /*xlo*/, Double_t /*xhi*/) const;
56 Bool_t isBinnedDistribution(const RooArgSet &obs) const;
57
58protected:
60 public:
62 : _sumFunc(&sumFunc), _tracker(&tracker)
63 {
64 _frac.add(flist);
65 };
67 virtual ~CacheElem();
72
74 const RooRealVar *frac(Int_t i) const;
75 void calculateFractions(const RooMomentMorphFunc &self, Bool_t verbose = kTRUE) const;
76 };
77 mutable RooObjCacheManager _cacheMgr; //! The cache manager
78 mutable RooArgSet *_curNormSet; //! Current normalization set
79
80 friend class CacheElem; // Cache needs to be able to clear _norm pointer
81
82 Double_t evaluate() const;
83
84 void initialize();
85 CacheElem *getCache(const RooArgSet *nset) const;
86
87 inline Int_t ij(const Int_t &i, const Int_t &j) const { return (i * _varList.getSize() + j); }
88 int idxmin(const double &m) const;
89 int idxmax(const double &m) const;
90
94 mutable TVectorD *_mref;
95
96 TIterator *_varItr; //! do not persist
98 mutable TMatrixD *_M; //
99
101
103
104 ClassDef(RooMomentMorphFunc, 3) // Your description goes here...
105};
106
107#endif
double Double_t
Definition RtypesCore.h:59
const Bool_t kTRUE
Definition RtypesCore.h:91
#define ClassDef(name, id)
Definition Rtypes.h:325
char name[80]
Definition TGX11.cxx:110
RooAbsCacheElement is the abstract base class for objects to be stored in RooAbsCache cache manager o...
Int_t getSize() const
virtual Bool_t add(const RooAbsArg &var, Bool_t silent=kFALSE)
Add the specified argument to list.
RooAbsRealLValue is the common abstract base class for objects that represent a real value that may a...
RooAbsReal is the common abstract base class for objects that represent a real value and implements f...
Definition RooAbsReal.h:61
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:29
RooChangeTracker is a meta object that tracks value changes in a given set of RooAbsArgs by registeri...
RooListProxy is the concrete proxy for RooArgList objects.
void operModeHook(RooAbsArg::OperMode)
Interface for operation mode change calls.
void calculateFractions(const RooMomentMorphFunc &self, Bool_t verbose=kTRUE) const
CacheElem(RooAbsReal &sumFunc, RooChangeTracker &tracker, const RooArgList &flist)
virtual RooArgList containedArgs(Action)
TIterator * _pdfItr
do not persist
virtual Double_t getVal(const RooArgSet *set=0) const
RooArgSet * _curNormSet
The cache manager.
RooObjCacheManager _cacheMgr
CacheElem * getCache(const RooArgSet *nset) const
void useHorizontalMorphing(bool val)
virtual std::list< Double_t > * binBoundaries(RooAbsRealLValue &, Double_t, Double_t) const
Retrieve bin boundaries if this distribution is binned in obs.
RooAbsReal * sumFunc(const RooArgSet *nset)
virtual Bool_t selfNormalized() const
void setMode(const Setting &setting)
virtual TObject * clone(const char *newname) const
Bool_t isBinnedDistribution(const RooArgSet &obs) const
Tests if the distribution is binned. Unless overridden by derived classes, this always returns false.
int idxmin(const double &m) const
Double_t evaluate() const
Evaluate this PDF / function / constant. Needs to be overridden by all derived classes.
Int_t ij(const Int_t &i, const Int_t &j) const
int idxmax(const double &m) const
virtual std::list< Double_t > * plotSamplingHint(RooAbsRealLValue &obs, Double_t xlo, Double_t xhi) const
Interface for returning an optional hint for initial sampling points when constructing a curve projec...
Class RooObjCacheManager is an implementation of class RooCacheManager<RooAbsCacheElement> and specia...
RooRealVar represents a variable that can be changed from the outside.
Definition RooRealVar.h:39
RooSetProxy is the concrete proxy for RooArgSet objects.
Definition RooSetProxy.h:23
Iterator abstract base class.
Definition TIterator.h:30
Mother of all ROOT objects.
Definition TObject.h:37