Added PID task, some fixes for coding conventions
[u/mrichter/AliRoot.git] / PWG4 / JetTasks / AliAnalysisTaskUE.h
CommitLineData
f3050824 1#ifndef ALIANALYSISTASKUE_H
2#define ALIANALYSISTASKUE_H
6ef5bfa4 3
f3050824 4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6ef5bfa4 6
f3050824 7#include "AliAnalysisTaskSE.h"
8
9class AliESDEvent;
10class AliAODEvent;
11class TH1F;
12class TH2F;
13class TH1I;
14class TVector3;
6ef5bfa4 15class TTree;
f3050824 16
6ef5bfa4 17class AliAnalysisTaskUE : public AliAnalysisTask
18 {
19 public:
20 AliAnalysisTaskUE(const char* name="AliAnalysisTaskUE");
21 virtual ~AliAnalysisTaskUE() {;}
22
23 // Implementation of interface methods
24 virtual void ConnectInputData(Option_t *);
25 virtual void CreateOutputObjects();
26 virtual void Exec(Option_t *option);
27 virtual void Terminate(Option_t *);
28
29 // Setters
30 virtual void SetDebugLevel( Int_t level ) { fDebug = level; }
31 void SetPtRangeInHist( Int_t bin, Double_t min, Double_t max ) {
32 fBinsPtInHist = bin;
33 fMinJetPtInHist = min;
34 fMaxJetPtInHist = max;
35 }
36
37 void SetAnaTopology( Int_t val ) { fAnaType = val; }
38 void SetRegionType( Int_t val ) { fRegionType = val; }
39 void SetUseChPartJet( Int_t val ) { fUseChPartJet = val; }
40 void SetPtSumOrdering( Bool_t val ) { fOrdering = val; }
41 void SetFilterBit( UInt_t val ) { fFilterBit = val; }
42 void SetJetsOnFly( Bool_t val ) { fJetsOnFly = val; }
43 void SetConeRadius( Double_t val ) { fConeRadius = val; }
44 void SetUseSingleCharge() { fUseSingleCharge = kTRUE; }
45 void SetUseNegativeChargeType() { fUsePositiveCharge = kFALSE; }
46 // Jet cuts
47 void SetJet1EtaCut( Double_t val ) { fJet1EtaCut = val; }
48 void SetJet2DeltaPhiCut( Double_t val ) { fJet2DeltaPhiCut = val; }
49 void SetJet2RatioPtCut( Double_t val ) { fJet2RatioPtCut = val; }
50 void SetJet3PtCut( Double_t val ) { fJet3PtCut = val; }
51 // track cuts
52 void SetTrackPtCut( Double_t val ) { fTrackPtCut = val; }
53 void SetTrackEtaCut( Double_t val ) { fTrackEtaCut = val; }
54
55 private:
56 AliAnalysisTaskUE(const AliAnalysisTaskUE &det);
57 AliAnalysisTaskUE& operator=(const AliAnalysisTaskUE &det);
58
59 void AnalyseUE();
60 Int_t IsTrackInsideRegion(TVector3 *jetVect, TVector3 *partVect);
61 void CreateHistos();
62 void SetRegionArea(TVector3 *jetVect);
63 void FillSumPtRegion( Double_t leadingE, Double_t ptMax, Double_t ptMin );
64 void FillAvePartPtRegion( Double_t leadingE, Double_t ptMax, Double_t ptMin );
65 void FillMultRegion( Double_t leadingE, Double_t nTrackPtmax, Double_t nTrackPtmin, Double_t ptMin );
66 TObjArray* FindChargedParticleJets();
67 void QSortTracks(TObjArray &a, Int_t first, Int_t last);
68 void WriteSettings();
69
70 Int_t fDebug; // Debug flag
71 AliAODEvent* fAOD; //! AOD Event
72 AliAODEvent* fAODjets; //! AOD Event for reconstructed on the fly (see ConnectInputData()
73 TList* fListOfHistos; // Output list of histograms
74
75 // Config
76 Int_t fBinsPtInHist; // # bins for Pt histos range
77 Double_t fMinJetPtInHist; // min Jet Pt value for histo range
78 Double_t fMaxJetPtInHist; // max Jet Pt value for histo range
79
80 // Cuts
81 Int_t fAnaType; // Analysis type on jet topology:
82 // 1=inclusive (default)
83 // 2=back to back inclusive
84 // 3=back to back exclusive
85 // 4=gama jet (back to back) ???
86 // Minimum bias
87 // 31 = Semi jet (charged leading particle jets)
88 // 32 = Random jetcone ?
89 // 33 = Swiss chees ?
90
91 // UE analysis is conducted in different type of regions
92 // Transverse are those like defined in: R. Field Acta Physica Polonica B. Vol 36 No. 2 pg 167 (2005)
93 // Cone regions like defined in: Phys. Rev. D 70, 072002 (2004)
94 Int_t fRegionType; // 1 = transverse regions (default)
95 // 2 = cone regions
96 Double_t fConeRadius; // if selected Cone-like region type, set Radius (=0.7 default)
97 Double_t fAreaReg; // Area of the region To be used as normalization factor when filling histograms
98 // if fRegionType = 2 not always it is included within eta range
99 Bool_t fUseChPartJet; // Use "Charged Particle Jet" instead of jets from AOD
100 // see FindChargedParticleJets()
101
102 // Theoreticians ask for tools charge-aware
103 // especially those which are related to multiplicity and MC-tunings
104 // see arXiv:hep-ph/0507008v3
105 Bool_t fUseSingleCharge; //Make analysis for a single type of charge (=kFALSE default)
106 Bool_t fUsePositiveCharge; //If Single type of charge used then set which one (=kTRUE default positive)
107
108 Int_t fOrdering; // Pt and multiplicity summation ordering:
109 // 1=CDF-like -independent sorting according quantity to be scored: Double sorting- (default)
110 // if Pt summation will be scored take Pt minimum between both zones and
111 // fill Pt Max. and Min. histog. accordingly
112 // if Multiplicity summation will be scored take Mult. minimum between both zones and
113 // fill Mult Max and Min histog. accordingly
114 // Bib:
115 // 2=Marchesini-like (Only Pt sorting: Single sorting)
116 // sort only according Pt summation scored, find minimum between both zones and
117 // fill Pt and Multiplicity Max and Min summation histog. following only this criterium
118 // Bib: Phys. Rev. D 38, 3419 (1988)
119 // 3=User Selection sorting (NOTE: USER must implement it within cxx)
120
121 UInt_t fFilterBit; // Select tracks from an specific track cut (default 0xFF all track selected)
122 Bool_t fJetsOnFly; // if jets are reconstructed on the fly from AOD tracks (see ConnectInputData() )
123
124 // Jet cuts
125 Double_t fJet1EtaCut; // |jet1 eta| < fJet1EtaCut (fAnaType = 1,2,3)
126 Double_t fJet2DeltaPhiCut; // |Jet1.Phi - Jet2.Phi| < fJet2DeltaPhiCut (fAnaType = 2,3)
127 Double_t fJet2RatioPtCut; // Jet2.Pt/Jet1Pt > fJet2RatioPtCut (fAnaType = 2,3)
128 Double_t fJet3PtCut; // Jet3.Pt < fJet3PtCut (fAnaType = 3)
129 // track cuts
130 Double_t fTrackPtCut; // Pt cut of tracks in the regions
131 Double_t fTrackEtaCut; // Eta cut on tracks in the regions (fRegionType=1)
132
133 // Histograms ( are owned by fListOfHistos TList )
134 TH1F* fhNJets; //!
135 TH1F* fhEleadingPt; //!
136
137 TH1F* fhMinRegPtDist; //!
138 TH1F* fhRegionMultMin; //!
139 TH1F* fhMinRegAvePt; //!
140 TH1F* fhMinRegSumPt; //!
141 TH1F* fhMinRegMaxPtPart; //!
142 TH1F* fhMinRegSumPtvsMult; //!
143
de6f8090 144 TH1F* fhdNdEtaPhiDist; //!
6ef5bfa4 145 TH2F* fhFullRegPartPtDistVsEt; //!
146 TH2F* fhTransRegPartPtDistVsEt; //!
147
148 TH1F* fhRegionSumPtMaxVsEt; //!
149 TH1I* fhRegionMultMax; //!
150 TH1F* fhRegionMultMaxVsEt; //!
151 TH1F* fhRegionSumPtMinVsEt; //!
152 TH1F* fhRegionMultMinVsEt; //!
153 TH1F* fhRegionAveSumPtVsEt; //!
154 TH1F* fhRegionDiffSumPtVsEt; //!
155
156 TH1F* fhRegionAvePartPtMaxVsEt; //!
157 TH1F* fhRegionAvePartPtMinVsEt; //!
158 TH1F* fhRegionMaxPartPtMaxVsEt; //!
159
160 TTree* fSettingsTree; //! Fast Settings saving
161
162 // TH2F* fhValidRegion; //! test to be canceled
163
164 ClassDef( AliAnalysisTaskUE, 1); // Analysis task for Underlying Event analysis
165 };
f3050824 166
f3050824 167#endif
6ef5bfa4 168
169