Logo ROOT  
Reference Guide
TF1Helper.h
Go to the documentation of this file.
1// @(#)root/hist:$Id$
2// Author: Lorenzo Moneta 12/06/07
3
4/**********************************************************************
5 * *
6 * Copyright (c) 2007 LCG ROOT Math Team, CERN/PH-SFT *
7 * *
8 * *
9 **********************************************************************/
10
11// helper functions used internally by TF1
12
13#ifndef ROOT_TF1Helper
14#define ROOT_TF1Helper
15
16#include "TF1.h"
17
18namespace ROOT {
19
20 namespace TF1Helper {
21
22 double IntegralError(TF1 * func, int dim, const double * a, const double * b, const double * params, const double * covmat, double eps);
23
24 /**
25 function class representing the derivative with respect a parameter of a given TF1
26 */
28
29 public:
30
31 TGradientParFunction(int ipar, TF1 * f) :
32 fPar(ipar),
33 fFunc(f)
34 {}
35
36 double operator() (double * x, double *) const
37 {
38 // evaluate gradient vector of functions at point x
39 return fFunc->GradientPar(fPar,x);
40 }
41
42 private:
43
44 unsigned int fPar;
45 mutable TF1 * fFunc;
46 };
47
48
49 } // end namespace TF1Helper
50
51} // end namespace TF1
52
53#endif
#define b(i)
Definition: RSha256.hxx:100
#define f(i)
Definition: RSha256.hxx:104
function class representing the derivative with respect a parameter of a given TF1
Definition: TF1Helper.h:27
double operator()(double *x, double *) const
Definition: TF1Helper.h:36
TGradientParFunction(int ipar, TF1 *f)
Definition: TF1Helper.h:31
1-Dim function class
Definition: TF1.h:211
virtual Double_t GradientPar(Int_t ipar, const Double_t *x, Double_t eps=0.01)
Compute the gradient (derivative) wrt a parameter ipar.
Definition: TF1.cxx:2427
Double_t x[n]
Definition: legend1.C:17
double IntegralError(TF1 *func, Int_t ndim, const double *a, const double *b, const double *params, const double *covmat, double epsilon)
Definition: TF1Helper.cxx:38
VSD Structures.
Definition: StringConv.hxx:21
auto * a
Definition: textangle.C:12