]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGLF/STRANGENESS/Cascades/AliAnalysisTaskStrangenessVsMultiplicityMC.h
Merge branch 'master' of https://git.cern.ch/reps/AliRoot
[u/mrichter/AliRoot.git] / PWGLF / STRANGENESS / Cascades / AliAnalysisTaskStrangenessVsMultiplicityMC.h
1 /**************************************************************************
2  * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3  *                                                                        *
4  * Author: The ALICE Off-line Project.                                    *
5  * Contributors are mentioned in the code where appropriate.              *
6  *                                                                        *
7  * Permission to use, copy, modify and distribute this software and its   *
8  * documentation strictly for non-commercial purposes is hereby granted   *
9  * without fee, provided that the above copyright notice appears in all   *
10  * copies and that both the copyright notice and this permission notice   *
11  * appear in the supporting documentation. The authors make no claims     *
12  * about the suitability of this software for any purpose. It is          *
13  * provided "as is" without express or implied warranty.                  *
14  **************************************************************************/
15
16 // +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
17 //
18 // Modified version of AliAnalysisTaskCheckCascade.h
19 // Used bits of code from AliAnalysisTaskCheckPerformanceStrange
20 //
21 // --- David Dobrigkeit Chinellato
22 //
23 // +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
24
25 #ifndef AliAnalysisTaskStrangenessVsMultiplicityMC_H
26 #define AliAnalysisTaskStrangenessVsMultiplicityMC_H
27
28 class TList;
29 class TH1F;
30 class TH2F;
31 class TH3F;
32 class TVector3;
33 class THnSparse;
34
35 class AliESDpid;
36 class AliESDtrackCuts;
37 class AliAnalysisUtils;
38 class AliESDEvent;
39 class AliPhysicsSelection;
40 class AliCFContainer;
41
42 //#include "TString.h"
43 //#include "AliESDtrackCuts.h"
44 //#include "AliAnalysisTaskSE.h"
45
46 class AliAnalysisTaskStrangenessVsMultiplicityMC : public AliAnalysisTaskSE {
47  public:
48   AliAnalysisTaskStrangenessVsMultiplicityMC();
49   AliAnalysisTaskStrangenessVsMultiplicityMC(const char *name);
50   virtual ~AliAnalysisTaskStrangenessVsMultiplicityMC();
51   
52   virtual void   UserCreateOutputObjects();
53   virtual void   UserExec(Option_t *option);
54   virtual void   Terminate(Option_t *);
55   Double_t MyRapidity(Double_t rE, Double_t rPz) const;
56
57   void SetSaveV0s                (Bool_t lSaveV0s        = kTRUE ) { fkSaveV0Tree        = lSaveV0s;        }
58   void SetSaveCascades           (Bool_t lSaveCascades   = kTRUE ) { fkSaveCascadeTree   = lSaveCascades;   }
59   
60 //---------------------------------------------------------------------------------------
61   //Task Configuration: Meant to enable quick re-execution of vertexer if needed
62   void SetRunVertexers ( Bool_t lRunVertexers = kTRUE) { fkRunVertexers = lRunVertexers; }
63 //---------------------------------------------------------------------------------------
64 //Setters for the V0 Vertexer Parameters
65   void SetV0VertexerMaxChisquare   ( Double_t lParameter ){ fV0VertexerSels[0] = lParameter; }
66   void SetV0VertexerDCAFirstToPV   ( Double_t lParameter ){ fV0VertexerSels[1] = lParameter; }
67   void SetV0VertexerDCASecondtoPV  ( Double_t lParameter ){ fV0VertexerSels[2] = lParameter; }
68   void SetV0VertexerDCAV0Daughters ( Double_t lParameter ){ fV0VertexerSels[3] = lParameter; }
69   void SetV0VertexerCosinePA       ( Double_t lParameter ){ fV0VertexerSels[4] = lParameter; }
70   void SetV0VertexerMinRadius      ( Double_t lParameter ){ fV0VertexerSels[5] = lParameter; }
71   void SetV0VertexerMaxRadius      ( Double_t lParameter ){ fV0VertexerSels[6] = lParameter; }
72 //---------------------------------------------------------------------------------------
73 //Setters for the Cascade Vertexer Parameters
74   void SetCascVertexerMaxChisquare         ( Double_t lParameter ){ fCascadeVertexerSels[0] = lParameter; } 
75   void SetCascVertexerMinV0ImpactParameter ( Double_t lParameter ){ fCascadeVertexerSels[1] = lParameter; } 
76   void SetCascVertexerV0MassWindow         ( Double_t lParameter ){ fCascadeVertexerSels[2] = lParameter; } 
77   void SetCascVertexerDCABachToPV          ( Double_t lParameter ){ fCascadeVertexerSels[3] = lParameter; } 
78   void SetCascVertexerDCACascadeDaughters  ( Double_t lParameter ){ fCascadeVertexerSels[4] = lParameter; }
79   void SetCascVertexerCascadeCosinePA      ( Double_t lParameter ){ fCascadeVertexerSels[5] = lParameter; }  
80   void SetCascVertexerCascadeMinRadius     ( Double_t lParameter ){ fCascadeVertexerSels[6] = lParameter; }  
81   void SetCascVertexerCascadeMaxRadius     ( Double_t lParameter ){ fCascadeVertexerSels[7] = lParameter; }  
82 //---------------------------------------------------------------------------------------
83   
84  private:
85         // Note : In ROOT, "//!" means "do not stream the data from Master node to Worker node" ...
86         // your data member object is created on the worker nodes and streaming is not needed.
87         // http://root.cern.ch/download/doc/11InputOutput.pdf, page 14
88   TList  *fListHist;  //! List of Cascade histograms
89   TTree  *fTreeEvent;              //! Output Tree, Events
90   TTree  *fTreeV0;              //! Output Tree, V0s
91   TTree  *fTreeCascade;              //! Output Tree, Cascades
92
93   AliPIDResponse *fPIDResponse;     // PID response object
94   AliESDtrackCuts *fESDtrackCuts;   // ESD track cuts used for primary track definition
95
96   //Objects Controlling Task Behaviour 
97   Bool_t fkSaveV0Tree;              //if true, save TTree
98   Bool_t fkSaveCascadeTree;         //if true, save TTree
99
100   //Objects Controlling Task Behaviour: has to be streamed! 
101   Bool_t    fkRunVertexers;           // if true, re-run vertexer with loose cuts *** only for CASCADES! *** 
102   Double_t  fV0VertexerSels[7];        // Array to store the 7 values for the different selections V0 related
103   Double_t  fCascadeVertexerSels[8];   // Array to store the 8 values for the different selections Casc. related
104
105 //===========================================================================================
106 //   Variables for Event Tree
107 //===========================================================================================
108   Float_t fAmplitude_V0A;   //!
109   Float_t fAmplitude_V0C;   //! 
110   Float_t fAmplitude_V0AEq; //!
111   Float_t fAmplitude_V0CEq; //! 
112   Float_t fCentrality_V0A;         //! 
113   Float_t fCentrality_V0C;         //! 
114   Float_t fCentrality_V0M;         //! 
115   Float_t fCentrality_V0AEq;       //! 
116   Float_t fCentrality_V0CEq;       //! 
117   Float_t fCentrality_V0MEq;       //! 
118   Int_t fRefMultEta5;              //!
119   Int_t fRefMultEta8;              //! 
120   Int_t fTrueMultEta5;             //!   
121   Int_t fTrueMultEta8;             //!  
122   Int_t fTrueMultVZEROA;           //!
123   Int_t fTrueMultVZEROC;           //!  
124   Int_t fRunNumber;                //!
125
126 //===========================================================================================
127 //   Variables for V0 Tree
128 //===========================================================================================
129         Float_t fTreeVariableChi2V0;         //!
130         Float_t fTreeVariableDcaV0Daughters; //!
131         Float_t fTreeVariableDcaV0ToPrimVertex; //!
132         Float_t fTreeVariableDcaPosToPrimVertex; //!
133         Float_t fTreeVariableDcaNegToPrimVertex; //!
134         Float_t fTreeVariableV0CosineOfPointingAngle; //!
135         Float_t fTreeVariableV0Radius; //!
136         Float_t fTreeVariablePt; //!
137         Float_t fTreeVariablePtMC; //!
138         Float_t fTreeVariableRapK0Short; //!
139         Float_t fTreeVariableRapLambda; //!
140         Float_t fTreeVariableRapMC; //!
141         Float_t fTreeVariableInvMassK0s; //!
142         Float_t fTreeVariableInvMassLambda; //!
143         Float_t fTreeVariableInvMassAntiLambda; //!
144         Float_t fTreeVariableAlphaV0; //!
145         Float_t fTreeVariablePtArmV0;//!
146         Float_t fTreeVariableNegEta; //!
147         Float_t fTreeVariablePosEta; //!
148
149         Float_t fTreeVariableNSigmasPosProton; //!
150         Float_t fTreeVariableNSigmasPosPion; //! 
151         Float_t fTreeVariableNSigmasNegProton; //!
152         Float_t fTreeVariableNSigmasNegPion; //! 
153         
154         Float_t fTreeVariableDistOverTotMom;//!
155         Int_t   fTreeVariableLeastNbrCrossedRows;//!
156         Float_t fTreeVariableLeastRatioCrossedRowsOverFindable;//!
157
158   //Event Multiplicity Variables 
159   Float_t fTreeVariableCentV0A;    //!
160   Float_t fTreeVariableCentV0C;    //!
161   Float_t fTreeVariableCentV0M;    //!
162   Float_t fTreeVariableCentV0AEq;  //!
163   Float_t fTreeVariableCentV0CEq;  //!
164   Float_t fTreeVariableCentV0MEq;  //!
165   Float_t fTreeVariableAmpV0A;     //!
166   Float_t fTreeVariableAmpV0C;     //!
167   Float_t fTreeVariableAmpV0AEq;   //!
168   Float_t fTreeVariableAmpV0CEq;   //!
169   Int_t   fTreeVariableRefMultEta8;  //!
170   Int_t   fTreeVariableRefMultEta5;  //!
171   Int_t   fTreeVariableRunNumber; //! //want to re-quantile per run? here's your ticket
172
173   //MC exclusive Characteristics: 7, also required for feeddown tests
174   Float_t fTreeVariablePtMother; //!
175   Int_t fTreeVariablePID; //!
176   Int_t fTreeVariablePIDPositive; //!
177   Int_t fTreeVariablePIDNegative; //!
178   Int_t fTreeVariablePIDMother; //!
179   Int_t fTreeVariablePrimaryStatus; //!
180   Int_t fTreeVariablePrimaryStatusMother; //!
181
182
183 //===========================================================================================
184 //   Variables for Cascade Candidate Tree
185 //===========================================================================================
186   Int_t fTreeCascVarCharge;         //! 
187   Float_t fTreeCascVarMassAsXi;     //! 
188   Float_t fTreeCascVarMassAsOmega;  //! 
189   Float_t fTreeCascVarPt;           //!
190   Float_t fTreeCascVarPtMC;         //!
191   Float_t fTreeCascVarRapXi;        //!
192   Float_t fTreeCascVarRapOmega;     //!
193   Float_t fTreeCascVarRapMC;        //!
194   Float_t fTreeCascVarNegEta;       //!
195   Float_t fTreeCascVarPosEta;       //!
196   Float_t fTreeCascVarBachEta;      //!
197   Float_t fTreeCascVarDCACascDaughters; //!
198   Float_t fTreeCascVarDCABachToPrimVtx; //!
199   Float_t fTreeCascVarDCAV0Daughters;   //!
200   Float_t fTreeCascVarDCAV0ToPrimVtx;   //!
201   Float_t fTreeCascVarDCAPosToPrimVtx;  //!
202   Float_t fTreeCascVarDCANegToPrimVtx;  //!
203   Float_t fTreeCascVarCascCosPointingAngle;         //!
204   Float_t fTreeCascVarCascRadius;                   //!
205   Float_t fTreeCascVarV0Mass;                       //!
206   Float_t fTreeCascVarV0CosPointingAngle;           //!
207   Float_t fTreeCascVarV0CosPointingAngleSpecial;    //!
208   Float_t fTreeCascVarV0Radius;                     //!
209   Int_t   fTreeCascVarLeastNbrClusters;             //!
210   Float_t fTreeCascVarDistOverTotMom;               //!
211
212   //TPC dEdx 
213   Float_t fTreeCascVarNegNSigmaPion;   //!
214   Float_t fTreeCascVarNegNSigmaProton; //!
215   Float_t fTreeCascVarPosNSigmaPion;   //! 
216   Float_t fTreeCascVarPosNSigmaProton; //! 
217   Float_t fTreeCascVarBachNSigmaPion;  //! 
218   Float_t fTreeCascVarBachNSigmaKaon;  //! 
219
220   //Event Multiplicity Variables 
221   Float_t fTreeCascVarCentV0A;    //!
222   Float_t fTreeCascVarCentV0C;    //!
223   Float_t fTreeCascVarCentV0M;    //!
224   Float_t fTreeCascVarCentV0AEq;  //!
225   Float_t fTreeCascVarCentV0CEq;  //!
226   Float_t fTreeCascVarCentV0MEq;  //!
227   Float_t fTreeCascVarAmpV0A;     //!
228   Float_t fTreeCascVarAmpV0C;     //!
229   Float_t fTreeCascVarAmpV0AEq;   //!
230   Float_t fTreeCascVarAmpV0CEq;   //!
231   Int_t fTreeCascVarRefMultEta8;  //!
232   Int_t fTreeCascVarRefMultEta5;  //!
233   Int_t fTreeCascVarTrueMultEta5; //!
234   Int_t fTreeCascVarTrueMultEta8; //!
235   Int_t fTreeCascVarTrueMultVZEROA; //!
236   Int_t fTreeCascVarTrueMultVZEROC; //!  
237
238   //MC-only Variables
239   Int_t   fTreeCascVarIsPhysicalPrimary; //!
240   Int_t   fTreeCascVarPID;         //!
241
242   Int_t   fTreeCascVarRunNumber;         //!
243
244 //===========================================================================================
245 //   Histograms
246 //===========================================================================================
247
248   TH1D *fHistEventCounter; //! 
249
250 //===========================================================================================
251 //  Histos needed for efficiency computation || Xis 
252 //===========================================================================================
253
254   //These are all analysis-level
255
256   //Let's not care too much about rapidity at the moment! 
257   TH1D *fHistPt_GenK0Short;      //! 
258   TH1D *fHistPt_GenLambda;       //! 
259   TH1D *fHistPt_GenAntiLambda;   //! 
260
261   TH1D *fHistPt_GenXiMinus;      //! 
262   TH1D *fHistPt_GenXiPlus;       //! 
263   TH1D *fHistPt_GenOmegaMinus;   //! 
264   TH1D *fHistPt_GenOmegaPlus;    //! 
265
266   //VsRefMult
267   TH2D *fHistPtVsRefMultEta5_GenXiMinus;      //!
268   TH2D *fHistPtVsRefMultEta5_GenXiPlus;       //! 
269   TH2D *fHistPtVsRefMultEta5_GenOmegaMinus;   //! 
270   TH2D *fHistPtVsRefMultEta5_GenOmegaPlus;    //!  
271   TH2D *fHistPtVsRefMultEta8_GenXiMinus;      //!
272   TH2D *fHistPtVsRefMultEta8_GenXiPlus;       //! 
273   TH2D *fHistPtVsRefMultEta8_GenOmegaMinus;   //! 
274   TH2D *fHistPtVsRefMultEta8_GenOmegaPlus;    //!  
275
276   //VsCentralities
277   TH2D *fHistPtVsCentV0A_GenXiMinus;      //!
278   TH2D *fHistPtVsCentV0A_GenXiPlus;       //! 
279   TH2D *fHistPtVsCentV0A_GenOmegaMinus;   //! 
280   TH2D *fHistPtVsCentV0A_GenOmegaPlus;    //!  
281   TH2D *fHistPtVsCentV0C_GenXiMinus;      //!
282   TH2D *fHistPtVsCentV0C_GenXiPlus;       //! 
283   TH2D *fHistPtVsCentV0C_GenOmegaMinus;   //! 
284   TH2D *fHistPtVsCentV0C_GenOmegaPlus;    //!  
285   TH2D *fHistPtVsCentV0M_GenXiMinus;      //!
286   TH2D *fHistPtVsCentV0M_GenXiPlus;       //! 
287   TH2D *fHistPtVsCentV0M_GenOmegaMinus;   //! 
288   TH2D *fHistPtVsCentV0M_GenOmegaPlus;    //!  
289
290   //Equalized
291   TH2D *fHistPtVsCentV0AEq_GenXiMinus;      //!
292   TH2D *fHistPtVsCentV0AEq_GenXiPlus;       //! 
293   TH2D *fHistPtVsCentV0AEq_GenOmegaMinus;   //! 
294   TH2D *fHistPtVsCentV0AEq_GenOmegaPlus;    //!  
295   TH2D *fHistPtVsCentV0CEq_GenXiMinus;      //!
296   TH2D *fHistPtVsCentV0CEq_GenXiPlus;       //! 
297   TH2D *fHistPtVsCentV0CEq_GenOmegaMinus;   //! 
298   TH2D *fHistPtVsCentV0CEq_GenOmegaPlus;    //!  
299   TH2D *fHistPtVsCentV0MEq_GenXiMinus;      //!
300   TH2D *fHistPtVsCentV0MEq_GenXiPlus;       //! 
301   TH2D *fHistPtVsCentV0MEq_GenOmegaMinus;   //! 
302   TH2D *fHistPtVsCentV0MEq_GenOmegaPlus;    //!  
303
304   //VsAmp
305   TH2D *fHistPtVsAmpV0A_GenXiMinus;      //!
306   TH2D *fHistPtVsAmpV0A_GenXiPlus;       //! 
307   TH2D *fHistPtVsAmpV0A_GenOmegaMinus;   //! 
308   TH2D *fHistPtVsAmpV0A_GenOmegaPlus;    //!  
309   TH2D *fHistPtVsAmpV0C_GenXiMinus;      //!
310   TH2D *fHistPtVsAmpV0C_GenXiPlus;       //! 
311   TH2D *fHistPtVsAmpV0C_GenOmegaMinus;   //! 
312   TH2D *fHistPtVsAmpV0C_GenOmegaPlus;    //!  
313   TH2D *fHistPtVsAmpV0M_GenXiMinus;      //!
314   TH2D *fHistPtVsAmpV0M_GenXiPlus;       //! 
315   TH2D *fHistPtVsAmpV0M_GenOmegaMinus;   //! 
316   TH2D *fHistPtVsAmpV0M_GenOmegaPlus;    //!  
317   //Equalized Amps
318   TH2D *fHistPtVsAmpV0AEq_GenXiMinus;      //!
319   TH2D *fHistPtVsAmpV0AEq_GenXiPlus;       //! 
320   TH2D *fHistPtVsAmpV0AEq_GenOmegaMinus;   //! 
321   TH2D *fHistPtVsAmpV0AEq_GenOmegaPlus;    //!  
322   TH2D *fHistPtVsAmpV0CEq_GenXiMinus;      //!
323   TH2D *fHistPtVsAmpV0CEq_GenXiPlus;       //! 
324   TH2D *fHistPtVsAmpV0CEq_GenOmegaMinus;   //! 
325   TH2D *fHistPtVsAmpV0CEq_GenOmegaPlus;    //!  
326   TH2D *fHistPtVsAmpV0MEq_GenXiMinus;      //!
327   TH2D *fHistPtVsAmpV0MEq_GenXiPlus;       //! 
328   TH2D *fHistPtVsAmpV0MEq_GenOmegaMinus;   //! 
329   TH2D *fHistPtVsAmpV0MEq_GenOmegaPlus;    //!  
330
331
332    AliAnalysisTaskStrangenessVsMultiplicityMC(const AliAnalysisTaskStrangenessVsMultiplicityMC&);            // not implemented
333    AliAnalysisTaskStrangenessVsMultiplicityMC& operator=(const AliAnalysisTaskStrangenessVsMultiplicityMC&); // not implemented
334    
335    ClassDef(AliAnalysisTaskStrangenessVsMultiplicityMC, 11);
336 };
337
338 #endif