]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWGCF/Correlations/DPhi/AliDptDptInMC.h
AliAODEvent::GetHeader() returns AliVHeader
[u/mrichter/AliRoot.git] / PWGCF / Correlations / DPhi / AliDptDptInMC.h
CommitLineData
1486c432
MW
1#ifndef AliDptDptInMC_H_Included
2#define AliDptDptInMC_H_Included
3
4#include "AliAnalysisTaskSE.h"
5#include "TString.h"
6#include "AliLog.h"
7
8#include "AliPID.h"
947cb887 9#include "AliPIDResponse.h"
fe9d7d9d 10
1486c432
MW
11class AliAODEvent;
12class AliESDEvent;
13class AliInputEventHandler;
14class TH1;
15class TH2;
16class TH2;
17class TH3;
18class TH1F;
19class TH2F;
20class TH2F;
21class TH3F;
22class TH1D;
23class TH2D;
24class TH2D;
25class TH3D;
26class TProfile;
27
28
29
30class AliDptDptInMC : public AliAnalysisTaskSE
31{
32public:
33 AliDptDptInMC();
34 AliDptDptInMC(const TString & name);
35
36private:
37 AliDptDptInMC(const AliDptDptInMC&);
38 const AliDptDptInMC& operator=(const AliDptDptInMC&);
39
40public:
41 virtual ~AliDptDptInMC();
42
43 // Implementation of interace methods
44 //virtual void ConnectInputData(Option_t *);
45 virtual void UserCreateOutputObjects();
46 virtual void UserExec(Option_t *option);
47 virtual void FinishTaskOutput();
48 virtual void Terminate(Option_t* );
49 virtual void createHistograms();
50 virtual void finalizeHistograms();
51
52 virtual void addToList(TH1 *h);
53
54 TH1D * createHisto1D(const TString & name, const TString & title,int n, double xmin, double xmax,const TString & xTitle, const TString & yTitle);
55 TH1D * createHisto1D(const TString & name, const TString & title,int n, double * bins,const TString & xTitle, const TString & yTitle);
56 TH2D * createHisto2D(const TString & name, const TString & title,
57 int nx, double xmin, double xmax, int ny, double ymin, double ymax, const TString & xTitle, const TString & yTitle, const TString & zTitle);
58 TH2D * createHisto2D(const TString & name, const TString & title, int nx, double* xbins, int ny, double ymin, double ymax,
59 const TString & xTitle, const TString & yTitle, const TString & zTitle);
60
61 TH1F * createHisto1F(const TString & name, const TString & title,int n, double xmin, double xmax,const TString & xTitle, const TString & yTitle);
62 TH1F * createHisto1F(const TString & name, const TString & title,int n, double * bins,const TString & xTitle, const TString & yTitle);
63 TH2F * createHisto2F(const TString & name, const TString & title,
64 int nx, double xmin, double xmax, int ny, double ymin, double ymax, const TString & xTitle, const TString & yTitle, const TString & zTitle);
65 TH2F * createHisto2F(const TString & name, const TString & title, int nx, double* xbins, int ny, double ymin, double ymax,
66 const TString & xTitle, const TString & yTitle, const TString & zTitle);
67 TH3F * createHisto3F(const TString & name, const TString & title,
68 int nx, double xmin, double xmax, int ny, double ymin, double ymax, int nz, double zmin, double zmax,
69 const TString & xTitle, const TString & yTitle, const TString & zTitle);
70 TProfile * createProfile(const TString & title,const TString & description, int n, double xMin,double xMax,
71 const TString & xTitle, const TString & yTitle);
72 TProfile * createProfile(const TString & name,const TString & description,
73 int nx, double* bins,
74 const TString & xTitle, const TString & yTitle);
75
76 //________________________________________________________________________
77
78 float * getFloatArray(int size, float v);
79 double * getDoubleArray(int size, double v);
80 void fillHistoWithArray(TH1 * h, double * array, int size);
81 void fillHistoWithArray(TH2 * h, double * array, int size1, int size2);
82 void fillHistoWithArray(TH3 * h, double * array, int size1, int size2, int size3);
83 void fillHistoWithArray(TH1 * h, float * array, int size);
84 void fillHistoWithArray(TH2 * h, float * array, int size1, int size2);
85 void fillHistoWithArray(TH3 * h, float * array, int size1, int size2, int size3);
86
87
88
89
90 virtual void SetDebugLevel( int v ) { _debugLevel = v; }
91 virtual void SetSinglesOnly(int v) { _singlesOnly = v; }
92 virtual void SetUseWeights(int v) { _useWeights = v; }
93 virtual void SetSameFilter(int v) { _sameFilter = v; }
94
95 virtual void SetRejectPileup(int v) { _rejectPileup = v; }
96 virtual void SetRejectPairConversion(int v) { _rejectPairConversion = v; }
97 virtual void SetVertexZMin(double v) { _vertexZMin = v; }
98 virtual void SetVertexZMax(double v) { _vertexZMax = v; }
99 virtual void SetVertexXYMin(double v) { _vertexXYMin = v; }
100 virtual void SetVertexXYMax(double v) { _vertexXYMax = v; }
101 virtual void SetCentralityMethod(int v) { _centralityMethod = v; }
102 virtual void SetCentrality(double centralityMin, double centralityMax)
103 {
104 _centralityMin = centralityMin;
105 _centralityMax = centralityMax;
106 }
107 virtual void SetRequestedCharge_1(int v) { _requestedCharge_1 = v; }
108 virtual void SetRequestedCharge_2(int v) { _requestedCharge_2 = v; }
109 virtual void SetPtMin1( double v) { _min_pt_1 = v; }
110 virtual void SetPtMax1( double v) { _max_pt_1 = v; }
111 virtual void SetEtaMin1(double v) { _min_eta_1 = v; }
112 virtual void SetEtaMax1(double v) { _max_eta_1 = v; }
113 virtual void SetPtMin2( double v) { _min_pt_2 = v; }
114 virtual void SetPtMax2( double v) { _max_pt_2 = v; }
115 virtual void SetEtaMin2(double v) { _min_eta_2 = v; }
116 virtual void SetEtaMax2(double v) { _max_eta_2 = v; }
117 virtual void SetDcaZMin(double v) { _dcaZMin = v; }
118 virtual void SetDcaZMax(double v) { _dcaZMax = v; }
119 virtual void SetDcaXYMin(double v) { _dcaXYMin = v; }
120 virtual void SetDcaXYMax(double v) { _dcaXYMax = v; }
121 virtual void SetDedxMin(double v) { _dedxMin = v; }
122 virtual void SetDedxMax(double v) { _dedxMax = v; }
123 virtual void SetNClusterMin(int v) { _nClusterMin = v; }
124 virtual void SetTrackFilterBit(int v) { _trackFilterBit = v; }
125 virtual void SetWeigth_1(TH3F * v) { _weight_1 = v; }
126 virtual void SetWeigth_2(TH3F * v) { _weight_2 = v; }
127
128 void SetNSigmaCut(Double_t nsigma){ fNSigmaCut = nsigma;}
129
130 void SetAnalysisType(const char* analysisType) {fAnalysisType = analysisType;}
131 void SetResonancesCut( Bool_t NoResonances ){ fExcludeResonancesInMC = NoResonances;}
132 void SetElectronCut( Bool_t NoElectron ){ fExcludeElectronsInMC = NoElectron;}
133
134protected:
135
136 // Handlers and events
137 AliAODEvent* fAODEvent; //! AOD Event
138 AliESDEvent* fESDEvent; //! ESD Event
139 AliInputEventHandler* fInputHandler; //! Generic InputEventHandler
140
947cb887 141 AliPIDResponse* fPIDResponse;
1486c432
MW
142
143 // Histogram settings
144 //TList* _inputHistoList;
145 TList* _outputHistoList;
146 //int _outputSlot;
147
148 TClonesArray *fArrayMC;
149 double _twoPi;
150 long _eventCount;
151
152 //configuration variables and filters
153 int _debugLevel;
154 int _singlesOnly;
155 int _useWeights;
156 int _sameFilter;
157 int _rejectPileup;
158 int _rejectPairConversion;
159 double _vertexZMin;
160 double _vertexZMax;
161 double _vertexXYMin;
162 double _vertexXYMax;
163 int _centralityMethod;
164 double _centralityMin;
165 double _centralityMax;
166 int _requestedCharge_1;
167 int _requestedCharge_2;
168 double _dcaZMin;
169 double _dcaZMax;
170 double _dcaXYMin;
171 double _dcaXYMax;
172 double _dedxMin;
173 double _dedxMax;
174 int _nClusterMin;
175 int _trackFilterBit;
176 Double_t fNSigmaCut;
177
178 //double _min_eta_1;
179 //double _max_eta_1;
180 //double _min_eta_2;
181 //double _max_eta_2;
182 TString fAnalysisType;
183
184 Bool_t fExcludeResonancesInMC;
185 Bool_t fExcludeElectronsInMC;
186
187 // event and track wise variables
188
189 double _field;
190 int _nTracks;
191 double _mult0;
192 double _mult1;
193 double _mult2;
194 double _mult3;
195 double _mult4;
196 double _mult4a;
197 double _mult5;
198 double _mult6;
199
200 //particle 1
201 int arraySize;
202 int *_id_1; //!
203 int *_charge_1; //!
204 //int * _iPhi_1; //!
205 //int * _iEta_1; //!
206 int *_iEtaPhi_1; //!
207 int *_iPt_1; //!
208 float *_pt_1; //!
209 float *_px_1; //!
210 float *_py_1; //!
211 float *_pz_1; //!
212 //float * _phi_1; //!
213 //float* _eta_1; //!
214 float *_correction_1; //!
215 float *_dedx_1; //!
216
217 //particle 2
218 int *_id_2; //!
219 int *_charge_2; //!
220 //int *_iPhi_2; //!
221 //int *_iEta_2; //!
222 int *_iEtaPhi_2; //!
223 int *_iPt_2; //!
224 float *_pt_2; //!
225 float *_px_2; //!
226 float *_py_2; //!
227 float *_pz_2; //!
228 //float *_phi_2; //!
229 //float *_eta_2; //!
230 float *_correction_2; //!
231 float *_dedx_2; //!
232
233 float * _correctionWeight_1; //!
234 float * _correctionWeight_2; //!
235
236 //histograming
237 int _nBins_M0; double _min_M0; double _max_M0; double _width_M0;
238 int _nBins_M1; double _min_M1; double _max_M1; double _width_M1;
239 int _nBins_M2; double _min_M2; double _max_M2; double _width_M2;
240 int _nBins_M3; double _min_M3; double _max_M3; double _width_M3;
241 int _nBins_M4; double _min_M4; double _max_M4; double _width_M4;
242 int _nBins_M5; double _min_M5; double _max_M5; double _width_M5;
243 int _nBins_M6; double _min_M6; double _max_M6; double _width_M6;
244
245 int _nBins_vertexZ; double _min_vertexZ; double _max_vertexZ; double _width_vertexZ;
246
247 int _nBins_pt_1; double _min_pt_1; double _max_pt_1; double _width_pt_1;
248 int _nBins_phi_1; double _min_phi_1; double _max_phi_1; double _width_phi_1;
249 int _nBins_eta_1; double _min_eta_1; double _max_eta_1; double _width_eta_1;
250 int _nBins_etaPhi_1;
251 int _nBins_etaPhiPt_1;
252 int _nBins_zEtaPhiPt_1;
253
254 int _nBins_pt_2; double _min_pt_2; double _max_pt_2; double _width_pt_2;
255 int _nBins_phi_2; double _min_phi_2; double _max_phi_2; double _width_phi_2;
256 int _nBins_eta_2; double _min_eta_2; double _max_eta_2; double _width_eta_2;
257 int _nBins_etaPhi_2;
258 int _nBins_etaPhiPt_2;
259 int _nBins_zEtaPhiPt_2;
260
261 int _nBins_etaPhi_12;
262
263 double __n1_1;
264 double __n1_2;
265 double __n2_12;
266 double __s1pt_1;
267 double __s1pt_2;
268 double __s2ptpt_12;
269 double __s2NPt_12;
270 double __s2PtN_12;
271
272 double __n1Nw_1;
273 double __n1Nw_2;
274 double __n2Nw_12;
275 double __s1ptNw_1;
276 double __s1ptNw_2;
277 double __s2ptptNw_12;
278 double __s2NPtNw_12;
279 double __s2PtNNw_12;
280
281 double * __n1_1_vsPt; //!
947cb887 282
1486c432
MW
283 double * __n1_1_vsEtaPhi; //!
284 double * __s1pt_1_vsEtaPhi; //!
285 float * __n1_1_vsZEtaPhiPt; //!
286
287 double * __n1_2_vsPt; //!
288 double * __n1_2_vsEtaPhi; //!
289 double * __s1pt_2_vsEtaPhi; //!
290 float * __n1_2_vsZEtaPhiPt; //!
291
292 //double * __n2_12_vsPtPt;
293 //double * __n2_12_vsEtaPhi;
294 //double * __s2ptpt_12_vsEtaPhi;
295 //double * __s2PtN_12_vsEtaPhi;
296 //double * __s2NPt_12_vsEtaPhi;
297
298 double * __n2_12_vsPtPt; //!
299 float * __n2_12_vsEtaPhi; //!
300 float * __s2ptpt_12_vsEtaPhi; //!
301 float * __s2PtN_12_vsEtaPhi; //!
302 float * __s2NPt_12_vsEtaPhi; //!
303
304 TH3F * _weight_1;
305 TH3F * _weight_2;
306 TH1D * _eventAccounting;
307 TH1D * _m0;
308 TH1D * _m1;
309 TH1D * _m2;
310 TH1D * _m3;
311 TH1D * _m4;
312 TH1D * _m5;
313 TH1D * _m6;
314 TH1D * _vertexZ;
315
316 TH1F * _Ncluster1;
317 TH1F * _Ncluster2;
318 TH1F * _etadis;
319 TH1F * _phidis;
320 TH1F * _dcaz;
321 TH1F * _dcaxy;
0f50230b 322 TH1F * _etadis2;
323 TH1F * _phidis2;
324 TH1F * _dcaz2;
325 TH1F * _dcaxy2;
326 TH1F * _etadis3;
327 TH1F * _phidis3;
328 TH1F * _dcaz3;
329 TH1F * _dcaxy3;
1486c432
MW
330
331
332 // PARTICLE 1 (satisfies filter 1)
333 // Primary filled quantities
334 TH1F * _n1_1_vsPt;
335 TH2F * _n1_1_vsEtaVsPhi;
336 TH2F * _s1pt_1_vsEtaVsPhi;
337 TH3F * _n1_1_vsZVsEtaVsPhiVsPt;
338 TProfile * _n1_1_vsM; // w/ weight
339 TProfile * _s1pt_1_vsM;
340 TProfile * _n1Nw_1_vsM; // w/o weight
341 TProfile * _s1ptNw_1_vsM;
342 TH2D * _dedxVsP_1;
343 TH2D * _corrDedxVsP_1;
344 TH2F * _betaVsP_1;
345
346 // PARTICLE 2 (satisfies filter 2)
347 // Primary filled quantities
348 TH1F * _n1_2_vsPt;
349 TH2F * _n1_2_vsEtaVsPhi;
350 TH2F * _s1pt_2_vsEtaVsPhi;
351 TH3F * _n1_2_vsZVsEtaVsPhiVsPt;
352 TProfile * _n1_2_vsM;
353 TProfile * _s1pt_2_vsM;
354 TProfile * _n1Nw_2_vsM; // w/o weight
355 TProfile * _s1ptNw_2_vsM;
356 TH2D * _dedxVsP_2;
357 TH2D * _corrDedxVsP_2;
358 TH2F * _betaVsP_2;
359
360 // Pairs 1 & 2
361 TH1F * _n2_12_vsEtaPhi;
362 TH2F * _n2_12_vsPtVsPt;
363 TH1F * _s2PtPt_12_vsEtaPhi;
364 TH1F * _s2PtN_12_vsEtaPhi;
365 TH1F * _s2NPt_12_vsEtaPhi;
366
367 TProfile * _n2_12_vsM;
368 TProfile * _s2PtPt_12_vsM;
369 TProfile * _s2PtN_12_vsM;
370 TProfile * _s2NPt_12_vsM;
371 TProfile * _n2Nw_12_vsM;
372 TProfile * _s2PtPtNw_12_vsM;
373 TProfile * _s2PtNNw_12_vsM;
374 TProfile * _s2NPtNw_12_vsM;
375
376 TH1F * _invMass;
377 TH1F * _invMassElec;
378
379 TString n1Name;
380 TString n1NwName;
381 TString n2Name;
382 TString n2NwName;
383 TString n3Name;
384 TString n1n1Name;
385 TString n1n1n1Name;
386 TString n2n1Name;
387 TString r1Name;
388 TString r2Name;
389 TString r3Name;
390 TString r2r1Name;
391 TString c2Name;
392 TString c3Name;
393 TString d3Name;
394 TString p3Name;
395 TString cName;
396
397 TString intR2Name;
398 TString binCorrName;
399 TString intBinCorrName;
400
401 TString countsName;
402 TString part_1_Name;
403 TString part_2_Name;
404 TString part_3_Name;
405 TString pair_12_Name;
406 TString pair_13_Name;
407 TString pair_23_Name;
408 TString tripletName;
409
410 TString avg;
411 TString avgName;
412 TString sumName;
413 TString s1ptName;
414 TString s1ptNwName;
415 TString s1DptName;
416
417 TString s2PtPtName;
418 TString s2NPtName;
419 TString s2PtNName;
420 TString s2DptDptName;
421
422 TString s2PtPtNwName;
423 TString s2NPtNwName;
424 TString s2PtNNwName;
425
426 TString ptName;
427 TString ptptName;
428 TString pt1pt1Name;
429 TString DptName;
430 TString DptDptName;
431 TString RDptDptName;
432 TString nPtName;
433 TString ptNName;
434 TString seanName;
435
436 TString _title_counts;
437
438 TString _title_m0;
439 TString _title_m1;
440 TString _title_m2;
441 TString _title_m3;
442 TString _title_m4;
443 TString _title_m5;
444 TString _title_m6;
445
446 TString _title_eta_1;
447 TString _title_phi_1;
448 TString _title_pt_1;
449 TString _title_etaPhi_1;
450 TString _title_n_1;
451 TString _title_SumPt_1;
452 TString _title_AvgPt_1;
453 TString _title_AvgN_1;
454 TString _title_AvgSumPt_1;
455
456 TString _title_eta_2;
457 TString _title_phi_2;
458 TString _title_pt_2;
459 TString _title_etaPhi_2;
460 TString _title_n_2;
461 TString _title_SumPt_2;
462 TString _title_AvgPt_2;
463 TString _title_AvgN_2;
464 TString _title_AvgSumPt_2;
465
466 TString _title_etaPhi_12;
467
468 TString _title_AvgN2_12;
469 TString _title_AvgSumPtPt_12;
470 TString _title_AvgSumPtN_12;
471 TString _title_AvgNSumPt_12;
472
473 TString vsZ;
474 TString vsM;
475 TString vsPt;
476 TString vsPhi;
477 TString vsEta;
478 TString vsEtaPhi;
479 TString vsPtVsPt;
480
481
482 ClassDef(AliDptDptInMC,1)
483};
484
485
486#endif
487
488