1 #ifndef AliAnalysisTaskV0QA_h
2 #define AliAnalysisTaskV0QA_h
3 //----------------------------------
4 // Class to check the V0 method efficiency for
5 // Author A. Marin revision 18/10/2009
6 //----------------------------------
10 #include "AliAnalysisTask.h"
11 #include "AliAnalysisManager.h"
12 #include "AliAnalysisDataContainer.h"
20 class AliAnalysisManager;
21 class AliAnalysisDataContainer;
22 class AliESDtrackCuts;
25 class AliAnalysisTaskV0QA : public AliAnalysisTask {
27 // AliAnalysisTaskV0QA() : AliAnalysisTask(), fESD(0), fChain(0) {}
28 AliAnalysisTaskV0QA(const char *name);
29 virtual ~AliAnalysisTaskV0QA();
31 virtual void ConnectInputData(Option_t *);
32 virtual void CreateOutputObjects();
33 virtual void Exec(Option_t *option);
34 virtual void Terminate(Option_t *);
36 void InspectListOfChargedParticles();
37 void InspectListOfV0s();
38 void FillHnSparseGamma();
39 void FillHnSparseK0();
41 void FillHnSparseAL();
43 // void getPID(AliESDtrack *esdTrack, Stat_t &fpid, Stat_t &fweight);
46 // AliESDtrackCuts* fEsdTrackCuts; // Object containing the parameters of the esd track cuts
47 // void SetESDtrackCuts();
52 Int_t GetTPCReference(Int_t label);
61 AliESDEvent *fESD; // ESD object
62 AliStack * fStack; // The MC Stack
63 AliMCEventHandler* fMCtruth; // The mc info
65 TChain * fChain; // Input chian
66 TList * fOutputContainer; // ! output data container
68 THnSparse *fSparseV0; // THnSparse with Gamma info
69 THnSparse *fSparseK0; // THnSparse with K0 info
70 THnSparse *fSparseL; // THnSparse with L info
71 THnSparse *fSparseAL; // THnSparse with antiL info
73 //////////////////////////////////
75 Int_t fnEv; // Number of event to analyse
76 Int_t fgDim; // Dimension of the THnSparse
78 Int_t fnConvGamGeant; // number of conversions in mc
80 Int_t * fgConvGamGeantIndex; //[fgDim] index of conversions in mc
81 Int_t * feNegConvGamGeantIndex; //[fgDim] index of e- from conversions in mc
82 Int_t * fePosConvGamGeantIndex; //[fgDim] index of e+ from conversions in mc
83 Float_t * feNegConvGamGeantLength; //[fgDim] length of the e- from conv
84 Float_t * fePosConvGamGeantLength; //[fgDim] length of the e+ from conv
87 Int_t * feNegConvGamSingleRecIndex; //[fgDim] index of e- from conversions reconstructed single
88 Int_t * fePosConvGamSingleRecIndex; //[fgDim] index of e+ from conversions reconstructed single
89 Int_t * feNegConvGamV0RecIndex; //[fgDim] index of e- from conversions reconstructed in V0
90 Int_t * fePosConvGamV0RecIndex; //[fgDim] index of e- from conversions reconstructed in V0
91 Int_t * fConvGamV0RecIndexPos; //[fgDim] index of V0 from conversions reconstructed
92 Int_t * fConvGamV0RecIndexNeg; //[fgDim] index of V0 from conversions reconstructed
97 Int_t fnDecayLGeant; // number of Lambda in mc
98 Int_t * flDecayLGeantIndex; //[fgDim] index of Lambda in MC
99 Int_t * fpiNegDecayLGeantIndex; //[fgDim] index of pi- from L in MC
100 Int_t * fpPosDecayLGeantIndex; //[fgDim] index of proton from L in MC
101 Float_t * fpiNegDecayLGeantLength; //[fgDim] length of the pi- from MC
102 Float_t * fpPosDecayLGeantLength; //[fgDim] length of the proton from MC
104 Int_t * fpiNegDecayLSingleRecIndex; //[fgDim] index of pi- from L reconstr. single
105 Int_t * fpPosDecayLSingleRecIndex; //[fgDim] index of proton from L reconstr. single
106 Int_t * fpiNegDecayLV0RecIndex; //[fgDim] index of pi- from L reconstr. V0
107 Int_t * fpPosDecayLV0RecIndex; //[fgDim] index of proton from L reconstr. V0
108 Int_t * fDecayLV0RecIndexPos; //[fgDim] index of pi- from L reconstr. V0
109 Int_t * fDecayLV0RecIndexNeg; //[fgDim] index of proton from L reconstr.
113 Int_t fnDecayALGeant; // number of Lambdabar in mc
114 Int_t * falDecayALGeantIndex; //[fgDim] index of Lambdabar in MC
115 Int_t * fpiPosDecayALGeantIndex; //[fgDim] index of pi+ from AL in MC
116 Int_t * fapNegDecayALGeantIndex; //[fgDim] index of antiproton from AL in MC
117 Float_t * fpiPosDecayALGeantLength; //[fgDim] Length of pi+ in MC
118 Float_t * fapNegDecayALGeantLength; //[fgDim] Length of antiproton in MC
120 Int_t * fpiPosDecayALSingleRecIndex; //[fgDim] index of pi+ from AL reconstr. single
121 Int_t * fapNegDecayALSingleRecIndex; //[fgDim] index of antiproton from AL reconstr. single
122 Int_t * fpiPosDecayALV0RecIndex; //[fgDim] index of pi+ from AL reconstr. V0
123 Int_t * fapNegDecayALV0RecIndex; //[fgDim] index of antiproton from AL reconstr. V0
124 Int_t * fDecayALV0RecIndexPos; //[fgDim] index of pi+ V0
125 Int_t * fDecayALV0RecIndexNeg; //[fgDim] index of antiproton V0
129 Int_t fnDecayK0Geant; // number of K0s in mc
130 Int_t * fK0DecayK0GeantIndex; //[fgDim] index of K0S in MC
131 Int_t * fpiNegDecayK0GeantIndex; //[fgDim] index of pi- from K0s in MC
132 Int_t * fpiPosDecayK0GeantIndex; //[fgDim] index of pi+ from K0s in MC
133 Float_t * fpiNegDecayK0GeantLength; //[fgDim] length of the pi- from K0s in MC
134 Float_t * fpiPosDecayK0GeantLength; //[fgDim] length of the pi+ from K0s in MC
136 Int_t * fpiNegDecayK0SingleRecIndex; //[fgDim] index of pi- from K0S reconstr. single
137 Int_t * fpiPosDecayK0SingleRecIndex; //[fgDim] index of pi+ from K0S reconstr. single
138 Int_t * fpiNegDecayK0V0RecIndex; //[fgDim] index of pi- from K0S reconstr. V0
139 Int_t * fpiPosDecayK0V0RecIndex; //[fgDim] index of pi+ from K0S reconstr. V0
140 Int_t * fDecayK0V0RecIndexPos; //[fgDim] index of pi+ V0
141 Int_t * fDecayK0V0RecIndexNeg; //[fgDim] index of pi- V0
143 Int_t fpiPosK0Index; //
144 Int_t fpiNegK0Index; //
147 Int_t fnTracksPrim; // number of primary tracks contributing to vertex
150 Int_t ftpcRefit; // tpcRefit condition
151 Int_t fitsRefit; // itsRefit condition
152 Int_t ftrdRefit; // trdRefit condition
153 Int_t ftrdOut; // trdOut condition
158 Double_t fprobabilityPos[AliPID::kSPECIES];
159 Double_t fprobabilityNeg[AliPID::kSPECIES];
161 Int_t fDim; // number of dimensions THnSparse
162 Double_t * fValueL; //[fDim] values to THnSparse for L
163 Double_t * fValueAL; //[fDim] values to THnSparse for AL
164 Double_t * fValueK0; //[fDim] values to THnSparse for K0
165 Double_t * fValueV0; //[fDim] values to THnSparse for Gamma
167 Double_t * fxminV0; //[fDim] min value to THnSparse
168 Double_t * fxmaxV0; //[fDim] max value to THnSparse
169 Int_t * fbinsV0; //[fDim] number of bins to THnSparse
174 TObjArray* fRefTPC; // references for the tpc
175 int fLabelsTPC[100000]; // labels for the tpc
178 TClonesArray *fclRefsN; // negative references for the tpc
179 TClonesArray *fclRefsP; // positive references for the tpc
183 AliAnalysisTaskV0QA (const AliAnalysisTaskV0QA & v0QA );
184 AliAnalysisTaskV0QA & operator=(const AliAnalysisTaskV0QA & v0QA);
188 ClassDef(AliAnalysisTaskV0QA, 1); // example of analysis