AliPhysics  608b256 (608b256)
AliAnalysisTaskMultiparticleFemtoscopy.h
Go to the documentation of this file.
1 /*
2  * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved.
3  * See cxx source for full Copyright notice
4  * $Id$
5  */
6 
7  /********************************
8  * femtoscopy with multiparticle *
9  * technology *
10  * *
11  * author: Ante Bilandzic *
12  * (abilandzic@gmail.com) *
13  ********************************/
14 
15 #ifndef ALIANALYSISTASKMULTIPARTICLEFEMTOSCOPY_H
16 #define ALIANALYSISTASKMULTIPARTICLEFEMTOSCOPY_H
17 
18 #include "AliAnalysisTaskSE.h"
19 #include "AliPIDResponse.h"
20 #include "AliAODTrack.h"
21 #include "AliAODEvent.h"
22 #include "AliVEvent.h"
23 #include "AliESDEvent.h"
24 #include "AliMCEvent.h"
25 #include "AliAODMCParticle.h"
26 #include "TExMap.h"
27 #include "TProfile.h"
28 #include "TProfile2D.h"
29 #include "TH1F.h"
30 #include "TH1I.h"
31 #include "THnSparse.h"
32 #include "TSystem.h"
33 
34 //================================================================================================================
35 
37  public:
39  AliAnalysisTaskMultiparticleFemtoscopy(const char *name, Bool_t useParticleWeights=kFALSE);
41  virtual void UserCreateOutputObjects();
42  virtual void UserExec(Option_t *);
43  virtual void Terminate(Option_t *);
44 
45  // 0.) Methods called in the constructor:
46  virtual void InitializeArrays(); // use this method temporarily for all objects not classified yet
48  virtual void InitializeArraysForEBEObjects();
50  virtual void InitializeArraysForBackground();
51  virtual void InitializeArraysForBuffers();
52  virtual void InitializeArraysForQA();
55  virtual void InitializeArraysForBackgroundTEST();
56  virtual void InitializeArraysForHybridApproach();
57  virtual void InitializeArraysForMPDF();
58 
59  // 1.) Methods called in UserCreateOutputObjects():
60  // 2a) Directly:
62  virtual void BookAndNestAllLists();
63  virtual void BookEverything(); // use this to book all un-classified objects
65  virtual void BookEverythingForEBEObjects();
67  virtual void BookEverythingForBackground();
68  virtual void BookEverythingForBuffers();
69  virtual void BookEverythingForQA();
70  virtual void BookEverythingForGlobalTrackCuts();
72  virtual void BookEverythingForBackgroundTEST();
73  virtual void BookEverythingForHybridApproach();
74  virtual void BookEverythingForMPDF();
75  // 2b) Indirectly:
76  Int_t InsanityChecksForGlobalTrackCuts(); // insanity checks for global track cuts
77 
78  // 2.) Methods called in UserExec(Option_t *):
79  // 2a) Directly:
80  virtual void InsanityChecksUserExec();
81  virtual void QA(AliVEvent *ave);
82  virtual void MC(AliMCEvent *aMC);
83  virtual void ESD(AliESDEvent *aESD);
84  virtual void AOD(AliAODEvent *aAOD);
85  virtual void OnlineMonitoring();
86  virtual void DoHybridApproach(AliVEvent *ave);
87  virtual void DoMPDF(AliVEvent *ave);
88  // 2b) Indirectly:
89  virtual void EstimateBackground(AliVEvent *ave);
90  virtual void EstimateBackgroundTEST(AliVEvent *ave);
91  virtual void FillControlHistogramsEvent(AliVEvent *ave);
92  virtual void FillControlHistogramsParticle(AliVEvent *ave);
93  virtual void FillControlHistogramsNonIdentifiedParticles(AliAODTrack *atrack);
94  virtual void FillControlHistogramsNonIdentifiedParticles(AliAODMCParticle *amcparticle);
95  virtual void FillControlHistogramsNonIdentifiedParticlesFTSF(AliAODTrack *atrack);
96  virtual void FillControlHistogramsIdentifiedParticles(AliAODTrack *atrack, AliAODTrack *gtrack);
97  virtual void FillControlHistogramsIdentifiedParticles(AliAODMCParticle *amcparticle);
98  virtual void V0s(AliVEvent *ave);
99  Int_t InsanityChecksForTracks(AliAODTrack *atrack); // insanity checks for each track ('atrack') in AOD
100  Int_t InsanityChecksForGlobalTracks(AliAODTrack *gtrack); // insanity checks only for global tracks ('gtrack') in AOD
101  Bool_t Pion(AliAODTrack *atrack, Int_t charge = 1, Bool_t bPrimary = kTRUE);
102  Bool_t Kaon(AliAODTrack *atrack, Int_t charge = 1, Bool_t bPrimary = kTRUE);
103  Bool_t Proton(AliAODTrack *atrack, Int_t charge = 1, Bool_t bPrimary = kTRUE);
104  Bool_t PassesCommonEventCuts(AliVEvent *ave);
105  Bool_t PassesMixedEventCuts(AliVEvent *ave);
106  Bool_t PassesGlobalTrackCuts(AliAODTrack *gtrack); // common cuts for global tracks TBI make it uniform with MC
107  Bool_t PassesCommonTrackCuts(AliAODTrack *atrack); // common cuts for analysis specific tracks (e.g. TPC-only) TBI make it uniform with MC
108  Bool_t PassesCommonTrackCuts(AliAODMCParticle *amcparticle); // common cuts for analysis specific tracks TBI see above two lines
109  virtual void GlobalTracksAOD(AliAODEvent *aAOD, Int_t index); // fill fGlobalTracksAOD in e-b-e . For the meaning of 'index', see declaration of fGlobalTracksAOD
110  virtual void GlobalTracksAODTEST(AliAODEvent *aAOD, Int_t index); // fill fGlobalTracksAODTEST in e-b-e . For the meaning of 'index', see declaration of fGlobalTracksAODTEST
111  virtual void GlobalTracksAODHA(AliAODEvent *aAOD, Int_t index); // fill fGlobalTracksAODHA in e-b-e . For the meaning of 'index', see declaration of fGlobalTracksAODHA
112  virtual void GlobalTracksAOD(AliAODEvent *aAOD, Int_t indexX, Int_t indexY); // fill TExMap *fGlobalTracksAOD1[10][5];
113  Double_t RelativeMomenta(AliAODTrack *agtrack1, AliAODTrack *agtrack2);
114  Double_t RelativeMomentaComponent(AliAODTrack *agtrack1, AliAODTrack *agtrack2, const char *component);
115  Double_t PairVectorComponent(AliAODTrack *agtrack1, AliAODTrack *agtrack2, const char *component);
116  Double_t RelativeMomenta(AliAODMCParticle *amcparticle1, AliAODMCParticle *amcparticle2);
117  Double_t Q2(AliAODTrack *agtrack1, AliAODTrack *agtrack2);
118  Double_t Q2(TLorentzVector lv1, TLorentzVector lv2);
119  Double_t Q3(AliAODTrack *agtrack1, AliAODTrack *agtrack2, AliAODTrack *agtrack3);
120  Double_t Q4(AliAODTrack *agtrack1, AliAODTrack *agtrack2, AliAODTrack *agtrack3, AliAODTrack *agtrack4);
121 
122  virtual void ResetEBEObjects();
123  Bool_t SpecifiedEvent(UInt_t run, UShort_t bunchCross, UInt_t orbit, UInt_t period);
125  virtual void DoSomeDebugging(AliVEvent *ave);
126  virtual void CalculateCorrelationFunctions(AliAODEvent *aAOD);
127  virtual void Calculate3pCorrelationFunctions(AliAODEvent *aAOD);
128  virtual void Calculate4pCorrelationFunctions(AliAODEvent *aAOD);
129  virtual void CalculateCorrelationFunctions(AliMCEvent *aMC);
131  virtual void Calculate2pBackground(TClonesArray *ca1, TClonesArray *ca2); // TBI soon will become obsolete
132  virtual void Calculate2pBackground(TClonesArray *ca1, TClonesArray *ca2, TExMap *em1, TExMap *em2);
133  virtual void Calculate2pBackgroundTEST(TClonesArray *ca1, TClonesArray *ca2, TExMap *em1, TExMap *em2);
134  virtual void Calculate3pBackground(TClonesArray *ca1, TClonesArray *ca2, TClonesArray *ca3); // TBI soon will become obsolete
135  virtual void Calculate3pBackground(TClonesArray *ca1, TClonesArray *ca2, TClonesArray *ca3, TExMap *em1, TExMap *em2, TExMap *em3);
136  virtual void Calculate3pBackgroundTEST(TClonesArray *ca1, TClonesArray *ca2, TClonesArray *ca3, TExMap *em1, TExMap *em2, TExMap *em3);
137  virtual void Calculate4pBackground(TClonesArray *ca1, TClonesArray *ca2, TClonesArray *ca3, TClonesArray *ca4);
138  virtual void Calculate2pBackground(TClonesArray *ca1, TClonesArray *ca2, Bool_t bMC); // TBI unify with the previous function
139  virtual void HybridApproach1stTerm(AliAODEvent *aAOD);
140  virtual void HybridApproach2ndTerm(AliAODEvent *aAOD, TClonesArray *ca3, TExMap *em3);
141  //virtual void HybridApproach3rdTerm(AliAODEvent *aAOD); // TBI not needed for the time being
142  //virtual void HybridApproach4thTerm(AliAODEvent *aAOD); // TBI not needed for the time being
143  virtual void HybridApproach5thTerm(TClonesArray *ca1, TClonesArray *ca2, TClonesArray *ca3, TExMap *em1, TExMap *em2, TExMap *em3);
144  virtual void CalculateMPDF2p(AliAODEvent *aAOD);
145  virtual void CalculateMPDF3p(AliAODEvent *aAOD);
146 
147  // 3.) Methods called in Terminate(Option_t *):
148  virtual void GetOutputHistograms(TList *histList);
149  // TBI implement the rest as well
150  virtual void GetPointersForCorrelationFunctions();
151  virtual void GetPointersForBackground();
152  virtual void GetPointersForBuffers();
153  virtual void GetPointersForMPDF();
154  virtual void NormalizeCorrelationFunctions();
155  virtual void ProjectMPDF2p();
156  virtual void ProjectMPDF3p();
157 
158  // 4.) Utility:
159  Int_t BinNoForSpecifiedValue(TH1F *hist, Double_t value);
160  Int_t BinNoForSpecifiedValue(TProfile *pro, Double_t value);
161  Double_t BinCenterSparse(THnSparse *hs, Int_t dim, Int_t binNo);
162 
163  // Setters and getters:
164  // 0.) Not classified yet;
165  // 1.) Control histograms;
166  // 2.) Event-by-event histograms;
167  // 3.) Correlation functions;
168  // 4.) Background;
169  // 5.) Buffers;
170  // 6.) QA;
171  // 7.) ...
172  // *.) Debugging
173 
174  // 0.) Not classified yet:
179  void SetProcessOnlyKine(Bool_t pok) {this->fProcessOnlyKine = pok;};
180  Bool_t GetProcessOnlyKine() const {return this->fProcessOnlyKine;};
181  void SetProcessOnlyReco(Bool_t por) {this->fProcessOnlyReco = por;};
182  Bool_t GetProcessOnlyReco() const {return this->fProcessOnlyReco;};
183  void SetRejectFakeTracks(Bool_t rft) {this->fRejectFakeTracks = rft;};
185 
186  // 1.) Control histograms:
187  void SetControlHistogramsList(TList* const chl) {this->fControlHistogramsList = chl;};
189  void SetControlHistogramsFlagsPro(TProfile* const chfp) {this->fControlHistogramsFlagsPro = chfp;};
190  TProfile* GetControlHistogramsFlagsPro() const {return this->fControlHistogramsFlagsPro;};
191  //void SetFillControlHistograms(Bool_t fch) {this->fFillControlHistograms = fch;}; // TBI remove eventually
192  //Bool_t GetFillControlHistograms() const {return this->fFillControlHistograms;}; // TBI remove eventually
199  void SetFilterBitFTSF(Int_t fbFTSF) {this->fFilterBitFTSF = fbFTSF;};
200  Int_t GetFilterBitFTSF() const {return this->fFilterBitFTSF;};
207  // 1d) Identified particles:
208  void SetInclusiveSigmaCuts(Int_t pidFunction, Double_t sigmaValue)
209  {
210  // pidFunction: [0=Electron(...),1=Muon(...),2=Pion(...),3=Kaon(...),4=Proton(...)]
211  // Example: SetInclusiveSigmaCuts(2,3.); sets in function Pion() inclusive cuts for pions to 3.0 sigmas
213  this->fInclusiveSigmaCuts[pidFunction] = sigmaValue;
214  };
215  void SetExclusiveSigmaCuts(Int_t pidFunction, Int_t pidExclusive, Double_t sigmaValue)
216  {
217  // pidFunction: [0=Electron(...),1=Muon(...),2=Pion(...),3=Kaon(...),4=Proton(...)]
218  // Example: SetExclusiveSigmaCuts(3,4,4.); sets in function Kaon() exclusive cuts for protons to 4.0 sigmas
220  this->fExclusiveSigmaCuts[pidFunction][pidExclusive] = sigmaValue;
221  };
222 
223  // 2.) Event-by-event histograms:
224  void SetEBEHistogramsList(TList* const ehl) {this->fEBEHistogramsList = ehl;};
226  void SetEBEObjectsFlagsPro(TProfile* const ehfp) {this->fEBEObjectsFlagsPro = ehfp;};
227  TProfile* GetEBEObjectsFlagsPro() const {return this->fEBEObjectsFlagsPro;};
228  //void SetFillEBEHistograms(Bool_t feh) {this->fFillEBEHistograms = feh;}; // TBI rethink
229  //Bool_t GetFillEBEHistograms() const {return this->fFillEBEHistograms;};
230 
231  // 3.) Correlation functions:
234  void SetCorrelationFunctionsFlagsPro(TProfile* const cffp) {this->fCorrelationFunctionsFlagsPro = cffp;};
236  void Set2pCorrelationFunctionsFlagsPro(TProfile* const cffp2p) {this->f2pCorrelationFunctionsFlagsPro = cffp2p;};
238  void Set3pCorrelationFunctionsFlagsPro(TProfile* const cffp3p) {this->f3pCorrelationFunctionsFlagsPro = cffp3p;};
240  void Set4pCorrelationFunctionsFlagsPro(TProfile* const cffp4p) {this->f4pCorrelationFunctionsFlagsPro = cffp4p;};
253  {
254  this->fNormalizeCorrelationFunctions = kTRUE;
255  this->fNormalizationOption = 1;
256  this->fNormalizationInterval[0] = min;
257  this->fNormalizationInterval[1] = max;
258  };
259  void SetnMergedBins(Int_t fnmb) {this->fnMergedBins = fnmb;};
260  Int_t GetnMergedBins() const {return this->fnMergedBins;};
261 
262  // 4.) Background:
263  void SetBackgroundList(TList* const bl) {this->fBackgroundList = bl;};
264  TList* GetBackgroundList() const {return this->fBackgroundList;}
265  void SetBackgroundFlagsPro(TProfile* const bfp) {this->fBackgroundFlagsPro = bfp;};
266  TProfile* GetBackgroundFlagsPro() const {return this->fBackgroundFlagsPro;};
267  void Set2pBackgroundFlagsPro(TProfile* const bfp2p) {this->f2pBackgroundFlagsPro = bfp2p;};
268  TProfile* Get2pBackgroundFlagsPro() const {return this->f2pBackgroundFlagsPro;};
269  void Set3pBackgroundFlagsPro(TProfile* const bfp3p) {this->f3pBackgroundFlagsPro = bfp3p;};
270  TProfile* Get3pBackgroundFlagsPro() const {return this->f3pBackgroundFlagsPro;};
271  void Set4pBackgroundFlagsPro(TProfile* const bfp4p) {this->f4pBackgroundFlagsPro = bfp4p;};
272  TProfile* Get4pBackgroundFlagsPro() const {return this->f4pBackgroundFlagsPro;};
274  Int_t GetBackgroundOption() const {return this->fBackgroundOption;};
281  void SetMaxBufferSize1(Int_t mbs1) {this->fMaxBufferSize1 = mbs1;};
282  Int_t GetMaxBufferSize1() const {return this->fMaxBufferSize1;};
283 
284  // 5.) Buffers:
285  void SetBuffersList(TList* const bl) {this->fBuffersList = bl;};
286  TList* GetBuffersList() const {return this->fBuffersList;}
287  void SetBuffersFlagsPro(TProfile* const bfp) {this->fBuffersFlagsPro = bfp;};
288  TProfile* GetBuffersFlagsPro() const {return this->fBuffersFlagsPro;};
289  void SetFillBuffers(Int_t mb) {this->fFillBuffers = kTRUE; this->fMaxBuffer = mb;};
290 
291  // 6.) QA:
292  void SetQAList(TList* const qal) {this->fQAList = qal;};
293  TList* GetQAList() const {return this->fQAList;}
294  void SetQAFlagsPro(TProfile* const qafp) {this->fQAFlagsPro = qafp;};
295  TProfile* GetQAlagsPro() const {return this->fQAFlagsPro;};
296  void SetBailOutAfterQA(Bool_t boaqa) {this->fBailOutAfterQA = boaqa;};
297  Bool_t GetBailOutAfterQA() const {return this->fBailOutAfterQA;};
298  void SetFillQAEvents(Bool_t ffqae) {this->fFillQAEvents = ffqae;};
299  Bool_t GetFillQAEvents() const {return this->fFillQAEvents;};
300  void SetFillQAParticles(Bool_t ffqap) {this->fFillQAParticles = ffqap;};
301  Bool_t GetFillQAParticles() const {return this->fFillQAParticles;};
302  void SetQAEventsList(TList* const qael) {this->fQAEventsList = qael;};
303  TList* GetQAEventsList() const {return this->fQAEventsList;}
304  void SetQAParticlesList(TList* const qapl) {this->fQAParticlesList = qapl;};
305  TList* GetQAParticlesList() const {return this->fQAParticlesList;}
306 
307  // 7.) Common event cuts:
312  void SetNumberOfTracks(Int_t minnoft, Int_t maxnoft)
313  {
314  fCutOnNumberOfTracks = kTRUE;
315  this->fMinNumberOfTracks = minnoft;
316  this->fMaxNumberOfTracks = maxnoft;
317  };
318  void SetNumberOfGlobalTracks(Int_t minnofgt, Int_t maxnofgt)
319  {
321  this->fMinNumberOfGlobalTracks = minnofgt;
322  this->fMaxNumberOfGlobalTracks = maxnofgt;
323  };
324  void SetNumberOfV0s(Int_t minnofV0s, Int_t maxnofV0s)
325  {
326  fCutOnNumberOfV0s = kTRUE;
327  this->fMinNumberOfV0s = minnofV0s;
328  this->fMaxNumberOfV0s = maxnofV0s;
329  };
330  void SetNumberOfCascades(Int_t minnofc, Int_t maxnofc)
331  {
332  fCutOnNumberOfCascades = kTRUE;
333  this->fMinNumberOfCascades = minnofc;
334  this->fMaxNumberOfCascades = maxnofc;
335  };
336  void SetVertexX(Float_t minvX, Float_t maxvX)
337  {
338  fCutOnVertexX = kTRUE;
339  this->fMinVertexX = minvX;
340  this->fMaxVertexX = maxvX;
341  };
342  void SetVertexY(Float_t minvY, Float_t maxvY)
343  {
344  fCutOnVertexY = kTRUE;
345  this->fMinVertexY = minvY;
346  this->fMaxVertexY = maxvY;
347  };
348  void SetVertexZ(Float_t minvZ, Float_t maxvZ)
349  {
350  fCutOnVertexZ = kTRUE;
351  this->fMinVertexZ = minvZ;
352  this->fMaxVertexZ = maxvZ;
353  };
354  void SetNContributors(Int_t minNc, Int_t maxNc)
355  {
356  fCutOnNContributors = kTRUE;
357  this->fMinNContributors = minNc;
358  this->fMaxNContributors = maxNc;
359  };
360 
361  // 8.) Common global track cuts: // TBI at the moment, they are applied both to 'atracks' and 'gtracks', decouple eventually
363  {
364  fApplyGlobalTrackCuts = kTRUE;
365  this->fPtRange[0] = ptMin;
366  this->fPtRange[1] = ptMax;
367  };
368  void SetEtaRange(Float_t etaMin, Float_t etaMax)
369  {
370  fApplyGlobalTrackCuts = kTRUE;
371  this->fEtaRange[0] = etaMin;
372  this->fEtaRange[1] = etaMax;
373  };
375  {
376  fApplyGlobalTrackCuts = kTRUE;
377  this->fPhiRange[0] = phiMin;
378  this->fPhiRange[1] = phiMax;
379  };
380 
381  // *.) Testing new ways to calculate correlation functions:
384  void SetCorrelationFunctionsTESTFlagsPro(TProfile* const cfTfp) {this->fCorrelationFunctionsTESTFlagsPro = cfTfp;};
386  void SetBoostVelocity(const Double_t vx, const Double_t vy, const Double_t vz)
387  {
388  fBoost = kTRUE;
389  fBoostVelocity = TVector3(vx,vy,vz);
390  }
391 
392  void SetQ2binning(const Int_t nBins, const Double_t min, const Double_t max)
393  {
394  this->fnQ2bins = nBins;
395  this->fnQ2min = min;
396  this->fnQ2max = max;
397  };
398  void SetQ3binning(const Int_t nBins, const Double_t min, const Double_t max)
399  {
400  this->fnQ3bins = nBins;
401  this->fnQ3min = min;
402  this->fnQ3max = max;
403  };
404  void SetQ4binning(const Int_t nBins, const Double_t min, const Double_t max)
405  {
406  this->fnQ4bins = nBins;
407  this->fnQ4min = min;
408  this->fnQ4max = max;
409  };
410  void SetFillCorrelationFunctionsTEST(Int_t const testNO, Bool_t bDoTest) {this->fFillCorrelationFunctionsTEST[testNO] = bDoTest;};
411 
412  // *.) Testing new ways to calculate background:
413  void SetBackgroundTESTList(TList* const bTl) {this->fBackgroundTESTList = bTl;};
415  void SetBackgroundTESTFlagsPro(TProfile* const bTfp) {this->fBackgroundTESTFlagsPro = bTfp;};
416  TProfile* GetBackgroundTESTFlagsPro() const {return this->fBackgroundTESTFlagsPro;};
417  void SetFillBackgroundTEST(Int_t const testNO, Bool_t bDoTest) {this->fFillBackgroundTEST[testNO] = bDoTest;};
418 
419  // *) 'hybrid approach':
420  void SetHybridApproachList(TList* const hal) {this->fHybridApproachList = hal;};
422  void SetHybridApproachFlagsPro(TProfile* const hafp) {this->fHybridApproachFlagsPro = hafp;};
423  TProfile* GetHybridApproachFlagsPro() const {return this->fHybridApproachFlagsPro;};
424  void SetDoHybridApproach(Bool_t bhap) {this->fDoHybridApproach = bhap;};
425 
426  // *) m.p.d.f.'s:
427  void SetMPDFList(TList* const mpdfl) {this->fMPDFList = mpdfl;};
428  TList* GetMPDFList() const {return this->fMPDFList;}
429  void SetMPDFFlagsPro(TProfile* const mpdffp) {this->fMPDFFlagsPro = mpdffp;};
430  TProfile* GetMPDFFlagsPro() const {return this->fMPDFFlagsPro;};
431  void SetDoMPDF(Bool_t bmpdf) {this->fDoMPDF = bmpdf;};
432  void SetCalculateMPDF2p(Bool_t cmpdf2p) {this->fCalculateMPDF2p = cmpdf2p;};
433  Bool_t GetCalculateMPDF2p() const {return this->fCalculateMPDF2p;};
434  void SetCalculateMPDF3p(Bool_t cmpdf3p) {this->fCalculateMPDF3p = cmpdf3p;};
435  Bool_t GetCalculateMPDF3p() const {return this->fCalculateMPDF3p;};
436  void SetProjectMPDF2p(Bool_t pmpdf2p) {this->fProjectMPDF2p = pmpdf2p;};
437  Bool_t GetProjectMPDF2p() const {return this->fProjectMPDF2p;};
438  void SetProjectMPDF3p(Bool_t pmpdf3p) {this->fProjectMPDF3p = pmpdf3p;};
439  Bool_t GetProjectMPDF3p() const {return this->fProjectMPDF3p;};
440  void SetnBinsPxPyPzE2p(Int_t p1xNbins, Int_t p1yNbins, Int_t p1zNbins, Int_t p2xNbins, Int_t p2yNbins, Int_t p2zNbins)
441  {
442  this->fnBinsPxPyPzE2p[0] = p1xNbins;
443  this->fnBinsPxPyPzE2p[1] = p1yNbins;
444  this->fnBinsPxPyPzE2p[2] = p1zNbins;
445  this->fnBinsPxPyPzE2p[3] = p2xNbins;
446  this->fnBinsPxPyPzE2p[4] = p2yNbins;
447  this->fnBinsPxPyPzE2p[5] = p2zNbins;
448  };
449  void SetMinValuesBinsPxPyPzE2p(Float_t p1xmin, Float_t p1ymin, Float_t p1zmin, Float_t p2xmin, Float_t p2ymin, Float_t p2zmin)
450  {
451  this->fmin2p[0] = p1xmin;
452  this->fmin2p[1] = p1ymin;
453  this->fmin2p[2] = p1zmin;
454  this->fmin2p[3] = p2xmin;
455  this->fmin2p[4] = p2ymin;
456  this->fmin2p[5] = p2zmin;
457  };
458  void SetMaxValuesBinsPxPyPzE2p(Float_t p1xmax, Float_t p1ymax, Float_t p1zmax, Float_t p2xmax, Float_t p2ymax, Float_t p2zmax)
459  {
460  this->fmax2p[0] = p1xmax;
461  this->fmax2p[1] = p1ymax;
462  this->fmax2p[2] = p1zmax;
463  this->fmax2p[3] = p2xmax;
464  this->fmax2p[4] = p2ymax;
465  this->fmax2p[5] = p2zmax;
466  };
467  void SetnBinsPxPyPzE1p(Int_t p1xNbins, Int_t p1yNbins, Int_t p1zNbins)
468  {
469  this->fnBinsPxPyPzE1p[0] = p1xNbins;
470  this->fnBinsPxPyPzE1p[1] = p1yNbins;
471  this->fnBinsPxPyPzE1p[2] = p1zNbins;
472  };
473  void SetMinValuesBinsPxPyPzE1p(Float_t p1xmin, Float_t p1ymin, Float_t p1zmin) // applies both for p1 and p2
474  {
475  this->fmin1p[0] = p1xmin;
476  this->fmin1p[1] = p1ymin;
477  this->fmin1p[2] = p1zmin;
478  };
479  void SetMaxValuesBinsPxPyPzE1p(Float_t p1xmax, Float_t p1ymax, Float_t p1zmax) // applies both for p1 and p2
480  {
481  this->fmax1p[0] = p1xmax;
482  this->fmax1p[1] = p1ymax;
483  this->fmax1p[2] = p1zmax;
484  };
485 
486  // *.) Online monitoring:
487  void SetUpdateOutputFile(const Int_t uf, const char *uqof)
488  {
489  // Example usage: taskMPF->SetUpdateOutputFile(44,"AnalysisResults.root");
490  this->fOnlineMonitoring = kTRUE;
491  this->fUpdateOutputFile = kTRUE;
492  this->fUpdateFrequency = uf;
493  this->fUpdateWhichOutputFile = new TString(uqof);
494  };
495  void SetMaxNumberOfEvents(const Int_t mnof, const char *uqof)
496  {
497  // Example usage: taskMPF->SetMaxNumberOfEvents(44,"AnalysisResults.root");
498  this->fOnlineMonitoring = kTRUE;
499  this->fMaxNumberOfEvents = mnof;
500  this->fUpdateWhichOutputFile = new TString(uqof);
501  };
502 
503  // *.) Debugging:
504  void SetWaitForSpecifiedEvent(UInt_t run, UShort_t bunchCross, UInt_t orbit, UInt_t period)
505  {
506  this->fDoSomeDebugging = kTRUE;
507  this->fWaitForSpecifiedEvent = kTRUE;
508  this->fRun = run;
509  this->fBunchCross = bunchCross;
510  this->fOrbit = orbit;
511  this->fPeriod = period;
512  }; // void SetWaitForSpecifiedEvent(UInt_t run, UShort_t bunchCross, UInt_t orbit, UInt_t period)
513 
514  private:
517 
518  TList *fHistList; // base list to hold all output object (a.k.a. grandmother of all lists)
520 
521  AliPIDResponse *fPIDResponse;
522 
523  Int_t fMaxNoGlobalTracksAOD; // maximum # of TExMap *fGlobalTracksAOD objects to be booked. Default is 3, one for default analysis, and two for event mixing
524  TExMap *fGlobalTracksAOD[10];
525  Bool_t fProcessBothKineAndReco; // process both aMC and aAOD, or aMC and aESD, typically to get purities (TBI: add support for ESD)
526  Bool_t fProcessOnlyKine; // process only aMC
527  Bool_t fProcessOnlyReco; // process only aAOD or aESD (i.e. disregard aMC even if available)
528  Bool_t fRejectFakeTracks; // if set to kFALSE, and if fMC is available, get the corresponding MC particle by taking absolute value of label
529  AliMCEvent *fMC; // placeholder for MC info
530 
531  // 1.) Control histograms:
532  TList *fControlHistogramsList; // list to hold all 'control histograms' objects
533  TProfile *fControlHistogramsFlagsPro; // profile to hold all flags for control histograms
534  Bool_t fFillControlHistograms; // not set directly, but instead via: fFillControlHistogramsEvent || fFillControlHistogramsNonIdentifiedParticles || ...
535  // 1a) Event (a.k.a. global event observables):
536  TList *fControlHistogramsEventList; // list to hold all 'control histograms' for events TBI
537  TProfile *fControlHistogramsEventFlagsPro; // profile to hold all flags for control histograms for events TBI
538  Bool_t fFillControlHistogramsEvent; // fill or not control histograms for global event observables
539  TH1I *fGetNumberOfTracksHist; // a{AOD,MC}->GetNumberOfTracks()
541  TH1I *fGetNumberOfV0sHist; // aAOD->GetNumberOfV0s()
542  TH1I *fGetNumberOfCascadesHist; // aAOD->GetNumberOfCascades()
543  TH1D *fGetMagneticFieldHist; // aAOD->GetMagneticField()
544  TH1I *fGetEventTypeHist; // aAOD->GetEventType()
545  TH1D *fGetCentralityHist; // aAOD->GetCentrality()
546  TH1F *fVertexXYZ[3];
547  TH1I *fGetNContributorsHist; // avtx->GetNContributors()
548  TH1F *fGetChi2perNDFHist; // avtx->GetChi2perNDF();
549  TH1I *fGetNDaughtersHist; // avtx->GetNDaughters();
550 
551  // 1b) Non-identified particles (for AOD these are "normal global" tracks, i.e. the ones which satisfy atrack->GetID()>=0 ):
552  TList *fControlHistogramsNonIdentifiedParticlesList; // list to hold all 'control histograms' for non-identified particles
553  TProfile *fControlHistogramsNonIdentifiedParticlesFlagsPro; // profile to hold all flags for control histograms for non-identified particles
554  Bool_t fFillControlHistogramsNonIdentifiedParticles; // fill or not control histograms for non-identified particles
555  TH1I *fChargeHist; // atrack->Charge()
556  TH1I *fGetTPCNclsHist; // atrack->GetTPCNcls()
557  TH1I *fGetTPCsignalNHist; // atrack->GetTPCsignalN()
558  TH1I *fGetITSNclsHist; // atrack->GetITSNcls()
559  TH2F *fdEdxVsPtHist; // atrack->GetTPCmomentum(),atrack->GetTPCsignal()
560  TH1F *fPtHist; // atrack->Pt()
561  TH1F *fEtaHist; // atrack->Eta()
562  TH1F *fPhiHist; // atrack->Phi()
563  TH1F *fMassHist; // atrack->M()
564  TH1I *fGetFilterMap; // atrack->GetFilterMap()
565  TH1I *fGetPdgCode; // atrack->GetPdgCode()
566 
567  // 1c) Non-identified particles for the specified filterbit (f.t.s.f.) (by default TPC-only):
568  TList *fControlHistogramsNonIdentifiedParticlesFTSFList; // list to hold all 'control histograms' for non-identified particles
569  TProfile *fControlHistogramsNonIdentifiedParticlesFTSFFlagsPro; // profile to hold all flags for control histograms for non-identified particles
570  Bool_t fFillControlHistogramsNonIdentifiedParticlesFTSF; // fill or not control histograms for non-identified particles
571  Int_t fFilterBitFTSF; // filter bit, relevant only for these group of control histos. For the particle selection, there is another flag
572  TH1I *fChargeFTSFHist; // atrack->Charge()
573  TH1I *fGetTPCNclsFTSFHist; // atrack->GetTPCNcls()
574  TH1I *fGetTPCsignalNFTSFHist; // atrack->GetTPCsignalN()
575  TH1I *fGetITSNclsFTSFHist; // atrack->GetITSNcls()
576  TH2F *fdEdxVsPtFTSFHist; // atrack->GetTPCmomentum(),atrack->GetTPCsignal()
577  TH1F *fPtFTSFHist; // atrack->Pt()
578  TH1F *fEtaFTSFHist; // atrack->Eta()
579  TH1F *fPhiFTSFHist; // atrack->Phi()
580  TH1F *fMassFTSFHist; // atrack->M()
581  TH1I *fGetFilterMapFTSF; // atrack->GetFilterMap()
582  TH1I *fGetPdgCodeFTSF; // atrack->GetPdgCode()
583 
584  // 1d) Identified particles:
585  TList *fControlHistogramsIdentifiedParticlesList; // list to hold all 'control histograms' for identified particles
586  TProfile *fControlHistogramsIdentifiedParticlesFlagsPro; // profile to hold all flags for control histograms for identified particles
587  Bool_t fFillControlHistogramsIdentifiedParticles; // fill or not control histograms for identified particles (by default they are not filled)
588  Bool_t fFillControlHistogramsWithGlobalTrackInfo; // by default, control histograms are filled with info from 'atrack'. If this flag is TRUE, then instead info from 'gtrack' is used. This then also applies to info used to get correlation functions and background as well
591  TH1F *fMassPIDHist[5][2][2];
592  TH1F *fPtPIDHist[5][2][2];
593  TH1F *fPPIDHist[5][2][2][3];
594  TH1F *fEtaPIDHist[5][2][2];
595  TH1F *fPhiPIDHist[5][2][2];
596  Bool_t fUseDefaultInclusiveSigmaCuts; // if the setter SetInclusiveSigmaCuts(...) (see above) is not called explicitly, the default hardwired values will be used
597  Bool_t fUseDefaultExclusiveSigmaCuts; // if the setter SetExclusiveSigmaCuts(...) (see above) is not called explicitly, the default hardwired values will be used
598  Double_t fInclusiveSigmaCuts[5]; // [PID function] see .cxx for detailed documentation
599  Double_t fExclusiveSigmaCuts[5][5]; // [PID function][PID exclusive] see .cxx for detailed documentation
600 
601  // ...
602  // 1e) V0s:
603  TList *fControlHistogramsV0sList; // list to hold all 'control histograms' for V0s
604  TProfile *fControlHistogramsV0sFlagsPro; // profile to hold all flags for control histograms for V0s
605  Bool_t fFillControlHistogramsV0s; // fill or not control histograms for V0s (by default they are not filled)
606  TH1I *fGetNProngsHist; // aAODv0->GetNProngs()
607  TH1F *fMassK0ShortHist; // aAODv0->MassK0Short()
608  TH1F *fMassLambdaHist; // aAODv0->MassLambda()
609  TH1F *fMassAntiLambdaHist; // aAODv0->MassAntiLambda()
610  TH1F *fOpenAngleV0Hist; // aAODv0->OpenAngleV0() // same as aAODv0->ProngsRelAngle()
611  TH1F *fRadiusV0Hist; // aAODv0->RadiusV0()
612  TH1F *fDcaV0ToPrimVertexHist; // aAODv0->DcaV0ToPrimVertex()
613  TH1F *fMomV0XHist; // aAODv0->MomV0X()
614  TH1F *fMomV0YHist; // aAODv0->MomV0Y()
615  TH1F *fMomV0ZHist; // aAODv0->MomV0Z()
616  TH1F *fPtV0Hist; // pow(aAODv0->Pt2V0(),0.5)
617  TH1F *fPseudoRapV0Hist; // aAODv0->PseudoRapV0()
618  TH2F *fPAHist; // Pod.-Arm.
619 
620  // ...
621  // 1d) Cascades:
622  // ...
623 
624  // 2.) Event-by-event objects:
625  TList *fEBEHistogramsList; // list to hold all stuff from e-b-e histograms
626  TProfile *fEBEObjectsFlagsPro; // profile to hold all flags for e-b-e histograms for V0s
627  //Bool_t fFillEBEHistograms; // fill or not e-b-e histograms TBI do I really need this?
628  TH1I *fUniqueIDHistEBE; // filled with aAODv0->GetPosID() and aAODv0->GetNegID(). If the bin corresponding to that ID is already filled, two V0s share the same daughter
629  TClonesArray *fPIDCA[5][2][2];
630  TClonesArray *fPIDV0sCA[1];
631 
632  // 3.) Correlation functions:
633  TList *fCorrelationFunctionsList; // list to hold all correlation functions for primary particle
634  TProfile *fCorrelationFunctionsFlagsPro; // profile to hold all flags for correlation functions
639  Bool_t fFillCorrelationFunctions; // fill or not correlation functions (by default they are not filled)
640  Bool_t fNormalizeCorrelationFunctions; // normalize correlation functions with the background
642  TH1F *fCorrelationFunctions[10][10];
643  Bool_t fFill3pCorrelationFunctions; // fill 3-p correlation functions
644  TH1F *f3pCorrelationFunctions[10][10][10];
645  Bool_t fFill4pCorrelationFunctions; // fill 4-p correlation functions
646  TH1F *f4pCorrelationFunctions[10][10][10][10];
647  Int_t fNormalizationOption; // set here how to normalize the correlation function: 0 = "just scale", 1 = "use concrete interval", 2 = ...
648  Float_t fNormalizationInterval[2]; // concrete example: 0.15 < q < 0.175 GeV/c. Then, fNormalizationInterval[0] is the low edge, etc. See the relevant setter SetNormalizationInterval
649  Int_t fnMergedBins; // before normalization, both signal and background will be rebinned with this value
650 
651  // 4.) Background:
652  TList *fBackgroundList; // list to hold all background objects primary particle
653  TProfile *fBackgroundFlagsPro; // profile to hold all flags for background
658  Int_t fBackgroundOption; // set how to estimate background: 0 = "shifting", 1 = "permutations", etc. (see .cxx for further explanation). By default, it is "shifting"
659  Bool_t fEstimate2pBackground; // enable or not 2p background estimation
660  Bool_t fEstimate3pBackground; // enable or not 3p background estimation
661  Bool_t fEstimate4pBackground; // enable or not 4p background estimation
662  TH1F *f2pBackground[10][10];
663  TH1F *f3pBackground[10][10][10];
664  TH1F *f4pBackground[10][10][10][10];
665  TClonesArray *fMixedEvents0[3];
666  Int_t fMaxBufferSize1; // the second index in fMixedEvents1[10][50]; and fGlobalTracksAOD1[10][50]; is booked only up to this number. When this number is reached, calculation is done, and buffer is cleaned. max = 50. defaulted to 10
667  TClonesArray *fMixedEvents1[10][50];
668  TExMap *fGlobalTracksAOD1[10][50];
669 
670  // 5.) Buffers:
671  TList *fBuffersList; // list to hold all objects for buffers
672  TProfile *fBuffersFlagsPro; // profile to hold all flags for buffers
673  Bool_t fFillBuffers; // hold some thingies for bunch of events in memories
674  Int_t fMaxBuffer; // max buffer size (e.g. for 3-p correlations it is 3, etc.) TBI there is a problem apparently, re-think
675  TClonesArray *fChargedParticlesCA[2][10][10000];
676  TExMap *fChargedParticlesEM[10];
677 
678  // 6.) QA:
679  TList *fQAList; // list to holds all QA objects. It is nested in: a) "QA events"; b) "QA particles"; c) ...
680  TProfile *fQAFlagsPro; // list to holds all flags for QA objects
681  Bool_t fFillQA; // fill QA objects. Not set directly, but instead via: fFillQA = fFillQAEvents || fFillQAParticles || ...
682  Bool_t fBailOutAfterQA; // fill QA objects and bail out, i.e. do not do the actual analysis
683  Bool_t fFillQAEvents; // fill two sets of histograms, before and after event cuts
684  Bool_t fFillQAParticles; // fill two sets of histograms, before and after particle cuts
685  TList *fQAEventsList; // list to holds all objects for "QA events"
686  TList *fQAParticlesList; // list to holds all objects for "QA particles"
687  TH1I *fQAFilterBitScan; // for each track in AOD, dump it's filterbits
688  TH2I *fQAIDvsFilterBit; // atrack->ID() vs. filterbit
689  TH1F *fQAParticleHist[2][10][10];
690 
691  // 7.) Common event cuts (TBI validated only for AOD analysis, for the time being...):
692  // a) Cuts on AliAODEvent:
693  Bool_t fRejectEventsWithoutPrimaryVertex; // as the name says it, by default set to kTRUE. has a setter
694  Float_t fMinMagneticField; // defaulted to 0.001, compared to aAOD->GetMagneticField()
695  Bool_t fCutOnNumberOfTracks; // cut on the total number of tracks in AOD, i.e. on aAOD->GetNumberOfTracks(). This is NOT multiplicity, since some tracks are stored multiple times in AOD
696  Int_t fMinNumberOfTracks; // default values never in effect; if aAOD->GetNumberOfTracks() < fMinNumberOfTracks, event is rejected
697  Int_t fMaxNumberOfTracks; // default values never in effect; if aAOD->GetNumberOfTracks() > fMaxNumberOfTracks, event is rejected
698  Bool_t fCutOnNumberOfGlobalTracks; // cut on the total number of 'normal' global tracks in AOD, i.e. on fGlobalTracksAOD[0]->GetSize()
699  Int_t fMinNumberOfGlobalTracks; // default values never in effect; if fGlobalTracksAOD[0]->GetSize() < fMinNumberOfGlobalTracks, event is rejected
700  Int_t fMaxNumberOfGlobalTracks; // default values never in effect; if fGlobalTracksAOD[0]->GetSize() > fMaxNumberOfGlobalTracks, event is rejected
701  Bool_t fCutOnNumberOfV0s; // cut on the total number of V0s in AOD, i.e. on aAOD->GetNumberOfV0s()
702  Int_t fMinNumberOfV0s; // default values never in effect; if aAOD->GetNumberOfV0s() < fMinNumberOfV0s, event is rejected
703  Int_t fMaxNumberOfV0s; // default values never in effect; if aAOD->GetNumberOfV0s() > fMaxNumberOfV0s, event is rejected
704  Bool_t fCutOnNumberOfCascades; // cut on the total number of cascades in AOD, i.e. on aAOD->GetNumberOfCascades()
705  Int_t fMinNumberOfCascades; // default values never in effect; if aAOD->GetNumberOfCascades() < fMinNumberOfCascades, event is rejected
706  Int_t fMaxNumberOfCascades; // default values never in effect; if aAOD->GetNumberOfCascades() > fMaxNumberOfCascades, event is rejected
707 
708  // b) Cuts on AliAODVertex:
709  Bool_t fCutOnVertexX; // cut on the x position of vertex, i.e. on avtx->GetX()
710  Float_t fMinVertexX; // default values never in effect; if avtx->GetX() < fMinVertexX, event is rejected
711  Float_t fMaxVertexX; // default values never in effect; if avtx->GetX() > fMaxVertexX, event is rejected
712  Bool_t fCutOnVertexY; // cut on the y position of vertex, i.e. on avtx->GetY()
713  Float_t fMinVertexY; // default values never in effect; if avtx->GetY() < fMinVertexY, event is rejected
714  Float_t fMaxVertexY; // default values never in effect; if avtx->GetY() > fMaxVertexY, event is rejected
715  Bool_t fCutOnVertexZ; // cut on the z position of vertex, i.e. on avtx->GetZ()
716  Float_t fMinVertexZ; // default values never in effect; if avtx->GetZ() < fMinVertexZ, event is rejected
717  Float_t fMaxVertexZ; // default values never in effect; if avtx->GetZ() > fMaxVertexZ, event is rejected
718  Bool_t fCutOnNContributors; // cut on avtx->GetNContributors()
719  Int_t fMinNContributors; // default values never in effect; if avtx->GetNContributors() < fMinNContributors, event is rejected
720  Int_t fMaxNContributors; // default values never in effect; if avtx->GetNContributors() > fMaxNContributors, event is rejected
721 
722  // 8.) Common global track cuts (applied only on "normal" global tracks in AOD):
723  TList *fGlobalTrackCutsList; // list to hold all objects for common global track cuts
724  TProfile *fGlobalTrackCutsFlagsPro; // profile to hold all flags
725  Bool_t fApplyGlobalTrackCuts; // if set to kFALSE, the default hardwired cuts will be used. TBI doesn't do anything at the moment in .cxx
726  Float_t fPtRange[2]; // ptMin = fPtRange[0], ptMax = fPtRange[1]
727  Float_t fEtaRange[2]; // etaMin = etaRange[0], etaMax = etaRange[1]
728  Float_t fPhiRange[2]; // phiMin = phiRange[0], phiMax = phiRange[1]
729 
730  // *.) Testing new ways to calculate correlation functions and cumulants:
731  TList *fCorrelationFunctionsTESTList; // list to hold all TEST correlation functions for primary particle
732  TProfile *fCorrelationFunctionsTESTFlagsPro; // profile to hold all flags for TEST correlation functions
733  Bool_t fBoost; // boost or not
734  TVector3 fBoostVelocity; // boost everything in the system mocing with relative velocity fBoostVelocity
735  Int_t fnQ2bins; // number of bins for all histos and profiles vs. Q2 (both for signal and background)
736  Double_t fnQ2min; // min bin for all histos and profiles vs. Q2 (both for signal and background)
737  Double_t fnQ2max; // max bin for all histos and profiles vs. Q2 (both for signal and background)
738  Int_t fnQ3bins; // number of bins for all histos and profiles vs. Q3 (both for signal and background)
739  Double_t fnQ3min; // min bin for all histos and profiles vs. Q3 (both for signal and background)
740  Double_t fnQ3max; // max bin for all histos and profiles vs. Q3 (both for signal and background)
741  Int_t fnQ4bins; // number of bins for all histos and profiles vs. Q4 (both for signal and background)
742  Double_t fnQ4min; // min bin for all histos and profiles vs. Q4 (both for signal and background)
743  Double_t fnQ4max; // max bin for all histos and profiles vs. Q4 (both for signal and background)
745  Bool_t fFillCorrelationFunctionsTEST[10]; // fill or not particular TEST correlation functions, they are enumerated in .cxx file (by default all are set to FALSE)
746  TProfile *fCorrelationFunctionsTEST[10][2][7][10];
747  TProfile *fSignalCumulantsTEST[10][2][4][10];
748  TH1F *fSignalYieldTEST[2];
749  TH1F *fEab_TEST6[2];
750 
751  // *.) Testing new ways to calculate background functions:
752  TList *fBackgroundTESTList; // list to hold all TEST background for primary particle
753  TProfile *fBackgroundTESTFlagsPro; // profile to hold all flags for TEST background
755  Bool_t fFillBackgroundTEST[10]; // fill or not particular TEST background, they are enumerated in .cxx file (by default all are set to FALSE)
756  TProfile *fBackgroundTEST[10][2][7][10];
757  TProfile *fBackgroundCumulantsTEST[10][2][4][10];
758  TClonesArray *fMixedEventsTEST[3];
759  TExMap *fGlobalTracksAODTEST[3];
761 
762  // *.) 'hybrid approach':
763  TList *fHybridApproachList; // list to hold all histos for 'hybrid approach' a la UH
764  TProfile *fHybridApproachFlagsPro; // profile to hold all flags for 'hybrid approach' a la UH
765  Bool_t fDoHybridApproach; // do or not the correlations via the 'hybrid approach' a la UH
767  TClonesArray *fMixedEventsHA[3];
768  TExMap *fGlobalTracksAODHA[3];
769 
770  // *.) m.p.d.f.'s:
771  TList *fMPDFList; // list to hold all histos for approach with m.p.d.f.'s
772  TProfile *fMPDFFlagsPro; // profile to hold all flags for approach with m.p.d.f.'s
773  Bool_t fDoMPDF; // do or not the correlations via the m.p.d.f.'s
774  Bool_t fCalculateMPDF2p; // calculate 2p correlations via m.p.d.f.'s
775  Bool_t fCalculateMPDF3p; // calculate 3p correlations via m.p.d.f.'s
776  Bool_t fProjectMPDF2p; // project 2p correlations at the end of the day
777  Bool_t fProjectMPDF3p; // project 3p correlations at the end of the day
778  THnSparse *fhs2p[3];
781  Int_t fnBinsPxPyPzE2p[6]; // TBI add a comment
782  Double_t fmin2p[6]; // TBI add a comment
783  Double_t fmax2p[6]; // TBI add a comment
784  Int_t fnBinsPxPyPzE1p[3]; // TBI add a comment
785  Double_t fmin1p[3]; // TBI add a comment
786  Double_t fmax1p[3]; // TBI add a comment
787 
788  // *.) Online monitoring:
789  Bool_t fOnlineMonitoring; // enable online monitoring (not set excplicitly!), the flags below just refine it
790  Bool_t fUpdateOutputFile; // update the output file after certain number of analysed events
791  Int_t fUpdateFrequency; // after how many events the output file will be updated
792  TString *fUpdateWhichOutputFile; // which file will be regularly updated
793  Int_t fMaxNumberOfEvents; // if this number of events is reached, write to external file and bail out
794 
795  // *.) Debugging:
796  Bool_t fDoSomeDebugging; // enable call to function within which debugging is done. Set indirectly.
797  Bool_t fWaitForSpecifiedEvent; // do something only for the specified event
798  UInt_t fRun; // do something only for the specified event
799  UShort_t fBunchCross; // do something only for the specified event
800  UInt_t fOrbit; // do something only for the specified event
801  UInt_t fPeriod; // do something only for the specified event
802 
804 
805 };
806 
807 //================================================================================================================
808 
809 #endif
810 
811 
812 
813 
814 
815 
816 
817 
818 
819 
820 
Int_t charge
Bool_t fUseDefaultInclusiveSigmaCuts
[0=e,1=mu,2=pi,3=K,4=p][particle(+q)/antiparticle(-q)][kPrimary/kFromDecayVtx]
virtual void GlobalTracksAODHA(AliAODEvent *aAOD, Int_t index)
TList * fHybridApproachList
[0=for <X1X2> and Q2, 1=for <X1X2X3> and Q3]
double Double_t
Definition: External.C:58
virtual void Calculate2pBackground(TClonesArray *ca1, TClonesArray *ca2)
Definition: External.C:236
Bool_t fFillCorrelationFunctions
lists to hold all correlation functions, for 2p [0], 3p [1], 4p [2], etc., separately ...
TList * fCorrelationFunctionsList
holds AliAODv0 candidates for each event [0=Lambda,1=...]
TH1F * fPtPIDHist[5][2][2]
[0=e,1=mu,2=pi,3=K,4=p][particle(+q)/antiparticle(-q)][kPrimary/kFromDecayVtx]
TH1F * fPhiPIDHist[5][2][2]
[0=e,1=mu,2=pi,3=K,4=p][particle(+q)/antiparticle(-q)][kPrimary/kFromDecayVtx]
virtual void HybridApproach5thTerm(TClonesArray *ca1, TClonesArray *ca2, TClonesArray *ca3, TExMap *em1, TExMap *em2, TExMap *em3)
AliAnalysisTaskMultiparticleFemtoscopy & operator=(const AliAnalysisTaskMultiparticleFemtoscopy &aatmpf)
TH1F * fEtaPIDHist[5][2][2]
[0=e,1=mu,2=pi,3=K,4=p][particle(+q)/antiparticle(-q)][kPrimary/kFromDecayVtx][xyz] ...
Int_t fnBinsPxPyPzE2p[6]
various distributions relevant for m.p.d.f.&#39;s (see .cxx file for a detailed expl.) ...
void SetNumberOfGlobalTracks(Int_t minnofgt, Int_t maxnofgt)
Double_t BinCenterSparse(THnSparse *hs, Int_t dim, Int_t binNo)
void SetQ3binning(const Int_t nBins, const Double_t min, const Double_t max)
Double_t phiMin
TH1F * fPPIDHist[5][2][2][3]
[0=e,1=mu,2=pi,3=K,4=p][particle(+q)/antiparticle(-q)][kPrimary/kFromDecayVtx]
virtual void HybridApproach2ndTerm(AliAODEvent *aAOD, TClonesArray *ca3, TExMap *em3)
void SetFillBackgroundTEST(Int_t const testNO, Bool_t bDoTest)
Bool_t SpecifiedEvent(UInt_t run, UShort_t bunchCross, UInt_t orbit, UInt_t period)
Double_t ptMin
Double_t Q2(AliAODTrack *agtrack1, AliAODTrack *agtrack2)
TH1I * fGetNumberOfV0sHist
fGlobalTracksAOD[0]->GetSize() this is then my multiplicity...
Bool_t fFillCorrelationFunctionsTEST[10]
lists to hold all TEST correlation functions, they are enumerated in .cxx file
void SetWaitForSpecifiedEvent(UInt_t run, UShort_t bunchCross, UInt_t orbit, UInt_t period)
Bool_t fFillBackgroundTEST[10]
lists to hold all TEST background, they are enumerated in .cxx file
Bool_t Proton(AliAODTrack *atrack, Int_t charge=1, Bool_t bPrimary=kTRUE)
void SetMaxValuesBinsPxPyPzE1p(Float_t p1xmax, Float_t p1ymax, Float_t p1zmax)
TExMap * fGlobalTracksAODTEST[3]
tracks for mixed events, using just &#39;shifting&#39; for simplicity TBI make it it more sophisticated later...
TH1F * fEab_TEST6[2]
[0=for <X1X2> and Q2, 1=for <X1X2X3> and Q3]
TProfile * f4pBackgroundFlagsPro
profile to hold all flags for 3p background (placed in fBackgroundSublist[1])
Double_t RelativeMomentaComponent(AliAODTrack *agtrack1, AliAODTrack *agtrack2, const char *component)
TList * fCorrelationFunctionsSublist[3]
profile to hold all flags for 4p correlation functions (placed in fCorrelationFunctionsSublist[2]) ...
void SetMaxNumberOfEvents(const Int_t mnof, const char *uqof)
TProfile * f3pCorrelationFunctionsFlagsPro
profile to hold all flags for 2p correlation functions (placed in fCorrelationFunctionsSublist[0]) ...
virtual void Calculate3pBackgroundTEST(TClonesArray *ca1, TClonesArray *ca2, TClonesArray *ca3, TExMap *em1, TExMap *em2, TExMap *em3)
TList * fBuffersList
global tracks in AOD. Used only for fBackgroundOption = 1. Indices must be the same as in TClonesArra...
void SetUpdateOutputFile(const Int_t uf, const char *uqof)
int Int_t
Definition: External.C:63
void SetnBinsPxPyPzE2p(Int_t p1xNbins, Int_t p1yNbins, Int_t p1zNbins, Int_t p2xNbins, Int_t p2yNbins, Int_t p2zNbins)
void SetExclusiveSigmaCuts(Int_t pidFunction, Int_t pidExclusive, Double_t sigmaValue)
void SetnBinsPxPyPzE1p(Int_t p1xNbins, Int_t p1yNbins, Int_t p1zNbins)
Definition: External.C:204
unsigned int UInt_t
Definition: External.C:33
TExMap * fChargedParticlesEM[10]
[0=AOD||ESD,1=MC][#events,max=10][particles]
float Float_t
Definition: External.C:68
TList * fQAList
[#events,max=10,has to correspond to 2nd entry above] this is standard mapping, nothing more nor less...
TClonesArray * fPIDV0sCA[1]
holds AliAODTrack candidates for each event [0=e,1=mu,2=pi,3=K,4=p][particle(+q)/antiparticle(-q)][kP...
Double_t RelativeMomenta(AliAODTrack *agtrack1, AliAODTrack *agtrack2)
Double_t phiMax
Definition: External.C:212
TClonesArray * fMixedEventsHA[3]
five distinct distributions in the numerator of Eq. (18)
Bool_t Pion(AliAODTrack *atrack, Int_t charge=1, Bool_t bPrimary=kTRUE)
Double_t Q4(AliAODTrack *agtrack1, AliAODTrack *agtrack2, AliAODTrack *agtrack3, AliAODTrack *agtrack4)
void SetMaxValuesBinsPxPyPzE2p(Float_t p1xmax, Float_t p1ymax, Float_t p1zmax, Float_t p2xmax, Float_t p2ymax, Float_t p2zmax)
Int_t fBackgroundOption
lists to hold all background correlations, for 2p [0], 3p [1], 4p [2], etc., separately ...
TProfile * fBackgroundCumulantsTEST[10][2][4][10]
[testNo][0=vs Q2, 1=vs Q3][correlation][differential index, e.g. for test 0 [0=Cx][1=Cy][2=Cz]] ...
void SetQ4binning(const Int_t nBins, const Double_t min, const Double_t max)
virtual void Calculate2pBackgroundTEST(TClonesArray *ca1, TClonesArray *ca2, TExMap *em1, TExMap *em2)
TH1F * fSignalYieldTEST[2]
[testNo][0=vs Q2, 1=vs Q3][[0=<x1x2>_c][1=<x1x3>_c][2=<x2x3>_c][3=<x1x2x3>_c]][differential index...
Bool_t fRejectEventsWithoutPrimaryVertex
[0="before rain",1="after rain"][distribution_index][cut_index]
virtual void GlobalTracksAODTEST(AliAODEvent *aAOD, Int_t index)
Bool_t Kaon(AliAODTrack *atrack, Int_t charge=1, Bool_t bPrimary=kTRUE)
Bool_t fFill4pCorrelationFunctions
[particle(+q): 0=e,1=mu,2=pi,3=K,4=p, anti-particle(-q): 5=e,6=mu,7=pi,8=K,9=p] x [same] x [same]...
void SetMinValuesBinsPxPyPzE1p(Float_t p1xmin, Float_t p1ymin, Float_t p1zmin)
virtual void GlobalTracksAOD(AliAODEvent *aAOD, Int_t index)
AliPIDResponse * fPIDResponse
MC, AOD, ESD, MC_AOD or MC_ESD.
TH1F * f4pBackground[10][10][10][10]
[particle(+q): 0=e,1=mu,2=pi,3=K,4=p, anti-particle(-q): 0=e,1=mu,2=pi,3=K,4=p] x [same] x [same] ...
virtual void Calculate4pBackground(TClonesArray *ca1, TClonesArray *ca2, TClonesArray *ca3, TClonesArray *ca4)
TH1F * fMassPIDHist[5][2][2]
holds the values of fExclusiveSigmaCuts[5][5];
virtual void Calculate3pBackground(TClonesArray *ca1, TClonesArray *ca2, TClonesArray *ca3)
Double_t PairVectorComponent(AliAODTrack *agtrack1, AliAODTrack *agtrack2, const char *component)
virtual void FillControlHistogramsNonIdentifiedParticles(AliAODTrack *atrack)
TList * fBackgroundSublist[3]
profile to hold all flags for 4p background (placed in fBackgroundSublist[2])
void SetQ2binning(const Int_t nBins, const Double_t min, const Double_t max)
TList * fBackgroundTESTList
[0=for signal "Test 6", 1=for background "Test 6"]
TProfile * f3pBackgroundFlagsPro
profile to hold all flags for 2p background (placed in fBackgroundSublist[0])
Double_t Q3(AliAODTrack *agtrack1, AliAODTrack *agtrack2, AliAODTrack *agtrack3)
TProfile * fSignalCumulantsTEST[10][2][4][10]
[testNo][0=vs Q2, 1=vs Q3][example [0=<x1>][1=<x2>], ...,[6=<x1x2x3>]][differential index...
TExMap * fGlobalTracksAODHA[3]
tracks for mixed events, using just &#39;shifting&#39; for simplicity TBI make it it more sophisticated later...
Bool_t fProcessBothKineAndReco
global tracks in AOD. [0] is used in the default analysis, [1] and [2] for event mixing, etc.
TExMap * fGlobalTracksAOD1[10][50]
tracks for mixed events. 10 vertex z-ranges. Keep at maximum 5 events in the buffer. Used only for fBackgroundOption = 1
TClonesArray * fMixedEvents0[3]
[particle(+q): 0=e,1=mu,2=pi,3=K,4=p, anti-particle(-q): 0=e,1=mu,2=pi,3=K,4=p] x [same] x [same] ...
void SetBoostVelocity(const Double_t vx, const Double_t vy, const Double_t vz)
TProfile * f4pCorrelationFunctionsFlagsPro
profile to hold all flags for 3p correlation functions (placed in fCorrelationFunctionsSublist[1]) ...
Int_t fMaxBufferSize1
tracks for mixed events (supporting up to 3-mixed events at the moment). Used only for fBackgroundOpt...
virtual void FillControlHistogramsIdentifiedParticles(AliAODTrack *atrack, AliAODTrack *gtrack)
Bool_t fFill3pCorrelationFunctions
[particle(+q): 0=e,1=mu,2=pi,3=K,4=p, anti-particle(-q): 5=e,6=mu,7=pi,8=K,9=p] x [same]...
unsigned short UShort_t
Definition: External.C:28
TH1D * fDistMPDF[9]
[0] = projection on Q2 from p.d.f. for both particles; [1] = projection on Q2 from the product of m...
const char Option_t
Definition: External.C:48
void SetMinValuesBinsPxPyPzE2p(Float_t p1xmin, Float_t p1ymin, Float_t p1zmin, Float_t p2xmin, Float_t p2ymin, Float_t p2zmin)
bool Bool_t
Definition: External.C:53
void SetInclusiveSigmaCuts(Int_t pidFunction, Double_t sigmaValue)
TClonesArray * fMixedEventsTEST[3]
[testNo][0=vs Q2, 1=vs Q3][[0=<x1x2>_c][1=<x1x3>_c][2=<x2x3>_c][3=<x1x2x3>_c]][differential index...
Double_t ptMax
Int_t fNormalizationOption
[particle(+q): 0=e,1=mu,2=pi,3=K,4=p, anti-particle(-q): 5=e,6=mu,7=pi,8=K,9=p] x [same] x [same] x [...
TH1F * f3pBackground[10][10][10]
[particle(+q): 0=e,1=mu,2=pi,3=K,4=p, anti-particle(-q): 0=e,1=mu,2=pi,3=K,4=p] x [same]...
void SetFillCorrelationFunctionsTEST(Int_t const testNO, Bool_t bDoTest)
TProfile2D * fExclusiveSigmaCutsPro
holds the values of fInclusiveSigmaCuts[5];
TH1I * fGetNContributorsHist
[avtx->GetX(),avtx->GetY(),avtx->GetZ()]
TH1F * fCorrelationFunctions[10][10]
associates pdg code to index of correlation function
TH1D * fProjectionQ2[3]
[0] = p.d.f. for both particles; [1] = m.p.d.f. for 1st particle; [2] = m.p.d.f. for 2nd particle ...
virtual void FillControlHistogramsNonIdentifiedParticlesFTSF(AliAODTrack *atrack)