]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG4/totEt/AliAnalysisEt.h
implementing realistic reweighting of V0s, fixing some minor coding violations, addin...
[u/mrichter/AliRoot.git] / PWG4 / totEt / AliAnalysisEt.h
1 #ifndef ALIANALYSISET_H
2 #define ALIANALYSISET_H
3 //_________________________________________________________________________
4 //  Utility Class for transverse energy studies
5 //  Base class for ESD & MC analysis
6 //  - reconstruction and MonteCarlo output
7 //
8 //*-- Authors: Oystein Djuvsland (Bergen), David Silvermyr (ORNL)
9 //_________________________________________________________________________
10
11 #include "TString.h"
12 #include "AliAnalysisEtCommon.h"
13
14 class TTree;
15 class TH2F;
16 class TH1F;
17 class AliVEvent;
18 class TList;
19 class AliESDtrackCuts;
20 class Rtypes;
21 class AliAnalysisEtCuts;
22
23 class AliAnalysisEt : public AliAnalysisEtCommon
24 {
25 public:
26    
27     AliAnalysisEt();
28     virtual ~AliAnalysisEt();
29   
30 public:
31   
32     /** Analyse the event! */
33     virtual Int_t AnalyseEvent(AliVEvent *event);
34
35     /** Fill the objects you want to output, classes which add new histograms should overload this. */
36     virtual void FillOutputList(TList* list);
37
38     /** Initialise the analysis, must be overloaded. */
39     virtual void Init();
40
41     /** 
42     * Creates the histograms, must be overloaded if you want to add your own. 
43     * Uses the fHistogramNameSuffix to create proper histogram names
44     */
45     virtual void CreateHistograms();
46     virtual void CreateTrees();
47     
48     /** Fills the histograms, must be overloaded if you want to add your own */
49     virtual void FillHistograms();
50
51     /** Reset event specific values (Et etc.) */
52     virtual void ResetEventValues();
53
54     
55
56     /** Total Et in the event (without acceptance cuts) */
57     Double_t GetTotEt() const { return fTotEt; }
58
59     /** Total Et in the event within the acceptance cuts */
60     Double_t GetTotEtAcc() const { return fTotEtAcc; }
61
62    /** Total neutral Et in the event (without acceptance cuts) */
63     Double_t GetTotNeutralEt() const { return fTotNeutralEt; }
64
65     /** Total neutral Et in the event within the acceptance cuts */
66     Double_t GetTotNeutralEtAcc() const { return fTotNeutralEtAcc; }
67     
68     /** Total charged Et in the event (without acceptance cuts) */
69     Double_t GetTotChargedEt() const { return fTotChargedEt; }
70
71     /** Total charged Et in the event within the acceptance cuts */
72     Double_t GetTotChargedEtAcc() const { return fTotChargedEtAcc; }
73
74     void SetTPCOnlyTrackCuts(const AliESDtrackCuts *cuts){ fEsdtrackCutsTPC = (AliESDtrackCuts *) cuts;}
75
76 protected:
77
78     //AliAnalysisEtCuts *fCuts; // keeper of basic cuts
79
80
81     Double_t fTotEt;/** Total Et in the event (without acceptance cuts) */    
82     Double_t fTotEtAcc;/** Total Et in the event within the acceptance cuts */
83     
84     Double_t fTotNeutralEt;/** Total neutral Et in the event */    
85     Double_t fTotNeutralEtAcc;/** Total neutral Et in the event within the acceptance cuts */    
86     Double_t fTotChargedEt;/** Total charged Et in the event */    
87     Double_t fTotChargedEtAcc;/** Total charged Et in the event within the acceptance cuts */
88
89     Int_t fMultiplicity;/** Multiplicity of particles in the event */    
90     Int_t fChargedMultiplicity;/** Multiplicity of charged particles in the event */    
91     Int_t fNeutralMultiplicity; /** Multiplicity of neutral particles in the event */
92     
93     Double_t fBaryonEt;     /** Et of identified baryons; calo based (Rec only for now) */    
94     Double_t fAntiBaryonEt; /** Et of identified anti-baryons; calo based (Rec only for now) */
95     Double_t fMesonEt;     /** Et of identified mesons; calo based (Rec only for now) */
96
97     Double_t fProtonEt; /** Et of identified protons */
98     Double_t fPionEt; /** Et of identified pions */
99     Double_t fChargedKaonEt; /** Et of identified charged kaons */
100     Double_t fMuonEt; /** Et of identified muons */
101     Double_t fElectronEt; /** Et of identified electrons */
102     Double_t fNeutronEt; /** Et of neutrons (MC only for now) */
103     Double_t fAntiNeutronEt; /** Et of anti-neutrons (MC only for now) */
104     Double_t fGammaEt; /** Et of identified electrons (MC only for now) */
105    
106     Double_t fProtonEtAcc; /** Et of identified protons in calorimeter acceptance */    
107     Double_t fPionEtAcc; /** Et of identified pions in calorimeter acceptance */    
108     Double_t fChargedKaonEtAcc; /** Et of identified charged kaons in calorimeter acceptance */    
109     Double_t fMuonEtAcc; /** Et of identified muons in calorimeter acceptance */
110     Double_t fElectronEtAcc; /** Et of identified electrons in calorimeter acceptance */
111     
112     Float_t fEnergyDeposited; /** Energy deposited in calorimeter */
113     Float_t fEnergyTPC; /** Energy measured in TPC */
114     Short_t fCharge; /** Charge of the particle */
115     Short_t fParticlePid; /** Particle PID */
116     Float_t fPidProb; /** Probability of PID */
117     Bool_t fTrackPassedCut; /** The track is accepted by ESDTrackCuts */
118    
119         
120     Double_t fEtaCut;/** Cut in eta (standard |eta| < 0.5 )*/
121
122     /** Eta cut for our acceptance */
123     Double_t fEtaCutAcc; // Eta cut for our acceptance
124     
125     /** Min phi cut for our acceptance in radians */    
126     Double_t fPhiCutAccMin; // Min phi cut for our acceptance in radians     
127     
128     /** Max phi cut for our acceptance in radians */
129     Double_t fPhiCutAccMax; // Max phi cut for our acceptance in radians 
130     
131     /** Detector radius */
132     Double_t fDetectorRadius; // Detector radius 
133     
134     /** Cut on the cluster energy */    
135     Double_t fClusterEnergyCut; // Cut on the cluster energy 
136     
137     /** Minimum energy to cut on single cell cluster */
138     Double_t fSingleCellEnergyCut;  // Minimum energy to cut on single cell cluster
139
140     // Declare the histograms
141
142     /** The full Et spectrum measured */
143     TH1F *fHistEt; //Et spectrum
144
145     /** The full charged Et spectrum measured */
146     TH1F *fHistChargedEt; //Charged Et spectrum 
147
148     /** The full neutral Et spectrum measured */
149     TH1F *fHistNeutralEt; //Neutral Et spectrum
150
151     /** The Et spectrum within the calorimeter acceptance */
152     TH1F *fHistEtAcc; //Et in acceptance
153
154     /** The charged Et spectrum within the calorimeter acceptance */
155     TH1F *fHistChargedEtAcc; //Charged Et in acceptance
156
157     /** The neutral Et spectrum within the calorimeter acceptance */
158     TH1F *fHistNeutralEtAcc; //Et in acceptance
159
160     /** Multiplicity of particles in the events */
161     TH1F *fHistMult; //Multiplicity
162
163     /** Charged multiplicity of particles in the events */
164     TH1F *fHistChargedMult; //Charged multiplicity
165
166     /** Neutral multiplicity of particles in the events */
167     TH1F *fHistNeutralMult; //Neutral multiplicity
168
169     /* Acceptance plots */
170     TH2F *fHistPhivsPtPos; //phi vs pT plot for positive tracks
171     TH2F *fHistPhivsPtNeg; //phi vs pT plot for negative tracks
172
173     /* PID plots */
174     TH1F *fHistBaryonEt; /** Et of identified baryons */    
175     TH1F *fHistAntiBaryonEt; /** Et of identified anti-baryons */
176     TH1F *fHistMesonEt; /** Et of identified mesons */
177
178     TH1F *fHistProtonEt; /** Et of identified protons */
179     TH1F *fHistPionEt; /** Et of identified protons */
180     TH1F *fHistChargedKaonEt; /** Et of identified charged kaons */
181     TH1F *fHistMuonEt; /** Et of identified muons */
182     TH1F *fHistElectronEt; /** Et of identified electrons */
183     TH1F *fHistNeutronEt; /** Et of neutrons (MC only for now) */
184     TH1F *fHistAntiNeutronEt; /** Et of anti-neutrons (MC only for now) */
185     TH1F *fHistGammaEt; /** Et of gammas (MC only for now) */
186     
187     TH1F *fHistProtonEtAcc; /** Et of identified protons in calorimeter acceptance */    
188     TH1F *fHistPionEtAcc; /** Et of identified protons in calorimeter acceptance */    
189     TH1F *fHistChargedKaonEtAcc; /** Et of identified charged kaons in calorimeter acceptance */    
190     TH1F *fHistMuonEtAcc; /** Et of identified muons in calorimeter acceptance */
191     TH1F *fHistElectronEtAcc; /** Et of identified electrons in calorimeter acceptance */
192     
193     /* Correction plots */
194     TH1F *fHistTMDeltaR; /* Track matching plots; Rec only for now */
195
196     TTree *fTree; // optional TTree
197     TTree *fTreeDeposit; // optional TTree for energy deposit measurements
198
199
200 private:
201     //Declare private to avoid compilation warning
202     AliAnalysisEt & operator = (const AliAnalysisEt & g) ;//cpy assignment
203     AliAnalysisEt(const AliAnalysisEt & g) ; // cpy ctor
204
205     ClassDef(AliAnalysisEt, 1);
206 };
207
208 #endif // ALIANALYSISET_H