BOSS 7.1.1
BESIII Offline Software System
Loading...
Searching...
No Matches
WidgetCurve.h
Go to the documentation of this file.
1//********************************************************************************
2// This file is part of the Widget, a package for performing dE/dx calibration.
3//
4// Author: Jake Bennett
5// Date: July 8, 2015
6//
7//
8// For additional details, see the Widget document.
9//
10//********************************************************************************
11#ifndef WIDGETCURVE_H
12#define WIDGETCURVE_H
13
14#include <math.h>
15
17
18 public:
19
21 virtual ~WidgetCurve() {};
22
23 double bgCurve( double *x, double *par ){
24
25 // ************* FIX ME ******************
26 // redundant parameters 3 and 5
27 // ***************************************
28 double f = 0;
29 if( par[0] == 1 )
30 f = par[1]*pow(sqrt(x[0]*x[0]+1),par[3])/pow(x[0],par[3]) *
31 (par[2]-par[6]*log(pow(1/x[0],par[4])) ) - par[5]+exp(par[7]+par[8]*x[0]);
32 else if( par[0] == 2 )
33 f = par[1]*pow(x[0],3)+par[2]*x[0]*x[0]+par[3]*x[0]+par[4];
34 else if( par[0] == 3 )
35 f = -1.0*par[1]*log(par[4]+pow(1/x[0],par[2]))+par[3];
36
37 return f;
38 }
39
40 double operator()( double *x, double *par ){
41 return bgCurve(x,par);
42 }
43};
44#endif
TFile f("ana_bhabha660a_dqa_mcPat_zy_old.root")
Double_t x[10]
EvtComplex exp(const EvtComplex &c)
double operator()(double *x, double *par)
Definition WidgetCurve.h:40
virtual ~WidgetCurve()
Definition WidgetCurve.h:21
double bgCurve(double *x, double *par)
Definition WidgetCurve.h:23