00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015 #ifndef TESUNCERTAINTY_H
00016 #define TESUNCERTAINTY_H
00017
00018 #include <vector>
00019 #include <map>
00020 #include <math.h>
00021 #include <iostream>
00022
00023 #include "stdio.h"
00024 #include "TFile.h"
00025 #include "TH1D.h"
00026 #include "TString.h"
00027 #include "TMath.h"
00028 #include "TObject.h"
00029
00030 namespace TauCorrUncert {
00031
00032 class TESUncertainty : public TObject
00033 {
00034
00035 public:
00036
00037 TESUncertainty(TString datafile);
00038
00039 ~TESUncertainty();
00040
00041
00042
00043
00044 enum TESComponent {
00045 FINAL,
00046 SHOWERMODEL,
00048 UE,
00049 DM,
00050 CLOSURE,
00051 PU,
00052 OTHERS,
00053
00054 SINGLEPARTICLE,
00055
00056 EOP_RSP,
00057 EOP_SYST,
00058 CTB_SYST,
00059 CTB_RSP,
00060 EM,
00061 LCW,
00062 Bias,
00063
00064 EOP,
00065 CTB,
00066 INSITUSTAT,
00067 INSITUSYST,
00068 SYSREST,
00069 TOTAL,
00070 REMAININGSYS,
00071 MODELING,
00072 INSITU,
00073 INSITUINTERPOL,
00074 INSITUSTATINTERPOL,
00075 INSITUSYSTINTERPOL,
00076 SINGLEPARTICLEINTERPOL
00077 };
00078
00079
00080
00081
00082
00083
00084 double GetTESUncertainty(double pt,
00085 double eta,
00086 int nProng,
00087 TESComponent component = FINAL);
00088 double GetTESShift(double pt,
00089 int nProng);
00090
00091 private:
00092
00093 double getInSituSys(const int& ntracks);
00094 double getInSituStat(const int& ntracks);
00095 double getSystRest(const double& pt,
00096 const int& ntracks,
00097 const int&, const unsigned int&);
00098 double getModeling(const double& pt,
00099 const unsigned int& itracks,
00100 const unsigned int& iE);
00101 double getClosure(const double& pt,
00102 const unsigned int& itracks,
00103 const unsigned int& iE);
00104 double getSingleParticleResponse(const double& pt,
00105 const unsigned int& itracks,
00106 const unsigned int& iE);
00107 double getSingleParticleResponseInterpolated(const double& pt,
00108 const unsigned int& itracks,
00109 const unsigned int& iE);
00110
00111 double getInSitu(const unsigned int& itracks);
00112 double getInSitu(const double& pt,
00113 const unsigned int& itracks);
00114
00115 double interpolateLin(const double& pt);
00116 TH1D* GetHist(TFile* file, TString name);
00117
00118 std::map<TESComponent, TString> map_components;
00119 std::map<TESComponent, double> map_uncertaintycomponents;
00120 std::map<TString, TH1D*> map_histo;
00121
00122 int m_nEta;
00123 int m_nPt;
00124
00125 const double GeV;
00126
00127 const double m_dInSituStat1P;
00128 const double m_dInSituStat3P;
00129 const double m_dInSituSyst1P;
00130 const double m_dInSituSyst3P;
00131 ClassDef(TESUncertainty, 1)
00132 };
00133 }
00134
00135 #endif