end-of-line normalization
[u/mrichter/AliRoot.git] / PWGCF / EBYE / PIDFluctuation / task / AliAnalysisTaskPIDFluctuation.h
CommitLineData
a65a7e70 1#ifndef ALIANALYSISTASKPIDFLUCTUATION_H
2#define ALIANALYSISTASKPIDFLUCTUATION_H
3
4/*
5 * updated by Zubayer Ahammed to instruct CINT about streaming
6 * of data members.
7 * Event by event PID fluctuation analysis
8 * author: Roberto Preghenella (R+)
9 * email: preghenella@bo.infn.it
10 *
11 */
12
13class TList;
14class TH1F;
15class TH2F;
16class TH3F;
17class AliVEvent;
18class AliVTrack;
19class AliESDtrackCuts;
20class AliPIDResponse;
21
22#include "AliAnalysisTaskSE.h"
23#include "AliPID.h"
24#include "THnSparse.h"
25
26class AliAnalysisTaskPIDFluctuation :
27public AliAnalysisTaskSE
28{
29
30 public:
31
32 AliAnalysisTaskPIDFluctuation(const Char_t *name = "PIDFluctuation"); // default constructor
33 virtual ~AliAnalysisTaskPIDFluctuation(); // default destructor
34
35 void UserCreateOutputObjects();
36 void UserExec(Option_t *option);
37
38 /* setters */
39 void SetPIDMethod(Int_t value) {fPIDMethod = value;}; // set PID method
40 void SetESDtrackCuts(AliESDtrackCuts *value) {fESDtrackCuts = value;}; // set ESD track cuts
41 void SetAODfilterBit(Int_t value) {fAODfilterBit = value;}; // set AOD filter bit
42 void SetEtaRange(Float_t etaMin, Float_t etaMax) {fEtaMin = etaMin; fEtaMax = etaMax;}; // set eta range
43 void SetPtRange(Float_t ptMin, Float_t ptMax) {fPtMin = ptMin; fPtMax = ptMax;}; // set pt range
44
45 static const Int_t kNCentralityBins = 10; // N centrality bins
46
47 enum EEventCounter_t {
48 kAllEvents,
49 kPhysicsSelection,
50 kPrimaryVertex,
51 kPrimaryVertexSPD,
52 kVertexAccepted,
53 kGoodCentrality,
54 kAcceptedEvents,
55 kNEventCounters
56 };
57
58 enum ESparseData_t {
59 kCent_V0M,
60 kCent_TRK,
61 kNch,
62 kNch_plus,
63 kNch_minus,
64 kNpi,
65 kNpi_plus,
66 kNpi_minus,
67 kNka,
68 kNka_plus,
69 kNka_minus,
70 kNpr,
71 kNpr_plus,
72 kNpr_minus,
73 kNSparseData
74 };
75
76 enum EPIDMethod_t {
77 kTPCTOF,
78 kTPConly,
79 kTOFonly,
80 kNPIDMethods
81 };
82
83 static void MeasureNuDyn(const Char_t *filename, Int_t i1, Int_t i2, Int_t centralityEstimator = kCent_V0M);
84
85 private:
86
87 AliAnalysisTaskPIDFluctuation(const AliAnalysisTaskPIDFluctuation &); // not implemented
88 AliAnalysisTaskPIDFluctuation &operator=(const AliAnalysisTaskPIDFluctuation &); // not implemented
89
90 /*** event and track selection ***/
91 Bool_t AcceptEvent(AliVEvent *event) const; // accept event
92 Bool_t AcceptTrack(AliVTrack *track) const; // accept track
93
94 /*** PID functions ***/
95 Bool_t HasTPCPID(AliVTrack *track) const; // has TPC PID
96 Bool_t HasTOFPID(AliVTrack *track) const; // has TOF PID
97 Double_t MakeTPCPID(AliVTrack *track, Double_t *nSigma) const; // make TPC PID
98 Double_t MakeTOFPID(AliVTrack *track, Double_t *nSigma) const; // make TOF PID
99 void MakePID(AliVTrack *track, Bool_t *pidFlag, Float_t centrality) const; // make PID
100 Bool_t InitPID(AliVEvent *event); // init PID
101
102 /*** PID objects and flags ***/
103 Int_t fPIDMethod; // PID method
104 AliESDtrackCuts *fESDtrackCuts; // ESD track cuts
105 Int_t fAODfilterBit; // AOD filter bit
106 Float_t fEtaMin; // eta min
107 Float_t fEtaMax; // eta max
108 Float_t fPtMin; // pt min
109 Float_t fPtMax; // pt max
110 AliPIDResponse *fPID; //! PID
111
112 /*** PID histos ***/
113 TList *fHistoList; //! histo list
114 TH1F *fHistoEventCounter; //! event counter
115 TH2F *fHistoAcceptedTracks; //! accepted tracks
116 TH2F *fHistoTOFMatchedTracks; //! TOF-matched tracks
117 TH3F *fHistoTPCdEdx; //! TPC dEdx
118 TH3F *fHistoTPCdEdx_inclusive; //! TPC dEdx
119 TH3F *fHistoTOFbeta; //! TOF beta
120 TH3F *fHistoTPCdEdx_selected[AliPID::kSPECIES]; //! TPC dEdx
121 TH3F *fHistoTOFbeta_selected[AliPID::kSPECIES]; //! TOF beta
122 TH3F *fHistoNSigmaTPC[AliPID::kSPECIES]; //! nsigma TPC
123 TH3F *fHistoNSigmaTOF[AliPID::kSPECIES]; //! nsigma TOF
124
125 /*** correlation histos */
126 THnSparseI *fHistoCorrelation; // correlation THnSparse
127
128 /*** labels, names and titles ***/
129 static const Char_t *fgkEventCounterName[kNEventCounters]; // event couter name
130 static const Char_t *fgkEventCounterTitle[kNEventCounters]; // event couter title
131 static const Char_t *fgkSparseDataName[kNSparseData]; // sparse data name
132 static const Char_t *fgkSparseDataTitle[kNSparseData]; // sparse data title
133
134
135 ClassDef(AliAnalysisTaskPIDFluctuation, 1);
136};
137
138#endif /* ALIANALYSISTASKPIDFLUCTUATION_H */