New reference run for SPD
[u/mrichter/AliRoot.git] / PWG4 / PartCorrDep / AliAnaParticleHadronCorrelation.h
CommitLineData
045396c8 1#ifndef ALIANAPARTICLEHADRONCORRELATION_H
2#define ALIANAPARTICLEHADRONCORRELATION_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5/* $Id: $ */
6
7//_________________________________________________________________________
8// Class that contains the algorithm for the analysis of particle - hadron correlations
9// Particle (for example direct gamma) must be found in a previous analysis
10//-- Author: Gustavo Conesa (INFN-LNF)
11
12// Modified by Yaxian Mao:
13// 1. add the UE subtraction for corrlation study
14// 2. change the correlation variable
15// 3. Only use leading particle(cluster/track) as trigger for correlation (2010/07/02)
16// 4. Make decay photon-hadron correlations where decay contribute pi0 mass (2010/09/09)
17// 5. fill the pout to extract kt at the end, also to study charge asymmetry(2010/10/06)
18// 6. Add the possibility for event selection analysis based on vertex and multiplicity bins (10/10/2010)
19// 7. change the way of delta phi cut for UE study due to memory issue (reduce histograms)
20// 8. Add the possibility to request the absolute leading particle at the near side or not, set trigger bins, general clean-up (08/2011)
21
22// --- ROOT system ---
23//class TH3D;
24
25// --- Analysis system ---
26#include "AliAnaPartCorrBaseClass.h"
27class AliAODPWG4ParticleCorrelation ;
28
29class AliAnaParticleHadronCorrelation : public AliAnaPartCorrBaseClass {
30
31 public:
c5693f62 32
045396c8 33 AliAnaParticleHadronCorrelation() ; // default ctor
34 virtual ~AliAnaParticleHadronCorrelation() {;} //virtual dtor
045396c8 35
36 // General methods
37
38 TObjString * GetAnalysisCuts();
39
40 TList * GetCreateOutputObjects();
41
42 void InitParameters();
43
44 void MakeAnalysisFillAOD() ;
45
46 void MakeAnalysisFillHistograms() ;
47
48 void Print(const Option_t * opt) const;
49
50 // Main analysis methods
51
c5693f62 52 Bool_t MakeChargedCorrelation (AliAODPWG4ParticleCorrelation * aodParticle, const TObjArray* pl, const Bool_t bFillHisto) ;
045396c8 53
c5693f62 54 Bool_t MakeNeutralCorrelation (AliAODPWG4ParticleCorrelation * aodParticle, const TObjArray* pl, const Bool_t bFillHisto) ;
045396c8 55
56 void MakeMCChargedCorrelation(AliAODPWG4ParticleCorrelation *aodParticle);
57
58
59 // Parameter setter and getter
60
61 Double_t GetDeltaPhiMaxCut() const { return fDeltaPhiMaxCut ; }
62 Double_t GetDeltaPhiMinCut() const { return fDeltaPhiMinCut ; }
63 Double_t GetUeDeltaPhiMaxCut() const { return fUeDeltaPhiMaxCut ; }
64 Double_t GetUeDeltaPhiMinCut() const { return fUeDeltaPhiMinCut ; }
65
66 void SetDeltaPhiCutRange(Double_t phimin, Double_t phimax)
67 { fDeltaPhiMaxCut = phimax ; fDeltaPhiMinCut = phimin ; }
68 void SetUeDeltaPhiCutRange(Double_t uephimin, Double_t uephimax)
69 { fUeDeltaPhiMaxCut = uephimax; fUeDeltaPhiMinCut = uephimin ; }
70
71 Bool_t IsSeveralUEOn() const { return fMakeSeveralUE ; }
72 void SwitchOnSeveralUECalculation() { fMakeSeveralUE = kTRUE ; }
73 void SwitchOffSeveralUECalculation() { fMakeSeveralUE = kFALSE ; }
74
75 // Do trigger-neutral correlation
76 Bool_t DoNeutralCorr() const { return fNeutralCorr ; }
77 void SwitchOnNeutralCorr() { fNeutralCorr = kTRUE ; }
78 void SwitchOffNeutralCorr() { fNeutralCorr = kFALSE ; }
79
80 // Taking the absolute leading as the trigger or not
81 Bool_t DoAbsoluteLeading() const { return fMakeAbsoluteLeading ; }
82 void SwitchOnAbsoluteLeading() { fMakeAbsoluteLeading = kTRUE ; }
83 void SwitchOffAbsoluteLeading() { fMakeAbsoluteLeading = kFALSE ; }
84
85 // Do decay-hadron correlation if it is pi0 trigger
86 Bool_t IsPi0Trigger() const { return fPi0Trigger ; }
87 void SwitchOnDecayCorr() { fPi0Trigger = kTRUE ; }
88 void SwitchOffDecayCorr() { fPi0Trigger = kFALSE ; }
89
90 Bool_t OnlyIsolated() const { return fSelectIsolated ; }
91 void SelectIsolated(Bool_t s) { fSelectIsolated = s ; }
92
93 void SetPi0AODBranchName(TString n) { fPi0AODBranchName = n ; }
94
05d0d05d 95 void SetNAssocPtBins(Int_t n) ;
96 void SetAssocPtBinLimit(Int_t ibin, Float_t pt) ;
045396c8 97
98 private:
99
100 Double_t fDeltaPhiMaxCut ; // Minimum Delta Phi Gamma-Hadron
101 Double_t fDeltaPhiMinCut ; // Maximum Delta Phi Gamma-Hadron
102 Bool_t fSelectIsolated ; // Select only trigger particles isolated
103 Bool_t fMakeSeveralUE ; // Do analysis for several underlying events contribution
104 Double_t fUeDeltaPhiMaxCut ; // Minimum Delta Phi Gamma-Underlying Hadron
105 Double_t fUeDeltaPhiMinCut ; // Maximum Delta Phi Gamma-Underlying Hadron
106 TString fPi0AODBranchName; // Name of AOD branch with pi0, not trigger
107 Bool_t fNeutralCorr ; // switch the analysis with neutral particles
108 Bool_t fPi0Trigger ; // switch the analysis with decay photon from pi0 trigger
109 Bool_t fMakeAbsoluteLeading ; // requesting absolute leading while it is cluster triggers
110 Int_t fLeadingTriggerIndex ; // Store here per event the trigger index, to avoid too many loops
111
05d0d05d 112 Int_t fNAssocPtBins ; // Number of associated pT bins under study
113 Float_t fAssocPtBinLimit[10] ; // Associated pT under study
045396c8 114
115 //Histograms
116
117 //leading particles
118 TH1F * fhPtLeading; //! pT distribution of leading particles
119 TH2F * fhPhiLeading; //! phi distribution vs pT of leading particles
120 TH2F * fhEtaLeading; //! eta distribution vs pT of leading particles
121
122 //trigger-charged histograms
123 TH2F * fhDeltaPhiDeltaEtaCharged ; //! differences of eta and phi between trigger and charged hadrons
124 TH2F * fhPhiCharged ; //! Phi distribution of charged particles
125 TH2F * fhEtaCharged ; //! Eta distribution of charged particles
126 TH2F * fhDeltaPhiCharged ; //! Difference of charged particle phi and trigger particle phi as function of trigger particle pT
127 TH2F * fhDeltaEtaCharged ; //! Difference of charged particle eta and trigger particle eta as function of trigger particle pT
128 TH2F * fhDeltaPhiChargedPt ; //! Difference of charged particle phi and trigger particle phi as function of charged particle pT
129 TH2F * fhDeltaPhiUeChargedPt ; //! Difference of charged particle from underlying events phi and trigger particle phi as function of charged particle pT
130 TH2F * fhPtImbalanceCharged ; //! Trigger particle -charged hadron momentim imbalance histogram
131 TH2F * fhPtImbalanceUeCharged ; //! Trigger particle -underlying charged hadron momentum imbalance histogram
132 TH2F * fhPtImbalancePosCharged ; //! Trigger particle -positive charged hadron momentum imbalance histogram
133 TH2F * fhPtImbalanceNegCharged ; //! Trigger particle -negative charged hadron momentum imbalance histogram
134
135 //with different imblance varible defination HBP distribution
136 TH2F * fhPtHbpCharged ; //! Trigger particle -charged hadron momentim HBP histogram
137 TH2F * fhPtHbpUeCharged ; //! Trigger particle -underlying charged hadron momentim HBP histogram
138
139 //if several UE calculation is on, most useful for jet-jet events contribution
140 TH2F * fhDeltaPhiUeLeftCharged ; //! Difference of charged particle from underlying events phi and trigger particle phi as function of charged particle pT
141 TH2F * fhDeltaPhiUeRightCharged ; //! Difference of charged particle from underlying events phi and trigger particle phi
142 TH2F * fhPtImbalanceUeLeftCharged ; //! Trigger particle -underlying charged hadron momentim imbalance histogram
143 TH2F * fhPtImbalanceUeRightCharged ; //! Trigger particle -underlying charged hadron momentim imbalance histogram
144 TH2F * fhPtHbpUeLeftCharged ; //! Trigger particle -underlying charged hadron momentim HBP histogram
145 TH2F * fhPtHbpUeRightCharged ; //! Trigger particle -underlying charged hadron momentim HBP histogram
146
147 //for pout and kt extraction
05d0d05d 148 TH2F * fhPtTrigPout ; //! Pout =associated pt*sin(delta phi) distribution vs trigger pt
045396c8 149 TH2F * fhPtTrigCharged ; //! trigger and correlated particl pt, to be used for mean value for kt
150
151 //if different multiplicity analysis asked
05d0d05d 152 TH2F ** fhTrigDeltaPhiCharged ; //![GetMultiBin()] differences of phi between trigger and charged hadrons
153 TH2F ** fhTrigDeltaEtaCharged ; //![GetMultiBin()] differences of eta between trigger and charged hadrons
154 TH2F ** fhTrigCorr ; //![GetMultiBin()] Trigger particle -charged hadron momentim imbalance histogram
155 TH2F ** fhTrigUeCorr ; //![GetMultiBin()] Trigger particle -UE charged hadron momentim imbalance histogram
045396c8 156
05d0d05d 157 TH2F * fhAssocPt ; //! Trigger pT vs associated pT
158 TH2F * fhAssocPtBkg; //! Trigger pT vs associated pT for background
159 TH2F ** fhDeltaPhiAssocPtBin; //![fNAssocPtBins] Trigger pT vs dPhi for different associated pt bins
160 TH2F ** fhDeltaPhiBradAssocPtBin; //![fNAssocPtBins] Trigger pT vs dPhi Brad (?) for different associated pt bins
161 TH2F ** fhXEAssocPtBin ; //![fNAssocPtBins] Trigger pT vs xE for different associated pt bins
045396c8 162
163 //trigger-neutral histograms
164 TH2F * fhDeltaPhiDeltaEtaNeutral ; //! differences of eta and phi between trigger and neutral hadrons (pi0)
165 TH2F * fhPhiNeutral ; //! Phi distribution of neutral particles
166 TH2F * fhEtaNeutral ; //! Eta distribution of neutral particles
167 TH2F * fhDeltaPhiNeutral ; //! Difference of neutral particle phi and trigger particle phi as function of trigger particle pT
168 TH2F * fhDeltaEtaNeutral ; //! Difference of neutral particle eta and trigger particle eta as function of trigger particle pT
169 TH2F * fhDeltaPhiNeutralPt ; //! Difference of neutral particle phi and trigger particle phi as function of neutral particle particle pT
170 TH2F * fhDeltaPhiUeNeutralPt ; //! Difference of neutral particle phi and trigger particle phi as function of neutral particle particle pT
171 TH2F * fhPtImbalanceNeutral ; //! Trigger particle - neutral hadron momentum imbalance histogram
172 TH2F * fhPtImbalanceUeNeutral ; //! Trigger particle - neutral hadron momentum imbalance histogram
173
174 //with different imblance varible defination HBP distribution
175 TH2F * fhPtHbpNeutral ; //! Trigger particle -neutral particle momentim HBP histogram
176 TH2F * fhPtHbpUeNeutral ; //! Trigger particle -underlying neutral hadron momentim HBP histogram
177
178 //if several UE calculation is on, most useful for jet-jet events contribution
179 TH2F * fhDeltaPhiUeLeftNeutral ; //! Difference of charged particle from underlying events phi and trigger particle phi as function of neutral particle pT
180 TH2F * fhDeltaPhiUeRightNeutral ; //! Difference of charged particle from underlying events phi and trigger particle phi
181 TH2F * fhPtImbalanceUeLeftNeutral ; //! Trigger particle -underlying neutral hadron momentim imbalance histogram
182 TH2F * fhPtImbalanceUeRightNeutral ; //! Trigger particle -underlying neutral hadron momentim imbalance histogram
183 TH2F * fhPtHbpUeLeftNeutral ; //! Trigger particle -underlying neutral hadron momentim HBP histogram
184 TH2F * fhPtHbpUeRightNeutral ; //! Trigger particle -underlying neutral hadron momentim HBP histogram
185
186 //for decay photon trigger correlation
187 TH2F * fhPtPi0DecayRatio ; //! for pi0 pt and ratio of decay photon pt
188 TH2F * fhDeltaPhiDecayCharged ; //! Difference of charged particle phi and decay trigger
189 TH2F * fhPtImbalanceDecayCharged ; //! Trigger particle (decay from pi0)-charged hadron momentim imbalance histogram
190 TH2F * fhDeltaPhiDecayNeutral ; //! Difference of neutral particle phi and decay trigger
191 TH2F * fhPtImbalanceDecayNeutral ; //! Trigger particle (decay from pi0)-neutral hadron momentim imbalance histogram
192
193 //if the data is MC, fill MC information
194 TH2F * fh2phiLeadingParticle; //! #phi resolution for triggers
195 TH1F * fhMCLeadingCount; //! add explanation
196 TH2F * fhMCEtaCharged; //! add explanation
197 TH2F * fhMCPhiCharged; //! add explanation
198 TH2F * fhMCDeltaEtaCharged; //! add explanation
199 TH2F * fhMCDeltaPhiCharged; //! add explanation
200 TH2F * fhMCDeltaPhiDeltaEtaCharged; //! add explanation
201 TH2F * fhMCDeltaPhiChargedPt; //! add explanation
202 TH2F * fhMCPtImbalanceCharged; //! add explanation
203 TH2F * fhMCPtHbpCharged; //! add explanation
204 TH2F * fhMCPtTrigPout ; //! add explanation
205 TH2F * fhMCPtAssocDeltaPhi ; //! Pout =associated pt*sin(delta phi) distribution
206
c5693f62 207 AliAnaParticleHadronCorrelation(const AliAnaParticleHadronCorrelation & ph) ; // cpy ctor
208 AliAnaParticleHadronCorrelation & operator = (const AliAnaParticleHadronCorrelation & ph) ;//cpy assignment
045396c8 209
05d0d05d 210 ClassDef(AliAnaParticleHadronCorrelation,8)
045396c8 211} ;
212
213
214#endif //ALIANAPARTICLEHADRONCORRELATION_H
215
216
217