AliPhysics  b095172 (b095172)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliFlowEventSimple.cxx
Go to the documentation of this file.
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  AliFlowEventSimple: A simple event
18  for flow analysis
19 
20  origin: Naomi van der Kolk (kolk@nikhef.nl)
21  Ante Bilandzic (anteb@nikhef.nl)
22  Raimond Snellings (Raimond.Snellings@nikhef.nl)
23  mods: Mikolaj Krzewicki (mikolaj.krzewicki@cern.ch)
24  Redmer A. Bertens (rbertens@cern.ch)
25 *****************************************************************/
26 
27 #include "Riostream.h"
28 #include "TObjArray.h"
29 #include "TFile.h"
30 #include "TList.h"
31 #include "TTree.h"
32 #include "TParticle.h"
33 #include "TMath.h"
34 #include "TH1F.h"
35 #include "TH1D.h"
36 #include "TF1.h"
37 #include "TF2.h"
38 #include "TProfile.h"
39 #include "TParameter.h"
40 #include "TBrowser.h"
41 #include "AliFlowVector.h"
42 #include "AliFlowTrackSimple.h"
43 #include "AliFlowTrackSimpleCuts.h"
44 #include "AliFlowEventSimple.h"
45 #include "TRandom.h"
46 
47 using std::cout;
48 using std::endl;
49 using std::cerr;
51 
52 //-----------------------------------------------------------------------
54  fTrackCollection(NULL),
55  fReferenceMultiplicity(0),
56  fNumberOfTracks(0),
57  fUseGlauberMCSymmetryPlanes(kFALSE),
58  fUseExternalSymmetryPlanes(kFALSE),
59  fPsi1(0.),
60  fPsi2(0.),
61  fPsi3(0.),
62  fPsi4(0.),
63  fPsi5(0.),
64  fPsi1Psi3(0x0),
65  fPsi2Psi4(0x0),
66  fPsi3Psi5(0x0),
67  fMCReactionPlaneAngle(0.),
68  fMCReactionPlaneAngleIsSet(kFALSE),
69  fAfterBurnerPrecision(0.001),
70  fUserModified(kFALSE),
71  fNumberOfTracksWrap(NULL),
72  fNumberOfRPsWrap(NULL),
73  fNumberOfPOIsWrap(NULL),
74  fMCReactionPlaneAngleWrap(NULL),
75  fShuffledIndexes(NULL),
76  fShuffleTracks(kFALSE),
77  fMothersCollection(NULL),
78  fCentrality(-1.),
79  fCentralityCL1(-1.),
80  fNITSCL1(-1.),
81  fCentralityTRK(-1.),
82  fRun(-1),
83  fZNCM(0.),
84  fZNAM(0.),
85  fNumberOfPOItypes(2),
86  fNumberOfPOIs(NULL)
87 {
88  fZNCQ = AliFlowVector();
89  fZNAQ = AliFlowVector();
90  for(Int_t i(0); i < 3; i++) {
91  fVtxPos[i] = 0.;
92  }
93  cout << "AliFlowEventSimple: Default constructor to be used only by root for io" << endl;
94 }
95 
96 //-----------------------------------------------------------------------
98  ConstructionMethod method,
99  TF1* ptDist,
100  Double_t phiMin,
101  Double_t phiMax,
102  Double_t etaMin,
103  Double_t etaMax):
104  fTrackCollection(new TObjArray(n)),
105  fReferenceMultiplicity(0),
106  fNumberOfTracks(0),
107  fUseGlauberMCSymmetryPlanes(kFALSE),
108  fUseExternalSymmetryPlanes(kFALSE),
109  fPsi1(0.),
110  fPsi2(0.),
111  fPsi3(0.),
112  fPsi4(0.),
113  fPsi5(0.),
114  fPsi1Psi3(0x0),
115  fPsi2Psi4(0x0),
116  fPsi3Psi5(0x0),
117  fMCReactionPlaneAngle(0.),
118  fMCReactionPlaneAngleIsSet(kFALSE),
119  fAfterBurnerPrecision(0.001),
120  fUserModified(kFALSE),
121  fNumberOfTracksWrap(NULL),
122  fNumberOfRPsWrap(NULL),
123  fNumberOfPOIsWrap(NULL),
124  fMCReactionPlaneAngleWrap(NULL),
125  fShuffledIndexes(NULL),
126  fShuffleTracks(kFALSE),
127  fMothersCollection(new TObjArray()),
128  fCentrality(-1.),
129  fCentralityCL1(-1.),
130  fNITSCL1(-1.),
131  fCentralityTRK(-1.),
132  fRun(-1),
133  fZNCM(0.),
134  fZNAM(0.),
135  fNumberOfPOItypes(2),
136  fNumberOfPOIs(new Int_t[fNumberOfPOItypes])
137 {
138  //ctor
139  // if second argument is set to AliFlowEventSimple::kGenerate
140  // it generates n random tracks with given Pt distribution
141  // (a sane default is provided), phi and eta are uniform
142 
143  if (method==kGenerate)
144  Generate(n,ptDist,phiMin,phiMax,etaMin,etaMax);
145 
146  fZNCQ = AliFlowVector();
147  fZNAQ = AliFlowVector();
148  for(Int_t i(0); i < 3; i++) {
149  fVtxPos[i] = 0.;
150  }
151 }
152 
153 //-----------------------------------------------------------------------
155  TObject(anEvent),
156  fTrackCollection((TObjArray*)(anEvent.fTrackCollection)->Clone()),
157  fReferenceMultiplicity(anEvent.fReferenceMultiplicity),
158  fNumberOfTracks(anEvent.fNumberOfTracks),
159  fUseGlauberMCSymmetryPlanes(anEvent.fUseGlauberMCSymmetryPlanes),
160  fUseExternalSymmetryPlanes(anEvent.fUseExternalSymmetryPlanes),
161  fPsi1(anEvent.fPsi1),
162  fPsi2(anEvent.fPsi2),
163  fPsi3(anEvent.fPsi3),
164  fPsi4(anEvent.fPsi4),
165  fPsi5(anEvent.fPsi5),
166  fPsi1Psi3(anEvent.fPsi1Psi3),
167  fPsi2Psi4(anEvent.fPsi2Psi4),
168  fPsi3Psi5(anEvent.fPsi3Psi5),
169  fMCReactionPlaneAngle(anEvent.fMCReactionPlaneAngle),
170  fMCReactionPlaneAngleIsSet(anEvent.fMCReactionPlaneAngleIsSet),
171  fAfterBurnerPrecision(anEvent.fAfterBurnerPrecision),
172  fUserModified(anEvent.fUserModified),
173  fNumberOfTracksWrap(anEvent.fNumberOfTracksWrap),
174  fNumberOfRPsWrap(anEvent.fNumberOfRPsWrap),
175  fNumberOfPOIsWrap(anEvent.fNumberOfPOIsWrap),
176  fMCReactionPlaneAngleWrap(anEvent.fMCReactionPlaneAngleWrap),
177  fShuffledIndexes(NULL),
178  fShuffleTracks(anEvent.fShuffleTracks),
179  fMothersCollection(new TObjArray()),
180  fCentrality(anEvent.fCentrality),
181  fCentralityCL1(anEvent.fCentralityCL1),
182  fNITSCL1(anEvent.fNITSCL1),
183  fCentralityTRK(anEvent.fCentralityTRK),
184  fRun(anEvent.fRun),
185  fZNCQ(anEvent.fZNCQ),
186  fZNAQ(anEvent.fZNAQ),
187  fZNCM(anEvent.fZNCM),
188  fZNAM(anEvent.fZNAM),
189  fNumberOfPOItypes(anEvent.fNumberOfPOItypes),
190  fNumberOfPOIs(new Int_t[fNumberOfPOItypes])
191 {
192  //copy constructor
193  memcpy(fNumberOfPOIs,anEvent.fNumberOfPOIs,fNumberOfPOItypes*sizeof(Int_t));
194  for(Int_t i(0); i < 3; i++) {
195  fVtxPos[i] = anEvent.fVtxPos[i];
196  }
197 }
198 
199 //-----------------------------------------------------------------------
200 void AliFlowEventSimple::SetNumberOfPOIs( Int_t numberOfPOIs, Int_t poiType)
201 {
202  //set the number of poi classes, resize the array if larger is needed
203  //never shrink the array
204  //never decrease the stored number
205  if (poiType>=fNumberOfPOItypes)
206  {
207  Int_t n = poiType+1;
208  Int_t* tmp = new Int_t[n];
209  for (Int_t j=0; j<n; j++) { tmp[j]=0; }
210  memcpy(tmp,fNumberOfPOIs,fNumberOfPOItypes*sizeof(Int_t));
211  delete [] fNumberOfPOIs;
212  fNumberOfPOIs = tmp;
213  fNumberOfPOItypes = n;
214  }
215 
216  fNumberOfPOIs[poiType] = numberOfPOIs;
217 }
218 
219 //-----------------------------------------------------------------------
221 {
222 
223  if (poiType>=fNumberOfPOItypes) SetNumberOfPOIs(0,poiType);
224  fNumberOfPOIs[poiType]++;
225 }
226 
227 //-----------------------------------------------------------------------
229 {
230  //assignment operator
231  if (&anEvent==this) return *this; //check self-assignment
232  if (fTrackCollection) fTrackCollection->Delete();
233  delete fTrackCollection;
234  fTrackCollection = (TObjArray*)(anEvent.fTrackCollection)->Clone(); //deep copy
238  delete [] fNumberOfPOIs;
240  memcpy(fNumberOfPOIs,anEvent.fNumberOfPOIs,fNumberOfPOItypes*sizeof(Int_t));
243  fPsi1 = anEvent.fPsi1;
244  fPsi2 = anEvent.fPsi2;
245  fPsi3 = anEvent.fPsi3;
246  fPsi4 = anEvent.fPsi4;
247  fPsi5 = anEvent.fPsi5;
248  fPsi1Psi3 = anEvent.fPsi1Psi3;
249  fPsi2Psi4 = anEvent.fPsi2Psi4;
250  fPsi3Psi5 = anEvent.fPsi3Psi5;
259  fShuffleTracks = anEvent.fShuffleTracks;
260  fCentrality = anEvent.fCentrality;
261  fCentralityCL1 = anEvent.fCentralityCL1;
262  fNITSCL1 = anEvent.fNITSCL1;
263  fCentralityTRK = anEvent.fCentralityTRK;
264  fRun = anEvent.fRun;
265  fZNCQ = anEvent.fZNCQ;
266  fZNAQ = anEvent.fZNAQ;
267  fZNCM = anEvent.fZNCM;
268  fZNAM = anEvent.fZNAM;
269  for(Int_t i(0); i < 3; i++) {
270  fVtxPos[i] = anEvent.fVtxPos[i];
271  }
272  delete [] fShuffledIndexes;
273  return *this;
274 }
275 
276 //-----------------------------------------------------------------------
278 {
279  //destructor
280  if (fTrackCollection) fTrackCollection->Delete();
281  delete fTrackCollection;
282  delete fNumberOfTracksWrap;
283  delete fNumberOfRPsWrap;
284  delete fNumberOfPOIsWrap;
286  delete fShuffledIndexes;
287  delete fMothersCollection;
288  delete [] fNumberOfPOIs;
289 }
290 
291 //-----------------------------------------------------------------------
293  TF1 *gPsi2Psi4,
294  TF1 *gPsi3Psi5) {
295  //Use symmetry planes, setup correlations between different Psi_n
297 
298  //Correlations between Psi_1 and Psi_3
299  if(gPsi1Psi3) fPsi1Psi3 = gPsi1Psi3;
300  else {
301  fPsi1Psi3 = new TF1("fPsi1Psi3","[0]*x+[1]",0.,2.*TMath::Pi());
302  fPsi1Psi3->SetParameter(0,1.);
303  fPsi1Psi3->SetParameter(1,0.);
304  }
305 
306  //Correlations between Psi_2 and Psi_4
307  if(gPsi2Psi4) fPsi2Psi4 = gPsi2Psi4;
308  else {
309  fPsi2Psi4 = new TF1("fPsi2Psi4","[0]*x+[1]",0.,2.*TMath::Pi());
310  fPsi2Psi4->SetParameter(0,1.);
311  fPsi2Psi4->SetParameter(1,0.);
312  }
313 
314  //Correlations between Psi_3 and Psi_5
315  if(gPsi3Psi5) fPsi3Psi5 = gPsi3Psi5;
316  else {
317  fPsi3Psi5 = new TF1("fPsi3Psi5","[0]*x+[1]",0.,2.*TMath::Pi());
318  fPsi3Psi5->SetParameter(0,1.);
319  fPsi3Psi5->SetParameter(1,0.);
320  }
321 }
322 
323 //-----------------------------------------------------------------------
325  TF1* ptDist,
326  Double_t phiMin,
327  Double_t phiMax,
328  Double_t etaMin,
329  Double_t etaMax)
330 {
331  //generate nParticles random tracks uniform in phi and eta
332  //according to the specified pt distribution
333  if (!ptDist)
334  {
335  static TF1 ptdistribution("ptSpectra","x*TMath::Exp(-pow(0.13957*0.13957+x*x,0.5)/0.4)",0.1,10.);
336  ptDist=&ptdistribution;
337  }
338 
339  for (Int_t i=0; i<nParticles; i++)
340  {
341  AliFlowTrackSimple* track = new AliFlowTrackSimple();
342  track->SetPhi( gRandom->Uniform(phiMin,phiMax) );
343  track->SetEta( gRandom->Uniform(etaMin,etaMax) );
344  track->SetPt( ptDist->GetRandom() );
345  track->SetCharge( (gRandom->Uniform()-0.5<0)?-1:1 );
346  AddTrack(track);
347  }
349  Double_t betaParameter = gRandom->Gaus(0.,1.3);
350  fPsi1Psi3->SetParameter(1,betaParameter);
351 
352  betaParameter = gRandom->Gaus(0.,0.9);
353  fPsi2Psi4->SetParameter(1,betaParameter);
354 
355  betaParameter = gRandom->Gaus(0.,1.5);
356  fPsi3Psi5->SetParameter(1,betaParameter);
357 
358  fPsi1 = gRandom->Uniform(2.*TMath::Pi());
359  fPsi2 = gRandom->Uniform(2.*TMath::Pi());
360  fPsi3 = fPsi1Psi3->Eval(fPsi1);
361  if(fPsi3 < 0) fPsi3 += 2.*TMath::Pi();
362  else if(fPsi3 > 2.*TMath::Pi()) fPsi3 -= 2.*TMath::Pi();
363  fPsi4 = fPsi2Psi4->Eval(fPsi2);
364  if(fPsi4 < 0) fPsi4 += 2.*TMath::Pi();
365  else if(fPsi4 > 2.*TMath::Pi()) fPsi4 -= 2.*TMath::Pi();
366  fPsi5 = fPsi3Psi5->Eval(fPsi3);
367  if(fPsi5 < 0) fPsi5 += 2.*TMath::Pi();
368  else if(fPsi5 > 2.*TMath::Pi()) fPsi5 -= 2.*TMath::Pi();
369 
372  }
373  else {
374  fMCReactionPlaneAngle=gRandom->Uniform(0.0,TMath::TwoPi());
376  }
377  SetUserModified();
378 }
379 
380 //-----------------------------------------------------------------------
382 {
383  //get track i from collection
384  if (i>=fNumberOfTracks) return NULL;
385  Int_t trackIndex=i;
386  //if asked use the shuffled index
387  if (fShuffleTracks)
388  {
390  trackIndex=fShuffledIndexes[i];
391  }
392  AliFlowTrackSimple* pTrack = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(trackIndex)) ;
393  return pTrack;
394 }
395 
396 //-----------------------------------------------------------------------
398 {
399  //shuffle track indexes
400  if (!fShuffledIndexes)
401  {
402  //initialize the table with shuffled indexes
404  for (Int_t j=0; j<fNumberOfTracks; j++) { fShuffledIndexes[j]=j; }
405  }
406  //shuffle
407  std::random_shuffle(&fShuffledIndexes[0], &fShuffledIndexes[fNumberOfTracks]);
408  Printf("Tracks shuffled! tracks: %i",fNumberOfTracks);
409 }
410 
411 //-----------------------------------------------------------------------
413 {
414  //add a track, delete the old one if necessary
415  if (fNumberOfTracks < fTrackCollection->GetEntriesFast())
416  {
418  delete o;
419  }
420  fTrackCollection->AddAtAndExpand(track,fNumberOfTracks);
421  if (track->GetNDaughters()>0)
422  {
423  //if there track has daughters cache in the collection of mothers
424  fMothersCollection->Add(track);
425  }
426  TrackAdded();
427 }
428 
429 //-----------------------------------------------------------------------
431 {
432  //book keeping after a new track has been added
433  fNumberOfTracks++;
434  if (fShuffledIndexes)
435  {
436  delete [] fShuffledIndexes;
437  fShuffledIndexes=NULL;
438  }
439 }
440 
441 //-----------------------------------------------------------------------
443 {
445  if( !t ) { // If there was no track at the end of the list then create a new track
446  t=new AliFlowTrackSimple();
447  }
448 
449  return t;
450 }
451 
452 //-----------------------------------------------------------------------
454  TList *weightsList,
455  Bool_t usePhiWeights,
456  Bool_t usePtWeights,
457  Bool_t useEtaWeights )
458 {
459  // calculate Q-vector in harmonic n without weights (default harmonic n=2)
460  Double_t dQX = 0.;
461  Double_t dQY = 0.;
462  AliFlowVector vQ;
463  vQ.Set(0.,0.);
464 
465  Int_t iOrder = n;
466  Double_t sumOfWeights = 0.;
467  Double_t dPhi = 0.;
468  Double_t dPt = 0.;
469  Double_t dEta = 0.;
470  Double_t dWeight = 1.;
471 
472  AliFlowTrackSimple* pTrack = NULL;
473 
474  Int_t nBinsPhi = 0;
475  Double_t dBinWidthPt = 0.;
476  Double_t dPtMin = 0.;
477  Double_t dBinWidthEta = 0.;
478  Double_t dEtaMin = 0.;
479 
480  Double_t wPhi = 1.; // weight Phi
481  Double_t wPt = 1.; // weight Pt
482  Double_t wEta = 1.; // weight Eta
483 
484  TH1F *phiWeights = NULL;
485  TH1D *ptWeights = NULL;
486  TH1D *etaWeights = NULL;
487 
488  if(weightsList)
489  {
490  if(usePhiWeights)
491  {
492  phiWeights = dynamic_cast<TH1F *>(weightsList->FindObject("phi_weights"));
493  if(phiWeights) nBinsPhi = phiWeights->GetNbinsX();
494  }
495  if(usePtWeights)
496  {
497  ptWeights = dynamic_cast<TH1D *>(weightsList->FindObject("pt_weights"));
498  if(ptWeights)
499  {
500  dBinWidthPt = ptWeights->GetBinWidth(1); // assuming that all bins have the same width
501  dPtMin = (ptWeights->GetXaxis())->GetXmin();
502  }
503  }
504  if(useEtaWeights)
505  {
506  etaWeights = dynamic_cast<TH1D *>(weightsList->FindObject("eta_weights"));
507  if(etaWeights)
508  {
509  dBinWidthEta = etaWeights->GetBinWidth(1); // assuming that all bins have the same width
510  dEtaMin = (etaWeights->GetXaxis())->GetXmin();
511  }
512  }
513  } // end of if(weightsList)
514 
515  // loop over tracks
516  for(Int_t i=0; i<fNumberOfTracks; i++)
517  {
518  pTrack = (AliFlowTrackSimple*)fTrackCollection->At(i);
519  if(pTrack)
520  {
521  if(pTrack->InRPSelection())
522  {
523  dPhi = pTrack->Phi();
524  dPt = pTrack->Pt();
525  dEta = pTrack->Eta();
526  dWeight = pTrack->Weight();
527 
528  // determine Phi weight: (to be improved, I should here only access it + the treatment of gaps in the if statement)
529  if(phiWeights && nBinsPhi)
530  {
531  wPhi = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(dPhi*nBinsPhi/TMath::TwoPi())));
532  }
533  // determine v'(pt) weight:
534  if(ptWeights && dBinWidthPt)
535  {
536  wPt=ptWeights->GetBinContent(1+(Int_t)(TMath::Floor((dPt-dPtMin)/dBinWidthPt)));
537  }
538  // determine v'(eta) weight:
539  if(etaWeights && dBinWidthEta)
540  {
541  wEta=etaWeights->GetBinContent(1+(Int_t)(TMath::Floor((dEta-dEtaMin)/dBinWidthEta)));
542  }
543 
544  // building up the weighted Q-vector:
545  dQX += dWeight*wPhi*wPt*wEta*TMath::Cos(iOrder*dPhi);
546  dQY += dWeight*wPhi*wPt*wEta*TMath::Sin(iOrder*dPhi);
547 
548  // weighted multiplicity:
549  sumOfWeights += dWeight*wPhi*wPt*wEta;
550 
551  } // end of if (pTrack->InRPSelection())
552  } // end of if (pTrack)
553  else
554  {
555  cerr << "no particle!!!"<<endl;
556  }
557  } // loop over particles
558 
559  vQ.Set(dQX,dQY);
560  vQ.SetMult(sumOfWeights);
561  vQ.SetHarmonic(iOrder);
563  vQ.SetSubeventNumber(-1);
564 
565  return vQ;
566 
567 }
568 
569 //-----------------------------------------------------------------------
571  Int_t n,
572  TList *weightsList,
573  Bool_t usePhiWeights,
574  Bool_t usePtWeights,
575  Bool_t useEtaWeights )
576 {
577 
578  // calculate Q-vector in harmonic n without weights (default harmonic n=2)
579  Double_t dQX = 0.;
580  Double_t dQY = 0.;
581 
582  Int_t iOrder = n;
583  Double_t sumOfWeights = 0.;
584  Double_t dPhi = 0.;
585  Double_t dPt = 0.;
586  Double_t dEta = 0.;
587  Double_t dWeight = 1.;
588 
589  AliFlowTrackSimple* pTrack = NULL;
590 
591  Int_t iNbinsPhiSub0 = 0;
592  Int_t iNbinsPhiSub1 = 0;
593  Double_t dBinWidthPt = 0.;
594  Double_t dPtMin = 0.;
595  Double_t dBinWidthEta= 0.;
596  Double_t dEtaMin = 0.;
597 
598  Double_t dWphi = 1.; // weight Phi
599  Double_t dWpt = 1.; // weight Pt
600  Double_t dWeta = 1.; // weight Eta
601 
602  TH1F* phiWeightsSub0 = NULL;
603  TH1F* phiWeightsSub1 = NULL;
604  TH1D* ptWeights = NULL;
605  TH1D* etaWeights = NULL;
606 
607  if(weightsList)
608  {
609  if(usePhiWeights)
610  {
611  phiWeightsSub0 = dynamic_cast<TH1F *>(weightsList->FindObject("phi_weights_sub0"));
612  if(phiWeightsSub0) {
613  iNbinsPhiSub0 = phiWeightsSub0->GetNbinsX();
614  }
615  phiWeightsSub1 = dynamic_cast<TH1F *>(weightsList->FindObject("phi_weights_sub1"));
616  if(phiWeightsSub1) {
617  iNbinsPhiSub1 = phiWeightsSub1->GetNbinsX();
618  }
619  }
620  if(usePtWeights)
621  {
622  ptWeights = dynamic_cast<TH1D *>(weightsList->FindObject("pt_weights"));
623  if(ptWeights)
624  {
625  dBinWidthPt = ptWeights->GetBinWidth(1); // assuming that all bins have the same width
626  dPtMin = (ptWeights->GetXaxis())->GetXmin();
627  }
628  }
629  if(useEtaWeights)
630  {
631  etaWeights = dynamic_cast<TH1D *>(weightsList->FindObject("eta_weights"));
632  if(etaWeights)
633  {
634  dBinWidthEta = etaWeights->GetBinWidth(1); // assuming that all bins have the same width
635  dEtaMin = (etaWeights->GetXaxis())->GetXmin();
636  }
637  }
638  } // end of if(weightsList)
639 
640  //loop over the two subevents
641  for (Int_t s=0; s<2; s++)
642  {
643  // loop over tracks
644  for(Int_t i=0; i<fNumberOfTracks; i++)
645  {
646  pTrack = (AliFlowTrackSimple*)fTrackCollection->At(i);
647  if(!pTrack)
648  {
649  cerr << "no particle!!!"<<endl;
650  continue;
651  }
652  if(pTrack->InRPSelection() && (pTrack->InSubevent(s)))
653  {
654  dPhi = pTrack->Phi();
655  dPt = pTrack->Pt();
656  dEta = pTrack->Eta();
657  dWeight = pTrack->Weight();
658 
659  // determine Phi weight: (to be improved, I should here only access it + the treatment of gaps in the if statement)
660  //subevent 0
661  if(s == 0) {
662  if(phiWeightsSub0 && iNbinsPhiSub0) {
663  Int_t phiBin = 1+(Int_t)(TMath::Floor(dPhi*iNbinsPhiSub0/TMath::TwoPi()));
664  //use the phi value at the center of the bin
665  dPhi = phiWeightsSub0->GetBinCenter(phiBin);
666  dWphi = phiWeightsSub0->GetBinContent(phiBin);
667  }
668  }
669  //subevent 1
670  else if (s == 1) {
671  if(phiWeightsSub1 && iNbinsPhiSub1) {
672  Int_t phiBin = 1+(Int_t)(TMath::Floor(dPhi*iNbinsPhiSub1/TMath::TwoPi()));
673  //use the phi value at the center of the bin
674  dPhi = phiWeightsSub1->GetBinCenter(phiBin);
675  dWphi = phiWeightsSub1->GetBinContent(phiBin);
676  }
677  }
678 
679  // determine v'(pt) weight:
680  if(ptWeights && dBinWidthPt)
681  {
682  dWpt=ptWeights->GetBinContent(1+(Int_t)(TMath::Floor((dPt-dPtMin)/dBinWidthPt)));
683  }
684 
685  // determine v'(eta) weight:
686  if(etaWeights && dBinWidthEta)
687  {
688  dWeta=etaWeights->GetBinContent(1+(Int_t)(TMath::Floor((dEta-dEtaMin)/dBinWidthEta)));
689  }
690 
691  // building up the weighted Q-vector:
692  dQX += dWeight*dWphi*dWpt*dWeta*TMath::Cos(iOrder*dPhi);
693  dQY += dWeight*dWphi*dWpt*dWeta*TMath::Sin(iOrder*dPhi);
694 
695  // weighted multiplicity:
696  sumOfWeights+=dWeight*dWphi*dWpt*dWeta;
697 
698  } // end of if (pTrack->InRPSelection())
699  } // loop over particles
700 
701  Qarray[s].Set(dQX,dQY);
702  Qarray[s].SetMult(sumOfWeights);
703  Qarray[s].SetHarmonic(iOrder);
705  Qarray[s].SetSubeventNumber(s);
706 
707  //reset
708  sumOfWeights = 0.;
709  dQX = 0.;
710  dQY = 0.;
711  }
712 
713 }
714 
715 
716 //-----------------------------------------------------------------------
718 {
719  Qarray[0] = fZNCQ;
720  Qarray[1] = fZNAQ;
721 }
722 
723 //-----------------------------------------------------------------------------
724 
726 {
727  fZNCQ = AliFlowVector(QVC[0],QVC[1],MC,1);
728  fZNAQ = AliFlowVector(QVA[0],QVA[1],MA,1);
729 }
730 //-----------------------------------------------------------------------
732 {
733  pos[0] = fVtxPos[0];
734  pos[1] = fVtxPos[1];
735  pos[2] = fVtxPos[2];
736 }
737 
738 //-----------------------------------------------------------------------------
739 
741 {
742  fVtxPos[0] = pos[0];
743  fVtxPos[1] = pos[1];
744  fVtxPos[2] = pos[2];
745 }
746 //-----------------------------------------------------------------------
747 
749 {
750  // -*-*-*-*-*Print some global quantities for this histogram collection class *-*-*-*-*-*-*-*
751  // ===============================================
752  // printf( "TH1.Print Name = %s, Entries= %d, Total sum= %g\n",GetName(),Int_t(fEntries),GetSumOfWeights());
753  printf( "Class.Print Name = %s, #tracks= %d, Number of RPs= %d, Number of POIs = %d, MC EventPlaneAngle= %f\n",
755 
756  TString optionstr(option);
757  if (!optionstr.Contains("all")) return;
758  if (fTrackCollection)
759  {
760  fTrackCollection->Print(option);
761  }
762  else
763  {
764  printf( "Empty track collection \n");
765  }
766 }
767 
768 //-----------------------------------------------------------------------
769 void AliFlowEventSimple::Browse(TBrowser *b)
770 {
771  //browse in TBrowser
772  if (!b) return;
773  if (!fNumberOfTracksWrap)
774  {
775  fNumberOfTracksWrap = new TParameter<int>("fNumberOfTracks", fNumberOfTracks);
776  b->Add(fNumberOfTracksWrap);
777  }
778  if (!fNumberOfRPsWrap)
779  {
780  fNumberOfRPsWrap = new TParameter<int>("fNumberOfRPs", GetNumberOfRPs());
781  b->Add(fNumberOfRPsWrap);
782  }
783  if (!fNumberOfPOIsWrap)
784  {
785  fNumberOfPOIsWrap = new TParameter<int>("fNumberOfPOIs", GetNumberOfPOIs());
786  b->Add(fNumberOfPOIsWrap);
787  }
789  {
790  fMCReactionPlaneAngleWrap = new TParameter<double>(" fMCReactionPlaneAngle", fMCReactionPlaneAngle);
791  b->Add( fMCReactionPlaneAngleWrap);
792  }
793  if (fTrackCollection) b->Add(fTrackCollection,"AliFlowTracksSimple");
794 }
795 
796 //-----------------------------------------------------------------------
798  const AliFlowTrackSimpleCuts* rpCuts,
799  const AliFlowTrackSimpleCuts* poiCuts):
800  fTrackCollection(NULL),
801  fReferenceMultiplicity(0),
802  fNumberOfTracks(0),
803  fUseGlauberMCSymmetryPlanes(kFALSE),
804  fUseExternalSymmetryPlanes(kFALSE),
805  fPsi1(0.),
806  fPsi2(0.),
807  fPsi3(0.),
808  fPsi4(0.),
809  fPsi5(0.),
810  fPsi1Psi3(0x0),
811  fPsi2Psi4(0x0),
812  fPsi3Psi5(0x0),
813  fMCReactionPlaneAngle(0.),
814  fMCReactionPlaneAngleIsSet(kFALSE),
815  fAfterBurnerPrecision(0.001),
816  fUserModified(kFALSE),
817  fNumberOfTracksWrap(NULL),
818  fNumberOfRPsWrap(NULL),
819  fNumberOfPOIsWrap(NULL),
820  fMCReactionPlaneAngleWrap(NULL),
821  fShuffledIndexes(NULL),
822  fShuffleTracks(kFALSE),
823  fMothersCollection(new TObjArray()),
824  fCentrality(-1.),
825  fCentralityCL1(-1.),
826  fNITSCL1(-1.),
827  fCentralityTRK(-1.),
828  fRun(-1),
829  fZNCM(0.),
830  fZNAM(0.),
831  fNumberOfPOItypes(2),
832  fNumberOfPOIs(new Int_t[fNumberOfPOItypes])
833 {
834  //constructor, fills the event from a TTree of kinematic.root files
835  //applies RP and POI cuts, tags the tracks
836 
837  Int_t numberOfInputTracks = inputTree->GetEntries() ;
838  fTrackCollection = new TObjArray(numberOfInputTracks/2);
839 
840  TParticle* pParticle = new TParticle();
841  inputTree->SetBranchAddress("Particles",&pParticle);
842 
843  for (Int_t i=0; i<numberOfInputTracks; i++)
844  {
845  inputTree->GetEntry(i); //get input particle
846 
847  if (!pParticle) continue; //no particle
848  if (!pParticle->IsPrimary()) continue;
849 
850  Bool_t rpOK = (rpCuts->PassesCuts(pParticle)>0);
851  Bool_t poiOK = poiCuts->PassesCuts(pParticle);
852  Int_t poiType = poiCuts->GetPOItype();
853 
854  if (rpOK || poiOK)
855  {
856  AliFlowTrackSimple* pTrack = new AliFlowTrackSimple(pParticle);
857 
858  //marking the particles used for int. flow:
859  if(rpOK)
860  {
861  pTrack->TagRP(kTRUE);
863  cout<<"numberOfRPs = "<<fNumberOfPOIs[0]<<endl;
864  }
865  //marking the particles used for diff. flow:
866  if(poiOK)
867  {
868  pTrack->Tag(poiType);
869  IncrementNumberOfPOIs(poiType);
870  printf("fNumberOfPOIs[%i] = %i",poiType,fNumberOfPOIs[poiType]);
871  }
872  //adding a particles which were used either for int. or diff. flow to the list
873  AddTrack(pTrack);
874  }
875  }//for i
876  delete pParticle;
877 
878  fZNCQ = AliFlowVector();
879  fZNAQ = AliFlowVector();
880  for(Int_t i(0); i < 3; i++) {
881  fVtxPos[i] = 0.;
882  }
883 }
884 
885 //_____________________________________________________________________________
887 {
888  //clone every track n times to add non-flow
889  if (n<=0) return; //no use to clone stuff zero or less times
890  Int_t ntracks = fNumberOfTracks;
891  fTrackCollection->Expand((n+1)*fNumberOfTracks);
892  for (Int_t i=0; i<n; i++)
893  {
894  for (Int_t itrack=0; itrack<ntracks; itrack++)
895  {
896  AliFlowTrackSimple* track = dynamic_cast<AliFlowTrackSimple*>(fTrackCollection->At(itrack));
897  if (!track) continue;
898  AddTrack(static_cast<AliFlowTrackSimple*>(track->Clone()));
899  }
900  }
901  SetUserModified();
902 }
903 
904 //_____________________________________________________________________________
906 {
907  //smear pt of all tracks by gaussian with sigma=res
908  for (Int_t i=0; i<fNumberOfTracks; i++)
909  {
910  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
911  if (track) track->ResolutionPt(res);
912  }
913  SetUserModified();
914 }
915 
916 //_____________________________________________________________________________
918  Double_t etaMaxA,
919  Double_t etaMinB,
920  Double_t etaMaxB )
921 {
922  //Flag two subevents in given eta ranges
923  for (Int_t i=0; i<fNumberOfTracks; i++)
924  {
925  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
926  if (!track) continue;
927  track->ResetSubEventTags();
928  Double_t eta=track->Eta();
929  if (eta >= etaMinA && eta <= etaMaxA) track->SetForSubevent(0);
930  if (eta >= etaMinB && eta <= etaMaxB) track->SetForSubevent(1);
931  }
932 }
933 
934 //_____________________________________________________________________________
936 {
937  //Flag two subevents in given eta ranges
938  for (Int_t i=0; i<fNumberOfTracks; i++)
939  {
940  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
941  if (!track) continue;
942  track->ResetSubEventTags();
943  Int_t charge=track->Charge();
944  if (charge<0) track->SetForSubevent(0);
945  if (charge>0) track->SetForSubevent(1);
946  }
947 }
948 
949 //_____________________________________________________________________________
951 {
952  //add v2 to all tracks wrt the reaction plane angle
953  for (Int_t i=0; i<fNumberOfTracks; i++)
954  {
955  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
956  if (track) {
958  track->AddV1(v1, fPsi1, fAfterBurnerPrecision);
959  else
961  }
962  }
963  SetUserModified();
964 }
965 
966 //_____________________________________________________________________________
968 {
969  //add v2 to all tracks wrt the reaction plane angle
970  for (Int_t i=0; i<fNumberOfTracks; i++)
971  {
972  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
973  if (track) {
975  track->AddV2(v2, fPsi2, fAfterBurnerPrecision);
976  else
978  }
979  }
980  SetUserModified();
981 }
982 
983 //_____________________________________________________________________________
985 {
986  //add v3 to all tracks wrt the reaction plane angle
987  for (Int_t i=0; i<fNumberOfTracks; i++)
988  {
989  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
990  if(track) {
992  track->AddV3(v3, fPsi3, fAfterBurnerPrecision);
993  else
995  }
996  }
997  SetUserModified();
998 }
999 
1000 //_____________________________________________________________________________
1002 {
1003  //add v4 to all tracks wrt the reaction plane angle
1004  for (Int_t i=0; i<fNumberOfTracks; i++)
1005  {
1006  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
1007  if(track) {
1009  track->AddV4(v4, fPsi4, fAfterBurnerPrecision);
1010  else
1012  }
1013  }
1014  SetUserModified();
1015 }
1016 
1017 //_____________________________________________________________________________
1019 {
1020  //add v4 to all tracks wrt the reaction plane angle
1021  for (Int_t i=0; i<fNumberOfTracks; i++)
1022  {
1023  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
1024  if(track) {
1026  track->AddV5(v5, fPsi5, fAfterBurnerPrecision);
1027  else
1029  }
1030  }
1031  SetUserModified();
1032 }
1033 
1034 //_____________________________________________________________________________
1036  Double_t rp1, Double_t rp2, Double_t rp3, Double_t rp4, Double_t rp5 )
1037 {
1038  //add flow to all tracks wrt the reaction plane angle, for all harmonic separate angle
1039  for (Int_t i=0; i<fNumberOfTracks; i++)
1040  {
1041  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
1042  if (track) track->AddFlow(v1,v2,v3,v4,v5,rp1,rp2,rp3,rp4,rp5,fAfterBurnerPrecision);
1043  }
1044  SetUserModified();
1045 }
1046 
1047 //_____________________________________________________________________________
1049 {
1050  //add flow to all tracks wrt the reaction plane angle
1051  for (Int_t i=0; i<fNumberOfTracks; i++)
1052  {
1053  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
1054  if (track) track->AddFlow(v1,v2,v3,v4,v5,fMCReactionPlaneAngle, fAfterBurnerPrecision);
1055  }
1056  SetUserModified();
1057 }
1058 
1059 //_____________________________________________________________________________
1060 void AliFlowEventSimple::AddV2( TF1* ptDepV2 )
1061 {
1062  //add v2 to all tracks wrt the reaction plane angle
1063  for (Int_t i=0; i<fNumberOfTracks; i++)
1064  {
1065  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
1066  if (!track) continue;
1067  Double_t v2 = ptDepV2->Eval(track->Pt());
1069  }
1070  SetUserModified();
1071 }
1072 
1073 //_____________________________________________________________________________
1074 void AliFlowEventSimple::AddV2( TF2* ptEtaDepV2 )
1075 {
1076  //add v2 to all tracks wrt the reaction plane angle
1077  for (Int_t i=0; i<fNumberOfTracks; i++)
1078  {
1079  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
1080  if (!track) continue;
1081  Double_t v2 = ptEtaDepV2->Eval(track->Pt(), track->Eta());
1083  }
1084  SetUserModified();
1085 }
1086 
1087 //_____________________________________________________________________________
1089 {
1090  //tag tracks as reference particles (RPs)
1091  for (Int_t i=0; i<fNumberOfTracks; i++)
1092  {
1093  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
1094  if (!track) continue;
1095  Bool_t pass=cuts->PassesCuts(track);
1096  Bool_t rpTrack=track->InRPSelection();
1097  if (pass)
1098  {
1099  if (!rpTrack) fNumberOfPOIs[0]++; //only increase if not already tagged
1100  }
1101  else
1102  {
1103  if (rpTrack) fNumberOfPOIs[0]--; //only decrease if detagging
1104  }
1105  track->SetForRPSelection(pass);
1106  }
1107 }
1108 
1109 //_____________________________________________________________________________
1111 {
1112  //tag tracks as particles of interest (POIs)
1113  for (Int_t i=0; i<fNumberOfTracks; i++)
1114  {
1115  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
1116  if (!track) continue;
1117  Bool_t pass=cuts->PassesCuts(track);
1118  Bool_t poiTrack=track->InPOISelection();
1119  if (pass)
1120  {
1121  if (!poiTrack) fNumberOfPOIs[poiType]++; //only increase if not already tagged
1122  }
1123  else
1124  {
1125  if (poiTrack) fNumberOfPOIs[poiType]--; //only decrease if detagging
1126  }
1127  track->Tag(poiType,pass);
1128  }
1129 }
1130 
1131 //_____________________________________________________________________________
1133 {
1134  // simple interface to tagging poi's and rp's
1135  TagPOI(cutsRP, 0);
1136  TagPOI(cutsPOI, 1);
1137 }
1138 //_____________________________________________________________________________
1140  Double_t etaMax,
1141  Double_t phiMin,
1142  Double_t phiMax )
1143 {
1144  //mark tracks in given eta-phi region as dead
1145  //by resetting the flow bits
1146  for (Int_t i=0; i<fNumberOfTracks; i++)
1147  {
1148  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
1149  Double_t eta = track->Eta();
1150  Double_t phi = track->Phi();
1151  if (eta>etaMin && eta<etaMax && phi>phiMin && phi<phiMax)
1152  {
1153  if (track->InRPSelection()) {fNumberOfPOIs[0]--;}
1154  for (Int_t j=1; j<fNumberOfPOItypes; j++)
1155  {
1156  if (track->CheckTag(j)) {fNumberOfPOIs[j]--;}
1157  }
1158  track->ResetPOItype();
1159  }
1160  }
1161 }
1162 
1163 //_____________________________________________________________________________
1165 {
1166  //remove tracks that have no flow tags set and cleanup the container
1167  //returns number of cleaned tracks
1168  Int_t ncleaned=0;
1169  for (Int_t i=0; i<fNumberOfTracks; i++)
1170  {
1171  AliFlowTrackSimple* track = static_cast<AliFlowTrackSimple*>(fTrackCollection->At(i));
1172  if (!track) continue;
1173  if (track->IsDead()) {delete track;track=NULL;ncleaned++;}
1174  }
1175  fTrackCollection->Compress(); //clean up empty slots
1176  fNumberOfTracks-=ncleaned; //update number of tracks
1177  delete [] fShuffledIndexes; fShuffledIndexes=NULL;
1178  return ncleaned;
1179 }
1180 
1181 //_____________________________________________________________________________
1183 {
1184  //return a standard pt dependent v2 formula, user has to clean up!
1185  return new TF1("StandardPtDepV2","((x<1.0)*(0.05/1.0)*x+(x>=1.0)*0.05)");
1186 }
1187 
1188 //_____________________________________________________________________________
1190 {
1191  //returna standard pt and eta dependent v2 formula, user has to clean up!
1192  return new TF2 ("f","((x<1)*.1*x+(x>=1)*.1)*(1-0.2*TMath::Abs(y))");
1193 }
1194 
1195 //_____________________________________________________________________________
1197 {
1198  //return a standard pt spectrum, user has to clean up!
1199  return new TF1("StandardPtSpectrum","x*TMath::Exp(-pow(0.13957*0.13957+x*x,0.5)/0.4)",0.1,10.);
1200 }
1201 
1202 //_____________________________________________________________________________
1204 {
1205  //clear the counters without deleting allocated objects so they can be reused
1207  fNumberOfTracks = 0;
1208  for (Int_t i=0; i<fNumberOfPOItypes; i++)
1209  {
1210  fNumberOfPOIs[i] = 0;
1211  }
1212  fMCReactionPlaneAngle = 0.0;
1213  fMCReactionPlaneAngleIsSet = kFALSE;
1214  fAfterBurnerPrecision = 0.001;
1215  fUserModified = kFALSE;
1216  delete [] fShuffledIndexes; fShuffledIndexes=NULL;
1217 }
void SetCharge(Int_t charge)
Int_t charge
void Print(Option_t *option="") const
void SetForSubevent(Int_t i)
void Browse(TBrowser *b)
double Double_t
Definition: External.C:58
virtual AliFlowVector GetQ(Int_t n=2, TList *weightsList=NULL, Bool_t usePhiWeights=kFALSE, Bool_t usePtWeights=kFALSE, Bool_t useEtaWeights=kFALSE)
void SetEta(Double_t eta)
virtual Int_t GetNDaughters() const
void AddV3(Double_t v3)
virtual void GetVertexPosition(Double_t *pos)
AliFlowTrackSimple * GetTrack(Int_t i)
void AddV1(Double_t v1, Double_t reactionPlaneAngle, Double_t precision, Int_t maxNumberOfIterations=100)
ClassImp(AliFlowEventSimple) AliFlowEventSimple
Bool_t InSubevent(Int_t i) const
Int_t GetNumberOfRPs() const
virtual void SetZDC2Qsub(Double_t *QVC, Double_t MC, Double_t *QVA, Double_t MA)
void AddV5(Double_t v5, Double_t reactionPlaneAngle, Double_t precision, Int_t maxNumberOfIterations=100)
void AddFlow(Double_t v1, Double_t v2, Double_t v3, Double_t v4, Double_t v5)
virtual AliFlowTrackSimple * Clone(const char *option="") const
TParameter< Int_t > * fNumberOfRPsWrap
number of tracks in TBrowser
void TagRP(const AliFlowTrackSimpleCuts *cuts)
static TF2 * SimplePtEtaDepV2()
void TagTracks(const AliFlowTrackSimpleCuts *cutsRP, const AliFlowTrackSimpleCuts *cutsPOI)
void AddV4(Double_t v4)
AliFlowEventSimple & operator=(const AliFlowEventSimple &anEvent)
static TF1 * SimplePtSpectrum()
void SetSubeventNumber(Int_t n)
Definition: AliFlowVector.h:51
void AddTrack(AliFlowTrackSimple *track)
void TagPOI(const AliFlowTrackSimpleCuts *cuts, Int_t poiType=1)
Bool_t PassesCuts(const AliFlowTrackSimple *track) const
void SetUserModified(Bool_t s=kTRUE)
TRandom * gRandom
void TagRP(Bool_t b=kTRUE)
Bool_t InRPSelection() const
virtual void SetVertexPosition(Double_t *pos)
void IncrementNumberOfPOIs(Int_t poiType=1)
Int_t * fShuffledIndexes
the angle of the reaction plane from the MC truth in TBrowser
TParameter< Double_t > * fMCReactionPlaneAngleWrap
number of tracks that have passed the POI selection in TBrowser
void SetForRPSelection(Bool_t b=kTRUE)
Double_t Phi() const
int Int_t
Definition: External.C:63
void SetHarmonic(Int_t h)
Definition: AliFlowVector.h:47
TParameter< Int_t > * fNumberOfPOIsWrap
number of tracks that have passed the RP selection in TBrowser
void SetNumberOfPOIs(Int_t nubmerOfPOIs, Int_t poiType=1)
void AddV4(Double_t v4, Double_t reactionPlaneAngle, Double_t precision, Int_t maxNumberOfIterations=100)
void ResolutionPt(Double_t res)
void SetMult(Double_t mult)
Definition: AliFlowVector.h:45
Definition: External.C:212
Bool_t CheckTag(Int_t n)
Int_t GetNumberOfPOIs(Int_t i=1) const
void Tag(Int_t n, Bool_t b=kTRUE)
void AddV1(Double_t v1)
Bool_t IsDead() const
void ResolutionPt(Double_t resolution)
virtual void Generate(Int_t nParticles, TF1 *ptDist=NULL, Double_t phiMin=0.0, Double_t phiMax=TMath::TwoPi(), Double_t etaMin=-1.0, Double_t etaMax=1.0)
Bool_t fShuffleTracks
placeholder for randomized indexes
TObjArray * fTrackCollection
virtual void Get2Qsub(AliFlowVector *Qarray, Int_t n=2, TList *weightsList=NULL, Bool_t usePhiWeights=kFALSE, Bool_t usePtWeights=kFALSE, Bool_t useEtaWeights=kFALSE)
void SetPhi(Double_t phi)
void DefineDeadZone(Double_t etaMin, Double_t etaMax, Double_t phiMin, Double_t phiMax)
AliFlowTrackSimple * MakeNewTrack()
void SetPt(Double_t pt)
void AddV2(Double_t v2, Double_t reactionPlaneAngle, Double_t precision, Int_t maxNumberOfIterations=100)
void AddV5(Double_t v5)
void SetPOItype(Int_t t)
Definition: AliFlowVector.h:49
virtual void GetZDC2Qsub(AliFlowVector *Qarray)
void AddFlow(Double_t v1, Double_t v2, Double_t v3, Double_t v4, Double_t reactionPlaneAngle, Double_t precision, Int_t maxNumberOfIterations=100)
void AddV3(Double_t v3, Double_t reactionPlaneAngle, Double_t precision, Int_t maxNumberOfIterations=100)
Double_t Pt() const
TParameter< Int_t > * fNumberOfTracksWrap
Double_t Weight() const
void AddV2(Double_t v2)
TObjArray * fMothersCollection
void TagSubeventsInEta(Double_t etaMinA, Double_t etaMaxA, Double_t etaMinB, Double_t etaMaxB)
void SetUseExternalSymmetryPlanes(TF1 *gPsi1Psi3=0x0, TF1 *gPsi2Psi4=0x0, TF1 *gPsi3Psi5=0x0)
static TF1 * SimplePtDepV2()
const char Option_t
Definition: External.C:48
Bool_t InPOISelection(Int_t poiType=1) const
Double_t Eta() const
bool Bool_t
Definition: External.C:53
Double_t fCentrality
cache the particles with daughters
Bool_t MC(TH1F *hs, TH1F *hb, Double_t &sgn, Double_t &errsgn, Double_t &bkg, Double_t &errbkg, Double_t &sgnf, Double_t &errsgnf, Double_t &sigmaused, Int_t &status)