68struct TF1v5Convert : 
public TF1 {
 
   73      fNpar = 
from.GetNpar();
 
   74      fNdim = 
from.GetNdim();
 
   75      if (
from.fType == 0) {
 
   90         if (
from.GetParameters())
 
   91            fFormula->SetParameters(
from.GetParameters());
 
   94         fParams = std::make_unique<TF1Parameters>(fNpar);
 
   95         fName = 
from.GetName();
 
   96         fTitle = 
from.GetTitle();
 
   98         if (
from.GetParameters())
 
   99            fParams->SetParameters(
from.GetParameters());
 
  103      fType = (EFType)
from.fType;
 
  104      fNpfits = 
from.fNpfits;
 
  106      fChisquare = 
from.fChisquare;
 
  107      fMaximum = 
from.fMaximum;
 
  108      fMinimum = 
from.fMinimum;
 
  113         fParErrors = std::vector<Double_t>(
from.fParErrors, 
from.fParErrors + fNpar);
 
  115         fParMin = std::vector<Double_t>(
from.fParMin, 
from.fParMin + fNpar);
 
  117         fParMax = std::vector<Double_t>(
from.fParMax, 
from.fParMax + fNpar);
 
  118      if (
from.fNsave > 0) {
 
  120         fSave = std::vector<Double_t>(
from.fSave, 
from.fSave + 
from.fNsave);
 
  128      from.TAttLine::Copy(*
this);
 
  129      from.TAttFill::Copy(*
this);
 
  130      from.TAttMarker::Copy(*
this);
 
  138   auto **
target = (TF1v5Convert **)
to;
 
  140   for (
int i = 0; i < 
nobjects; ++i) {
 
 
  205      f->fFunc->InitArgs(
f->fX, 
f->fPar);
 
 
 
  491   fXmin(0), fXmax(0), fNpar(0), fNdim(0), fType(
EFType::kFormula)
 
 
  529         if (formula[i] == 
'(')
 
  531         else if (formula[i] == 
')')
 
  533         else if (formula[i] == 
',' && 
parenCount == 0) {
 
  537               Error(
"TF1", 
"CONV takes 2 arguments. Too many arguments found in : %s", formula);
 
  541         Error(
"TF1", 
"CONV takes 2 arguments. Only one argument found in : %s", formula);
 
  566      fComposition = std::unique_ptr<TF1AbsComposition>(conv);
 
  570      for (
int i = 0; i < 
fNpar; i++)
 
  576      for (
int i = 0; i < 
f1Npar; i++)
 
  585         for (
int i = 0; i < 
f2Npar; i++)
 
  592         for (
int i = 0; i < 
f2Npar; i++)
 
  615      for (
int i = 0; i < 
formDense.Length(); ++i) {
 
  630      if (
xmin == 0 && 
xmax == 1.) 
Info(
"TF1",
"Created TF1NormSum object using the default [0,1] range");
 
  642      for (
int i = 0; i < 
fNpar; i++) {
 
  664      Error(
"TF1", 
"function: %s/%s has dimension %d instead of 1", 
name, formula, 
fNdim);
 
  683   if (!opt) 
return false;
 
  686   if (
option.Contains(
"VEC")) 
return true;
 
 
  720      Info(
"TF1", 
"TF1 has a name starting with a \'*\' - it is for saved TF1 objects in a .C file");
 
  723      Error(
"TF1", 
"requires a proper function name!");
 
  731      Error(
"TF1", 
"No function found with the signature %s(Double_t*,Double_t*)", 
name);
 
 
  820      gROOT->GetListOfFunctions()->Add(
this);
 
 
  851   if (!
gROOT) 
return false;
 
  857         assert(
gROOT->GetListOfFunctions()->FindObject(
this) != 
nullptr);
 
  864      gROOT->GetListOfFunctions()->Add(
this);
 
  872         Warning(
"AddToGlobalList", 
"Function is supposed to be in the global list but it is not present");
 
  875      gROOT->GetListOfFunctions()->Remove(
this);
 
 
  947      rhs.TF1::Copy(*
this);
 
 
  962      if (
gROOT) 
gROOT->GetListOfFunctions()->Remove(
this);
 
 
  974   fXmin(0), fXmax(0), fNpar(0), fNdim(0), fType(
EFType::kFormula)
 
 
  997   Draw(
b ? 
b->GetDrawOption() : 
"");
 
 
 1009   delete((
TF1 &)obj).fHistogram;
 
 1032   ((
TF1 &)obj).fHistogram = 
nullptr;
 
 1033   ((
TF1 &)obj).fMethodCall = 
nullptr;
 
 1036   ((
TF1 &)obj).fFormula   = 
nullptr;
 
 1042   ((
TF1 &)obj).fMethodCall.reset(
m);
 
 1058   ((
TF1 &)obj).fComposition.reset(
comp);
 
 
 1118      Warning(
"Derivative", 
"Function dimension is larger than one");
 
 1126   if (
h <= 0) 
h = 0.001;
 
 1130      wtf.SetParameters(params);
 
 
 1183      Warning(
"Derivative2", 
"Function dimension is larger than one");
 
 1191   if (
h <= 0) 
h = 0.001;
 
 1195      wtf.SetParameters(params);
 
 
 1248      Warning(
"Derivative3", 
"Function dimension is larger than one");
 
 1256   if (
h <= 0) 
h = 0.001;
 
 1260      wtf.SetParameters(params);
 
 
 1343   gPad->IncrementPaletteColor(1, opt);
 
 
 1506#ifdef R__HAS_VECCORE 
 1525         Error(
"EvalPar", 
"Composition function not found");
 
 1527      result = (*fComposition)(
x, params);
 
 
 1544   if (!
gPad->GetView()) {
 
 
 1573   ::Warning(
"TF1::GetCurrent", 
"This function is obsolete and is working only for the current painted functions");
 
 
 1623   if (!logx && 
gPad != 
nullptr) logx = 
gPad->GetLogx();
 
 1630   bm.SetLogScan(logx);
 
 1633   x = - 
bm.FValMinimum();
 
 
 1664   if (!logx && 
gPad != 
nullptr) logx = 
gPad->GetLogx();
 
 1671   bm.SetLogScan(logx);
 
 
 1705   if (!logx && 
gPad != 
nullptr) logx = 
gPad->GetLogx();
 
 1711   bm.SetLogScan(logx);
 
 1714   x = 
bm.FValMinimum();
 
 
 1731      Error(
"GetMinimumNDim", 
"Function of dimension 0 - return Eval(x)");
 
 1732      return (
const_cast<TF1 &
>(*
this))(
x);
 
 1740   if (min == 
nullptr) {
 
 1741      Error(
"GetMinimumNDim", 
"Error creating minimizer %s", 
minimName);
 
 1746   if (epsilon > 0) min->SetTolerance(epsilon);
 
 1759   std::vector<double> 
rmin(ndim);
 
 1760   std::vector<double> 
rmax(ndim);
 
 1762   for (
int i = 0; i < ndim; ++i) {
 
 1763      const char *
xname =  
nullptr;
 
 1768      else if (std::abs(
x[i]) > 1.)
 
 1775         } 
else if (i == 1) {
 
 1793   bool ret = min->Minimize();
 
 1795      Error(
"GetMinimumNDim", 
"Error minimizing function %s", 
GetName());
 
 1797   if (min->X()) std::copy(min->X(), min->X() + ndim, 
x);
 
 1798   double fmin = min->MinValue();
 
 
 1836   bm.SetLogScan(logx);
 
 
 1872   if (!logx && 
gPad != 
nullptr) logx = 
gPad->GetLogx();
 
 1879   brf.SetLogScan(logx);
 
 
 1908      ((
TF1 *)
this)->GetParLimits(i, 
al, 
bl);
 
 
 1922   static char info[64];
 
 
 1959   if (
fNDF <= 0) 
return 0;
 
 
 2012   for (i = 0; i < 
npx; i++) {
 
 2018      integral[i + 1] = integral[i] + 
integ;
 
 2022      Warning(
"GetQuantiles", 
"function:%s has %d negative values: abs assumed",
 
 2024   if (integral[
npx] == 0) {
 
 2025      Error(
"GetQuantiles", 
"Integral of function is zero");
 
 2030   for (i = 1; i <= 
npx; i++) integral[i] /= 
total;
 
 2034   for (i = 0; i < 
npx; i++) {
 
 2036      const Double_t r2 = integral[i + 1] - integral[i];
 
 2038      gamma[i] = (2 * 
r2 - 4 * 
r1) / (
dx * 
dx);
 
 2039      beta[i]  = 
r2 / 
dx - gamma[i] * 
dx;
 
 2063         const Double_t fac = -2.*gamma[bin] * 
rr / beta[bin] / beta[bin];
 
 2064         if (
fac != 0 && 
fac <= 1)
 
 2065            xx = (-beta[bin] + 
TMath::Sqrt(beta[bin] * beta[bin] + 2 * gamma[bin] * 
rr)) / gamma[bin];
 
 2066         else if (beta[bin] != 0.)
 
 2067            xx = 
rr / beta[bin];
 
 2068         q[i] = alpha[bin] + 
xx;
 
 2071         if (integral[bin + 1] == 
r) 
q[i] += 
dx;
 
 
 2106         Info(
"GetRandom", 
"Use log scale for tabulating the integral in [%f,%f] with %d points", 
fXmin, 
fXmax, 
fNpx);
 
 2110   std::vector<Double_t> 
xx(
fNpx + 1);
 
 2111   for (i = 0; i < 
fNpx; i++) {
 
 2115   for (i = 0; i < 
fNpx; i++) {
 
 2131      Error(
"GetRandom", 
"Integral of function is zero");
 
 2135   for (i = 1; i <= 
fNpx; i++) { 
 
 2142   for (i = 0; i < 
fNpx; i++) {
 
 
 2287   for (
int i = 0; i < ndim; ++i) {
 
 2291      } 
else if (i == 1) {
 
 2294      } 
else if (i == 2) {
 
 
 2346   if (
fSave.empty()) 
return 0;
 
 2363            xlow = 
xaxis->GetBinCenter(bin);
 
 2364            xup  = 
xaxis->GetBinCenter(bin + 1);
 
 2368            xlow = 
xaxis->GetBinCenter(bin - 1);
 
 2369            xup  = 
xaxis->GetBinCenter(bin);
 
 2374         y  = ((xup * ylow - xlow * yup) + 
x * (yup - ylow)) / 
dx;
 
 2385   if (
dx <= 0) 
return 0;
 
 2391   yup  = 
fSave[bin + 1];
 
 2392   y    = ((xup * ylow - xlow * yup) + 
x * (yup - ylow)) / 
dx;
 
 
 2403   if (!
h) 
return nullptr;
 
 2404   return h->GetXaxis();
 
 
 2414   if (!
h) 
return nullptr;
 
 2415   return h->GetYaxis();
 
 
 2425   if (!
h) 
return nullptr;
 
 2426   return h->GetZaxis();
 
 
 2472      std::fill(grad, grad + 
fNpar, 0.);
 
 
 2487      if (params) args[1] = (
Longptr_t)params;
 
 
 2501   if (!
gROOT->GetListOfFunctions()->FindObject(
"gaus")) {
 
 2502      f1 = 
new TF1(
"gaus", 
"gaus", -1, 1);
 
 2504      f1 = 
new TF1(
"gausn", 
"gausn", -1, 1);
 
 2506      f1 = 
new TF1(
"landau", 
"landau", -1, 1);
 
 2508      f1 = 
new TF1(
"landaun", 
"landaun", -1, 1);
 
 2510      f1 = 
new TF1(
"expo", 
"expo", -1, 1);
 
 2512      for (
Int_t i = 0; i < 10; i++) {
 
 
 2543         Warning(
"analytical integral not available for %s - with number %d  compute numerical integral", 
GetName(), 
GetNumber());
 
 
 
 2640      error = 
iod.Error();
 
 2641      status = 
iod.Status();
 
 2652      error = 
iod.Error();
 
 2653      status = 
iod.Status();
 
 2657      Warning(
"IntegralOneDim", 
"Error found in integrating function %s in [%f,%f] using %s. Result = %f +/- %f  - status = %d", 
GetName(), 
a, 
b, 
igName.c_str(), 
result, error, status);
 
 2659      for (
int ipar = 0; ipar < 
GetNpar(); ++ipar) {
 
 2664      Info(
"IntegralOneDim", 
"%s", 
msg.Data());
 
 
 2784      wf1.SetParameters(params);
 
 2787   return gli.Integral(
a, 
b);
 
 
 2804      Warning(
"IntegralMultiple", 
"failed code=%d, ", 
ifail);
 
 
 2903   } 
else if (
fType >  0) {
 
 2905         printf(
"Interpreted based function: %s(double *x, double *p).  Ndim = %d, Npar = %d  \n", 
GetName(), 
GetNdim(),
 
 2910            printf(
"fComposition not found!\n"); 
 
 2913            printf(
"Compiled based function: %s  based on a functor object.  Ndim = %d, Npar = %d\n", 
GetName(),
 
 2916            printf(
"Function based on a list of points from a compiled based function: %s.  Ndim = %d, Npar = %d, Npx " 
 2920               Warning(
"Print", 
"Function %s is based on a list of points but list is empty", 
GetName());
 
 2928            printf(
"List of  Parameters: \n");
 
 2929            for (
int i = 0; i < 
fNpar; ++i)
 
 2932         if (!
fSave.empty()) {
 
 2934            printf(
"List of  Saved points (N=%d): \n", 
int(
fSave.size()));
 
 2942      printf(
"Contained histogram\n");
 
 
 2960   if (opt.Contains(
"sames"))
 
 2962   else if (opt.Contains(
"same"))
 
 2966   opt.ReplaceAll(
' ', 
"");
 
 3034   if (opt.Length() == 0) {
 
 
 3101         for (i = 0; i <= 
fNpx; i++) {
 
 3122   for (i = 1; i <= 
fNpx; i++) {
 
 
 3180            xv[0]    = 
h->GetXaxis()->GetBinCenter(i);
 
 
 3225      out << 
"double " << 
GetName() << 
"(double xv) {" << std::endl;
 
 3227      out << 
"   double x[" << 
fNpx << 
"] = {" << std::endl;
 
 3230      for (i = 0; i < 
fNpx; i++) {
 
 3232         if (i < 
fNpx - 1) out << 
", ";
 
 3240      out << 
"   };" << std::endl;
 
 3241      out << 
"   double y[" << 
fNpx << 
"] = {" << std::endl;
 
 3244      for (i = 0; i < 
fNpx; i++) {
 
 3246         if (i < 
fNpx - 1) out << 
", ";
 
 3254      out << 
"   };" << std::endl;
 
 3255      out << 
"   if (xv<x[0]) return y[0];" << std::endl;
 
 3256      out << 
"   if (xv>x[" << 
fNpx - 1 << 
"]) return y[" << 
fNpx - 1 << 
"];" << std::endl;
 
 3257      out << 
"   int i, j=0;" << std::endl;
 
 3258      out << 
"   for (i=1; i<" << 
fNpx << 
"; i++) { if (xv < x[i]) break; j++; }" << std::endl;
 
 3259      out << 
"   return y[j] + (y[j + 1] - y[j]) / (x[j + 1] - x[j]) * (xv - x[j]);" << std::endl;
 
 3260      out << 
"}" << std::endl;
 
 3264   out << 
"   " << std::endl;
 
 3277   const char *
addToGlobList = 
fParent ? 
", TF1::EAddToList::kNo" : 
", TF1::EAddToList::kDefault";
 
 3282         out << 
"   " << 
f1Name.Data() << 
"->SetNpx(" << 
fNpx << 
");" << std::endl;
 
 3286      out << 
"    //The original function : " << 
GetTitle() << 
" had originally been created by:" << std::endl;
 
 3289      out << 
"   " << 
f1Name.Data() << 
"->SetRange(" << 
fXmin << 
"," << 
fXmax << 
");" << std::endl;
 
 3293         out << 
"   " << 
f1Name.Data() << 
"->SetNpx(" << 
fNpx << 
");" << std::endl;
 
 3299      for (i = 0; i <= 
fNpx; i++) {
 
 3302         out << 
"   " << 
f1Name.Data() << 
"->SetSavedPoint(" << i << 
"," << save << 
");" << std::endl;
 
 3304      out << 
"   " << 
f1Name.Data() << 
"->SetSavedPoint(" << 
fNpx + 1 << 
"," << 
fXmin << 
");" << std::endl;
 
 3305      out << 
"   " << 
f1Name.Data() << 
"->SetSavedPoint(" << 
fNpx + 2 << 
"," << 
fXmax << 
");" << std::endl;
 
 3309      out << 
"   " << 
f1Name.Data() << 
"->SetBit(TF1::kNotDraw);" << std::endl;
 
 3317      out << 
"   " << 
f1Name.Data() << 
"->SetChisquare(" << 
GetChisquare() << 
");" << std::endl;
 
 3318      out << 
"   " << 
f1Name.Data() << 
"->SetNDF(" << 
GetNDF() << 
");" << std::endl;
 
 3325   for (i = 0; i < 
GetNpar(); i++) {
 
 3326      out << 
"   " << 
f1Name.Data() << 
"->SetParameter(" << i << 
"," << 
GetParameter(i) << 
");" << std::endl;
 
 3327      out << 
"   " << 
f1Name.Data() << 
"->SetParError(" << i << 
"," << 
GetParError(i) << 
");" << std::endl;
 
 3329      out << 
"   " << 
f1Name.Data() << 
"->SetParLimits(" << i << 
"," << 
parmin << 
"," << 
parmax << 
");" << std::endl;
 
 3332      out << 
"   " << 
f1Name.Data() << 
"->Draw(" 
 
 3359      Warning(
"SetFitResult", 
"Empty Fit result - nothing is set in TF1");
 
 3363      Error(
"SetFitResult", 
"Invalid Fit result passed - number of parameter is %d , different than TF1::GetNpar() = %d", 
npar, 
result.NPar());
 
 3377      if (ipar < 0) 
continue;
 
 3380      if (ipar < (
int) 
result.Errors().size())
 
 
 3472      fFormula->SetParNames(
name0, 
name1, 
name2, 
name3, 
name4, 
name5, 
name6, 
name7, 
name8, 
name9, 
name10);
 
 3474      fParams->SetParNames(
name0, 
name1, 
name2, 
name3, 
name4, 
name5, 
name6, 
name7, 
name8, 
name9, 
name10);
 
 
 3544   if (
fSave.empty()) {
 
 
 3573   if (
b.IsReading()) {
 
 3585            gROOT->GetListOfFunctions()->Add(
this);
 
 3593         ((TF1v5Convert *)
this)->Convert(
fold);
 
 
 3711   giod.SetFunction(func);
 
 3712   giod.SetRelTolerance(epsilon);
 
 3716      Error(
"Moment", 
"Integral zero over range");
 
 
 3745   giod.SetFunction(func);
 
 3746   giod.SetRelTolerance(epsilon);
 
 3750      Error(
"Moment", 
"Integral zero over range");
 
 
 3831   gli.GetWeightVectors(
x, 
w);
 
 
 3848   for (
unsigned int i = 0; i < 
fParNames.size(); ++i) {
 
 
 
 
 
 
 
 
 
 
Double_t AnalyticalIntegral(TF1 *f, Double_t a, Double_t b)
 
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
 
bool R__SetClonesArrayTF1Updater(TF1Updater_t func)
 
TF1::EAddToList GetGlobalListOption(Option_t *opt)
 
int R__RegisterTF1UpdaterTrigger
 
void(*)(Int_t nobjects, TObject **from, TObject **to) TF1Updater_t
 
static Double_t gErrorTF1
 
static void R__v5TF1Updater(Int_t nobjects, TObject **from, TObject **to)
 
bool GetVectorizedOption(Option_t *opt)
 
void GetParameters(TFitEditor::FuncParams_t &pars, TF1 *func)
Stores the parameters of the given function into pars.
 
static unsigned int total
 
Option_t Option_t SetLineWidth
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t hmin
 
Option_t Option_t SetFillStyle
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t hmax
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t target
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t np
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t r
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t result
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void on
 
Option_t Option_t SetLineColor
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void value
 
Option_t Option_t TPoint TPoint const char x2
 
Option_t Option_t TPoint TPoint const char x1
 
R__EXTERN TVirtualMutex * gROOTMutex
 
R__EXTERN TRandom * gRandom
 
R__EXTERN TStyle * gStyle
 
#define R__LOCKGUARD(mutex)
 
double operator()(double x) const
 
GFunc(const TF1 *function, double y)
 
GInverseFuncNdim(TF1 *function)
 
double operator()(const double *x) const
 
double operator()(double x) const
 
GInverseFunc(const TF1 *function)
 
class containing the result of the fit and all the related information (fitted parameter values,...
 
Class for adaptive quadrature integration in multi-dimensions using rectangular regions.
 
User class for performing function minimization.
 
Class for finding the root of a one dimensional function using the Brent algorithm.
 
static ROOT::Math::Minimizer * CreateMinimizer(const std::string &minimizerType="", const std::string &algoType="")
static method to create the corresponding Minimizer given the string Supported Minimizers types are: ...
 
Functor1D class for one-dimensional functions.
 
User class for performing function integration.
 
User class for performing function integration.
 
Interface (abstract class) for generic functions objects of one-dimension Provides a method to evalua...
 
static IntegrationMultiDim::Type DefaultIntegratorType()
 
static unsigned int DefaultNCalls()
 
static double DefaultRelTolerance()
 
static double DefaultAbsTolerance()
 
User class for performing multidimensional integration.
 
static double DefaultAbsTolerance()
 
static double DefaultRelTolerance()
 
static IntegrationOneDim::Type DefaultIntegratorType()
 
User Class for performing numerical integration of a function in one dimension.
 
static std::string GetName(IntegrationOneDim::Type)
static function to get a string from the enumeration
 
static const std::string & DefaultMinimizerType()
 
static const std::string & DefaultMinimizerAlgo()
 
Abstract Minimizer class, defining the interface for the various minimizer (like Minuit2,...
 
Param Functor class for Multidimensional functions.
 
User class for calculating the derivatives of a function.
 
Template class to wrap any C++ callable object which takes one argument i.e.
 
Template class to wrap any C++ callable object implementing operator() (const double * x) in a multi-...
 
Class to Wrap a ROOT Function class (like TF1) in a IParamFunction interface of one dimensions to be ...
 
Array of doubles (64 bits per element).
 
const Double_t * GetArray() const
 
virtual Color_t GetLabelColor() const
 
virtual Int_t GetNdivisions() const
 
virtual Float_t GetLabelOffset() const
 
virtual void SetLabelSize(Float_t size=0.04)
Set size of axis labels.
 
virtual Style_t GetLabelFont() const
 
virtual void SetLabelOffset(Float_t offset=0.005)
Set distance between the axis and the labels.
 
virtual void SetLabelFont(Style_t font=62)
Set labels' font.
 
virtual Float_t GetLabelSize() const
 
virtual void SetNdivisions(Int_t n=510, Bool_t optim=kTRUE)
Set the number of divisions for this axis.
 
virtual void SetLabelColor(Color_t color=1, Float_t alpha=1.)
Set color of labels.
 
Fill Area Attributes class.
 
virtual Color_t GetFillColor() const
Return the fill area color.
 
void Copy(TAttFill &attfill) const
Copy this fill attributes to a new TAttFill.
 
virtual Style_t GetFillStyle() const
Return the fill area style.
 
virtual void SetFillColor(Color_t fcolor)
Set the fill area color.
 
virtual void SaveFillAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1001)
Save fill attributes as C++ statement(s) on output stream out.
 
virtual Color_t GetLineColor() const
Return the line color.
 
virtual void SetLineStyle(Style_t lstyle)
Set the line style.
 
virtual Width_t GetLineWidth() const
Return the line width.
 
virtual void SetLineColor(Color_t lcolor)
Set the line color.
 
virtual Style_t GetLineStyle() const
Return the line style.
 
void Copy(TAttLine &attline) const
Copy this line attributes to a new TAttLine.
 
virtual void SaveLineAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1, Int_t widdef=1)
Save line attributes as C++ statement(s) on output stream out.
 
virtual void SaveMarkerAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1, Int_t sizdef=1)
Save line attributes as C++ statement(s) on output stream out.
 
virtual Style_t GetMarkerStyle() const
Return the marker style.
 
virtual void SetMarkerColor(Color_t mcolor=1)
Set the marker color.
 
virtual Color_t GetMarkerColor() const
Return the marker color.
 
virtual Size_t GetMarkerSize() const
Return the marker size.
 
void Copy(TAttMarker &attmarker) const
Copy this marker attributes to a new TAttMarker.
 
Class to manage histogram axis.
 
const char * GetTitle() const override
Returns title of object.
 
void SaveAttributes(std::ostream &out, const char *name, const char *subname) override
Save axis attributes as C++ statement(s) on output stream out.
 
virtual void SetLimits(Double_t xmin, Double_t xmax)
 
Using a TBrowser one can browse all ROOT objects.
 
Buffer base class used for serializing objects.
 
void * New(ENewType defConstructor=kClassNew, Bool_t quiet=kFALSE) const
Return a pointer to a newly allocated object of this class.
 
Class wrapping convolution of two functions.
 
const char * GetParName(Int_t ipar) const
 
Class adding two functions: c1*f1+c2*f2.
 
std::vector< std::string > fParNames
 
Int_t GetParNumber(const char *name) const
Returns the parameter number given a name not very efficient but list of parameters is typically smal...
 
ROOT::Math::IGenFunction * Clone() const override
Clone a function.
 
Double_t EvalFirstMom(Double_t x)
 
Double_t DoEval(Double_t x) const override
implementation of the evaluation function. Must be implemented by derived classes
 
Double_t EvalNMom(Double_t x) const
 
TF1_EvalWrapper(TF1 *f, const Double_t *par, bool useAbsVal, Double_t n=1, Double_t x0=0)
 
std::unique_ptr< TF1FunctorPointer > fFunctor
! Functor object to wrap any C++ callable object
 
virtual Double_t GetMinimumX(Double_t xmin=0, Double_t xmax=0, Double_t epsilon=1.E-10, Int_t maxiter=100, Bool_t logx=false) const
Returns the X value corresponding to the minimum value of the function on the (xmin,...
 
virtual Double_t GetMinimum(Double_t xmin=0, Double_t xmax=0, Double_t epsilon=1.E-10, Int_t maxiter=100, Bool_t logx=false) const
Returns the minimum value of the function on the (xmin, xmax) interval.
 
virtual Double_t GetXmax() const
 
virtual void ReleaseParameter(Int_t ipar)
Release parameter number ipar during a fit operation.
 
virtual void SetParError(Int_t ipar, Double_t error)
Set error for parameter number ipar.
 
static void RejectPoint(Bool_t reject=kTRUE)
Static function to set the global flag to reject points the fgRejectPoint global flag is tested by al...
 
EAddToList
Add to list behavior.
 
virtual Double_t Derivative(Double_t x, Double_t *params=nullptr, Double_t epsilon=0.001) const
Returns the first derivative of the function at point x, computed by Richardson's extrapolation metho...
 
virtual Int_t GetNumber() const
 
virtual Int_t GetNDF() const
Return the number of degrees of freedom in the fit the fNDF parameter has been previously computed du...
 
std::vector< Double_t > fParErrors
Array of errors of the fNpar parameters.
 
Int_t fNdim
Function dimension.
 
static void CalcGaussLegendreSamplingPoints(Int_t num, Double_t *x, Double_t *w, Double_t eps=3.0e-11)
Type safe interface (static method) The number of sampling points are taken from the TGraph.
 
static void AbsValue(Bool_t reject=kTRUE)
Static function: set the fgAbsValue flag.
 
virtual TH1 * GetHistogram() const
Return a pointer to the histogram used to visualise the function Note that this histogram is managed ...
 
virtual void GetParLimits(Int_t ipar, Double_t &parmin, Double_t &parmax) const
Return limits for parameter ipar.
 
Int_t fNpar
Number of parameters.
 
TAxis * GetYaxis() const
Get y axis of the function.
 
virtual void SetNDF(Int_t ndf)
Set the number of degrees of freedom ndf should be the number of points used in a fit - the number of...
 
virtual Double_t GetParError(Int_t ipar) const
Return value of parameter number ipar.
 
static std::atomic< Bool_t > fgAddToGlobList
 
virtual Double_t IntegralError(Double_t a, Double_t b, const Double_t *params=nullptr, const Double_t *covmat=nullptr, Double_t epsilon=1.E-2)
Return Error on Integral of a parametric function between a and b due to the parameter uncertainties ...
 
virtual void SetChisquare(Double_t chi2)
 
virtual Double_t IntegralFast(Int_t num, Double_t *x, Double_t *w, Double_t a, Double_t b, Double_t *params=nullptr, Double_t epsilon=1e-12)
Gauss-Legendre integral, see CalcGaussLegendreSamplingPoints.
 
Double_t fNormIntegral
Integral of the function before being normalized.
 
Double_t GetChisquare() const
Return the Chisquare after fitting. See ROOT::Fit::FitResult::Chi2()
 
virtual void SetMaximum(Double_t maximum=-1111)
Set the maximum value along Y for this function In case the function is already drawn,...
 
void Print(Option_t *option="") const override
This method must be overridden when a class wants to print itself.
 
virtual TH1 * CreateHistogram()
 
Double_t fXmin
Lower bounds for the range.
 
std::unique_ptr< TMethodCall > fMethodCall
! Pointer to MethodCall in case of interpreted function
 
virtual void Update()
Called by functions such as SetRange, SetNpx, SetParameters to force the deletion of the associated h...
 
virtual Double_t GetProb() const
Return the fit probability.
 
virtual Double_t GradientPar(Int_t ipar, const Double_t *x, Double_t eps=0.01)
Compute the gradient (derivative) wrt a parameter ipar.
 
TAxis * GetZaxis() const
Get z axis of the function. (In case this object is a TF2 or TF3)
 
virtual Double_t GetRandom(TRandom *rng=nullptr, Option_t *opt=nullptr)
Return a random number following this function shape.
 
virtual void SetRange(Double_t xmin, Double_t xmax)
Initialize the upper and lower bounds to draw the function.
 
virtual Int_t GetNpar() const
 
std::vector< Double_t > fBeta
! Array beta. is approximated by x = alpha +beta*r *gamma*r**2
 
Int_t fNDF
Number of degrees of freedom in the fit.
 
TH1 * fHistogram
! Pointer to histogram used for visualisation
 
std::unique_ptr< TF1AbsComposition > fComposition
Pointer to composition (NSUM or CONV)
 
virtual void SetParErrors(const Double_t *errors)
Set errors for all active parameters when calling this function, the array errors must have at least ...
 
virtual TH1 * DoCreateHistogram(Double_t xmin, Double_t xmax, Bool_t recreate=kFALSE)
Create histogram with bin content equal to function value computed at the bin center This histogram w...
 
Int_t fNpfits
Number of points used in the fit.
 
virtual Double_t Derivative2(Double_t x, Double_t *params=nullptr, Double_t epsilon=0.001) const
Returns the second derivative of the function at point x, computed by Richardson's extrapolation meth...
 
static void SetCurrent(TF1 *f1)
Static function setting the current function.
 
std::vector< Double_t > fAlpha
! Array alpha. for each bin in x the deconvolution r of fIntegral
 
virtual Double_t Integral(Double_t a, Double_t b, Double_t epsrel=1.e-12)
IntegralOneDim or analytical integral.
 
void SetTitle(const char *title="") override
Set function title if title has the form "fffffff;xxxx;yyyy", it is assumed that the function title i...
 
std::unique_ptr< TFormula > fFormula
Pointer to TFormula in case when user define formula.
 
virtual void SetParNames(const char *name0="", const char *name1="", const char *name2="", const char *name3="", const char *name4="", const char *name5="", const char *name6="", const char *name7="", const char *name8="", const char *name9="", const char *name10="")
Set up to 10 parameter names.
 
static Double_t DerivativeError()
Static function returning the error of the last call to the of Derivative's functions.
 
std::vector< Double_t > fParMin
Array of lower limits of the fNpar parameters.
 
static void InitStandardFunctions()
Create the basic function objects.
 
Double_t fMaximum
Maximum value for plotting.
 
virtual void SetNpx(Int_t npx=100)
Set the number of points used to draw the function.
 
virtual Double_t * GetParameters() const
 
Double_t fMinimum
Minimum value for plotting.
 
int TermCoeffLength(TString &term)
 
static Bool_t fgRejectPoint
 
void Copy(TObject &f1) const override
Copy this F1 to a new F1.
 
void Streamer(TBuffer &) override
Stream a class object.
 
virtual void SetNumberFitPoints(Int_t npfits)
 
void Paint(Option_t *option="") override
Paint this function with its current attributes.
 
TF1 & operator=(const TF1 &rhs)
Operator =.
 
virtual Int_t GetNumberFreeParameters() const
Return the number of free parameters.
 
virtual Double_t Moment(Double_t n, Double_t a, Double_t b, const Double_t *params=nullptr, Double_t epsilon=0.000001)
Return nth moment of function between a and b.
 
virtual Double_t CentralMoment(Double_t n, Double_t a, Double_t b, const Double_t *params=nullptr, Double_t epsilon=0.000001)
Return nth central moment of function between a and b (i.e the n-th moment around the mean value)
 
Double_t fChisquare
Function fit chisquare.
 
virtual void InitArgs(const Double_t *x, const Double_t *params)
Initialize parameters addresses.
 
virtual Double_t IntegralMultiple(Int_t n, const Double_t *a, const Double_t *b, Int_t maxpts, Double_t epsrel, Double_t epsabs, Double_t &relerr, Int_t &nfnevl, Int_t &ifail)
This function computes, to an attempted specified accuracy, the value of the integral.
 
Int_t DistancetoPrimitive(Int_t px, Int_t py) override
Compute distance from point px,py to a function.
 
Bool_t fNormalized
Normalization option (false by default)
 
void Draw(Option_t *option="") override
Draw this function with its current attributes.
 
virtual void SetMinimum(Double_t minimum=-1111)
Set the minimum value along Y for this function In case the function is already drawn,...
 
virtual void GetRange(Double_t *xmin, Double_t *xmax) const
Return range of a generic N-D function.
 
void Browse(TBrowser *b) override
Browse.
 
virtual const char * GetParName(Int_t ipar) const
 
~TF1() override
TF1 default destructor.
 
virtual Double_t EvalPar(const Double_t *x, const Double_t *params=nullptr)
Evaluate function with given coordinates and parameters.
 
Int_t fNpx
Number of points used for the graphical representation.
 
virtual void SetParLimits(Int_t ipar, Double_t parmin, Double_t parmax)
Set lower and upper limits for parameter ipar.
 
void DoInitialize(EAddToList addToGlobList)
Common initialization of the TF1.
 
virtual Double_t GetX(Double_t y, Double_t xmin=0, Double_t xmax=0, Double_t epsilon=1.E-10, Int_t maxiter=100, Bool_t logx=false) const
Returns the X value corresponding to the function value fy for (xmin<x<xmax).
 
static TF1 * GetCurrent()
Static function returning the current function being processed.
 
virtual Int_t GetQuantiles(Int_t nprobSum, Double_t *q, const Double_t *probSum)
Compute Quantiles for density distribution of this function.
 
virtual void SetParName(Int_t ipar, const char *name)
Set name of parameter number ipar.
 
char * GetObjectInfo(Int_t px, Int_t py) const override
Redefines TObject::GetObjectInfo.
 
void ExecuteEvent(Int_t event, Int_t px, Int_t py) override
Execute action corresponding to one event.
 
virtual Double_t GetSave(const Double_t *x)
Get value corresponding to X in array of fSave values.
 
static std::atomic< Bool_t > fgAbsValue
 
TF1()
TF1 default constructor.
 
virtual TF1 * DrawCopy(Option_t *option="") const
Draw a copy of this function with its current attributes.
 
std::vector< Double_t > fParMax
Array of upper limits of the fNpar parameters.
 
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save primitive as a C++ statement(s) on output stream out.
 
virtual Bool_t IsValid() const
Return kTRUE if the function is valid.
 
static Bool_t DefaultAddToGlobalList(Bool_t on=kTRUE)
Static method to add/avoid to add automatically functions to the global list (gROOT->GetListOfFunctio...
 
std::vector< Double_t > fSave
Array of fNsave function values.
 
static Bool_t RejectedPoint()
See TF1::RejectPoint above.
 
void DefineNSUMTerm(TObjArray *newFuncs, TObjArray *coeffNames, TString &fullFormula, TString &formula, int termStart, int termEnd, Double_t xmin, Double_t xmax)
Helper functions for NSUM parsing.
 
std::vector< Double_t > fGamma
! Array gamma.
 
TObject * fParent
! Parent object hooking this function (if one)
 
virtual Double_t GetMinMaxNDim(Double_t *x, Bool_t findmax, Double_t epsilon=0, Int_t maxiter=0) const
Find the minimum of a function of whatever dimension.
 
virtual void DrawF1(Double_t xmin, Double_t xmax, Option_t *option="")
Draw function between xmin and xmax.
 
Bool_t ComputeCdfTable(Option_t *opt)
Compute the cumulative function at fNpx points between fXmin and fXmax.
 
virtual void SetParameters(const Double_t *params)
 
virtual TObject * DrawIntegral(Option_t *option="al")
Draw integral of this function.
 
std::vector< Double_t > fIntegral
! Integral of function binned on fNpx bins
 
virtual TObject * DrawDerivative(Option_t *option="al")
Draw derivative of this function.
 
virtual Double_t Eval(Double_t x, Double_t y=0, Double_t z=0, Double_t t=0) const
Evaluate this function.
 
virtual Double_t GetMaximum(Double_t xmin=0, Double_t xmax=0, Double_t epsilon=1.E-10, Int_t maxiter=100, Bool_t logx=false) const
Returns the maximum value of the function.
 
std::unique_ptr< TF1Parameters > fParams
Pointer to Function parameters object (exists only for not-formula functions)
 
virtual void SetParameter(Int_t param, Double_t value)
 
virtual Double_t Derivative3(Double_t x, Double_t *params=nullptr, Double_t epsilon=0.001) const
Returns the third derivative of the function at point x, computed by Richardson's extrapolation metho...
 
virtual void Save(Double_t xmin, Double_t xmax, Double_t ymin, Double_t ymax, Double_t zmin, Double_t zmax)
Save values of function in array fSave.
 
TObject * Clone(const char *newname=nullptr) const override
Make a complete copy of the underlying object.
 
@ kFormula
Formula functions which can be stored,.
 
@ kPtrScalarFreeFcn
Pointer to scalar free function,.
 
@ kTemplScalar
TemplScalar functors evaluating on scalar parameters.
 
@ kTemplVec
Vectorized free functions or TemplScalar functors evaluating on vectorized parameters,...
 
@ kInterpreted
Interpreted functions constructed by name,.
 
virtual void SetSavedPoint(Int_t point, Double_t value)
Restore value of function saved at point.
 
virtual void FixParameter(Int_t ipar, Double_t value)
Fix the value of a parameter for a fit operation The specified value will be used in the fit and the ...
 
Double_t fXmax
Upper bounds for the range.
 
virtual Double_t GetMaximumX(Double_t xmin=0, Double_t xmax=0, Double_t epsilon=1.E-10, Int_t maxiter=100, Bool_t logx=false) const
Returns the X value corresponding to the maximum value of the function.
 
TClass * IsA() const override
 
virtual Int_t GetNdim() const
 
virtual Double_t GetXmin() const
 
virtual Bool_t AddToGlobalList(Bool_t on=kTRUE)
Add to global list of functions (gROOT->GetListOfFunctions() ) return previous status (true if the fu...
 
virtual Double_t IntegralOneDim(Double_t a, Double_t b, Double_t epsrel, Double_t epsabs, Double_t &err)
Return Integral of function between a and b using the given parameter values and relative and absolut...
 
virtual Double_t GetParameter(Int_t ipar) const
 
virtual void SetFitResult(const ROOT::Fit::FitResult &result, const Int_t *indpar=nullptr)
Set the result from the fit parameter values, errors, chi2, etc... Optionally a pointer to a vector (...
 
TAxis * GetXaxis() const
Get x axis of the function.
 
A TGraph is an object made of two arrays X and Y with npoints each.
 
void Draw(Option_t *chopt="") override
Draw this graph with its current attributes.
 
1-D histogram with a double per channel (see TH1 documentation)
 
TH1 is the base class of all histogram classes in ROOT.
 
virtual void SetDirectory(TDirectory *dir)
By default, when a histogram is created, it is added to the list of histogram objects in the current ...
 
Int_t DistancetoPrimitive(Int_t px, Int_t py) override
Compute distance from point px,py to a line.
 
void SetTitle(const char *title) override
Change/set the title.
 
virtual Double_t GetMinimumStored() const
 
@ kLogX
X-axis in log scale.
 
@ kNoStats
Don't draw stats box.
 
@ kIsZoomed
Bit set when zooming on Y axis.
 
void Print(Option_t *option="") const override
Print some global quantities for this histogram.
 
virtual Double_t GetMaximum(Double_t maxval=FLT_MAX) const
Return maximum value smaller than maxval of bins in the range, unless the value has been overridden b...
 
virtual void SetMaximum(Double_t maximum=-1111)
 
virtual void SetMinimum(Double_t minimum=-1111)
 
void Paint(Option_t *option="") override
Control routine to paint any kind of histograms.
 
virtual Double_t GetMaximumStored() const
 
void ExecuteEvent(Int_t event, Int_t px, Int_t py) override
Execute action corresponding to one event.
 
TObject * Clone(const char *newname="") const override
Make a complete copy of the underlying object.
 
virtual Double_t GetMinimum(Double_t minval=-FLT_MAX) const
Return minimum value larger than minval of bins in the range, unless the value has been overridden by...
 
Method or function calling interface.
 
The TNamed class is the base class for all named ROOT classes.
 
TObject * Clone(const char *newname="") const override
Make a clone of an object using the Streamer facility.
 
void Copy(TObject &named) const override
Copy this to obj.
 
virtual void SetTitle(const char *title="")
Set the title of the TNamed.
 
const char * GetName() const override
Returns name of object.
 
const char * GetTitle() const override
Returns title of object.
 
Collectable string class.
 
Mother of all ROOT objects.
 
R__ALWAYS_INLINE Bool_t TestBit(UInt_t f) const
 
virtual void RecursiveRemove(TObject *obj)
Recursively remove this object from a list.
 
virtual void Warning(const char *method, const char *msgfmt,...) const
Issue warning message.
 
virtual void AppendPad(Option_t *option="")
Append graphics object to current pad.
 
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
 
virtual Bool_t InheritsFrom(const char *classname) const
Returns kTRUE if object inherits from class "classname".
 
virtual void Error(const char *method, const char *msgfmt,...) const
Issue error message.
 
@ kCanDelete
if object in a list can be deleted
 
virtual void Info(const char *method, const char *msgfmt,...) const
Issue info message.
 
This is the base class for the ROOT Random number generators.
 
Double_t Rndm() override
Machine independent random number generator.
 
virtual Double_t Uniform(Double_t x1=1)
Returns a uniform deviate on the interval (0, x1).
 
void ToLower()
Change string to lower-case.
 
const char * Data() const
 
TString & ReplaceAll(const TString &s1, const TString &s2)
 
void ToUpper()
Change string to upper case.
 
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
 
Bool_t Contains(const char *pat, ECaseCompare cmp=kExact) const
 
Color_t GetFuncColor() const
 
Width_t GetFuncWidth() const
 
Style_t GetFuncStyle() const
 
small helper class to store/restore gPad context in TPad methods
 
@ kGAUSS
simple Gauss integration method with fixed rule
 
@ kADAPTIVE
adaptive multi-dimensional integration
 
Namespace for new Math classes and functions.
 
double IntegralError(TF1 *func, Int_t ndim, const double *a, const double *b, const double *params, const double *covmat, double epsilon)
 
tbb::task_arena is an alias of tbb::interface7::task_arena, which doesn't allow to forward declare tb...
 
Short_t Max(Short_t a, Short_t b)
Returns the largest of a and b.
 
Double_t Prob(Double_t chi2, Int_t ndf)
Computation of the probability for a certain Chi-squared (chi2) and number of degrees of freedom (ndf...
 
Double_t QuietNaN()
Returns a quiet NaN as defined by IEEE 754.
 
Double_t Sqrt(Double_t x)
Returns the square root of x.
 
LongDouble_t Power(LongDouble_t x, LongDouble_t y)
Returns x raised to the power y.
 
Short_t Min(Short_t a, Short_t b)
Returns the smallest of a and b.
 
Bool_t AreEqualRel(Double_t af, Double_t bf, Double_t relPrec)
Comparing floating points.
 
Long64_t BinarySearch(Long64_t n, const T *array, T value)
Binary search in an array of n values to locate value.
 
Double_t Log10(Double_t x)
Returns the common (base-10) logarithm of x.
 
Short_t Abs(Short_t d)
Returns the absolute value of parameter Short_t d.
 
Double_t Infinity()
Returns an infinity as defined by the IEEE standard.