23 #define AliFlowAnalysisCRC_cxx
25 #include "Riostream.h"
34 #include "TParticle.h"
38 #include "TProfile2D.h"
39 #include "TProfile3D.h"
42 #include "TPaveLabel.h"
52 #include "THnSparse.h"
85 fBookOnlyBasicCCH(kTRUE),
87 fCommonHists2nd(NULL),
88 fCommonHists4th(NULL),
89 fCommonHists6th(NULL),
90 fCommonHists8th(NULL),
91 fCommonHistsResults2nd(NULL),
92 fCommonHistsResults4th(NULL),
93 fCommonHistsResults6th(NULL),
94 fCommonHistsResults8th(NULL),
107 fCommonConstants(NULL),
108 fFillMultipleControlHistograms(kFALSE),
110 fAnalysisLabel(NULL),
112 fUsePhiWeights(kFALSE),
113 fUsePtWeights(kFALSE),
114 fUseEtaWeights(kFALSE),
115 fUseTrackWeights(kFALSE),
116 fUsePhiEtaWeights(kFALSE),
117 fUsePhiEtaWeightsChDep(kFALSE),
118 fUsePhiEtaWeightsVtxDep(kFALSE),
119 fUsePhiEtaWeightsChPtDep(kFALSE),
120 fUseZDCESEMulWeights(kFALSE),
121 fUseZDCESESpecWeights(kFALSE),
122 fUseParticleWeights(NULL),
124 fMultiplicityWeight(NULL),
128 fIntFlowProfiles(NULL),
129 fIntFlowResults(NULL),
130 fIntFlowAllCorrelationsVsM(NULL),
132 fApplyCorrectionForNUA(kFALSE),
133 fApplyCorrectionForNUAVsM(kFALSE),
137 fPropagateErrorAlsoFromNIT(kFALSE),
138 fCalculateCumulantsVsM(kFALSE),
139 fCalculateAllCorrelationsVsM(kFALSE),
140 fMinimumBiasReferenceFlow(kTRUE),
141 fForgetAboutCovariances(kFALSE),
142 fStoreVarious(kFALSE),
144 fUse2DHistograms(kFALSE),
145 fFillProfilesVsMUsingWeights(kTRUE),
146 fUseQvectorTerms(kFALSE),
152 fIntFlowCorrelationsEBE(NULL),
153 fIntFlowEventWeightsForCorrelationsEBE(NULL),
154 fIntFlowCorrelationsAllEBE(NULL),
156 fNumberOfPOIsEBE(0.),
157 fReferenceMultiplicityEBE(0.),
158 fReferenceMultiplicityRecEBE(0.),
160 fNewCentralityEBE(0.),
166 fCentralityCL1EBE(0.),
168 fCentralityTRKEBE(0.),
176 fAvMultiplicity(NULL),
177 fIntFlowCorrelationsPro(NULL),
178 fIntFlowSquaredCorrelationsPro(NULL),
179 fIntFlowCorrelationsAllPro(NULL),
180 fIntFlowExtraCorrelationsPro(NULL),
181 fIntFlowProductOfCorrelationsPro(NULL),
182 fIntFlowProductOfCorrectionTermsForNUAPro(NULL),
183 fIntFlowCorrelationsHist(NULL),
184 fIntFlowCorrelationsAllHist(NULL),
185 fIntFlowCovariances(NULL),
186 fIntFlowSumOfProductOfEventWeights(NULL),
187 fIntFlowCovariancesNUA(NULL),
188 fIntFlowSumOfProductOfEventWeightsNUA(NULL),
189 fIntFlowQcumulants(NULL),
190 fIntFlowQcumulantsRebinnedInM(NULL),
191 fIntFlowQcumulantsErrorSquaredRatio(NULL),
193 fIntFlowRebinnedInM(NULL),
194 fIntFlowDetectorBias(NULL),
197 fDiffFlowProfiles(NULL),
198 fDiffFlowResults(NULL),
200 fDiffFlowFlags(NULL),
201 fCalculateDiffFlow(kTRUE),
202 fCalculate2DDiffFlow(kFALSE),
203 fCalculateDiffFlowVsEta(kTRUE),
205 fOtherDiffCorrelatorsList(NULL),
207 fDistributionsList(NULL),
208 fDistributionsFlags(NULL),
209 fStoreDistributions(kFALSE),
210 fnBinsForCorrelations(10000),
212 fNestedLoopsList(NULL),
213 fEvaluateIntFlowNestedLoops(kFALSE),
214 fEvaluateDiffFlowNestedLoops(kFALSE),
215 fMaxAllowedMultiplicity(10),
216 fEvaluateNestedLoops(NULL),
217 fIntFlowDirectCorrelations(NULL),
218 fIntFlowExtraDirectCorrelations(NULL),
219 fCrossCheckInPtBinNo(10),
220 fCrossCheckInEtaBinNo(20),
221 fNoOfParticlesInBin(NULL),
222 fMixedHarmonicsNestedLoops(NULL),
224 fMixedHarmonicsList(NULL),
225 fMixedHarmonicsProfiles(NULL),
226 fMixedHarmonicsResults(NULL),
227 fMixedHarmonicsErrorPropagation(NULL),
228 fMixedHarmonicsFlags(NULL),
229 fCalculateMixedHarmonics(kFALSE),
230 fCalculateMixedHarmonicsVsM(kFALSE),
231 f2pCorrelations(NULL),
232 f3pCorrelations(NULL),
233 f4pCorrelations(NULL),
234 f5pCorrelations(NULL),
235 f6pCorrelations(NULL),
236 f7pCorrelations(NULL),
237 f8pCorrelations(NULL),
245 fMixedHarmonicProductOfEventWeights(NULL),
246 fMixedHarmonicProductOfCorrelations(NULL),
248 fControlHistogramsList(NULL),
249 fControlHistogramsFlags(NULL),
250 fStoreControlHistograms(kFALSE),
251 fCorrelationNoRPsVsRefMult(NULL),
252 fCorrelationNoPOIsVsRefMult(NULL),
253 fCorrelationNoRPsVsNoPOIs(NULL),
255 fBootstrapList(NULL),
256 fBootstrapProfilesList(NULL),
257 fBootstrapResultsList(NULL),
258 fBootstrapFlags(NULL),
259 fUseBootstrap(kFALSE),
260 fUseBootstrapVsM(kFALSE),
263 fBootstrapCorrelations(NULL),
264 fBootstrapCumulants(NULL),
269 fCalculateCRC(kTRUE),
270 fCalculateCRCPt(kFALSE),
271 fCalculateCME(kFALSE),
272 fCalculateCRCInt(kFALSE),
273 fCalculateCRC2(kFALSE),
274 fCalculateCRCVZ(kFALSE),
275 fCalculateCRCZDC(kFALSE),
276 fCalculateFlowQC(kFALSE),
277 fCalculateFlowZDC(kFALSE),
278 fCalculateFlowVZ(kFALSE),
279 fCalculateEbEFlow(kFALSE),
280 fStoreZDCQVecVtxPos(kFALSE),
281 fUsePhiEtaCuts(kFALSE),
284 fRecenterZDC(kFALSE),
286 fUseCRCRecenter(kFALSE),
297 fCorrWeightTPC(kUnit),
298 fCorrWeightVZ(kUnit),
299 fCorrWeightZDC(kUnit),
302 fCRCCenBinWidth(CenWidth),
303 fCRCIntRbRList(NULL),
306 fInteractionRate(kAll),
307 fSelectCharge(kAllCh),
308 fPOIExtraWeights(kNone),
310 fCRCQVecListTPC(NULL),
311 fCRCQVecWeightsList(NULL),
312 fCRCZDCCalibList(NULL),
313 fCRCZDC2DCutList(NULL),
314 fCRCVZEROCalibList(NULL),
315 fCRCZDCResList(NULL),
319 fCRCZDCRbRList(NULL),
326 fFlowSPZDCList(NULL),
328 fFlowQCCorrZDCList(NULL),
333 fFlowQCDeltaEta(0.4),
339 fQAZDCCutsFlag(kTRUE),
340 fUseTracklets(kFALSE),
343 fZDCGainAlpha(0.395),
344 fbFlagIsPosMagField(kFALSE)
349 fHistList =
new TList();
350 fHistList->SetName(
"cobjQC");
351 fHistList->SetOwner(kTRUE);
354 fTempList =
new TList();
355 fTempList->SetName(
"temp");
356 fTempList->SetOwner(kTRUE);
359 fMultiplicityWeight =
new TString(
"combinations");
362 fAnalysisLabel =
new TString();
365 this->InitializeArraysForIntFlow();
366 this->InitializeArraysForDiffFlow();
367 this->InitializeArraysForDistributions();
368 this->InitializeArraysForVarious();
369 this->InitializeArraysForNestedLoops();
370 this->InitializeArraysForMixedHarmonics();
371 this->InitializeArraysForControlHistograms();
372 this->InitializeArraysForBootstrap();
381 this->InitializeCostantsForCRC();
382 this->InitializeArraysForParticleWeights();
383 this->InitializeArraysForCRC();
384 this->InitializeArraysForCRCVZ();
385 this->InitializeArraysForCRCZDC();
386 this->InitializeArraysForCRC2();
387 this->InitializeArraysForQVec();
388 this->InitializeArraysForCRCPt();
389 this->InitializeArraysForCME();
390 this->InitializeArraysForFlowEbE();
391 this->InitializeArraysForFlowQC();
392 this->InitializeArraysForFlowQCHighOrders();
393 this->InitializeArraysForFlowGF();
394 this->InitializeArraysForFlowSPZDC();
395 this->InitializeArraysForFlowSPVZ();
396 this->InitializeArraysForEbEFlow();
441 Bool_t oldHistAddStatus = TH1::AddDirectoryStatus();
442 TH1::AddDirectory(kFALSE);
500 TH1::AddDirectory(oldHistAddStatus);
541 Int_t nCounterNoRPs = 0;
596 if(fRunBin<0 || fRunBin>=
fCRCnRun) {
return;}
598 if(fCenBin<0 || fCenBin>=
fCRCnCen) {
return;}
611 Int_t dRun15hPos[] = {246390, 246391, 246392, 246994, 246991, 246989, 246984, 246982, 246980, 246948, 246945, 246928, 246851, 246847, 246846, 246845, 246844, 246810, 246809, 246808, 246807, 246805, 246804, 246766, 246765, 246763, 246760, 246759, 246758, 246757, 246751, 246750, 246495, 246493, 246488, 246487, 246434, 246431, 246428, 246424};
612 for (
Int_t i=0; i<40; i++) {
680 Bool_t bPassZDCcuts = kTRUE;
681 if( ZCM<=0. || ZAM<=0. || sqrt(ZCRe*ZCRe+ZCIm*ZCIm)<1.E-6 || sqrt(ZARe*ZARe+ZAIm*ZAIm)<1.E-6 ) bPassZDCcuts=kFALSE;
703 AliWarning(
"WARNING: POIExtraWeights (kEtaPhiRbR) not found ! \n");
707 for (
Int_t i=0; i<2; i++) {
711 AliWarning(
"WARNING: POIExtraWeights (kEtaPhiChRbR) not found ! \n");
720 AliWarning(
"WARNING: POIExtraWeights (kEtaPhiVtxRbR) not found ! \n");
728 for(
Int_t i=0;i<nPrim;i++) {
735 Bool_t IsSplitMergedTracks = kFALSE;
739 if(IsSplitMergedTracks)
continue;
745 dPhi = aftsTrack->
Phi();
746 dPt = aftsTrack->
Pt();
747 dEta = aftsTrack->
Eta();
748 dCharge = aftsTrack->
Charge();
753 cw = (dCharge > 0. ? 0 : 1);
765 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
772 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
777 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
782 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
784 Int_t ptbebe = (dPt>1.? 2 : (dPt>0.5 ? 1 : 0));
788 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
794 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
799 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
807 for(
Int_t m=0;m<12;m++)
809 for(
Int_t k=0;k<9;k++)
811 (*fReQ)(m,k)+=pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Cos((m+1)*n*dPhi);
812 (*fImQ)(m,k)+=pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Sin((m+1)*n*dPhi);
816 for(
Int_t p=0;p<8;p++)
818 for(
Int_t k=0;k<9;k++)
820 (*fSpk)(p,k)+=pow(wPhiEta*wPhi*wPt*wEta*wTrack,k);
829 for(
Int_t k=0;k<9;k++)
831 for(
Int_t m=0;m<4;m++)
837 fReRPQ1dEBE[0][pe][m][k]->Fill(ptEta[pe],pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Cos((m+1.)*n*dPhi),1.);
838 fImRPQ1dEBE[0][pe][m][k]->Fill(ptEta[pe],pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Sin((m+1.)*n*dPhi),1.);
841 fs1dEBE[0][pe][k]->Fill(ptEta[pe],pow(wPhiEta*wPhi*wPt*wEta*wTrack,k),1.);
847 fReRPQ2dEBE[0][m][k]->Fill(dPt,dEta,pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Cos((m+1.)*n*dPhi),1.);
848 fImRPQ2dEBE[0][m][k]->Fill(dPt,dEta,pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Sin((m+1.)*n*dPhi),1.);
851 fs2dEBE[0][k]->Fill(dPt,dEta,pow(wPhiEta*wPhi*wPt*wEta*wTrack,k),1.);
860 for(
Int_t k=0;k<9;k++)
862 for(
Int_t m=0;m<4;m++)
868 fReRPQ1dEBE[2][pe][m][k]->Fill(ptEta[pe],pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Cos((m+1.)*n*dPhi),1.);
869 fImRPQ1dEBE[2][pe][m][k]->Fill(ptEta[pe],pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Sin((m+1.)*n*dPhi),1.);
872 fs1dEBE[2][pe][k]->Fill(ptEta[pe],pow(wPhiEta*wPhi*wPt*wEta*wTrack,k),1.);
878 fReRPQ2dEBE[2][m][k]->Fill(dPt,dEta,pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Cos((m+1.)*n*dPhi),1.);
879 fImRPQ2dEBE[2][m][k]->Fill(dPt,dEta,pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Sin((m+1.)*n*dPhi),1.);
882 fs2dEBE[2][k]->Fill(dPt,dEta,pow(wPhiEta*wPhi*wPt*wEta*wTrack,k),1.);
899 dPhi = aftsTrack->
Phi();
900 dPt = aftsTrack->
Pt();
901 dEta = aftsTrack->
Eta();
902 dCharge = aftsTrack->
Charge();
909 if(dCharge > 0.) dPt += 1.E-2;
913 cw = (dCharge > 0. ? 0 : 1);
926 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
933 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
938 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
943 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
945 Int_t ptbebe = (dPt>1.? 2 : (dPt>0.5 ? 1 : 0));
949 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
955 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
960 if(std::isfinite(1./wt)) wPhiEta *= 1./wt;
966 if(dPhi>2.136283 && dPhi<2.324779)
continue;
970 for(
Int_t m=0;m<21;m++)
972 for(
Int_t k=0;k<9;k++)
974 (*fReQGF)(m,k) += pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Cos(m*dPhi);
975 (*fImQGF)(m,k) += pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Sin(m*dPhi);
982 for(
Int_t k=0;k<9;k++)
984 for(
Int_t m=0;m<4;m++)
990 fReRPQ1dEBE[1][pe][m][k]->Fill(ptEta[pe],pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Cos((m+1.)*n*dPhi),1.);
991 fImRPQ1dEBE[1][pe][m][k]->Fill(ptEta[pe],pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Sin((m+1.)*n*dPhi),1.);
996 fReRPQ2dEBE[1][m][k]->Fill(dPt,dEta,pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Cos((m+1.)*n*dPhi),1.);
997 fImRPQ2dEBE[1][m][k]->Fill(dPt,dEta,pow(wPhiEta*wPhi*wPt*wEta*wTrack,k)*TMath::Sin((m+1.)*n*dPhi),1.);
1005 fCRCQRe[cw][h]->Fill(dEta,wPhiEta*TMath::Cos((h+1.)*dPhi));
1006 fCRCQIm[cw][h]->Fill(dEta,wPhiEta*TMath::Sin((h+1.)*dPhi));
1007 fCRCMult[cw][h]->Fill(dEta,wPhiEta);
1009 fCRC2QRe[cw][h]->Fill(dEta,wPhiEta*TMath::Cos((h+1.)*dPhi));
1010 fCRC2QIm[cw][h]->Fill(dEta,wPhiEta*TMath::Sin((h+1.)*dPhi));
1011 fCRC2Mul[cw][h]->Fill(dEta,pow(wPhiEta,h));
1013 fCRCZDCQRe[cw][h]->Fill(dEta,wPhiEta*TMath::Cos((h+1.)*dPhi));
1014 fCRCZDCQIm[cw][h]->Fill(dEta,wPhiEta*TMath::Sin((h+1.)*dPhi));
1018 fCRC2QRe[2][h]->Fill(dEta,wPhiEta*TMath::Cos((h+1.)*dPhi));
1019 fCRC2QIm[2][h]->Fill(dEta,wPhiEta*TMath::Sin((h+1.)*dPhi));
1020 fCRC2Mul[2][h]->Fill(dEta,pow(wPhiEta,h));
1024 fCRCZDCQRe[2][h]->Fill(dEta,wPhiEta*TMath::Cos((h+1.)*dPhi));
1025 fCRCZDCQIm[2][h]->Fill(dEta,wPhiEta*TMath::Sin((h+1.)*dPhi));
1028 fCRCZDCQRe[3][h]->Fill(dEta,wPhiEta*TMath::Cos((h+1.)*dPhi));
1029 fCRCZDCQIm[3][h]->Fill(dEta,wPhiEta*TMath::Sin((h+1.)*dPhi));
1037 if(weraw > 0.) SpecWeig = 1./weraw;
1039 fCMEQRe[cw][h]->Fill(dEta,SpecWeig*wPhiEta*TMath::Cos((h+1.)*dPhi));
1040 fCMEQIm[cw][h]->Fill(dEta,SpecWeig*wPhiEta*TMath::Sin((h+1.)*dPhi));
1041 fCMEMult[cw][h]->Fill(dEta,SpecWeig*wPhiEta);
1042 fCMEQRe[2+cw][h]->Fill(dEta,pow(SpecWeig*wPhiEta,2.)*TMath::Cos((h+1.)*dPhi));
1043 fCMEQIm[2+cw][h]->Fill(dEta,pow(SpecWeig*wPhiEta,2.)*TMath::Sin((h+1.)*dPhi));
1044 fCMEMult[2+cw][h]->Fill(dEta,pow(SpecWeig*wPhiEta,2.));
1060 fPOIPtDiffQRe[k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1061 fPOIPtDiffQIm[k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1064 fPOIPtDiffQReCh[cw][k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1065 fPOIPtDiffQImCh[cw][k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1068 fPOIPhiDiffQRe[k][h]->Fill(dPhi,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1069 fPOIPhiDiffQIm[k][h]->Fill(dPhi,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1072 fPOIPtEtaDiffQRe[k][h]->Fill(dPt,dEta,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1073 fPOIPtEtaDiffQIm[k][h]->Fill(dPt,dEta,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1081 Int_t keta = (dEta<0.?0:1);
1082 fPOIPtDiffQReEG[keta][k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1083 fPOIPtDiffQImEG[keta][k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1085 fPOIPhiDiffQReEG[keta][k][h]->Fill(dPhi,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1086 fPOIPhiDiffQImEG[keta][k][h]->Fill(dPhi,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1090 }
else if(fFlowQCDeltaEta<0. && fFlowQCDeltaEta>-1.) {
1093 fPOIPtDiffQRe[k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1094 fPOIPtDiffQIm[k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1097 fPOIPhiDiffQRe[k][h]->Fill(dPhi,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1098 fPOIPhiDiffQIm[k][h]->Fill(dPhi,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1103 if((dEta>0. && dEta<0.4-boundetagap/2.) || (dEta>0.4+boundetagap/2. && dEta<0.8)) {
1105 if(dEta>0. && dEta<0.4-boundetagap/2.) keta = 0;
1107 fPOIPtDiffQReEG[keta][k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1108 fPOIPtDiffQImEG[keta][k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1116 }
else if(fFlowQCDeltaEta<-1. && fFlowQCDeltaEta>-2.) {
1119 fPOIPtDiffQRe[k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1120 fPOIPtDiffQIm[k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1123 fPOIPhiDiffQRe[k][h]->Fill(dPhi,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1124 fPOIPhiDiffQIm[k][h]->Fill(dPhi,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1129 if((dEta<0. && dEta>-0.4+boundetagap/2.) || (dEta<-0.4-boundetagap/2. && dEta>-0.8)) {
1131 if(dEta<0. && dEta>-0.4+boundetagap/2.) keta = 0;
1133 fPOIPtDiffQReEG[keta][k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Cos((h+1.)*dPhi));
1134 fPOIPtDiffQImEG[keta][k][h]->Fill(dPt,pow(wPhiEta,k)*TMath::Sin((h+1.)*dPhi));
1147 fEtaDiffQRe[cw][h]->Fill(dEta,wPhiEta*TMath::Cos((h+1.)*dPhi));
1148 fEtaDiffQIm[cw][h]->Fill(dEta,wPhiEta*TMath::Sin((h+1.)*dPhi));
1150 fPOIEtaPtQRe[cw][h]->Fill(dEta,dPt,wPhiEta*TMath::Cos((h+1.)*dPhi));
1151 fPOIEtaPtQIm[cw][h]->Fill(dEta,dPt,wPhiEta*TMath::Sin((h+1.)*dPhi));
1179 for (
Int_t h=0;h<6;h++) {
1202 printf(
"\n WARNING (QC): No particle (i.e. aftsTrack is a NULL pointer in AFAWQC::Make())!!!!\n\n");
1209 for(
Int_t p=0;p<8;p++)
1211 for(
Int_t k=0;k<9;k++)
1213 (*fSpk)(p,k)=pow((*
fSpk)(p,k),p+1);
1608 const Float_t kLimit1 = 0.02 * 3;
1612 Bool_t isNoSplit = kFALSE;
1615 if (it1 < nTracks - 1) {
1616 for (
Int_t itll2 = it1 + 1; itll2 < nTracks; itll2++) {
1628 if (TMath::Abs(deta1) < 0.02 * 2.5 * 3) {
1636 Float_t dphistarminabs1 = 1e5;
1639 if (TMath::Abs(dphistar11) < kLimit1 || TMath::Abs(dphistar21) < kLimit1 || dphistar11 * dphistar21 < 0 ) {
1641 for (
Double_t rad1 = 0.8; rad1 < 2.51; rad1 += 0.01) {
1644 Float_t dphistarabs1 = TMath::Abs(dphistar1);
1645 if (dphistarabs1 < dphistarminabs1) {
1646 dphistarmin1 = dphistar1;
1647 dphistarminabs1 = dphistarabs1;
1650 if (dphistarminabs1 < 0.02 && TMath::Abs(deta1) < 0.02) {
1704 cout<<
"Skipping the event because multiplicity is "<<nPrim<<
". Too high to evaluate nested loops!"<<endl;
1708 cout<<
"Skipping the event because multiplicity is "<<nPrim<<
"."<<endl;
1844 cosP1n = dReQ1n/dMult;
1862 cosP1nP1n = (pow(dReQ1n,2)-pow(dImQ1n,2)-dReQ2n)/(dMult*(dMult-1));
1863 cosP2nM1n = (dReQ2n*dReQ1n+dImQ2n*dImQ1n-dReQ1n)/(dMult*(dMult-1));
1887 cosP1nM1nM1n = (dReQ1n*(pow(dReQ1n,2)+pow(dImQ1n,2))-dReQ1n*dReQ2n-dImQ1n*dImQ2n-2.*(dMult-1)*dReQ1n)
1888 / (dMult*(dMult-1)*(dMult-2));
1953 sinP1n = dImQ1n/dMult;
1970 sinP1nP1n = (2.*dReQ1n*dImQ1n-dImQ2n)/(dMult*(dMult-1));
1971 sinP2nM1n = (dImQ2n*dReQ1n-dReQ2n*dImQ1n-dImQ1n)/(dMult*(dMult-1));
1995 sinP1nM1nM1n = (-dImQ1n*(pow(dReQ1n,2)+pow(dImQ1n,2))+dReQ1n*dImQ2n-dImQ1n*dReQ2n+2.*(dMult-1)*dImQ1n)
1996 / (dMult*(dMult-1)*(dMult-2));
2026 if(outputListHistos)
2031 printf(
"\n WARNING (QC): fHistList is NULL in AFAWQC::GOH() !!!!\n\n");
2060 printf(
"\n WARNING (QC): outputListHistos is NULL in AFAWQC::GOH() !!!!\n\n");
2072 Int_t nBinsPt = profilePtEta->GetNbinsX();
2073 Double_t dPtMin = (profilePtEta->GetXaxis())->GetXmin();
2074 Double_t dPtMax = (profilePtEta->GetXaxis())->GetXmax();
2076 Int_t nBinsEta = profilePtEta->GetNbinsY();
2078 TProfile *profilePt =
new TProfile(
"",
"",nBinsPt,dPtMin,dPtMax);
2080 for(
Int_t p=1;p<=nBinsPt;p++)
2088 for(
Int_t e=1;e<=nBinsEta;e++)
2090 contentPt += (profilePtEta->GetBinContent(profilePtEta->GetBin(p,e)))
2091 * (profilePtEta->GetBinEntries(profilePtEta->GetBin(p,e)));
2092 entryPt += (profilePtEta->GetBinEntries(profilePtEta->GetBin(p,e)));
2094 sum1 += (profilePtEta->GetBinEntries(profilePtEta->GetBin(p,e)))
2095 * (pow(profilePtEta->GetBinError(profilePtEta->GetBin(p,e)),2.)
2096 + pow(profilePtEta->GetBinContent(profilePtEta->GetBin(p,e)),2.));
2097 sum2 += (profilePtEta->GetBinEntries(profilePtEta->GetBin(p,e)));
2098 sum3 += (profilePtEta->GetBinEntries(profilePtEta->GetBin(p,e)))
2099 * (profilePtEta->GetBinContent(profilePtEta->GetBin(p,e)));
2101 if(sum2>0. && sum1/sum2-pow(sum3/sum2,2.) > 0.)
2103 spreadPt = pow(sum1/sum2-pow(sum3/sum2,2.),0.5);
2105 profilePt->SetBinContent(p,contentPt);
2106 profilePt->SetBinEntries(p,entryPt);
2108 profilePt->SetBinError(p,spreadPt);
2125 Int_t nBinsEta = profilePtEta->GetNbinsY();
2126 Double_t dEtaMin = (profilePtEta->GetYaxis())->GetXmin();
2127 Double_t dEtaMax = (profilePtEta->GetYaxis())->GetXmax();
2129 Int_t nBinsPt = profilePtEta->GetNbinsX();
2131 TProfile *profileEta =
new TProfile(
"",
"",nBinsEta,dEtaMin,dEtaMax);
2133 for(
Int_t e=1;e<=nBinsEta;e++)
2137 for(
Int_t p=1;p<=nBinsPt;p++)
2139 contentEta += (profilePtEta->GetBinContent(profilePtEta->GetBin(p,e)))
2140 * (profilePtEta->GetBinEntries(profilePtEta->GetBin(p,e)));
2141 entryEta += (profilePtEta->GetBinEntries(profilePtEta->GetBin(p,e)));
2143 profileEta->SetBinContent(e,contentEta);
2144 profileEta->SetBinEntries(e,entryEta);
2164 for(
Int_t b=0;b<4;b++)
2175 }
else if(type ==
"RP")
2185 }
else if(type ==
"POI")
2197 for(
Int_t b=0;b<4;b++)
2206 TString subtitle2 =
" (rebinned in M)";
2208 if(type !=
"RF, rebinned in M")
2212 subtitle.Append(type);
2213 subtitle.Append(
", without weights)");
2216 subtitle.Append(type);
2217 subtitle.Append(
", with weights)");
2223 subtitle.Append(
"RF");
2224 subtitle.Append(
", without weights)");
2227 subtitle.Append(
"RF");
2228 subtitle.Append(
", with weights)");
2233 cout<<
"*************************************"<<endl;
2234 cout<<
"*************************************"<<endl;
2235 cout<<title.Data()<<endl;
2236 cout<<subtitle.Data()<<endl;
2237 if(type ==
"RF, rebinned in M"){cout<<subtitle2.Data()<<endl;}
2240 for(
Int_t i=0;i<4;i++)
2242 cout<<
" v_"<<n<<
"{"<<2*(i+1)<<
"} = "<<dVn[i]<<
" +/- "<<dVnErr[i]<<endl;
2250 cout<<
" detector bias (corrected for): "<<endl;
2253 cout<<
" detector bias (not corrected for):"<<endl;
2259 if(type ==
"RF" || type ==
"RF, rebinned in M")
2263 else if (type ==
"RP")
2267 else if (type ==
"POI")
2272 cout<<
"*************************************"<<endl;
2273 cout<<
"*************************************"<<endl;
2283 TFile *output =
new TFile(outputFileName.Data(),
"RECREATE");
2299 outputFileName->Write(outputFileName->GetName(), TObject::kSingleKey);
2312 TString commonHistsName =
"AliFlowCommonHistQC";
2320 TString commonHists2ndOrderName =
"AliFlowCommonHist2ndOrderQC";
2325 TString commonHists4thOrderName =
"AliFlowCommonHist4thOrderQC";
2330 TString commonHists6thOrderName =
"AliFlowCommonHist6thOrderQC";
2335 TString commonHists8thOrderName =
"AliFlowCommonHist8thOrderQC";
2343 TString commonHistResults2ndOrderName =
"AliFlowCommonHistResults2ndOrderQC";
2348 TString commonHistResults4thOrderName =
"AliFlowCommonHistResults4thOrderQC";
2353 TString commonHistResults6thOrderName =
"AliFlowCommonHistResults6thOrderQC";
2358 TString commonHistResults8thOrderName =
"AliFlowCommonHistResults8thOrderQC";
2550 TF1 *CenFit =
new TF1(
"CenFit",
"pol0", 0., 100.);
2553 Double_t CenAv = CenFit->GetParameter(0);
2565 Double_t CenAv = CenFit->GetParameter(0);
2567 Double_t SemiCenAv = CenFit->GetParameter(0);
2593 TString sinCosFlag[2] = {
"sin",
"cos"};
2594 TString powerFlag[2] = {
"linear",
"quadratic"};
2597 TString intFlowFlagsName =
"fIntFlowFlags";
2599 fIntFlowFlags =
new TProfile(intFlowFlagsName.Data(),
"Flags for Integrated Flow",20,0.,20.);
2605 fIntFlowFlags->GetXaxis()->SetBinLabel(1,
"Particle Weights");
2607 fIntFlowFlags->GetXaxis()->SetBinLabel(3,
"Corrected for NUA?");
2608 fIntFlowFlags->GetXaxis()->SetBinLabel(4,
"Print RF results");
2609 fIntFlowFlags->GetXaxis()->SetBinLabel(5,
"Print RP results");
2610 fIntFlowFlags->GetXaxis()->SetBinLabel(6,
"Print POI results");
2611 fIntFlowFlags->GetXaxis()->SetBinLabel(7,
"Print RF (rebinned in M) results");
2612 fIntFlowFlags->GetXaxis()->SetBinLabel(8,
"Corrected for NUA vs M?");
2613 fIntFlowFlags->GetXaxis()->SetBinLabel(9,
"Propagate errors to v_{n} from correlations?");
2614 fIntFlowFlags->GetXaxis()->SetBinLabel(10,
"Calculate cumulants vs M");
2615 fIntFlowFlags->GetXaxis()->SetBinLabel(11,
"fMinimumBiasReferenceFlow");
2616 fIntFlowFlags->GetXaxis()->SetBinLabel(12,
"fForgetAboutCovariances");
2618 fIntFlowFlags->GetXaxis()->SetBinLabel(14,
"fFillMultipleControlHistograms");
2619 fIntFlowFlags->GetXaxis()->SetBinLabel(15,
"Calculate all correlations vs M");
2620 fIntFlowFlags->GetXaxis()->SetBinLabel(16,
"fMultiplicityIs");
2622 fIntFlowFlags->GetXaxis()->SetBinLabel(18,
"fUse2DHistograms");
2623 fIntFlowFlags->GetXaxis()->SetBinLabel(19,
"fFillProfilesVsMUsingWeights");
2624 fIntFlowFlags->GetXaxis()->SetBinLabel(20,
"fUseQvectorTerms");
2629 fReQ =
new TMatrixD(12,9);
2630 fImQ =
new TMatrixD(12,9);
2631 fSpk =
new TMatrixD(8,9);
2632 fReQGF =
new TMatrixD(21,9);
2633 fImQGF =
new TMatrixD(21,9);
2635 TString intFlowCorrelationsEBEName =
"fIntFlowCorrelationsEBE";
2639 TString intFlowEventWeightsForCorrelationsEBEName =
"fIntFlowEventWeightsForCorrelationsEBE";
2640 intFlowEventWeightsForCorrelationsEBEName +=
fAnalysisLabel->Data();
2643 TString intFlowCorrelationsAllEBEName =
"fIntFlowCorrelationsAllEBE";
2648 TString fIntFlowCorrectionTermsForNUAEBEName =
"fIntFlowCorrectionTermsForNUAEBE";
2650 for(
Int_t sc=0;sc<2;sc++)
2652 fIntFlowCorrectionTermsForNUAEBE[sc] =
new TH1D(Form(
"%s: %s terms",fIntFlowCorrectionTermsForNUAEBEName.Data(),sinCosFlag[sc].Data()),Form(
"Correction terms for non-uniform acceptance (%s terms)",sinCosFlag[sc].
Data()),4,0,4);
2655 TString fIntFlowEventWeightForCorrectionTermsForNUAEBEName =
"fIntFlowEventWeightForCorrectionTermsForNUAEBE";
2656 fIntFlowEventWeightForCorrectionTermsForNUAEBEName +=
fAnalysisLabel->Data();
2657 for(
Int_t sc=0;sc<2;sc++)
2663 TString avMultiplicityName =
"fAvMultiplicity";
2665 fAvMultiplicity =
new TProfile(avMultiplicityName.Data(),
"Average multiplicities of reference particles (RPs)",9,0,9);
2682 TString correlationFlag[4] = {
"#LT#LT2#GT#GT",
"#LT#LT4#GT#GT",
"#LT#LT6#GT#GT",
"#LT#LT8#GT#GT"};
2683 TString intFlowCorrelationsProName =
"fIntFlowCorrelationsPro";
2685 fIntFlowCorrelationsPro =
new TProfile(intFlowCorrelationsProName.Data(),
"Average correlations for all events",4,0,4,
"s");
2691 for(
Int_t b=0;b<4;b++)
2697 TString squaredCorrelationFlag[4] = {
"#LT#LT2#GT^{2}#GT",
"#LT#LT4#GT^{2}#GT",
"#LT#LT6#GT^{2}#GT",
"#LT#LT8#GT^{2}#GT"};
2698 TString intFlowSquaredCorrelationsProName =
"fIntFlowSquaredCorrelationsPro";
2706 for(
Int_t b=0;b<4;b++)
2713 for(
Int_t ci=0;ci<4;ci++)
2716 TString intFlowCorrelationsVsMProName =
"fIntFlowCorrelationsVsMPro";
2718 fIntFlowCorrelationsVsMPro[ci] =
new TProfile(Form(
"%s, %s",intFlowCorrelationsVsMProName.Data(),correlationFlag[ci].Data()),
2719 Form(
"%s vs multiplicity",correlationFlag[ci].
Data()),
2735 TString intFlowSquaredCorrelationsVsMProName =
"fIntFlowSquaredCorrelationsVsMPro";
2738 Form(
"%s vs multiplicity",squaredCorrelationFlag[ci].
Data()),
2756 TString intFlowCorrelationsAllProName =
"fIntFlowCorrelationsAllPro";
2758 fIntFlowCorrelationsAllPro =
new TProfile(intFlowCorrelationsAllProName.Data(),
"Average all correlations for all events",64,0,64);
2864 fIntFlowCorrelationsAllVsMPro[30] =
new TProfile(
"eight1n1n1n1n1n1n1n1n",
"#LT#LT8#GT#GT_{n,n,n,n|n,n,n,n}",
fnBinsMult,
fMinMult,
fMaxMult);
2898 for(
Int_t n=0;n<63;n++)
2920 TString intFlowExtraCorrelationsProName =
"fIntFlowExtraCorrelationsPro";
2922 fIntFlowExtraCorrelationsPro =
new TProfile(intFlowExtraCorrelationsProName.Data(),
"Average extra correlations for all events",100,0,100,
"s");
2933 TString productFlag[6] = {
"#LT#LT2#GT#LT4#GT#GT",
"#LT#LT2#GT#LT6#GT#GT",
"#LT#LT2#GT#LT8#GT#GT",
2934 "#LT#LT4#GT#LT6#GT#GT",
"#LT#LT4#GT#LT8#GT#GT",
"#LT#LT6#GT#LT8#GT#GT"};
2935 TString intFlowProductOfCorrelationsProName =
"fIntFlowProductOfCorrelationsPro";
2942 for(
Int_t b=0;b<6;b++)
2951 TString intFlowProductOfCorrelationsVsMProName =
"fIntFlowProductOfCorrelationsVsMPro";
2952 intFlowProductOfCorrelationsVsMProName +=
fAnalysisLabel->Data();
2956 Form(
"%s versus multiplicity",productFlag[
pi].
Data()),
2972 TString intFlowProductOfCorrectionTermsForNUAProName =
"fIntFlowProductOfCorrectionTermsForNUAPro";
2973 intFlowProductOfCorrectionTermsForNUAProName +=
fAnalysisLabel->Data();
3008 for(
Int_t sc=0;sc<2;sc++)
3010 TString intFlowCorrectionTermsForNUAProName =
"fIntFlowCorrectionTermsForNUAPro";
3012 fIntFlowCorrectionTermsForNUAPro[sc] =
new TProfile(Form(
"%s: %s terms",intFlowCorrectionTermsForNUAProName.Data(),sinCosFlag[sc].Data()),Form(
"Correction terms for non-uniform acceptance (%s terms)",sinCosFlag[sc].
Data()),4,0,4,
"s");
3025 TString correctionTermFlag[4] = {
"(n(phi1))",
"(n(phi1+phi2))",
"(n(phi1-phi2-phi3))",
"(n(2phi1-phi2))"};
3026 for(
Int_t ci=0;ci<4;ci++)
3028 TString intFlowCorrectionTermsForNUAVsMProName =
"fIntFlowCorrectionTermsForNUAVsMPro";
3029 intFlowCorrectionTermsForNUAVsMProName +=
fAnalysisLabel->Data();
3030 fIntFlowCorrectionTermsForNUAVsMPro[sc][ci] =
new TProfile(Form(
"%s: #LT#LT%s%s#GT#GT",intFlowCorrectionTermsForNUAVsMProName.Data(),sinCosFlag[sc].Data(),correctionTermFlag[ci].Data()),Form(
"#LT#LT%s%s#GT#GT vs M",sinCosFlag[sc].
Data(),correctionTermFlag[ci].Data()),
fnBinsMult,
fMinMult,
fMaxMult,
"s");
3038 TString intFlowCorrelationsHistName =
"fIntFlowCorrelationsHist";
3053 for(
Int_t ci=0;ci<4;ci++)
3055 TString intFlowCorrelationsVsMHistName =
"fIntFlowCorrelationsVsMHist";
3058 Form(
"%s vs multiplicity",correlationFlag[ci].
Data()),
3075 TString intFlowCorrelationsAllHistName =
"fIntFlowCorrelationsAllHist";
3116 for(
Int_t sc=0;sc<2;sc++)
3118 TString intFlowCorrectionTermsForNUAHistName =
"fIntFlowCorrectionTermsForNUAHist";
3120 fIntFlowCorrectionTermsForNUAHist[sc] =
new TH1D(Form(
"%s: %s terms",intFlowCorrectionTermsForNUAHistName.Data(),sinCosFlag[sc].Data()),Form(
"Correction terms for non-uniform acceptance (%s terms)",sinCosFlag[sc].
Data()),4,0,4);
3132 TString intFlowCovariancesName =
"fIntFlowCovariances";
3134 fIntFlowCovariances =
new TH1D(intFlowCovariancesName.Data(),
"Covariances (multiplied with weight dependent prefactor)",6,0,6);
3145 TString intFlowSumOfEventWeightsName =
"fIntFlowSumOfEventWeights";
3147 for(
Int_t power=0;power<2;power++)
3149 fIntFlowSumOfEventWeights[power] =
new TH1D(Form(
"%s: %s",intFlowSumOfEventWeightsName.Data(),powerFlag[power].Data()),Form(
"Sum of %s event weights for correlations",powerFlag[power].
Data()),4,0,4);
3158 }
else if (power == 1)
3168 TString intFlowSumOfProductOfEventWeightsName =
"fIntFlowSumOfProductOfEventWeights";
3184 TString intFlowCovariancesVsMName =
"fIntFlowCovariancesVsM";
3186 TString covarianceFlag[6] = {
"Cov(<2>,<4>)",
"Cov(<2>,<6>)",
"Cov(<2>,<8>)",
"Cov(<4>,<6>)",
"Cov(<4>,<8>)",
"Cov(<6>,<8>)"};
3187 for(
Int_t ci=0;ci<6;ci++)
3190 Form(
"%s vs multiplicity",covarianceFlag[ci].
Data()),
3210 TString intFlowSumOfEventWeightsVsMName =
"fIntFlowSumOfEventWeightsVsM";
3212 TString sumFlag[2][4] = {{
"#sum_{i=1}^{N} w_{<2>}",
"#sum_{i=1}^{N} w_{<4>}",
"#sum_{i=1}^{N} w_{<6>}",
"#sum_{i=1}^{N} w_{<8>}"},
3213 {
"#sum_{i=1}^{N} w_{<2>}^{2}",
"#sum_{i=1}^{N} w_{<4>}^{2}",
"#sum_{i=1}^{N} w_{<6>}^{2}",
"#sum_{i=1}^{N} w_{<8>}^{2}"}};
3214 for(
Int_t si=0;si<4;si++)
3216 for(
Int_t power=0;power<2;power++)
3219 Form(
"%s vs multiplicity",sumFlag[power][si].
Data()),
3241 TString intFlowSumOfProductOfEventWeightsVsMName =
"fIntFlowSumOfProductOfEventWeightsVsM";
3242 intFlowSumOfProductOfEventWeightsVsMName +=
fAnalysisLabel->Data();
3243 TString sopowFlag[6] = {
"#sum_{i=1}^{N} w_{<2>} w_{<4>}",
"#sum_{i=1}^{N} w_{<2>} w_{<6>}",
"#sum_{i=1}^{N} w_{<2>} w_{<8>}",
3244 "#sum_{i=1}^{N} w_{<4>} w_{<6>}",
"#sum_{i=1}^{N} w_{<4>} w_{<8>}",
"#sum_{i=1}^{N} w_{<6>} w_{<8>}"};
3248 Form(
"%s versus multiplicity",sopowFlag[
pi].
Data()),
3265 TString intFlowCovariancesNUAName =
"fIntFlowCovariancesNUA";
3267 fIntFlowCovariancesNUA =
new TH1D(intFlowCovariancesNUAName.Data(),
"Covariances for NUA (multiplied with weight dependent prefactor)",27,0,27);
3286 (
fIntFlowCovariancesNUA->GetXaxis())->SetBinLabel(16,
"Cov(<cos(#phi)>,<cos(#phi_{1}-#phi_{2}-#phi_{3})>)");
3287 (
fIntFlowCovariancesNUA->GetXaxis())->SetBinLabel(17,
"Cov(<cos(#phi)>,<sin(#phi_{1}-#phi_{2}-#phi_{3})>)");
3290 (
fIntFlowCovariancesNUA->GetXaxis())->SetBinLabel(20,
"Cov(<sin(#phi)>,<cos(#phi_{1}-#phi_{2}-#phi_{3})>)");
3291 (
fIntFlowCovariancesNUA->GetXaxis())->SetBinLabel(21,
"Cov(<sin(#phi)>,<sin(#phi_{1}-#phi_{2}-#phi_{3})>)");
3292 (
fIntFlowCovariancesNUA->GetXaxis())->SetBinLabel(22,
"Cov(<cos(#phi_{1}+#phi_{2})>,<sin(#phi_{1}+#phi_{2})>)");
3293 (
fIntFlowCovariancesNUA->GetXaxis())->SetBinLabel(23,
"Cov(<cos(#phi_{1}+#phi_{2})>,<cos(#phi_{1}-#phi_{2}-#phi_{3})>)");
3294 (
fIntFlowCovariancesNUA->GetXaxis())->SetBinLabel(24,
"Cov(<cos(#phi_{1}+#phi_{2})>,<sin(#phi_{1}-#phi_{2}-#phi_{3})>)");
3295 (
fIntFlowCovariancesNUA->GetXaxis())->SetBinLabel(25,
"Cov(<sin(#phi_{1}+#phi_{2})>,<cos(#phi_{1}-#phi_{2}-#phi_{3})>)");
3296 (
fIntFlowCovariancesNUA->GetXaxis())->SetBinLabel(26,
"Cov(<sin(#phi_{1}+#phi_{2})>,<sin(#phi_{1}-#phi_{2}-#phi_{3})>)");
3297 (
fIntFlowCovariancesNUA->GetXaxis())->SetBinLabel(27,
"Cov(<cos(#phi_{1}-#phi_{2}-#phi_{3}>,<sin(#phi_{1}-#phi_{2}-#phi_{3}>)");
3300 TString intFlowSumOfEventWeightsNUAName =
"fIntFlowSumOfEventWeightsNUA";
3302 for(
Int_t sc=0;sc<2;sc++)
3304 for(
Int_t power=0;power<2;power++)
3306 fIntFlowSumOfEventWeightsNUA[sc][power] =
new TH1D(Form(
"%s: %s, %s",intFlowSumOfEventWeightsNUAName.Data(),powerFlag[power].Data(),sinCosFlag[sc].Data()),Form(
"Sum of %s event weights for NUA %s terms",powerFlag[power].
Data(),sinCosFlag[sc].Data()),4,0,4);
3315 }
else if(power == 1)
3319 (
fIntFlowSumOfEventWeightsNUA[sc][power]->GetXaxis())->SetBinLabel(3,Form(
"#sum_{i=1}^{N} w_{<%s(#phi_{1}-#phi_{2}-#phi_{3})>}^{2}",sinCosFlag[sc].
Data()));
3326 TString intFlowSumOfProductOfEventWeightsNUAName =
"fIntFlowSumOfProductOfEventWeightsNUA";
3327 intFlowSumOfProductOfEventWeightsNUAName +=
fAnalysisLabel->Data();
3360 TString cumulantFlag[4] = {
"QC{2}",
"QC{4}",
"QC{6}",
"QC{8}"};
3361 TString intFlowQcumulantsName =
"fIntFlowQcumulants";
3366 fIntFlowQcumulants->SetTitle(
"Reference Q-cumulants (error from non-isotropic terms also propagated)");
3370 for(
Int_t b=0;b<4;b++)
3378 TString intFlowQcumulantsRebinnedInMName =
"fIntFlowQcumulantsRebinnedInM";
3383 for(
Int_t b=0;b<4;b++)
3390 TString intFlowQcumulantsErrorSquaredRatioName =
"fIntFlowQcumulantsErrorSquaredRatio";
3391 intFlowQcumulantsErrorSquaredRatioName +=
fAnalysisLabel->Data();
3395 for(
Int_t b=0;b<4;b++)
3403 TString intFlowQcumulantsVsMName =
"fIntFlowQcumulantsVsM";
3405 for(
Int_t co=0;co<4;co++)
3408 Form(
"%s vs multiplicity",cumulantFlag[co].
Data()),
3425 TString flowFlag[4] = {Form(
"v_{%d}{2,QC}",
fHarmonic),Form(
"v_{%d}{4,QC}",
fHarmonic),Form(
"v_{%d}{6,QC}",
fHarmonic),Form(
"v_{%d}{8,QC}",
fHarmonic)};
3426 TString intFlowName =
"fIntFlow";
3429 fIntFlow =
new TH1D(intFlowName.Data(),
"Reference flow estimates from Q-cumulants",4,0,4);
3432 for(
Int_t b=0;b<4;b++)
3434 (
fIntFlow->GetXaxis())->SetBinLabel(b+1,flowFlag[b].
Data());
3440 TString intFlowRebinnedInMName =
"fIntFlowRebinnedInM";
3442 fIntFlowRebinnedInM =
new TH1D(intFlowRebinnedInMName.Data(),
"Reference flow estimates from Q-cumulants (rebinned in M)",4,0,4);
3445 for(
Int_t b=0;b<4;b++)
3454 TString intFlowVsMName =
"fIntFlowVsM";
3456 for(
Int_t co=0;co<4;co++)
3458 fIntFlowVsM[co] =
new TH1D(Form(
"%s, %s",intFlowVsMName.Data(),flowFlag[co].Data()),
3459 Form(
"%s vs multiplicity",flowFlag[co].
Data()),
3466 fIntFlowVsM[co]->GetXaxis()->SetTitle(
"Reference multiplicity (from ESD)");
3476 TString intFlowDetectorBiasName =
"fIntFlowDetectorBias";
3481 for(
Int_t ci=0;ci<4;ci++)
3483 (
fIntFlowDetectorBias->GetXaxis())->SetBinLabel(ci+1,Form(
"#frac{corrected}{measured} %s",cumulantFlag[ci].
Data()));
3489 TString intFlowDetectorBiasVsMName =
"fIntFlowDetectorBiasVsM";
3491 for(
Int_t ci=0;ci<4;ci++)
3494 Form(
"Quantifying detector bias for %s vs multiplicity",cumulantFlag[ci].
Data()),
3523 TString controlHistogramsFlagsName =
"fControlHistogramsFlags";
3525 fControlHistogramsFlags =
new TProfile(controlHistogramsFlagsName.Data(),
"Flags for Control Histograms",2,0,2);
3539 TString sCorrelationNoRPsVsRefMultName =
"fCorrelationNoRPsVsRefMult";
3550 TString sCorrelationNoPOIsVsRefMultName =
"fCorrelationNoPOIsVsRefMult";
3561 TString sCorrelationNoRPsVsNoPOIsName =
"fCorrelationNoRPsVsNoPOIs";
3572 TString sCorrelation[4] = {
"#LT2#GT",
"#LT4#GT",
"#LT6#GT",
"#LT8#GT"};
3576 sMultiplicity =
"# RPs";
3579 sMultiplicity =
"Reference multiplicity (from ESD)";
3582 sMultiplicity =
"# POIs";
3584 for(
Int_t ci=0;ci<4;ci++)
3596 TString sCorrelationProduct[1] = {
"#LT2#GT#LT4#GT"};
3597 for(
Int_t cpi=0;cpi<1;cpi++)
3611 TString sQvectorTerms[4] = {
"#frac{|Q_{n}|^{2}}{M}",
"#frac{|Q_{2n}|^{2}}{M}",
"#frac{|Q_{n}|^{4}}{M(2M-1)}",
"#frac{Re[Q_{2n}Q_{n}^{*}Q_{n}^{*}]}{M^{3/2}}"};
3612 for(
Int_t qvti=0;qvti<4;qvti++)
3639 TString bootstrapFlagsName =
"fBootstrapFlags";
3641 fBootstrapFlags =
new TProfile(bootstrapFlagsName.Data(),
"Flags for bootstrap",3,0,3);
3653 TString correlationFlag[4] = {
"#LT#LT2#GT#GT",
"#LT#LT4#GT#GT",
"#LT#LT6#GT#GT",
"#LT#LT8#GT#GT"};
3654 TString cumulantFlag[4] = {
"QC{2}",
"QC{4}",
"QC{6}",
"QC{8}"};
3658 TString bootstrapCorrelationsName =
"fBootstrapCorrelations";
3662 for(
Int_t ci=0;ci<4;ci++)
3672 TString bootstrapCumulantsName =
"fBootstrapCumulants";
3676 for(
Int_t co=0;co<4;co++)
3691 sMultiplicity =
"# RPs";
3694 sMultiplicity =
"Reference multiplicity (from ESD)";
3697 sMultiplicity =
"# POIs";
3702 TString bootstrapCorrelationsVsMName =
"fBootstrapCorrelationsVsM";
3704 for(
Int_t ci=0;ci<4;ci++)
3706 fBootstrapCorrelationsVsM[ci] =
new TProfile2D(Form(
"%s, %s",bootstrapCorrelationsVsMName.Data(),correlationFlag[ci].Data()),
3707 Form(
"Bootstrap Correlations Vs. M, %s",correlationFlag[ci].
Data()),
3718 TString bootstrapCumulantsVsMName =
"fBootstrapCumulantsVsM";
3720 for(
Int_t co=0;co<4;co++)
3723 Form(
"Bootstrap Cumulants Vs. M, %s",cumulantFlag[co].
Data()),
3749 TString mixedHarmonicsFlagsName =
"fMixedHarmonicsFlags";
3751 fMixedHarmonicsFlags =
new TProfile(mixedHarmonicsFlagsName.Data(),
"Flags for Mixed Harmonics",4,0,4);
3767 TString s2pCorrelationsName =
"f2pCorrelations";
3769 f2pCorrelations =
new TProfile(s2pCorrelationsName.Data(),Form(
"2-particle correlations (n = %d)",
fHarmonic),6,0,6,
"s");
3784 TString s3pCorrelationsName =
"f3pCorrelations";
3786 f3pCorrelations =
new TProfile(s3pCorrelationsName.Data(),Form(
"3-particle correlations (n = %d)",
fHarmonic),10,0,10,
"s");
3807 TString s4pCorrelationsName =
"f4pCorrelations";
3809 f4pCorrelations =
new TProfile(s4pCorrelationsName.Data(),Form(
"4-particle correlations (n = %d)",
fHarmonic),45,0,45,
"s");
3868 TString s5pCorrelationsName =
"f5pCorrelations";
3870 f5pCorrelations =
new TProfile(s5pCorrelationsName.Data(),Form(
"5-particle correlations (n = %d)",
fHarmonic),87,0,87,
"s");
3971 TString s6pCorrelationsName =
"f6pCorrelations";
3973 f6pCorrelations =
new TProfile(s6pCorrelationsName.Data(),Form(
"6-particle correlations (n = %d)",
fHarmonic),1,0.,1.);
3982 TString s7pCorrelationsName =
"f7pCorrelations";
3984 f7pCorrelations =
new TProfile(s7pCorrelationsName.Data(),Form(
"7-particle correlations (n = %d)",
fHarmonic),1,0.,1.);
3993 TString s8pCorrelationsName =
"f8pCorrelations";
3995 f8pCorrelations =
new TProfile(s8pCorrelationsName.Data(),Form(
"8-particle correlations (n = %d)",
fHarmonic),1,0.,1.);
4040 TString mixedHarmonicEventWeightsName =
"fMixedHarmonicEventWeights";
4042 TString powerFlag[2] = {
"linear",
"quadratic"};
4043 for(
Int_t power=0;power<2;power++)
4045 fMixedHarmonicEventWeights[power] =
new TH1D(Form(
"%s: %s",mixedHarmonicEventWeightsName.Data(),powerFlag[power].Data()),Form(
"Sum of %s event weights for correlations",powerFlag[power].
Data()),8,0.,8.);
4059 }
else if (power == 1)
4074 TString mixedHarmonicProductOfEventWeightsName =
"fMixedHarmonicProductOfEventWeights";
4075 mixedHarmonicProductOfEventWeightsName +=
fAnalysisLabel->Data();
4080 for(
Int_t b=1;b<=8;b++)
4088 TString mixedHarmonicProductOfCorrelationsName =
"fMixedHarmonicProductOfCorrelations";
4089 mixedHarmonicProductOfCorrelationsName +=
fAnalysisLabel->Data();