Warning, file /include/root/RooAbsAnaConvPdf.h was not indexed
or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016 #ifndef ROO_ABS_ANA_CONV_PDF
0017 #define ROO_ABS_ANA_CONV_PDF
0018
0019
0020 #include "RooAbsPdf.h"
0021 #include "RooRealProxy.h"
0022 #include "RooListProxy.h"
0023 #include "RooDataSet.h"
0024 #include "RooAICRegistry.h"
0025 #include "RooObjCacheManager.h"
0026 #include "RooAbsCacheElement.h"
0027
0028 class RooResolutionModel ;
0029 class RooRealVar ;
0030 class RooConvGenContext ;
0031
0032 class RooAbsAnaConvPdf : public RooAbsPdf {
0033 public:
0034
0035
0036 RooAbsAnaConvPdf() ;
0037 RooAbsAnaConvPdf(const char *name, const char *title,
0038 const RooResolutionModel& model,
0039 RooRealVar& convVar) ;
0040
0041 RooAbsAnaConvPdf(const RooAbsAnaConvPdf& other, const char* name=nullptr);
0042 ~RooAbsAnaConvPdf() override;
0043
0044 Int_t declareBasis(const char* expression, const RooArgList& params) ;
0045 void printMultiline(std::ostream& stream, Int_t contents, bool verbose=false, TString indent= "") const override ;
0046
0047
0048 inline double getCoefNorm(Int_t coefIdx, const RooArgSet& nset, const char* rangeName) const {
0049
0050 return getCoefNorm(coefIdx,&nset,rangeName) ;
0051 }
0052 double getCoefNorm(Int_t coefIdx, const RooArgSet* nset=nullptr, const char* rangeName=nullptr) const {
0053 return getCoefNorm(coefIdx,nset,RooNameReg::ptr(rangeName));
0054 }
0055
0056
0057 Int_t getAnalyticalIntegralWN(RooArgSet& allVars, RooArgSet& analVars, const RooArgSet* normSet, const char* rangeName=nullptr) const override ;
0058 double analyticalIntegralWN(Int_t code, const RooArgSet* normSet, const char* rangeName=nullptr) const override ;
0059
0060
0061 virtual Int_t getCoefAnalyticalIntegral(Int_t coef, RooArgSet& allVars, RooArgSet& analVars, const char* rangeName=nullptr) const ;
0062 virtual double coefAnalyticalIntegral(Int_t coef, Int_t code, const char* rangeName=nullptr) const ;
0063 bool forceAnalyticalInt(const RooAbsArg& dep) const override ;
0064
0065 virtual double coefficient(Int_t basisIndex) const = 0 ;
0066 virtual RooFit::OwningPtr<RooArgSet> coefVars(Int_t coefIdx) const ;
0067
0068 bool isDirectGenSafe(const RooAbsArg& arg) const override ;
0069
0070 void setCacheAndTrackHints(RooArgSet&) override ;
0071
0072 RooAbsGenContext* genContext(const RooArgSet &vars, const RooDataSet *prototype=nullptr,
0073 const RooArgSet* auxProto=nullptr, bool verbose= false) const override ;
0074 virtual bool changeModel(const RooResolutionModel& newModel) ;
0075
0076
0077 RooAbsRealLValue* convVar();
0078
0079 const RooAbsRealLValue* convVar() const {
0080 return const_cast<RooAbsAnaConvPdf*>(this)->convVar();
0081 }
0082
0083 std::unique_ptr<RooAbsArg> compileForNormSet(RooArgSet const &normSet, RooFit::Detail::CompileContext & ctx) const override;
0084
0085 protected:
0086 double getCoefNorm(Int_t coefIdx, const RooArgSet* nset, const TNamed* rangeName) const ;
0087
0088 bool _isCopy ;
0089
0090 double evaluate() const override ;
0091
0092 void makeCoefVarList(RooArgList&) const ;
0093
0094 friend class RooConvGenContext ;
0095
0096 RooRealProxy _model ;
0097 RooRealProxy _convVar ;
0098
0099 RooArgSet* parseIntegrationRequest(const RooArgSet& intSet, Int_t& coefCode, RooArgSet* analVars=nullptr) const ;
0100
0101 RooListProxy _convSet ;
0102 RooArgList _basisList ;
0103
0104
0105 class CacheElem : public RooAbsCacheElement {
0106 public:
0107 RooArgList containedArgs(Action) override {
0108 RooArgList l(_coefVarList) ;
0109 l.add(_normList) ;
0110 return l ;
0111 }
0112
0113 RooArgList _coefVarList ;
0114 RooArgList _normList ;
0115 } ;
0116 mutable RooObjCacheManager _coefNormMgr ;
0117
0118 mutable RooAICRegistry _codeReg ;
0119
0120 ClassDefOverride(RooAbsAnaConvPdf,3)
0121 };
0122
0123 #endif