]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWGCF/FEMTOSCOPY/Chaoticity/AliFourPion.h
Merge branch 'feature-movesplit'
[u/mrichter/AliRoot.git] / PWGCF / FEMTOSCOPY / Chaoticity / AliFourPion.h
CommitLineData
be9ef9f9 1#ifndef AliFourPion_cxx
2#define AliFourPion_cxx
3//
4// Class AliFourPion
5//
6// AliFourPion
7// author:
8// Dhevan Gangadharan (dhevan.raja.gangadharan@cern.ch)
9//
10
11
12
13class TH1F;
14class TH3F;
15class TH1D;
16class TH2D;
17class TH3D;
18
19class TProfile;
20class TProfile2D;
78c3bd48 21class TProfile3D;
be9ef9f9 22class TRandom3;
23
24class AliESDEvent;
25class AliAODEvent;
26class AliESDtrackCuts;
27class AliESDpid;
28
29#include "AliAnalysisTask.h"
30#include "AliAnalysisTaskSE.h"
31#include "AliESDpid.h"
32#include "AliAODPid.h"
33#include "AliFourPionEventCollection.h"
34#include "AliCentrality.h"
35
36class AliFourPion : public AliAnalysisTaskSE {
37 public:
38
39 AliFourPion();
40 AliFourPion(const Char_t *name);
41 virtual ~AliFourPion();
42 AliFourPion(const AliFourPion &obj);
43 AliFourPion &operator=(const AliFourPion &obj);
44
45
46 virtual void UserCreateOutputObjects();
47 virtual void UserExec(Option_t *option);
48 virtual void Terminate(Option_t *);
49
50 enum {
51 kPairLimit = 10000,//10000
52 kNormPairLimit = 45000,
53 kMultLimitPbPb = 1800,//1800
54 kMultLimitpp = 300,
0207c034 55 kMultBinspp = 10,
be9ef9f9 56 kMCarrayLimit = 150000,// 110000
57 kQbinsWeights = 40,
58 kNDampValues = 16,
59 kRmin = 5,// EW min radii 5 fm
574647ef 60 kDENtypes = 179,// was 104
be9ef9f9 61 };
62
63 static const Int_t fKbinsT = 4;// Set fKstep as well !!!!
64 static const Int_t fKbinsY = 1;// Set fKstep as well !!!!
70a43d86 65 static const Int_t fEDbins = 4;
be9ef9f9 66 static const Int_t fCentBins = 10;// 0-50%
0207c034 67 static const Int_t fMbinsMixing = 10;// 5% widths
be9ef9f9 68 static const Int_t fRVALUES = 7;// 7 EW radii (5-11) , was 8 Gaussian radii (3-10fm)
69
70
71 Int_t GetNumKtBins() const {return AliFourPion::fKbinsT;}
72 Int_t GetNumRValues() const {return AliFourPion::fRVALUES;}
73 Int_t GetNumCentBins() const {return AliFourPion::fCentBins;}
74 Int_t GetNumEDBins() const {return AliFourPion::fEDbins;}
75 void SetWeightArrays(Bool_t legoCase=kTRUE, TH3F *histos[AliFourPion::fKbinsT][AliFourPion::fCentBins]=0x0);
80507acf 76 void SetMomResCorrections(Bool_t legoCase=kTRUE, TH2D *temp2DSC=0x0, TH2D *temp2DMC=0x0);
be9ef9f9 77 void SetFSICorrelations(Bool_t legoCase=kTRUE, TH1D *tempss[12]=0x0, TH1D *tempos[12]=0x0);
5591748e 78 void SetMuonCorrections(Bool_t legoCase=kTRUE, TH2D *tempMuon=0x0);
70a43d86 79 void Setc3FitEAs(Bool_t legoCase=kTRUE, TH3D *histoPbPb[2]=0x0, TH3D *histopPb[2]=0x0, TH3D *histopp[2]=0x0);
be9ef9f9 80 //
81 void SetMCdecision(Bool_t mc) {fMCcase = mc;}
82 void SetTabulatePairs(Bool_t tabulate) {fTabulatePairs = tabulate;}
95567836 83 void SetInterpolationType(Bool_t linearInterp) {fLinearInterpolation = linearInterp;}
803ae3ce 84 void SetCollisionType(Short_t ct) {fCollisionType = ct;}
be9ef9f9 85 void SetGenerateSignal(Bool_t gen) {fGenerateSignal = gen;}
86 void SetGeneratorOnly(Bool_t genOnly) {fGeneratorOnly = genOnly;}
87 void SetCentBinRange(Int_t low, Int_t high) {fCentBinLowLimit = low; fCentBinHighLimit = high;}
88 void SetLEGOCase(Bool_t lego) {fLEGO = lego;}
89 void SetFilterBit(UInt_t filterbit) {fFilterBit = filterbit;}
90 void SetMaxChi2NDF(Float_t MaxChi2NDF) {fMaxChi2NDF = MaxChi2NDF;}
91 void SetMinTPCncls(Int_t MinTPCncls) {fMinTPCncls = MinTPCncls;}
574647ef 92 void SetEAtype(Int_t eat) {fEAtype = eat;}
be9ef9f9 93 void SetPairSeparationCutEta(Float_t pairsep) {fMinSepPairEta = pairsep;}
94 void SetPairSeparationCutPhi(Float_t pairsep) {fMinSepPairPhi = pairsep;}
95 void SetNsigmaTPC(Float_t nsig) {fSigmaCutTPC = nsig;}
96 void SetNsigmaTOF(Float_t nsig) {fSigmaCutTOF = nsig;}
97 void SetRMax(Int_t rbin) {fRMax = rbin;}
98 void SetfcSq(Float_t fcSq) {ffcSq = fcSq;}
42802bba 99 void SetMixedChargeCut(Bool_t mcCut) {fMixedChargeCut = mcCut;}
100 void SetMinPt(Float_t minPt) {fMinPt = minPt;}
101 void SetMaxPt(Float_t maxPt) {fMaxPt = maxPt;}
102 void SetKT3transition(Float_t KT3trans) {fKT3transition = KT3trans;}
103 void SetKT4transition(Float_t KT4trans) {fKT4transition = KT4trans;}
0207c034 104 void SetTriggerType(Int_t tt) {fTriggerType = tt;}
d3df474e 105 void SetNormLow(Float_t nl) {fNormQcutLow = nl;}
106 void SetNormHigh(Float_t nh) {fNormQcutHigh = nh;}
52b6cc66 107 void SetFSIindexSmallSystem(Int_t ind) {fFSIindexSmallSystem = ind;}
70a43d86 108 void Setq2Binning(Bool_t qb) {fq2Binning = qb;}
109 void Setq2Index(Int_t q2i) {fq2Index = q2i;}
110 void Setq2CutLow(Float_t q2l) {fq2CutLow = q2l;}
111 void Setq2CutHigh(Float_t q2h) {fq2CutHigh = q2h;}
be9ef9f9 112 //
d3df474e 113
be9ef9f9 114
115 private:
116
117 void ParInit();
118 Bool_t AcceptPair(AliFourPionTrackStruct, AliFourPionTrackStruct);
fac2d84b 119 Bool_t AcceptPairPM(AliFourPionTrackStruct, AliFourPionTrackStruct);
fcb16ac9 120 Float_t Gamov(Int_t, Int_t, Float_t);
be9ef9f9 121 void Shuffle(Int_t*, Int_t, Int_t);
122 Float_t GetQinv(Float_t[], Float_t[]);
123 void GetQosl(Float_t[], Float_t[], Float_t&, Float_t&, Float_t&);
124 void GetWeight(Float_t[], Float_t[], Float_t&, Float_t&);
125 Float_t FSICorrelation(Int_t, Int_t, Float_t);
126 Float_t MCWeight(Int_t[2], Float_t, Float_t, Float_t, Float_t);
127 Float_t MCWeightOSL(Int_t, Int_t, Int_t, Int_t, Float_t, Float_t, Float_t, Float_t);
128 Float_t MCWeight3(Int_t, Float_t, Float_t, Int_t[3], Float_t[3], Float_t[3]);
129 Float_t MCWeightFSI3(Int_t, Float_t, Float_t, Int_t[3], Float_t[3]);
130 Float_t MCWeight4(Int_t, Float_t, Float_t, Int_t[4], Float_t[6], Float_t[6]);
131 Float_t MCWeightFSI4(Int_t, Float_t, Float_t, Int_t[4], Float_t[6]);
132 //
133 void SetFillBins2(Int_t, Int_t, Int_t&, Int_t&);
134 void SetFillBins3(Int_t, Int_t, Int_t, Short_t, Int_t&, Int_t&, Int_t&, Bool_t&, Bool_t&, Bool_t&);
6bb6954b 135 void SetFillBins4(Int_t, Int_t, Int_t, Int_t, Int_t&, Int_t&, Int_t&, Int_t&, Int_t, Bool_t[13]);
be9ef9f9 136 void SetFSIindex(Float_t);
137 //
95567836 138 Float_t cubicInterpolate(Float_t[4], Float_t);
139 Float_t nCubicInterpolate(Int_t, Float_t*, Float_t[]);
2b6fd022 140
be9ef9f9 141
142 const char* fname;// name of class
143 AliAODEvent *fAOD; //! // AOD object
144 TList *fOutputList; //! Compact Output list
145 AliPIDResponse *fPIDResponse; //! PID response object; equivalent to AliAODpidUtil
146
147
148 AliFourPionEventCollection ***fEC; //!
149 AliFourPionEventStruct *fEvt; //!
150 AliFourPionTrackStruct *fTempStruct; //!
151 TRandom3* fRandomNumber; //!
152
153
154
155 //////////////////////////////
156 // histogram structures
157
158
159 struct St6 {
160 TH1D *fNorm3; //!
161 TH1D *fTerms3; //!
78c3bd48 162 TH3D *fTerms33D; //!
be9ef9f9 163 TProfile *fKfactor; //!
78c3bd48 164 TProfile3D *fKfactor3D; //!
80507acf 165 TProfile *fKfactorWeighted; //!
be9ef9f9 166 TProfile *fMeanQinv; //!
167 TH2D *fIdeal; //!
168 TH2D *fSmeared; //!
169 //
5591748e 170 TH3D *fMuonSmeared; //!
171 TH3D *fMuonIdeal; //!
172 TH3D *fMuonPionK3; //!
173 TH3D *fPionPionK3; //!
174 //
574647ef 175 TH2D *fBuild; //!
176 TH2D *fBuildNeg; //!
177 TH2D *fBuildErr; //!
be9ef9f9 178 };
179 struct St7 {
180 TH3D *fTerms2OSL; //!
181 TH3D *fTerms2OSLQW; //!
182 };
183 struct St5 {
184 TH2D *fTerms2; //!
185 TH2D *fTerms2QW; //!
186 TH3D *fTerms2ThreeD; //!
187 TProfile2D *fAvgP; //!
188 TH2D *fIdeal; //!
189 TH2D *fSmeared; //!
190 TH2D *fUnitMultBin; //!
191 //
192 TH2D *fMuonSmeared; //!
193 TH2D *fMuonIdeal; //!
194 TH2D *fMuonPionK2; //!
195 TH2D *fPionPionK2; //!
196 TH1D *fMCqinv; //!
197 TH1D *fMCqinvQW; //!
198 TH2D *fPIDpurityDen; //!
199 TH3D *fPIDpurityNum; //!
200 struct St7 OSL_ktbin[2];
201 };
202 struct StFourPT {
203 TH1D *fNorm4; //!
204 TH1D *fTerms4; //!
205 TProfile *fKfactor; //!
80507acf 206 TProfile *fKfactorWeighted; //!
be9ef9f9 207 TH2D *fIdeal; //!
208 TH2D *fSmeared; //!
209 //
5591748e 210 TH3D *fMuonSmeared; //!
211 TH3D *fMuonIdeal; //!
212 TH3D *fMuonPionK4; //!
213 TH3D *fPionPionK4; //!
214 //
574647ef 215 TH2D *fBuild; //!
216 TH2D *fPrimeBuild; //!
217 TH2D *fPrimePrimeBuild; //!
218 TH2D *fCumulantBuild; //!
219 TH2D *fBuildNeg; //!
220 TH2D *fPrimeBuildNeg; //!
221 TH2D *fPrimePrimeBuildNeg; //!
222 TH2D *fCumulantBuildNeg; //!
223 //
224 TH2D *fBuildErr; //!
225 //
70a43d86 226 TH3D *fBuildFromFits; //!
227 TH3D *fPrimeBuildFromFits; //!
228 TH3D *fPrimePrimeBuildFromFits; //!
229 TH3D *fCumulantBuildFromFits; //!
be9ef9f9 230 };
231 struct St_EDB {
232 struct St5 TwoPT[2];
233 struct St6 ThreePT[5];
6bb6954b 234 struct StFourPT FourPT[13];
be9ef9f9 235 };
236 struct St_M {
237 struct St_EDB EDB[fEDbins];
238 };
239 struct St4 {
240 struct St_M MB[fCentBins];
241 };
242 struct St3 {
243 struct St4 Charge4[2];
244 struct St_M MB[fCentBins];
245 };
246 struct St2 {
247 struct St3 Charge3[2];
248 struct St_M MB[fCentBins];
249 };
250 struct St1 {
251 struct St2 Charge2[2];
252 };
253 struct St1 Charge1[2];//!
254
255
256 /////////////////////
257 // 4D r3 denominator
258 struct St_Ky {
259 struct St_M MB[fCentBins];
260 };
261 struct St_Kt {
262 struct St_Ky KY[fKbinsY];
263 };
264 struct St_Kt KT[fKbinsT];//!
265
266
267 Bool_t fLEGO;
268 Bool_t fMCcase;
269 Bool_t fAODcase;
ebd00f1b 270 Short_t fCollisionType;
be9ef9f9 271 Bool_t fGenerateSignal;
272 Bool_t fGeneratorOnly;
be9ef9f9 273 Bool_t fTabulatePairs;
95567836 274 Bool_t fLinearInterpolation;
42802bba 275 Bool_t fMixedChargeCut;
be9ef9f9 276 Int_t fRMax;
78c3bd48 277 Float_t fRstartMC;
be9ef9f9 278 Float_t ffcSq;
80507acf 279 Float_t ffcSqMRC;
be9ef9f9 280 UInt_t fFilterBit;
281 Float_t fMaxChi2NDF;
282 Int_t fMinTPCncls;
574647ef 283 Int_t fEAtype;
be9ef9f9 284 Double_t fBfield;
285 Int_t fMbin;
286 Int_t fFSIindex;
52b6cc66 287 Int_t fFSIindexSmallSystem;
be9ef9f9 288 Int_t fEDbin;
289 Int_t fMbins;
290 Int_t fMultLimit;
291 Int_t fCentBinLowLimit;
292 Int_t fCentBinHighLimit;
0207c034 293 Int_t fTriggerType;
be9ef9f9 294 Int_t fEventCounter;
295 Int_t fEventsToMix;
296 Int_t fZvertexBins;
297 Int_t fMultLimits[kMultBinspp+1];
42802bba 298 Float_t fMinPt;
299 Float_t fMaxPt;
be9ef9f9 300 Float_t fQcut;
301 Float_t fQLowerCut;
302 Float_t fNormQcutLow;
303 Float_t fNormQcutHigh;
304 Float_t fKupperBound;
0c82e40e 305 Double_t fQupperBoundQ2;
306 Double_t fQupperBoundQ3;
307 Double_t fQupperBoundQ4;
308 Int_t fQbinsQ2;
309 Int_t fQbinsQ3;
310 Int_t fQbinsQ4;
311 Double_t fQupperBoundWeights;
312 Int_t fQbinsQinv3D;
313 Double_t fQupperBoundQinv3D;
be9ef9f9 314 Float_t fKstepT[fKbinsT];
315 Float_t fKstepY[fKbinsY];
316 Float_t fKmeanT[fKbinsT];
317 Float_t fKmeanY[fKbinsY];
318 Float_t fKmiddleT[fKbinsT];
319 Float_t fKmiddleY[fKbinsY];
320 Float_t fQstep;
321 Float_t fQstepWeights;
322 Float_t fQmean[kQbinsWeights];
323 Float_t fDampStart;
324 Float_t fDampStep;
70a43d86 325 Bool_t fq2Binning;
326 Int_t fq2Index;
327 Float_t fq2CutLow;
328 Float_t fq2CutHigh;
be9ef9f9 329 Float_t fTPCTOFboundry;
330 Float_t fTOFboundry;
331 Float_t fSigmaCutTPC;
332 Float_t fSigmaCutTOF;
333
334 Float_t fMinSepPairEta;
335 Float_t fMinSepPairPhi;
336 Float_t fShareQuality;
337 Float_t fShareFraction;
338
339 Float_t fTrueMassP, fTrueMassPi, fTrueMassK, fTrueMassKs, fTrueMassLam;
340
341 Int_t fKtIndexL,fKtIndexH;
342 //
343 Int_t fQoIndexL,fQoIndexH;
344 Int_t fQsIndexL,fQsIndexH;
345 Int_t fQlIndexL,fQlIndexH;
346
347 Bool_t fDummyB;
348
349 Float_t fKT3transition;
350 Float_t fKT4transition;
351
95567836 352 Float_t farrP1[4][4][4];
353 Float_t farrP2[4][4][4];
b71263d0 354
2b6fd022 355
b71263d0 356 //
357 Char_t fDefaultsCharSwitch[kMultLimitPbPb];//!
358 TArrayC *fLowQPairSwitch_E0E0[kMultLimitPbPb];//!
359 TArrayC *fLowQPairSwitch_E0E1[kMultLimitPbPb];//!
360 TArrayC *fLowQPairSwitch_E0E2[kMultLimitPbPb];//!
361 TArrayC *fLowQPairSwitch_E0E3[kMultLimitPbPb];//!
6bb6954b 362 TArrayC *fLowQPairSwitch_E1E1[kMultLimitPbPb];//!
b71263d0 363 TArrayC *fLowQPairSwitch_E1E2[kMultLimitPbPb];//!
364 TArrayC *fLowQPairSwitch_E1E3[kMultLimitPbPb];//!
365 TArrayC *fLowQPairSwitch_E2E3[kMultLimitPbPb];//!
366 //
367 TArrayC *fNormQPairSwitch_E0E0[kMultLimitPbPb];//!
368 TArrayC *fNormQPairSwitch_E0E1[kMultLimitPbPb];//!
369 TArrayC *fNormQPairSwitch_E0E2[kMultLimitPbPb];//!
370 TArrayC *fNormQPairSwitch_E0E3[kMultLimitPbPb];//!
6bb6954b 371 TArrayC *fNormQPairSwitch_E1E1[kMultLimitPbPb];//!
b71263d0 372 TArrayC *fNormQPairSwitch_E1E2[kMultLimitPbPb];//!
373 TArrayC *fNormQPairSwitch_E1E3[kMultLimitPbPb];//!
374 TArrayC *fNormQPairSwitch_E2E3[kMultLimitPbPb];//!
375
ebd00f1b 376
be9ef9f9 377
378 public:
80507acf 379 TH2D *fMomResC2SC;
380 TH2D *fMomResC2MC;
5591748e 381 TH2D *fWeightmuonCorrection;
70a43d86 382 TH3D *fPbPbc3FitEA[2];
383 TH3D *fpPbc3FitEA[2];
384 TH3D *fppc3FitEA[2];
52b6cc66 385 TH1D *fFSIss[13];
386 TH1D *fFSIos[13];
be9ef9f9 387 TH3F *fNormWeight[fKbinsT][fCentBins];
70a43d86 388 TF1 *ExchangeAmp[7][50][2];
be9ef9f9 389
390 ClassDef(AliFourPion, 1);
391};
392
393#endif