Added check for wrong records in the config file (R. Shaoyan)
[u/mrichter/AliRoot.git] / PWG2 / FLOW / AliFlowCommon / AliFlowAnalysisWithQCumulants.cxx
CommitLineData
bc92c0cb 1/*************************************************************************
2* Copyright(c) 1998-2008, 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 * flow analysis with Q-cumulants *
18 * *
19 * author: Ante Bilandzic *
20 * (anteb@nikhef.nl) *
21 *********************************/
22
23#define AliFlowAnalysisWithQCumulants_cxx
24
25#include "Riostream.h"
26#include "AliFlowCommonConstants.h"
27#include "AliFlowCommonHist.h"
28#include "AliFlowCommonHistResults.h"
29#include "TChain.h"
30#include "TFile.h"
1315fe58 31#include "TList.h"
e085f1a9 32#include "TGraph.h"
bc92c0cb 33#include "TParticle.h"
34#include "TRandom3.h"
1315fe58 35#include "TStyle.h"
bc92c0cb 36#include "TProfile.h"
37#include "TProfile2D.h"
38#include "TProfile3D.h"
1dfa3c16 39#include "TMath.h"
e085f1a9 40#include "TArrow.h"
41#include "TPaveLabel.h"
42#include "TCanvas.h"
bc92c0cb 43#include "AliFlowEventSimple.h"
44#include "AliFlowTrackSimple.h"
45#include "AliFlowAnalysisWithQCumulants.h"
3d824203 46#include "TArrayD.h"
bc92c0cb 47#include "TRandom.h"
48
49class TH1;
9c1a9547 50class TH2;
bc92c0cb 51class TGraph;
52class TPave;
53class TLatex;
54class TMarker;
55class TRandom3;
56class TObjArray;
57class TList;
58class TCanvas;
59class TSystem;
60class TROOT;
61class AliFlowVector;
62class TVector;
63
64//================================================================================================================
65
66ClassImp(AliFlowAnalysisWithQCumulants)
67
68AliFlowAnalysisWithQCumulants::AliFlowAnalysisWithQCumulants():
69 fTrack(NULL),
70 fHistList(NULL),
ae733b3b 71 fDiffFlowList(NULL),
03a02aca 72 fWeightsList(NULL),
9c1a9547 73 fResultsList(NULL),
1315fe58 74 fAvMultIntFlowQC(NULL),
bc92c0cb 75 fQvectorComponents(NULL),
1315fe58 76 fDiffFlowResults2ndOrderQC(NULL),
77 fDiffFlowResults4thOrderQC(NULL),
78 fCovariances(NULL),
e085f1a9 79 fQvectorForEachEventX(NULL),//to be removed
80 fQvectorForEachEventY(NULL),//to be removed
bc92c0cb 81 fQCorrelations(NULL),
9c1a9547 82 fQCorrelationsW(NULL),
8842fb2b 83 fQProduct(NULL),
bc92c0cb 84 fDirectCorrelations(NULL),
9c1a9547 85 fDirectCorrelationsW(NULL),
86 fDirectCorrelationsDiffFlow(NULL),
87 fDirectCorrelationsDiffFlowW(NULL),
1dfa3c16 88 f2PerPtBin1n1nPOI(NULL),
1dfa3c16 89 f4PerPtBin1n1n1n1nPOI(NULL),
1dfa3c16 90 f2PerEtaBin1n1nPOI(NULL),
1dfa3c16 91 f4PerEtaBin1n1n1n1nPOI(NULL),
3d824203 92 f2WPerPtBin1n1nPOI(NULL),
3d824203 93 f4WPerPtBin1n1n1n1nPOI(NULL),
3d824203 94 f2WPerEtaBin1n1nPOI(NULL),
95 f4WPerEtaBin1n1n1n1nPOI(NULL),
77515452 96 f2PerPtBin1n1nRP(NULL),
97 f4PerPtBin1n1n1n1nRP(NULL),
98 f2PerEtaBin1n1nRP(NULL),
99 f4PerEtaBin1n1n1n1nRP(NULL),
3d824203 100 f2WPerPtBin1n1nRP(NULL),
101 f4WPerPtBin1n1n1n1nRP(NULL),
3d824203 102 f2WPerEtaBin1n1nRP(NULL),
103 f4WPerEtaBin1n1n1n1nRP(NULL),
cb308e83 104 fCommonHists2nd(NULL),
105 fCommonHists4th(NULL),
106 fCommonHists6th(NULL),
107 fCommonHists8th(NULL),
8842fb2b 108 fCommonHistsResults2nd(NULL),
109 fCommonHistsResults4th(NULL),
110 fCommonHistsResults6th(NULL),
111 fCommonHistsResults8th(NULL),
52021ae2 112 f2pDistribution(NULL),
113 f4pDistribution(NULL),
114 f6pDistribution(NULL),
5e838eeb 115 f8pDistribution(NULL),
8842fb2b 116 fnBinsPt(0),
117 fPtMin(0),
1dfa3c16 118 fPtMax(0),
119 fnBinsEta(0),
120 fEtaMin(0),
e085f1a9 121 fEtaMax(0),
122 fEventCounter(0),
123 fUsePhiWeights(kFALSE),
124 fUsePtWeights(kFALSE),
9c1a9547 125 fUseEtaWeights(kFALSE),
126 fUseWeights(kFALSE),
127 fUseWeightsBits(NULL),
9c1a9547 128
129 // ...................................................................................................................
130 // Q_{n,k} and S^M_{n,k}:
131 fReQ(NULL),
132 fImQ(NULL),
133 fSMpk(NULL),
134
135 // q_n and m:
136 fReqnPtEta(NULL),
137 fImqnPtEta(NULL),
138 fmPtEta(NULL),
139
140 // non-weighted q''_{n} and q''_{2n}:
141 fReqPrimePrime1nPtEta(NULL),
142 fImqPrimePrime1nPtEta(NULL),
143 fReqPrimePrime2nPtEta(NULL),
144 fImqPrimePrime2nPtEta(NULL),
145
146 // weighted q''_{n,2k} and q''_{2n,k}:
147 fReqPrimePrime1n2kPtEta(NULL),
148 fImqPrimePrime1n2kPtEta(NULL),
149 fReqPrimePrime2n1kPtEta(NULL),
150 fImqPrimePrime2n1kPtEta(NULL),
151
152 // m''
153 fmPrimePrimePtEta(NULL),
154
155 // S^{m''}_{n,k}
156 fSmPrimePrime1p1kPtEta(NULL),
157 fSmPrimePrime1p2kPtEta(NULL),
158 fSmPrimePrime1p3kPtEta(NULL),
159
160 // non-weighted q_RP{n} and q_RP{2n}:
161 fReqRP1nPtEta(NULL),
162 fImqRP1nPtEta(NULL),
163 fReqRP2nPtEta(NULL),
164 fImqRP2nPtEta(NULL),
165
166 // weighted q_RP{n,2k} and q_RP{2n,k} (for each (pt,eta) bin for RPs)
167 fReqRP1n2kPtEta(NULL),
168 fImqRP1n2kPtEta(NULL),
169 fReqRP2n1kPtEta(NULL),
170 fImqRP2n1kPtEta(NULL),
171
172 // m_RP:
173 fmRPPtEta(NULL), // # of particles which are RPs for each (pt,eta) bin
174
175 // S^{m_RP}_{p,k} (for each (pt,eta) bin for RPs):
176 fSmRP1p1kPtEta(NULL),
177 fSmRP1p2kPtEta(NULL),
178 fSmRP1p3kPtEta(NULL),
179
180 // ----- RESULTS ----
181
182 // non-weighted integrated flow:
183 fIntFlowResultsQC(NULL),
184 fIntFlowResultsPOIQC(NULL),
185 fIntFlowResultsRPQC(NULL),
186
187 // weighted integrated flow:
188 fIntFlowResultsQCW(NULL),
189 fIntFlowResultsPOIQCW(NULL),
190 fIntFlowResultsRPQCW(NULL),
191
192 // non-weighted correlations for each (pt,eta) bin for POIs:
193 f2pPtEtaPOI(NULL),
194 f4pPtEtaPOI(NULL),
195 f6pPtEtaPOI(NULL),
196 f8pPtEtaPOI(NULL),
197
198 // non-weighted final results for differential flow for POIs:
199 // 3D (pt,eta)
200 fvn2ndPtEtaPOI(NULL),
201 fvn4thPtEtaPOI(NULL),
202 fvn6thPtEtaPOI(NULL),
203 fvn8thPtEtaPOI(NULL),
204 // 2D (pt)
205 fvn2ndPtPOI(NULL),
206 fvn4thPtPOI(NULL),
207 fvn6thPtPOI(NULL),
208 fvn8thPtPOI(NULL),
209 // 2D (eta)
210 fvn2ndEtaPOI(NULL),
211 fvn4thEtaPOI(NULL),
212 fvn6thEtaPOI(NULL),
213 fvn8thEtaPOI(NULL),
214
215 // weighted correlations for each (pt,eta) bin for POIs:
216 f2pPtEtaPOIW(NULL),
217 f4pPtEtaPOIW(NULL),
218 f6pPtEtaPOIW(NULL),
219 f8pPtEtaPOIW(NULL),
220
221 // weighted final results for differential flow for POIs:
222 // 3D (pt,eta)
223 fvn2ndPtEtaPOIW(NULL),
224 fvn4thPtEtaPOIW(NULL),
225 fvn6thPtEtaPOIW(NULL),
226 fvn8thPtEtaPOIW(NULL),
227 // 2D (pt)
228 fvn2ndPtPOIW(NULL),
229 fvn4thPtPOIW(NULL),
230 fvn6thPtPOIW(NULL),
231 fvn8thPtPOIW(NULL),
232 // 2D (eta)
233 fvn2ndEtaPOIW(NULL),
234 fvn4thEtaPOIW(NULL),
235 fvn6thEtaPOIW(NULL),
236 fvn8thEtaPOIW(NULL),
237
238 // non-weighted correlations for each (pt,eta) bin for RPs:
239 f2pPtEtaRP(NULL),
240 f4pPtEtaRP(NULL),
241 f6pPtEtaRP(NULL),
242 f8pPtEtaRP(NULL),
243
244 // non-weighted final results for differential flow for RPs:
245 // 3D (pt,eta)
246 fvn2ndPtEtaRP(NULL),
247 fvn4thPtEtaRP(NULL),
248 fvn6thPtEtaRP(NULL),
249 fvn8thPtEtaRP(NULL),
250 // 2D (pt)
251 fvn2ndPtRP(NULL),
252 fvn4thPtRP(NULL),
253 fvn6thPtRP(NULL),
254 fvn8thPtRP(NULL),
255 // 2D (eta)
256 fvn2ndEtaRP(NULL),
257 fvn4thEtaRP(NULL),
258 fvn6thEtaRP(NULL),
259 fvn8thEtaRP(NULL),
260
261 // weighted correlations for each (pt,eta) bin for RPs:
262 f2pPtEtaRPW(NULL),
263 f4pPtEtaRPW(NULL),
264 f6pPtEtaRPW(NULL),
265 f8pPtEtaRPW(NULL),
266
267 // weighted final results for differential flow for RPs:
268 // 3D (pt,eta)
269 fvn2ndPtEtaRPW(NULL),
270 fvn4thPtEtaRPW(NULL),
271 fvn6thPtEtaRPW(NULL),
272 fvn8thPtEtaRPW(NULL),
273 // 2D (pt)
274 fvn2ndPtRPW(NULL),
275 fvn4thPtRPW(NULL),
276 fvn6thPtRPW(NULL),
277 fvn8thPtRPW(NULL),
278 // 2D (eta)
279 fvn2ndEtaRPW(NULL),
280 fvn4thEtaRPW(NULL),
281 fvn6thEtaRPW(NULL),
282 fvn8thEtaRPW(NULL)
283 // ...................................................................................................................
284
bc92c0cb 285{
9c1a9547 286 // constructor
ae733b3b 287 fHistList = new TList();
288 fDiffFlowList = new TList();
289 fDiffFlowList->SetName("DifferentialFlow");
03a02aca 290 fWeightsList = new TList();
ae733b3b 291 fWeightsList->SetName("Weights");
9c1a9547 292 fResultsList = new TList();
293 fResultsList->SetName("Results");
03a02aca 294
8842fb2b 295 fnBinsPt = AliFlowCommonConstants::GetNbinsPt();
296 fPtMin = AliFlowCommonConstants::GetPtMin();
297 fPtMax = AliFlowCommonConstants::GetPtMax();
298
1dfa3c16 299 fnBinsEta = AliFlowCommonConstants::GetNbinsEta();
300 fEtaMin = AliFlowCommonConstants::GetEtaMin();
301 fEtaMax = AliFlowCommonConstants::GetEtaMax();
bc92c0cb 302}
303
304AliFlowAnalysisWithQCumulants::~AliFlowAnalysisWithQCumulants()
305{
03a02aca 306 //destructor
bc92c0cb 307 delete fHistList;
ae733b3b 308 delete fDiffFlowList;
309 delete fWeightsList;
9c1a9547 310 delete fResultsList;
bc92c0cb 311}
312
313//================================================================================================================
314
e085f1a9 315void AliFlowAnalysisWithQCumulants::Init()
bc92c0cb 316{
317 //various output histograms
bc92c0cb 318 //avarage multiplicity
1315fe58 319 fAvMultIntFlowQC = new TProfile("fAvMultIntFlowQC","Average Multiplicity",1,0,1,"s");
320 fAvMultIntFlowQC->SetXTitle("");
321 fAvMultIntFlowQC->SetYTitle("");
322 fAvMultIntFlowQC->SetLabelSize(0.06);
323 fAvMultIntFlowQC->SetMarkerStyle(25);
324 fAvMultIntFlowQC->SetLabelOffset(0.01);
325 (fAvMultIntFlowQC->GetXaxis())->SetBinLabel(1,"Average Multiplicity");
326 fHistList->Add(fAvMultIntFlowQC);
bc92c0cb 327
328 //Q-vector stuff
329 fQvectorComponents = new TProfile("fQvectorComponents","Avarage of Q-vector components",44,0.,44.,"s");
330 fQvectorComponents->SetXTitle("");
331 fQvectorComponents->SetYTitle("");
332 //fHistList->Add(fQvectorComponents);
333
bc92c0cb 334 //final results for differential flow from 2nd order Q-cumulant
8842fb2b 335 fDiffFlowResults2ndOrderQC = new TH1D("fDiffFlowResults2ndOrderQC","Differential Flow from 2nd Order Q-cumulant",fnBinsPt,fPtMin,fPtMax);
1315fe58 336 fDiffFlowResults2ndOrderQC->SetXTitle("p_{t} [GeV]");
337 //fDiffFlowResults2ndOrderQC->SetYTitle("Differential Flow");
338 fHistList->Add(fDiffFlowResults2ndOrderQC);
bc92c0cb 339
340 //final results for differential flow from 4th order Q-cumulant
8842fb2b 341 fDiffFlowResults4thOrderQC = new TH1D("fDiffFlowResults4thOrderQC","Differential Flow from 4th Order Q-cumulant",fnBinsPt,fPtMin,fPtMax);
1315fe58 342 fDiffFlowResults4thOrderQC->SetXTitle("p_{t} [GeV]");
343 //fDiffFlowResults4thOrderQC->SetYTitle("Differential Flow");
344 fHistList->Add(fDiffFlowResults4thOrderQC);
345
346 //final results for covariances (1st bin: <2*4>-<2>*<4>, 2nd bin: <2*6>-<2>*<6>, ...)
347 fCovariances = new TH1D("fCovariances","Covariances",6,0,6);
348 //fCovariances->SetXTitle("");
349 //fCovariances->SetYTitle("<covariance>");
350 fCovariances->SetLabelSize(0.04);
351 fCovariances->SetTickLength(1);
352 fCovariances->SetMarkerStyle(25);
353 (fCovariances->GetXaxis())->SetBinLabel(1,"Cov(2,4)");
354 (fCovariances->GetXaxis())->SetBinLabel(2,"Cov(2,6)");
355 (fCovariances->GetXaxis())->SetBinLabel(3,"Cov(2,8)");
356 (fCovariances->GetXaxis())->SetBinLabel(4,"Cov(4,6)");
357 (fCovariances->GetXaxis())->SetBinLabel(5,"Cov(4,8)");
358 (fCovariances->GetXaxis())->SetBinLabel(6,"Cov(6,8)");
359 fHistList->Add(fCovariances);
bc92c0cb 360
e085f1a9 361 //xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
362 // !!!! to be removed !!!!
363 //profile containing the x-components of Q-vectors from all events
364 fQvectorForEachEventX = new TProfile("fQvectorForEachEventX","x-components of Q-vectors",44000,1,44000,"s");
365 fHistList->Add(fQvectorForEachEventX);
366
367 //profile containing the y-components of Q-vectors from all events
368 fQvectorForEachEventY = new TProfile("fQvectorForEachEventY","y-components of Q-vectors",44000,1,44000,"s");
369 fHistList->Add(fQvectorForEachEventY);
370 //xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
371
9c1a9547 372 // multi-particle correlations calculated from Q-vectors
dee1e0e0 373 fQCorrelations = new TProfile("fQCorrelations","multi-particle correlations from Q-vectors",32,0,32,"s");
1315fe58 374 fQCorrelations->SetTickLength(-0.01,"Y");
375 fQCorrelations->SetMarkerStyle(25);
376 fQCorrelations->SetLabelSize(0.03);
377 fQCorrelations->SetLabelOffset(0.01,"Y");
9c1a9547 378 // 2-p:
1315fe58 379 (fQCorrelations->GetXaxis())->SetBinLabel(1,"<<2>>_{n|n}");
380 (fQCorrelations->GetXaxis())->SetBinLabel(2,"<<2>>_{2n|2n}");
381 (fQCorrelations->GetXaxis())->SetBinLabel(3,"<<2>>_{3n|3n}");
382 (fQCorrelations->GetXaxis())->SetBinLabel(4,"<<2>>_{4n|4n}");
9c1a9547 383 // 3-p:
1315fe58 384 (fQCorrelations->GetXaxis())->SetBinLabel(6,"<<3>>_{2n|n,n}");
385 (fQCorrelations->GetXaxis())->SetBinLabel(7,"<<3>>_{3n|2n,n}");
386 (fQCorrelations->GetXaxis())->SetBinLabel(8,"<<3>>_{4n|2n,2n}");
387 (fQCorrelations->GetXaxis())->SetBinLabel(9,"<<3>>_{4n|3n,n}");
9c1a9547 388 // 4-p:
1315fe58 389 (fQCorrelations->GetXaxis())->SetBinLabel(11,"<<4>>_{n,n|n,n}");
390 (fQCorrelations->GetXaxis())->SetBinLabel(12,"<<4>>_{2n,n|2n,n}");
dee1e0e0 391 (fQCorrelations->GetXaxis())->SetBinLabel(13,"<<4>>_{2n,2n|2n,2n}");
392 (fQCorrelations->GetXaxis())->SetBinLabel(14,"<<4>>_{3n|n,n,n}");
393 (fQCorrelations->GetXaxis())->SetBinLabel(15,"<<4>>_{3n,n|3n,n}");
394 (fQCorrelations->GetXaxis())->SetBinLabel(16,"<<4>>_{3n,n|2n,2n}");
395 (fQCorrelations->GetXaxis())->SetBinLabel(17,"<<4>>_{4n|2n,n,n}");
9c1a9547 396 // 5-p:
dee1e0e0 397 (fQCorrelations->GetXaxis())->SetBinLabel(19,"<<5>>_{2n|n,n,n,n}");
398 (fQCorrelations->GetXaxis())->SetBinLabel(20,"<<5>>_{2n,2n|2n,n,n}");
399 (fQCorrelations->GetXaxis())->SetBinLabel(21,"<<5>>_{3n,n|2n,n,n}");
400 (fQCorrelations->GetXaxis())->SetBinLabel(22,"<<5>>_{4n|n,n,n,n}");
9c1a9547 401 // 6-p:
dee1e0e0 402 (fQCorrelations->GetXaxis())->SetBinLabel(24,"<<6>>_{n,n,n|n,n,n}");
403 (fQCorrelations->GetXaxis())->SetBinLabel(25,"<<6>>_{2n,n,n|2n,n,n}");
404 (fQCorrelations->GetXaxis())->SetBinLabel(26,"<<6>>_{2n,2n|n,n,n,n}");
405 (fQCorrelations->GetXaxis())->SetBinLabel(27,"<<6>>_{3n,n|n,n,n,n}");
9c1a9547 406 // 7-p:
dee1e0e0 407 (fQCorrelations->GetXaxis())->SetBinLabel(29,"<<7>>_{2n,n,n|n,n,n,n}");
9c1a9547 408 // 8-p:
dee1e0e0 409 (fQCorrelations->GetXaxis())->SetBinLabel(31,"<<8>>_{n,n,n,n|n,n,n,n}");
9c1a9547 410 // add fQCorrelations to the main list:
bc92c0cb 411 fHistList->Add(fQCorrelations);
412
9c1a9547 413 //.........................................................................
3d824203 414 //weighted multi-particle correlations calculated from Q-vectors
9c1a9547 415 fQCorrelationsW = new TProfile("fQCorrelationsW","weighted multi-particle correlations from Q-vectors",200,0,200,"s");
416 fQCorrelationsW->SetTickLength(-0.01,"Y");
417 fQCorrelationsW->SetMarkerStyle(25);
418 fQCorrelationsW->SetLabelSize(0.03);
419 fQCorrelationsW->SetLabelOffset(0.01,"Y");
420 // 2-p:
421 (fQCorrelationsW->GetXaxis())->SetBinLabel(1,"<w_{1}w_{2}cos(n(#phi_{1}-#phi_{2}))>");
422 (fQCorrelationsW->GetXaxis())->SetBinLabel(2,"<w_{1}^{2}w_{2}^{2}cos(2n(#phi_{1}-#phi_{2}))>");
423 (fQCorrelationsW->GetXaxis())->SetBinLabel(3,"<w_{1}^{3}w_{2}^{3}cos(3n(#phi_{1}-#phi_{2}))>");
424 (fQCorrelationsW->GetXaxis())->SetBinLabel(4,"<w_{1}^{4}w_{2}^{4}cos(4n(#phi_{1}-#phi_{2}))>");
425 (fQCorrelationsW->GetXaxis())->SetBinLabel(5,"<w_{1}^{3}w_{2}cos(n(#phi_{1}-#phi_{2}))>");
426 (fQCorrelationsW->GetXaxis())->SetBinLabel(6,"<w_{1}^{2}w_{2}w_{3}cos(n(#phi_{1}-#phi_{2}))>");
427 // 3-p:
428 (fQCorrelationsW->GetXaxis())->SetBinLabel(21,"<w_{1}w_{2}w_{3}^{2}cos(n(2#phi_{1}-#phi_{2}-#phi_{3}))>");
429 // 4-p:
430 (fQCorrelationsW->GetXaxis())->SetBinLabel(41,"<w_{1}w_{2}w_{3}w_{4}cos(n(#phi_{1}+#phi_{2}-#phi_{3}-#phi_{4}))>");
431 // add fQCorrelationsW to the main list:
432 fHistList->Add(fQCorrelationsW);
433 //.........................................................................
3d824203 434
3d824203 435
8842fb2b 436 //average products
437 fQProduct = new TProfile("fQProduct","average of products",6,0,6,"s");
438 fQProduct->SetTickLength(-0.01,"Y");
439 fQProduct->SetMarkerStyle(25);
440 fQProduct->SetLabelSize(0.03);
441 fQProduct->SetLabelOffset(0.01,"Y");
442 (fQProduct->GetXaxis())->SetBinLabel(1,"<<2*4>>");
443 (fQProduct->GetXaxis())->SetBinLabel(2,"<<2*6>>");
444 (fQProduct->GetXaxis())->SetBinLabel(3,"<<2*8>>");
445 (fQProduct->GetXaxis())->SetBinLabel(4,"<<4*6>>");
446 (fQProduct->GetXaxis())->SetBinLabel(5,"<<4*8>>");
447 (fQProduct->GetXaxis())->SetBinLabel(6,"<<6*8>>");
448 fQProduct->SetXTitle("");
449 fQProduct->SetYTitle("");
450 fHistList->Add(fQProduct);
bc92c0cb 451
9c1a9547 452 // multi-particle correlations calculated with nested loops (needed for int. flow)
453 fDirectCorrelations = new TProfile("fDirectCorrelations","multi-particle correlations with nested loops",100,0,100,"s");
bc92c0cb 454 fDirectCorrelations->SetXTitle("");
455 fDirectCorrelations->SetYTitle("correlations");
456 fHistList->Add(fDirectCorrelations);
457
9c1a9547 458 // multi-particle correlations calculated with nested loops (needed for weighted int. flow)
459 fDirectCorrelationsW = new TProfile("fDirectCorrelationsW","multi-particle correlations with nested loops",200,0,200,"s");
460 fDirectCorrelationsW->SetXTitle("");
461 fDirectCorrelationsW->SetYTitle("correlations");
462 fHistList->Add(fDirectCorrelationsW);
463
464 // multi-particle correlations calculated with nested loops (needed for diff. flow)
465 fDirectCorrelationsDiffFlow = new TProfile("fDirectCorrelationsDiffFlow","multi-particle correlations with nested loops",200,0,200,"s");
466 fDirectCorrelationsDiffFlow->SetXTitle("");
467 fDirectCorrelationsDiffFlow->SetYTitle("correlations");
468 fHistList->Add(fDirectCorrelationsDiffFlow);
469
470 // multi-particle correlations calculated with nested loops (needed for weighted diff. flow)
471 fDirectCorrelationsDiffFlowW = new TProfile("fDirectCorrelationsDiffFlowW","multi-particle correlations with nested loops",200,0,200,"s");
472 fDirectCorrelationsDiffFlowW->SetXTitle("");
473 fDirectCorrelationsDiffFlowW->SetYTitle("correlations");
474 fHistList->Add(fDirectCorrelationsDiffFlowW);
475
1dfa3c16 476 //f2PerPtBin1n1nRP
477 f2PerPtBin1n1nRP = new TProfile("f2PerPtBin1n1nRP","<2'>_{n|n}",fnBinsPt,fPtMin,fPtMax,"s");
478 f2PerPtBin1n1nRP->SetXTitle("p_{t} [GeV]");
ae733b3b 479 fDiffFlowList->Add(f2PerPtBin1n1nRP);
1dfa3c16 480
1dfa3c16 481 //f4PerPtBin1n1n1n1nRP
482 f4PerPtBin1n1n1n1nRP = new TProfile("f4PerPtBin1n1n1n1nRP","<4'>_{n,n|n,n}",fnBinsPt,fPtMin,fPtMax,"s");
483 f4PerPtBin1n1n1n1nRP->SetXTitle("p_{t} [GeV]");
ae733b3b 484 fDiffFlowList->Add(f4PerPtBin1n1n1n1nRP);
1dfa3c16 485
1dfa3c16 486 //f2PerEtaBin1n1nRP
487 f2PerEtaBin1n1nRP = new TProfile("f2PerEtaBin1n1nRP","<2'>_{n|n}",fnBinsEta,fEtaMin,fEtaMax,"s");
488 f2PerEtaBin1n1nRP->SetXTitle("#eta");
ae733b3b 489 fDiffFlowList->Add(f2PerEtaBin1n1nRP);
1dfa3c16 490
1dfa3c16 491 //f4PerEtaBin1n1n1n1nRP
492 f4PerEtaBin1n1n1n1nRP = new TProfile("f4PerEtaBin1n1n1n1nRP","<4'>_{n,n|n,n}",fnBinsEta,fEtaMin,fEtaMax,"s");
493 f4PerEtaBin1n1n1n1nRP->SetXTitle("#eta");
ae733b3b 494 fDiffFlowList->Add(f4PerEtaBin1n1n1n1nRP);
1dfa3c16 495
1dfa3c16 496 //f2PerPtBin1n1nPOI
497 f2PerPtBin1n1nPOI = new TProfile("f2PerPtBin1n1nPOI","<2'>_{n|n}",fnBinsPt,fPtMin,fPtMax,"s");
4057ba99 498 f2PerPtBin1n1nPOI->SetXTitle("#eta");
ae733b3b 499 fDiffFlowList->Add(f2PerPtBin1n1nPOI);
1dfa3c16 500
1dfa3c16 501 //f4PerPtBin1n1n1n1nPOI
502 f4PerPtBin1n1n1n1nPOI = new TProfile("f4PerPtBin1n1n1n1nPOI","<4'>_{n,n|n,n}",fnBinsPt,fPtMin,fPtMax,"s");
503 f4PerPtBin1n1n1n1nPOI->SetXTitle("p_{t} [GeV]");
ae733b3b 504 fDiffFlowList->Add(f4PerPtBin1n1n1n1nPOI);
1dfa3c16 505
1dfa3c16 506 //f2PerEtaBin1n1nPOI
507 f2PerEtaBin1n1nPOI = new TProfile("f2PerEtaBin1n1nPOI","<2'>_{n|n}",fnBinsEta,fEtaMin,fEtaMax,"s");
508 f2PerEtaBin1n1nPOI->SetXTitle("#eta");
ae733b3b 509 fDiffFlowList->Add(f2PerEtaBin1n1nPOI);
1dfa3c16 510
1dfa3c16 511 //f4PerEtaBin1n1n1n1nPOI
512 f4PerEtaBin1n1n1n1nPOI = new TProfile("f4PerEtaBin1n1n1n1nPOI","<4'>_{n,n|n,n}",fnBinsEta,fEtaMin,fEtaMax,"s");
513 f4PerEtaBin1n1n1n1nPOI->SetXTitle("#eta");
ae733b3b 514 fDiffFlowList->Add(f4PerEtaBin1n1n1n1nPOI);
bc92c0cb 515
3d824203 516 //f2WPerPtBin1n1nPOI
517 f2WPerPtBin1n1nPOI = new TProfile("f2WPerPtBin1n1nPOI","<2'>_{n|n}",fnBinsPt,fPtMin,fPtMax,"s");
518 f2WPerPtBin1n1nPOI->SetXTitle("#pt");
519 fDiffFlowList->Add(f2WPerPtBin1n1nPOI);
520
3d824203 521 //f4WPerPtBin1n1n1n1nPOI
522 f4WPerPtBin1n1n1n1nPOI = new TProfile("f4WPerPtBin1n1n1n1nPOI","<4'>_{n,n|n,n}",fnBinsPt,fPtMin,fPtMax,"s");
523 f4WPerPtBin1n1n1n1nPOI->SetXTitle("#Pt");
524 fDiffFlowList->Add(f4WPerPtBin1n1n1n1nPOI);
525
3d824203 526 //f2WPerEtaBin1n1nPOI
527 f2WPerEtaBin1n1nPOI = new TProfile("f2WPerEtaBin1n1nPOI","<2'>_{n|n}",fnBinsEta,fEtaMin,fEtaMax,"s");
528 f2WPerEtaBin1n1nPOI->SetXTitle("#eta");
529 fDiffFlowList->Add(f2WPerEtaBin1n1nPOI);
530
531 //f4WPerEtaBin1n1n1n1nPOI
532 f4WPerEtaBin1n1n1n1nPOI = new TProfile("f4WPerEtaBin1n1n1n1nPOI","<4'>_{n,n|n,n}",fnBinsEta,fEtaMin,fEtaMax,"s");
533 f4WPerEtaBin1n1n1n1nPOI->SetXTitle("#eta");
534 fDiffFlowList->Add(f4WPerEtaBin1n1n1n1nPOI);
535
3d824203 536 //f2WPerPtBin1n1nRP
537 f2WPerPtBin1n1nRP = new TProfile("f2WPerPtBin1n1nRP","<2'>_{n|n}",fnBinsPt,fPtMin,fPtMax,"s");
538 f2WPerPtBin1n1nRP->SetXTitle("#pt");
539 fDiffFlowList->Add(f2WPerPtBin1n1nRP);
540
541 //f4WPerPtBin1n1n1n1nRP
542 f4WPerPtBin1n1n1n1nRP = new TProfile("f4WPerPtBin1n1n1n1nRP","<4'>_{n,n|n,n}",fnBinsPt,fPtMin,fPtMax,"s");
543 f4WPerPtBin1n1n1n1nRP->SetXTitle("#Pt");
544 fDiffFlowList->Add(f4WPerPtBin1n1n1n1nRP);
545
3d824203 546 //f2WPerEtaBin1n1nRP
547 f2WPerEtaBin1n1nRP = new TProfile("f2WPerEtaBin1n1nRP","<2'>_{n|n}",fnBinsEta,fEtaMin,fEtaMax,"s");
548 f2WPerEtaBin1n1nRP->SetXTitle("#eta");
549 fDiffFlowList->Add(f2WPerEtaBin1n1nRP);
550
551 //f4WPerEtaBin1n1n1n1nRP
552 f4WPerEtaBin1n1n1n1nRP = new TProfile("f4WPerEtaBin1n1n1n1nRP","<4'>_{n,n|n,n}",fnBinsEta,fEtaMin,fEtaMax,"s");
553 f4WPerEtaBin1n1n1n1nRP->SetXTitle("#eta");
554 fDiffFlowList->Add(f4WPerEtaBin1n1n1n1nRP);
555
cb308e83 556 //common control histogram (2nd order)
557 fCommonHists2nd = new AliFlowCommonHist("AliFlowCommonHist2ndOrderQC");
558 fHistList->Add(fCommonHists2nd);
1315fe58 559
cb308e83 560 //common control histogram (4th order)
561 fCommonHists4th = new AliFlowCommonHist("AliFlowCommonHist4thOrderQC");
562 fHistList->Add(fCommonHists4th);
563
564 //common control histogram (6th order)
565 fCommonHists6th = new AliFlowCommonHist("AliFlowCommonHist6thOrderQC");
566 fHistList->Add(fCommonHists6th);
567
568 //common control histogram (8th order)
569 fCommonHists8th = new AliFlowCommonHist("AliFlowCommonHist8thOrderQC");
570 fHistList->Add(fCommonHists8th);
4057ba99 571
8842fb2b 572 //common histograms for final results (2nd order)
1315fe58 573 fCommonHistsResults2nd = new AliFlowCommonHistResults("AliFlowCommonHistResults2ndOrderQC");
574 fHistList->Add(fCommonHistsResults2nd);
575
8842fb2b 576 //common histograms for final results (4th order)
1315fe58 577 fCommonHistsResults4th = new AliFlowCommonHistResults("AliFlowCommonHistResults4thOrderQC");
578 fHistList->Add(fCommonHistsResults4th);
579
8842fb2b 580 //common histograms for final results (6th order)
1315fe58 581 fCommonHistsResults6th = new AliFlowCommonHistResults("AliFlowCommonHistResults6thOrderQC");
582 fHistList->Add(fCommonHistsResults6th);
583
8842fb2b 584 //common histograms for final results (8th order)
1315fe58 585 fCommonHistsResults8th = new AliFlowCommonHistResults("AliFlowCommonHistResults8thOrderQC");
586 fHistList->Add(fCommonHistsResults8th);
1315fe58 587
588 //weighted <2>_{n|n} distribution
52021ae2 589 f2pDistribution = new TH1D("f2pDistribution","<2>_{n|n} distribution",100000,-0.02,0.1);
590 f2pDistribution->SetXTitle("<2>_{n|n}");
591 f2pDistribution->SetYTitle("Counts");
592 fHistList->Add(f2pDistribution);
1315fe58 593
594 //weighted <4>_{n,n|n,n} distribution
52021ae2 595 f4pDistribution = new TH1D("f4pDistribution","<4>_{n,n|n,n} distribution",100000,-0.00025,0.002);
596 f4pDistribution->SetXTitle("<4>_{n,n|n,n}");
597 f4pDistribution->SetYTitle("Counts");
598 fHistList->Add(f4pDistribution);
1315fe58 599
600 //weighted <6>_{n,n,n|n,n,n} distribution
52021ae2 601 f6pDistribution = new TH1D("f6pDistribution","<6>_{n,n,n|n,n,n} distribution",100000,-0.000005,0.000025);
602 f6pDistribution->SetXTitle("<6>_{n,n,n|n,n,n}");
603 f6pDistribution->SetYTitle("Counts");
604 fHistList->Add(f6pDistribution);
bc92c0cb 605
5e838eeb 606 //weighted <8>_{n,n,n,n|n,n,n,n} distribution
607 f8pDistribution = new TH1D("f8pDistribution","<8>_{n,n,n,n|n,n,n,n} distribution",100000,-0.000000001,0.00000001);
608 f8pDistribution->SetXTitle("<8>_{n,n,n,n|n,n,n,n}");
609 f8pDistribution->SetYTitle("Counts");
610 fHistList->Add(f8pDistribution);
ae733b3b 611
ae733b3b 612
03a02aca 613
ae733b3b 614
bc92c0cb 615
ae733b3b 616
ae733b3b 617
ae733b3b 618
9c1a9547 619 // .......................................................................................................................................
620 // Q_{n,k} and S^M_{n,k}:
621 fReQ = new TMatrixD(4,9);
622 fImQ = new TMatrixD(4,9);
623 fSMpk = new TMatrixD(8,9);
ae733b3b 624
9c1a9547 625 // q'_{n}:
626 fReqnPtEta = new TH2D("fReqnPtEta","Re[q_{n}(p_{t},#eta)]",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
627 fImqnPtEta = new TH2D("fImqnPtEta","Im[q_{n}(p_{t},#eta)]",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
628 fmPtEta = new TH2D("fmPtEta","m(p_{t},#eta)",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
bc92c0cb 629
9c1a9547 630 // non-weighted q''_{n} and q''_{2n}:
631 fReqPrimePrime1nPtEta = new TH2D("fReqPrimePrime1nPtEta","Re[q''_{n}(p_{t},#eta)]",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
632 fImqPrimePrime1nPtEta = new TH2D("fImqPrimePrime1nPtEta","Im[q''_{n}(p_{t},#eta)]",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
633 fReqPrimePrime2nPtEta = new TH2D("fReqPrimePrime2nPtEta","Re[q''_{2n}(p_{t},#eta)]",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
634 fImqPrimePrime2nPtEta = new TH2D("fImqPrimePrime2nPtEta","Im[q''_{2n}(p_{t},#eta)]",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
635
636 // weighted q''_{n,2k} and q''_{2n,k}:
637 fReqPrimePrime1n2kPtEta = new TH2D("fReqPrimePrime1n2kPtEta","Re[q''_{n,2}(p_{t},#eta)]",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
638 fImqPrimePrime1n2kPtEta = new TH2D("fImqPrimePrime1n2kPtEta","Im[q''_{n,2}(p_{t},#eta)]",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
639 fReqPrimePrime2n1kPtEta = new TH2D("fReqPrimePrime2n1kPtEta","Re[q''_{2n,1(p_{t},#eta)}]",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
640 fImqPrimePrime2n1kPtEta = new TH2D("fImqPrimePrime2n1kPtEta","Im[q''_{2n,1}(p_{t},#eta)]",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
1dfa3c16 641
9c1a9547 642 // m'':
643 fmPrimePrimePtEta = new TH2D("fmPrimePrimePtEta","m''(p_{t},#eta)",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
bc92c0cb 644
9c1a9547 645 // S^{m''}_{p,k}:
646 fSmPrimePrime1p1kPtEta = new TH2D("fSmPrimePrime1p1kPtEta","S^{m''}_{1,1}(p_{t},#eta)",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
647 fSmPrimePrime1p2kPtEta = new TH2D("fSmPrimePrime1p2kPtEta","S^{m''}_{1,2}(p_{t},#eta)",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
648 fSmPrimePrime1p3kPtEta = new TH2D("fSmPrimePrime1p3kPtEta","S^{m''}_{1,3}(p_{t},#eta)",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
649
650 // non-weighted q_RP{n} and q_RP{2n}:
651 fReqRP1nPtEta = new TH2D("fReqRP1nPtEta","Re[q_{n}(p_{t},#eta)] for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
652 fImqRP1nPtEta = new TH2D("fImqRP1nPtEta","Im[q_{n}(p_{t},#eta)] for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
653 fReqRP2nPtEta = new TH2D("fReqRP2nPtEta","Re[q_{2n}(p_{t},#eta)] for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
654 fImqRP2nPtEta = new TH2D("fImqRP2nPtEta","Im[q_{2n}(p_{t},#eta)] for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
bc92c0cb 655
9c1a9547 656 // weighted q_RP{n,2k} and q_RP{2n,k}:
657 fReqRP1n2kPtEta = new TH2D("fReqRP1n2kPtEta","Re[q_{n,2}(p_{t},#eta)] for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
658 fImqRP1n2kPtEta = new TH2D("fImqRP1n2kPtEta","Im[q_{n,2}(p_{t},#eta)] for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
659 fReqRP2n1kPtEta = new TH2D("fReqRP2n1kPtEta","Re[q_{2n,1(p_{t},#eta)}] for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
660 fImqRP2n1kPtEta = new TH2D("fImqRP2n1kPtEta","Im[q_{2n,1}(p_{t},#eta)] for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
cb308e83 661
9c1a9547 662 // mRP:
663 fmRPPtEta = new TH2D("fmRPPtEta","m(p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
dee1e0e0 664
9c1a9547 665 // S^{mRP}_{p,k}:
666 fSmRP1p1kPtEta = new TH2D("fSmRP1p1kPtEta","S^{m}_{1,1}(p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
667 fSmRP1p2kPtEta = new TH2D("fSmRP1p2kPtEta","S^{m}_{1,2}(p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
668 fSmRP1p3kPtEta = new TH2D("fSmRP1p3kPtEta","S^{m}_{1,3}(p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
dee1e0e0 669
9c1a9547 670 // ----- RESULTS ----
dee1e0e0 671
9c1a9547 672 // final results for non-weighted no-name integrated flow:
673 fIntFlowResultsQC = new TH1D("fIntFlowResultsQC","Integrated Flow from Q-cumulants",4,0,4);
674 fIntFlowResultsQC->SetLabelSize(0.06);
675 fIntFlowResultsQC->SetMarkerStyle(25);
676 (fIntFlowResultsQC->GetXaxis())->SetBinLabel(1,"v_{n}{2}");
677 (fIntFlowResultsQC->GetXaxis())->SetBinLabel(2,"v_{n}{4}");
678 (fIntFlowResultsQC->GetXaxis())->SetBinLabel(3,"v_{n}{6}");
679 (fIntFlowResultsQC->GetXaxis())->SetBinLabel(4,"v_{n}{8}");
680 fResultsList->Add(fIntFlowResultsQC);
681
682 // final results for non-weighted POIs integrated flow:
683 fIntFlowResultsPOIQC = new TH1D("fIntFlowResultsPOIQC","Integrated Flow (POI) from Q-cumulants",4,0,4);
684 fIntFlowResultsPOIQC->SetLabelSize(0.06);
685 fIntFlowResultsPOIQC->SetMarkerStyle(25);
686 (fIntFlowResultsPOIQC->GetXaxis())->SetBinLabel(1,"v_{n}{2}");
687 (fIntFlowResultsPOIQC->GetXaxis())->SetBinLabel(2,"v_{n}{4}");
688 (fIntFlowResultsPOIQC->GetXaxis())->SetBinLabel(3,"v_{n}{6}");
689 (fIntFlowResultsPOIQC->GetXaxis())->SetBinLabel(4,"v_{n}{8}");
690 fResultsList->Add(fIntFlowResultsPOIQC);
691
692 // final results for non-weighted RPs integrated flow:
693 fIntFlowResultsRPQC = new TH1D("fIntFlowResultsRPQC","Integrated Flow (RP) from Q-cumulants",4,0,4);
694 fIntFlowResultsRPQC->SetLabelSize(0.06);
695 fIntFlowResultsRPQC->SetMarkerStyle(25);
696 (fIntFlowResultsRPQC->GetXaxis())->SetBinLabel(1,"v_{n}{2}");
697 (fIntFlowResultsRPQC->GetXaxis())->SetBinLabel(2,"v_{n}{4}");
698 (fIntFlowResultsRPQC->GetXaxis())->SetBinLabel(3,"v_{n}{6}");
699 (fIntFlowResultsRPQC->GetXaxis())->SetBinLabel(4,"v_{n}{8}");
700 fResultsList->Add(fIntFlowResultsRPQC);
701
702 // final results for weighted no-name integrated flow:
703 fIntFlowResultsQCW = new TH1D("fIntFlowResultsQCW","Integrated Flow from Q-cumulants with Weights",4,0,4);
704 fIntFlowResultsQCW->SetLabelSize(0.06);
705 fIntFlowResultsQCW->SetMarkerStyle(25);
706 (fIntFlowResultsQCW->GetXaxis())->SetBinLabel(1,"v_{n}{2}");
707 (fIntFlowResultsQCW->GetXaxis())->SetBinLabel(2,"v_{n}{4}");
708 (fIntFlowResultsQCW->GetXaxis())->SetBinLabel(3,"v_{n}{6}");
709 (fIntFlowResultsQCW->GetXaxis())->SetBinLabel(4,"v_{n}{8}");
710 fResultsList->Add(fIntFlowResultsQCW);
711
712 // final results for weighted POIs integrated flow:
713 fIntFlowResultsPOIQCW = new TH1D("fIntFlowResultsPOIQCW","Integrated Flow (POI) from Q-cumulants with Weights",4,0,4);
714 fIntFlowResultsPOIQCW->SetLabelSize(0.06);
715 fIntFlowResultsPOIQCW->SetMarkerStyle(25);
716 (fIntFlowResultsPOIQCW->GetXaxis())->SetBinLabel(1,"v_{n}{2}");
717 (fIntFlowResultsPOIQCW->GetXaxis())->SetBinLabel(2,"v_{n}{4}");
718 (fIntFlowResultsPOIQCW->GetXaxis())->SetBinLabel(3,"v_{n}{6}");
719 (fIntFlowResultsPOIQCW->GetXaxis())->SetBinLabel(4,"v_{n}{8}");
720 fResultsList->Add(fIntFlowResultsPOIQCW);
721
722 // final results for weighted RPs integrated flow:
723 fIntFlowResultsRPQCW = new TH1D("fIntFlowResultsRPQCW","Integrated Flow (RP) from Q-cumulants with Weights",4,0,4);
724 fIntFlowResultsRPQCW->SetLabelSize(0.06);
725 fIntFlowResultsRPQCW->SetMarkerStyle(25);
726 (fIntFlowResultsRPQCW->GetXaxis())->SetBinLabel(1,"v_{n}{2}");
727 (fIntFlowResultsRPQCW->GetXaxis())->SetBinLabel(2,"v_{n}{4}");
728 (fIntFlowResultsRPQCW->GetXaxis())->SetBinLabel(3,"v_{n}{6}");
729 (fIntFlowResultsRPQCW->GetXaxis())->SetBinLabel(4,"v_{n}{8}");
730 fResultsList->Add(fIntFlowResultsRPQCW);
731
732 // <cos n(psi1-phi2)> for POIs:
733 f2pPtEtaPOI = new TProfile2D("f2pPtEtaPOI","<cos n(#psi_{1}-#phi_{2})> (p_{t},#eta) for POIs",
734 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
735 f2pPtEtaPOI->SetXTitle("p_{t}");
736 f2pPtEtaPOI->SetYTitle("#eta");
737 fDiffFlowList->Add(f2pPtEtaPOI);
738
739 // <cos n(psi1+phi2-phi3-phi4)> for POIs:
740 f4pPtEtaPOI = new TProfile2D("f4pPtEtaPOI","<cos n(#psi_{1}+#phi_{2}-#phi_{3}-#phi_{4})> (p_{t},#eta) for POIs",
741 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
742 f4pPtEtaPOI->SetXTitle("p_{t}");
743 f4pPtEtaPOI->SetYTitle("#eta");
744 fDiffFlowList->Add(f4pPtEtaPOI);
745
746 // <cos n(psi1+phi2+phi3-phi4-phi5-phi6)> for POIs:
747 f6pPtEtaPOI = new TProfile2D("f6pPtEtaPOI","<cos n(#psi_{1}+#phi_{2}+#phi_{3}-#phi_{4}-#phi_{5}-#phi_{6})> (p_{t},#eta) for POIs",
748 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
749 f6pPtEtaPOI->SetXTitle("p_{t}");
750 f6pPtEtaPOI->SetYTitle("#eta");
751 fDiffFlowList->Add(f6pPtEtaPOI);
752
753 // <cos n(psi1+phi2+phi3+phi4-phi5-phi6-phi7-phi8)> for POIs:
754 f8pPtEtaPOI = new TProfile2D("f8pPtEtaPOI","<cos n(#psi_{1}+#phi_{2}+#phi_{3}+#phi_{4}-#phi_{5}-#phi_{6}-#phi_{7}-#phi_{8})> (p_{t},#eta) for POIs",
755 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
756 f8pPtEtaPOI->SetXTitle("p_{t}");
757 f8pPtEtaPOI->SetYTitle("#eta");
758 fDiffFlowList->Add(f8pPtEtaPOI);
759
760 // non-weighted v'_{n}{2,QC} (pt,eta) for POIs
761 fvn2ndPtEtaPOI = new TH2D("fvn2ndPtEtaPOI","v'_{n}{2,QC} (p_{t},#eta) for POIs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
762 fvn2ndPtEtaPOI->SetXTitle("p_{t}");
763 fvn2ndPtEtaPOI->SetYTitle("#eta");
764 fResultsList->Add(fvn2ndPtEtaPOI);
765
766 // non-weighted v'_{n}{4,QC} (pt,eta) for POIs
767 fvn4thPtEtaPOI = new TH2D("fvn4thPtEtaPOI","v'_{n}{4,QC} (p_{t},#eta) for POIs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
768 fvn4thPtEtaPOI->SetXTitle("p_{t}");
769 fvn4thPtEtaPOI->SetYTitle("#eta");
770 fResultsList->Add(fvn4thPtEtaPOI);
771
772 // non-weighted v'_{n}{6,QC} (pt,eta) for POIs
773 fvn6thPtEtaPOI = new TH2D("fvn6thPtEtaPOI","v'_{n}{6,QC} (p_{t},#eta) for POIs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
774 fvn6thPtEtaPOI->SetXTitle("p_{t}");
775 fvn6thPtEtaPOI->SetYTitle("#eta");
776 fResultsList->Add(fvn6thPtEtaPOI);
777
778 // non-weighted v'_{n}{8,QC} (pt,eta) for POIs
779 fvn8thPtEtaPOI = new TH2D("fvn8thPtEtaPOI","v'_{n}{8,QC} (p_{t},#eta) for POIs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
780 fvn8thPtEtaPOI->SetXTitle("p_{t}");
781 fvn8thPtEtaPOI->SetYTitle("#eta");
782 fResultsList->Add(fvn8thPtEtaPOI);
783
784 // non-weighted v'_{n}{2,QC} (pt) for POIs
785 fvn2ndPtPOI = new TH1D("fvn2ndPtPOI","v'_{n}{2,QC} (p_{t}) for POIs",fnBinsPt,fPtMin,fPtMax);
786 fvn2ndPtPOI->SetXTitle("p_{t}");
787 fResultsList->Add(fvn2ndPtPOI);
788
789 // non-weighted v'_{n}{4,QC} (pt) for POIs
790 fvn4thPtPOI = new TH1D("fvn4thPtPOI","v'_{n}{4,QC} (p_{t}) for POIs",fnBinsPt,fPtMin,fPtMax);
791 fvn4thPtPOI->SetXTitle("p_{t}");
792 fvn4thPtPOI->SetYTitle("#eta");
793 fResultsList->Add(fvn4thPtPOI);
794
795 // non-weighted v'_{n}{6,QC} (pt) for POIs
796 fvn6thPtPOI = new TH1D("fvn6thPtPOI","v'_{n}{6,QC} (p_{t}) for POIs",fnBinsPt,fPtMin,fPtMax);
797 fvn6thPtPOI->SetXTitle("p_{t}");
798 fResultsList->Add(fvn6thPtPOI);
799
800 // non-weighted v'_{n}{8,QC} (pt) for POIs
801 fvn8thPtPOI = new TH1D("fvn8thPtPOI","v'_{n}{8,QC} (p_{t}) for POIs",fnBinsPt,fPtMin,fPtMax);
802 fvn8thPtPOI->SetXTitle("p_{t}");
803 fResultsList->Add(fvn8thPtPOI);
804
805 // non-weighted v'_{n}{2,QC} (eta) for POIs
806 fvn2ndEtaPOI = new TH1D("fvn2ndEtaPOI","v'_{n}{2,QC} (#eta) for POIs",fnBinsEta,fEtaMin,fEtaMax);
807 fvn2ndEtaPOI->SetXTitle("#eta");
808 fResultsList->Add(fvn2ndEtaPOI);
809
810 // non-weighted v'_{n}{4,QC} (eta) for POIs
811 fvn4thEtaPOI = new TH1D("fvn4thEtaPOI","v'_{n}{4,QC} (#eta) for POIs",fnBinsEta,fEtaMin,fEtaMax);
812 fvn4thEtaPOI->SetXTitle("#eta");
813 fResultsList->Add(fvn4thEtaPOI);
814
815 // non-weighted v'_{n}{6,QC} (eta) for POIs
816 fvn6thEtaPOI = new TH1D("fvn6thEtaPOI","v'_{n}{6,QC} (#eta) for POIs",fnBinsEta,fEtaMin,fEtaMax);
817 fvn6thEtaPOI->SetXTitle("#eta");
818 fResultsList->Add(fvn6thEtaPOI);
819
820 // non-weighted v'_{n}{8,QC} (eta) for POIs
821 fvn8thEtaPOI = new TH1D("fvn8thEtaPOI","v'_{n}{8,QC} (#eta) for POIs",fnBinsEta,fEtaMin,fEtaMax);
822 fvn8thEtaPOI->SetXTitle("p_{t}");
823 fResultsList->Add(fvn8thEtaPOI);
824
825 // <w2 cos n(psi1-phi2)> for POIs:
826 f2pPtEtaPOIW = new TProfile2D("f2pPtEtaPOIW","<w_{2} cos n(#psi_{1}-#phi_{2})> (p_{t},#eta) for POIs",
827 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
828 f2pPtEtaPOIW->SetXTitle("p_{t}");
829 fDiffFlowList->Add(f2pPtEtaPOIW);
830
831 // <w2 w3 w4 cos n(psi1+phi2-phi3-phi4)> for POIs:
832 f4pPtEtaPOIW = new TProfile2D("f4pPtEtaPOIW","<w_{2}w_{3}w_{4} cos n(#psi_{1}+#phi_{2}-#phi_{3}-#phi_{4})> (p_{t},#eta) for POIs",
833 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
834 f4pPtEtaPOIW->SetXTitle("p_{t}");
835 fDiffFlowList->Add(f4pPtEtaPOIW);
836
837 // <w2 w3 w4 w5 w6 cos n(psi1+phi2+phi3-phi4-phi5-phi6)> for POIs:
838 f6pPtEtaPOIW = new TProfile2D("f6pPtEtaPOIW","<w_{2}w_{3}w_{4}w_{5}w_{6} cos n(#psi_{1}+#phi_{2}+#phi_{3}-#phi_{4}-#phi_{5}-#phi_{6})> (p_{t},#eta) for POIs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
839 f6pPtEtaPOIW->SetXTitle("p_{t}");
840 fDiffFlowList->Add(f6pPtEtaPOIW);
841
842 // <w2 w3 w4 w5 w6 w7 w8 cos n(psi1+phi2+phi3+phi4-phi5-phi6-phi7-phi8)> for POIs:
843 f8pPtEtaPOIW = new TProfile2D("f8pPtEtaPOIW","<w_{2}w_{3}w_{4}w_{5}w_{6}w_{7}w_{8} cos n(#psi_{1}+#phi_{2}+#phi_{3}+#phi_{4}-#phi_{5}-#phi_{6}-#phi_{7}-#phi_{8})> (p_{t},#eta) for POIs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
844 f8pPtEtaPOIW->SetXTitle("p_{t}");
845 f8pPtEtaPOIW->SetYTitle("#eta");
846 fDiffFlowList->Add(f8pPtEtaPOIW);
847
848 // weighted v'_{n}{2,QC} (pt,eta) for POIs
849 fvn2ndPtEtaPOIW = new TH2D("fvn2ndPtEtaPOIW","weighted v'_{n}{2,QC} (p_{t},#eta) for POIs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
850 fvn2ndPtEtaPOIW->SetXTitle("p_{t}");
851 fvn2ndPtEtaPOIW->SetYTitle("#eta");
852 fResultsList->Add(fvn2ndPtEtaPOIW);
853
854 // weighted v'_{n}{4,QC} (pt,eta) for POIs
855 fvn4thPtEtaPOIW = new TH2D("fvn4thPtEtaPOIW","weighted v'_{n}{4,QC} (p_{t},#eta) for POIs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
856 fvn4thPtEtaPOIW->SetXTitle("p_{t}");
857 fvn4thPtEtaPOIW->SetYTitle("#eta");
858 fResultsList->Add(fvn4thPtEtaPOIW);
859
860 // weighted v'_{n}{6,QC} (pt,eta) for POIs
861 fvn6thPtEtaPOIW = new TH2D("fvn6thPtEtaPOIW","weighted v'_{n}{6,QC} (p_{t},#eta) for POIs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
862 fvn6thPtEtaPOIW->SetXTitle("p_{t}");
863 fvn6thPtEtaPOIW->SetYTitle("#eta");
864 fResultsList->Add(fvn6thPtEtaPOIW);
865
866 // weighted v'_{n}{8,QC} (pt,eta) for POIs
867 fvn8thPtEtaPOIW = new TH2D("fvn8thPtEtaPOIW","weighted v'_{n}{8,QC} (p_{t},#eta) for POIs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
868 fvn8thPtEtaPOIW->SetXTitle("p_{t}");
869 fvn8thPtEtaPOIW->SetYTitle("#eta");
870 fResultsList->Add(fvn8thPtEtaPOIW);
871
872 // weighted v'_{n}{2,QC} (pt) for POIs
873 fvn2ndPtPOIW = new TH1D("fvn2ndPtPOIW","weighted v'_{n}{2,QC} (p_{t}) for POIs",fnBinsPt,fPtMin,fPtMax);
874 fvn2ndPtPOIW->SetXTitle("p_{t}");
875 fResultsList->Add(fvn2ndPtPOIW);
876
877 // weighted v'_{n}{4,QC} (pt) for POIs
878 fvn4thPtPOIW = new TH1D("fvn4thPtPOIW","weighted v'_{n}{4,QC} (p_{t}) for POIs",fnBinsPt,fPtMin,fPtMax);
879 fvn4thPtPOIW->SetXTitle("p_{t}");
880 fResultsList->Add(fvn4thPtPOIW);
881
882 // weighted v'_{n}{6,QC} (pt) for POIs
883 fvn6thPtPOIW = new TH1D("fvn6thPtPOIW","weighted v'_{n}{6,QC} (p_{t}) for POIs",fnBinsPt,fPtMin,fPtMax);
884 fvn6thPtPOIW->SetXTitle("p_{t}");
885 fResultsList->Add(fvn6thPtPOIW);
886
887 // weighted v'_{n}{8,QC} (pt) for POIs
888 fvn8thPtPOIW = new TH1D("fvn8thPtPOIW","weighted v'_{n}{8,QC} (p_{t}) for POIs",fnBinsPt,fPtMin,fPtMax);
889 fvn8thPtPOIW->SetXTitle("p_{t}");
890 fResultsList->Add(fvn8thPtPOIW);
891
892 // weighted v'_{n}{2,QC} (eta) for POIs
893 fvn2ndEtaPOIW = new TH1D("fvn2ndEtaPOIW","weighted v'_{n}{2,QC} (#eta) for POIs",fnBinsEta,fEtaMin,fEtaMax);
894 fvn2ndEtaPOIW->SetXTitle("#eta");
895 fResultsList->Add(fvn2ndEtaPOIW);
896
897 // weighted v'_{n}{4,QC} (eta) for POIs
898 fvn4thEtaPOIW = new TH1D("fvn4thEtaPOIW","weighted v'_{n}{4,QC} (#eta) for POIs",fnBinsEta,fEtaMin,fEtaMax);
899 fvn4thEtaPOIW->SetXTitle("#eta");
900 fResultsList->Add(fvn4thEtaPOIW);
901
902 // weighted v'_{n}{6,QC} (eta) for POIs
903 fvn6thEtaPOIW = new TH1D("fvn6thEtaPOIW","weighted v'_{n}{6,QC} (#eta) for POIs",fnBinsEta,fEtaMin,fEtaMax);
904 fvn6thEtaPOIW->SetXTitle("#eta");
905 fResultsList->Add(fvn6thEtaPOIW);
906
907 // weighted v'_{n}{8,QC} (eta) for POIs
908 fvn8thEtaPOIW = new TH1D("fvn8thEtaPOIW","weighted v'_{n}{8,QC} (#eta) for POIs",fnBinsEta,fEtaMin,fEtaMax);
909 fvn8thEtaPOIW->SetXTitle("#eta");
910 fResultsList->Add(fvn8thEtaPOIW);
911
912 // <cos n(psi1-phi2)> for RPs:
913 f2pPtEtaRP = new TProfile2D("f2pPtEtaRP","<cos n(#psi_{1}-#phi_{2})> (p_{t},#eta) for RPs",
914 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
915 f2pPtEtaRP->SetXTitle("p_{t}");
916 f2pPtEtaRP->SetYTitle("#eta");
917 fDiffFlowList->Add(f2pPtEtaRP);
918
919 // <cos n(psi1+phi2-phi3-phi4)> for RPs:
920 f4pPtEtaRP = new TProfile2D("f4pPtEtaRP","<cos n(#psi_{1}+#phi_{2}-#phi_{3}-#phi_{4})> (p_{t},#eta) for RPs",
921 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
922 f4pPtEtaRP->SetXTitle("p_{t}");
923 f4pPtEtaRP->SetYTitle("#eta");
924 fDiffFlowList->Add(f4pPtEtaRP);
925
926 // <cos n(psi1+phi2+phi3-phi4-phi5-phi6)> for RPs:
927 f6pPtEtaRP = new TProfile2D("f6pPtEtaRP","<cos n(#psi_{1}+#phi_{2}+#phi_{3}-#phi_{4}-#phi_{5}-#phi_{6})> (p_{t},#eta) for RPs",
928 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
929 f6pPtEtaRP->SetXTitle("p_{t}");
930 f6pPtEtaRP->SetYTitle("#eta");
931 fDiffFlowList->Add(f6pPtEtaRP);
932
933 // <cos n(psi1+phi2+phi3+phi4-phi5-phi6-phi7-phi8)> for RPs:
934 f8pPtEtaRP = new TProfile2D("f8pPtEtaRP","<cos n(#psi_{1}+#phi_{2}+#phi_{3}+#phi_{4}-#phi_{5}-#phi_{6}-#phi_{7}-#phi_{8})> (p_{t},#eta) for RPs",
935 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
936 f8pPtEtaRP->SetXTitle("p_{t}");
937 f8pPtEtaRP->SetYTitle("#eta");
938 fDiffFlowList->Add(f8pPtEtaRP);
939
940 // non-weighted v'_{n}{2,QC} (pt,eta) for RPs
941 fvn2ndPtEtaRP = new TH2D("fvn2ndPtEtaRP","v'_{n}{2,QC} (p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
942 fvn2ndPtEtaRP->SetXTitle("p_{t}");
943 fvn2ndPtEtaRP->SetYTitle("#eta");
944 fResultsList->Add(fvn2ndPtEtaRP);
945
946 // non-weighted v'_{n}{4,QC} (pt,eta) for RPs
947 fvn4thPtEtaRP = new TH2D("fvn4thPtEtaRP","v'_{n}{4,QC} (p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
948 fvn4thPtEtaRP->SetXTitle("p_{t}");
949 fvn4thPtEtaRP->SetYTitle("#eta");
950 fResultsList->Add(fvn4thPtEtaRP);
951
952 // non-weighted v'_{n}{6,QC} (pt,eta) for RPs
953 fvn6thPtEtaRP = new TH2D("fvn6thPtEtaRP","v'_{n}{6,QC} (p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
954 fvn6thPtEtaRP->SetXTitle("p_{t}");
955 fvn6thPtEtaRP->SetYTitle("#eta");
956 fResultsList->Add(fvn6thPtEtaRP);
957
958 // non-weighted v'_{n}{8,QC} (pt,eta) for RPs
959 fvn8thPtEtaRP = new TH2D("fvn8thPtEtaRP","v'_{n}{8,QC} (p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
960 fvn8thPtEtaRP->SetXTitle("p_{t}");
961 fvn8thPtEtaRP->SetYTitle("#eta");
962 fResultsList->Add(fvn8thPtEtaRP);
963
964 // non-weighted v'_{n}{2,QC} (pt) for RPs
965 fvn2ndPtRP = new TH1D("fvn2ndPtRP","v'_{n}{2,QC} (p_{t}) for RPs",fnBinsPt,fPtMin,fPtMax);
966 fvn2ndPtRP->SetXTitle("p_{t}");
967 fResultsList->Add(fvn2ndPtRP);
968
969 // non-weighted v'_{n}{4,QC} (pt) for RPs
970 fvn4thPtRP = new TH1D("fvn4thPtRP","v'_{n}{4,QC} (p_{t}) for RPs",fnBinsPt,fPtMin,fPtMax);
971 fvn4thPtRP->SetXTitle("p_{t}");
972 fResultsList->Add(fvn4thPtRP);
973
974 // non-weighted v'_{n}{6,QC} (pt) for RPs
975 fvn6thPtRP = new TH1D("fvn6thPtRP","v'_{n}{6,QC} (p_{t}) for RPs",fnBinsPt,fPtMin,fPtMax);
976 fvn6thPtRP->SetXTitle("p_{t}");
977 fResultsList->Add(fvn6thPtRP);
978
979 // non-weighted v'_{n}{8,QC} (pt) for RPs
980 fvn8thPtRP = new TH1D("fvn8thPtRP","v'_{n}{8,QC} (p_{t}) for RPs",fnBinsPt,fPtMin,fPtMax);
981 fvn8thPtRP->SetXTitle("p_{t}");
982 fResultsList->Add(fvn8thPtRP);
983
984 // non-weighted v'_{n}{2,QC} (eta) for RPs
985 fvn2ndEtaRP = new TH1D("fvn2ndEtaRP","v'_{n}{2,QC} (#eta) for RPs",fnBinsEta,fEtaMin,fEtaMax);
986 fvn2ndEtaRP->SetXTitle("#eta");
987 fResultsList->Add(fvn2ndEtaRP);
988
989 // non-weighted v'_{n}{4,QC} (eta) for RPs
990 fvn4thEtaRP = new TH1D("fvn4thEtaRP","v'_{n}{4,QC} (#eta) for RPs",fnBinsEta,fEtaMin,fEtaMax);
991 fvn4thEtaRP->SetXTitle("#eta");
992 fResultsList->Add(fvn4thEtaRP);
993
994 // non-weighted v'_{n}{6,QC} (eta) for RPs
995 fvn6thEtaRP = new TH1D("fvn6thEtaRP","v'_{n}{6,QC} (#eta) for RPs",fnBinsEta,fEtaMin,fEtaMax);
996 fvn6thEtaRP->SetXTitle("#eta");
997 fResultsList->Add(fvn6thEtaRP);
998
999 // non-weighted v'_{n}{8,QC} (eta) for RPs
1000 fvn8thEtaRP = new TH1D("fvn8thEtaRP","v'_{n}{8,QC} (#eta) for RPs",fnBinsEta,fEtaMin,fEtaMax);
1001 fvn8thEtaRP->SetXTitle("#eta");
1002 fResultsList->Add(fvn8thEtaRP);
1003
1004 // <w2 cos n(psi1-phi2)> for RPs:
1005 f2pPtEtaRPW = new TProfile2D("f2pPtEtaRPW","<w_{2} cos n(#psi_{1}-#phi_{2})> (p_{t},#eta) for RPs",
1006 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
1007 f2pPtEtaRPW->SetXTitle("p_{t}");
1008 f2pPtEtaRPW->SetYTitle("#eta");
1009 fDiffFlowList->Add(f2pPtEtaRPW);
1010
1011 // <w2 w3 w4 cos n(psi1+phi2-phi3-phi4)> for RPs:
1012 f4pPtEtaRPW = new TProfile2D("f4pPtEtaRPW","<w_{2}w_{3}w_{4} cos n(#psi_{1}+#phi_{2}-#phi_{3}-#phi_{4})> (p_{t},#eta) for RPs",
1013 fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
1014 f4pPtEtaRPW->SetXTitle("p_{t}");
1015 f4pPtEtaRPW->SetYTitle("#eta");
1016 fDiffFlowList->Add(f4pPtEtaRPW);
1017
1018 // <w2 w3 w4 w5 w6 cos n(psi1+phi2+phi3-phi4-phi5-phi6)> for RPs:
1019 f6pPtEtaRPW = new TProfile2D("f6pPtEtaRPW","<w_{2}w_{3}w_{4}w_{5}w_{6} cos n(#psi_{1}+#phi_{2}+#phi_{3}-#phi_{4}-#phi_{5}-#phi_{6})> (p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
1020 f6pPtEtaRPW->SetXTitle("p_{t}");
1021 f6pPtEtaRPW->SetYTitle("#eta");
1022 fDiffFlowList->Add(f6pPtEtaRPW);
1023
1024 // <w2 w3 w4 w5 w6 w7 w8 cos n(psi1+phi2+phi3+phi4-phi5-phi6-phi7-phi8)> for RPs:
1025 f8pPtEtaRPW = new TProfile2D("f8pPtEtaRPW","<w_{2}w_{3}w_{4}w_{5}w_{6}w_{7}w_{8} cos n(#psi_{1}+#phi_{2}+#phi_{3}+#phi_{4}-#phi_{5}-#phi_{6}-#phi_{7}-#phi_{8})> (p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax,"s");
1026 f8pPtEtaRPW->SetXTitle("p_{t}");
1027 f8pPtEtaRPW->SetYTitle("#eta");
1028 fDiffFlowList->Add(f8pPtEtaRPW);
1029
1030 // weighted v'_{n}{2,QC} (pt,eta) for RPs
1031 fvn2ndPtEtaRPW = new TH2D("fvn2ndPtEtaRPW","weighted v'_{n}{2,QC} (p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
1032 fvn2ndPtEtaRPW->SetXTitle("p_{t}");
1033 fvn2ndPtEtaRPW->SetYTitle("#eta");
1034 fResultsList->Add(fvn2ndPtEtaRPW);
1035
1036 // weighted v'_{n}{4,QC} (pt,eta) for RPs
1037 fvn4thPtEtaRPW = new TH2D("fvn4thPtEtaRPW","weighted v'_{n}{4,QC} (p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
1038 fvn4thPtEtaRPW->SetXTitle("p_{t}");
1039 fvn4thPtEtaRPW->SetYTitle("#eta");
1040 fResultsList->Add(fvn4thPtEtaRPW);
1041
1042 // weighted v'_{n}{6,QC} (pt,eta) for RPs
1043 fvn6thPtEtaRPW = new TH2D("fvn6thPtEtaRPW","weighted v'_{n}{6,QC} (p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
1044 fvn6thPtEtaRPW->SetXTitle("p_{t}");
1045 fvn6thPtEtaRPW->SetYTitle("#eta");
1046 fResultsList->Add(fvn6thPtEtaRPW);
1047
1048 // weighted v'_{n}{8,QC} (pt,eta) for RPs
1049 fvn8thPtEtaRPW = new TH2D("fvn8thPtEtaRPW","weighted v'_{n}{8,QC} (p_{t},#eta) for RPs",fnBinsPt,fPtMin,fPtMax,fnBinsEta,fEtaMin,fEtaMax);
1050 fvn8thPtEtaRPW->SetXTitle("p_{t}");
1051 fvn8thPtEtaRPW->SetYTitle("#eta");
1052 fResultsList->Add(fvn8thPtEtaRPW);
1053
1054 // weighted v'_{n}{2,QC} (pt) for RPs
1055 fvn2ndPtRPW = new TH1D("fvn2ndPtRPW","weighted v'_{n}{2,QC} (p_{t}) for RPs",fnBinsPt,fPtMin,fPtMax);
1056 fvn2ndPtRPW->SetXTitle("p_{t}");
1057 fResultsList->Add(fvn2ndPtRPW);
1058
1059 // weighted v'_{n}{4,QC} (pt) for RPs
1060 fvn4thPtRPW = new TH1D("fvn4thPtRPW","weighted v'_{n}{4,QC} (p_{t}) for RPs",fnBinsPt,fPtMin,fPtMax);
1061 fvn4thPtRPW->SetXTitle("p_{t}");
1062 fResultsList->Add(fvn4thPtRPW);
1063
1064 // weighted v'_{n}{6,QC} (pt) for RPs
1065 fvn6thPtRPW = new TH1D("fvn6thPtRPW","weighted v'_{n}{6,QC} (p_{t}) for RPs",fnBinsPt,fPtMin,fPtMax);
1066 fvn6thPtRPW->SetXTitle("p_{t}");
1067 fResultsList->Add(fvn6thPtRPW);
1068
1069 // weighted v'_{n}{8,QC} (pt) for RPs
1070 fvn8thPtRPW = new TH1D("fvn8thPtRPW","weighted v'_{n}{8,QC} (p_{t}) for RPs",fnBinsPt,fPtMin,fPtMax);
1071 fvn8thPtRPW->SetXTitle("p_{t}");
1072 fResultsList->Add(fvn8thPtRPW);
1073
1074 // weighted v'_{n}{2,QC} (eta) for RPs
1075 fvn2ndEtaRPW = new TH1D("fvn2ndEtaRPW","weighted v'_{n}{2,QC} (#eta) for RPs",fnBinsEta,fEtaMin,fEtaMax);
1076 fvn2ndEtaRPW->SetXTitle("#eta");
1077 fResultsList->Add(fvn2ndEtaRPW);
1078
1079 // weighted v'_{n}{4,QC} (eta) for RPs
1080 fvn4thEtaRPW = new TH1D("fvn4thEtaRPW","weighted v'_{n}{4,QC} (#eta) for RPs",fnBinsEta,fEtaMin,fEtaMax);
1081 fvn4thEtaRPW->SetXTitle("#eta");
1082 fResultsList->Add(fvn4thEtaRPW);
1083
1084 // weighted v'_{n}{6,QC} (eta) for RPs
1085 fvn6thEtaRPW = new TH1D("fvn6thEtaRPW","weighted v'_{n}{6,QC} (#eta) for RPs",fnBinsEta,fEtaMin,fEtaMax);
1086 fvn6thEtaRPW->SetXTitle("#eta");
1087 fResultsList->Add(fvn6thEtaRPW);
1088
1089 // weighted v'_{n}{8,QC} (eta) for RPs
1090 fvn8thEtaRP = new TH1D("fvn8thEtaEtaRP","weighted v'_{n}{8,QC} (#eta) for RPs",fnBinsEta,fEtaMin,fEtaMax);
1091 fvn8thEtaRP->SetXTitle("#eta");
1092 fResultsList->Add(fvn8thEtaRP);
1093 // .....................................................................................................................................
1094
1095
1096
1097
1098 // add fUseWeightsBits to the main list (to be improved)
1099 fUseWeightsBits = new TBits(1);
1100 fHistList->Add(fUseWeightsBits);
1101
1102 // add list fWeightsList with weights to the main list
1103 fHistList->Add(fWeightsList);
dee1e0e0 1104
9c1a9547 1105 // add list fDiffFlowList with histograms and profiles needed for differential flow to the main list
1106 fHistList->Add(fDiffFlowList);
5e838eeb 1107
9c1a9547 1108 // add list fResultsList with final results to the main list
1109 fHistList->Add(fResultsList);
3c16adde 1110
9c1a9547 1111
1112}//end of Init()
3d824203 1113
9c1a9547 1114
1115//================================================================================================================
1116
1117
1118void AliFlowAnalysisWithQCumulants::Make(AliFlowEventSimple* anEvent)
1119{
1120 // running over data only in this method
1121
1122
1123
1124
1125 // *********************************************
1126 // **** ACCESS THE OUTPUT FILE WITH WEIGHTS ****
1127 // *********************************************
1128
1129 fUseWeights = fUsePhiWeights||fUsePtWeights||fUseEtaWeights;
1130 fUseWeightsBits->SetBitNumber(1,fUseWeights); // to be improved (how to pass boolean to Finish()?)
1131
3d824203 1132 TH1F *phiWeights = NULL; // histogram with phi weights
1133 TH1D *ptWeights = NULL; // histogram with pt weights
1134 TH1D *etaWeights = NULL; // histogram with eta weights
1135
9c1a9547 1136 if(fUseWeights)
3d824203 1137 {
1138 if(!fWeightsList)
1315fe58 1139 {
9c1a9547 1140 cout<<" WARNING: fWeightsList is NULL pointer in AFAWQC::Make(). "<<endl;
3d824203 1141 exit(0);
1142 }
1143 if(fUsePhiWeights)
1144 {
1145 phiWeights = dynamic_cast<TH1F *>(fWeightsList->FindObject("phi_weights"));
1146 if(!phiWeights)
ae733b3b 1147 {
9c1a9547 1148 cout<<" WARNING: couldn't access the histogram with phi weights in AFAWQC::Make(). "<<endl;
3d824203 1149 exit(0);
ae733b3b 1150 }
3d824203 1151 }
1152 if(fUsePtWeights)
1153 {
1154 ptWeights = dynamic_cast<TH1D *>(fWeightsList->FindObject("pt_weights"));
1155 if(!ptWeights)
1156 {
9c1a9547 1157 cout<<" WARNING: couldn't access the histogram with pt weights in AFAWQC::Make(). "<<endl;
3d824203 1158 exit(0);
1159 }
1160 }
1161 if(fUseEtaWeights)
1162 {
1163 etaWeights = dynamic_cast<TH1D *>(fWeightsList->FindObject("eta_weights"));
1164 if(!etaWeights)
1165 {
9c1a9547 1166 cout<<" WARNING: couldn't access the histogram with eta weights in AFAWQC::Make(). "<<endl;
3d824203 1167 exit(0);
1168 }
1169 }
1170 }
1171
77515452 1172 Int_t nBinsPhi = 0;
9c1a9547 1173 Double_t dBinWidthPt = 0.;
1174 Double_t dBinWidthEta = 0.;
1175
77515452 1176 if(fnBinsPt)
1177 {
1178 dBinWidthPt=(fPtMax-fPtMin)/fnBinsPt;
1179 }
9c1a9547 1180
77515452 1181 if(fnBinsEta)
1182 {
1183 dBinWidthEta=(fEtaMax-fEtaMin)/fnBinsEta;
1184 }
3d824203 1185
1186 if(fWeightsList)
9c1a9547 1187 {
1188 if(fUsePhiWeights)
3d824203 1189 {
9c1a9547 1190 if(phiWeights) nBinsPhi = phiWeights->GetNbinsX();
1191 }
1192 if(fUsePtWeights)
1193 {
1194 if(ptWeights)
3d824203 1195 {
9c1a9547 1196 Double_t dBinWidthPtW = ptWeights->GetBinWidth(1); // assuming that all bins have the same width
1197 if(dBinWidthPtW != dBinWidthPt)
3d824203 1198 {
9c1a9547 1199 cout<<" WARNING: dBinWidthPtW != dBinWidthPt in AFAWQC::Make()."<<endl;
1200 exit(0);
1201 }
1202 Double_t dPtMinW = (ptWeights->GetXaxis())->GetXmin();
1203 if(dPtMinW != fPtMin)
1204 {
1205 cout<<" WARNING: dPtMinW != fPtMin in AFAWQC::Make()."<<endl;
1206 exit(0);
1207 }
1208 }
1209 }
1210 if(fUseEtaWeights)
1211 {
1212 if(etaWeights)
3d824203 1213 {
9c1a9547 1214 Double_t dBinWidthEtaW = etaWeights->GetBinWidth(1); // assuming that all bins have the same width
1215 if(dBinWidthEtaW != dBinWidthEta)
3d824203 1216 {
9c1a9547 1217 cout<<" WARNING: dBinWidthEtaW != dBinWidthEta in AFAWQC::Make()."<<endl;
1218 exit(0);
1219 }
1220 Double_t dEtaMinW = (etaWeights->GetXaxis())->GetXmin();
1221 if(dEtaMinW != fEtaMin)
1222 {
1223 cout<<" WARNING: dEtaMinW != fEtaMin in AFAWQC::Make()."<<endl;
1224 exit(0);
1225 }
1226 }
1227 }
1228 } // end of if(weightsList)
3d824203 1229
9c1a9547 1230 Double_t dPhi = 0.; // azumithal angle in the laboratory frame
1231 Double_t dPt = 0.; // transverse momentum
1232 Double_t dEta = 0.; // pseudorapidity
1233
3d824203 1234 Double_t wPhi = 1.; // phi weight
1235 Double_t wPt = 1.; // pt weight
1236 Double_t wEta = 1.; // eta weight
1237
9c1a9547 1238
1239
1240
1241 // ********************************************
1242 // **** FILL THE COMMON CONTROL HISTOGRAMS ****
1243 // ********************************************
1244
1245 Int_t nRP = anEvent->GetEventNSelTracksRP();
1246 if(nRP>1)
1247 {
1248 fCommonHists2nd->FillControlHistograms(anEvent);
1249 if(nRP>3)
1250 {
1251 fCommonHists4th->FillControlHistograms(anEvent);
1252 if(nRP>5)
3d824203 1253 {
9c1a9547 1254 fCommonHists6th->FillControlHistograms(anEvent);
1255 if(nRP>7)
3d824203 1256 {
9c1a9547 1257 fCommonHists8th->FillControlHistograms(anEvent);
1258 } // end of if(nRP>7)
1259 } // end of if(nRP>5)
1260 } // end of if(nRP>3)
1261 } // end of if(nRP>1)
3d824203 1262
3d824203 1263
3d824203 1264
9c1a9547 1265
1266 // ***************************
1267 // **** LOOPING OVER DATA ****
1268 // ***************************
3d824203 1269
9c1a9547 1270 Int_t nPrim = anEvent->NumberOfTracks();
3d824203 1271
9c1a9547 1272 // nPrim = total number of primary tracks, i.e. nPrim = nRP + nPOI + rest, where:
1273 // nRP = # of particles used to determine the reaction plane;
1274 // nPOI = # of particles of interest for a detailed flow analysis;
1275 // rest = # of particles which are niether RPs not POIs.
3d824203 1276
9c1a9547 1277 for(Int_t i=0;i<nPrim;i++)
3d824203 1278 {
9c1a9547 1279 fTrack=anEvent->GetTrack(i);
77515452 1280 if(fTrack)
1281 {
9c1a9547 1282 if(!(fTrack->InRPSelection() || fTrack->InPOISelection())) continue;
1283
1284 // checking the RP condition:
1285 if(fTrack->InRPSelection())
1286 {
1287 dPhi = fTrack->Phi();
1288 dPt = fTrack->Pt();
1289 dEta = fTrack->Eta();
1290
1291 // determine phi weight for this particle:
1292 if(phiWeights && nBinsPhi)
3d824203 1293 {
9c1a9547 1294 wPhi = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(dPhi*nBinsPhi/TMath::TwoPi())));
1295 }
1296 // determine pt weight for this particle:
1297 if(ptWeights && dBinWidthPt)
1298 {
1299 wPt = ptWeights->GetBinContent(1+(Int_t)(TMath::Floor((dPt-fPtMin)/dBinWidthPt)));
1300 }
1301 // determine eta weight for this particle:
1302 if(etaWeights && dBinWidthEta)
1303 {
1304 wEta = etaWeights->GetBinContent(1+(Int_t)(TMath::Floor((dEta-fEtaMin)/dBinWidthEta)));
1305 }
1306
1307 // fill Re[Q_{n,k}] and Im[Q_{n,k}]:
1308 for(Int_t n=0;n<4;n++)
1309 {
1310 for(Int_t k=0;k<9;k++)
77515452 1311 {
9c1a9547 1312 (*fReQ)(n,k)+=pow(wPhi*wPt*wEta,k)*TMath::Cos(2*(n+1)*dPhi);
1313 (*fImQ)(n,k)+=pow(wPhi*wPt*wEta,k)*TMath::Sin(2*(n+1)*dPhi);
77515452 1314 }
9c1a9547 1315 }
1316
1317 // fill S^{M}_{p,k}:
1318 for(Int_t p=0;p<8;p++)
1319 {
1320 for(Int_t k=0;k<9;k++)
1321 {
1322 (*fSMpk)(p,k)+=pow(wPhi*wPt*wEta,k);
77515452 1323 }
9c1a9547 1324 }
77515452 1325
9c1a9547 1326 Int_t n = 2; // to be improved (add setter for harmonic)
77515452 1327
9c1a9547 1328 // fill non-weighted q_RPs
1329 fReqRP1nPtEta->Fill(dPt,dEta,TMath::Cos(1.*n*dPhi));
1330 fImqRP1nPtEta->Fill(dPt,dEta,TMath::Sin(1.*n*dPhi));
1331 fReqRP2nPtEta->Fill(dPt,dEta,TMath::Cos(2.*n*dPhi));
1332 fImqRP2nPtEta->Fill(dPt,dEta,TMath::Sin(2.*n*dPhi));
77515452 1333
9c1a9547 1334 // mRP:
1335 fmRPPtEta->Fill(dPt,dEta,1);
1336
1337 // fill weighted q_RPs
1338 if(fUseWeights)
3d824203 1339 {
9c1a9547 1340 n = 2; // to be improved (add setter for harmonic)
77515452 1341
9c1a9547 1342 // qRP_{n,k} (weighted qRP):
1343 fReqRP1n2kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,2.)*TMath::Cos(1.*n*dPhi));
1344 fImqRP1n2kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,2.)*TMath::Sin(1.*n*dPhi));
1345 fReqRP2n1kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,1.)*TMath::Cos(2.*n*dPhi));
1346 fImqRP2n1kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,1.)*TMath::Sin(2.*n*dPhi));
3d824203 1347
9c1a9547 1348 // S^{mRP}_{p,k}:
1349 fSmRP1p1kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,1.));
1350 fSmRP1p2kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,2.));
1351 fSmRP1p3kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,3.));
1352 }
1353
1354 // checking if RP particle is also POI particle:
1355 if(fTrack->InPOISelection())
1356 {
1357 n = 2; // to be improved (add setter for harmonic)
1358
1359 // q''_{n} (non-weighted q''):
1360 fReqPrimePrime1nPtEta->Fill(dPt,dEta,TMath::Cos(1.*n*dPhi));
1361 fImqPrimePrime1nPtEta->Fill(dPt,dEta,TMath::Sin(1.*n*dPhi));
1362 fReqPrimePrime2nPtEta->Fill(dPt,dEta,TMath::Cos(2.*n*dPhi));
1363 fImqPrimePrime2nPtEta->Fill(dPt,dEta,TMath::Sin(2.*n*dPhi));
1364
1365 // m'':
1366 fmPrimePrimePtEta->Fill(dPt,dEta,1);
3d824203 1367
9c1a9547 1368 if(fUseWeights)
1369 {
1370 // q''_{n,k} (weighted q''):
1371 fReqPrimePrime1n2kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,2.)*TMath::Cos(1.*n*dPhi));
1372 fImqPrimePrime1n2kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,2.)*TMath::Sin(1.*n*dPhi));
1373 fReqPrimePrime2n1kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,1.)*TMath::Cos(2.*n*dPhi));
1374 fImqPrimePrime2n1kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,1.)*TMath::Sin(2.*n*dPhi));
b7cb54d5 1375
9c1a9547 1376 // S^{m''}_{p,k}:
1377 fSmPrimePrime1p1kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,1.));
1378 fSmPrimePrime1p2kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,2.));
1379 fSmPrimePrime1p3kPtEta->Fill(dPt,dEta,pow(wPhi*wPt*wEta,3.));
1380 }
1381 } // end of if(fTrack->InPOISelection())
1382 } // end of if(pTrack->InRPSelection())
b7cb54d5 1383
9c1a9547 1384 // checking the POI condition:
1385 if(fTrack->InPOISelection())
1386 {
1387 Int_t n = 2; // to be improved (add setter for harmonic)
1388
1389 dPhi = fTrack->Phi();
1390 dPt = fTrack->Pt();
1391 dEta = fTrack->Eta();
b7cb54d5 1392
9c1a9547 1393 // q_n:
1394 fReqnPtEta->Fill(dPt,dEta,TMath::Cos(1.*n*dPhi));
1395 fImqnPtEta->Fill(dPt,dEta,TMath::Sin(1.*n*dPhi));
1396
1397 // m:
1398 fmPtEta->Fill(dPt,dEta,1);
3d824203 1399
9c1a9547 1400 } // end of if(pTrack->InPOISelection() )
1401 } // end of if(fTrack)
1402 else{
1403 cout<<endl;
1404 cout<<" WARNING: no particle! (i.e. fTrack is a NULL pointer in AFAWQC::Make().)"<<endl;
1405 cout<<endl;
1406 }
1407 } // end of for(Int_t i=0;i<nPrim;i++)
3d824203 1408
9c1a9547 1409 // calculate the final expressions for S^{M}_{p,k} = (sum_{i=1}^{M} w_{i}^{k})^{p}:
1410 for(Int_t p=0;p<8;p++)
1411 {
1412 for(Int_t k=0;k<9;k++)
77515452 1413 {
9c1a9547 1414 (*fSMpk)(p,k)=pow((*fSMpk)(p,k),p+1);
1415 }
1416 }
77515452 1417
1418
1419
77515452 1420
9c1a9547 1421 // *****************************
1422 // **** CALLING THE METHODS ****
1423 // *****************************
77515452 1424
9c1a9547 1425 // nested loops (needed for cross-checking the results):
1426 Bool_t evaluateNestedLoopsForIntegratedFlow = kFALSE; // to be improved / removed
1427 Bool_t evaluateNestedLoopsForDifferentialFlow = kFALSE; // to be improved / removed
77515452 1428
9c1a9547 1429 if(evaluateNestedLoopsForIntegratedFlow && nPrim>0 && nPrim<14) // to be improved / removed (eventually I would not need this if())
1430 {
1431 // calculate all correlations needed for 'no-name' integrated flow WITHOUT weights
1432 // (the results are stored in 1D profile fQCorrelations)
1433 if(!(fUseWeights)) this->CalculateCorrelationsForIntegratedFlow();
77515452 1434
9c1a9547 1435 // calculate all correlations needed for 'no-name' integrated flow WITH weights
1436 // (the results are stored in 1D profile fQCorrelationsW)
1437 if(fUseWeights) this->CalculateWeightedCorrelationsForIntegratedFlow();
1438 }
1439 else if (!evaluateNestedLoopsForIntegratedFlow)
1440 {
1441 this->CalculateCorrelationsForIntegratedFlow();
1442 if(fUseWeights) this->CalculateWeightedCorrelationsForIntegratedFlow();
1443 }
77515452 1444
9c1a9547 1445 if(evaluateNestedLoopsForDifferentialFlow && nPrim>0 && nPrim<14 ) // to be improved / removed (eventually I would not need this if())
1446 {
1447 // calculate all correlations needed for differential flow WITHOUT weights
1448 // and store the results in 2D profiles (pt,eta):
1449 // a) POIs: f2pPtEtaPOI, f4pPtEtaPOI, f6pPtEtaPOI and f8pPtEtaPOI;
1450 // b) RPs: f2pPtEtaRP, f4pPtEtaRP, f6pPtEtaRP and f8pPtEtaRP.
1451 if(!(fUseWeights))
77515452 1452 {
9c1a9547 1453 this->CalculateCorrelationsForDifferentialFlow("POI");
1454 this->CalculateCorrelationsForDifferentialFlow("RP");
77515452 1455 }
9c1a9547 1456 // calculate all correlations needed for differential flow WITH weights
1457 // and store the results in 2D profiles (pt,eta):
1458 // a) POIs: f2pPtEtaPOIW, f4pPtEtaPOIW, f6pPtEtaPOIW and f8pPtEtaPOIW;
1459 // b) RPs: f2pPtEtaRPW, f4pPtEtaRPW, f6pPtEtaRPW and f8pPtEtaRPW.
1460 if(fUseWeights)
1461 {
1462 this->CalculateWeightedCorrelationsForDifferentialFlow("POI");
1463 this->CalculateWeightedCorrelationsForDifferentialFlow("RP");
1464 }
1465 }
1466 else if (!evaluateNestedLoopsForDifferentialFlow)
1467 {
1468 this->CalculateCorrelationsForDifferentialFlow("POI");
1469 this->CalculateCorrelationsForDifferentialFlow("RP");
3d824203 1470
9c1a9547 1471 if(fUseWeights)
77515452 1472 {
9c1a9547 1473 this->CalculateWeightedCorrelationsForDifferentialFlow("POI");
1474 this->CalculateWeightedCorrelationsForDifferentialFlow("RP");
77515452 1475 }
3d824203 1476
9c1a9547 1477 }
77515452 1478
9c1a9547 1479 if(evaluateNestedLoopsForIntegratedFlow && nPrim>0 && nPrim<14) // to be improved / removed (eventually I would not need this if())
1480 {
1481 this->EvaluateNestedLoopsForIntegratedFlow(anEvent);
1482 }
3d824203 1483
9c1a9547 1484 if(evaluateNestedLoopsForDifferentialFlow && nPrim>0 && nPrim<14) // to be improved / removed (eventually I would not need this if())
1485 {
1486 this->EvaluateNestedLoopsForDifferentialFlow(anEvent);
1487 }
3d824203 1488
3d824203 1489
9c1a9547 1490
1491
1492 // ********************************
1493 // **** RESET E-B-E QUANTITIES ****
1494 // ********************************
3d824203 1495
9c1a9547 1496 fReQ->Zero();
1497 fImQ->Zero();
1498 fSMpk->Zero();
1499 fReqnPtEta->Reset();
1500 fImqnPtEta->Reset();
1501 fmPtEta->Reset();
1502 fReqPrimePrime1nPtEta->Reset();
1503 fImqPrimePrime1nPtEta->Reset();
1504 fReqPrimePrime2nPtEta->Reset();
1505 fImqPrimePrime2nPtEta->Reset();
1506 fmPrimePrimePtEta->Reset();
1507 fReqPrimePrime1n2kPtEta->Reset();
1508 fImqPrimePrime1n2kPtEta->Reset();
1509 fReqPrimePrime2n1kPtEta->Reset();
1510 fImqPrimePrime2n1kPtEta->Reset();
1511 fSmPrimePrime1p1kPtEta->Reset();
1512 fSmPrimePrime1p2kPtEta->Reset();
1513 fSmPrimePrime1p3kPtEta->Reset();
1514 // qRPs (to be improved - notation)
1515 fReqRP1nPtEta->Reset();
1516 fImqRP1nPtEta->Reset();
1517 fReqRP2nPtEta->Reset();
1518 fImqRP2nPtEta->Reset();
1519 fmRPPtEta->Reset();
1520 fReqRP1n2kPtEta->Reset();
1521 fImqRP1n2kPtEta->Reset();
1522 fReqRP2n1kPtEta->Reset();
1523 fImqRP2n1kPtEta->Reset();
1524 fSmRP1p1kPtEta->Reset();
1525 fSmRP1p2kPtEta->Reset();
1526 fSmRP1p3kPtEta->Reset();
1527
1528} // end of AliFlowAnalysisWithQCumulants::Make(AliFlowEventSimple* anEvent)
1529
1530
1531//================================================================================================================================
1532
1533
1534void AliFlowAnalysisWithQCumulants::CalculateCorrelationsForIntegratedFlow()
1535{
1536 // calculate all correlations needed for 'no-name' integrated flow // to be improved (name)
1537
1538 // multiplicity:
1539 Double_t dMult = (*fSMpk)(0,0);
1540
1541 // real and imaginary parts of non-weighted Q-vectors evaluated in harmonics n, 2n, 3n and 4n:
1542 Double_t dReQ1n = (*fReQ)(0,0);
1543 Double_t dReQ2n = (*fReQ)(1,0);
1544 Double_t dReQ3n = (*fReQ)(2,0);
1545 Double_t dReQ4n = (*fReQ)(3,0);
1546 Double_t dImQ1n = (*fImQ)(0,0);
1547 Double_t dImQ2n = (*fImQ)(1,0);
1548 Double_t dImQ3n = (*fImQ)(2,0);
1549 Double_t dImQ4n = (*fImQ)(3,0);
3d824203 1550
9c1a9547 1551 // real and imaginary parts of some expressions involving various combinations of Q-vectors evaluated in harmonics n, 2n, 3n and 4n:
1552 // (these expression appear in the Eqs. for the multi-particle correlations bellow)
77515452 1553
9c1a9547 1554 // Re[Q_{2n} Q_{n}^* Q_{n}^*]
1555 Double_t reQ2nQ1nstarQ1nstar = pow(dReQ1n,2.)*dReQ2n + 2.*dReQ1n*dImQ1n*dImQ2n - pow(dImQ1n,2.)*dReQ2n;
77515452 1556
9c1a9547 1557 // Im[Q_{2n} Q_{n}^* Q_{n}^*]
1558 //Double_t imQ2nQ1nstarQ1nstar = pow(dReQ1n,2.)*dImQ2n-2.*dReQ1n*dImQ1n*dReQ2n-pow(dImQ1n,2.)*dImQ2n;
77515452 1559
9c1a9547 1560 // Re[Q_{n} Q_{n} Q_{2n}^*] = Re[Q_{2n} Q_{n}^* Q_{n}^*]
1561 Double_t reQ1nQ1nQ2nstar = reQ2nQ1nstarQ1nstar;
77515452 1562
9c1a9547 1563 // Re[Q_{3n} Q_{n} Q_{2n}^* Q_{2n}^*]
1564 Double_t reQ3nQ1nQ2nstarQ2nstar = (pow(dReQ2n,2.)-pow(dImQ2n,2.))*(dReQ3n*dReQ1n-dImQ3n*dImQ1n)
1565 + 2.*dReQ2n*dImQ2n*(dReQ3n*dImQ1n+dImQ3n*dReQ1n);
77515452 1566
9c1a9547 1567 // Im[Q_{3n} Q_{n} Q_{2n}^* Q_{2n}^*]
1568 //Double_t imQ3nQ1nQ2nstarQ2nstar = calculate and implement this (deleteMe)
1569
1570 // Re[Q_{2n} Q_{2n} Q_{3n}^* Q_{1n}^*] = Re[Q_{3n} Q_{n} Q_{2n}^* Q_{2n}^*]
1571 Double_t reQ2nQ2nQ3nstarQ1nstar = reQ3nQ1nQ2nstarQ2nstar;
1572
1573 // Re[Q_{4n} Q_{2n}^* Q_{2n}^*]
1574 Double_t reQ4nQ2nstarQ2nstar = pow(dReQ2n,2.)*dReQ4n+2.*dReQ2n*dImQ2n*dImQ4n-pow(dImQ2n,2.)*dReQ4n;
77515452 1575
9c1a9547 1576 // Im[Q_{4n} Q_{2n}^* Q_{2n}^*]
1577 //Double_t imQ4nQ2nstarQ2nstar = calculate and implement this (deleteMe)
77515452 1578
9c1a9547 1579 // Re[Q_{2n} Q_{2n} Q_{4n}^*] = Re[Q_{4n} Q_{2n}^* Q_{2n}^*]
1580 Double_t reQ2nQ2nQ4nstar = reQ4nQ2nstarQ2nstar;
77515452 1581
9c1a9547 1582 // Re[Q_{4n} Q_{3n}^* Q_{n}^*]
1583 Double_t reQ4nQ3nstarQ1nstar = dReQ4n*(dReQ3n*dReQ1n-dImQ3n*dImQ1n)+dImQ4n*(dReQ3n*dImQ1n+dImQ3n*dReQ1n);
77515452 1584
9c1a9547 1585 // Re[Q_{3n} Q_{n} Q_{4n}^*] = Re[Q_{4n} Q_{3n}^* Q_{n}^*]
1586 Double_t reQ3nQ1nQ4nstar = reQ4nQ3nstarQ1nstar;
77515452 1587
9c1a9547 1588 // Im[Q_{4n} Q_{3n}^* Q_{n}^*]
1589 //Double_t imQ4nQ3nstarQ1nstar = calculate and implement this (deleteMe)
6f366058 1590
9c1a9547 1591 // Re[Q_{3n} Q_{2n}^* Q_{n}^*]
1592 Double_t reQ3nQ2nstarQ1nstar = dReQ3n*dReQ2n*dReQ1n-dReQ3n*dImQ2n*dImQ1n+dImQ3n*dReQ2n*dImQ1n
1593 + dImQ3n*dImQ2n*dReQ1n;
1594
1595 // Re[Q_{2n} Q_{n} Q_{3n}^*] = Re[Q_{3n} Q_{2n}^* Q_{n}^*]
1596 Double_t reQ2nQ1nQ3nstar = reQ3nQ2nstarQ1nstar;
3d824203 1597
9c1a9547 1598 // Im[Q_{3n} Q_{2n}^* Q_{n}^*]
1599 //Double_t imQ3nQ2nstarQ1nstar; //calculate and implement this (deleteMe)
3d824203 1600
9c1a9547 1601 // Re[Q_{3n} Q_{n}^* Q_{n}^* Q_{n}^*]
1602 Double_t reQ3nQ1nstarQ1nstarQ1nstar = dReQ3n*pow(dReQ1n,3)-3.*dReQ1n*dReQ3n*pow(dImQ1n,2)
1603 + 3.*dImQ1n*dImQ3n*pow(dReQ1n,2)-dImQ3n*pow(dImQ1n,3);
1604
1605 // Im[Q_{3n} Q_{n}^* Q_{n}^* Q_{n}^*]
1606 //Double_t imQ3nQ1nstarQ1nstarQ1nstar; //calculate and implement this (deleteMe)
3d824203 1607
9c1a9547 1608 // |Q_{2n}|^2 |Q_{n}|^2
1609 Double_t dQ2nQ1nQ2nstarQ1nstar = (pow(dReQ2n,2.)+pow(dImQ2n,2.))*(pow(dReQ1n,2.)+pow(dImQ1n,2.));
3d824203 1610
9c1a9547 1611 // Re[Q_{4n} Q_{2n}^* Q_{n}^* Q_{n}^*]
1612 Double_t reQ4nQ2nstarQ1nstarQ1nstar = (dReQ4n*dReQ2n+dImQ4n*dImQ2n)*(pow(dReQ1n,2)-pow(dImQ1n,2))
1613 + 2.*dReQ1n*dImQ1n*(dImQ4n*dReQ2n-dReQ4n*dImQ2n);
3d824203 1614
9c1a9547 1615 // Im[Q_{4n} Q_{2n}^* Q_{n}^* Q_{n}^*]
1616 //Double_t imQ4nQ2nstarQ1nstarQ1nstar; //calculate and implement this (deleteMe)
3d824203 1617
9c1a9547 1618 // Re[Q_{2n} Q_{n} Q_{n}^* Q_{n}^* Q_{n}^*]
1619 Double_t reQ2nQ1nQ1nstarQ1nstarQ1nstar = (dReQ2n*dReQ1n-dImQ2n*dImQ1n)*(pow(dReQ1n,3)-3.*dReQ1n*pow(dImQ1n,2))
1620 + (dReQ2n*dImQ1n+dReQ1n*dImQ2n)*(3.*dImQ1n*pow(dReQ1n,2)-pow(dImQ1n,3));
1621
1622 // Im[Q_{2n} Q_{n} Q_{n}^* Q_{n}^* Q_{n}^*]
1623 //Double_t imQ2nQ1nQ1nstarQ1nstarQ1nstar; //calculate and implement this (deleteMe)
1dfa3c16 1624
9c1a9547 1625 // Re[Q_{2n} Q_{2n} Q_{2n}^* Q_{n}^* Q_{n}^*]
1626 Double_t reQ2nQ2nQ2nstarQ1nstarQ1nstar = (pow(dReQ2n,2.)+pow(dImQ2n,2.))
1627 * (dReQ2n*(pow(dReQ1n,2.)-pow(dImQ1n,2.)) + 2.*dImQ2n*dReQ1n*dImQ1n);
1628
1629 // Im[Q_{2n} Q_{2n} Q_{2n}^* Q_{n}^* Q_{n}^*]
1630 //Double_t imQ2nQ2nQ2nstarQ1nstarQ1nstar = (pow(dReQ2n,2.)+pow(dImQ2n,2.))
1631 // * (dImQ2n*(pow(dReQ1n,2.)-pow(dImQ1n,2.)) - 2.*dReQ2n*dReQ1n*dImQ1n);
1632
1633 // Re[Q_{4n} Q_{n}^* Q_{n}^* Q_{n}^* Q_{n}^*]
1634 Double_t reQ4nQ1nstarQ1nstarQ1nstarQ1nstar = pow(dReQ1n,4.)*dReQ4n-6.*pow(dReQ1n,2.)*dReQ4n*pow(dImQ1n,2.)
1635 + pow(dImQ1n,4.)*dReQ4n+4.*pow(dReQ1n,3.)*dImQ1n*dImQ4n
1636 - 4.*pow(dImQ1n,3.)*dReQ1n*dImQ4n;
1637
1638 // Im[Q_{4n} Q_{n}^* Q_{n}^* Q_{n}^* Q_{n}^*]
1639 //Double_t imQ4nQ1nstarQ1nstarQ1nstarQ1nstar = pow(dReQ1n,4.)*dImQ4n-6.*pow(dReQ1n,2.)*dImQ4n*pow(dImQ1n,2.)
1640 // + pow(dImQ1n,4.)*dImQ4n+4.*pow(dImQ1n,3.)*dReQ1n*dReQ4n
1641 // - 4.*pow(dReQ1n,3.)*dImQ1n*dReQ4n;
1642
1643 // Re[Q_{3n} Q_{n} Q_{2n}^* Q_{n}^* Q_{n}^*]
1644 Double_t reQ3nQ1nQ2nstarQ1nstarQ1nstar = (pow(dReQ1n,2.)+pow(dImQ1n,2.))
1645 * (dReQ1n*dReQ2n*dReQ3n-dReQ3n*dImQ1n*dImQ2n+dReQ2n*dImQ1n*dImQ3n+dReQ1n*dImQ2n*dImQ3n);
1646
1647 // Im[Q_{3n} Q_{n} Q_{2n}^* Q_{n}^* Q_{n}^*]
1648 //Double_t imQ3nQ1nQ2nstarQ1nstarQ1nstar = (pow(dReQ1n,2.)+pow(dImQ1n,2.))
1649 // * (-dReQ2n*dReQ3n*dImQ1n-dReQ1n*dReQ3n*dImQ2n+dReQ1n*dReQ2n*dImQ3n-dImQ1n*dImQ2n*dImQ3n);
1650
1651
1652 // Re[Q_{2n} Q_{2n} Q_{n}^* Q_{n}^* Q_{n}^* Q_{n}^*]
1653 Double_t reQ2nQ2nQ1nstarQ1nstarQ1nstarQ1nstar = (pow(dReQ1n,2.)*dReQ2n-2.*dReQ1n*dReQ2n*dImQ1n-dReQ2n*pow(dImQ1n,2.)
1654 + dImQ2n*pow(dReQ1n,2.)+2.*dReQ1n*dImQ1n*dImQ2n-pow(dImQ1n,2.)*dImQ2n)
1655 * (pow(dReQ1n,2.)*dReQ2n+2.*dReQ1n*dReQ2n*dImQ1n-dReQ2n*pow(dImQ1n,2.)
1656 - dImQ2n*pow(dReQ1n,2.)+2.*dReQ1n*dImQ1n*dImQ2n+pow(dImQ1n,2.)*dImQ2n);
1657
1658 // Im[Q_{2n} Q_{2n} Q_{n}^* Q_{n}^* Q_{n}^* Q_{n}^*]
1659 //Double_t imQ2nQ2nQ1nstarQ1nstarQ1nstarQ1nstar = 2.*(pow(dReQ1n,2.)*dReQ2n-dReQ2n*pow(dImQ1n,2.)
1660 // + 2.*dReQ1n*dImQ1n*dImQ2n)*(pow(dReQ1n,2.)*dImQ2n
1661 // - 2.*dReQ1n*dImQ1n*dReQ2n-pow(dImQ1n,2.)*dImQ2n);
1662
1663 // Re[Q_{3n} Q_{n} Q_{n}^* Q_{n}^* Q_{n}^* Q_{n}^*]
1664 Double_t reQ3nQ1nQ1nstarQ1nstarQ1nstarQ1nstar = (pow(dReQ1n,2.)+pow(dImQ1n,2.))
1665 * (pow(dReQ1n,3.)*dReQ3n-3.*dReQ1n*dReQ3n*pow(dImQ1n,2.)
1666 + 3.*pow(dReQ1n,2.)*dImQ1n*dImQ3n-pow(dImQ1n,3.)*dImQ3n);
1667
1668 // Im[Q_{3n} Q_{n} Q_{n}^* Q_{n}^* Q_{n}^* Q_{n}^*]
1669 //Double_t imQ3nQ1nQ1nstarQ1nstarQ1nstarQ1nstar = (pow(dReQ1n,2.)+pow(dImQ1n,2.))
1670 // * (pow(dImQ1n,3.)*dReQ3n-3.*dImQ1n*dReQ3n*pow(dReQ1n,2.)
1671 // - 3.*pow(dImQ1n,2.)*dReQ1n*dImQ3n+pow(dReQ1n,3.)*dImQ3n);
1672
1673 // |Q_{2n}|^2 |Q_{n}|^4
1674 Double_t dQ2nQ1nQ1nQ2nstarQ1nstarQ1nstar = (pow(dReQ2n,2.)+pow(dImQ2n,2.))*pow((pow(dReQ1n,2.)+pow(dImQ1n,2.)),2.);
1675
1676 // Re[Q_{2n} Q_{n} Q_{n} Q_{n}^* Q_{n}^* Q_{n}^* Q_{n}^*]
1677 Double_t reQ2nQ1nQ1nQ1nstarQ1nstarQ1nstarQ1nstar = pow((pow(dReQ1n,2.)+pow(dImQ1n,2.)),2.)
1678 * (pow(dReQ1n,2.)*dReQ2n-dReQ2n*pow(dImQ1n,2.)
1679 + 2.*dReQ1n*dImQ1n*dImQ2n);
1680
1681 // Im[Q_{2n} Q_{n} Q_{n} Q_{n}^* Q_{n}^* Q_{n}^* Q_{n}^*]
1682 //Double_t imQ2nQ1nQ1nQ1nstarQ1nstarQ1nstarQ1nstar = pow((pow(dReQ1n,2.)+pow(dImQ1n,2.)),2.)
1683 // * (pow(dReQ1n,2.)*dImQ2n-dImQ2n*pow(dImQ1n,2.)
1684 // - 2.*dReQ1n*dReQ2n*dImQ1n);
ae733b3b 1685
9c1a9547 1686
1dfa3c16 1687
9c1a9547 1688
1689 // **************************************
1690 // **** multi-particle correlations: ****
1691 // **************************************
1692 //
1693 // Remark 1: multi-particle correlations calculated with non-weighted Q-vectors are stored in 1D profile fQCorrelations.
1694 // Remark 2: binning of fQCorrelations is organized as follows:
1695 // --------------------------------------------------------------------------------------------------------------------
1696 // 1st bin: <2>_{1n|1n} = two1n1n = cos(n*(phi1-phi2))>
1697 // 2nd bin: <2>_{2n|2n} = two2n2n = cos(2n*(phi1-phi2))>
1698 // 3rd bin: <2>_{3n|3n} = two3n3n = cos(3n*(phi1-phi2))>
1699 // 4th bin: <2>_{4n|4n} = two4n4n = cos(4n*(phi1-phi2))>
1700 // 5th bin: ---- EMPTY ----
1701 // 6th bin: <3>_{2n|1n,1n} = three2n1n1n = <cos(n*(2.*phi1-phi2-phi3))>
1702 // 7th bin: <3>_{3n|2n,1n} = three3n2n1n = <cos(n*(3.*phi1-2.*phi2-phi3))>
1703 // 8th bin: <3>_{4n|2n,2n} = three4n2n2n = <cos(n*(4.*phi1-2.*phi2-2.*phi3))>
1704 // 9th bin: <3>_{4n|3n,1n} = three4n3n1n = <cos(n*(4.*phi1-3.*phi2-phi3))>
1705 // 10th bin: ---- EMPTY ----
1706 // 11th bin: <4>_{1n,1n|1n,1n} = four1n1n1n1n = <cos(n*(phi1+phi2-phi3-phi4))>
1707 // 12th bin: <4>_{2n,1n|2n,1n} = four2n1n2n1n = <cos(2.*n*(phi1+phi2-phi3-phi4))>
1708 // 13th bin: <4>_{2n,2n|2n,2n} = four2n2n2n2n = <cos(n*(2.*phi1+phi2-2.*phi3-phi4))>
1709 // 14th bin: <4>_{3n|1n,1n,1n} = four3n1n1n1n = <cos(n*(3.*phi1-phi2-phi3-phi4))>
1710 // 15th bin: <4>_{3n,1n|3n,1n} = four3n1n3n1n = <cos(n*(4.*phi1-2.*phi2-phi3-phi4))>
1711 // 16th bin: <4>_{3n,1n|2n,2n} = four3n1n2n2n = <cos(n*(3.*phi1+phi2-2.*phi3-2.*phi4))>
1712 // 17th bin: <4>_{4n|2n,1n,1n} = four4n2n1n1n = <cos(n*(3.*phi1+phi2-3.*phi3-phi4))>
1713 // 18th bin: ---- EMPTY ----
1714 // 19th bin: <5>_{2n|1n,1n,1n,1n} = five2n1n1n1n1n = <cos(n*(2.*phi1+phi2-phi3-phi4-phi5))>
1715 // 20th bin: <5>_{2n,2n|2n,1n,1n} = five2n2n2n1n1n = <cos(n*(2.*phi1+2.*phi2-2.*phi3-phi4-phi5))>
1716 // 21st bin: <5>_{3n,1n|2n,1n,1n} = five3n1n2n1n1n = <cos(n*(3.*phi1+phi2-2.*phi3-phi4-phi5))>
1717 // 22nd bin: <5>_{4n|1n,1n,1n,1n} = five4n1n1n1n1n = <cos(n*(4.*phi1-phi2-phi3-phi4-phi5))>
1718 // 23rd bin: ---- EMPTY ----
1719 // 24th bin: <6>_{1n,1n,1n|1n,1n,1n} = six1n1n1n1n1n1n = <cos(n*(phi1+phi2+phi3-phi4-phi5-phi6))>
1720 // 25th bin: <6>_{2n,1n,1n|2n,1n,1n} = six2n1n1n2n1n1n = <cos(n*(2.*phi1+2.*phi2-phi3-phi4-phi5-phi6))>
1721 // 26th bin: <6>_{2n,2n|1n,1n,1n,1n} = six2n2n1n1n1n1n = <cos(n*(3.*phi1+phi2-phi3-phi4-phi5-phi6))>
1722 // 27th bin: <6>_{3n,1n|1n,1n,1n,1n} = six3n1n1n1n1n1n = <cos(n*(2.*phi1+phi2+phi3-2.*phi4-phi5-phi6))>
1723 // 28th bin: ---- EMPTY ----
1724 // 29th bin: <7>_{2n,1n,1n|1n,1n,1n,1n} = seven2n1n1n1n1n1n1n = <cos(n*(2.*phi1+phi2+phi3-phi4-phi5-phi6-phi7))>
1725 // 30th bin: ---- EMPTY ----
1726 // 31st bin: <8>_{1n,1n,1n,1n|1n,1n,1n,1n} = eight1n1n1n1n1n1n1n1n = <cos(n*(phi1+phi2+phi3+phi4-phi5-phi6-phi7-phi8))>
1727 // --------------------------------------------------------------------------------------------------------------------
1728
1729 // 2-particle:
1730 Double_t two1n1n = 0.; // <cos(n*(phi1-phi2))>
1731 Double_t two2n2n = 0.; // <cos(2n*(phi1-phi2))>
1732 Double_t two3n3n = 0.; // <cos(3n*(phi1-phi2))>
1733 Double_t two4n4n = 0.; // <cos(4n*(phi1-phi2))>
1dfa3c16 1734
9c1a9547 1735 if(dMult>1)
1736 {
1737 two1n1n = (pow(dReQ1n,2.)+pow(dImQ1n,2.)-dMult)/(dMult*(dMult-1.));
1738 two2n2n = (pow(dReQ2n,2.)+pow(dImQ2n,2.)-dMult)/(dMult*(dMult-1.));
1739 two3n3n = (pow(dReQ3n,2.)+pow(dImQ3n,2.)-dMult)/(dMult*(dMult-1.));
1740 two4n4n = (pow(dReQ4n,2.)+pow(dImQ4n,2.)-dMult)/(dMult*(dMult-1.));
1741
1742 fQCorrelations->Fill(0.,two1n1n,dMult*(dMult-1.));
1743 fQCorrelations->Fill(1.,two2n2n,dMult*(dMult-1.));
1744 fQCorrelations->Fill(2.,two3n3n,dMult*(dMult-1.));
1745 fQCorrelations->Fill(3.,two4n4n,dMult*(dMult-1.));
1746
1747 // distribution of <cos(n*(phi1-phi2))>:
1748 f2pDistribution->Fill(two1n1n,dMult*(dMult-1.));
1749 } // end of if(dMult>1)
ae733b3b 1750
9c1a9547 1751 // 3-particle:
1752 Double_t three2n1n1n = 0.; // <cos(n*(2.*phi1-phi2-phi3))>
1753 Double_t three3n2n1n = 0.; // <cos(n*(3.*phi1-2.*phi2-phi3))>
1754 Double_t three4n2n2n = 0.; // <cos(n*(4.*phi1-2.*phi2-2.*phi3))>
1755 Double_t three4n3n1n = 0.; // <cos(n*(4.*phi1-3.*phi2-phi3))>
ae733b3b 1756
9c1a9547 1757 if(dMult>2)
1758 {
1759 three2n1n1n = (reQ2nQ1nstarQ1nstar-2.*(pow(dReQ1n,2.)+pow(dImQ1n,2.))
1760 - (pow(dReQ2n,2.)+pow(dImQ2n,2.))+2.*dMult)
1761 / (dMult*(dMult-1.)*(dMult-2.));
1762 three3n2n1n = (reQ3nQ2nstarQ1nstar-(pow(dReQ3n,2.)+pow(dImQ3n,2.))
1763 - (pow(dReQ2n,2.)+pow(dImQ2n,2.))
1764 - (pow(dReQ1n,2.)+pow(dImQ1n,2.))+2.*dMult)
1765 / (dMult*(dMult-1.)*(dMult-2.));
1766 three4n2n2n = (reQ4nQ2nstarQ2nstar-2.*(pow(dReQ2n,2.)+pow(dImQ2n,2.))
1767 - (pow(dReQ4n,2.)+pow(dImQ4n,2.))+2.*dMult)
1768 / (dMult*(dMult-1.)*(dMult-2.));
1769 three4n3n1n = (reQ4nQ3nstarQ1nstar-(pow(dReQ4n,2.)+pow(dImQ4n,2.))
1770 - (pow(dReQ3n,2.)+pow(dImQ3n,2.))
1771 - (pow(dReQ1n,2.)+pow(dImQ1n,2.))+2.*dMult)
1772 / (dMult*(dMult-1.)*(dMult-2.));
1773
1774 fQCorrelations->Fill(5.,three2n1n1n,dMult*(dMult-1.)*(dMult-2.));
1775 fQCorrelations->Fill(6.,three3n2n1n,dMult*(dMult-1.)*(dMult-2.));
1776 fQCorrelations->Fill(7.,three4n2n2n,dMult*(dMult-1.)*(dMult-2.));
1777 fQCorrelations->Fill(8.,three4n3n1n,dMult*(dMult-1.)*(dMult-2.));
1778 } // end of if(dMult>2)
ae733b3b 1779
9c1a9547 1780 // 4-particle:
1781 Double_t four1n1n1n1n = 0.; // <cos(n*(phi1+phi2-phi3-phi4))>
1782 Double_t four2n2n2n2n = 0.; // <cos(2.*n*(phi1+phi2-phi3-phi4))>
1783 Double_t four2n1n2n1n = 0.; // <cos(n*(2.*phi1+phi2-2.*phi3-phi4))>
1784 Double_t four3n1n1n1n = 0.; // <cos(n*(3.*phi1-phi2-phi3-phi4))>
1785 Double_t four4n2n1n1n = 0.; // <cos(n*(4.*phi1-2.*phi2-phi3-phi4))>
1786 Double_t four3n1n2n2n = 0.; // <cos(n*(3.*phi1+phi2-2.*phi3-2.*phi4))>
1787 Double_t four3n1n3n1n = 0.; // <cos(n*(3.*phi1+phi2-3.*phi3-phi4))>
1dfa3c16 1788
9c1a9547 1789 if(dMult>3)
1790 {
1791 four1n1n1n1n = (2.*dMult*(dMult-3.)+pow((pow(dReQ1n,2.)+pow(dImQ1n,2.)),2.)-4.*(dMult-2.)*(pow(dReQ1n,2.)
1792 + pow(dImQ1n,2.))-2.*reQ2nQ1nstarQ1nstar+(pow(dReQ2n,2.)+pow(dImQ2n,2.)))
1793 / (dMult*(dMult-1)*(dMult-2.)*(dMult-3.));
1794 four2n2n2n2n = (2.*dMult*(dMult-3.)+pow((pow(dReQ2n,2.)+pow(dImQ2n,2.)),2.)-4.*(dMult-2.)*(pow(dReQ2n,2.)
1795 + pow(dImQ2n,2.))-2.*reQ4nQ2nstarQ2nstar+(pow(dReQ4n,2.)+pow(dImQ4n,2.)))
1796 / (dMult*(dMult-1)*(dMult-2.)*(dMult-3.));
1797 four2n1n2n1n = (dQ2nQ1nQ2nstarQ1nstar-2.*reQ3nQ2nstarQ1nstar-2.*reQ2nQ1nstarQ1nstar)
1798 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.))
1799 - ((dMult-5.)*(pow(dReQ1n,2.)+pow(dImQ1n,2.))
1800 + (dMult-4.)*(pow(dReQ2n,2.)+pow(dImQ2n,2.))-(pow(dReQ3n,2.)+pow(dImQ3n,2.)))
1801 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.))
1802 + (dMult-6.)/((dMult-1.)*(dMult-2.)*(dMult-3.));
1803 four3n1n1n1n = (reQ3nQ1nstarQ1nstarQ1nstar-3.*reQ3nQ2nstarQ1nstar-3.*reQ2nQ1nstarQ1nstar)
1804 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.))
1805 + (2.*(pow(dReQ3n,2.)+pow(dImQ3n,2.))+3.*(pow(dReQ2n,2.)+pow(dImQ2n,2.))
1806 + 6.*(pow(dReQ1n,2.)+pow(dImQ1n,2.))-6.*dMult)
1807 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.));
1808 four4n2n1n1n = (reQ4nQ2nstarQ1nstarQ1nstar-2.*reQ4nQ3nstarQ1nstar-reQ4nQ2nstarQ2nstar-2.*reQ3nQ2nstarQ1nstar)
1809 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.))
1810 - (reQ2nQ1nstarQ1nstar-2.*(pow(dReQ4n,2.)+pow(dImQ4n,2.))-2.*(pow(dReQ3n,2.)+pow(dImQ3n,2.))
1811 - 3.*(pow(dReQ2n,2.)+pow(dImQ2n,2.))-4.*(pow(dReQ1n,2.)+pow(dImQ1n,2.)))
1812 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.))
1813 - 6./((dMult-1.)*(dMult-2.)*(dMult-3.));
1814 four3n1n2n2n = (reQ3nQ1nQ2nstarQ2nstar-reQ4nQ2nstarQ2nstar-reQ3nQ1nQ4nstar-2.*reQ3nQ2nstarQ1nstar)
1815 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.))
1816 - (2.*reQ1nQ1nQ2nstar-(pow(dReQ4n,2.)+pow(dImQ4n,2.))-2.*(pow(dReQ3n,2.)+pow(dImQ3n,2.))
1817 - 4.*(pow(dReQ2n,2.)+pow(dImQ2n,2.))-4.*(pow(dReQ1n,2.)+pow(dImQ1n,2.)))
1818 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.))
1819 - 6./((dMult-1.)*(dMult-2.)*(dMult-3.));
1820 four3n1n3n1n = ((pow(dReQ3n,2.)+pow(dImQ3n,2.))*(pow(dReQ1n,2.)+pow(dImQ1n,2.))
1821 - 2.*reQ4nQ3nstarQ1nstar-2.*reQ3nQ2nstarQ1nstar)
1822 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.))
1823 + ((pow(dReQ4n,2.)+pow(dImQ4n,2.))-(dMult-4.)*(pow(dReQ3n,2.)+pow(dImQ3n,2.))
1824 + (pow(dReQ2n,2.)+pow(dImQ2n,2.))-(dMult-4.)*(pow(dReQ1n,2.)+pow(dImQ1n,2.)))
1825 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.))
1826 + (dMult-6.)/((dMult-1.)*(dMult-2.)*(dMult-3.));
1827
1828 fQCorrelations->Fill(10.,four1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.));
1829 fQCorrelations->Fill(11.,four2n1n2n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.));
1830 fQCorrelations->Fill(12.,four2n2n2n2n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.));
1831 fQCorrelations->Fill(13.,four3n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.));
1832 fQCorrelations->Fill(14.,four3n1n3n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.));
1833 fQCorrelations->Fill(15.,four3n1n2n2n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.));
1834 fQCorrelations->Fill(16.,four4n2n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.));
1835
1836 // distribution of <cos(n*(phi1+phi2-phi3-phi4))>
1837 f4pDistribution->Fill(four1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.));
1838
1839 // fQProduct->Fill(0.,two1n1n*four1n1n1n1n,dMult*(dMult-1.)*dMult*(dMult-1.)*(dMult-2.)*(dMult-3.));
1840 } // end of if(dMult>3)
1841
1842 // 5-particle:
1843 Double_t five2n1n1n1n1n = 0.; // <cos(n*(2.*phi1+phi2-phi3-phi4-phi5))>
1844 Double_t five2n2n2n1n1n = 0.; // <cos(n*(2.*phi1+2.*phi2-2.*phi3-phi4-phi5))>
1845 Double_t five3n1n2n1n1n = 0.; // <cos(n*(3.*phi1+phi2-2.*phi3-phi4-phi5))>
1846 Double_t five4n1n1n1n1n = 0.; // <cos(n*(4.*phi1-phi2-phi3-phi4-phi5))>
4057ba99 1847
9c1a9547 1848 if(dMult>4)
1849 {
1850 five2n1n1n1n1n = (reQ2nQ1nQ1nstarQ1nstarQ1nstar-reQ3nQ1nstarQ1nstarQ1nstar+6.*reQ3nQ2nstarQ1nstar)
1851 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1852 - (reQ2nQ1nQ3nstar+3.*(dMult-6.)*reQ2nQ1nstarQ1nstar+3.*reQ1nQ1nQ2nstar)
1853 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1854 - (2.*(pow(dReQ3n,2.)+pow(dImQ3n,2.))
1855 + 3.*(pow(dReQ1n,2.)+pow(dImQ1n,2.))*(pow(dReQ2n,2.)+pow(dImQ2n,2.))
1856 - 3.*(dMult-4.)*(pow(dReQ2n,2.)+pow(dImQ2n,2.)))
1857 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1858 - 3.*(pow((pow(dReQ1n,2.)+pow(dImQ1n,2.)),2.)
1859 - 2.*(2*dMult-5.)*(pow(dReQ1n,2.)+pow(dImQ1n,2.))+2.*dMult*(dMult-4.))
1860 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.));
1861
1862 five2n2n2n1n1n = (reQ2nQ2nQ2nstarQ1nstarQ1nstar-reQ4nQ2nstarQ1nstarQ1nstar-2.*reQ2nQ2nQ3nstarQ1nstar)
1863 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1864 + 2.*(reQ4nQ2nstarQ2nstar+4.*reQ3nQ2nstarQ1nstar+reQ3nQ1nQ4nstar)
1865 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1866 + (reQ2nQ2nQ4nstar-2.*(dMult-5.)*reQ2nQ1nstarQ1nstar+2.*reQ1nQ1nQ2nstar)
1867 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1868 - (2.*(pow(dReQ4n,2.)+pow(dImQ4n,2.))+4.*(pow(dReQ3n,2.)+pow(dImQ3n,2.))
1869 + 1.*pow((pow(dReQ2n,2.)+pow(dImQ2n,2.)),2.)
1870 - 2.*(3.*dMult-10.)*(pow(dReQ2n,2.)+pow(dImQ2n,2.)))
1871 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1872 - (4.*(pow(dReQ1n,2.)+pow(dImQ1n,2.))*(pow(dReQ2n,2.)+pow(dImQ2n,2.))
1873 - 4.*(dMult-5.)*(pow(dReQ1n,2.)+pow(dImQ1n,2.))+4.*dMult*(dMult-6.))
1874 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.));
1875
1876 five4n1n1n1n1n = (reQ4nQ1nstarQ1nstarQ1nstarQ1nstar-6.*reQ4nQ2nstarQ1nstarQ1nstar-4.*reQ3nQ1nstarQ1nstarQ1nstar)
1877 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1878 + (8.*reQ4nQ3nstarQ1nstar+3.*reQ4nQ2nstarQ2nstar+12.*reQ3nQ2nstarQ1nstar+12.*reQ2nQ1nstarQ1nstar)
1879 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1880 - (6.*(pow(dReQ4n,2.)+pow(dImQ4n,2.))+8.*(pow(dReQ3n,2.)+pow(dImQ3n,2.))
1881 + 12.*(pow(dReQ2n,2.)+pow(dImQ2n,2.))+24.*(pow(dReQ1n,2.)+pow(dImQ1n,2.))-24.*dMult)
1882 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.));
1883
1884 five3n1n2n1n1n = (reQ3nQ1nQ2nstarQ1nstarQ1nstar-reQ4nQ2nstarQ1nstarQ1nstar-reQ3nQ1nstarQ1nstarQ1nstar)
1885 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1886 - (reQ3nQ1nQ2nstarQ2nstar-3.*reQ4nQ3nstarQ1nstar-reQ4nQ2nstarQ2nstar)
1887 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1888 - ((2.*dMult-13.)*reQ3nQ2nstarQ1nstar-reQ3nQ1nQ4nstar-9.*reQ2nQ1nstarQ1nstar)
1889 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1890 - (2.*reQ1nQ1nQ2nstar+2.*(pow(dReQ4n,2.)+pow(dImQ4n,2.))
1891 - 2.*(dMult-5.)*(pow(dReQ3n,2.)+pow(dImQ3n,2.))+2.*(pow(dReQ3n,2.)
1892 + pow(dImQ3n,2.))*(pow(dReQ1n,2.)+pow(dImQ1n,2.)))
1893 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1894 + (2.*(dMult-6.)*(pow(dReQ2n,2.)+pow(dImQ2n,2.))
1895 - 2.*(pow(dReQ2n,2.)+pow(dImQ2n,2.))*(pow(dReQ1n,2.)+pow(dImQ1n,2.))
1896 - pow((pow(dReQ1n,2.)+pow(dImQ1n,2.)),2.)
1897 + 2.*(3.*dMult-11.)*(pow(dReQ1n,2.)+pow(dImQ1n,2.)))
1898 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.))
1899 - 4.*(dMult-6.)/((dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.));
1900
1901 fQCorrelations->Fill(18.,five2n1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.));
1902 fQCorrelations->Fill(19.,five2n2n2n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.));
1903 fQCorrelations->Fill(20.,five3n1n2n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.));
1904 fQCorrelations->Fill(21.,five4n1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.));
1905 } // end of if(dMult>4)
1906
1907 // 6-particle:
1908 Double_t six1n1n1n1n1n1n = 0.; // <cos(n*(phi1+phi2+phi3-phi4-phi5-phi6))>
1909 Double_t six2n2n1n1n1n1n = 0.; // <cos(n*(2.*phi1+2.*phi2-phi3-phi4-phi5-phi6))>
1910 Double_t six3n1n1n1n1n1n = 0.; // <cos(n*(3.*phi1+phi2-phi3-phi4-phi5-phi6))>
1911 Double_t six2n1n1n2n1n1n = 0.; // <cos(n*(2.*phi1+phi2+phi3-2.*phi4-phi5-phi6))>
ae733b3b 1912
9c1a9547 1913 if(dMult>5)
1914 {
1915 six1n1n1n1n1n1n = (pow(pow(dReQ1n,2.)+pow(dImQ1n,2.),3.)+9.*dQ2nQ1nQ2nstarQ1nstar-6.*reQ2nQ1nQ1nstarQ1nstarQ1nstar)
1916 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.))
1917 + 4.*(reQ3nQ1nstarQ1nstarQ1nstar-3.*reQ3nQ2nstarQ1nstar)
1918 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.))
1919 + 2.*(9.*(dMult-4.)*reQ2nQ1nstarQ1nstar+2.*(pow(dReQ3n,2.)+pow(dImQ3n,2.)))
1920 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.))
1921 - 9.*(pow((pow(dReQ1n,2.)+pow(dImQ1n,2.)),2.)+(pow(dReQ2n,2.)+pow(dImQ2n,2.)))
1922 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-5.))
1923 + (18.*(pow(dReQ1n,2.)+pow(dImQ1n,2.)))
1924 / (dMult*(dMult-1)*(dMult-3)*(dMult-4))
1925 - 6./((dMult-1.)*(dMult-2.)*(dMult-3.));
1926
1927 six2n1n1n2n1n1n = (dQ2nQ1nQ1nQ2nstarQ1nstarQ1nstar-dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)
1928 * (2.*five2n2n2n1n1n+4.*five2n1n1n1n1n+4.*five3n1n2n1n1n+4.*four2n1n2n1n+1.*four1n1n1n1n)
1929 - dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(4.*four1n1n1n1n+4.*two1n1n
1930 + 2.*three2n1n1n+2.*three2n1n1n+4.*four3n1n1n1n+8.*three2n1n1n+2.*four4n2n1n1n
1931 + 4.*four2n1n2n1n+2.*two2n2n+8.*four2n1n2n1n+4.*four3n1n3n1n+8.*three3n2n1n
1932 + 4.*four3n1n2n2n+4.*four1n1n1n1n+4.*four2n1n2n1n+1.*four2n2n2n2n)
1933 - dMult*(dMult-1.)*(dMult-2.)*(2.*three2n1n1n+8.*two1n1n+4.*two1n1n+2.
1934 + 4.*two1n1n+4.*three2n1n1n+2.*two2n2n+4.*three2n1n1n+8.*three3n2n1n
1935 + 8.*two2n2n+4.*three4n3n1n+4.*two3n3n+4.*three3n2n1n+4.*two1n1n
1936 + 8.*three2n1n1n+4.*two1n1n+4.*three3n2n1n+4.*three2n1n1n+2.*two2n2n
1937 + 4.*three3n2n1n+2.*three4n2n2n)-dMult*(dMult-1.)
1938 * (4.*two1n1n+4.+4.*two1n1n+2.*two2n2n+1.+4.*two1n1n+4.*two2n2n+4.*two3n3n
1939 + 1.+2.*two2n2n+1.*two4n4n)-dMult)
1940 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)); // to be improved (direct formula needed)
1941
1942 six2n2n1n1n1n1n = (reQ2nQ2nQ1nstarQ1nstarQ1nstarQ1nstar-dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)
1943 * (five4n1n1n1n1n+8.*five2n1n1n1n1n+6.*five2n2n2n1n1n)-dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)
1944 * (4.*four3n1n1n1n+6.*four4n2n1n1n+12.*three2n1n1n+12.*four1n1n1n1n+24.*four2n1n2n1n
1945 + 4.*four3n1n2n2n+3.*four2n2n2n2n)-dMult*(dMult-1.)*(dMult-2.)*(6.*three2n1n1n+12.*three3n2n1n
1946 + 4.*three4n3n1n+3.*three4n2n2n+8.*three2n1n1n+24.*two1n1n+12.*two2n2n+12.*three2n1n1n+8.*three3n2n1n
1947 + 1.*three4n2n2n)-dMult*(dMult-1.)*(4.*two1n1n+6.*two2n2n+4.*two3n3n+1.*two4n4n+2.*two2n2n+8.*two1n1n+6.)-dMult)
1948 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)); // to be improved (direct formula needed)
1949
1950 six3n1n1n1n1n1n = (reQ3nQ1nQ1nstarQ1nstarQ1nstarQ1nstar-dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)
1951 * (five4n1n1n1n1n+4.*five2n1n1n1n1n+6.*five3n1n2n1n1n+4.*four3n1n1n1n)
1952 - dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(4.*four3n1n1n1n+6.*four4n2n1n1n+6.*four1n1n1n1n
1953 + 12.*three2n1n1n+12.*four2n1n2n1n+6.*four3n1n1n1n+12.*three3n2n1n+4.*four3n1n3n1n+3.*four3n1n2n2n)
1954 - dMult*(dMult-1.)*(dMult-2.)*(6.*three2n1n1n+12.*three3n2n1n+4.*three4n3n1n+3.*three4n2n2n+4.*two1n1n
1955 + 12.*two1n1n+6.*three2n1n1n+12.*three2n1n1n+4.*three3n2n1n+12.*two2n2n+4.*three3n2n1n+4.*two3n3n+1.*three4n3n1n
1956 + 6.*three3n2n1n)-dMult*(dMult-1.)*(4.*two1n1n+6.*two2n2n+4.*two3n3n+1.*two4n4n+1.*two1n1n+4.+6.*two1n1n+4.*two2n2n
1957 + 1.*two3n3n)-dMult)/(dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)); // to be improved (direct formula needed)
1958
1959 fQCorrelations->Fill(23.,six1n1n1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.));
1960 fQCorrelations->Fill(24.,six2n1n1n2n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.));
1961 fQCorrelations->Fill(25.,six2n2n1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.));
1962 fQCorrelations->Fill(26.,six3n1n1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.));
1963
1964 // distribution of <cos(n*(phi1+phi2+phi3-phi4-phi5-phi6))>
1965 f6pDistribution->Fill(six1n1n1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.));
1966
1967 //fQProduct->Fill(1.,two1n1n*six1n1n1n1n1n1n,dMult*(dMult-1.)*dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.));
1968 //fQProduct->Fill(3.,four1n1n1n1n*six1n1n1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.));
1969 } // end of if(dMult>5)
4057ba99 1970
9c1a9547 1971 // 7-particle:
1972 Double_t seven2n1n1n1n1n1n1n = 0.; // <cos(n*(2.*phi1+phi2+phi3-phi4-phi5-phi6-phi7))>
1dfa3c16 1973
9c1a9547 1974 if(dMult>6)
1975 {
1976 seven2n1n1n1n1n1n1n = (reQ2nQ1nQ1nQ1nstarQ1nstarQ1nstarQ1nstar-dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)
1977 * (2.*six3n1n1n1n1n1n+4.*six1n1n1n1n1n1n+1.*six2n2n1n1n1n1n+6.*six2n1n1n2n1n1n+8.*five2n1n1n1n1n)
1978 - dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(1.*five4n1n1n1n1n +8.*five2n1n1n1n1n+8.*four3n1n1n1n
1979 + 12.*five3n1n2n1n1n+4.*five2n1n1n1n1n+3.*five2n2n2n1n1n+6.*five2n2n2n1n1n+6.*four1n1n1n1n+24.*four1n1n1n1n
1980 + 12.*five2n1n1n1n1n+12.*five2n1n1n1n1n+12.*three2n1n1n+24.*four2n1n2n1n+4.*five3n1n2n1n1n+4.*five2n1n1n1n1n)
1981 - dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(4.*four3n1n1n1n+6.*four4n2n1n1n+12.*four1n1n1n1n+24.*three2n1n1n
1982 + 24.*four2n1n2n1n+12.*four3n1n1n1n+24.*three3n2n1n+8.*four3n1n3n1n+6.*four3n1n2n2n+6.*three2n1n1n+12.*four1n1n1n1n
1983 + 12.*four2n1n2n1n+6.*three2n1n1n+12.*four2n1n2n1n+4.*four3n1n2n2n+3.*four2n2n2n2n+4.*four1n1n1n1n+6.*three2n1n1n
1984 + 24.*two1n1n+24.*four1n1n1n1n+4.*four3n1n1n1n+24.*two1n1n+24.*three2n1n1n+12.*two2n2n+24.*three2n1n1n+12.*four2n1n2n1n
1985 + 8.*three3n2n1n+8.*four2n1n2n1n+1.*four4n2n1n1n)-dMult*(dMult-1.)*(dMult-2.)*(6.*three2n1n1n+1.*three2n1n1n+8.*two1n1n
1986 + 12.*three3n2n1n+24.*two1n1n+12.*three2n1n1n+4.*three2n1n1n+8.*two1n1n+4.*three4n3n1n+24.*three2n1n1n+8.*three3n2n1n
1987 + 12.*two1n1n+12.*two1n1n+3.*three4n2n2n+24.*two2n2n+6.*two2n2n+12.+12.*three3n2n1n+8.*two3n3n+12.*three2n1n1n+24.*two1n1n
1988 + 4.*three3n2n1n+8.*three3n2n1n+2.*three4n3n1n+12.*two1n1n+8.*three2n1n1n+4.*three2n1n1n+2.*three3n2n1n+6.*two2n2n+8.*two2n2n
1989 + 1.*three4n2n2n+4.*three3n2n1n+6.*three2n1n1n)-dMult*(dMult-1.)*(4.*two1n1n+2.*two1n1n+6.*two2n2n+8.+1.*two2n2n+4.*two3n3n
1990 + 12.*two1n1n+4.*two1n1n+1.*two4n4n+8.*two2n2n+6.+2.*two3n3n+4.*two1n1n+1.*two2n2n)-dMult)
1991 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)*(dMult-6.)); // to be improved (direct formula needed)
1992
1993 fQCorrelations->Fill(28.,seven2n1n1n1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)*(dMult-6.));
1994 } // end of if(dMult>6)
ae733b3b 1995
9c1a9547 1996 // 8-particle:
1997 Double_t eight1n1n1n1n1n1n1n1n = 0.; // <cos(n*(phi1+phi2+phi3+phi4-phi5-phi6-phi7-phi8))>
1998 if(dMult>7)
1999 {
2000 eight1n1n1n1n1n1n1n1n = (pow(pow(dReQ1n,2.)+pow(dImQ1n,2.),4.)-dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)*(dMult-6.)
2001 * (12.*seven2n1n1n1n1n1n1n+16.*six1n1n1n1n1n1n)-dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)
2002 * (8.*six3n1n1n1n1n1n+48.*six1n1n1n1n1n1n+6.*six2n2n1n1n1n1n+96.*five2n1n1n1n1n+72.*four1n1n1n1n+36.*six2n1n1n2n1n1n)
2003 - dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(2.*five4n1n1n1n1n+32.*five2n1n1n1n1n+36.*four1n1n1n1n
2004 + 32.*four3n1n1n1n+48.*five2n1n1n1n1n+48.*five3n1n2n1n1n+144.*five2n1n1n1n1n+288.*four1n1n1n1n+36.*five2n2n2n1n1n
2005 + 144.*three2n1n1n+96.*two1n1n+144.*four2n1n2n1n)-dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)
2006 * (8.*four3n1n1n1n+48.*four1n1n1n1n+12.*four4n2n1n1n+96.*four2n1n2n1n+96.*three2n1n1n+72.*three2n1n1n+144.*two1n1n
2007 + 16.*four3n1n3n1n+48.*four3n1n1n1n+144.*four1n1n1n1n+72.*four1n1n1n1n+96.*three3n2n1n+24.*four3n1n2n2n+144.*four2n1n2n1n
2008 + 288.*two1n1n+288.*three2n1n1n+9.*four2n2n2n2n+72.*two2n2n+24.)-dMult*(dMult-1.)*(dMult-2.)*(12.*three2n1n1n+16.*two1n1n
2009 + 24.*three3n2n1n+48.*three2n1n1n+96.*two1n1n+8.*three4n3n1n+32.*three3n2n1n+96.*three2n1n1n+144.*two1n1n+6.*three4n2n2n
2010 + 96.*two2n2n+36.*two2n2n+72.+48.*three3n2n1n+16.*two3n3n+72.*three2n1n1n+144.*two1n1n)-dMult*(dMult-1.)*(8.*two1n1n
2011 + 12.*two2n2n+16.+8.*two3n3n+48.*two1n1n+1.*two4n4n+16.*two2n2n+18.)-dMult)
2012 / (dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)*(dMult-6.)*(dMult-7.)); // to be improved (direct formula needed)
2013
2014 fQCorrelations->Fill(30.,eight1n1n1n1n1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)*(dMult-6.)*(dMult-7.));
ae733b3b 2015
9c1a9547 2016 // distribution of <cos(n*(phi1+phi2+phi3+phi4-phi5-phi6-phi7-phi8))>
2017 f8pDistribution->Fill(eight1n1n1n1n1n1n1n1n,dMult*(dMult-1.)*(dMult-2.)*(dMult-3.)*(dMult-4.)*(dMult-5.)*(dMult-6.)*(dMult-7.));
2018
2019 } // end of if(dMult>7)
1dfa3c16 2020
9c1a9547 2021} // end of AliFlowAnalysisWithQCumulants::CalculateCorrelationsForIntegratedFlow()
bc92c0cb 2022
2023
9c1a9547 2024//================================================================================================================================
bc92c0cb 2025
2026
9c1a9547 2027void AliFlowAnalysisWithQCumulants::CalculateWeightedCorrelationsForIntegratedFlow()
2028{
2029 // calculate all weighted correlations needed for 'no-name' integrated flow and store them in 1D profile fQCorrelationsW
2030
2031 // Remark 1: binning of fQCorrelationsW is organized as follows:
2032 //..............................................................................................
2033 // ---- bins 1-20: 2-particle correlations ----
2034 // 1st bin: two1n1nW1W1 = <w1 w2 cos(n*(phi1-phi2))>
2035 // 2nd bin: two2n2nW2W2 = <w1^2 w2^2 cos(2n*(phi1-phi2))>
2036 // 3rd bin: two3n3nW3W3 = <w1^3 w2^3 cos(3n*(phi1-phi2))>
2037 // 4th bin: two4n4nW4W4 = <w1^4 w2^4 cos(4n*(phi1-phi2))>
2038 // 5th bin: two1n1nW3W1 = <w1^3 w2 cos(n*(phi1-phi2))>
2039 // 6th bin: two1n1nW1W1W2 = <w1 w2 w3^2 cos(n*(phi1-phi2))>
2040 // ---- bins 21-40: 3-particle correlations ----
2041 // 21st bin: three2n1n1nW2W1W1 = <w1^2 w2 w3 cos(n*(2phi1-phi2-phi3))>
2042 // ---- bins 41-60: 4-particle correlations ----
2043 // 41st bin: four1n1n1n1nW1W1W1W1 = <w1 w2 w3 w4 cos(n*(phi1+phi2-phi3-phi4))>
2044 // ---- bins 61-80: 5-particle correlations ----
2045 // ---- bins 81-100: 6-particle correlations ----
2046 // ---- bins 101-120: 7-particle correlations ----
2047 // ---- bins 121-140: 8-particle correlations ----
2048 //..............................................................................................
2049
2050 // multiplicity (number of particles used to determine the reaction plane)
2051 Double_t dMult = (*fSMpk)(0,0);
2052
2053 // real and imaginary parts of weighted Q-vectors evaluated in harmonics n, 2n, 3n and 4n:
2054 Double_t dReQ1n1k = (*fReQ)(0,1);
2055 Double_t dReQ2n2k = (*fReQ)(1,2);
2056 Double_t dReQ3n3k = (*fReQ)(2,3);
2057 Double_t dReQ4n4k = (*fReQ)(3,4);
2058 Double_t dReQ1n3k = (*fReQ)(0,3);
2059 Double_t dImQ1n1k = (*fImQ)(0,1);
2060 Double_t dImQ2n2k = (*fImQ)(1,2);
2061 Double_t dImQ3n3k = (*fImQ)(2,3);
2062 Double_t dImQ4n4k = (*fImQ)(3,4);
2063 Double_t dImQ1n3k = (*fImQ)(0,3);
2064
2065 // dMs are variables introduced in order to simplify some Eqs. bellow:
2066 //..............................................................................................
2067 Double_t dM11 = (*fSMpk)(1,1)-(*fSMpk)(0,2); // dM11 = sum_{i,j=1,i!=j}^M w_i w_j
2068 Double_t dM22 = (*fSMpk)(1,2)-(*fSMpk)(0,4); // dM22 = sum_{i,j=1,i!=j}^M w_i^2 w_j^2
2069 Double_t dM33 = (*fSMpk)(1,3)-(*fSMpk)(0,6); // dM33 = sum_{i,j=1,i!=j}^M w_i^3 w_j^3
2070 Double_t dM44 = (*fSMpk)(1,4)-(*fSMpk)(0,8); // dM44 = sum_{i,j=1,i!=j}^M w_i^4 w_j^4
2071 Double_t dM31 = (*fSMpk)(0,3)*(*fSMpk)(0,1)-(*fSMpk)(0,4); // dM31 = sum_{i,j=1,i!=j}^M w_i^3 w_j
2072 Double_t dM211 = (*fSMpk)(0,2)*(*fSMpk)(1,1)-2.*(*fSMpk)(0,3)*(*fSMpk)(0,1)
2073 - (*fSMpk)(1,2)+2.*(*fSMpk)(0,4); // dM211 = sum_{i,j,k=1,i!=j!=k}^M w_i^2 w_j w_k
2074 Double_t dM1111 = (*fSMpk)(3,1)-6.*(*fSMpk)(0,2)*(*fSMpk)(1,1)
2075 + 8.*(*fSMpk)(0,3)*(*fSMpk)(0,1)
2076 + 3.*(*fSMpk)(1,2)-6.*(*fSMpk)(0,4); // dM1111 = sum_{i,j,k,l=1,i!=j!=k!=l}^M w_i w_j w_k w_l
2077 //..............................................................................................
bc92c0cb 2078
2079
9c1a9547 2080
bc92c0cb 2081
9c1a9547 2082 // ***********************************************
2083 // **** weighted multi-particle correlations: ****
2084 // ***********************************************
2085 //..............................................................................................
2086 // weighted 2-particle correlations:
2087 Double_t two1n1nW1W1 = 0.; // <w1 w2 cos(n*(phi1-phi2))>
2088 Double_t two2n2nW2W2 = 0.; // <w1^2 w2^2 cos(2n*(phi1-phi2))>
2089 Double_t two3n3nW3W3 = 0.; // <w1^3 w2^3 cos(3n*(phi1-phi2))>
2090 Double_t two4n4nW4W4 = 0.; // <w1^4 w2^4 cos(4n*(phi1-phi2))>
2091 Double_t two1n1nW3W1 = 0.; // <w1^3 w2 cos(n*(phi1-phi2))>
2092 Double_t two1n1nW1W1W2 = 0.; // <w1 w2 w3^2 cos(n*(phi1-phi2))>
2093
2094 if(dMult>1)
2095 {
2096 if(dM11)
2097 {
2098 two1n1nW1W1 = (pow(dReQ1n1k,2)+pow(dImQ1n1k,2)-(*fSMpk)(0,2))/dM11;
2099 fQCorrelationsW->Fill(0.,two1n1nW1W1,dM11);
2100 }
2101 if(dM22)
2102 {
2103 two2n2nW2W2 = (pow(dReQ2n2k,2)+pow(dImQ2n2k,2)-(*fSMpk)(0,4))/dM22;
2104 fQCorrelationsW->Fill(1.,two2n2nW2W2,dM22);
2105 }
2106 if(dM33)
2107 {
2108 two3n3nW3W3 = (pow(dReQ3n3k,2)+pow(dImQ3n3k,2)-(*fSMpk)(0,6))/dM33;
2109 fQCorrelationsW->Fill(2.,two3n3nW3W3,dM33);
2110 }
2111 if(dM44)
2112 {
2113 two4n4nW4W4 = (pow(dReQ4n4k,2)+pow(dImQ4n4k,2)-(*fSMpk)(0,8))/dM44;
2114 fQCorrelationsW->Fill(3.,two4n4nW4W4,dM44);
2115 }
2116 if(dM31)
2117 {
2118 two1n1nW3W1 = (dReQ1n3k*dReQ1n1k+dImQ1n3k*dImQ1n1k-(*fSMpk)(0,4))/dM31;
2119 fQCorrelationsW->Fill(4.,two1n1nW3W1,dM31);
2120 }
2121 if(dM211)
2122 {
2123 two1n1nW1W1W2 = ((*fSMpk)(0,2)*(pow(dReQ1n1k,2)+pow(dImQ1n1k,2)-(*fSMpk)(0,2))
2124 - 2.*(dReQ1n3k*dReQ1n1k+dImQ1n3k*dImQ1n1k
2125 - (*fSMpk)(0,4)))/dM211;
2126 fQCorrelationsW->Fill(5.,two1n1nW1W1W2,dM211);
2127 }
2128 } // end of if(dMult>1)
2129 //..............................................................................................
2130
2131 //..............................................................................................
2132 // weighted 3-particle correlations:
2133 Double_t three2n1n1nW2W1W1 = 0.; // <w1^2 w2 w3 cos(n*(2phi1-phi2-phi3))>
2134
2135 if(dMult>2)
2136 {
2137 if(dM211)
2138 {
2139 three2n1n1nW2W1W1 = (pow(dReQ1n1k,2.)*dReQ2n2k+2.*dReQ1n1k*dImQ1n1k*dImQ2n2k-pow(dImQ1n1k,2.)*dReQ2n2k
2140 - 2.*(dReQ1n3k*dReQ1n1k+dImQ1n3k*dImQ1n1k)
2141 - pow(dReQ2n2k,2)-pow(dImQ2n2k,2)
2142 + 2.*(*fSMpk)(0,4))/dM211;
2143 fQCorrelationsW->Fill(20.,three2n1n1nW2W1W1,dM211);
2144 }
2145 } // end of if(dMult>2)
2146 //..............................................................................................
2147
2148 //..............................................................................................
2149 // weighted 4-particle correlations:
2150 Double_t four1n1n1n1nW1W1W1W1 = 0.; // <w1 w2 w3 w4 cos(n*(phi1+phi2-phi3-phi4))>
2151 if(dMult>3)
2152 {
2153 if(dM1111)
2154 {
2155 four1n1n1n1nW1W1W1W1 = (pow(pow(dReQ1n1k,2.)+pow(dImQ1n1k,2.),2)
2156 - 2.*(pow(dReQ1n1k,2.)*dReQ2n2k+2.*dReQ1n1k*dImQ1n1k*dImQ2n2k-pow(dImQ1n1k,2.)*dReQ2n2k)
2157 + 8.*(dReQ1n3k*dReQ1n1k+dImQ1n3k*dImQ1n1k)
2158 + (pow(dReQ2n2k,2)+pow(dImQ2n2k,2))
2159 - 4.*(*fSMpk)(0,2)*(pow(dReQ1n1k,2)+pow(dImQ1n1k,2))
2160 - 6.*(*fSMpk)(0,4)+2.*(*fSMpk)(1,2))/dM1111;
2161 fQCorrelationsW->Fill(40.,four1n1n1n1nW1W1W1W1,dM1111);
2162 }
2163 } // end of if(dMult>3)
2164 //..............................................................................................
2165
2166} // end of AliFlowAnalysisWithQCumulants::CalculateWeightedCorrelationsForIntegratedFlow()
bc92c0cb 2167
2168
9c1a9547 2169//================================================================================================================================
bc92c0cb 2170
2171
9c1a9547 2172void AliFlowAnalysisWithQCumulants::CalculateCorrelationsForDifferentialFlow(TString type)
2173{
2174 // calculate all correlations needed for differential flow for each (pt,eta) bin:
2175
2176 // pt and eta bin width:
2177 Double_t dBinWidthPt = 0.; // to be improved (should I promote this variable to data members?)
2178 Double_t dBinWidthEta = 0.; // to be improved (should I promote this variable to data members?)
2179
2180 if(fnBinsPt) dBinWidthPt=(fPtMax-fPtMin)/fnBinsPt;
2181 if(fnBinsEta) dBinWidthEta=(fEtaMax-fEtaMin)/fnBinsEta;
2182
2183 // multiplicity:
2184 Double_t dMult = (*fSMpk)(0,0);
2185
2186 // real and imaginary parts of non-weighted Q-vectors evaluated in harmonics n, 2n, 3n and 4n:
2187 Double_t dReQ1n = (*fReQ)(0,0);
2188 Double_t dReQ2n = (*fReQ)(1,0);
2189 //Double_t dReQ3n = (*fReQ)(2,0);
2190 //Double_t dReQ4n = (*fReQ)(3,0);
2191 Double_t dImQ1n = (*fImQ)(0,0);
2192 Double_t dImQ2n = (*fImQ)(1,0);
2193 //Double_t dImQ3n = (*fImQ)(2,0);
2194 //Double_t dImQ4n = (*fImQ)(3,0);
2195
2196 // looping over all (pt,eta) bins and calculating correlations needed for differential flow:
2197 for(Int_t p=1;p<=fnBinsPt;p++)
2198 {
2199 for(Int_t e=1;e<=fnBinsEta;e++)
2200 {
2201 // real and imaginary parts of q_n (non-weighted Q-vector evaluated only for POIs in harmonic n for each (pt,eta) bin):
2202 Double_t dReqnPtEta = 0.;
2203 Double_t dImqnPtEta = 0.;
2204
2205 // number of POIs in each (pt,eta) bin:
2206 Double_t dmPtEta = 0.;
2207
2208 // real and imaginary parts of q''_{n}, q''_{2n}, ...
2209 // (non-weighted Q-vectors evaluated only for particles which are both RPs and POIs in harmonic n, 2n, ... for each (pt,eta) bin):
2210 Double_t dReqPrimePrime1nPtEta = 0.;
2211 Double_t dImqPrimePrime1nPtEta = 0.;
2212 Double_t dReqPrimePrime2nPtEta = 0.;
2213 Double_t dImqPrimePrime2nPtEta = 0.;
2214
2215 // number of particles which are both RPs and POIs in each (pt,eta) bin:
2216 Double_t dmPrimePrimePtEta = 0.;
2217
2218 if(type == "POI")
2219 {
2220 // q''_{n}, q''_{2n}:
2221 //...............................................................................................
2222 dReqPrimePrime1nPtEta = fReqPrimePrime1nPtEta->GetBinContent(fReqPrimePrime1nPtEta->GetBin(p,e));
2223 dImqPrimePrime1nPtEta = fImqPrimePrime1nPtEta->GetBinContent(fImqPrimePrime1nPtEta->GetBin(p,e));
2224 dReqPrimePrime2nPtEta = fReqPrimePrime2nPtEta->GetBinContent(fReqPrimePrime2nPtEta->GetBin(p,e));
2225 dImqPrimePrime2nPtEta = fImqPrimePrime2nPtEta->GetBinContent(fImqPrimePrime2nPtEta->GetBin(p,e));
2226 //...............................................................................................
2227
2228 // m'':
2229 dmPrimePrimePtEta = fmPrimePrimePtEta->GetBinContent(fmPrimePrimePtEta->GetBin(p,e));
2230
2231 // q'_{n}:
2232 dReqnPtEta = fReqnPtEta->GetBinContent(fReqnPtEta->GetBin(p,e));
2233 dImqnPtEta = fImqnPtEta->GetBinContent(fImqnPtEta->GetBin(p,e));
2234 dmPtEta = fmPtEta->GetBinContent(fmPtEta->GetBin(p,e));
2235 }
2236 else if(type == "RP")
2237 {
2238 // q_RP{n}, q_RP{2n}:
2239 //...............................................................................................
2240 dReqPrimePrime1nPtEta = fReqRP1nPtEta->GetBinContent(fReqRP1nPtEta->GetBin(p,e));
2241 dImqPrimePrime1nPtEta = fImqRP1nPtEta->GetBinContent(fImqRP1nPtEta->GetBin(p,e));
2242 dReqPrimePrime2nPtEta = fReqRP2nPtEta->GetBinContent(fReqRP2nPtEta->GetBin(p,e));
2243 dImqPrimePrime2nPtEta = fImqRP2nPtEta->GetBinContent(fImqRP2nPtEta->GetBin(p,e));
2244 //...............................................................................................
2245
2246 // m'':
2247 dmPrimePrimePtEta = fmRPPtEta->GetBinContent(fmRPPtEta->GetBin(p,e));
2248
2249 dReqnPtEta = fReqRP1nPtEta->GetBinContent(fReqRP1nPtEta->GetBin(p,e)); // not a bug ;-)
2250 dImqnPtEta = fImqRP1nPtEta->GetBinContent(fImqRP1nPtEta->GetBin(p,e)); // not a bug ;-)
2251 dmPtEta = fmRPPtEta->GetBinContent(fmRPPtEta->GetBin(p,e)); // not a bug ;-)
2252 }
2253
2254 // 2'-particle correlation:
2255 Double_t two1n1nPtEta = 0.;
2256 if(dmPtEta*dMult-dmPrimePrimePtEta)
2257 {
2258 two1n1nPtEta = (dReqnPtEta*dReQ1n+dImqnPtEta*dImQ1n-dmPrimePrimePtEta)
2259 / (dmPtEta*dMult-dmPrimePrimePtEta);
2260
2261 // fill the 2D profile to get the average correlation for each (pt, eta) bin:
2262 if(type == "POI")
2263 {
2264 f2pPtEtaPOI->Fill(fPtMin+(p-1)*dBinWidthPt,fEtaMin+(e-1)*dBinWidthEta,two1n1nPtEta,dmPtEta*dMult-dmPrimePrimePtEta);
2265 }
2266 else if(type == "RP")
2267 {
2268 f2pPtEtaRP->Fill(fPtMin+(p-1)*dBinWidthPt,fEtaMin+(e-1)*dBinWidthEta,two1n1nPtEta,dmPtEta*dMult-dmPrimePrimePtEta);
2269 }
2270 } // end of if(dmPtEta*dMult-dmPrimePrimePtEta)
2271
2272 // 4'-particle correlation:
2273 Double_t four1n1n1n1nPtEta = 0.;
2274 if((dmPtEta-dmPrimePrimePtEta)*dMult*(dMult-1.)*(dMult-2.)
2275 + dmPrimePrimePtEta*(dMult-1.)*(dMult-2.)*(dMult-3.)) // to be improved (introduce a new variable for this expression)
2276 {
2277 four1n1n1n1nPtEta = ((pow(dReQ1n,2.)+pow(dImQ1n,2.))*(dReqnPtEta*dReQ1n+dImqnPtEta*dImQ1n)
2278 - dReqPrimePrime2nPtEta*(pow(dReQ1n,2.)-pow(dImQ1n,2.))
2279 - 2.*dImqPrimePrime2nPtEta*dReQ1n*dImQ1n
2280 - dReqnPtEta*(dReQ1n*dReQ2n+dImQ1n*dImQ2n)
2281 + dImqnPtEta*(dImQ1n*dReQ2n-dReQ1n*dImQ2n)
2282 - 2.*dMult*(dReqnPtEta*dReQ1n+dImqnPtEta*dImQ1n)
2283 - 2.*(pow(dReQ1n,2.)+pow(dImQ1n,2.))*dmPrimePrimePtEta
2284 + 6.*(dReqPrimePrime1nPtEta*dReQ1n+dImqPrimePrime1nPtEta*dImQ1n)
2285 + 1.*(dReqPrimePrime2nPtEta*dReQ2n+dImqPrimePrime2nPtEta*dImQ2n)
2286 + 2.*(dReqnPtEta*dReQ1n+dImqnPtEta*dImQ1n)
2287 + 2.*dmPrimePrimePtEta*dMult
2288 - 6.*dmPrimePrimePtEta)
2289 / ((dmPtEta-dmPrimePrimePtEta)*dMult*(dMult-1.)*(dMult-2.)
2290 + dmPrimePrimePtEta*(dMult-1.)*(dMult-2.)*(dMult-3.));
2291
2292 // fill the 2D profile to get the average correlation for each (pt, eta) bin:
2293 if(type == "POI")
2294 {
2295 f4pPtEtaPOI->Fill(fPtMin+(p-1)*dBinWidthPt,fEtaMin+(e-1)*dBinWidthEta,four1n1n1n1nPtEta,
2296 (dmPtEta-dmPrimePrimePtEta)*dMult*(dMult-1.)*(dMult-2.)
2297 + dmPrimePrimePtEta*(dMult-1.)*(dMult-2.)*(dMult-3.));
2298 }
2299 else if(type == "RP")
2300 {
2301 f4pPtEtaRP->Fill(fPtMin+(p-1)*dBinWidthPt,fEtaMin+(e-1)*dBinWidthEta,four1n1n1n1nPtEta,
2302 (dmPtEta-dmPrimePrimePtEta)*dMult*(dMult-1.)*(dMult-2.)
2303 + dmPrimePrimePtEta*(dMult-1.)*(dMult-2.)*(dMult-3.));
2304 }
2305 } // end of if((dmPtEta-dmPrimePrimePtEta)*dMult*(dMult-1.)*(dMult-2.)
2306 // +dmPrimePrimePtEta*(dMult-1.)*(dMult-2.)*(dMult-3.))
2307
2308 } // end of for(Int_t e=1;e<=fnBinsEta;e++)
2309 } // end of for(Int_t p=1;p<=fnBinsPt;p++)
2310
2311} // end of AliFlowAnalysisWithQCumulants::CalculateCorrelationsForDifferentialFlow()
bc92c0cb 2312
bc92c0cb 2313
9c1a9547 2314//================================================================================================================================
bc92c0cb 2315
2316
9c1a9547 2317void AliFlowAnalysisWithQCumulants::CalculateWeightedCorrelationsForDifferentialFlow(TString type)
2318{
2319 // calculate all weighted correlations needed for differential flow
2320
2321 // pt and eta bin width:
2322 Double_t dBinWidthPt = 0.; // to be improved (should I promote this variable to data members?)
2323 Double_t dBinWidthEta = 0.; // to be improved (should I promote this variable to data members?)
2324
2325 if(fnBinsPt) dBinWidthPt=(fPtMax-fPtMin)/fnBinsPt;
2326 if(fnBinsEta) dBinWidthEta=(fEtaMax-fEtaMin)/fnBinsEta;
2327
2328 // real and imaginary parts of weighted Q-vectors evaluated in harmonics n, 2n, 3n and 4n:
2329 Double_t dReQ1n1k = (*fReQ)(0,1);
2330 Double_t dReQ2n2k = (*fReQ)(1,2);
2331 Double_t dReQ1n3k = (*fReQ)(0,3);
2332 //Double_t dReQ4n4k = (*fReQ)(3,4);
2333 Double_t dImQ1n1k = (*fImQ)(0,1);
2334 Double_t dImQ2n2k = (*fImQ)(1,2);
2335 Double_t dImQ1n3k = (*fImQ)(0,3);
2336 //Double_t dImQ4n4k = (*fImQ)(3,4);
2337
2338 // S^M_{p,k} (see .h file for the definition of fSMpk):
2339 Double_t dSM1p1k = (*fSMpk)(0,1);
2340 Double_t dSM1p2k = (*fSMpk)(0,2);
2341 Double_t dSM1p3k = (*fSMpk)(0,3);
2342 Double_t dSM2p1k = (*fSMpk)(1,1);
2343 Double_t dSM3p1k = (*fSMpk)(2,1);
2344
2345 // looping over all (pt,eta) bins and calculating weighted correlations needed for differential flow:
2346 for(Int_t p=1;p<=fnBinsPt;p++)
2347 {
2348 for(Int_t e=1;e<=fnBinsEta;e++)
2349 {
2350 // real and imaginary parts of q_n (non-weighted Q-vector evaluated only for POIs in harmonic n for each (pt,eta) bin):
2351 Double_t dReqnPtEta = 0.;
2352 Double_t dImqnPtEta = 0.;
2353
2354 // number of POIs in each (pt,eta) bin:
2355 Double_t dmPtEta = 0.;
2356
2357 // real and imaginary parts of q''_{n,2k}, q''_{2n,1k}, ...
2358 // (weighted Q-vectors evaluated only for particles which are both RPs and POIs in harmonic n, 2n, ... for each (pt,eta) bin):
2359 Double_t dReqPrimePrime1n2kPtEta = 0.;
2360 Double_t dImqPrimePrime1n2kPtEta = 0.;
2361 Double_t dReqPrimePrime2n1kPtEta = 0.;
2362 Double_t dImqPrimePrime2n1kPtEta = 0.;
2363
2364 // S^{m''}_{1,1}, S^{m''}_{1,2}, S^{m''}_{1,3}... (see .h file for the definition):
2365 Double_t dSmPrimePrime1p1kPtEta = 0.;
2366 Double_t dSmPrimePrime1p2kPtEta = 0.;
2367 Double_t dSmPrimePrime1p3kPtEta = 0.;
2368
2369 // M0111 from Eq. (118) in QC2c (to be improved (notation))
2370 Double_t dM0111 = 0.;
2371
2372 // qPOI_{n}: // to be improved (notation)
2373 if(type == "POI")
2374 {
2375 dReqnPtEta = fReqnPtEta->GetBinContent(fReqnPtEta->GetBin(p,e));
2376 dImqnPtEta = fImqnPtEta->GetBinContent(fImqnPtEta->GetBin(p,e));
2377 dmPtEta = fmPtEta->GetBinContent(fmPtEta->GetBin(p,e));
2378
2379 //...............................................................................................
2380 // q''_{n,2k}, q''_{2n,1k}:
2381 dReqPrimePrime1n2kPtEta = fReqPrimePrime1n2kPtEta->GetBinContent(fReqPrimePrime1n2kPtEta->GetBin(p,e));
2382 dImqPrimePrime1n2kPtEta = fImqPrimePrime1n2kPtEta->GetBinContent(fImqPrimePrime1n2kPtEta->GetBin(p,e));
2383 dReqPrimePrime2n1kPtEta = fReqPrimePrime2n1kPtEta->GetBinContent(fReqPrimePrime2n1kPtEta->GetBin(p,e));
2384 dImqPrimePrime2n1kPtEta = fImqPrimePrime2n1kPtEta->GetBinContent(fImqPrimePrime2n1kPtEta->GetBin(p,e));
2385
2386 // S^{m''}_{1,1}, S^{m''}_{1,2}, S^{m''}_{1,3}...:
2387 dSmPrimePrime1p1kPtEta = fSmPrimePrime1p1kPtEta->GetBinContent(fSmPrimePrime1p1kPtEta->GetBin(p,e));
2388 dSmPrimePrime1p2kPtEta = fSmPrimePrime1p2kPtEta->GetBinContent(fSmPrimePrime1p2kPtEta->GetBin(p,e));
2389 dSmPrimePrime1p3kPtEta = fSmPrimePrime1p3kPtEta->GetBinContent(fSmPrimePrime1p3kPtEta->GetBin(p,e));
2390
2391 // M0111 from Eq. (118) in QC2c (to be improved (notation)):
2392 dM0111 = dmPtEta*(dSM3p1k-3.*dSM1p1k*dSM1p2k+2.*dSM1p3k)
2393 - 3.*(dSmPrimePrime1p1kPtEta*(dSM2p1k-dSM1p2k)
2394 + 2.*(dSmPrimePrime1p3kPtEta-dSmPrimePrime1p2kPtEta*dSM1p1k));
2395 //...............................................................................................
2396 }
2397 else if(type == "RP")
2398 {
2399 dReqnPtEta = fReqRP1nPtEta->GetBinContent(fReqRP1nPtEta->GetBin(p,e)); // not a bug ;-)
2400 dImqnPtEta = fImqRP1nPtEta->GetBinContent(fImqRP1nPtEta->GetBin(p,e)); // not a bug ;-)
2401 dmPtEta = fmRPPtEta->GetBinContent(fmRPPtEta->GetBin(p,e)); // not a bug ;-)
2402
2403 //...............................................................................................
2404 // q''_{n,2k}, q''_{2n,1k}: (to be improved (notation)):
2405 dReqPrimePrime1n2kPtEta = fReqRP1n2kPtEta->GetBinContent(fReqRP1n2kPtEta->GetBin(p,e));
2406 dImqPrimePrime1n2kPtEta = fImqRP1n2kPtEta->GetBinContent(fImqRP1n2kPtEta->GetBin(p,e));
2407 dReqPrimePrime2n1kPtEta = fReqRP2n1kPtEta->GetBinContent(fReqRP2n1kPtEta->GetBin(p,e));
2408 dImqPrimePrime2n1kPtEta = fImqRP2n1kPtEta->GetBinContent(fImqRP2n1kPtEta->GetBin(p,e));
2409
2410 // S^{m''}_{1,1}, S^{m''}_{1,2}, S^{m''}_{1,3}...: (to be improved (notation)):
2411 dSmPrimePrime1p1kPtEta = fSmRP1p1kPtEta->GetBinContent(fSmRP1p1kPtEta->GetBin(p,e));
2412 dSmPrimePrime1p2kPtEta = fSmRP1p2kPtEta->GetBinContent(fSmRP1p2kPtEta->GetBin(p,e));
2413 dSmPrimePrime1p3kPtEta = fSmRP1p3kPtEta->GetBinContent(fSmRP1p3kPtEta->GetBin(p,e));
2414
2415 // M0111 from Eq. (118) in QC2c (to be improved (notation)):
2416 dM0111 = dmPtEta*(dSM3p1k-3.*dSM1p1k*dSM1p2k+2.*dSM1p3k)
2417 - 3.*(dSmPrimePrime1p1kPtEta*(dSM2p1k-dSM1p2k)
2418 + 2.*(dSmPrimePrime1p3kPtEta-dSmPrimePrime1p2kPtEta*dSM1p1k));
2419 //...............................................................................................
2420 }
2421
2422 // 2'-particle correlation:
2423 Double_t two1n1nW0W1PtEta = 0.;
2424 if(dmPtEta*dSM1p1k-dSmPrimePrime1p1kPtEta)
2425 {
2426 two1n1nW0W1PtEta = (dReqnPtEta*dReQ1n1k+dImqnPtEta*dImQ1n1k-dSmPrimePrime1p1kPtEta)
2427 / (dmPtEta*dSM1p1k-dSmPrimePrime1p1kPtEta);
2428
2429 // fill the 2D profile to get the average correlation for each (pt, eta) bin:
2430 if(type == "POI")
2431 {
2432 f2pPtEtaPOIW->Fill(fPtMin+(p-1)*dBinWidthPt,fEtaMin+(e-1)*dBinWidthEta,two1n1nW0W1PtEta,
2433 dmPtEta*dSM1p1k-dSmPrimePrime1p1kPtEta);
2434 }
2435 else if(type == "RP")
2436 {
2437 f2pPtEtaRPW->Fill(fPtMin+(p-1)*dBinWidthPt,fEtaMin+(e-1)*dBinWidthEta,two1n1nW0W1PtEta,
2438 dmPtEta*dSM1p1k-dSmPrimePrime1p1kPtEta);
2439 }
2440 } // end of if(dmPtEta*dMult-dmPrimePrimePtEta)
2441
2442 // 4'-particle correlation:
2443 Double_t four1n1n1n1nW0W1W1W1PtEta = 0.;
2444 if(dM0111)
2445 {
2446 four1n1n1n1nW0W1W1W1PtEta = ((pow(dReQ1n1k,2.)+pow(dImQ1n1k,2.))*(dReqnPtEta*dReQ1n1k+dImqnPtEta*dImQ1n1k)
2447 - dReqPrimePrime2n1kPtEta*(pow(dReQ1n1k,2.)-pow(dImQ1n1k,2.))
2448 - 2.*dImqPrimePrime2n1kPtEta*dReQ1n1k*dImQ1n1k
2449 - dReqnPtEta*(dReQ1n1k*dReQ2n2k+dImQ1n1k*dImQ2n2k)
2450 + dImqnPtEta*(dImQ1n1k*dReQ2n2k-dReQ1n1k*dImQ2n2k)
2451 - 2.*dSM1p2k*(dReqnPtEta*dReQ1n1k+dImqnPtEta*dImQ1n1k)
2452 - 2.*(pow(dReQ1n1k,2.)+pow(dImQ1n1k,2.))*dSmPrimePrime1p1kPtEta
2453 + 6.*(dReqPrimePrime1n2kPtEta*dReQ1n1k+dImqPrimePrime1n2kPtEta*dImQ1n1k)
2454 + 1.*(dReqPrimePrime2n1kPtEta*dReQ2n2k+dImqPrimePrime2n1kPtEta*dImQ2n2k)
2455 + 2.*(dReqnPtEta*dReQ1n3k+dImqnPtEta*dImQ1n3k)
2456 + 2.*dSmPrimePrime1p1kPtEta*dSM1p2k
2457 - 6.*dSmPrimePrime1p3kPtEta)
2458 / dM0111; // to be imropoved (notation of dM0111)
2459
2460 // fill the 2D profile to get the average correlation for each (pt, eta) bin:
2461 if(type == "POI")
2462 {
2463 f4pPtEtaPOIW->Fill(fPtMin+(p-1)*dBinWidthPt,fEtaMin+(e-1)*dBinWidthEta,four1n1n1n1nW0W1W1W1PtEta,dM0111);
2464 }
2465 else if(type == "RP")
2466 {
2467 f4pPtEtaRPW->Fill(fPtMin+(p-1)*dBinWidthPt,fEtaMin+(e-1)*dBinWidthEta,four1n1n1n1nW0W1W1W1PtEta,dM0111);
2468 }
2469 } // end of if(dM0111)
2470
2471 } // end of for(Int_t e=1;e<=fnBinsEta;e++)
2472 } // end of for(Int_t p=1;p<=fnBinsPt;p++)
2473
2474} // end of AliFlowAnalysisWithQCumulants::CalculateWeightedCorrelationsForDifferentialFlow(TString type)
bc92c0cb 2475
2476
9c1a9547 2477//================================================================================================================================
bc92c0cb 2478
2479
9c1a9547 2480void AliFlowAnalysisWithQCumulants::EvaluateNestedLoopsForIntegratedFlow(AliFlowEventSimple* anEvent)
2481{
2482 // evaluate the nested loops relevant for integrated flow (needed for cross-checking the results)
3d824203 2483
9c1a9547 2484 Int_t nPrim = anEvent->NumberOfTracks();
dee1e0e0 2485
9c1a9547 2486 TH1F *phiWeights = NULL; // histogram with phi weights
2487 Int_t nBinsPhi = 0;
3d824203 2488
9c1a9547 2489 if(fUsePhiWeights)
2490 {
2491 if(!fWeightsList)
2492 {
2493 cout<<" WARNING: fWeightsList is NULL pointer in AFAWQC::ENLFIF(). "<<endl;
2494 exit(0);
2495 }
2496 phiWeights = dynamic_cast<TH1F *>(fWeightsList->FindObject("phi_weights"));
2497 if(!phiWeights)
2498 {
2499 cout<<" WARNING: couldn't access the histogram with phi weights in AFAWQC::ENLFIF(). "<<endl;
2500 exit(0);
2501 }
2502 nBinsPhi = phiWeights->GetNbinsX();
2503 }
77515452 2504
9c1a9547 2505 Double_t phi1=0., phi2=0., phi3=0., phi4=0., phi5=0., phi6=0., phi7=0., phi8=0.;
2506 Double_t wPhi1=1., wPhi2=1., wPhi3=1., wPhi4=1., wPhi5=1., wPhi6=1., wPhi7=1., wPhi8=1.;
77515452 2507
9c1a9547 2508 Int_t n=2; // to be improved
77515452 2509
9c1a9547 2510 // ******************************************
2511 // **** NESTED LOOPS FOR INTEGRATED FLOW ****
2512 // ******************************************
2513 //
2514 // Remark 1: multi-particle correlations calculated with nested loops without weights are stored in 1D profile fDirectCorrelations;
2515 // Remark 2: multi-particle correlations calculated with nested loops with weights are stored in 1D profile fDirectCorrelationsW;
2516
2517 // Remark 3: binning of fDirectCorrelations is organized as follows:
2518 // --------------------------------------------------------------------------------------------------------------------
2519 // 1st bin: <2>_{1n|1n} = two1n1n = cos(n*(phi1-phi2))>
2520 // 2nd bin: <2>_{2n|2n} = two2n2n = cos(2n*(phi1-phi2))>
2521 // 3rd bin: <2>_{3n|3n} = two3n3n = cos(3n*(phi1-phi2))>
2522 // 4th bin: <2>_{4n|4n} = two4n4n = cos(4n*(phi1-phi2))>
2523 // 5th bin: ---- EMPTY ----
2524 // 6th bin: <3>_{2n|1n,1n} = three2n1n1n = <cos(n*(2.*phi1-phi2-phi3))>
2525 // 7th bin: <3>_{3n|2n,1n} = three3n2n1n = <cos(n*(3.*phi1-2.*phi2-phi3))>
2526 // 8th bin: <3>_{4n|2n,2n} = three4n2n2n = <cos(n*(4.*phi1-2.*phi2-2.*phi3))>
2527 // 9th bin: <3>_{4n|3n,1n} = three4n3n1n = <cos(n*(4.*phi1-3.*phi2-phi3))>
2528 // 10th bin: ---- EMPTY ----
2529 // 11th bin: <4>_{1n,1n|1n,1n} = four1n1n1n1n = <cos(n*(phi1+phi2-phi3-phi4))>
2530 // 12th bin: <4>_{2n,1n|2n,1n} = four2n1n2n1n = <cos(2.*n*(phi1+phi2-phi3-phi4))>
2531 // 13th bin: <4>_{2n,2n|2n,2n} = four2n2n2n2n = <cos(n*(2.*phi1+phi2-2.*phi3-phi4))>
2532 // 14th bin: <4>_{3n|1n,1n,1n} = four3n1n1n1n = <cos(n*(3.*phi1-phi2-phi3-phi4))>
2533 // 15th bin: <4>_{3n,1n|3n,1n} = four3n1n3n1n = <cos(n*(4.*phi1-2.*phi2-phi3-phi4))>
2534 // 16th bin: <4>_{3n,1n|2n,2n} = four3n1n2n2n = <cos(n*(3.*phi1+phi2-2.*phi3-2.*phi4))>
2535 // 17th bin: <4>_{4n|2n,1n,1n} = four4n2n1n1n = <cos(n*(3.*phi1+phi2-3.*phi3-phi4))>
2536 // 18th bin: ---- EMPTY ----
2537 // 19th bin: <5>_{2n|1n,1n,1n,1n} = five2n1n1n1n1n = <cos(n*(2.*phi1+phi2-phi3-phi4-phi5))>
2538 // 20th bin: <5>_{2n,2n|2n,1n,1n} = five2n2n2n1n1n = <cos(n*(2.*phi1+2.*phi2-2.*phi3-phi4-phi5))>
2539 // 21st bin: <5>_{3n,1n|2n,1n,1n} = five3n1n2n1n1n = <cos(n*(3.*phi1+phi2-2.*phi3-phi4-phi5))>
2540 // 22nd bin: <5>_{4n|1n,1n,1n,1n} = five4n1n1n1n1n = <cos(n*(4.*phi1-phi2-phi3-phi4-phi5))>
2541 // 23rd bin: ---- EMPTY ----
2542 // 24th bin: <6>_{1n,1n,1n|1n,1n,1n} = six1n1n1n1n1n1n = <cos(n*(phi1+phi2+phi3-phi4-phi5-phi6))>
2543 // 25th bin: <6>_{2n,1n,1n|2n,1n,1n} = six2n1n1n2n1n1n = <cos(n*(2.*phi1+2.*phi2-phi3-phi4-phi5-phi6))>
2544 // 26th bin: <6>_{2n,2n|1n,1n,1n,1n} = six2n2n1n1n1n1n = <cos(n*(3.*phi1+phi2-phi3-phi4-phi5-phi6))>
2545 // 27th bin: <6>_{3n,1n|1n,1n,1n,1n} = six3n1n1n1n1n1n = <cos(n*(2.*phi1+phi2+phi3-2.*phi4-phi5-phi6))>
2546 // 28th bin: ---- EMPTY ----
2547 // 29th bin: <7>_{2n,1n,1n|1n,1n,1n,1n} = seven2n1n1n1n1n1n1n = <cos(n*(2.*phi1+phi2+phi3-phi4-phi5-phi6-phi7))>
2548 // 30th bin: ---- EMPTY ----
2549 // 31st bin: <8>_{1n,1n,1n,1n|1n,1n,1n,1n} = eight1n1n1n1n1n1n1n1n = <cos(n*(phi1+phi2+phi3+phi4-phi5-phi6-phi7-phi8))>
2550 // --------------------------------------------------------------------------------------------------------------------
2551
2552 // Remark 4: binning of fDirectCorrelationsW is organized as follows:
2553 //..............................................................................................
2554 // ---- bins 1-20: 2-particle correlations ----
2555 // 1st bin: two1n1nW1W1 = <w1 w2 cos(n*(phi1-phi2))>
2556 // 2nd bin: two2n2nW2W2 = <w1^2 w2^2 cos(2n*(phi1-phi2))>
2557 // 3rd bin: two3n3nW3W3 = <w1^3 w2^3 cos(3n*(phi1-phi2))>
2558 // 4th bin: two4n4nW4W4 = <w1^4 w2^4 cos(4n*(phi1-phi2))>
2559 // 5th bin: two1n1nW3W1 = <w1^3 w2 cos(n*(phi1-phi2))>
2560 // 6th bin: two1n1nW1W1W2 = <w1 w2 w3^2 cos(n*(phi1-phi2))>
2561 // ---- bins 21-40: 3-particle correlations ----
2562 // 21st bin: three2n1n1nW2W1W1 = <w1^2 w2 w3 cos(n*(2phi1-phi2-phi3))>
2563 // ---- bins 41-60: 4-particle correlations ----
2564 // 41st bin: four1n1n1n1nW1W1W1W1 = <w1 w2 w3 w4 cos(n*(phi1+phi2-phi3-phi4))>
2565 // ---- bins 61-80: 5-particle correlations ----
2566 // ---- bins 81-100: 6-particle correlations ----
2567 // ---- bins 101-120: 7-particle correlations ----
2568 // ---- bins 121-140: 8-particle correlations ----
2569 //..............................................................................................
77515452 2570
2571
9c1a9547 2572 // 2-particle correlations:
2573 for(Int_t i1=0;i1<nPrim;i1++)
bc92c0cb 2574 {
dee1e0e0 2575 fTrack=anEvent->GetTrack(i1);
9c1a9547 2576 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2577 phi1=fTrack->Phi();
3d824203 2578 if(phiWeights) wPhi1 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi1*nBinsPhi/TMath::TwoPi())));
9c1a9547 2579 for(Int_t i2=0;i2<nPrim;i2++)
bc92c0cb 2580 {
dee1e0e0 2581 if(i2==i1)continue;
2582 fTrack=anEvent->GetTrack(i2);
9c1a9547 2583 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2584 phi2=fTrack->Phi();
3d824203 2585 if(phiWeights) wPhi2 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi2*nBinsPhi/TMath::TwoPi())));
9c1a9547 2586
2587 // non-weighted:
2588 //------------------------------------------------------------------------------
2589 fDirectCorrelations->Fill(0.,cos(n*(phi1-phi2)),1.); // <cos(n*(phi1-phi2))>
2590 fDirectCorrelations->Fill(1.,cos(2.*n*(phi1-phi2)),1.); // <cos(2n*(phi1-phi2))>
2591 fDirectCorrelations->Fill(2.,cos(3.*n*(phi1-phi2)),1.); // <cos(3n*(phi1-phi2))>
2592 fDirectCorrelations->Fill(3.,cos(4.*n*(phi1-phi2)),1.); // <cos(4n*(phi1-phi2))>
2593 //------------------------------------------------------------------------------
2594
2595 // weighted:
2596 //................................................................................................................
2597 fDirectCorrelationsW->Fill(0.,cos(n*(phi1-phi2)),wPhi1*wPhi2); // <w1 w2 cos( n*(phi1-phi2))>
2598 fDirectCorrelationsW->Fill(1.,cos(2.*n*(phi1-phi2)),pow(wPhi1,2)*pow(wPhi2,2)); // <w1^2 w2^2 cos(2n*(phi1-phi2))>
2599 fDirectCorrelationsW->Fill(2.,cos(3.*n*(phi1-phi2)),pow(wPhi1,3)*pow(wPhi2,3)); // <w1^3 w2^3 cos(3n*(phi1-phi2))>
2600 fDirectCorrelationsW->Fill(3.,cos(4.*n*(phi1-phi2)),pow(wPhi1,4)*pow(wPhi2,4)); // <w1^4 w2^4 cos(4n*(phi1-phi2))>
2601 fDirectCorrelationsW->Fill(4.,cos(n*(phi1-phi2)),pow(wPhi1,3)*wPhi2); // <w1^3 w2 cos(n*(phi1-phi2))>
2602 //................................................................................................................
2603
bc92c0cb 2604 }
2605 }
3d824203 2606
9c1a9547 2607 // 3-particle correlations:
2608 for(Int_t i1=0;i1<nPrim;i1++)
bc92c0cb 2609 {
dee1e0e0 2610 fTrack=anEvent->GetTrack(i1);
9c1a9547 2611 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2612 phi1=fTrack->Phi();
3d824203 2613 if(phiWeights) wPhi1 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi1*nBinsPhi/TMath::TwoPi())));
9c1a9547 2614 for(Int_t i2=0;i2<nPrim;i2++)
bc92c0cb 2615 {
dee1e0e0 2616 if(i2==i1)continue;
2617 fTrack=anEvent->GetTrack(i2);
9c1a9547 2618 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2619 phi2=fTrack->Phi();
3d824203 2620 if(phiWeights) wPhi2 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi2*nBinsPhi/TMath::TwoPi())));
9c1a9547 2621 for(Int_t i3=0;i3<nPrim;i3++)
bc92c0cb 2622 {
dee1e0e0 2623 if(i3==i1||i3==i2)continue;
2624 fTrack=anEvent->GetTrack(i3);
9c1a9547 2625 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2626 phi3=fTrack->Phi();
3d824203 2627 if(phiWeights) wPhi3 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi3*nBinsPhi/TMath::TwoPi())));
3d824203 2628
9c1a9547 2629 // non-weighted:
2630 //-----------------------------------------------------------------------------------
2631 fDirectCorrelations->Fill(5.,cos(2.*n*phi1-n*(phi2+phi3)),1.); //<3>_{2n|nn,n}
2632 fDirectCorrelations->Fill(6.,cos(3.*n*phi1-2.*n*phi2-n*phi3),1.); //<3>_{3n|2n,n}
2633 fDirectCorrelations->Fill(7.,cos(4.*n*phi1-2.*n*phi2-2.*n*phi3),1.); //<3>_{4n|2n,2n}
2634 fDirectCorrelations->Fill(8.,cos(4.*n*phi1-3.*n*phi2-n*phi3),1.); //<3>_{4n|3n,n}
2635 //-----------------------------------------------------------------------------------
3d824203 2636
9c1a9547 2637 // weighted:
2638 //..............................................................................................................................
2639 // 2-p:
2640 fDirectCorrelationsW->Fill(5.,cos(n*(phi1-phi2)),wPhi1*wPhi2*pow(wPhi3,2)); // <w1 w2 w3^2 cos(n*(phi1-phi2))>
3d824203 2641
9c1a9547 2642 // 3-p:
2643 fDirectCorrelationsW->Fill(20.,cos(2.*n*phi1-n*(phi2+phi3)),pow(wPhi1,2)*wPhi2*wPhi3); // <w1^2 w2 w3 cos(n*(2phi1-phi2-phi3))>
2644 //..............................................................................................................................
3d824203 2645
bc92c0cb 2646 }
2647 }
2648 }
3d824203 2649
9c1a9547 2650 // 4-particle correlations:
2651 for(Int_t i1=0;i1<nPrim;i1++)
bc92c0cb 2652 {
dee1e0e0 2653 fTrack=anEvent->GetTrack(i1);
9c1a9547 2654 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2655 phi1=fTrack->Phi();
3d824203 2656 if(phiWeights) wPhi1 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi1*nBinsPhi/TMath::TwoPi())));
9c1a9547 2657 for(Int_t i2=0;i2<nPrim;i2++)
bc92c0cb 2658 {
dee1e0e0 2659 if(i2==i1)continue;
2660 fTrack=anEvent->GetTrack(i2);
9c1a9547 2661 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2662 phi2=fTrack->Phi();
3d824203 2663 if(phiWeights) wPhi2 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi2*nBinsPhi/TMath::TwoPi())));
9c1a9547 2664 for(Int_t i3=0;i3<nPrim;i3++)
bc92c0cb 2665 {
dee1e0e0 2666 if(i3==i1||i3==i2)continue;
2667 fTrack=anEvent->GetTrack(i3);
9c1a9547 2668 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2669 phi3=fTrack->Phi();
3d824203 2670 if(phiWeights) wPhi3 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi3*nBinsPhi/TMath::TwoPi())));
9c1a9547 2671 for(Int_t i4=0;i4<nPrim;i4++)
bc92c0cb 2672 {
dee1e0e0 2673 if(i4==i1||i4==i2||i4==i3)continue;
2674 fTrack=anEvent->GetTrack(i4);
9c1a9547 2675 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2676 phi4=fTrack->Phi();
3d824203 2677 if(phiWeights) wPhi4 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi4*nBinsPhi/TMath::TwoPi())));
3d824203 2678
9c1a9547 2679 // non-weighted:
2680 //-------------------------------------------------------------------------------------------------
2681 fDirectCorrelations->Fill(10.,cos(n*phi1+n*phi2-n*phi3-n*phi4),1.); // <4>_{n,n|n,n}
2682 fDirectCorrelations->Fill(11.,cos(2.*n*phi1+n*phi2-2.*n*phi3-n*phi4),1.); // <4>_{2n,n|2n,n}
2683 fDirectCorrelations->Fill(12.,cos(2.*n*phi1+2*n*phi2-2.*n*phi3-2.*n*phi4),1.); // <4>_{2n,2n|2n,2n}
2684 fDirectCorrelations->Fill(13.,cos(3.*n*phi1-n*phi2-n*phi3-n*phi4),1.); // <4>_{3n|n,n,n}
2685 fDirectCorrelations->Fill(14.,cos(3.*n*phi1+n*phi2-3.*n*phi3-n*phi4),1.); // <4>_{3n,n|3n,n}
2686 fDirectCorrelations->Fill(15.,cos(3.*n*phi1+n*phi2-2.*n*phi3-2.*n*phi4),1.); // <4>_{3n,n|2n,2n}
2687 fDirectCorrelations->Fill(16.,cos(4.*n*phi1-2.*n*phi2-n*phi3-n*phi4),1.); // <4>_{4n|2n,n,n}
2688 //-------------------------------------------------------------------------------------------------
2689
2690 // weighted:
2691 //.......................................................................................
2692 // 4-p:
2693 fDirectCorrelationsW->Fill(40.,cos(n*phi1+n*phi2-n*phi3-n*phi4),wPhi1*wPhi2*wPhi3*wPhi4);
2694 //.......................................................................................
2695
bc92c0cb 2696 }
2697 }
2698 }
2699 }
9c1a9547 2700
2701 // 5-particle correlations:
2702 for(Int_t i1=0;i1<nPrim;i1++)
bc92c0cb 2703 {
dee1e0e0 2704 //cout<<"i1 = "<<i1<<endl;
2705 fTrack=anEvent->GetTrack(i1);
9c1a9547 2706 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2707 phi1=fTrack->Phi();
3d824203 2708 if(phiWeights) wPhi1 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi1*nBinsPhi/TMath::TwoPi())));
9c1a9547 2709 for(Int_t i2=0;i2<nPrim;i2++)
bc92c0cb 2710 {
dee1e0e0 2711 if(i2==i1)continue;
2712 fTrack=anEvent->GetTrack(i2);
9c1a9547 2713 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2714 phi2=fTrack->Phi();
3d824203 2715 if(phiWeights) wPhi2 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi2*nBinsPhi/TMath::TwoPi())));
9c1a9547 2716 for(Int_t i3=0;i3<nPrim;i3++)
bc92c0cb 2717 {
dee1e0e0 2718 if(i3==i1||i3==i2)continue;
2719 fTrack=anEvent->GetTrack(i3);
9c1a9547 2720 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2721 phi3=fTrack->Phi();
3d824203 2722 if(phiWeights) wPhi3 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi3*nBinsPhi/TMath::TwoPi())));
9c1a9547 2723 for(Int_t i4=0;i4<nPrim;i4++)
bc92c0cb 2724 {
dee1e0e0 2725 if(i4==i1||i4==i2||i4==i3)continue;
2726 fTrack=anEvent->GetTrack(i4);
9c1a9547 2727 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2728 phi4=fTrack->Phi();
3d824203 2729 if(phiWeights) wPhi4 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi4*nBinsPhi/TMath::TwoPi())));
9c1a9547 2730 for(Int_t i5=0;i5<nPrim;i5++)
bc92c0cb 2731 {
dee1e0e0 2732 if(i5==i1||i5==i2||i5==i3||i5==i4)continue;
2733 fTrack=anEvent->GetTrack(i5);
9c1a9547 2734 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2735 phi5=fTrack->Phi();
3d824203 2736 if(phiWeights) wPhi5 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi5*nBinsPhi/TMath::TwoPi())));
9c1a9547 2737
2738 // non-weighted:
2739 //------------------------------------------------------------------------------------------------------
2740 fDirectCorrelations->Fill(18.,cos(2.*n*phi1+n*phi2-n*phi3-n*phi4-n*phi5),1.); //<5>_{2n,n|n,n,n}
2741 fDirectCorrelations->Fill(19.,cos(2.*n*phi1+2.*n*phi2-2.*n*phi3-n*phi4-n*phi5),1.); //<5>_{2n,2n|2n,n,n}
2742 fDirectCorrelations->Fill(20.,cos(3.*n*phi1+n*phi2-2.*n*phi3-n*phi4-n*phi5),1.); //<5>_{3n,n|2n,n,n}
2743 fDirectCorrelations->Fill(21.,cos(4.*n*phi1-n*phi2-n*phi3-n*phi4-n*phi5),1.); //<5>_{4n|n,n,n,n}
2744 //------------------------------------------------------------------------------------------------------
2745
2746 // weighted:
2747 //..............................................................................................................
2748 // 5-p:
2749 fDirectCorrelationsW->Fill(60.,cos(2.*n*phi1+n*phi2-n*phi3-n*phi4-n*phi5),pow(wPhi1,2)*wPhi2*wPhi3*wPhi4*wPhi5);
2750 //..............................................................................................................
2751
bc92c0cb 2752 }
2753 }
2754 }
2755 }
2756 }
2757
9c1a9547 2758 // 6-particle correlations:
2759 for(Int_t i1=0;i1<nPrim;i1++)
dee1e0e0 2760 {
2761 //cout<<"i1 = "<<i1<<endl;
2762 fTrack=anEvent->GetTrack(i1);
9c1a9547 2763 if(!(fTrack->InRPSelection())) continue;
dee1e0e0 2764 phi1=fTrack->Phi();
3d824203 2765 if(phiWeights) wPhi1 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi1*nBinsPhi/TMath::TwoPi())));
9c1a9547 2766 for(Int_t i2=0;i2<nPrim;i2++)
dee1e0e0 2767 {
2768 if(i2==i1)continue;
2769 fTrack=anEvent->GetTrack(i2);
9c1a9547 2770 if(!(fTrack->InRPSelection())) continue;
dee1e0e0 2771 phi2=fTrack->Phi();
3d824203 2772 if(phiWeights) wPhi2 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi2*nBinsPhi/TMath::TwoPi())));
9c1a9547 2773 for(Int_t i3=0;i3<nPrim;i3++)
dee1e0e0 2774 {
2775 if(i3==i1||i3==i2)continue;
2776 fTrack=anEvent->GetTrack(i3);
9c1a9547 2777 if(!(fTrack->InRPSelection())) continue;
dee1e0e0 2778 phi3=fTrack->Phi();
3d824203 2779 if(phiWeights) wPhi3 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi3*nBinsPhi/TMath::TwoPi())));
9c1a9547 2780 for(Int_t i4=0;i4<nPrim;i4++)
dee1e0e0 2781 {
2782 if(i4==i1||i4==i2||i4==i3)continue;
2783 fTrack=anEvent->GetTrack(i4);
9c1a9547 2784 if(!(fTrack->InRPSelection())) continue;
dee1e0e0 2785 phi4=fTrack->Phi();
3d824203 2786 if(phiWeights) wPhi4 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi4*nBinsPhi/TMath::TwoPi())));
9c1a9547 2787 for(Int_t i5=0;i5<nPrim;i5++)
dee1e0e0 2788 {
2789 if(i5==i1||i5==i2||i5==i3||i5==i4)continue;
2790 fTrack=anEvent->GetTrack(i5);
9c1a9547 2791 if(!(fTrack->InRPSelection())) continue;
dee1e0e0 2792 phi5=fTrack->Phi();
3d824203 2793 if(phiWeights) wPhi5 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi5*nBinsPhi/TMath::TwoPi())));
9c1a9547 2794 for(Int_t i6=0;i6<nPrim;i6++)
dee1e0e0 2795 {
2796 if(i6==i1||i6==i2||i6==i3||i6==i4||i6==i5)continue;
2797 fTrack=anEvent->GetTrack(i6);
9c1a9547 2798 if(!(fTrack->InRPSelection())) continue;
dee1e0e0 2799 phi6=fTrack->Phi();
3d824203 2800 if(phiWeights) wPhi6 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi6*nBinsPhi/TMath::TwoPi())));
9c1a9547 2801
2802 // non-weighted:
2803 //-----------------------------------------------------------------------------------------------------------
2804 fDirectCorrelations->Fill(23.,cos(n*phi1+n*phi2+n*phi3-n*phi4-n*phi5-n*phi6),1.); //<6>_{n,n,n|n,n,n}
2805 fDirectCorrelations->Fill(24.,cos(2.*n*phi1+n*phi2+n*phi3-2.*n*phi4-n*phi5-n*phi6),1.); //<6>_{2n,n,n|2n,n,n}
2806 fDirectCorrelations->Fill(25.,cos(2.*n*phi1+2.*n*phi2-n*phi3-n*phi4-n*phi5-n*phi6),1.); //<6>_{2n,2n|n,n,n,n}
2807 fDirectCorrelations->Fill(26.,cos(3.*n*phi1+n*phi2-n*phi3-n*phi4-n*phi5-n*phi6),1.); //<6>_{3n,n|n,n,n,n}
2808 //-----------------------------------------------------------------------------------------------------------
2809
2810 // weighted:
2811 //.................................................................................................................
2812 // 6-p:
2813 fDirectCorrelationsW->Fill(80.,cos(n*phi1+n*phi2+n*phi3-n*phi4-n*phi5-n*phi6),wPhi1*wPhi2*wPhi3*wPhi4*wPhi5*wPhi6);
2814 //.................................................................................................................
2815
dee1e0e0 2816 }
2817 }
2818 }
2819 }
2820 }
2821 }
3d824203 2822
9c1a9547 2823 // 7-particle correlations:
2824 for(Int_t i1=0;i1<nPrim;i1++)
bc92c0cb 2825 {
dee1e0e0 2826 //cout<<"i1 = "<<i1<<endl;
2827 fTrack=anEvent->GetTrack(i1);
9c1a9547 2828 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2829 phi1=fTrack->Phi();
3d824203 2830 if(phiWeights) wPhi1 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi1*nBinsPhi/TMath::TwoPi())));
9c1a9547 2831 for(Int_t i2=0;i2<nPrim;i2++)
bc92c0cb 2832 {
dee1e0e0 2833 if(i2==i1)continue;
2834 fTrack=anEvent->GetTrack(i2);
9c1a9547 2835 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2836 phi2=fTrack->Phi();
3d824203 2837 if(phiWeights) wPhi2 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi2*nBinsPhi/TMath::TwoPi())));
9c1a9547 2838 for(Int_t i3=0;i3<nPrim;i3++)
bc92c0cb 2839 {
dee1e0e0 2840 if(i3==i1||i3==i2)continue;
2841 fTrack=anEvent->GetTrack(i3);
9c1a9547 2842 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2843 phi3=fTrack->Phi();
3d824203 2844 if(phiWeights) wPhi3 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi3*nBinsPhi/TMath::TwoPi())));
9c1a9547 2845 for(Int_t i4=0;i4<nPrim;i4++)
bc92c0cb 2846 {
dee1e0e0 2847 if(i4==i1||i4==i2||i4==i3)continue;
2848 fTrack=anEvent->GetTrack(i4);
9c1a9547 2849 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2850 phi4=fTrack->Phi();
3d824203 2851 if(phiWeights) wPhi4 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi4*nBinsPhi/TMath::TwoPi())));
9c1a9547 2852 for(Int_t i5=0;i5<nPrim;i5++)
bc92c0cb 2853 {
dee1e0e0 2854 if(i5==i1||i5==i2||i5==i3||i5==i4)continue;
2855 fTrack=anEvent->GetTrack(i5);
9c1a9547 2856 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2857 phi5=fTrack->Phi();
3d824203 2858 if(phiWeights) wPhi5 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi5*nBinsPhi/TMath::TwoPi())));
9c1a9547 2859 for(Int_t i6=0;i6<nPrim;i6++)
bc92c0cb 2860 {
dee1e0e0 2861 if(i6==i1||i6==i2||i6==i3||i6==i4||i6==i5)continue;
2862 fTrack=anEvent->GetTrack(i6);
9c1a9547 2863 if(!(fTrack->InRPSelection())) continue;
bc92c0cb 2864 phi6=fTrack->Phi();
3d824203 2865 if(phiWeights) wPhi6 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi6*nBinsPhi/TMath::TwoPi())));
9c1a9547 2866 for(Int_t i7=0;i7<nPrim;i7++)
dee1e0e0 2867 {
2868 if(i7==i1||i7==i2||i7==i3||i7==i4||i7==i5||i7==i6)continue;
2869 fTrack=anEvent->GetTrack(i7);
9c1a9547 2870 if(!(fTrack->InRPSelection())) continue;
dee1e0e0 2871 phi7=fTrack->Phi();
3d824203 2872 if(phiWeights) wPhi7 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi7*nBinsPhi/TMath::TwoPi())));
9c1a9547 2873
2874 // non-weighted:
2875 //---------------------------------------------------------------------------------------------------------------
2876 fDirectCorrelations->Fill(28.,cos(2.*n*phi1+n*phi2+n*phi3-n*phi4-n*phi5-n*phi6-n*phi7),1.);//<7>_{2n,n,n|n,n,n,n}
2877 //---------------------------------------------------------------------------------------------------------------
2878
2879 // weighted:
2880 //..........................................................................................................................................
2881 fDirectCorrelationsW->Fill(100.,cos(2.*n*phi1+n*phi2+n*phi3-n*phi4-n*phi5-n*phi6-n*phi7),pow(wPhi1,2.)*wPhi2*wPhi3*wPhi4*wPhi5*wPhi6*wPhi7);
2882 //..........................................................................................................................................
2883
dee1e0e0 2884 }
bc92c0cb 2885 }
2886 }
2887 }
2888 }
2889 }
2890 }
52021ae2 2891
9c1a9547 2892 // 8-particle correlations:
2893 for(Int_t i1=0;i1<nPrim;i1++)
dee1e0e0 2894 {
2895 cout<<"i1 = "<<i1<<endl;
2896 fTrack=anEvent->GetTrack(i1);
9c1a9547 2897 if(!(fTrack->InRPSelection())) continue;
dee1e0e0 2898 phi1=fTrack->Phi();
3d824203 2899 if(phiWeights) wPhi1 = phiWeights->GetBinContent(1+(Int_t)(TMath::Floor(phi1*nBinsPhi/TMath::TwoPi())));
9c1a9547 2900 for(Int_t i2=0;i2<nPrim;i2++)
dee1e0e0 2901 {
2902 if(i2==i1)continue;