1 #ifndef AliAnalysisTaskEMCALPi0PbPb_h
2 #define AliAnalysisTaskEMCALPi0PbPb_h
12 class AliAODCaloCells;
13 class AliAODCaloCluster;
16 class AliEMCALGeoUtils;
17 class AliEMCALRecoUtils;
18 class AliESDCaloCells;
19 class AliESDCaloCluster;
22 class AliESDtrackCuts;
24 #include "AliAnalysisTaskSE.h"
26 class AliAnalysisTaskEMCALPi0PbPb : public AliAnalysisTaskSE {
28 AliAnalysisTaskEMCALPi0PbPb(const char *name=0);
29 virtual ~AliAnalysisTaskEMCALPi0PbPb();
31 void UserCreateOutputObjects();
32 void UserExec(Option_t *option);
33 void Terminate(Option_t *);
35 void SetAsymMax(Double_t asymMax) { fAsymMax = asymMax; }
36 void SetCentrality(const char *name) { fCentVar = name; }
37 void SetCentralityRange(Double_t from, Double_t to) { fCentFrom=from; fCentTo=to; }
38 void SetClusName(const char *name) { fClusName = name; }
39 void SetDoAfterburner(Bool_t b) { fDoAfterburner = b; }
40 void SetFillNtuple(Bool_t b) { fDoNtuple = b; }
41 void SetGeoName(const char *n) { fGeoName = n; }
42 void SetIsoDist(Double_t d) { fIsoDist = d; }
43 void SetMinClusEnergy(Double_t e) { fMinE = e; }
44 void SetMinEcc(Double_t ecc) { fMinEcc = ecc; }
45 void SetMinErat(Double_t erat) { fMinErat = erat; }
46 void SetMinNClustersPerTrack(Double_t mct) { fMinNClustPerTrack = mct; }
47 void SetMinPtPerMatchedTrack(Double_t mpt) { fMinPtPerTrack = mpt; }
48 void SetNminCells(Int_t n) { fNminCells = n; }
49 void SetTrClassNames(const char *n) { fTrClassNames = n; }
50 void SetTrackCuts(AliESDtrackCuts *c) { fTrCuts = c; }
51 void SetUseQualFlag(Bool_t b) { fUseQualFlag = b; }
52 void SetVertexRange(Double_t z1, Double_t z2) { fVtxZMin=z1; fVtxZMax=z2; }
55 virtual void CalcClusterProps();
56 virtual void CalcTracks();
57 virtual void ClusterAfterburner();
58 virtual void FillCellHists();
59 virtual void FillClusHists();
60 virtual void FillPionHists();
61 virtual void FillOtherHists();
62 Double_t GetCellIsolation(Double_t cEta, Double_t cPhi, Double_t radius=0.2) const;
63 Double_t GetMaxCellEnergy(AliVCluster *c) const;
64 Int_t GetNCells(AliVCluster *c, Double_t emin=0.) const;
65 void GetSigma(AliVCluster *c, Double_t &sigmaMax, Double_t &sigmaMin) const;
66 Double_t GetTrackIsolation(Double_t cEta, Double_t cPhi, Double_t radius=0.2) const;
70 ClusProps() : fTrIndex(-1), fTrDz(-1), fTrDr(-1), fTrDist(-1), fTrEp(0),
71 fTrIso(0), fTrLowPtIso(0), fCellIso(0) {}
72 void Reset() { fTrIndex=-1; fTrDz=-1; fTrDr=-1; fTrDist=-1; fTrEp=0; fTrIso=0; fTrLowPtIso=0; fCellIso=0; }
83 TString fCentVar; // variable for centrality determination
84 Double_t fCentFrom; // min centrality (def=0)
85 Double_t fCentTo; // max centrality (def=100)
86 Double_t fVtxZMin; // min primary vertex z (def=-10cm)
87 Double_t fVtxZMax; // max primary vertex z (def=+10cm)
88 Bool_t fUseQualFlag; // if true use quality flag for centrality
89 TString fClusName; // cluster branch name (def="")
90 Bool_t fDoNtuple; // if true write out ntuple
91 Bool_t fDoAfterburner; // if true run after burner
92 Double_t fAsymMax; // maximum energy asymmetry (def=1)
93 Int_t fNminCells; // minimum number of cells attached to cluster (def=1)
94 Double_t fMinE; // minimum cluster energy (def=0.1 GeV/c)
95 Double_t fMinErat; // minimum emax/ec ratio (def=0)
96 Double_t fMinEcc; // minimum eccentricity (def=0)
97 TString fGeoName; // geometry name (def = EMCAL_FIRSTYEARV1)
98 Double_t fMinNClustPerTrack; // minimum number of cluster per track (def=50)
99 Double_t fMinPtPerTrack; // minimum pT per track (def=0.25 GeV/c)
100 Double_t fIsoDist; // isolation distance (def=0.2)
101 TString fTrClassNames; // trigger class names
102 AliESDtrackCuts *fTrCuts; // track cuts
104 // derived members (ie with ! after //)
105 ULong64_t fNEvs; //!accepted events
106 AliEMCALGeoUtils *fGeom; //!geometry utils
107 AliEMCALRecoUtils *fReco; //!geometry utils
108 TList *fOutput; //!container of output histograms
109 TObjArray *fTrClassNamesArr; //!array of trig class names
110 AliESDEvent *fEsdEv; //!pointer to input esd event
111 AliAODEvent *fAodEv; //!pointer to input aod event
112 TObjArray *fRecPoints; //!pointer to rec points (AliAnalysisTaskEMCALClusterizeFast)
113 TObjArray *fEsdClusters; //!pointer to esd clusters
114 AliESDCaloCells *fEsdCells; //!pointer to esd cells
115 TObjArray *fAodClusters; //!pointer to aod clusters
116 AliAODCaloCells *fAodCells; //!pointer to aod cells
117 TAxis *fPtRanges; //!pointer to pt ranges
118 TNtuple *fNtuple; //!pointer to ntuple
119 TObjArray *fSelTracks; //!pointer to selected tracks
120 ClusProps fClusProps[1000]; //!array of cluster properties
122 TH1 *fHCuts; //!histo for cuts
123 TH1 *fHVertexZ; //!histo for vtxz
124 TH1 *fHVertexZ2; //!histo for vtxz after vtx cuts
125 TH1 *fHCent; //!histo for cent
126 TH1 *fHCentQual; //!histo for cent after quality flag cut
127 TH1 *fHTclsBeforeCuts; //!histo for trigger classes before cuts
128 TH1 *fHTclsAfterCuts; //!histo for trigger classes after cuts
130 // histograms for cells
131 TH2 **fHColuRow; //!histo for cell column and row
132 TH2 **fHColuRowE; //!histo for cell column and row weight energy
133 TH1 **fHCellMult; //!histo for cell multiplicity in module
134 TH1 *fHCellE; //!histo for cell energy
135 TH1 *fHCellH; //!histo for highest cell energy
136 TH1 *fHCellM; //!histo for mean cell energy (normalized to hit cells)
137 TH1 *fHCellM2; //!histo for mean cell energy (normalized to all cells)
138 TH1 **fHCellFreqNoCut; //!histo for cell frequency without cut
139 TH1 **fHCellFrequCut100M; //!histo for cell frequency with cut 100MeV
140 TH1 **fHCellFrequCut300M; //!histo for cell frequency with cut 300MeV
141 TH1 **fHCellCheckE; //!histo for cell E distribution for given channels
142 // histograms for clusters
143 TH1 *fHClustEccentricity; //!histo for cluster eccentricity
144 TH2 *fHClustEtaPhi; //!histo for cluster eta vs. phi
145 TH2 *fHClustEnergyPt; //!histo for cluster energy vs. pT
146 TH2 *fHClustEnergySigma; //!histo for cluster energy vs. variance over long axis
147 TH2 *fHClustSigmaSigma; //!histo for sigma vs. lambda_0 comparison
148 TH2 *fHClustNCellEnergyRatio; //!histo for cluster n tow vs. energy ratio
149 // histograms for pion candidates
150 TH2 *fHPionEtaPhi; //!histo for pion eta vs. phi
151 TH2 *fHPionMggPt; //!histo for pion mass vs. pT
152 TH2 *fHPionMggAsym; //!histo for pion mass vs. asym
153 TH2 *fHPionMggDgg; //!histo for pion mass vs. opening angle
154 TH1 *fHPionInvMasses[21]; //!histos for invariant mass plots
157 AliAnalysisTaskEMCALPi0PbPb(const AliAnalysisTaskEMCALPi0PbPb&); // not implemented
158 AliAnalysisTaskEMCALPi0PbPb &operator=(const AliAnalysisTaskEMCALPi0PbPb&); // not implemented
160 ClassDef(AliAnalysisTaskEMCALPi0PbPb, 4); // Analysis task for neutral pions in Pb+Pb