ROOT   Reference Guide
Searching...
No Matches
Go to the documentation of this file.
1/*****************************************************************************
2 * Project: RooFit *
3 * Package: RooFitCore *
4 * File: $Id$
5 * Authors: *
6 * WV, Wouter Verkerke, UC Santa Barbara, verkerke@slac.stanford.edu *
7 * DK, David Kirkby, UC Irvine, dkirkby@uci.edu *
8 * *
9 * Copyright (c) 2000-2005, Regents of the University of California *
11 * *
12 * Redistribution and use in source and binary forms, *
13 * with or without modification, are permitted according to the terms *
15 *****************************************************************************/
18
19#include "RooAbsIntegrator.h"
20#include "RooNumIntConfig.h"
21#include "TString.h"
22
23#include <Math/IFunctionfwd.h>
24
25namespace ROOT {
26namespace Math {
28}
29} // namespace ROOT
30class RooFunctor;
31
33public:
34 // Constructors, assignment etc
36
38
39 bool checkLimits() const override;
40 double integral(const double *yvec = nullptr) override;
41
43 bool setLimits(double *xmin, double *xmax) override;
44
45 bool setUseIntegrandLimits(bool flag) override
46 {
48 return true;
49 }
50
51protected:
53
54 bool _useIntegrandLimits; ///< If true limits of function binding are used
55
56 mutable std::vector<double> _xmin; ///< Lower bound in each dimension
57 mutable std::vector<double> _xmax; ///< Upper bound in each dimension
58 double _epsRel; ///< Relative precision
59 double _epsAbs; ///< Absolute precision
60 Int_t _nmax; ///< Max number of divisions
61 Int_t _nError; ///< Number of error occurrences
62 Int_t _nWarn; ///< Max number of warnings to be issued ;
63 std::unique_ptr<RooFunctor> _rooFunctor; ///<! RooFunctor binding
64 std::unique_ptr<ROOT::Math::IMultiGenFunction> _func; ///<! ROOT::Math multi-parameter function binding
66 TString _intName; ///< Integrand name
67
68 friend class RooNumIntFactory;
69 static void registerIntegrator(RooNumIntFactory &fact);
70};
71
72#endif
RooAbsReal & function()
float xmin
float xmax
Abstract interface for evaluating a real-valued function of one real variable and performing numerica...
Definition RooAbsFunc.h:27
Abstract interface for integrators of real-valued functions that implement the RooAbsFunc interface.
virtual bool setLimits(double *, double *)
Int_t _nmax
Max number of divisions.
bool checkLimits() const override
Check that our integration range is finite and otherwise return false.
bool setUseIntegrandLimits(bool flag) override
Interface function that allows to defer limit definition to integrand definition.
bool _useIntegrandLimits
If true limits of function binding are used.
double integral(const double *yvec=nullptr) override
Evaluate integral at given function binding parameter values.
std::unique_ptr< RooFunctor > _rooFunctor
! RooFunctor binding
bool setLimits(double *xmin, double *xmax) override
Change our integration limits.
std::vector< double > _xmin
Lower bound in each dimension.
double _epsRel
Relative precision.
double _epsAbs
Absolute precision.
TString _intName
Integrand name.
Destructor.
static void registerIntegrator(RooNumIntFactory &fact)
Register RooAdaptiveIntegratorND, its parameters, dependencies and capabilities with RooNumIntFactory...
Int_t _nError
Number of error occurrences.
std::unique_ptr< ROOT::Math::IMultiGenFunction > _func
! ROOT::Math multi-parameter function binding