1 /**************************************************************************
2 * Author: Panos Christakoglou. *
3 * Contributors are mentioned in the code where appropriate. *
5 * Permission to use, copy, modify and distribute this software and its *
6 * documentation strictly for non-commercial purposes is hereby granted *
7 * without fee, provided that the above copyright notice appears in all *
8 * copies and that both the copyright notice and this permission notice *
9 * appear in the supporting documentation. The authors make no claims *
10 * about the suitability of this software for any purpose. It is *
11 * provided "as is" without express or implied warranty. *
12 **************************************************************************/
14 /* $Id: AliProtonQAAnalysis.cxx 29114 2008-10-03 16:49:02Z pchrist $ */
16 //-----------------------------------------------------------------
17 // AliProtonQAAnalysis class
18 // This is the class to deal with the proton analysis
19 // Origin: Panos Christakoglou | Panos.Christakoglou@cern.ch
20 //-----------------------------------------------------------------
21 #include <Riostream.h>
28 #include <TParticle.h>
30 #include "AliProtonQAAnalysis.h"
31 #include "AliProtonAnalysisBase.h"
33 #include <AliExternalTrackParam.h>
34 #include <AliESDEvent.h>
38 #include <AliESDVertex.h>
39 #include <AliGenEventHeader.h>
40 #include <AliMCEvent.h>
42 ClassImp(AliProtonQAAnalysis)
44 //____________________________________________________________________//
45 AliProtonQAAnalysis::AliProtonQAAnalysis() :
46 TObject(), fProtonAnalysisBase(0),
47 fNBinsY(0), fMinY(0), fMaxY(0), fY(0),
48 fNBinsPt(0), fMinPt(0), fMaxPt(0), fPt(0), fUseAsymmetricBinning(kFALSE),
49 fGlobalQAList(0), fQAVertexList(0), fQA2DList(0),
50 fQAPrimaryProtonsAcceptedList(0),
51 fQAPrimaryProtonsRejectedList(0),
52 fQASecondaryProtonsAcceptedList(0),
53 fQASecondaryProtonsRejectedList(0),
54 fQAPrimaryAntiProtonsAcceptedList(0),
55 fQAPrimaryAntiProtonsRejectedList(0),
56 fQASecondaryAntiProtonsAcceptedList(0),
57 fQASecondaryAntiProtonsRejectedList(0),
58 fPDGList(0), fMCProcessesList(0),
59 fRunMCAnalysis(kFALSE),
60 fMCProcessIdFlag(kFALSE), fMCProcessId(0),
61 fMotherParticlePDGCodeFlag(kFALSE), fMotherParticlePDGCode(0),
62 fAcceptedCutList(0), fRejectedCutList(0),
63 fAcceptedDCAList(0), fRejectedDCAList(0),
64 fRunEfficiencyAnalysis(kFALSE),
65 fUseCutsInEfficiency(kFALSE),
66 fEfficiencyList(0), fCutEfficiencyList(0) {
70 //____________________________________________________________________//
71 AliProtonQAAnalysis::~AliProtonQAAnalysis() {
73 if(fProtonAnalysisBase) delete fProtonAnalysisBase;
74 if(fGlobalQAList) delete fGlobalQAList;
75 if(fQAVertexList) delete fQAVertexList;
76 if(fQA2DList) delete fQA2DList;
77 if(fQAPrimaryProtonsAcceptedList) delete fQAPrimaryProtonsAcceptedList;
78 if(fQAPrimaryProtonsRejectedList) delete fQAPrimaryProtonsRejectedList;
79 if(fQASecondaryProtonsAcceptedList) delete fQASecondaryProtonsAcceptedList;
80 if(fQASecondaryProtonsRejectedList) delete fQASecondaryProtonsRejectedList;
81 if(fQAPrimaryAntiProtonsAcceptedList)
82 delete fQAPrimaryAntiProtonsAcceptedList;
83 if(fQAPrimaryAntiProtonsRejectedList)
84 delete fQAPrimaryAntiProtonsRejectedList;
85 if(fQASecondaryAntiProtonsAcceptedList)
86 delete fQASecondaryAntiProtonsAcceptedList;
87 if(fQASecondaryAntiProtonsRejectedList)
88 delete fQASecondaryAntiProtonsRejectedList;
90 if(fPDGList) delete fPDGList;
91 if(fMCProcessesList) delete fMCProcessesList;
93 if(fAcceptedCutList) delete fAcceptedCutList;
94 if(fRejectedCutList) delete fRejectedCutList;
95 if(fAcceptedDCAList) delete fAcceptedDCAList;
96 if(fRejectedDCAList) delete fRejectedDCAList;
98 if(fEfficiencyList) delete fEfficiencyList;
99 if(fCutEfficiencyList) delete fCutEfficiencyList;
102 //____________________________________________________________________//
103 void AliProtonQAAnalysis::FillQA(AliStack *const stack,
105 const AliESDVertex *vertex,
106 AliESDtrack* track) {
107 // Checks if the track is excluded from the cuts
108 Int_t nPrimaries = stack->GetNprimary();
109 Int_t label = TMath::Abs(track->GetLabel());
111 Double_t gPt = 0.0, gPx = 0.0, gPy = 0.0, gPz = 0.0;
112 Double_t dca[2] = {0.0,0.0}, cov[3] = {0.0,0.0,0.0}; //The impact parameters and their covariance.
114 if((fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kTPC)||(fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kHybrid)) {
115 AliExternalTrackParam *tpcTrack = (AliExternalTrackParam *)track->GetTPCInnerParam();
117 gPt = 0.0; gPx = 0.0; gPy = 0.0; gPz = 0.0;
118 dca[0] = -100.; dca[1] = -100.;
119 cov[0] = -100.; cov[1] = -100.; cov[2] = -100.;
122 gPt = tpcTrack->Pt();
123 gPx = tpcTrack->Px();
124 gPy = tpcTrack->Py();
125 gPz = tpcTrack->Pz();
126 tpcTrack->PropagateToDCA(vertex,
127 esd->GetMagneticField(),
136 track->PropagateToDCA(vertex,
137 esd->GetMagneticField(),
141 //TParticle *particle = stack->Particle(label);
143 //Int_t pdgcode = particle->GetPdgCode();
144 //Int_t gProcess = particle->GetUniqueID();
146 Int_t nClustersITS = track->GetITSclusters(fIdxInt);
147 Int_t nClustersTPC = track->GetTPCclusters(fIdxInt);
149 Float_t chi2PerClusterITS = -1;
151 chi2PerClusterITS = track->GetITSchi2()/Float_t(nClustersITS);
152 Float_t chi2PerClusterTPC = -1;
154 chi2PerClusterTPC = track->GetTPCchi2()/Float_t(nClustersTPC);
157 track->GetExternalCovariance(extCov);
160 if(track->Charge() > 0) {
162 if(label <= nPrimaries) {
163 if(fProtonAnalysisBase->IsUsedMinITSClusters()) {
164 if(nClustersITS < fProtonAnalysisBase->GetMinITSClusters()) {
165 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(0)))->Fill(nClustersITS);
167 else if(nClustersITS >= fProtonAnalysisBase->GetMinITSClusters())
168 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(0)))->Fill(nClustersITS);
170 if(fProtonAnalysisBase->IsUsedMaxChi2PerITSCluster()) {
171 if(chi2PerClusterITS > fProtonAnalysisBase->GetMaxChi2PerITSCluster()) {
172 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(1)))->Fill(chi2PerClusterITS);
174 else if(chi2PerClusterITS <= fProtonAnalysisBase->GetMaxChi2PerITSCluster())
175 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(1)))->Fill(chi2PerClusterITS);
176 }//chi2 per ITS cluster
177 if(fProtonAnalysisBase->IsUsedMinTPCClusters()) {
178 if(nClustersTPC < fProtonAnalysisBase->GetMinTPCClusters()) {
179 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(2)))->Fill(nClustersTPC);
181 else if(nClustersTPC >= fProtonAnalysisBase->GetMinTPCClusters()) {
182 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(2)))->Fill(nClustersTPC);
185 if(fProtonAnalysisBase->IsUsedMaxChi2PerTPCCluster()) {
186 if(chi2PerClusterTPC > fProtonAnalysisBase->GetMaxChi2PerTPCCluster()) {
187 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(3)))->Fill(chi2PerClusterTPC);
189 else if(chi2PerClusterTPC <= fProtonAnalysisBase->GetMaxChi2PerTPCCluster())
190 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(3)))->Fill(chi2PerClusterTPC);
191 }//chi2 per TPC cluster
192 if(fProtonAnalysisBase->IsUsedMaxCov11()) {
193 if(extCov[0] > fProtonAnalysisBase->GetMaxCov11()) {
194 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(4)))->Fill(extCov[0]);
196 else if(extCov[0] <= fProtonAnalysisBase->GetMaxCov11())
197 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(4)))->Fill(extCov[0]);
199 if(fProtonAnalysisBase->IsUsedMaxCov22()) {
200 if(extCov[2] > fProtonAnalysisBase->GetMaxCov22()) {
201 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(5)))->Fill(extCov[2]);
203 else if(extCov[2] <= fProtonAnalysisBase->GetMaxCov22())
204 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(5)))->Fill(extCov[2]);
206 if(fProtonAnalysisBase->IsUsedMaxCov33()) {
207 if(extCov[5] > fProtonAnalysisBase->GetMaxCov33()) {
208 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(6)))->Fill(extCov[5]);
210 else if(extCov[5] <= fProtonAnalysisBase->GetMaxCov33())
211 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(6)))->Fill(extCov[5]);
213 if(fProtonAnalysisBase->IsUsedMaxCov44()) {
214 if(extCov[9] > fProtonAnalysisBase->GetMaxCov44()) {
215 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(7)))->Fill(extCov[9]);
217 else if(extCov[9] <= fProtonAnalysisBase->GetMaxCov44())
218 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(7)))->Fill(extCov[9]);
220 if(fProtonAnalysisBase->IsUsedMaxCov55()) {
221 if(extCov[14] > fProtonAnalysisBase->GetMaxCov55()) {
222 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(8)))->Fill(extCov[14]);
224 else if(extCov[14] <= fProtonAnalysisBase->GetMaxCov55())
225 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(8)))->Fill(extCov[14]);
227 if(fProtonAnalysisBase->IsUsedMaxSigmaToVertex()) {
228 if(fProtonAnalysisBase->GetSigmaToVertex(track) > fProtonAnalysisBase->GetMaxSigmaToVertex()) {
229 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(9)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
231 else if(fProtonAnalysisBase->GetSigmaToVertex(track) <= fProtonAnalysisBase->GetMaxSigmaToVertex())
232 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(9)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
234 if(fProtonAnalysisBase->IsUsedMaxSigmaToVertexTPC()) {
235 if(fProtonAnalysisBase->GetSigmaToVertex(track) > fProtonAnalysisBase->GetMaxSigmaToVertexTPC()) {
236 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(10)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
238 else if(fProtonAnalysisBase->GetSigmaToVertex(track) <= fProtonAnalysisBase->GetMaxSigmaToVertexTPC())
239 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(10)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
240 }//sigma to vertex TPC
241 if(fProtonAnalysisBase->IsUsedMaxDCAXY()) {
242 if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXY()) {
243 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(11)))->Fill(TMath::Abs(dca[0]));
245 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXY())
246 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(11)))->Fill(TMath::Abs(dca[0]));
247 }//DCA xy global tracking
248 if(fProtonAnalysisBase->IsUsedMaxDCAXYTPC()) {
249 if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXYTPC()) {
250 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(12)))->Fill(TMath::Abs(dca[0]));
252 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXYTPC())
253 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(12)))->Fill(TMath::Abs(dca[0]));
254 }//DCA xy TPC tracking
255 if(fProtonAnalysisBase->IsUsedMaxDCAZ()) {
256 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZ()) {
257 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(13)))->Fill(TMath::Abs(dca[1]));
259 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZ())
260 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(13)))->Fill(TMath::Abs(dca[1]));
261 }//DCA z global tracking
262 if(fProtonAnalysisBase->IsUsedMaxDCAZTPC()) {
263 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZTPC()) {
264 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(14)))->Fill(TMath::Abs(dca[1]));
266 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZTPC())
267 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(14)))->Fill(TMath::Abs(dca[1]));
268 }//DCA z TPC tracking
269 if(fProtonAnalysisBase->IsUsedMaxConstrainChi2()) {
270 if(track->GetConstrainedChi2() > 0) {
271 if(TMath::Log(track->GetConstrainedChi2()) > fProtonAnalysisBase->GetMaxConstrainChi2()) {
272 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(15)))->Fill(TMath::Log(track->GetConstrainedChi2()));
274 else if(TMath::Log(track->GetConstrainedChi2()) <= fProtonAnalysisBase->GetMaxConstrainChi2())
275 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(15)))->Fill(TMath::Log(track->GetConstrainedChi2()));
277 }//constrain chi2 - vertex
278 if(fProtonAnalysisBase->IsUsedITSRefit()) {
279 if ((track->GetStatus() & AliESDtrack::kITSrefit) == 0) {
280 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(16)))->Fill(0);
282 else if((track->GetStatus() & AliESDtrack::kITSrefit) != 0)
283 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(16)))->Fill(0);
285 if(fProtonAnalysisBase->IsUsedTPCRefit()) {
286 if ((track->GetStatus() & AliESDtrack::kTPCrefit) == 0) {
287 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(17)))->Fill(0);
289 else if((track->GetStatus() & AliESDtrack::kTPCrefit) != 0)
290 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(17)))->Fill(0);
292 if(fProtonAnalysisBase->IsUsedESDpid()) {
293 if ((track->GetStatus() & AliESDtrack::kESDpid) == 0) {
294 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(18)))->Fill(0);
296 else if((track->GetStatus() & AliESDtrack::kESDpid) != 0)
297 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(18)))->Fill(0);
299 if(fProtonAnalysisBase->IsUsedTPCpid()) {
300 if ((track->GetStatus() & AliESDtrack::kTPCpid) == 0) {
301 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(19)))->Fill(0);
303 else if((track->GetStatus() & AliESDtrack::kTPCpid) != 0)
304 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(19)))->Fill(0);
306 if(fProtonAnalysisBase->IsUsedPointOnITSLayer1()) {
307 if(!track->HasPointOnITSLayer(0)) {
308 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(20)))->Fill(0);
310 else if(track->HasPointOnITSLayer(0))
311 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(20)))->Fill(0);
313 if(fProtonAnalysisBase->IsUsedPointOnITSLayer2()) {
314 if(!track->HasPointOnITSLayer(1)) {
315 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(21)))->Fill(0);
317 else if(track->HasPointOnITSLayer(1))
318 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(21)))->Fill(0);
320 if(fProtonAnalysisBase->IsUsedPointOnITSLayer3()) {
321 if(!track->HasPointOnITSLayer(2)) {
322 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(22)))->Fill(0);
324 else if(track->HasPointOnITSLayer(2))
325 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(22)))->Fill(0);
327 if(fProtonAnalysisBase->IsUsedPointOnITSLayer4()) {
328 if(!track->HasPointOnITSLayer(3)) {
329 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(23)))->Fill(0);
331 else if(track->HasPointOnITSLayer(3))
332 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(23)))->Fill(0);
334 if(fProtonAnalysisBase->IsUsedPointOnITSLayer5()) {
335 if(!track->HasPointOnITSLayer(4)) {
336 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(24)))->Fill(0);
338 else if(track->HasPointOnITSLayer(4))
339 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(24)))->Fill(0);
341 if(fProtonAnalysisBase->IsUsedPointOnITSLayer6()) {
342 if(!track->HasPointOnITSLayer(5)) {
343 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(25)))->Fill(0);
345 else if(track->HasPointOnITSLayer(5))
346 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(25)))->Fill(0);
348 if(fProtonAnalysisBase->IsUsedMinTPCdEdxPoints()) {
349 if(track->GetTPCsignalN() < fProtonAnalysisBase->GetMinTPCdEdxPoints()) {
350 ((TH1F *)(fQAPrimaryProtonsRejectedList->At(26)))->Fill(track->GetTPCsignalN());
352 if(track->GetTPCsignalN() >= fProtonAnalysisBase->GetMinTPCdEdxPoints())
353 ((TH1F *)(fQAPrimaryProtonsAcceptedList->At(26)))->Fill(track->GetTPCsignalN());
354 }//number of TPC points for the dE/dx
356 /*if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXY()) {
357 ((TH2F *)(fQAPrimaryProtonsRejectedList->At(27)))->Fill(gPt,TMath::Abs(dca[0]));
359 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXY())
360 ((TH2F *)(fQAPrimaryProtonsAcceptedList->At(27)))->Fill(gPt,TMath::Abs(dca[0]));
361 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZ()) {
362 ((TH2F *)(fQAPrimaryProtonsRejectedList->At(28)))->Fill(gPt,TMath::Abs(dca[1]));
364 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZ())
365 ((TH2F *)(fQAPrimaryProtonsAcceptedList->At(28)))->Fill(gPt,TMath::Abs(dca[1]));*/
366 }//primary particle cut
369 if(label > nPrimaries) {
370 if(fProtonAnalysisBase->IsUsedMinITSClusters()) {
371 if(nClustersITS < fProtonAnalysisBase->GetMinITSClusters()) {
372 ((TH1F *)(fQASecondaryProtonsRejectedList->At(0)))->Fill(nClustersITS);
374 else if(nClustersITS >= fProtonAnalysisBase->GetMinITSClusters())
375 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(0)))->Fill(nClustersITS);
377 if(fProtonAnalysisBase->IsUsedMaxChi2PerITSCluster()) {
378 if(chi2PerClusterITS > fProtonAnalysisBase->GetMaxChi2PerITSCluster()) {
379 ((TH1F *)(fQASecondaryProtonsRejectedList->At(1)))->Fill(chi2PerClusterITS);
381 else if(chi2PerClusterITS <= fProtonAnalysisBase->GetMaxChi2PerITSCluster())
382 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(1)))->Fill(chi2PerClusterITS);
383 }//chi2 per ITS cluster
384 if(fProtonAnalysisBase->IsUsedMinTPCClusters()) {
385 if(nClustersTPC < fProtonAnalysisBase->GetMinTPCClusters()) {
386 //cout<<"Secondary proton rejected"<<endl;
387 ((TH1F *)(fQASecondaryProtonsRejectedList->At(2)))->Fill(nClustersTPC);
389 else if(nClustersTPC >= fProtonAnalysisBase->GetMinTPCClusters()) {
390 //cout<<"Secondary proton accepted"<<endl;
391 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(2)))->Fill(nClustersTPC);
394 if(fProtonAnalysisBase->IsUsedMaxChi2PerTPCCluster()) {
395 if(chi2PerClusterTPC > fProtonAnalysisBase->GetMaxChi2PerTPCCluster()) {
396 ((TH1F *)(fQASecondaryProtonsRejectedList->At(3)))->Fill(chi2PerClusterTPC);
398 else if(chi2PerClusterTPC <= fProtonAnalysisBase->GetMaxChi2PerTPCCluster())
399 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(3)))->Fill(chi2PerClusterTPC);
400 }//chi2 per TPC cluster
401 if(fProtonAnalysisBase->IsUsedMaxCov11()) {
402 if(extCov[0] > fProtonAnalysisBase->GetMaxCov11()) {
403 ((TH1F *)(fQASecondaryProtonsRejectedList->At(4)))->Fill(extCov[0]);
405 else if(extCov[0] <= fProtonAnalysisBase->GetMaxCov11())
406 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(4)))->Fill(extCov[0]);
408 if(fProtonAnalysisBase->IsUsedMaxCov22()) {
409 if(extCov[2] > fProtonAnalysisBase->GetMaxCov22()) {
410 ((TH1F *)(fQASecondaryProtonsRejectedList->At(5)))->Fill(extCov[2]);
412 else if(extCov[2] <= fProtonAnalysisBase->GetMaxCov22())
413 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(5)))->Fill(extCov[2]);
415 if(fProtonAnalysisBase->IsUsedMaxCov33()) {
416 if(extCov[5] > fProtonAnalysisBase->GetMaxCov33()) {
417 ((TH1F *)(fQASecondaryProtonsRejectedList->At(6)))->Fill(extCov[5]);
419 else if(extCov[5] <= fProtonAnalysisBase->GetMaxCov33())
420 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(6)))->Fill(extCov[5]);
422 if(fProtonAnalysisBase->IsUsedMaxCov44()) {
423 if(extCov[9] > fProtonAnalysisBase->GetMaxCov44()) {
424 ((TH1F *)(fQASecondaryProtonsRejectedList->At(7)))->Fill(extCov[9]);
426 else if(extCov[9] <= fProtonAnalysisBase->GetMaxCov44())
427 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(7)))->Fill(extCov[9]);
429 if(fProtonAnalysisBase->IsUsedMaxCov55()) {
430 if(extCov[14] > fProtonAnalysisBase->GetMaxCov55()) {
431 ((TH1F *)(fQASecondaryProtonsRejectedList->At(8)))->Fill(extCov[14]);
433 else if(extCov[14] <= fProtonAnalysisBase->GetMaxCov55())
434 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(8)))->Fill(extCov[14]);
436 if(fProtonAnalysisBase->IsUsedMaxSigmaToVertex()) {
437 if(fProtonAnalysisBase->GetSigmaToVertex(track) > fProtonAnalysisBase->GetMaxSigmaToVertex()) {
438 ((TH1F *)(fQASecondaryProtonsRejectedList->At(9)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
440 else if(fProtonAnalysisBase->GetSigmaToVertex(track) <= fProtonAnalysisBase->GetMaxSigmaToVertex())
441 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(9)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
443 if(fProtonAnalysisBase->IsUsedMaxSigmaToVertexTPC()) {
444 if(fProtonAnalysisBase->GetSigmaToVertex(track) > fProtonAnalysisBase->GetMaxSigmaToVertexTPC()) {
445 ((TH1F *)(fQASecondaryProtonsRejectedList->At(10)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
447 else if(fProtonAnalysisBase->GetSigmaToVertex(track) <= fProtonAnalysisBase->GetMaxSigmaToVertexTPC())
448 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(10)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
449 }//sigma to vertex TPC
450 if(fProtonAnalysisBase->IsUsedMaxDCAXY()) {
451 if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXY()) {
452 ((TH1F *)(fQASecondaryProtonsRejectedList->At(11)))->Fill(TMath::Abs(dca[0]));
454 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXY())
455 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(11)))->Fill(TMath::Abs(dca[0]));
456 }//DCA xy global tracking
457 if(fProtonAnalysisBase->IsUsedMaxDCAXYTPC()) {
458 if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXYTPC()) {
459 ((TH1F *)(fQASecondaryProtonsRejectedList->At(12)))->Fill(TMath::Abs(dca[0]));
461 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXYTPC())
462 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(12)))->Fill(TMath::Abs(dca[0]));
463 }//DCA xy TPC tracking
464 if(fProtonAnalysisBase->IsUsedMaxDCAZ()) {
465 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZ()) {
466 ((TH1F *)(fQASecondaryProtonsRejectedList->At(13)))->Fill(TMath::Abs(dca[1]));
468 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZ())
469 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(13)))->Fill(TMath::Abs(dca[1]));
470 }//DCA z global tracking
471 if(fProtonAnalysisBase->IsUsedMaxDCAZTPC()) {
472 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZTPC()) {
473 ((TH1F *)(fQASecondaryProtonsRejectedList->At(14)))->Fill(TMath::Abs(dca[1]));
475 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZTPC())
476 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(14)))->Fill(TMath::Abs(dca[1]));
477 }//DCA z TPC tracking
478 if(fProtonAnalysisBase->IsUsedMaxConstrainChi2()) {
479 if(track->GetConstrainedChi2() > 0) {
480 if(TMath::Log(track->GetConstrainedChi2()) > fProtonAnalysisBase->GetMaxConstrainChi2()) {
481 ((TH1F *)(fQASecondaryProtonsRejectedList->At(15)))->Fill(TMath::Log(track->GetConstrainedChi2()));
483 else if(TMath::Log(track->GetConstrainedChi2()) <= fProtonAnalysisBase->GetMaxConstrainChi2())
484 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(15)))->Fill(TMath::Log(track->GetConstrainedChi2()));
486 }//constrain chi2 - vertex
487 if(fProtonAnalysisBase->IsUsedITSRefit()) {
488 if ((track->GetStatus() & AliESDtrack::kITSrefit) == 0) {
489 ((TH1F *)(fQASecondaryProtonsRejectedList->At(16)))->Fill(0);
491 else if((track->GetStatus() & AliESDtrack::kITSrefit) != 0)
492 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(16)))->Fill(0);
494 if(fProtonAnalysisBase->IsUsedTPCRefit()) {
495 if ((track->GetStatus() & AliESDtrack::kTPCrefit) == 0) {
496 ((TH1F *)(fQASecondaryProtonsRejectedList->At(17)))->Fill(0);
498 else if((track->GetStatus() & AliESDtrack::kTPCrefit) != 0)
499 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(17)))->Fill(0);
501 if(fProtonAnalysisBase->IsUsedESDpid()) {
502 if ((track->GetStatus() & AliESDtrack::kESDpid) == 0) {
503 ((TH1F *)(fQASecondaryProtonsRejectedList->At(18)))->Fill(0);
505 else if((track->GetStatus() & AliESDtrack::kESDpid) != 0)
506 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(18)))->Fill(0);
508 if(fProtonAnalysisBase->IsUsedTPCpid()) {
509 if ((track->GetStatus() & AliESDtrack::kTPCpid) == 0) {
510 ((TH1F *)(fQASecondaryProtonsRejectedList->At(19)))->Fill(0);
512 else if((track->GetStatus() & AliESDtrack::kTPCpid) != 0)
513 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(19)))->Fill(0);
515 if(fProtonAnalysisBase->IsUsedPointOnITSLayer1()) {
516 if(!track->HasPointOnITSLayer(0)) {
517 ((TH1F *)(fQASecondaryProtonsRejectedList->At(20)))->Fill(0);
519 else if(track->HasPointOnITSLayer(0))
520 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(20)))->Fill(0);
522 if(fProtonAnalysisBase->IsUsedPointOnITSLayer2()) {
523 if(!track->HasPointOnITSLayer(1)) {
524 ((TH1F *)(fQASecondaryProtonsRejectedList->At(21)))->Fill(0);
526 else if(track->HasPointOnITSLayer(1))
527 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(21)))->Fill(0);
529 if(fProtonAnalysisBase->IsUsedPointOnITSLayer3()) {
530 if(!track->HasPointOnITSLayer(2)) {
531 ((TH1F *)(fQASecondaryProtonsRejectedList->At(22)))->Fill(0);
533 else if(track->HasPointOnITSLayer(2))
534 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(22)))->Fill(0);
536 if(fProtonAnalysisBase->IsUsedPointOnITSLayer4()) {
537 if(!track->HasPointOnITSLayer(3)) {
538 ((TH1F *)(fQASecondaryProtonsRejectedList->At(23)))->Fill(0);
540 else if(track->HasPointOnITSLayer(3))
541 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(23)))->Fill(0);
543 if(fProtonAnalysisBase->IsUsedPointOnITSLayer5()) {
544 if(!track->HasPointOnITSLayer(4)) {
545 ((TH1F *)(fQASecondaryProtonsRejectedList->At(24)))->Fill(0);
547 else if(track->HasPointOnITSLayer(4))
548 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(24)))->Fill(0);
550 if(fProtonAnalysisBase->IsUsedPointOnITSLayer6()) {
551 if(!track->HasPointOnITSLayer(5)) {
552 ((TH1F *)(fQASecondaryProtonsRejectedList->At(25)))->Fill(0);
554 else if(track->HasPointOnITSLayer(5))
555 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(25)))->Fill(0);
557 if(fProtonAnalysisBase->IsUsedMinTPCdEdxPoints()) {
558 if(track->GetTPCsignalN() < fProtonAnalysisBase->GetMinTPCdEdxPoints()) {
559 ((TH1F *)(fQASecondaryProtonsRejectedList->At(26)))->Fill(track->GetTPCsignalN());
561 if(track->GetTPCsignalN() >= fProtonAnalysisBase->GetMinTPCdEdxPoints())
562 ((TH1F *)(fQASecondaryProtonsAcceptedList->At(26)))->Fill(track->GetTPCsignalN());
563 }//number of TPC points for the dE/dx
565 /*if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXY()) {
567 ((TH2F *)(fQASecondaryProtonsRejectedList->At(27)))->Fill(gPt,TMath::Abs(dca[0]));
569 ((TH2F *)(fQASecondaryProtonsRejectedList->At(29)))->Fill(gPt,TMath::Abs(dca[0]));
571 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXY()) {
573 ((TH2F *)(fQASecondaryProtonsAcceptedList->At(27)))->Fill(gPt,TMath::Abs(dca[0]));
575 ((TH2F *)(fQASecondaryProtonsAcceptedList->At(29)))->Fill(gPt,TMath::Abs(dca[0]));
577 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZ()) {
579 ((TH2F *)(fQASecondaryProtonsRejectedList->At(28)))->Fill(gPt,TMath::Abs(dca[1]));
581 ((TH2F *)(fQASecondaryProtonsRejectedList->At(30)))->Fill(gPt,TMath::Abs(dca[1]));
583 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZ()) {
585 ((TH2F *)(fQASecondaryProtonsAcceptedList->At(28)))->Fill(gPt,TMath::Abs(dca[1]));
587 ((TH2F *)(fQASecondaryProtonsAcceptedList->At(30)))->Fill(gPt,TMath::Abs(dca[1]));
589 }//secondary particle cut
593 if(track->Charge() < 0) {
595 if(label <= nPrimaries) {
596 if(fProtonAnalysisBase->IsUsedMinITSClusters()) {
597 if(nClustersITS < fProtonAnalysisBase->GetMinITSClusters()) {
598 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(0)))->Fill(nClustersITS);
600 else if(nClustersITS >= fProtonAnalysisBase->GetMinITSClusters())
601 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(0)))->Fill(nClustersITS);
603 if(fProtonAnalysisBase->IsUsedMaxChi2PerITSCluster()) {
604 if(chi2PerClusterITS > fProtonAnalysisBase->GetMaxChi2PerITSCluster()) {
605 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(1)))->Fill(chi2PerClusterITS);
607 else if(chi2PerClusterITS <= fProtonAnalysisBase->GetMaxChi2PerITSCluster())
608 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(1)))->Fill(chi2PerClusterITS);
609 }//chi2 per ITS cluster
610 if(fProtonAnalysisBase->IsUsedMinTPCClusters()) {
611 if(nClustersTPC < fProtonAnalysisBase->GetMinTPCClusters()) {
612 //cout<<"Primary antiproton rejected"<<endl;
613 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(2)))->Fill(nClustersTPC);
615 else if(nClustersTPC >= fProtonAnalysisBase->GetMinTPCClusters()) {
616 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(2)))->Fill(nClustersTPC);
619 if(fProtonAnalysisBase->IsUsedMaxChi2PerTPCCluster()) {
620 if(chi2PerClusterTPC > fProtonAnalysisBase->GetMaxChi2PerTPCCluster()) {
621 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(3)))->Fill(chi2PerClusterTPC);
623 else if(chi2PerClusterTPC <= fProtonAnalysisBase->GetMaxChi2PerTPCCluster())
624 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(3)))->Fill(chi2PerClusterTPC);
625 }//chi2 per TPC cluster
626 if(fProtonAnalysisBase->IsUsedMaxCov11()) {
627 if(extCov[0] > fProtonAnalysisBase->GetMaxCov11()) {
628 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(4)))->Fill(extCov[0]);
630 else if(extCov[0] <= fProtonAnalysisBase->GetMaxCov11())
631 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(4)))->Fill(extCov[0]);
633 if(fProtonAnalysisBase->IsUsedMaxCov22()) {
634 if(extCov[2] > fProtonAnalysisBase->GetMaxCov22()) {
635 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(5)))->Fill(extCov[2]);
637 else if(extCov[2] <= fProtonAnalysisBase->GetMaxCov22())
638 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(5)))->Fill(extCov[2]);
640 if(fProtonAnalysisBase->IsUsedMaxCov33()) {
641 if(extCov[5] > fProtonAnalysisBase->GetMaxCov33()) {
642 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(6)))->Fill(extCov[5]);
644 else if(extCov[5] <= fProtonAnalysisBase->GetMaxCov33())
645 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(6)))->Fill(extCov[5]);
647 if(fProtonAnalysisBase->IsUsedMaxCov44()) {
648 if(extCov[9] > fProtonAnalysisBase->GetMaxCov44()) {
649 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(7)))->Fill(extCov[9]);
651 else if(extCov[9] <= fProtonAnalysisBase->GetMaxCov44())
652 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(7)))->Fill(extCov[9]);
654 if(fProtonAnalysisBase->IsUsedMaxCov55()) {
655 if(extCov[14] > fProtonAnalysisBase->GetMaxCov55()) {
656 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(8)))->Fill(extCov[14]);
658 else if(extCov[14] <= fProtonAnalysisBase->GetMaxCov55())
659 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(8)))->Fill(extCov[14]);
661 if(fProtonAnalysisBase->IsUsedMaxSigmaToVertex()) {
662 if(fProtonAnalysisBase->GetSigmaToVertex(track) > fProtonAnalysisBase->GetMaxSigmaToVertex()) {
663 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(9)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
665 else if(fProtonAnalysisBase->GetSigmaToVertex(track) <= fProtonAnalysisBase->GetMaxSigmaToVertex())
666 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(9)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
668 if(fProtonAnalysisBase->IsUsedMaxSigmaToVertexTPC()) {
669 if(fProtonAnalysisBase->GetSigmaToVertex(track) > fProtonAnalysisBase->GetMaxSigmaToVertexTPC()) {
670 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(10)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
672 else if(fProtonAnalysisBase->GetSigmaToVertex(track) <= fProtonAnalysisBase->GetMaxSigmaToVertexTPC())
673 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(10)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
674 }//sigma to vertex TPC
675 if(fProtonAnalysisBase->IsUsedMaxDCAXY()) {
676 if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXY()) {
677 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(11)))->Fill(TMath::Abs(dca[0]));
679 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXY())
680 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(11)))->Fill(TMath::Abs(dca[0]));
681 }//DCA xy global tracking
682 if(fProtonAnalysisBase->IsUsedMaxDCAXYTPC()) {
683 if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXYTPC()) {
684 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(12)))->Fill(TMath::Abs(dca[0]));
686 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXYTPC())
687 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(12)))->Fill(TMath::Abs(dca[0]));
688 }//DCA xy TPC tracking
689 if(fProtonAnalysisBase->IsUsedMaxDCAZ()) {
690 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZ()) {
691 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(13)))->Fill(TMath::Abs(dca[1]));
693 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZ())
694 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(13)))->Fill(TMath::Abs(dca[1]));
695 }//DCA z global tracking
696 if(fProtonAnalysisBase->IsUsedMaxDCAZTPC()) {
697 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZTPC()) {
698 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(14)))->Fill(TMath::Abs(dca[1]));
700 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZTPC())
701 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(14)))->Fill(TMath::Abs(dca[1]));
702 }//DCA z TPC tracking
703 if(fProtonAnalysisBase->IsUsedMaxConstrainChi2()) {
704 if(track->GetConstrainedChi2() > 0) {
705 if(TMath::Log(track->GetConstrainedChi2()) > fProtonAnalysisBase->GetMaxConstrainChi2()) {
706 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(15)))->Fill(TMath::Log(track->GetConstrainedChi2()));
708 else if(TMath::Log(track->GetConstrainedChi2()) <= fProtonAnalysisBase->GetMaxConstrainChi2())
709 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(15)))->Fill(TMath::Log(track->GetConstrainedChi2()));
711 }//constrain chi2 - vertex
712 if(fProtonAnalysisBase->IsUsedITSRefit()) {
713 if ((track->GetStatus() & AliESDtrack::kITSrefit) == 0) {
714 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(16)))->Fill(0);
716 else if((track->GetStatus() & AliESDtrack::kITSrefit) != 0)
717 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(16)))->Fill(0);
719 if(fProtonAnalysisBase->IsUsedTPCRefit()) {
720 if ((track->GetStatus() & AliESDtrack::kTPCrefit) == 0) {
721 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(17)))->Fill(0);
723 else if((track->GetStatus() & AliESDtrack::kTPCrefit) != 0)
724 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(17)))->Fill(0);
726 if(fProtonAnalysisBase->IsUsedESDpid()) {
727 if ((track->GetStatus() & AliESDtrack::kESDpid) == 0) {
728 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(18)))->Fill(0);
730 else if((track->GetStatus() & AliESDtrack::kESDpid) != 0)
731 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(18)))->Fill(0);
733 if(fProtonAnalysisBase->IsUsedTPCpid()) {
734 if ((track->GetStatus() & AliESDtrack::kTPCpid) == 0) {
735 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(19)))->Fill(0);
737 else if((track->GetStatus() & AliESDtrack::kTPCpid) != 0)
738 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(19)))->Fill(0);
740 if(fProtonAnalysisBase->IsUsedPointOnITSLayer1()) {
741 if(!track->HasPointOnITSLayer(0)) {
742 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(20)))->Fill(0);
744 else if(track->HasPointOnITSLayer(0))
745 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(20)))->Fill(0);
747 if(fProtonAnalysisBase->IsUsedPointOnITSLayer2()) {
748 if(!track->HasPointOnITSLayer(1)) {
749 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(21)))->Fill(0);
751 else if(track->HasPointOnITSLayer(1))
752 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(21)))->Fill(0);
754 if(fProtonAnalysisBase->IsUsedPointOnITSLayer3()) {
755 if(!track->HasPointOnITSLayer(2)) {
756 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(22)))->Fill(0);
758 else if(track->HasPointOnITSLayer(2))
759 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(22)))->Fill(0);
761 if(fProtonAnalysisBase->IsUsedPointOnITSLayer4()) {
762 if(!track->HasPointOnITSLayer(3)) {
763 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(23)))->Fill(0);
765 else if(track->HasPointOnITSLayer(3))
766 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(23)))->Fill(0);
768 if(fProtonAnalysisBase->IsUsedPointOnITSLayer5()) {
769 if(!track->HasPointOnITSLayer(4)) {
770 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(24)))->Fill(0);
772 else if(track->HasPointOnITSLayer(4))
773 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(24)))->Fill(0);
775 if(fProtonAnalysisBase->IsUsedPointOnITSLayer6()) {
776 if(!track->HasPointOnITSLayer(5)) {
777 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(25)))->Fill(0);
779 else if(track->HasPointOnITSLayer(5))
780 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(25)))->Fill(0);
782 if(fProtonAnalysisBase->IsUsedMinTPCdEdxPoints()) {
783 if(track->GetTPCsignalN() < fProtonAnalysisBase->GetMinTPCdEdxPoints()) {
784 ((TH1F *)(fQAPrimaryAntiProtonsRejectedList->At(26)))->Fill(track->GetTPCsignalN());
786 if(track->GetTPCsignalN() >= fProtonAnalysisBase->GetMinTPCdEdxPoints())
787 ((TH1F *)(fQAPrimaryAntiProtonsAcceptedList->At(26)))->Fill(track->GetTPCsignalN());
788 }//number of TPC points for the dE/dx
790 /*if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXY()) {
791 ((TH2F *)(fQAPrimaryAntiProtonsRejectedList->At(27)))->Fill(gPt,TMath::Abs(dca[0]));
793 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXY())
794 ((TH2F *)(fQAPrimaryAntiProtonsAcceptedList->At(27)))->Fill(gPt,TMath::Abs(dca[0]));
795 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZ()) {
796 ((TH2F *)(fQAPrimaryAntiProtonsRejectedList->At(28)))->Fill(gPt,TMath::Abs(dca[1]));
798 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZ())
799 ((TH2F *)(fQAPrimaryAntiProtonsAcceptedList->At(28)))->Fill(gPt,TMath::Abs(dca[1]));*/
800 }//primary particle cut
803 if(label > nPrimaries) {
804 if(fProtonAnalysisBase->IsUsedMinITSClusters()) {
805 if(nClustersITS < fProtonAnalysisBase->GetMinITSClusters()) {
806 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(0)))->Fill(nClustersITS);
808 else if(nClustersITS >= fProtonAnalysisBase->GetMinITSClusters())
809 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(0)))->Fill(nClustersITS);
811 if(fProtonAnalysisBase->IsUsedMaxChi2PerITSCluster()) {
812 if(chi2PerClusterITS > fProtonAnalysisBase->GetMaxChi2PerITSCluster()) {
813 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(1)))->Fill(chi2PerClusterITS);
815 else if(chi2PerClusterITS <= fProtonAnalysisBase->GetMaxChi2PerITSCluster())
816 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(1)))->Fill(chi2PerClusterITS);
817 }//chi2 per ITS cluster
818 if(fProtonAnalysisBase->IsUsedMinTPCClusters()) {
819 if(nClustersTPC < fProtonAnalysisBase->GetMinTPCClusters()) {
820 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(2)))->Fill(nClustersTPC);
822 else if(nClustersTPC >= fProtonAnalysisBase->GetMinTPCClusters()) {
823 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(2)))->Fill(nClustersTPC);
826 if(fProtonAnalysisBase->IsUsedMaxChi2PerTPCCluster()) {
827 if(chi2PerClusterTPC > fProtonAnalysisBase->GetMaxChi2PerTPCCluster()) {
828 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(3)))->Fill(chi2PerClusterTPC);
830 else if(chi2PerClusterTPC <= fProtonAnalysisBase->GetMaxChi2PerTPCCluster())
831 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(3)))->Fill(chi2PerClusterTPC);
832 }//chi2 per TPC cluster
833 if(fProtonAnalysisBase->IsUsedMaxCov11()) {
834 if(extCov[0] > fProtonAnalysisBase->GetMaxCov11()) {
835 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(4)))->Fill(extCov[0]);
837 else if(extCov[0] <= fProtonAnalysisBase->GetMaxCov11())
838 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(4)))->Fill(extCov[0]);
840 if(fProtonAnalysisBase->IsUsedMaxCov22()) {
841 if(extCov[2] > fProtonAnalysisBase->GetMaxCov22()) {
842 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(5)))->Fill(extCov[2]);
844 else if(extCov[2] <= fProtonAnalysisBase->GetMaxCov22())
845 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(5)))->Fill(extCov[2]);
847 if(fProtonAnalysisBase->IsUsedMaxCov33()) {
848 if(extCov[5] > fProtonAnalysisBase->GetMaxCov33()) {
849 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(6)))->Fill(extCov[5]);
851 else if(extCov[5] <= fProtonAnalysisBase->GetMaxCov33())
852 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(6)))->Fill(extCov[5]);
854 if(fProtonAnalysisBase->IsUsedMaxCov44()) {
855 if(extCov[9] > fProtonAnalysisBase->GetMaxCov44()) {
856 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(7)))->Fill(extCov[9]);
858 else if(extCov[9] <= fProtonAnalysisBase->GetMaxCov44())
859 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(7)))->Fill(extCov[9]);
861 if(fProtonAnalysisBase->IsUsedMaxCov55()) {
862 if(extCov[14] > fProtonAnalysisBase->GetMaxCov55()) {
863 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(8)))->Fill(extCov[14]);
865 else if(extCov[14] <= fProtonAnalysisBase->GetMaxCov55())
866 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(8)))->Fill(extCov[14]);
868 if(fProtonAnalysisBase->IsUsedMaxSigmaToVertex()) {
869 if(fProtonAnalysisBase->GetSigmaToVertex(track) > fProtonAnalysisBase->GetMaxSigmaToVertex()) {
870 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(9)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
872 else if(fProtonAnalysisBase->GetSigmaToVertex(track) <= fProtonAnalysisBase->GetMaxSigmaToVertex())
873 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(9)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
875 if(fProtonAnalysisBase->IsUsedMaxSigmaToVertexTPC()) {
876 if(fProtonAnalysisBase->GetSigmaToVertex(track) > fProtonAnalysisBase->GetMaxSigmaToVertexTPC()) {
877 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(10)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
879 else if(fProtonAnalysisBase->GetSigmaToVertex(track) <= fProtonAnalysisBase->GetMaxSigmaToVertexTPC())
880 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(10)))->Fill(fProtonAnalysisBase->GetSigmaToVertex(track));
881 }//sigma to vertex TPC
882 if(fProtonAnalysisBase->IsUsedMaxDCAXY()) {
883 if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXY()) {
884 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(11)))->Fill(TMath::Abs(dca[0]));
886 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXY())
887 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(11)))->Fill(TMath::Abs(dca[0]));
888 }//DCA xy global tracking
889 if(fProtonAnalysisBase->IsUsedMaxDCAXYTPC()) {
890 if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXYTPC()) {
891 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(12)))->Fill(TMath::Abs(dca[0]));
893 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXYTPC())
894 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(12)))->Fill(TMath::Abs(dca[0]));
895 }//DCA xy TPC tracking
896 if(fProtonAnalysisBase->IsUsedMaxDCAZ()) {
897 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZ()) {
898 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(13)))->Fill(TMath::Abs(dca[1]));
900 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZ())
901 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(13)))->Fill(TMath::Abs(dca[1]));
902 }//DCA z global tracking
903 if(fProtonAnalysisBase->IsUsedMaxDCAZTPC()) {
904 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZTPC()) {
905 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(14)))->Fill(TMath::Abs(dca[1]));
907 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZTPC())
908 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(14)))->Fill(TMath::Abs(dca[1]));
909 }//DCA z TPC tracking
910 if(fProtonAnalysisBase->IsUsedMaxConstrainChi2()) {
911 if(track->GetConstrainedChi2() > 0) {
912 if(TMath::Log(track->GetConstrainedChi2()) > fProtonAnalysisBase->GetMaxConstrainChi2()) {
913 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(15)))->Fill(TMath::Log(track->GetConstrainedChi2()));
915 else if(TMath::Log(track->GetConstrainedChi2()) <= fProtonAnalysisBase->GetMaxConstrainChi2())
916 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(15)))->Fill(TMath::Log(track->GetConstrainedChi2()));
918 }//constrain chi2 - vertex
919 if(fProtonAnalysisBase->IsUsedITSRefit()) {
920 if ((track->GetStatus() & AliESDtrack::kITSrefit) == 0) {
921 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(16)))->Fill(0);
923 else if((track->GetStatus() & AliESDtrack::kITSrefit) != 0)
924 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(16)))->Fill(0);
926 if(fProtonAnalysisBase->IsUsedTPCRefit()) {
927 if ((track->GetStatus() & AliESDtrack::kTPCrefit) == 0) {
928 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(17)))->Fill(0);
930 else if((track->GetStatus() & AliESDtrack::kTPCrefit) != 0)
931 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(17)))->Fill(0);
933 if(fProtonAnalysisBase->IsUsedESDpid()) {
934 if ((track->GetStatus() & AliESDtrack::kESDpid) == 0) {
935 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(18)))->Fill(0);
937 else if((track->GetStatus() & AliESDtrack::kESDpid) != 0)
938 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(18)))->Fill(0);
940 if(fProtonAnalysisBase->IsUsedTPCpid()) {
941 if ((track->GetStatus() & AliESDtrack::kTPCpid) == 0) {
942 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(19)))->Fill(0);
944 else if((track->GetStatus() & AliESDtrack::kTPCpid) != 0)
945 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(19)))->Fill(0);
947 if(fProtonAnalysisBase->IsUsedPointOnITSLayer1()) {
948 if(!track->HasPointOnITSLayer(0)) {
949 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(20)))->Fill(0);
951 else if(track->HasPointOnITSLayer(0))
952 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(20)))->Fill(0);
954 if(fProtonAnalysisBase->IsUsedPointOnITSLayer2()) {
955 if(!track->HasPointOnITSLayer(1)) {
956 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(21)))->Fill(0);
958 else if(track->HasPointOnITSLayer(1))
959 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(21)))->Fill(0);
961 if(fProtonAnalysisBase->IsUsedPointOnITSLayer3()) {
962 if(!track->HasPointOnITSLayer(2)) {
963 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(22)))->Fill(0);
965 else if(track->HasPointOnITSLayer(2))
966 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(22)))->Fill(0);
968 if(fProtonAnalysisBase->IsUsedPointOnITSLayer4()) {
969 if(!track->HasPointOnITSLayer(3)) {
970 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(23)))->Fill(0);
972 else if(track->HasPointOnITSLayer(3))
973 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(23)))->Fill(0);
975 if(fProtonAnalysisBase->IsUsedPointOnITSLayer5()) {
976 if(!track->HasPointOnITSLayer(4)) {
977 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(24)))->Fill(0);
979 else if(track->HasPointOnITSLayer(4))
980 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(24)))->Fill(0);
982 if(fProtonAnalysisBase->IsUsedPointOnITSLayer6()) {
983 if(!track->HasPointOnITSLayer(5)) {
984 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(25)))->Fill(0);
986 else if(track->HasPointOnITSLayer(5))
987 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(25)))->Fill(0);
989 if(fProtonAnalysisBase->IsUsedMinTPCdEdxPoints()) {
990 if(track->GetTPCsignalN() < fProtonAnalysisBase->GetMinTPCdEdxPoints()) {
991 ((TH1F *)(fQASecondaryAntiProtonsRejectedList->At(26)))->Fill(track->GetTPCsignalN());
993 if(track->GetTPCsignalN() >= fProtonAnalysisBase->GetMinTPCdEdxPoints())
994 ((TH1F *)(fQASecondaryAntiProtonsAcceptedList->At(26)))->Fill(track->GetTPCsignalN());
995 }//number of TPC points for the dE/dx
997 /*if(TMath::Abs(dca[0]) > fProtonAnalysisBase->GetMaxDCAXY()) {
999 ((TH2F *)(fQASecondaryAntiProtonsRejectedList->At(27)))->Fill(gPt,TMath::Abs(dca[0]));
1001 ((TH2F *)(fQASecondaryAntiProtonsRejectedList->At(29)))->Fill(gPt,TMath::Abs(dca[0]));
1003 else if(TMath::Abs(dca[0]) <= fProtonAnalysisBase->GetMaxDCAXY()) {
1005 ((TH2F *)(fQASecondaryAntiProtonsAcceptedList->At(27)))->Fill(gPt,TMath::Abs(dca[0]));
1007 ((TH2F *)(fQASecondaryAntiProtonsAcceptedList->At(29)))->Fill(gPt,TMath::Abs(dca[0]));
1009 if(TMath::Abs(dca[1]) > fProtonAnalysisBase->GetMaxDCAZ()) {
1011 ((TH2F *)(fQASecondaryAntiProtonsRejectedList->At(28)))->Fill(gPt,TMath::Abs(dca[1]));
1013 ((TH2F *)(fQASecondaryAntiProtonsRejectedList->At(30)))->Fill(gPt,TMath::Abs(dca[1]));
1015 else if(TMath::Abs(dca[1]) <= fProtonAnalysisBase->GetMaxDCAZ()) {
1017 ((TH2F *)(fQASecondaryAntiProtonsAcceptedList->At(28)))->Fill(gPt,TMath::Abs(dca[1]));
1019 ((TH2F *)(fQASecondaryAntiProtonsAcceptedList->At(30)))->Fill(gPt,TMath::Abs(dca[1]));
1021 }//secondary particle cut
1026 //____________________________________________________________________//
1027 void AliProtonQAAnalysis::SetRunQAAnalysis() {
1028 //initializes the QA lists
1029 //fQAHistograms = kTRUE;
1030 fGlobalQAList = new TList();
1032 fQA2DList = new TList();
1033 fQA2DList->SetName("fQA2DList");
1034 fGlobalQAList->Add(fQA2DList);
1036 fQAPrimaryProtonsAcceptedList = new TList();
1037 fQAPrimaryProtonsAcceptedList->SetName("fQAPrimaryProtonsAcceptedList");
1038 fGlobalQAList->Add(fQAPrimaryProtonsAcceptedList);
1040 fQAPrimaryProtonsRejectedList = new TList();
1041 fQAPrimaryProtonsRejectedList->SetName("fQAPrimaryProtonsRejectedList");
1042 fGlobalQAList->Add(fQAPrimaryProtonsRejectedList);
1044 fQASecondaryProtonsAcceptedList = new TList();
1045 fQASecondaryProtonsAcceptedList->SetName("fQASecondaryProtonsAcceptedList");
1046 fGlobalQAList->Add(fQASecondaryProtonsAcceptedList);
1048 fQASecondaryProtonsRejectedList = new TList();
1049 fQASecondaryProtonsRejectedList->SetName("fQASecondaryProtonsRejectedList");
1050 fGlobalQAList->Add(fQASecondaryProtonsRejectedList);
1052 fQAPrimaryAntiProtonsAcceptedList = new TList();
1053 fQAPrimaryAntiProtonsAcceptedList->SetName("fQAPrimaryAntiProtonsAcceptedList");
1054 fGlobalQAList->Add(fQAPrimaryAntiProtonsAcceptedList);
1056 fQAPrimaryAntiProtonsRejectedList = new TList();
1057 fQAPrimaryAntiProtonsRejectedList->SetName("fQAPrimaryAntiProtonsRejectedList");
1058 fGlobalQAList->Add(fQAPrimaryAntiProtonsRejectedList);
1060 fQASecondaryAntiProtonsAcceptedList = new TList();
1061 fQASecondaryAntiProtonsAcceptedList->SetName("fQASecondaryAntiProtonsAcceptedList");
1062 fGlobalQAList->Add(fQASecondaryAntiProtonsAcceptedList);
1064 fQASecondaryAntiProtonsRejectedList = new TList();
1065 fQASecondaryAntiProtonsRejectedList->SetName("fQASecondaryAntiProtonsRejectedList");
1066 fGlobalQAList->Add(fQASecondaryAntiProtonsRejectedList);
1069 //____________________________________________________________________//
1070 void AliProtonQAAnalysis::SetQAYPtBins(Int_t nbinsY,
1071 Double_t minY, Double_t maxY,
1073 Double_t minPt, Double_t maxPt) {
1074 //Initializes the QA binning
1076 fMinY = minY; fMaxY = maxY;
1078 fMinPt = minPt; fMaxPt = maxPt;
1082 if(fRunMCAnalysis) InitMCAnalysis();
1083 if(fRunEfficiencyAnalysis) InitEfficiencyAnalysis();
1086 //____________________________________________________________________//
1087 void AliProtonQAAnalysis::SetQAYPtBins(Int_t nbinsY, Double_t *gY,
1088 Int_t nbinsPt, Double_t *gPt) {
1089 //Initializes the QA binning - asymmetric binning case
1090 fUseAsymmetricBinning = kTRUE;
1092 for(Int_t i = 0; i < nbinsY; i++) fY[i] = gY[i];
1093 fMinY = gY[0]; fMaxY = gY[nbinsPt];
1095 for(Int_t i = 0; i < nbinsPt; i++) fPt[i] = gPt[i];
1096 fMinPt = gPt[0]; fMaxPt = gPt[nbinsPt];
1100 if(fRunMCAnalysis) InitMCAnalysis();
1101 if(fRunEfficiencyAnalysis) InitEfficiencyAnalysis();
1104 //____________________________________________________________________//
1105 void AliProtonQAAnalysis::InitEfficiencyAnalysis() {
1106 //Initialization of the efficiency list - reconstruction & PID & cut
1108 //Adding each monitored object in the list
1109 fEfficiencyList = new TList();
1111 //MC primary protons and antiprotons for the reconstruction efficiency
1112 TH2D *gHistMCYPtProtons = 0x0;
1113 if(fUseAsymmetricBinning)
1114 gHistMCYPtProtons = new TH2D("gHistMCYPtProtons",
1116 fNBinsY,fY,fNBinsPt,fPt);
1118 gHistMCYPtProtons = new TH2D("gHistMCYPtProtons",
1120 fNBinsY,fMinY,fMaxY,
1121 fNBinsPt,fMinPt,fMaxPt);
1122 if(fProtonAnalysisBase->GetEtaMode())
1123 gHistMCYPtProtons->GetXaxis()->SetTitle("#eta");
1125 gHistMCYPtProtons->GetXaxis()->SetTitle("y");
1126 gHistMCYPtProtons->SetStats(kTRUE);
1127 gHistMCYPtProtons->GetXaxis()->SetTitleColor(1);
1128 fEfficiencyList->Add(gHistMCYPtProtons);
1129 TH2D *gHistMCYPtAntiProtons = 0x0;
1130 if(fUseAsymmetricBinning)
1131 gHistMCYPtAntiProtons = new TH2D("gHistMCYPtAntiProtons",
1133 fNBinsY,fY,fNBinsPt,fPt);
1135 gHistMCYPtAntiProtons = new TH2D("gHistMCYPtAntiProtons",
1137 fNBinsY,fMinY,fMaxY,
1138 fNBinsPt,fMinPt,fMaxPt);
1139 if(fProtonAnalysisBase->GetEtaMode())
1140 gHistMCYPtAntiProtons->GetXaxis()->SetTitle("#eta");
1142 gHistMCYPtAntiProtons->GetXaxis()->SetTitle("y");
1143 gHistMCYPtAntiProtons->SetStats(kTRUE);
1144 gHistMCYPtAntiProtons->GetXaxis()->SetTitleColor(1);
1145 fEfficiencyList->Add(gHistMCYPtAntiProtons);
1147 //MC secondary protons and antiprotons that come from weak decay for the reconstruction efficiency
1148 TH2D *gHistMCYPtProtonsFromWeak = 0x0;
1149 if(fUseAsymmetricBinning)
1150 gHistMCYPtProtonsFromWeak = new TH2D("gHistMCYPtProtonsFromWeak",
1152 fNBinsY,fY,fNBinsPt,fPt);
1154 gHistMCYPtProtonsFromWeak = new TH2D("gHistMCYPtProtonsFromWeak",
1156 fNBinsY,fMinY,fMaxY,
1157 fNBinsPt,fMinPt,fMaxPt);
1158 if(fProtonAnalysisBase->GetEtaMode())
1159 gHistMCYPtProtonsFromWeak->GetXaxis()->SetTitle("#eta");
1161 gHistMCYPtProtonsFromWeak->GetXaxis()->SetTitle("y");
1162 gHistMCYPtProtonsFromWeak->SetStats(kTRUE);
1163 gHistMCYPtProtonsFromWeak->GetXaxis()->SetTitleColor(1);
1164 fEfficiencyList->Add(gHistMCYPtProtonsFromWeak);
1165 TH2D *gHistMCYPtAntiProtonsFromWeak = 0x0;
1166 if(fUseAsymmetricBinning)
1167 gHistMCYPtAntiProtonsFromWeak = new TH2D("gHistMCYPtAntiProtonsFromWeak",
1169 fNBinsY,fY,fNBinsPt,fPt);
1171 gHistMCYPtAntiProtonsFromWeak = new TH2D("gHistMCYPtAntiProtonsFromWeak",
1173 fNBinsY,fMinY,fMaxY,
1174 fNBinsPt,fMinPt,fMaxPt);
1175 if(fProtonAnalysisBase->GetEtaMode())
1176 gHistMCYPtAntiProtonsFromWeak->GetXaxis()->SetTitle("#eta");
1178 gHistMCYPtAntiProtonsFromWeak->GetXaxis()->SetTitle("y");
1179 gHistMCYPtAntiProtonsFromWeak->SetStats(kTRUE);
1180 gHistMCYPtAntiProtonsFromWeak->GetXaxis()->SetTitleColor(1);
1181 fEfficiencyList->Add(gHistMCYPtAntiProtonsFromWeak);
1183 //MC secondary protons and antiprotons that come from hadronic interactions for the reconstruction efficiency
1184 TH2D *gHistMCYPtProtonsFromHadronic = 0x0;
1185 if(fUseAsymmetricBinning)
1186 gHistMCYPtProtonsFromHadronic = new TH2D("gHistMCYPtProtonsFromHadronic",
1188 fNBinsY,fY,fNBinsPt,fPt);
1190 gHistMCYPtProtonsFromHadronic = new TH2D("gHistMCYPtProtonsFromHadronic",
1192 fNBinsY,fMinY,fMaxY,
1193 fNBinsPt,fMinPt,fMaxPt);
1194 if(fProtonAnalysisBase->GetEtaMode())
1195 gHistMCYPtProtonsFromHadronic->GetXaxis()->SetTitle("#eta");
1197 gHistMCYPtProtonsFromHadronic->GetXaxis()->SetTitle("y");
1198 gHistMCYPtProtonsFromHadronic->SetStats(kTRUE);
1199 gHistMCYPtProtonsFromHadronic->GetXaxis()->SetTitleColor(1);
1200 fEfficiencyList->Add(gHistMCYPtProtonsFromHadronic);
1201 TH2D *gHistMCYPtAntiProtonsFromHadronic = 0x0;
1202 if(fUseAsymmetricBinning)
1203 gHistMCYPtAntiProtonsFromHadronic = new TH2D("gHistMCYPtAntiProtonsFromHadronic",
1205 fNBinsY,fY,fNBinsPt,fPt);
1207 gHistMCYPtAntiProtonsFromHadronic = new TH2D("gHistMCYPtAntiProtonsFromHadronic",
1209 fNBinsY,fMinY,fMaxY,
1210 fNBinsPt,fMinPt,fMaxPt);
1211 if(fProtonAnalysisBase->GetEtaMode())
1212 gHistMCYPtAntiProtonsFromHadronic->GetXaxis()->SetTitle("#eta");
1214 gHistMCYPtAntiProtonsFromHadronic->GetXaxis()->SetTitle("y");
1215 gHistMCYPtAntiProtonsFromHadronic->SetStats(kTRUE);
1216 gHistMCYPtAntiProtonsFromHadronic->GetXaxis()->SetTitleColor(1);
1217 fEfficiencyList->Add(gHistMCYPtAntiProtonsFromHadronic);
1219 //ESD primary protons and antiprotons for the reconstruction efficiency
1220 TH2D *gHistESDYPtProtons = 0x0;
1221 if(fUseAsymmetricBinning)
1222 gHistESDYPtProtons = new TH2D("gHistESDYPtProtons",
1224 fNBinsY,fY,fNBinsPt,fPt);
1226 gHistESDYPtProtons = new TH2D("gHistESDYPtProtons",
1228 fNBinsY,fMinY,fMaxY,
1229 fNBinsPt,fMinPt,fMaxPt);
1230 if(fProtonAnalysisBase->GetEtaMode())
1231 gHistESDYPtProtons->GetXaxis()->SetTitle("#eta");
1233 gHistESDYPtProtons->GetXaxis()->SetTitle("y");
1234 gHistESDYPtProtons->SetStats(kTRUE);
1235 gHistESDYPtProtons->GetXaxis()->SetTitleColor(1);
1236 fEfficiencyList->Add(gHistESDYPtProtons);
1237 TH2D *gHistESDYPtAntiProtons = 0x0;
1238 if(fUseAsymmetricBinning)
1239 gHistESDYPtAntiProtons = new TH2D("gHistESDYPtAntiProtons",
1241 fNBinsY,fY,fNBinsPt,fPt);
1243 gHistESDYPtAntiProtons = new TH2D("gHistESDYPtAntiProtons",
1245 fNBinsY,fMinY,fMaxY,
1246 fNBinsPt,fMinPt,fMaxPt);
1247 if(fProtonAnalysisBase->GetEtaMode())
1248 gHistESDYPtAntiProtons->GetXaxis()->SetTitle("#eta");
1250 gHistESDYPtAntiProtons->GetXaxis()->SetTitle("y");
1251 gHistESDYPtAntiProtons->SetStats(kTRUE);
1252 gHistESDYPtAntiProtons->GetXaxis()->SetTitleColor(1);
1253 fEfficiencyList->Add(gHistESDYPtAntiProtons);
1255 //ESD (anti)protons from weak decays for the reconstruction efficiency
1256 TH2D *gHistESDYPtProtonsFromWeak = 0x0;
1257 if(fUseAsymmetricBinning)
1258 gHistESDYPtProtonsFromWeak = new TH2D("gHistESDYPtProtonsFromWeak",
1260 fNBinsY,fY,fNBinsPt,fPt);
1262 gHistESDYPtProtonsFromWeak = new TH2D("gHistESDYPtProtonsFromWeak",
1264 fNBinsY,fMinY,fMaxY,
1265 fNBinsPt,fMinPt,fMaxPt);
1266 if(fProtonAnalysisBase->GetEtaMode())
1267 gHistESDYPtProtonsFromWeak->GetXaxis()->SetTitle("#eta");
1269 gHistESDYPtProtonsFromWeak->GetXaxis()->SetTitle("y");
1270 gHistESDYPtProtonsFromWeak->SetStats(kTRUE);
1271 gHistESDYPtProtonsFromWeak->GetXaxis()->SetTitleColor(1);
1272 fEfficiencyList->Add(gHistESDYPtProtonsFromWeak);
1273 TH2D *gHistESDYPtAntiProtonsFromWeak = 0x0;
1274 if(fUseAsymmetricBinning)
1275 gHistESDYPtAntiProtonsFromWeak = new TH2D("gHistESDYPtAntiProtonsFromWeak",
1277 fNBinsY,fY,fNBinsPt,fPt);
1279 gHistESDYPtAntiProtonsFromWeak = new TH2D("gHistESDYPtAntiProtonsFromWeak",
1281 fNBinsY,fMinY,fMaxY,
1282 fNBinsPt,fMinPt,fMaxPt);
1283 if(fProtonAnalysisBase->GetEtaMode())
1284 gHistESDYPtAntiProtonsFromWeak->GetXaxis()->SetTitle("#eta");
1286 gHistESDYPtAntiProtonsFromWeak->GetXaxis()->SetTitle("y");
1287 gHistESDYPtAntiProtonsFromWeak->SetStats(kTRUE);
1288 gHistESDYPtAntiProtonsFromWeak->GetXaxis()->SetTitleColor(1);
1289 fEfficiencyList->Add(gHistESDYPtAntiProtonsFromWeak);
1291 //ESD (anti)protons from hadronic interactions for the reconstruction efficiency
1292 TH2D *gHistESDYPtProtonsFromHadronic = 0x0;
1293 if(fUseAsymmetricBinning)
1294 gHistESDYPtProtonsFromHadronic = new TH2D("gHistESDYPtProtonsFromHadronic",
1296 fNBinsY,fY,fNBinsPt,fPt);
1298 gHistESDYPtProtonsFromHadronic = new TH2D("gHistESDYPtProtonsFromHadronic",
1300 fNBinsY,fMinY,fMaxY,
1301 fNBinsPt,fMinPt,fMaxPt);
1302 if(fProtonAnalysisBase->GetEtaMode())
1303 gHistESDYPtProtonsFromHadronic->GetXaxis()->SetTitle("#eta");
1305 gHistESDYPtProtonsFromHadronic->GetXaxis()->SetTitle("y");
1306 gHistESDYPtProtonsFromHadronic->SetStats(kTRUE);
1307 gHistESDYPtProtonsFromHadronic->GetXaxis()->SetTitleColor(1);
1308 fEfficiencyList->Add(gHistESDYPtProtonsFromHadronic);
1309 TH2D *gHistESDYPtAntiProtonsFromHadronic = 0x0;
1310 if(fUseAsymmetricBinning)
1311 gHistESDYPtAntiProtonsFromHadronic = new TH2D("gHistESDYPtAntiProtonsFromHadronic",
1313 fNBinsY,fY,fNBinsPt,fPt);
1315 gHistESDYPtAntiProtonsFromHadronic = new TH2D("gHistESDYPtAntiProtonsFromHadronic",
1317 fNBinsY,fMinY,fMaxY,
1318 fNBinsPt,fMinPt,fMaxPt);
1319 if(fProtonAnalysisBase->GetEtaMode())
1320 gHistESDYPtAntiProtonsFromHadronic->GetXaxis()->SetTitle("#eta");
1322 gHistESDYPtAntiProtonsFromHadronic->GetXaxis()->SetTitle("y");
1323 gHistESDYPtAntiProtonsFromHadronic->SetStats(kTRUE);
1324 gHistESDYPtAntiProtonsFromHadronic->GetXaxis()->SetTitleColor(1);
1325 fEfficiencyList->Add(gHistESDYPtAntiProtonsFromHadronic);
1327 //ESD reconstructed tracks that were initially protons for the PID efficiency
1328 TH3D *gHistESDInitYPtProtons = 0x0;
1329 if(fUseAsymmetricBinning) {
1330 Double_t gNPoints[51];
1331 for(Int_t i = 0; i < 51; i++)
1333 gHistESDInitYPtProtons = new TH3D("gHistESDInitYPtProtons",
1334 ";;P_{T} [GeV/c];N_{points}",
1335 fNBinsY,fY,fNBinsPt,fPt,50,gNPoints);
1338 gHistESDInitYPtProtons = new TH3D("gHistESDInitYPtProtons",
1339 ";;P_{T} [GeV/c];N_{points}",
1340 fNBinsY,fMinY,fMaxY,
1341 fNBinsPt,fMinPt,fMaxPt,
1343 if(fProtonAnalysisBase->GetEtaMode())
1344 gHistESDInitYPtProtons->GetXaxis()->SetTitle("#eta");
1346 gHistESDInitYPtProtons->GetXaxis()->SetTitle("y");
1347 gHistESDInitYPtProtons->SetStats(kTRUE);
1348 gHistESDInitYPtProtons->GetXaxis()->SetTitleColor(1);
1349 fEfficiencyList->Add(gHistESDInitYPtProtons);
1351 //ESD reconstructed tracks that were initially protons and were identified as protons for the PID efficiency
1352 TH3D *gHistESDIdYPtProtons = 0x0;
1353 if(fUseAsymmetricBinning) {
1354 Double_t gNPoints[51];
1355 for(Int_t i = 0; i < 51; i++)
1357 gHistESDIdYPtProtons = new TH3D("gHistESDIdYPtProtons",
1358 ";;P_{T} [GeV/c];N_{points}",
1359 fNBinsY,fY,fNBinsPt,fPt,50,gNPoints);
1362 gHistESDIdYPtProtons = new TH3D("gHistESDIdYPtProtons",
1363 ";;P_{T} [GeV/c];N_{points}",
1364 fNBinsY,fMinY,fMaxY,
1365 fNBinsPt,fMinPt,fMaxPt,
1367 if(fProtonAnalysisBase->GetEtaMode())
1368 gHistESDIdYPtProtons->GetXaxis()->SetTitle("#eta");
1370 gHistESDIdYPtProtons->GetXaxis()->SetTitle("y");
1371 gHistESDIdYPtProtons->SetStats(kTRUE);
1372 gHistESDIdYPtProtons->GetXaxis()->SetTitleColor(1);
1373 fEfficiencyList->Add(gHistESDIdYPtProtons);
1375 //ESD reconstructed tracks that were identified as protons for the PID contamination
1376 TH3D *gHistESDRecIdYPtProtons = 0x0;
1377 if(fUseAsymmetricBinning) {
1378 Double_t gNPoints[51];
1379 for(Int_t i = 0; i < 51; i++)
1381 gHistESDRecIdYPtProtons = new TH3D("gHistESDRecIdYPtProtons",
1382 ";;P_{T} [GeV/c];N_{points}",
1383 fNBinsY,fY,fNBinsPt,fPt,50,gNPoints);
1386 gHistESDRecIdYPtProtons = new TH3D("gHistESDRecIdYPtProtons",
1387 ";;P_{T} [GeV/c];N_{points}",
1388 fNBinsY,fMinY,fMaxY,
1389 fNBinsPt,fMinPt,fMaxPt,
1391 if(fProtonAnalysisBase->GetEtaMode())
1392 gHistESDRecIdYPtProtons->GetXaxis()->SetTitle("#eta");
1394 gHistESDRecIdYPtProtons->GetXaxis()->SetTitle("y");
1395 gHistESDRecIdYPtProtons->SetStats(kTRUE);
1396 gHistESDRecIdYPtProtons->GetXaxis()->SetTitleColor(1);
1397 fEfficiencyList->Add(gHistESDRecIdYPtProtons);
1399 //ESD reconstructed tracks that were identified as protons but were initially not protons for the PID contamination
1400 TH3D *gHistESDContamYPtProtons = 0x0;
1401 if(fUseAsymmetricBinning) {
1402 Double_t gNPoints[51];
1403 for(Int_t i = 0; i < 51; i++)
1405 gHistESDContamYPtProtons = new TH3D("gHistESDContamYPtProtons",
1406 ";;P_{T} [GeV/c];N_{points}",
1407 fNBinsY,fY,fNBinsPt,fPt,50,gNPoints);
1410 gHistESDContamYPtProtons = new TH3D("gHistESDContamYPtProtons",
1411 ";;P_{T} [GeV/c];N_{points}",
1412 fNBinsY,fMinY,fMaxY,
1413 fNBinsPt,fMinPt,fMaxPt,
1415 if(fProtonAnalysisBase->GetEtaMode())
1416 gHistESDContamYPtProtons->GetXaxis()->SetTitle("#eta");
1418 gHistESDContamYPtProtons->GetXaxis()->SetTitle("y");
1419 gHistESDContamYPtProtons->SetStats(kTRUE);
1420 gHistESDContamYPtProtons->GetXaxis()->SetTitleColor(1);
1421 fEfficiencyList->Add(gHistESDContamYPtProtons);
1426 fCutEfficiencyList = new TList();
1427 //Reconstructed primary tracks that were identified as protons
1428 TH2D *gHistESDYPtProtonsTotal = 0x0;
1429 if(fUseAsymmetricBinning)
1430 gHistESDYPtProtonsTotal = new TH2D("gHistESDYPtProtonsTotal",
1432 fNBinsY,fY,fNBinsPt,fPt);
1434 gHistESDYPtProtonsTotal = new TH2D("gHistESDYPtProtonsTotal",
1436 fNBinsY,fMinY,fMaxY,
1437 fNBinsPt,fMinPt,fMaxPt);
1438 if(fProtonAnalysisBase->GetEtaMode())
1439 gHistESDYPtProtonsTotal->GetXaxis()->SetTitle("#eta");
1441 gHistESDYPtProtonsTotal->GetXaxis()->SetTitle("y");
1442 gHistESDYPtProtonsTotal->SetStats(kTRUE);
1443 gHistESDYPtProtonsTotal->GetXaxis()->SetTitleColor(1);
1444 fCutEfficiencyList->Add(gHistESDYPtProtonsTotal);
1446 //Reconstructed primary tracks that were identified as antiprotons
1447 TH2D *gHistESDYPtAntiProtonsTotal = 0x0;
1448 if(fUseAsymmetricBinning)
1449 gHistESDYPtAntiProtonsTotal = new TH2D("gHistESDYPtAntiProtonsTotal",
1451 fNBinsY,fY,fNBinsPt,fPt);
1453 gHistESDYPtAntiProtonsTotal = new TH2D("gHistESDYPtAntiProtonsTotal",
1455 fNBinsY,fMinY,fMaxY,
1456 fNBinsPt,fMinPt,fMaxPt);
1457 if(fProtonAnalysisBase->GetEtaMode())
1458 gHistESDYPtAntiProtonsTotal->GetXaxis()->SetTitle("#eta");
1460 gHistESDYPtAntiProtonsTotal->GetXaxis()->SetTitle("y");
1461 gHistESDYPtAntiProtonsTotal->SetStats(kTRUE);
1462 gHistESDYPtAntiProtonsTotal->GetXaxis()->SetTitleColor(1);
1463 fCutEfficiencyList->Add(gHistESDYPtAntiProtonsTotal);
1465 //Reconstructed, survived primary tracks that were identified as protons
1466 TH2D *gHistESDYPtProtonsSurvived = 0x0;
1467 if(fUseAsymmetricBinning)
1468 gHistESDYPtProtonsSurvived = new TH2D("gHistESDYPtProtonsSurvived",
1470 fNBinsY,fY,fNBinsPt,fPt);
1472 gHistESDYPtProtonsSurvived = new TH2D("gHistESDYPtProtonsSurvived",
1474 fNBinsY,fMinY,fMaxY,
1475 fNBinsPt,fMinPt,fMaxPt);
1476 if(fProtonAnalysisBase->GetEtaMode())
1477 gHistESDYPtProtonsSurvived->GetXaxis()->SetTitle("#eta");
1479 gHistESDYPtProtonsSurvived->GetXaxis()->SetTitle("y");
1480 gHistESDYPtProtonsSurvived->SetStats(kTRUE);
1481 gHistESDYPtProtonsSurvived->GetXaxis()->SetTitleColor(1);
1482 fCutEfficiencyList->Add(gHistESDYPtProtonsSurvived);
1484 //Reconstructed, survived primary tracks that were identified as antiprotons
1485 TH2D *gHistESDYPtAntiProtonsSurvived = 0x0;
1486 if(fUseAsymmetricBinning)
1487 gHistESDYPtAntiProtonsSurvived = new TH2D("gHistESDYPtAntiProtonsSurvived",
1489 fNBinsY,fY,fNBinsPt,fPt);
1491 gHistESDYPtAntiProtonsSurvived = new TH2D("gHistESDYPtAntiProtonsSurvived",
1493 fNBinsY,fMinY,fMaxY,
1494 fNBinsPt,fMinPt,fMaxPt);
1495 if(fProtonAnalysisBase->GetEtaMode())
1496 gHistESDYPtAntiProtonsSurvived->GetXaxis()->SetTitle("#eta");
1498 gHistESDYPtAntiProtonsSurvived->GetXaxis()->SetTitle("y");
1499 gHistESDYPtAntiProtonsSurvived->SetStats(kTRUE);
1500 gHistESDYPtAntiProtonsSurvived->GetXaxis()->SetTitleColor(1);
1501 fCutEfficiencyList->Add(gHistESDYPtAntiProtonsSurvived);
1504 //____________________________________________________________________//
1505 void AliProtonQAAnalysis::InitCutLists() {
1506 //Initialization of the cut lists
1507 //Adding each monitored object in each list
1510 fAcceptedCutList = new TList();
1511 TH1F *gPrimaryProtonsClustersOnITSLayers = new TH1F("gPrimaryProtonsClustersOnITSLayers",";ITS Layer;Entries",6,0.5,6.5);
1512 fAcceptedCutList->Add(gPrimaryProtonsClustersOnITSLayers);
1513 TH1F *gPrimaryAntiProtonsClustersOnITSLayers = new TH1F("gPrimaryAntiProtonsClustersOnITSLayers",";ITS Layer;Entries",6,0.5,6.5);
1514 fAcceptedCutList->Add(gPrimaryAntiProtonsClustersOnITSLayers);
1515 TH1F *gSecondaryProtonsClustersOnITSLayers = new TH1F("gSecondaryProtonsClustersOnITSLayers",";ITS Layer;Entries",6,0.5,6.5);
1516 fAcceptedCutList->Add(gSecondaryProtonsClustersOnITSLayers);
1517 TH1F *gSecondaryAntiProtonsClustersOnITSLayers = new TH1F("gSecondaryAntiProtonsClustersOnITSLayers",";ITS Layer;Entries",6,0.5,6.5);
1518 fAcceptedCutList->Add(gSecondaryAntiProtonsClustersOnITSLayers);
1520 TH1F *gPrimaryProtonsNClustersITS = new TH1F("gPrimaryProtonsNClustersITS",";ITS Layer;Entries",6,0.5,6.5);
1521 fAcceptedCutList->Add(gPrimaryProtonsNClustersITS);
1522 TH1F *gPrimaryAntiProtonsNClustersITS = new TH1F("gPrimaryAntiProtonsNClustersITS",";ITS Layer;Entries",6,0.5,6.5);
1523 fAcceptedCutList->Add(gPrimaryAntiProtonsNClustersITS);
1524 TH1F *gSecondaryProtonsNClustersITS = new TH1F("gSecondaryProtonsNClustersITS",";ITS Layer;Entries",6,0.5,6.5);
1525 fAcceptedCutList->Add(gSecondaryProtonsNClustersITS);
1526 TH1F *gSecondaryAntiProtonsNClustersITS = new TH1F("gSecondaryAntiProtonsNClustersITS",";ITS Layer;Entries",6,0.5,6.5);
1527 fAcceptedCutList->Add(gSecondaryAntiProtonsNClustersITS);
1529 TH1F *gPrimaryProtonsChi2PerClusterITS = new TH1F("gPrimaryProtonsChi2PerClusterITS",
1530 ";x^{2}/N_{clusters} (ITS);Entries",
1532 fAcceptedCutList->Add(gPrimaryProtonsChi2PerClusterITS);
1533 TH1F *gPrimaryAntiProtonsChi2PerClusterITS = new TH1F("gPrimaryAntiProtonsChi2PerClusterITS",
1534 ";x^{2}/N_{clusters} (ITS);Entries",
1536 fAcceptedCutList->Add(gPrimaryAntiProtonsChi2PerClusterITS);
1537 TH1F *gSecondaryProtonsChi2PerClusterITS = new TH1F("gSecondaryProtonsChi2PerClusterITS",
1538 ";x^{2}/N_{clusters} (ITS);Entries",
1540 fAcceptedCutList->Add(gSecondaryProtonsChi2PerClusterITS);
1541 TH1F *gSecondaryAntiProtonsChi2PerClusterITS = new TH1F("gSecondaryAntiProtonsChi2PerClusterITS",
1542 ";x^{2}/N_{clusters} (ITS);Entries",
1544 fAcceptedCutList->Add(gSecondaryAntiProtonsChi2PerClusterITS);
1546 TH1F *gPrimaryProtonsConstrainChi2 = new TH1F("gPrimaryProtonsConstrainChi2",
1547 ";Log_{10}(#chi^{2});Entries",
1549 fAcceptedCutList->Add(gPrimaryProtonsConstrainChi2);
1550 TH1F *gPrimaryAntiProtonsConstrainChi2 = new TH1F("gPrimaryAntiProtonsConstrainChi2",
1551 ";Log_{10}(#chi^{2});Entries",
1553 fAcceptedCutList->Add(gPrimaryAntiProtonsConstrainChi2);
1554 TH1F *gSecondaryProtonsConstrainChi2 = new TH1F("gSecondaryProtonsConstrainChi2",
1555 ";Log_{10}(#chi^{2});Entries",
1557 fAcceptedCutList->Add(gSecondaryProtonsConstrainChi2);
1558 TH1F *gSecondaryAntiProtonsConstrainChi2 = new TH1F("gSecondaryAntiProtonsConstrainChi2",
1559 ";Log_{10}(#chi^{2});Entries",
1561 fAcceptedCutList->Add(gSecondaryAntiProtonsConstrainChi2);
1563 TH1F *gPrimaryProtonsTPCClusters = new TH1F("gPrimaryProtonsTPCClusters",
1564 ";N_{clusters} (TPC);Entries",
1566 fAcceptedCutList->Add(gPrimaryProtonsTPCClusters);
1567 TH1F *gPrimaryAntiProtonsTPCClusters = new TH1F("gPrimaryAntiProtonsTPCClusters",
1568 ";N_{clusters} (TPC);Entries",
1570 fAcceptedCutList->Add(gPrimaryAntiProtonsTPCClusters);
1571 TH1F *gSecondaryProtonsTPCClusters = new TH1F("gSecondaryProtonsTPCClusters",
1572 ";N_{clusters} (TPC);Entries",
1574 fAcceptedCutList->Add(gSecondaryProtonsTPCClusters);
1575 TH1F *gSecondaryAntiProtonsTPCClusters = new TH1F("gSecondaryAntiProtonsTPCClusters",
1576 ";N_{clusters} (TPC);Entries",
1578 fAcceptedCutList->Add(gSecondaryAntiProtonsTPCClusters);
1580 TH1F *gPrimaryProtonsChi2PerClusterTPC = new TH1F("gPrimaryProtonsChi2PerClusterTPC",
1581 ";x^{2}/N_{clusters} (TPC);Entries",
1583 fAcceptedCutList->Add(gPrimaryProtonsChi2PerClusterTPC);
1584 TH1F *gPrimaryAntiProtonsChi2PerClusterTPC = new TH1F("gPrimaryAntiProtonsChi2PerClusterTPC",
1585 ";x^{2}/N_{clusters} (TPC);Entries",
1587 fAcceptedCutList->Add(gPrimaryAntiProtonsChi2PerClusterTPC);
1588 TH1F *gSecondaryProtonsChi2PerClusterTPC = new TH1F("gSecondaryProtonsChi2PerClusterTPC",
1589 ";x^{2}/N_{clusters} (TPC);Entries",
1591 fAcceptedCutList->Add(gSecondaryProtonsChi2PerClusterTPC);
1592 TH1F *gSecondaryAntiProtonsChi2PerClusterTPC = new TH1F("gSecondaryAntiProtonsChi2PerClusterTPC",
1593 ";x^{2}/N_{clusters} (TPC);Entries",
1595 fAcceptedCutList->Add(gSecondaryAntiProtonsChi2PerClusterTPC);
1597 TH1F *gPrimaryProtonsExtCov11 = new TH1F("gPrimaryProtonsExtCov11",
1598 ";#sigma_{y} [cm];Entries",
1600 fAcceptedCutList->Add(gPrimaryProtonsExtCov11);
1601 TH1F *gPrimaryAntiProtonsExtCov11 = new TH1F("gPrimaryAntiProtonsExtCov11",
1602 ";#sigma_{y} [cm];Entries",
1604 fAcceptedCutList->Add(gPrimaryAntiProtonsExtCov11);
1605 TH1F *gSecondaryProtonsExtCov11 = new TH1F("gSecondaryProtonsExtCov11",
1606 ";#sigma_{y} [cm];Entries",
1608 fAcceptedCutList->Add(gSecondaryProtonsExtCov11);
1609 TH1F *gSecondaryAntiProtonsExtCov11 = new TH1F("gSecondaryAntiProtonsExtCov11",
1610 ";#sigma_{y} [cm];Entries",
1612 fAcceptedCutList->Add(gSecondaryAntiProtonsExtCov11);
1615 TH1F *gPrimaryProtonsExtCov22 = new TH1F("gPrimaryProtonsExtCov22",
1616 ";#sigma_{z} [cm];Entries",
1618 fAcceptedCutList->Add(gPrimaryProtonsExtCov22);
1619 TH1F *gPrimaryAntiProtonsExtCov22 = new TH1F("gPrimaryAntiProtonsExtCov22",
1620 ";#sigma_{z} [cm];Entries",
1622 fAcceptedCutList->Add(gPrimaryAntiProtonsExtCov22);
1623 TH1F *gSecondaryProtonsExtCov22 = new TH1F("gSecondaryProtonsExtCov22",
1624 ";#sigma_{z} [cm];Entries",
1626 fAcceptedCutList->Add(gSecondaryProtonsExtCov22);
1627 TH1F *gSecondaryAntiProtonsExtCov22 = new TH1F("gSecondaryAntiProtonsExtCov22",
1628 ";#sigma_{z} [cm];Entries",
1630 fAcceptedCutList->Add(gSecondaryAntiProtonsExtCov22);
1633 TH1F *gPrimaryProtonsExtCov33 = new TH1F("gPrimaryProtonsExtCov33",
1634 ";#sigma_{sin(#phi)};Entries",
1636 fAcceptedCutList->Add(gPrimaryProtonsExtCov33);
1637 TH1F *gPrimaryAntiProtonsExtCov33 = new TH1F("gPrimaryAntiProtonsExtCov33",
1638 ";#sigma_{sin(#phi)};Entries",
1640 fAcceptedCutList->Add(gPrimaryAntiProtonsExtCov33);
1641 TH1F *gSecondaryProtonsExtCov33 = new TH1F("gSecondaryProtonsExtCov33",
1642 ";#sigma_{sin(#phi)};Entries",
1644 fAcceptedCutList->Add(gSecondaryProtonsExtCov33);
1645 TH1F *gSecondaryAntiProtonsExtCov33 = new TH1F("gSecondaryAntiProtonsExtCov33",
1646 ";#sigma_{sin(#phi)};Entries",
1648 fAcceptedCutList->Add(gSecondaryAntiProtonsExtCov33);
1651 TH1F *gPrimaryProtonsExtCov44 = new TH1F("gPrimaryProtonsExtCov44",
1652 ";#sigma_{tan(#lambda)};Entries",
1654 fAcceptedCutList->Add(gPrimaryProtonsExtCov44);
1655 TH1F *gPrimaryAntiProtonsExtCov44 = new TH1F("gPrimaryAntiProtonsExtCov44",
1656 ";#sigma_{tan(#lambda)};Entries",
1658 fAcceptedCutList->Add(gPrimaryAntiProtonsExtCov44);
1659 TH1F *gSecondaryProtonsExtCov44 = new TH1F("gSecondaryProtonsExtCov44",
1660 ";#sigma_{tan(#lambda)};Entries",
1662 fAcceptedCutList->Add(gSecondaryProtonsExtCov44);
1663 TH1F *gSecondaryAntiProtonsExtCov44 = new TH1F("gSecondaryAntiProtonsExtCov44",
1664 ";#sigma_{tan(#lambda)};Entries",
1666 fAcceptedCutList->Add(gSecondaryAntiProtonsExtCov44);
1669 TH1F *gPrimaryProtonsExtCov55 = new TH1F("gPrimaryProtonsExtCov55",
1670 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
1672 fAcceptedCutList->Add(gPrimaryProtonsExtCov55);
1673 TH1F *gPrimaryAntiProtonsExtCov55 = new TH1F("gPrimaryAntiProtonsExtCov55",
1674 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
1676 fAcceptedCutList->Add(gPrimaryAntiProtonsExtCov55);
1677 TH1F *gSecondaryProtonsExtCov55 = new TH1F("gSecondaryProtonsExtCov55",
1678 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
1680 fAcceptedCutList->Add(gSecondaryProtonsExtCov55);
1681 TH1F *gSecondaryAntiProtonsExtCov55 = new TH1F("gSecondaryAntiProtonsExtCov55",
1682 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
1684 fAcceptedCutList->Add(gSecondaryAntiProtonsExtCov55);
1686 TH3D *gHistEtaPhiNClustersPrimaryProtonsPass = new TH3D("gHistEtaPhiNClustersPrimaryProtonsPass",
1687 "Accepted primary protons;#eta;#phi;N_{clusters}(TPC)",
1688 fNBinsY,fMinY,fMaxY,
1691 gHistEtaPhiNClustersPrimaryProtonsPass->SetStats(kTRUE);
1692 gHistEtaPhiNClustersPrimaryProtonsPass->GetXaxis()->SetTitleColor(1);
1693 fAcceptedCutList->Add(gHistEtaPhiNClustersPrimaryProtonsPass);//eta-phi of primary accepted ESD protons
1694 TH3D *gHistEtaPhiNClustersPrimaryAntiProtonsPass = new TH3D("gHistEtaPhiNClustersPrimaryAntiProtonsPass",
1695 "Accepted primary antiprotons;#eta;#phi;N_{clusters}(TPC)",
1696 fNBinsY,fMinY,fMaxY,
1699 gHistEtaPhiNClustersPrimaryAntiProtonsPass->SetStats(kTRUE);
1700 gHistEtaPhiNClustersPrimaryAntiProtonsPass->GetXaxis()->SetTitleColor(1);
1701 fAcceptedCutList->Add(gHistEtaPhiNClustersPrimaryAntiProtonsPass);//eta-phi of primary accepted ESD antiprotons
1702 TH3D *gHistEtaPhiNClustersSecondaryProtonsPass = new TH3D("gHistEtaPhiNClustersSecondaryProtonsPass",
1703 "Accepted secondary protons;#eta;#phi;N_{clusters}(TPC)",
1704 fNBinsY,fMinY,fMaxY,
1707 gHistEtaPhiNClustersSecondaryProtonsPass->SetStats(kTRUE);
1708 gHistEtaPhiNClustersSecondaryProtonsPass->GetXaxis()->SetTitleColor(1);
1709 fAcceptedCutList->Add(gHistEtaPhiNClustersSecondaryProtonsPass);//eta-phi of secondary accepted ESD protons
1710 TH3D *gHistEtaPhiNClustersSecondaryAntiProtonsPass = new TH3D("gHistEtaPhiNClustersSecondaryAntiProtonsPass",
1711 "Accepted secondary antiprotons;#eta;#phi;N_{clusters}(TPC)",
1712 fNBinsY,fMinY,fMaxY,
1715 gHistEtaPhiNClustersSecondaryAntiProtonsPass->SetStats(kTRUE);
1716 gHistEtaPhiNClustersSecondaryAntiProtonsPass->GetXaxis()->SetTitleColor(1);
1717 fAcceptedCutList->Add(gHistEtaPhiNClustersSecondaryAntiProtonsPass);//eta-phi of secondary accepted ESD antiprotons
1718 //eta-phi-chi^2 per TPC cluster
1719 TH3D *gHistEtaPhiChi2PerTPCClusterPrimaryProtonsPass = new TH3D("gHistEtaPhiChi2PerTPCClusterPrimaryProtonsPass",
1720 "Accepted primary protons;#eta;#phi;#chi^{2}/N_{clusters}(TPC)",
1721 fNBinsY,fMinY,fMaxY,
1724 gHistEtaPhiChi2PerTPCClusterPrimaryProtonsPass->SetStats(kTRUE);
1725 gHistEtaPhiChi2PerTPCClusterPrimaryProtonsPass->GetXaxis()->SetTitleColor(1);
1726 fAcceptedCutList->Add(gHistEtaPhiChi2PerTPCClusterPrimaryProtonsPass);//eta-phi of primary accepted ESD protons
1727 TH3D *gHistEtaPhiChi2PerTPCClusterPrimaryAntiProtonsPass = new TH3D("gHistEtaPhiChi2PerTPCClusterPrimaryAntiProtonsPass",
1728 "Accepted primary antiprotons;#eta;#phi;#chi^{2}/N_{clusters}(TPC)",
1729 fNBinsY,fMinY,fMaxY,
1732 gHistEtaPhiChi2PerTPCClusterPrimaryAntiProtonsPass->SetStats(kTRUE);
1733 gHistEtaPhiChi2PerTPCClusterPrimaryAntiProtonsPass->GetXaxis()->SetTitleColor(1);
1734 fAcceptedCutList->Add(gHistEtaPhiChi2PerTPCClusterPrimaryAntiProtonsPass);//eta-phi of primary accepted ESD antiprotons
1735 TH3D *gHistEtaPhiChi2PerTPCClusterSecondaryProtonsPass = new TH3D("gHistEtaPhiChi2PerTPCClusterSecondaryProtonsPass",
1736 "Accepted secondary protons;#eta;#phi;#chi^{2}/N_{clusters}(TPC)",
1737 fNBinsY,fMinY,fMaxY,
1740 gHistEtaPhiChi2PerTPCClusterSecondaryProtonsPass->SetStats(kTRUE);
1741 gHistEtaPhiChi2PerTPCClusterSecondaryProtonsPass->GetXaxis()->SetTitleColor(1);
1742 fAcceptedCutList->Add(gHistEtaPhiChi2PerTPCClusterSecondaryProtonsPass);//eta-phi of secondary accepted ESD protons
1743 TH3D *gHistEtaPhiChi2PerTPCClusterSecondaryAntiProtonsPass = new TH3D("gHistEtaPhiChi2PerTPCClusterSecondaryAntiProtonsPass",
1744 "Accepted secondary antiprotons;#eta;#phi;#chi^{2}/N_{clusters}(TPC)",
1745 fNBinsY,fMinY,fMaxY,
1748 gHistEtaPhiChi2PerTPCClusterSecondaryAntiProtonsPass->SetStats(kTRUE);
1749 gHistEtaPhiChi2PerTPCClusterSecondaryAntiProtonsPass->GetXaxis()->SetTitleColor(1);
1750 fAcceptedCutList->Add(gHistEtaPhiChi2PerTPCClusterSecondaryAntiProtonsPass);//eta-phi of secondary accepted ESD antiprotons
1751 //eta-phi-number of TPC points for the dE/dx
1752 TH3D *gHistEtaPhiTPCdEdxNPointsPrimaryProtonsPass = new TH3D("gHistEtaPhiTPCdEdxNPointsPrimaryProtonsPass",
1753 "Accepted primary protons;#eta;#phi;N_{points}(TPC)",
1754 fNBinsY,fMinY,fMaxY,
1757 gHistEtaPhiTPCdEdxNPointsPrimaryProtonsPass->SetStats(kTRUE);
1758 gHistEtaPhiTPCdEdxNPointsPrimaryProtonsPass->GetXaxis()->SetTitleColor(1);
1759 fAcceptedCutList->Add(gHistEtaPhiTPCdEdxNPointsPrimaryProtonsPass);//eta-phi of primary accepted ESD protons
1760 TH3D *gHistEtaPhiTPCdEdxNPointsPrimaryAntiProtonsPass = new TH3D("gHistEtaPhiTPCdEdxNPointsPrimaryAntiProtonsPass",
1761 "Accepted primary antiprotons;#eta;#phi;N_{points}(TPC)",
1762 fNBinsY,fMinY,fMaxY,
1765 gHistEtaPhiTPCdEdxNPointsPrimaryAntiProtonsPass->SetStats(kTRUE);
1766 gHistEtaPhiTPCdEdxNPointsPrimaryAntiProtonsPass->GetXaxis()->SetTitleColor(1);
1767 fAcceptedCutList->Add(gHistEtaPhiTPCdEdxNPointsPrimaryAntiProtonsPass);//eta-phi of primary accepted ESD antiprotons
1768 TH3D *gHistEtaPhiTPCdEdxNPointsSecondaryProtonsPass = new TH3D("gHistEtaPhiTPCdEdxNPointsSecondaryProtonsPass",
1769 "Accepted secondary protons;#eta;#phi;N_{points}(TPC)",
1770 fNBinsY,fMinY,fMaxY,
1773 gHistEtaPhiTPCdEdxNPointsSecondaryProtonsPass->SetStats(kTRUE);
1774 gHistEtaPhiTPCdEdxNPointsSecondaryProtonsPass->GetXaxis()->SetTitleColor(1);
1775 fAcceptedCutList->Add(gHistEtaPhiTPCdEdxNPointsSecondaryProtonsPass);//eta-phi of secondary accepted ESD protons
1776 TH3D *gHistEtaPhiTPCdEdxNPointsSecondaryAntiProtonsPass = new TH3D("gHistEtaPhiTPCdEdxNPointsSecondaryAntiProtonsPass",
1777 "Accepted secondary antiprotons;#eta;#phi;N_{points}(TPC)",
1778 fNBinsY,fMinY,fMaxY,
1781 gHistEtaPhiTPCdEdxNPointsSecondaryAntiProtonsPass->SetStats(kTRUE);
1782 gHistEtaPhiTPCdEdxNPointsSecondaryAntiProtonsPass->GetXaxis()->SetTitleColor(1);
1783 fAcceptedCutList->Add(gHistEtaPhiTPCdEdxNPointsSecondaryAntiProtonsPass);//eta-phi of secondary accepted ESD antiprotons
1785 TH1F *gPrimaryProtonsNPointsTPCdEdx = new TH1F("gPrimaryProtonsNPointsTPCdEdx",
1786 ";N_{points} (TPC-dE/dx);Entries",
1788 fAcceptedCutList->Add(gPrimaryProtonsNPointsTPCdEdx);
1789 TH1F *gPrimaryAntiProtonsNPointsTPCdEdx = new TH1F("gPrimaryAntiProtonsNPointsTPCdEdx",
1790 ";N_{points} (TPC-dE/dx);Entries",
1792 fAcceptedCutList->Add(gPrimaryAntiProtonsNPointsTPCdEdx);
1793 TH1F *gSecondaryProtonsNPointsTPCdEdx = new TH1F("gSecondaryProtonsNPointsTPCdEdx",
1794 ";N_{points} (TPC-dE/dx);Entries",
1796 fAcceptedCutList->Add(gSecondaryProtonsNPointsTPCdEdx);
1797 TH1F *gSecondaryAntiProtonsNPointsTPCdEdx = new TH1F("gSecondaryAntiProtonsNPointsTPCdEdx",
1798 ";N_{points} (TPC-dE/dx);Entries",
1800 fAcceptedCutList->Add(gSecondaryAntiProtonsNPointsTPCdEdx);
1803 fRejectedCutList = new TList();
1805 TH3D *gHistEtaPhiNClustersPrimaryProtonsReject = new TH3D("gHistEtaPhiNClustersPrimaryProtonsReject",
1806 "Rejected primary protons;#eta;#phi;N_{clusters}(TPC)",
1807 fNBinsY,fMinY,fMaxY,
1810 gHistEtaPhiNClustersPrimaryProtonsReject->SetStats(kTRUE);
1811 gHistEtaPhiNClustersPrimaryProtonsReject->GetXaxis()->SetTitleColor(1);
1812 fRejectedCutList->Add(gHistEtaPhiNClustersPrimaryProtonsReject);//eta-phi of primary rejected ESD protons
1813 TH3D *gHistEtaPhiNClustersPrimaryAntiProtonsReject = new TH3D("gHistEtaPhiNClustersPrimaryAntiProtonsReject",
1814 "Rejected primary antiprotons;#eta;#phi;N_{clusters}(TPC)",
1815 fNBinsY,fMinY,fMaxY,
1818 gHistEtaPhiNClustersPrimaryAntiProtonsReject->SetStats(kTRUE);
1819 gHistEtaPhiNClustersPrimaryAntiProtonsReject->GetXaxis()->SetTitleColor(1);
1820 fRejectedCutList->Add(gHistEtaPhiNClustersPrimaryAntiProtonsReject);//eta-phi of primary rejected ESD antiprotons
1821 TH3D *gHistEtaPhiNClustersSecondaryProtonsReject = new TH3D("gHistEtaPhiNClustersSecondaryProtonsReject",
1822 "Rejected secondary protons;#eta;#phi;N_{clusters}(TPC)",
1823 fNBinsY,fMinY,fMaxY,
1826 gHistEtaPhiNClustersSecondaryProtonsReject->SetStats(kTRUE);
1827 gHistEtaPhiNClustersSecondaryProtonsReject->GetXaxis()->SetTitleColor(1);
1828 fRejectedCutList->Add(gHistEtaPhiNClustersSecondaryProtonsReject);//eta-phi of secondary rejected ESD protons
1829 TH3D *gHistEtaPhiNClustersSecondaryAntiProtonsReject = new TH3D("gHistEtaPhiNClustersSecondaryAntiProtonsReject",
1830 "Rejected secondary antiprotons;#eta;#phi;N_{clusters}(TPC)",
1831 fNBinsY,fMinY,fMaxY,
1834 gHistEtaPhiNClustersSecondaryAntiProtonsReject->SetStats(kTRUE);
1835 gHistEtaPhiNClustersSecondaryAntiProtonsReject->GetXaxis()->SetTitleColor(1);
1836 fRejectedCutList->Add(gHistEtaPhiNClustersSecondaryAntiProtonsReject);//eta-phi of secondary rejected ESD antiprotons
1837 //eta-phi-chi^2 per TPC cluster
1838 TH3D *gHistEtaPhiChi2PerTPCClusterPrimaryProtonsReject = new TH3D("gHistEtaPhiChi2PerTPCClusterPrimaryProtonsReject",
1839 "Rejected primary protons;#eta;#phi;#chi^{2}/N_{clusters}(TPC)",
1840 fNBinsY,fMinY,fMaxY,
1843 gHistEtaPhiChi2PerTPCClusterPrimaryProtonsReject->SetStats(kTRUE);
1844 gHistEtaPhiChi2PerTPCClusterPrimaryProtonsReject->GetXaxis()->SetTitleColor(1);
1845 fRejectedCutList->Add(gHistEtaPhiChi2PerTPCClusterPrimaryProtonsReject);//eta-phi of primary rejected ESD protons
1846 TH3D *gHistEtaPhiChi2PerTPCClusterPrimaryAntiProtonsReject = new TH3D("gHistEtaPhiChi2PerTPCClusterPrimaryAntiProtonsReject",
1847 "Rejected primary antiprotons;#eta;#phi;#chi^{2}/N_{clusters}(TPC)",
1848 fNBinsY,fMinY,fMaxY,
1851 gHistEtaPhiChi2PerTPCClusterPrimaryAntiProtonsReject->SetStats(kTRUE);
1852 gHistEtaPhiChi2PerTPCClusterPrimaryAntiProtonsReject->GetXaxis()->SetTitleColor(1);
1853 fRejectedCutList->Add(gHistEtaPhiChi2PerTPCClusterPrimaryAntiProtonsReject);//eta-phi of primary rejected ESD antiprotons
1854 TH3D *gHistEtaPhiChi2PerTPCClusterSecondaryProtonsReject = new TH3D("gHistEtaPhiChi2PerTPCClusterSecondaryProtonsReject",
1855 "Rejected secondary protons;#eta;#phi;#chi^{2}/N_{clusters}(TPC)",
1856 fNBinsY,fMinY,fMaxY,
1859 gHistEtaPhiChi2PerTPCClusterSecondaryProtonsReject->SetStats(kTRUE);
1860 gHistEtaPhiChi2PerTPCClusterSecondaryProtonsReject->GetXaxis()->SetTitleColor(1);
1861 fRejectedCutList->Add(gHistEtaPhiChi2PerTPCClusterSecondaryProtonsReject);//eta-phi of secondary rejected ESD protons
1862 TH3D *gHistEtaPhiChi2PerTPCClusterSecondaryAntiProtonsReject = new TH3D("gHistEtaPhiChi2PerTPCClusterSecondaryAntiProtonsReject",
1863 "Rejected secondary antiprotons;#eta;#phi;#chi^{2}/N_{clusters}(TPC)",
1864 fNBinsY,fMinY,fMaxY,
1867 gHistEtaPhiChi2PerTPCClusterSecondaryAntiProtonsReject->SetStats(kTRUE);
1868 gHistEtaPhiChi2PerTPCClusterSecondaryAntiProtonsReject->GetXaxis()->SetTitleColor(1);
1869 fRejectedCutList->Add(gHistEtaPhiChi2PerTPCClusterSecondaryAntiProtonsReject);//eta-phi of secondary rejected ESD antiprotons
1870 //eta-phi-number of TPC points for the dE/dx
1871 TH3D *gHistEtaPhiTPCdEdxNPointsPrimaryProtonsReject = new TH3D("gHistEtaPhiTPCdEdxNPointsPrimaryProtonsReject",
1872 "Rejected primary protons;#eta;#phi;N_{points}(TPC)",
1873 fNBinsY,fMinY,fMaxY,
1876 gHistEtaPhiTPCdEdxNPointsPrimaryProtonsReject->SetStats(kTRUE);
1877 gHistEtaPhiTPCdEdxNPointsPrimaryProtonsReject->GetXaxis()->SetTitleColor(1);
1878 fRejectedCutList->Add(gHistEtaPhiTPCdEdxNPointsPrimaryProtonsReject);//eta-phi of primary rejected ESD protons
1879 TH3D *gHistEtaPhiTPCdEdxNPointsPrimaryAntiProtonsReject = new TH3D("gHistEtaPhiTPCdEdxNPointsPrimaryAntiProtonsReject",
1880 "Rejected primary antiprotons;#eta;#phi;N_{points}(TPC)",
1881 fNBinsY,fMinY,fMaxY,
1884 gHistEtaPhiTPCdEdxNPointsPrimaryAntiProtonsReject->SetStats(kTRUE);
1885 gHistEtaPhiTPCdEdxNPointsPrimaryAntiProtonsReject->GetXaxis()->SetTitleColor(1);
1886 fRejectedCutList->Add(gHistEtaPhiTPCdEdxNPointsPrimaryAntiProtonsReject);//eta-phi of primary rejected ESD antiprotons
1887 TH3D *gHistEtaPhiTPCdEdxNPointsSecondaryProtonsReject = new TH3D("gHistEtaPhiTPCdEdxNPointsSecondaryProtonsReject",
1888 "Rejected secondary protons;#eta;#phi;N_{points}(TPC)",
1889 fNBinsY,fMinY,fMaxY,
1892 gHistEtaPhiTPCdEdxNPointsSecondaryProtonsReject->SetStats(kTRUE);
1893 gHistEtaPhiTPCdEdxNPointsSecondaryProtonsReject->GetXaxis()->SetTitleColor(1);
1894 fRejectedCutList->Add(gHistEtaPhiTPCdEdxNPointsSecondaryProtonsReject);//eta-phi of secondary rejected ESD protons
1895 TH3D *gHistEtaPhiTPCdEdxNPointsSecondaryAntiProtonsReject = new TH3D("gHistEtaPhiTPCdEdxNPointsSecondaryAntiProtonsReject",
1896 "Rejected secondary antiprotons;#eta;#phi;N_{points}(TPC)",
1897 fNBinsY,fMinY,fMaxY,
1900 gHistEtaPhiTPCdEdxNPointsSecondaryAntiProtonsReject->SetStats(kTRUE);
1901 gHistEtaPhiTPCdEdxNPointsSecondaryAntiProtonsReject->GetXaxis()->SetTitleColor(1);
1902 fRejectedCutList->Add(gHistEtaPhiTPCdEdxNPointsSecondaryAntiProtonsReject);//eta-phi of secondary rejected ESD antiprotons
1905 fAcceptedDCAList = new TList();
1906 TH1F *gPrimaryProtonsDCAXY = new TH1F("gPrimaryProtonsDCAXY",
1907 ";DCA_{xy} [cm];Entries",
1909 fAcceptedDCAList->Add(gPrimaryProtonsDCAXY);
1910 TH1F *gPrimaryAntiProtonsDCAXY = new TH1F("gPrimaryAntiProtonsDCAXY",
1911 ";DCA_{xy} [cm];Entries",
1913 fAcceptedDCAList->Add(gPrimaryAntiProtonsDCAXY);
1914 TH1F *gSecondaryProtonsDCAXY = new TH1F("gSecondaryProtonsDCAXY",
1915 ";DCA_{xy} [cm];Entries",
1917 fAcceptedDCAList->Add(gSecondaryProtonsDCAXY);
1918 TH1F *gSecondaryAntiProtonsDCAXY = new TH1F("gSecondaryAntiProtonsDCAXY",
1919 ";DCA_{xy} [cm];Entries",
1922 fAcceptedDCAList->Add(gSecondaryAntiProtonsDCAXY);
1923 TH1F *gPrimaryProtonsDCAZ = new TH1F("gPrimaryProtonsDCAZ",
1924 ";DCA_{z} [cm];Entries",
1926 fAcceptedDCAList->Add(gPrimaryProtonsDCAZ);
1927 TH1F *gPrimaryAntiProtonsDCAZ = new TH1F("gPrimaryAntiProtonsDCAZ",
1928 ";DCA_{z} [cm];Entries",
1930 fAcceptedDCAList->Add(gPrimaryAntiProtonsDCAZ);
1931 TH1F *gSecondaryProtonsDCAZ = new TH1F("gSecondaryProtonsDCAZ",
1932 ";DCA_{z} [cm];Entries",
1934 fAcceptedDCAList->Add(gSecondaryProtonsDCAZ);
1935 TH1F *gSecondaryAntiProtonsDCAZ = new TH1F("gSecondaryAntiProtonsDCAZ",
1936 ";DCA_{z} [cm];Entries",
1938 fAcceptedDCAList->Add(gSecondaryAntiProtonsDCAZ);
1940 TH1F *gPrimaryProtonsSigmaToVertex = new TH1F("gPrimaryProtonsSigmaToVertex",
1941 ";#sigma_{Vertex};Entries",
1943 fAcceptedDCAList->Add(gPrimaryProtonsSigmaToVertex);
1944 TH1F *gPrimaryAntiProtonsSigmaToVertex = new TH1F("gPrimaryAntiProtonsSigmaToVertex",
1945 ";#sigma_{Vertex};Entries",
1947 fAcceptedDCAList->Add(gPrimaryAntiProtonsSigmaToVertex);
1948 TH1F *gSecondaryProtonsSigmaToVertex = new TH1F("gSecondaryProtonsSigmaToVertex",
1949 ";#sigma_{Vertex};Entries",
1951 fAcceptedDCAList->Add(gSecondaryProtonsSigmaToVertex);
1952 TH1F *gSecondaryAntiProtonsSigmaToVertex = new TH1F("gSecondaryAntiProtonsSigmaToVertex",
1953 ";#sigma_{Vertex};Entries",
1955 fAcceptedDCAList->Add(gSecondaryAntiProtonsSigmaToVertex);
1957 //3D DCA vs pT plots
1958 TH3F *gHistPrimaryProtonsDCAxyEtaPt = new TH3F("gHistPrimaryProtonsDCAxyEtaPt",
1959 ";#eta;P_{T} [GeV/c];dca_{xy} [cm]",
1963 gHistPrimaryProtonsDCAxyEtaPt->SetStats(kFALSE);
1964 fAcceptedDCAList->Add(gHistPrimaryProtonsDCAxyEtaPt);
1965 TH3F *gHistPrimaryAntiProtonsDCAxyEtaPt = new TH3F("gHistPrimaryAntiProtonsDCAxyEtaPt",
1966 ";#eta;P_{T} [GeV/c];dca_{xy} [cm]",
1970 gHistPrimaryAntiProtonsDCAxyEtaPt->SetStats(kFALSE);
1971 fAcceptedDCAList->Add(gHistPrimaryAntiProtonsDCAxyEtaPt);
1972 TH3F *gHistSecondaryProtonsFromWeakDCAxyEtaPt = new TH3F("gHistSecondaryProtonsFromWeakDCAxyEtaPt",
1973 ";#eta;P_{T} [GeV/c];dca_{xy} [cm]",
1977 gHistSecondaryProtonsFromWeakDCAxyEtaPt->SetStats(kFALSE);
1978 fAcceptedDCAList->Add(gHistSecondaryProtonsFromWeakDCAxyEtaPt);
1979 TH3F *gHistSecondaryAntiProtonsFromWeakDCAxyEtaPt = new TH3F("gHistSecondaryAntiProtonsFromWeakDCAxyEtaPt",
1980 ";#eta;P_{T} [GeV/c];dca_{xy} [cm]",
1984 gHistSecondaryAntiProtonsFromWeakDCAxyEtaPt->SetStats(kFALSE);
1985 fAcceptedDCAList->Add(gHistSecondaryAntiProtonsFromWeakDCAxyEtaPt);
1986 TH3F *gHistSecondaryProtonsFromHadronicDCAxyEtaPt = new TH3F("gHistSecondaryProtonsFromHadronicDCAxyEtaPt",
1987 ";#eta;P_{T} [GeV/c];dca_{xy} [cm]",
1991 gHistSecondaryProtonsFromHadronicDCAxyEtaPt->SetStats(kFALSE);
1992 fAcceptedDCAList->Add(gHistSecondaryProtonsFromHadronicDCAxyEtaPt);
1993 TH3F *gHistSecondaryAntiProtonsFromHadronicDCAxyEtaPt = new TH3F("gHistSecondaryAntiProtonsFromHadronicDCAxyEtaPt",
1994 ";#eta;P_{T} [GeV/c];dca_{xy} [cm]",
1998 gHistSecondaryAntiProtonsFromHadronicDCAxyEtaPt->SetStats(kFALSE);
1999 fAcceptedDCAList->Add(gHistSecondaryAntiProtonsFromHadronicDCAxyEtaPt);
2001 TH3F *gHistPrimaryProtonsDCAzEtaPt = new TH3F("gHistPrimaryProtonsDCAzEtaPt",
2002 ";#eta;P_{T} [GeV/c];dca_{z} [cm]",
2006 gHistPrimaryProtonsDCAzEtaPt->SetStats(kFALSE);
2007 fAcceptedDCAList->Add(gHistPrimaryProtonsDCAzEtaPt);
2008 TH3F *gHistPrimaryAntiProtonsDCAzEtaPt = new TH3F("gHistPrimaryAntiProtonsDCAzEtaPt",
2009 ";#eta;P_{T} [GeV/c];dca_{z} [cm]",
2013 gHistPrimaryAntiProtonsDCAzEtaPt->SetStats(kFALSE);
2014 fAcceptedDCAList->Add(gHistPrimaryAntiProtonsDCAzEtaPt);
2015 TH3F *gHistSecondaryProtonsFromWeakDCAzEtaPt = new TH3F("gHistSecondaryProtonsFromWeakDCAzEtaPt",
2016 ";#eta;P_{T} [GeV/c];dca_{z} [cm]",
2020 gHistSecondaryProtonsFromWeakDCAzEtaPt->SetStats(kFALSE);
2021 fAcceptedDCAList->Add(gHistSecondaryProtonsFromWeakDCAzEtaPt);
2022 TH3F *gHistSecondaryAntiProtonsFromWeakDCAzEtaPt = new TH3F("gHistSecondaryAntiProtonsFromWeakDCAzEtaPt",
2023 ";#eta;P_{T} [GeV/c];dca_{z} [cm]",
2027 gHistSecondaryAntiProtonsFromWeakDCAzEtaPt->SetStats(kFALSE);
2028 fAcceptedDCAList->Add(gHistSecondaryAntiProtonsFromWeakDCAzEtaPt);
2029 TH3F *gHistSecondaryProtonsFromHadronicDCAzEtaPt = new TH3F("gHistSecondaryProtonsFromHadronicDCAzEtaPt",
2030 ";#eta;P_{T} [GeV/c];dca_{z} [cm]",
2034 gHistSecondaryProtonsFromHadronicDCAzEtaPt->SetStats(kFALSE);
2035 fAcceptedDCAList->Add(gHistSecondaryProtonsFromHadronicDCAzEtaPt);
2036 TH3F *gHistSecondaryAntiProtonsFromHadronicDCAzEtaPt = new TH3F("gHistSecondaryAntiProtonsFromHadronicDCAzEtaPt",
2037 ";#eta;P_{T} [GeV/c];dca_{z} [cm]",
2041 gHistSecondaryAntiProtonsFromHadronicDCAzEtaPt->SetStats(kFALSE);
2042 fAcceptedDCAList->Add(gHistSecondaryAntiProtonsFromHadronicDCAzEtaPt);
2045 //____________________________________________________________________//
2046 void AliProtonQAAnalysis::InitVertexQA() {
2047 //Initializes the Vertex QA histograms
2048 fQAVertexList = new TList();
2049 fQAVertexList->SetName("fQAVertexList");
2051 //Gen. multiplicity bins
2052 //Float_t xBins[24] = {0,1,2,4,6,8,10,15,20,30,40,50,75,100,
2053 //200,300,400,500,750,1000,1500,2000,2500,3000};
2054 //MC primary multiplicity (vertex efficiency calculation)
2055 TH1F *gHistMCPrimaryVz = new TH1F("gHistMCPrimaryVz",
2056 ";V_{z} (gen.) [cm];Entries",
2058 fQAVertexList->Add(gHistMCPrimaryVz);
2059 //TH1F *gHistMCPrimaryMultiplicity = new TH1F("gHistMCPrimaryMultiplicity",
2060 //";N_{prim. gen.};Entries",
2062 //fQAVertexList->Add(gHistMCPrimaryMultiplicity);
2065 TH1F *gHistTPCVz = new TH1F("gHistTPCVz",
2066 ";V_{z} (gen.) [cm];Entries",
2068 fQAVertexList->Add(gHistTPCVz);
2069 //TH1F *gHistMCPrimaryMultiplicityTPC = new TH1F("gHistMCPrimaryMultiplicityTPC",
2070 //"Vertex TPC;N_{prim. gen.};Entries",
2072 //fQAVertexList->Add(gHistMCPrimaryMultiplicityTPC);
2073 TH2F *gHistTPCESDVxN = new TH2F("gHistTPCESDVxN",
2074 "Primary vertex TPC;V_{x} [cm];N_{contributors}",
2075 100,-10.,10.,1000,0,5000);
2076 fQAVertexList->Add(gHistTPCESDVxN);
2077 TH2F *gHistTPCESDVyN = new TH2F("gHistTPCESDVyN",
2078 "Primary vertex TPC;V_{y} [cm];N_{contributors}",
2079 100,-10.,10.,1000,0,5000);
2080 fQAVertexList->Add(gHistTPCESDVyN);
2081 TH2F *gHistTPCESDVzN = new TH2F("gHistTPCESDVzN",
2082 "Primary vertex TPC;V_{z} [cm];N_{contributors}",
2083 100,-20.,20.,1000,0,5000);
2084 fQAVertexList->Add(gHistTPCESDVzN);
2085 TH1F *gHistTPCDiffVx = new TH1F("gHistTPCDiffVx",
2086 ";V_{x}(rec.) - V_{x}(true) [#mu m];Entries",
2087 100,-10000.,10000.);
2088 fQAVertexList->Add(gHistTPCDiffVx);
2089 TH1F *gHistTPCDiffVy = new TH1F("gHistTPCDiffVy",
2090 ";V_{y}(rec.) - V_{y}(true) [#mu m];Entries",
2091 100,-10000.,10000.);
2092 fQAVertexList->Add(gHistTPCDiffVy);
2093 TH1F *gHistTPCDiffVz = new TH1F("gHistTPCDiffVz",
2094 ";V_{z}(rec.) - V_{z}(true) [#mu m];Entries",
2095 100,-10000.,10000.);
2096 fQAVertexList->Add(gHistTPCDiffVz);
2097 TH1F *gHistTPCResolutionVx = new TH1F("gHistTPCResolutionVx",
2098 ";#sigma_{x} [#mu m];Entries",
2100 fQAVertexList->Add(gHistTPCResolutionVx);
2101 TH1F *gHistTPCResolutionVy = new TH1F("gHistTPCResolutionVy",
2102 ";#sigma_{y} [#mu m];Entries",
2104 fQAVertexList->Add(gHistTPCResolutionVy);
2105 TH1F *gHistTPCResolutionVz = new TH1F("gHistTPCResolutionVz",
2106 ";#sigma_{z} [#mu m];Entries",
2108 fQAVertexList->Add(gHistTPCResolutionVz);
2111 TH1F *gHistSPDVz = new TH1F("gHistSPDVz",
2112 ";V_{z} (gen.) [cm];Entries",
2114 fQAVertexList->Add(gHistSPDVz);
2115 //TH1F *gHistMCPrimaryMultiplicitySPD = new TH1F("gHistMCPrimaryMultiplicitySPD",
2116 //"Vertex SPD;N_{prim. gen.};Entries",
2118 //fQAVertexList->Add(gHistMCPrimaryMultiplicitySPD);
2119 TH2F *gHistSPDESDVxN = new TH2F("gHistSPDESDVxN",
2120 "Primary vertex SPD;V_{x} [cm];N_{contributors}",
2121 100,-10.,10.,1000,0,5000);
2122 fQAVertexList->Add(gHistSPDESDVxN);
2123 TH2F *gHistSPDESDVyN = new TH2F("gHistSPDESDVyN",
2124 "Primary vertex SPD;V_{y} [cm];N_{contributors}",
2125 100,-10.,10.,1000,0,5000);
2126 fQAVertexList->Add(gHistSPDESDVyN);
2127 TH2F *gHistSPDESDVzN = new TH2F("gHistSPDESDVzN",
2128 "Primary vertex SPD;V_{z} [cm];N_{contributors}",
2129 100,-20.,20.,1000,0,5000);
2130 fQAVertexList->Add(gHistSPDESDVzN);
2131 TH1F *gHistSPDDiffVx = new TH1F("gHistSPDDiffVx",
2132 ";V_{x}(rec.) - V_{x}(true) [#mu m];Entries",
2133 100,-10000.,10000.);
2134 fQAVertexList->Add(gHistSPDDiffVx);
2135 TH1F *gHistSPDDiffVy = new TH1F("gHistSPDDiffVy",
2136 ";V_{y}(rec.) - V_{y}(true) [#mu m];Entries",
2137 100,-10000.,10000.);
2138 fQAVertexList->Add(gHistSPDDiffVy);
2139 TH1F *gHistSPDDiffVz = new TH1F("gHistSPDDiffVz",
2140 ";V_{z}(rec.) - V_{z}(true) [#mu m];Entries",
2141 100,-10000.,10000.);
2142 fQAVertexList->Add(gHistSPDDiffVz);
2143 TH1F *gHistSPDResolutionVx = new TH1F("gHistSPDResolutionVx",
2144 ";#sigma_{x} [#mu m];Entries",
2146 fQAVertexList->Add(gHistSPDResolutionVx);
2147 TH1F *gHistSPDResolutionVy = new TH1F("gHistSPDResolutionVy",
2148 ";#sigma_{y} [#mu m];Entries",
2150 fQAVertexList->Add(gHistSPDResolutionVy);
2151 TH1F *gHistSPDResolutionVz = new TH1F("gHistSPDResolutionVz",
2152 ";#sigma_{z} [#mu m];Entries",
2154 fQAVertexList->Add(gHistSPDResolutionVz);
2157 TH1F *gHistTracksVz = new TH1F("gHistTracksVz",
2158 ";V_{z} (gen.) [cm];Entries",
2160 fQAVertexList->Add(gHistTracksVz);
2161 //TH1F *gHistMCPrimaryMultiplicityTracks = new TH1F("gHistMCPrimaryMultiplicityTracks",
2162 //"Vertex Tracks;N_{prim. gen.};Entries",
2164 //fQAVertexList->Add(gHistMCPrimaryMultiplicityTracks);
2165 TH2F *gHistTracksESDVxN = new TH2F("gHistTracksESDVxN",
2166 "Primary vertex Tracks;V_{x} [cm];N_{contributors}",
2167 100,-10.,10.,1000,0,5000);
2168 fQAVertexList->Add(gHistTracksESDVxN);
2169 TH2F *gHistTracksESDVyN = new TH2F("gHistTracksESDVyN",
2170 "Primary vertex Tracks;V_{y} [cm];N_{contributors}",
2171 100,-10.,10.,1000,0,5000);
2172 fQAVertexList->Add(gHistTracksESDVyN);
2173 TH2F *gHistTracksESDVzN = new TH2F("gHistTracksESDVzN",
2174 "Primary vertex Tracks;V_{z} [cm];N_{contributors}",
2175 100,-20.,20.,1000,0,5000);
2176 fQAVertexList->Add(gHistTracksESDVzN);
2177 TH1F *gHistTracksDiffVx = new TH1F("gHistTracksDiffVx",
2178 ";V_{x}(rec.) - V_{x}(true) [#mu m];Entries",
2179 100,-10000.,10000.);
2180 fQAVertexList->Add(gHistTracksDiffVx);
2181 TH1F *gHistTracksDiffVy = new TH1F("gHistTracksDiffVy",
2182 ";V_{y}(rec.) - V_{y}(true) [#mu m];Entries",
2183 100,-10000.,10000.);
2184 fQAVertexList->Add(gHistTracksDiffVy);
2185 TH1F *gHistTracksDiffVz = new TH1F("gHistTracksDiffVz",
2186 ";V_{z}(rec.) - V_{z}(true) [#mu m];Entries",
2187 100,-10000.,10000.);
2188 fQAVertexList->Add(gHistTracksDiffVz);
2189 TH1F *gHistTracksResolutionVx = new TH1F("gHistTracksResolutionVx",
2190 ";#sigma_{x} [#mu m];Entries",
2192 fQAVertexList->Add(gHistTracksResolutionVx);
2193 TH1F *gHistTracksResolutionVy = new TH1F("gHistTracksResolutionVy",
2194 ";#sigma_{y} [#mu m];Entries",
2196 fQAVertexList->Add(gHistTracksResolutionVy);
2197 TH1F *gHistTracksResolutionVz = new TH1F("gHistTracksResolutionVz",
2198 ";#sigma_{z} [#mu m];Entries",
2200 fQAVertexList->Add(gHistTracksResolutionVz);
2203 //____________________________________________________________________//
2204 void AliProtonQAAnalysis::InitQA() {
2205 //Initializes the QA histograms
2206 //if(!fQAHistograms)
2210 //TDirectory *dir2D = gDirectory->mkdir("2D");
2211 //fGlobalQAList->Add(dir2D); dir2D->cd();
2212 TH2D *gHistYPtPrimaryProtonsPass = 0x0;
2213 if(fUseAsymmetricBinning)
2214 gHistYPtPrimaryProtonsPass = new TH2D("gHistYPtPrimaryProtonsPass",
2216 fNBinsY,fY,fNBinsPt,fPt);
2218 gHistYPtPrimaryProtonsPass = new TH2D("gHistYPtPrimaryProtonsPass",
2220 fNBinsY,fMinY,fMaxY,
2221 fNBinsPt,fMinPt,fMaxPt);
2222 if(fProtonAnalysisBase->GetEtaMode())
2223 gHistYPtPrimaryProtonsPass->GetXaxis()->SetTitle("#eta");
2225 gHistYPtPrimaryProtonsPass->GetXaxis()->SetTitle("y");
2226 gHistYPtPrimaryProtonsPass->SetStats(kTRUE);
2227 gHistYPtPrimaryProtonsPass->GetXaxis()->SetTitleColor(1);
2228 fQA2DList->Add(gHistYPtPrimaryProtonsPass);//y-pT of primary accepted ESD protons
2229 TH2D *gHistYPtPrimaryProtonsReject = 0x0;
2230 if(fUseAsymmetricBinning)
2231 gHistYPtPrimaryProtonsReject = new TH2D("gHistYPtPrimaryProtonsReject",
2233 fNBinsY,fY,fNBinsPt,fPt);
2235 gHistYPtPrimaryProtonsReject = new TH2D("gHistYPtPrimaryProtonsReject",
2237 fNBinsY,fMinY,fMaxY,
2238 fNBinsPt,fMinPt,fMaxPt);
2239 if(fProtonAnalysisBase->GetEtaMode())
2240 gHistYPtPrimaryProtonsReject->GetXaxis()->SetTitle("#eta");
2242 gHistYPtPrimaryProtonsReject->GetXaxis()->SetTitle("y");
2243 gHistYPtPrimaryProtonsReject->SetStats(kTRUE);
2244 gHistYPtPrimaryProtonsReject->GetXaxis()->SetTitleColor(1);
2245 fQA2DList->Add(gHistYPtPrimaryProtonsReject);//y-pT of primary rejected ESD protons
2247 TH2D *gHistYPtSecondaryProtonsPass = 0x0;
2248 if(fUseAsymmetricBinning)
2249 gHistYPtSecondaryProtonsPass = new TH2D("gHistYPtSecondaryProtonsPass",
2251 fNBinsY,fY,fNBinsPt,fPt);
2253 gHistYPtSecondaryProtonsPass = new TH2D("gHistYPtSecondaryProtonsPass",
2255 fNBinsY,fMinY,fMaxY,
2256 fNBinsPt,fMinPt,fMaxPt);
2257 if(fProtonAnalysisBase->GetEtaMode())
2258 gHistYPtSecondaryProtonsPass->GetXaxis()->SetTitle("#eta");
2260 gHistYPtSecondaryProtonsPass->GetXaxis()->SetTitle("y");
2261 gHistYPtSecondaryProtonsPass->SetStats(kTRUE);
2262 gHistYPtSecondaryProtonsPass->GetXaxis()->SetTitleColor(1);
2263 fQA2DList->Add(gHistYPtSecondaryProtonsPass);//y-pT of secondary accepted ESD protons
2264 TH2D *gHistYPtSecondaryProtonsReject = 0x0;
2265 if(fUseAsymmetricBinning)
2266 gHistYPtSecondaryProtonsReject = new TH2D("gHistYPtSecondaryProtonsReject",
2268 fNBinsY,fY,fNBinsPt,fPt);
2270 gHistYPtSecondaryProtonsReject = new TH2D("gHistYPtSecondaryProtonsReject",
2272 fNBinsY,fMinY,fMaxY,
2273 fNBinsPt,fMinPt,fMaxPt);
2274 if(fProtonAnalysisBase->GetEtaMode())
2275 gHistYPtSecondaryProtonsReject->GetXaxis()->SetTitle("#eta");
2277 gHistYPtSecondaryProtonsReject->GetXaxis()->SetTitle("y");
2278 gHistYPtSecondaryProtonsReject->SetStats(kTRUE);
2279 gHistYPtSecondaryProtonsReject->GetXaxis()->SetTitleColor(1);
2280 fQA2DList->Add(gHistYPtSecondaryProtonsReject);//y-pT of secondary rejected ESD protons
2282 TH2D *gHistYPtPrimaryAntiProtonsPass = 0x0;
2283 if(fUseAsymmetricBinning)
2284 gHistYPtPrimaryAntiProtonsPass = new TH2D("gHistYPtPrimaryAntiProtonsPass",
2286 fNBinsY,fY,fNBinsPt,fPt);
2288 gHistYPtPrimaryAntiProtonsPass = new TH2D("gHistYPtPrimaryAntiProtonsPass",
2290 fNBinsY,fMinY,fMaxY,
2291 fNBinsPt,fMinPt,fMaxPt);
2292 if(fProtonAnalysisBase->GetEtaMode())
2293 gHistYPtPrimaryAntiProtonsPass->GetXaxis()->SetTitle("#eta");
2295 gHistYPtPrimaryAntiProtonsPass->GetXaxis()->SetTitle("y");
2296 gHistYPtPrimaryAntiProtonsPass->SetStats(kTRUE);
2297 gHistYPtPrimaryAntiProtonsPass->GetXaxis()->SetTitleColor(1);
2298 fQA2DList->Add(gHistYPtPrimaryAntiProtonsPass);//y-pT of primary accepted ESD antiprotons
2299 TH2D *gHistYPtPrimaryAntiProtonsReject = 0x0;
2300 if(fUseAsymmetricBinning)
2301 gHistYPtPrimaryAntiProtonsReject = new TH2D("gHistYPtPrimaryAntiProtonsReject",
2303 fNBinsY,fY,fNBinsPt,fPt);
2305 gHistYPtPrimaryAntiProtonsReject = new TH2D("gHistYPtPrimaryAntiProtonsReject",
2307 fNBinsY,fMinY,fMaxY,
2308 fNBinsPt,fMinPt,fMaxPt);
2309 if(fProtonAnalysisBase->GetEtaMode())
2310 gHistYPtPrimaryAntiProtonsReject->GetXaxis()->SetTitle("#eta");
2312 gHistYPtPrimaryAntiProtonsReject->GetXaxis()->SetTitle("y");
2313 gHistYPtPrimaryAntiProtonsReject->SetStats(kTRUE);
2314 gHistYPtPrimaryAntiProtonsReject->GetXaxis()->SetTitleColor(1);
2315 fQA2DList->Add(gHistYPtPrimaryAntiProtonsReject);//y-pT of primary rejected ESD antiprotons
2317 TH2D *gHistYPtSecondaryAntiProtonsPass = 0x0;
2318 if(fUseAsymmetricBinning)
2319 gHistYPtSecondaryAntiProtonsPass = new TH2D("gHistYPtSecondaryAntiProtonsPass",
2321 fNBinsY,fY,fNBinsPt,fPt);
2323 gHistYPtSecondaryAntiProtonsPass = new TH2D("gHistYPtSecondaryAntiProtonsPass",
2325 fNBinsY,fMinY,fMaxY,
2326 fNBinsPt,fMinPt,fMaxPt);
2327 if(fProtonAnalysisBase->GetEtaMode())
2328 gHistYPtSecondaryAntiProtonsPass->GetXaxis()->SetTitle("#eta");
2330 gHistYPtSecondaryAntiProtonsPass->GetXaxis()->SetTitle("y");
2331 gHistYPtSecondaryAntiProtonsPass->SetStats(kTRUE);
2332 gHistYPtSecondaryAntiProtonsPass->GetXaxis()->SetTitleColor(1);
2333 fQA2DList->Add(gHistYPtSecondaryAntiProtonsPass);//y-pT of secondary accepted ESD antiprotons
2334 TH2D *gHistYPtSecondaryAntiProtonsReject = 0x0;
2335 if(fUseAsymmetricBinning)
2336 gHistYPtSecondaryAntiProtonsReject = new TH2D("gHistYPtSecondaryAntiProtonsReject",
2338 fNBinsY,fY,fNBinsPt,fPt);
2340 gHistYPtSecondaryAntiProtonsReject = new TH2D("gHistYPtSecondaryAntiProtonsReject",
2342 fNBinsY,fMinY,fMaxY,
2343 fNBinsPt,fMinPt,fMaxPt);
2344 if(fProtonAnalysisBase->GetEtaMode())
2345 gHistYPtSecondaryAntiProtonsReject->GetXaxis()->SetTitle("#eta");
2347 gHistYPtSecondaryAntiProtonsReject->GetXaxis()->SetTitle("y");
2348 gHistYPtSecondaryAntiProtonsReject->SetStats(kTRUE);
2349 gHistYPtSecondaryAntiProtonsReject->GetXaxis()->SetTitleColor(1);
2350 fQA2DList->Add(gHistYPtSecondaryAntiProtonsReject);//y-pT of secondary rejected ESD antiprotons
2352 TH2D *gHistYPtPrimaryProtonsMC = 0x0;
2353 if(fUseAsymmetricBinning)
2354 gHistYPtPrimaryProtonsMC = new TH2D("gHistYPtPrimaryProtonsMC",
2356 fNBinsY,fY,fNBinsPt,fPt);
2358 gHistYPtPrimaryProtonsMC = new TH2D("gHistYPtPrimaryProtonsMC",
2360 fNBinsY,fMinY,fMaxY,
2361 fNBinsPt,fMinPt,fMaxPt);
2362 if(fProtonAnalysisBase->GetEtaMode())
2363 gHistYPtPrimaryProtonsMC->GetXaxis()->SetTitle("#eta");
2365 gHistYPtPrimaryProtonsMC->GetXaxis()->SetTitle("y");
2366 gHistYPtPrimaryProtonsMC->SetStats(kTRUE);
2367 gHistYPtPrimaryProtonsMC->GetXaxis()->SetTitleColor(1);
2368 fQA2DList->Add(gHistYPtPrimaryProtonsMC);//y-pT of primary MC protons
2369 TH2D *gHistYPtPrimaryAntiProtonsMC = 0x0;
2370 if(fUseAsymmetricBinning)
2371 gHistYPtPrimaryAntiProtonsMC = new TH2D("gHistYPtPrimaryAntiProtonsMC",
2373 fNBinsY,fY,fNBinsPt,fPt);
2375 gHistYPtPrimaryAntiProtonsMC = new TH2D("gHistYPtPrimaryAntiProtonsMC",
2377 fNBinsY,fMinY,fMaxY,
2378 fNBinsPt,fMinPt,fMaxPt);
2379 if(fProtonAnalysisBase->GetEtaMode())
2380 gHistYPtPrimaryAntiProtonsMC->GetXaxis()->SetTitle("#eta");
2382 gHistYPtPrimaryAntiProtonsMC->GetXaxis()->SetTitle("y");
2383 gHistYPtPrimaryAntiProtonsMC->SetStats(kTRUE);
2384 gHistYPtPrimaryAntiProtonsMC->GetXaxis()->SetTitleColor(1);
2385 fQA2DList->Add(gHistYPtPrimaryAntiProtonsMC);//y-pT of primary MC antiprotons
2387 TH3F *gHistYPtPDGProtonsPass = 0x0;
2388 if(fUseAsymmetricBinning) {
2389 Double_t gPDG[15] = {-0.5,0.5,1.5,2.5,3.5,4.5,5.5,6.5,7.5,8.5,9.5,10.5,11.5,12.5,13.5};
2390 gHistYPtPDGProtonsPass = new TH3F("gHistYPtPDGProtonsPass",
2391 ";;P_{T} [GeV/c];PDG",
2392 fNBinsY,fY,fNBinsPt,fPt,14,gPDG);
2395 gHistYPtPDGProtonsPass = new TH3F("gHistYPtPDGProtonsPass",
2396 ";;P_{T} [GeV/c];PDG",
2397 fNBinsY,fMinY,fMaxY,
2398 fNBinsPt,fMinPt,fMaxPt,
2400 if(fProtonAnalysisBase->GetEtaMode())
2401 gHistYPtPDGProtonsPass->GetXaxis()->SetTitle("#eta");
2403 gHistYPtPDGProtonsPass->GetXaxis()->SetTitle("y");
2404 fQA2DList->Add(gHistYPtPDGProtonsPass);//composition of secondary protons
2405 TH3F *gHistYPtPDGAntiProtonsPass = 0x0;
2406 if(fUseAsymmetricBinning) {
2407 Double_t gPDG[15] = {-0.5,0.5,1.5,2.5,3.5,4.5,5.5,6.5,7.5,8.5,9.5,10.5,11.5,12.5,13.5};
2408 gHistYPtPDGAntiProtonsPass = new TH3F("gHistYPtPDGAntiProtonsPass",
2409 ";;P_{T} [GeV/c];PDG",
2410 fNBinsY,fY,fNBinsPt,fPt,14,gPDG);
2413 gHistYPtPDGAntiProtonsPass = new TH3F("gHistYPtPDGAntiProtonsPass",
2414 ";;P_{T} [GeV/c];PDG",
2415 fNBinsY,fMinY,fMaxY,
2416 fNBinsPt,fMinPt,fMaxPt,
2418 if(fProtonAnalysisBase->GetEtaMode())
2419 gHistYPtPDGAntiProtonsPass->GetXaxis()->SetTitle("#eta");
2421 gHistYPtPDGAntiProtonsPass->GetXaxis()->SetTitle("y");
2422 fQA2DList->Add(gHistYPtPDGAntiProtonsPass);//composition of secondary antiprotons
2424 /*gDirectory->cd("../");
2426 TDirectory *dirProtons = gDirectory->mkdir("Protons");
2427 fGlobalQAList->Add(dirProtons); dirProtons->cd();*/
2429 //________________________________________________________________//
2430 /*TDirectory *dirProtonsPrimary = gDirectory->mkdir("Primaries");
2431 dirProtonsPrimary->cd();
2432 TDirectory *dirProtonsPrimaryAccepted = gDirectory->mkdir("Accepted");
2433 dirProtonsPrimaryAccepted->cd();*/
2435 //Accepted primary protons
2436 TH1F *gPrimaryProtonsITSClustersPass = new TH1F("gPrimaryProtonsITSClustersPass",
2437 ";N_{clusters} (ITS);Entries",
2439 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsITSClustersPass);
2440 TH1F *gPrimaryProtonsChi2PerClusterITSPass = new TH1F("gPrimaryProtonsChi2PerClusterITSPass",
2441 ";x^{2}/N_{clusters} (ITS);Entries",
2443 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsChi2PerClusterITSPass);
2444 TH1F *gPrimaryProtonsTPCClustersPass = new TH1F("gPrimaryProtonsTPCClustersPass",
2445 ";N_{clusters} (TPC);Entries",
2447 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsTPCClustersPass);
2448 TH1F *gPrimaryProtonsChi2PerClusterTPCPass = new TH1F("gPrimaryProtonsChi2PerClusterTPCPass",
2449 ";x^{2}/N_{clusters} (TPC);Entries",
2451 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsChi2PerClusterTPCPass);
2452 TH1F *gPrimaryProtonsExtCov11Pass = new TH1F("gPrimaryProtonsExtCov11Pass",
2453 ";#sigma_{y} [cm];Entries",
2455 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsExtCov11Pass);
2456 TH1F *gPrimaryProtonsExtCov22Pass = new TH1F("gPrimaryProtonsExtCov22Pass",
2457 ";#sigma_{z} [cm];Entries",
2459 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsExtCov22Pass);
2460 TH1F *gPrimaryProtonsExtCov33Pass = new TH1F("gPrimaryProtonsExtCov33Pass",
2461 ";#sigma_{sin(#phi)};Entries",
2463 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsExtCov33Pass);
2464 TH1F *gPrimaryProtonsExtCov44Pass = new TH1F("gPrimaryProtonsExtCov44Pass",
2465 ";#sigma_{tan(#lambda)};Entries",
2467 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsExtCov44Pass);
2468 TH1F *gPrimaryProtonsExtCov55Pass = new TH1F("gPrimaryProtonsExtCov55Pass",
2469 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
2471 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsExtCov55Pass);
2472 TH1F *gPrimaryProtonsSigmaToVertexPass = new TH1F("gPrimaryProtonsSigmaToVertexPass",
2473 ";#sigma_{Vertex};Entries",
2475 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsSigmaToVertexPass);
2476 TH1F *gPrimaryProtonsSigmaToVertexTPCPass = new TH1F("gPrimaryProtonsSigmaToVertexTPCPass",
2477 ";#sigma_{Vertex};Entries",
2479 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsSigmaToVertexTPCPass);
2480 TH1F *gPrimaryProtonsDCAXYPass = new TH1F("gPrimaryProtonsDCAXYPass",
2481 ";DCA_{xy} [cm];Entries",
2483 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsDCAXYPass);
2484 TH1F *gPrimaryProtonsDCAXYTPCPass = new TH1F("gPrimaryProtonsDCAXYTPCPass",
2485 ";DCA_{xy} [cm];Entries",
2487 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsDCAXYTPCPass);
2488 TH1F *gPrimaryProtonsDCAZPass = new TH1F("gPrimaryProtonsDCAZPass",
2489 ";DCA_{z} [cm];Entries",
2491 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsDCAZPass);
2492 TH1F *gPrimaryProtonsDCAZTPCPass = new TH1F("gPrimaryProtonsDCAZTPCPass",
2493 ";DCA_{z} [cm];Entries",
2495 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsDCAZTPCPass);
2496 TH1F *gPrimaryProtonsConstrainChi2Pass = new TH1F("gPrimaryProtonsConstrainChi2Pass",
2497 ";Log_{10}(#chi^{2});Entries",
2499 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsConstrainChi2Pass);
2500 TH1F *gPrimaryProtonsITSRefitPass = new TH1F("gPrimaryProtonsITSRefitPass",
2502 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsITSRefitPass);
2503 TH1F *gPrimaryProtonsTPCRefitPass = new TH1F("gPrimaryProtonsTPCRefitPass",
2505 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsTPCRefitPass);
2506 TH1F *gPrimaryProtonsESDpidPass = new TH1F("gPrimaryProtonsESDpidPass",
2508 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsESDpidPass);
2509 TH1F *gPrimaryProtonsTPCpidPass = new TH1F("gPrimaryProtonsTPCpidPass",
2511 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsTPCpidPass);
2512 TH1F *gPrimaryProtonsPointOnITSLayer1Pass = new TH1F("gPrimaryProtonsPointOnITSLayer1Pass",
2514 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsPointOnITSLayer1Pass);
2515 TH1F *gPrimaryProtonsPointOnITSLayer2Pass = new TH1F("gPrimaryProtonsPointOnITSLayer2Pass",
2517 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsPointOnITSLayer2Pass);
2518 TH1F *gPrimaryProtonsPointOnITSLayer3Pass = new TH1F("gPrimaryProtonsPointOnITSLayer3Pass",
2520 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsPointOnITSLayer3Pass);
2521 TH1F *gPrimaryProtonsPointOnITSLayer4Pass = new TH1F("gPrimaryProtonsPointOnITSLayer4Pass",
2523 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsPointOnITSLayer4Pass);
2524 TH1F *gPrimaryProtonsPointOnITSLayer5Pass = new TH1F("gPrimaryProtonsPointOnITSLayer5Pass",
2526 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsPointOnITSLayer5Pass);
2527 TH1F *gPrimaryProtonsPointOnITSLayer6Pass = new TH1F("gPrimaryProtonsPointOnITSLayer6Pass",
2529 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsPointOnITSLayer6Pass);
2530 TH1F *gPrimaryProtonsNumberOfTPCdEdxPointsPass = new TH1F("gPrimaryProtonsNumberOfTPCdEdxPointsPass","",100,0,200);
2531 fQAPrimaryProtonsAcceptedList->Add(gPrimaryProtonsNumberOfTPCdEdxPointsPass);
2533 //Rejected primary protons
2534 /*gDirectory->cd("../");
2535 TDirectory *dirProtonsPrimaryRejected = gDirectory->mkdir("Rejected");
2536 dirProtonsPrimaryRejected->cd();*/
2538 TH1F *gPrimaryProtonsITSClustersReject = new TH1F("gPrimaryProtonsITSClustersReject",
2539 ";N_{clusters} (ITS);Entries",
2541 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsITSClustersReject);
2542 TH1F *gPrimaryProtonsChi2PerClusterITSReject = new TH1F("gPrimaryProtonsChi2PerClusterITSReject",
2543 ";x^{2}/N_{clusters} (ITS);Entries",
2545 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsChi2PerClusterITSReject);
2546 TH1F *gPrimaryProtonsTPCClustersReject = new TH1F("gPrimaryProtonsTPCClustersReject",
2547 ";N_{clusters} (TPC);Entries",
2549 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsTPCClustersReject);
2550 TH1F *gPrimaryProtonsChi2PerClusterTPCReject = new TH1F("gPrimaryProtonsChi2PerClusterTPCReject",
2551 ";x^{2}/N_{clusters} (TPC);Entries",
2553 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsChi2PerClusterTPCReject);
2554 TH1F *gPrimaryProtonsExtCov11Reject = new TH1F("gPrimaryProtonsExtCov11Reject",
2555 ";#sigma_{y} [cm];Entries",
2557 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsExtCov11Reject);
2558 TH1F *gPrimaryProtonsExtCov22Reject = new TH1F("gPrimaryProtonsExtCov22Reject",
2559 ";#sigma_{z} [cm];Entries",
2561 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsExtCov22Reject);
2562 TH1F *gPrimaryProtonsExtCov33Reject = new TH1F("gPrimaryProtonsExtCov33Reject",
2563 ";#sigma_{sin(#phi)};Entries",
2565 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsExtCov33Reject);
2566 TH1F *gPrimaryProtonsExtCov44Reject = new TH1F("gPrimaryProtonsExtCov44Reject",
2567 ";#sigma_{tan(#lambda)};Entries",
2569 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsExtCov44Reject);
2570 TH1F *gPrimaryProtonsExtCov55Reject = new TH1F("gPrimaryProtonsExtCov55Reject",
2571 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
2573 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsExtCov55Reject);
2574 TH1F *gPrimaryProtonsSigmaToVertexReject = new TH1F("gPrimaryProtonsSigmaToVertexReject",
2575 ";#sigma_{Vertex};Entries",
2577 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsSigmaToVertexReject);
2578 TH1F *gPrimaryProtonsSigmaToVertexTPCReject = new TH1F("gPrimaryProtonsSigmaToVertexTPCReject",
2579 ";#sigma_{Vertex};Entries",
2581 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsSigmaToVertexTPCReject);
2582 TH1F *gPrimaryProtonsDCAXYReject = new TH1F("gPrimaryProtonsDCAXYReject",
2583 ";DCA_{xy} [cm];Entries",
2585 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsDCAXYReject);
2586 TH1F *gPrimaryProtonsDCAXYTPCReject = new TH1F("gPrimaryProtonsDCAXYTPCReject",
2587 ";DCA_{xy} [cm];Entries",
2589 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsDCAXYTPCReject);
2590 TH1F *gPrimaryProtonsDCAZReject = new TH1F("gPrimaryProtonsDCAZReject",
2591 ";DCA_{z} [cm];Entries",
2593 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsDCAZReject);
2594 TH1F *gPrimaryProtonsDCAZTPCReject = new TH1F("gPrimaryProtonsDCAZTPCReject",
2595 ";DCA_{z} [cm];Entries",
2597 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsDCAZTPCReject);
2598 TH1F *gPrimaryProtonsConstrainChi2Reject = new TH1F("gPrimaryProtonsConstrainChi2Reject",
2599 ";Log_{10}(#chi^{2});Entries",
2601 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsConstrainChi2Reject);
2602 TH1F *gPrimaryProtonsITSRefitReject = new TH1F("gPrimaryProtonsITSRefitReject",
2604 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsITSRefitReject);
2605 TH1F *gPrimaryProtonsTPCRefitReject = new TH1F("gPrimaryProtonsTPCRefitReject",
2607 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsTPCRefitReject);
2608 TH1F *gPrimaryProtonsESDpidReject = new TH1F("gPrimaryProtonsESDpidReject",
2610 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsESDpidReject);
2611 TH1F *gPrimaryProtonsTPCpidReject = new TH1F("gPrimaryProtonsTPCpidReject",
2613 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsTPCpidReject);
2614 TH1F *gPrimaryProtonsPointOnITSLayer1Reject = new TH1F("gPrimaryProtonsPointOnITSLayer1Reject",
2616 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsPointOnITSLayer1Reject);
2617 TH1F *gPrimaryProtonsPointOnITSLayer2Reject = new TH1F("gPrimaryProtonsPointOnITSLayer2Reject",
2619 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsPointOnITSLayer2Reject);
2620 TH1F *gPrimaryProtonsPointOnITSLayer3Reject = new TH1F("gPrimaryProtonsPointOnITSLayer3Reject",
2622 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsPointOnITSLayer3Reject);
2623 TH1F *gPrimaryProtonsPointOnITSLayer4Reject = new TH1F("gPrimaryProtonsPointOnITSLayer4Reject",
2625 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsPointOnITSLayer4Reject);
2626 TH1F *gPrimaryProtonsPointOnITSLayer5Reject = new TH1F("gPrimaryProtonsPointOnITSLayer5Reject",
2628 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsPointOnITSLayer5Reject);
2629 TH1F *gPrimaryProtonsPointOnITSLayer6Reject = new TH1F("gPrimaryProtonsPointOnITSLayer6Reject",
2631 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsPointOnITSLayer6Reject);
2632 TH1F *gPrimaryProtonsNumberOfTPCdEdxPointsReject = new TH1F("gPrimaryProtonsNumberOfTPCdEdxPointsReject","",100,0,200);
2633 fQAPrimaryProtonsRejectedList->Add(gPrimaryProtonsNumberOfTPCdEdxPointsReject);
2634 //________________________________________________________________//
2635 /*gDirectory->cd("../../");
2637 TDirectory *dirProtonsSecondary = gDirectory->mkdir("Secondaries");
2638 dirProtonsSecondary->cd();
2639 TDirectory *dirProtonsSecondaryAccepted = gDirectory->mkdir("Accepted");
2640 dirProtonsSecondaryAccepted->cd();*/
2642 //Accepted secondary protons
2643 TH1F *gSecondaryProtonsITSClustersPass = new TH1F("gSecondaryProtonsITSClustersPass",
2644 ";N_{clusters} (ITS);Entries",
2646 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsITSClustersPass);
2647 TH1F *gSecondaryProtonsChi2PerClusterITSPass = new TH1F("gSecondaryProtonsChi2PerClusterITSPass",
2648 ";x^{2}/N_{clusters} (ITS);Entries",
2650 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsChi2PerClusterITSPass);
2651 TH1F *gSecondaryProtonsTPCClustersPass = new TH1F("gSecondaryProtonsTPCClustersPass",
2652 ";N_{clusters} (TPC);Entries",
2654 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsTPCClustersPass);
2655 TH1F *gSecondaryProtonsChi2PerClusterTPCPass = new TH1F("gSecondaryProtonsChi2PerClusterTPCPass",
2656 ";x^{2}/N_{clusters} (TPC);Entries",
2658 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsChi2PerClusterTPCPass);
2659 TH1F *gSecondaryProtonsExtCov11Pass = new TH1F("gSecondaryProtonsExtCov11Pass",
2660 ";#sigma_{y} [cm];Entries",
2662 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsExtCov11Pass);
2663 TH1F *gSecondaryProtonsExtCov22Pass = new TH1F("gSecondaryProtonsExtCov22Pass",
2664 ";#sigma_{z} [cm];Entries",
2666 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsExtCov22Pass);
2667 TH1F *gSecondaryProtonsExtCov33Pass = new TH1F("gSecondaryProtonsExtCov33Pass",
2668 ";#sigma_{sin(#phi)};Entries",
2670 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsExtCov33Pass);
2671 TH1F *gSecondaryProtonsExtCov44Pass = new TH1F("gSecondaryProtonsExtCov44Pass",
2672 ";#sigma_{tan(#lambda)};Entries",
2674 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsExtCov44Pass);
2675 TH1F *gSecondaryProtonsExtCov55Pass = new TH1F("gSecondaryProtonsExtCov55Pass",
2676 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
2678 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsExtCov55Pass);
2679 TH1F *gSecondaryProtonsSigmaToVertexPass = new TH1F("gSecondaryProtonsSigmaToVertexPass",
2680 ";#sigma_{Vertex};Entries",
2682 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsSigmaToVertexPass);
2683 TH1F *gSecondaryProtonsSigmaToVertexTPCPass = new TH1F("gSecondaryProtonsSigmaToVertexTPCPass",
2684 ";#sigma_{Vertex};Entries",
2686 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsSigmaToVertexTPCPass);
2687 TH1F *gSecondaryProtonsDCAXYPass = new TH1F("gSecondaryProtonsDCAXYPass",
2688 ";DCA_{xy} [cm];Entries",
2690 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsDCAXYPass);
2691 TH1F *gSecondaryProtonsDCAXYTPCPass = new TH1F("gSecondaryProtonsDCAXYTPCPass",
2692 ";DCA_{xy} [cm];Entries",
2694 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsDCAXYTPCPass);
2695 TH1F *gSecondaryProtonsDCAZPass = new TH1F("gSecondaryProtonsDCAZPass",
2696 ";DCA_{z} [cm];Entries",
2698 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsDCAZPass);
2699 TH1F *gSecondaryProtonsDCAZTPCPass = new TH1F("gSecondaryProtonsDCAZTPCPass",
2700 ";DCA_{z} [cm];Entries",
2702 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsDCAZTPCPass);
2703 TH1F *gSecondaryProtonsConstrainChi2Pass = new TH1F("gSecondaryProtonsConstrainChi2Pass",
2704 ";Log_{10}(#chi^{2});Entries",
2706 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsConstrainChi2Pass);
2707 TH1F *gSecondaryProtonsITSRefitPass = new TH1F("gSecondaryProtonsITSRefitPass",
2709 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsITSRefitPass);
2710 TH1F *gSecondaryProtonsTPCRefitPass = new TH1F("gSecondaryProtonsTPCRefitPass",
2712 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsTPCRefitPass);
2713 TH1F *gSecondaryProtonsESDpidPass = new TH1F("gSecondaryProtonsESDpidPass",
2715 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsESDpidPass);
2716 TH1F *gSecondaryProtonsTPCpidPass = new TH1F("gSecondaryProtonsTPCpidPass",
2718 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsTPCpidPass);
2719 TH1F *gSecondaryProtonsPointOnITSLayer1Pass = new TH1F("gSecondaryProtonsPointOnITSLayer1Pass",
2721 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsPointOnITSLayer1Pass);
2722 TH1F *gSecondaryProtonsPointOnITSLayer2Pass = new TH1F("gSecondaryProtonsPointOnITSLayer2Pass",
2724 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsPointOnITSLayer2Pass);
2725 TH1F *gSecondaryProtonsPointOnITSLayer3Pass = new TH1F("gSecondaryProtonsPointOnITSLayer3Pass",
2727 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsPointOnITSLayer3Pass);
2728 TH1F *gSecondaryProtonsPointOnITSLayer4Pass = new TH1F("gSecondaryProtonsPointOnITSLayer4Pass",
2730 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsPointOnITSLayer4Pass);
2731 TH1F *gSecondaryProtonsPointOnITSLayer5Pass = new TH1F("gSecondaryProtonsPointOnITSLayer5Pass",
2733 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsPointOnITSLayer5Pass);
2734 TH1F *gSecondaryProtonsPointOnITSLayer6Pass = new TH1F("gSecondaryProtonsPointOnITSLayer6Pass",
2736 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsPointOnITSLayer6Pass);
2737 TH1F *gSecondaryProtonsNumberOfTPCdEdxPointsPass = new TH1F("gSecondaryProtonsNumberOfTPCdEdxPointsPass","",100,0,200);
2738 fQASecondaryProtonsAcceptedList->Add(gSecondaryProtonsNumberOfTPCdEdxPointsPass);
2740 //Rejected secondary protons
2741 /*gDirectory->cd("../");
2742 TDirectory *dirProtonsSecondaryRejected = gDirectory->mkdir("Rejected");
2743 dirProtonsSecondaryRejected->cd();*/
2745 TH1F *gSecondaryProtonsITSClustersReject = new TH1F("gSecondaryProtonsITSClustersReject",
2746 ";N_{clusters} (ITS);Entries",
2748 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsITSClustersReject);
2749 TH1F *gSecondaryProtonsChi2PerClusterITSReject = new TH1F("gSecondaryProtonsChi2PerClusterITSReject",
2750 ";x^{2}/N_{clusters} (ITS);Entries",
2752 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsChi2PerClusterITSReject);
2753 TH1F *gSecondaryProtonsTPCClustersReject = new TH1F("gSecondaryProtonsTPCClustersReject",
2754 ";N_{clusters} (TPC);Entries",
2756 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsTPCClustersReject);
2757 TH1F *gSecondaryProtonsChi2PerClusterTPCReject = new TH1F("gSecondaryProtonsChi2PerClusterTPCReject",
2758 ";x^{2}/N_{clusters} (TPC);Entries",
2760 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsChi2PerClusterTPCReject);
2761 TH1F *gSecondaryProtonsExtCov11Reject = new TH1F("gSecondaryProtonsExtCov11Reject",
2762 ";#sigma_{y} [cm];Entries",
2764 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsExtCov11Reject);
2765 TH1F *gSecondaryProtonsExtCov22Reject = new TH1F("gSecondaryProtonsExtCov22Reject",
2766 ";#sigma_{z} [cm];Entries",
2768 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsExtCov22Reject);
2769 TH1F *gSecondaryProtonsExtCov33Reject = new TH1F("gSecondaryProtonsExtCov33Reject",
2770 ";#sigma_{sin(#phi)};Entries",
2772 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsExtCov33Reject);
2773 TH1F *gSecondaryProtonsExtCov44Reject = new TH1F("gSecondaryProtonsExtCov44Reject",
2774 ";#sigma_{tan(#lambda)};Entries",
2776 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsExtCov44Reject);
2777 TH1F *gSecondaryProtonsExtCov55Reject = new TH1F("gSecondaryProtonsExtCov55Reject",
2778 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
2780 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsExtCov55Reject);
2781 TH1F *gSecondaryProtonsSigmaToVertexReject = new TH1F("gSecondaryProtonsSigmaToVertexReject",
2782 ";#sigma_{Vertex};Entries",
2784 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsSigmaToVertexReject);
2785 TH1F *gSecondaryProtonsSigmaToVertexTPCReject = new TH1F("gSecondaryProtonsSigmaToVertexTPCReject",
2786 ";#sigma_{Vertex};Entries",
2788 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsSigmaToVertexTPCReject);
2789 TH1F *gSecondaryProtonsDCAXYReject = new TH1F("gSecondaryProtonsDCAXYReject",
2790 ";DCA_{xy} [cm];Entries",
2792 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsDCAXYReject);
2793 TH1F *gSecondaryProtonsDCAXYTPCReject = new TH1F("gSecondaryProtonsDCAXYTPCReject",
2794 ";DCA_{xy} [cm];Entries",
2796 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsDCAXYTPCReject);
2797 TH1F *gSecondaryProtonsDCAZReject = new TH1F("gSecondaryProtonsDCAZReject",
2798 ";DCA_{z} [cm];Entries",
2800 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsDCAZReject);
2801 TH1F *gSecondaryProtonsDCAZTPCReject = new TH1F("gSecondaryProtonsDCAZTPCReject",
2802 ";DCA_{z} [cm];Entries",
2804 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsDCAZTPCReject);
2805 TH1F *gSecondaryProtonsConstrainChi2Reject = new TH1F("gSecondaryProtonsConstrainChi2Reject",
2806 ";Log_{10}(#chi^{2});Entries",
2808 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsConstrainChi2Reject);
2809 TH1F *gSecondaryProtonsITSRefitReject = new TH1F("gSecondaryProtonsITSRefitReject",
2811 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsITSRefitReject);
2812 TH1F *gSecondaryProtonsTPCRefitReject = new TH1F("gSecondaryProtonsTPCRefitReject",
2814 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsTPCRefitReject);
2815 TH1F *gSecondaryProtonsESDpidReject = new TH1F("gSecondaryProtonsESDpidReject",
2817 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsESDpidReject);
2818 TH1F *gSecondaryProtonsTPCpidReject = new TH1F("gSecondaryProtonsTPCpidReject",
2820 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsTPCpidReject);
2821 TH1F *gSecondaryProtonsPointOnITSLayer1Reject = new TH1F("gSecondaryProtonsPointOnITSLayer1Reject",
2823 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsPointOnITSLayer1Reject);
2824 TH1F *gSecondaryProtonsPointOnITSLayer2Reject = new TH1F("gSecondaryProtonsPointOnITSLayer2Reject",
2826 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsPointOnITSLayer2Reject);
2827 TH1F *gSecondaryProtonsPointOnITSLayer3Reject = new TH1F("gSecondaryProtonsPointOnITSLayer3Reject",
2829 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsPointOnITSLayer3Reject);
2830 TH1F *gSecondaryProtonsPointOnITSLayer4Reject = new TH1F("gSecondaryProtonsPointOnITSLayer4Reject",
2832 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsPointOnITSLayer4Reject);
2833 TH1F *gSecondaryProtonsPointOnITSLayer5Reject = new TH1F("gSecondaryProtonsPointOnITSLayer5Reject",
2835 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsPointOnITSLayer5Reject);
2836 TH1F *gSecondaryProtonsPointOnITSLayer6Reject = new TH1F("gSecondaryProtonsPointOnITSLayer6Reject",
2838 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsPointOnITSLayer6Reject);
2839 TH1F *gSecondaryProtonsNumberOfTPCdEdxPointsReject = new TH1F("gSecondaryProtonsNumberOfTPCdEdxPointsReject","",100,0,200);
2840 fQASecondaryProtonsRejectedList->Add(gSecondaryProtonsNumberOfTPCdEdxPointsReject);
2842 /*gDirectory->cd("../../../");
2845 TDirectory *dirAntiProtons = gDirectory->mkdir("AntiProtons");
2846 fGlobalQAList->Add(dirAntiProtons); dirAntiProtons->cd();*/
2848 //________________________________________________________________//
2849 /*TDirectory *dirAntiProtonsPrimary = gDirectory->mkdir("Primaries");
2850 dirAntiProtonsPrimary->cd();
2851 TDirectory *dirAntiProtonsPrimaryAccepted = gDirectory->mkdir("Accepted");
2852 dirAntiProtonsPrimaryAccepted->cd();*/
2854 //Accepted primary antiprotons
2855 TH1F *gPrimaryAntiProtonsITSClustersPass = new TH1F("gPrimaryAntiProtonsITSClustersPass",
2856 ";N_{clusters} (ITS);Entries",
2858 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsITSClustersPass);
2859 TH1F *gPrimaryAntiProtonsChi2PerClusterITSPass = new TH1F("gPrimaryAntiProtonsChi2PerClusterITSPass",
2860 ";x^{2}/N_{clusters} (ITS);Entries",
2862 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsChi2PerClusterITSPass);
2863 TH1F *gPrimaryAntiProtonsTPCClustersPass = new TH1F("gPrimaryAntiProtonsTPCClustersPass",
2864 ";N_{clusters} (TPC);Entries",
2866 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsTPCClustersPass);
2867 TH1F *gPrimaryAntiProtonsChi2PerClusterTPCPass = new TH1F("gPrimaryAntiProtonsChi2PerClusterTPCPass",
2868 ";x^{2}/N_{clusters} (TPC);Entries",
2870 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsChi2PerClusterTPCPass);
2871 TH1F *gPrimaryAntiProtonsExtCov11Pass = new TH1F("gPrimaryAntiProtonsExtCov11Pass",
2872 ";#sigma_{y} [cm];Entries",
2874 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsExtCov11Pass);
2875 TH1F *gPrimaryAntiProtonsExtCov22Pass = new TH1F("gPrimaryAntiProtonsExtCov22Pass",
2876 ";#sigma_{z} [cm];Entries",
2878 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsExtCov22Pass);
2879 TH1F *gPrimaryAntiProtonsExtCov33Pass = new TH1F("gPrimaryAntiProtonsExtCov33Pass",
2880 ";#sigma_{sin(#phi)};Entries",
2882 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsExtCov33Pass);
2883 TH1F *gPrimaryAntiProtonsExtCov44Pass = new TH1F("gPrimaryAntiProtonsExtCov44Pass",
2884 ";#sigma_{tan(#lambda)};Entries",
2886 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsExtCov44Pass);
2887 TH1F *gPrimaryAntiProtonsExtCov55Pass = new TH1F("gPrimaryAntiProtonsExtCov55Pass",
2888 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
2890 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsExtCov55Pass);
2891 TH1F *gPrimaryAntiProtonsSigmaToVertexPass = new TH1F("gPrimaryAntiProtonsSigmaToVertexPass",
2892 ";#sigma_{Vertex};Entries",
2894 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsSigmaToVertexPass);
2895 TH1F *gPrimaryAntiProtonsSigmaToVertexTPCPass = new TH1F("gPrimaryAntiProtonsSigmaToVertexTPCPass",
2896 ";#sigma_{Vertex};Entries",
2898 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsSigmaToVertexTPCPass);
2899 TH1F *gPrimaryAntiProtonsDCAXYPass = new TH1F("gPrimaryAntiProtonsDCAXYPass",
2900 ";DCA_{xy} [cm];Entries",
2902 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsDCAXYPass);
2903 TH1F *gPrimaryAntiProtonsDCAXYTPCPass = new TH1F("gPrimaryAntiProtonsDCAXYTPCPass",
2904 ";DCA_{xy} [cm];Entries",
2906 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsDCAXYTPCPass);
2907 TH1F *gPrimaryAntiProtonsDCAZPass = new TH1F("gPrimaryAntiProtonsDCAZPass",
2908 ";DCA_{z} [cm];Entries",
2910 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsDCAZPass);
2911 TH1F *gPrimaryAntiProtonsDCAZTPCPass = new TH1F("gPrimaryAntiProtonsDCAZTPCPass",
2912 ";DCA_{z} [cm];Entries",
2914 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsDCAZTPCPass);
2915 TH1F *gPrimaryAntiProtonsConstrainChi2Pass = new TH1F("gPrimaryAntiProtonsConstrainChi2Pass",
2916 ";Log_{10}(#chi^{2});Entries",
2918 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsConstrainChi2Pass);
2919 TH1F *gPrimaryAntiProtonsITSRefitPass = new TH1F("gPrimaryAntiProtonsITSRefitPass",
2921 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsITSRefitPass);
2922 TH1F *gPrimaryAntiProtonsTPCRefitPass = new TH1F("gPrimaryAntiProtonsTPCRefitPass",
2924 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsTPCRefitPass);
2925 TH1F *gPrimaryAntiProtonsESDpidPass = new TH1F("gPrimaryAntiProtonsESDpidPass",
2927 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsESDpidPass);
2928 TH1F *gPrimaryAntiProtonsTPCpidPass = new TH1F("gPrimaryAntiProtonsTPCpidPass",
2930 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsTPCpidPass);
2931 TH1F *gPrimaryAntiProtonsPointOnITSLayer1Pass = new TH1F("gPrimaryAntiProtonsPointOnITSLayer1Pass",
2933 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsPointOnITSLayer1Pass);
2934 TH1F *gPrimaryAntiProtonsPointOnITSLayer2Pass = new TH1F("gPrimaryAntiProtonsPointOnITSLayer2Pass",
2936 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsPointOnITSLayer2Pass);
2937 TH1F *gPrimaryAntiProtonsPointOnITSLayer3Pass = new TH1F("gPrimaryAntiProtonsPointOnITSLayer3Pass",
2939 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsPointOnITSLayer3Pass);
2940 TH1F *gPrimaryAntiProtonsPointOnITSLayer4Pass = new TH1F("gPrimaryAntiProtonsPointOnITSLayer4Pass",
2942 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsPointOnITSLayer4Pass);
2943 TH1F *gPrimaryAntiProtonsPointOnITSLayer5Pass = new TH1F("gPrimaryAntiProtonsPointOnITSLayer5Pass",
2945 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsPointOnITSLayer5Pass);
2946 TH1F *gPrimaryAntiProtonsPointOnITSLayer6Pass = new TH1F("gPrimaryAntiProtonsPointOnITSLayer6Pass",
2948 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsPointOnITSLayer6Pass);
2949 TH1F *gPrimaryAntiProtonsNumberOfTPCdEdxPointsPass = new TH1F("gPrimaryAntiProtonsNumberOfTPCdEdxPointsPass","",100,0,200);
2950 fQAPrimaryAntiProtonsAcceptedList->Add(gPrimaryAntiProtonsNumberOfTPCdEdxPointsPass);
2951 /*TH2F *gHistPrimaryAntiProtonsDCAxyPtPass = new TH2F("gHistPrimaryAntiProtonsDCAxyPtPass",
2952 ";P_{T} [GeV/c];dca_{xy} [cm]",
2955 gHistPrimaryAntiProtonsDCAxyPtPass->SetStats(kFALSE);
2956 fQAPrimaryAntiProtonsAcceptedList->Add(gHistPrimaryAntiProtonsDCAxyPtPass);
2957 TH2F *gHistPrimaryAntiProtonsDCAzPtPass = new TH2F("gHistPrimaryAntiProtonsDCAzPtPass",
2958 ";P_{T} [GeV/c];dca_{z} [cm]",
2961 gHistPrimaryAntiProtonsDCAzPtPass->SetStats(kFALSE);
2962 fQAPrimaryAntiProtonsAcceptedList->Add(gHistPrimaryAntiProtonsDCAzPtPass);*/
2964 //Rejected primary antiprotons
2965 /*gDirectory->cd("../");
2966 TDirectory *dirAntiProtonsPrimaryRejected = gDirectory->mkdir("Rejected");
2967 dirAntiProtonsPrimaryRejected->cd();*/
2969 TH1F *gPrimaryAntiProtonsITSClustersReject = new TH1F("gPrimaryAntiProtonsITSClustersReject",
2970 ";N_{clusters} (ITS);Entries",
2972 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsITSClustersReject);
2973 TH1F *gPrimaryAntiProtonsChi2PerClusterITSReject = new TH1F("gPrimaryAntiProtonsChi2PerClusterITSReject",
2974 ";x^{2}/N_{clusters} (ITS);Entries",
2976 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsChi2PerClusterITSReject);
2977 TH1F *gPrimaryAntiProtonsTPCClustersReject = new TH1F("gPrimaryAntiProtonsTPCClustersReject",
2978 ";N_{clusters} (TPC);Entries",
2980 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsTPCClustersReject);
2981 TH1F *gPrimaryAntiProtonsChi2PerClusterTPCReject = new TH1F("gPrimaryAntiProtonsChi2PerClusterTPCReject",
2982 ";x^{2}/N_{clusters} (TPC);Entries",
2984 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsChi2PerClusterTPCReject);
2985 TH1F *gPrimaryAntiProtonsExtCov11Reject = new TH1F("gPrimaryAntiProtonsExtCov11Reject",
2986 ";#sigma_{y} [cm];Entries",
2988 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsExtCov11Reject);
2989 TH1F *gPrimaryAntiProtonsExtCov22Reject = new TH1F("gPrimaryAntiProtonsExtCov22Reject",
2990 ";#sigma_{z} [cm];Entries",
2992 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsExtCov22Reject);
2993 TH1F *gPrimaryAntiProtonsExtCov33Reject = new TH1F("gPrimaryAntiProtonsExtCov33Reject",
2994 ";#sigma_{sin(#phi)};Entries",
2996 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsExtCov33Reject);
2997 TH1F *gPrimaryAntiProtonsExtCov44Reject = new TH1F("gPrimaryAntiProtonsExtCov44Reject",
2998 ";#sigma_{tan(#lambda)};Entries",
3000 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsExtCov44Reject);
3001 TH1F *gPrimaryAntiProtonsExtCov55Reject = new TH1F("gPrimaryAntiProtonsExtCov55Reject",
3002 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
3004 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsExtCov55Reject);
3005 TH1F *gPrimaryAntiProtonsSigmaToVertexReject = new TH1F("gPrimaryAntiProtonsSigmaToVertexReject",
3006 ";#sigma_{Vertex};Entries",
3008 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsSigmaToVertexReject);
3009 TH1F *gPrimaryAntiProtonsSigmaToVertexTPCReject = new TH1F("gPrimaryAntiProtonsSigmaToVertexTPCReject",
3010 ";#sigma_{Vertex};Entries",
3012 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsSigmaToVertexTPCReject);
3013 TH1F *gPrimaryAntiProtonsDCAXYReject = new TH1F("gPrimaryAntiProtonsDCAXYReject",
3014 ";DCA_{xy} [cm];Entries",
3016 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsDCAXYReject);
3017 TH1F *gPrimaryAntiProtonsDCAXYTPCReject = new TH1F("gPrimaryAntiProtonsDCAXYTPCReject",
3018 ";DCA_{xy} [cm];Entries",
3020 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsDCAXYTPCReject);
3021 TH1F *gPrimaryAntiProtonsDCAZReject = new TH1F("gPrimaryAntiProtonsDCAZReject",
3022 ";DCA_{z} [cm];Entries",
3024 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsDCAZReject);
3025 TH1F *gPrimaryAntiProtonsDCAZTPCReject = new TH1F("gPrimaryAntiProtonsDCAZTPCReject",
3026 ";DCA_{z} [cm];Entries",
3028 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsDCAZTPCReject);
3029 TH1F *gPrimaryAntiProtonsConstrainChi2Reject = new TH1F("gPrimaryAntiProtonsConstrainChi2Reject",
3030 ";Log_{10}(#chi^{2});Entries",
3032 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsConstrainChi2Reject);
3033 TH1F *gPrimaryAntiProtonsITSRefitReject = new TH1F("gPrimaryAntiProtonsITSRefitReject",
3035 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsITSRefitReject);
3036 TH1F *gPrimaryAntiProtonsTPCRefitReject = new TH1F("gPrimaryAntiProtonsTPCRefitReject",
3038 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsTPCRefitReject);
3039 TH1F *gPrimaryAntiProtonsESDpidReject = new TH1F("gPrimaryAntiProtonsESDpidReject",
3041 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsESDpidReject);
3042 TH1F *gPrimaryAntiProtonsTPCpidReject = new TH1F("gPrimaryAntiProtonsTPCpidReject",
3044 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsTPCpidReject);
3045 TH1F *gPrimaryAntiProtonsPointOnITSLayer1Reject = new TH1F("gPrimaryAntiProtonsPointOnITSLayer1Reject",
3047 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsPointOnITSLayer1Reject);
3048 TH1F *gPrimaryAntiProtonsPointOnITSLayer2Reject = new TH1F("gPrimaryAntiProtonsPointOnITSLayer2Reject",
3050 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsPointOnITSLayer2Reject);
3051 TH1F *gPrimaryAntiProtonsPointOnITSLayer3Reject = new TH1F("gPrimaryAntiProtonsPointOnITSLayer3Reject",
3053 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsPointOnITSLayer3Reject);
3054 TH1F *gPrimaryAntiProtonsPointOnITSLayer4Reject = new TH1F("gPrimaryAntiProtonsPointOnITSLayer4Reject",
3056 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsPointOnITSLayer4Reject);
3057 TH1F *gPrimaryAntiProtonsPointOnITSLayer5Reject = new TH1F("gPrimaryAntiProtonsPointOnITSLayer5Reject",
3059 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsPointOnITSLayer5Reject);
3060 TH1F *gPrimaryAntiProtonsPointOnITSLayer6Reject = new TH1F("gPrimaryAntiProtonsPointOnITSLayer6Reject",
3062 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsPointOnITSLayer6Reject);
3063 TH1F *gPrimaryAntiProtonsNumberOfTPCdEdxPointsReject = new TH1F("gPrimaryAntiProtonsNumberOfTPCdEdxPointsReject","",100,0,200);
3064 fQAPrimaryAntiProtonsRejectedList->Add(gPrimaryAntiProtonsNumberOfTPCdEdxPointsReject);
3065 /*TH2F *gHistPrimaryAntiProtonsDCAxyPtReject = new TH2F("gHistPrimaryAntiProtonsDCAxyPtReject",
3066 ";P_{T} [GeV/c];dca_{xy} [cm]",
3069 gHistPrimaryAntiProtonsDCAxyPtReject->SetStats(kFALSE);
3070 fQAPrimaryAntiProtonsRejectedList->Add(gHistPrimaryAntiProtonsDCAxyPtReject);
3071 TH2F *gHistPrimaryAntiProtonsDCAzPtReject = new TH2F("gHistPrimaryAntiProtonsDCAzPtReject",
3072 ";P_{T} [GeV/c];dca_{z} [cm]",
3075 gHistPrimaryAntiProtonsDCAzPtReject->SetStats(kFALSE);
3076 fQAPrimaryAntiProtonsRejectedList->Add(gHistPrimaryAntiProtonsDCAzPtReject);*/
3078 //________________________________________________________________//
3079 /*gDirectory->cd("../../");
3081 TDirectory *dirAntiProtonsSecondary = gDirectory->mkdir("Secondaries");
3082 dirAntiProtonsSecondary->cd();
3083 TDirectory *dirAntiProtonsSecondaryAccepted = gDirectory->mkdir("Accepted");
3084 dirAntiProtonsSecondaryAccepted->cd();*/
3086 //Accepted secondary antiprotons
3087 TH1F *gSecondaryAntiProtonsITSClustersPass = new TH1F("gSecondaryAntiProtonsITSClustersPass",
3088 ";N_{clusters} (ITS);Entries",
3090 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsITSClustersPass);
3091 TH1F *gSecondaryAntiProtonsChi2PerClusterITSPass = new TH1F("gSecondaryAntiProtonsChi2PerClusterITSPass",
3092 ";x^{2}/N_{clusters} (ITS);Entries",
3094 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsChi2PerClusterITSPass);
3095 TH1F *gSecondaryAntiProtonsTPCClustersPass = new TH1F("gSecondaryAntiProtonsTPCClustersPass",
3096 ";N_{clusters} (TPC);Entries",
3098 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsTPCClustersPass);
3099 TH1F *gSecondaryAntiProtonsChi2PerClusterTPCPass = new TH1F("gSecondaryAntiProtonsChi2PerClusterTPCPass",
3100 ";x^{2}/N_{clusters} (TPC);Entries",
3102 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsChi2PerClusterTPCPass);
3103 TH1F *gSecondaryAntiProtonsExtCov11Pass = new TH1F("gSecondaryAntiProtonsExtCov11Pass",
3104 ";#sigma_{y} [cm];Entries",
3106 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsExtCov11Pass);
3107 TH1F *gSecondaryAntiProtonsExtCov22Pass = new TH1F("gSecondaryAntiProtonsExtCov22Pass",
3108 ";#sigma_{z} [cm];Entries",
3110 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsExtCov22Pass);
3111 TH1F *gSecondaryAntiProtonsExtCov33Pass = new TH1F("gSecondaryAntiProtonsExtCov33Pass",
3112 ";#sigma_{sin(#phi)};Entries",
3114 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsExtCov33Pass);
3115 TH1F *gSecondaryAntiProtonsExtCov44Pass = new TH1F("gSecondaryAntiProtonsExtCov44Pass",
3116 ";#sigma_{tan(#lambda)};Entries",
3118 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsExtCov44Pass);
3119 TH1F *gSecondaryAntiProtonsExtCov55Pass = new TH1F("gSecondaryAntiProtonsExtCov55Pass",
3120 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
3122 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsExtCov55Pass);
3123 TH1F *gSecondaryAntiProtonsSigmaToVertexPass = new TH1F("gSecondaryAntiProtonsSigmaToVertexPass",
3124 ";#sigma_{Vertex};Entries",
3126 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsSigmaToVertexPass);
3127 TH1F *gSecondaryAntiProtonsSigmaToVertexTPCPass = new TH1F("gSecondaryAntiProtonsSigmaToVertexTPCPass",
3128 ";#sigma_{Vertex};Entries",
3130 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsSigmaToVertexTPCPass);
3131 TH1F *gSecondaryAntiProtonsDCAXYPass = new TH1F("gSecondaryAntiProtonsDCAXYPass",
3132 ";DCA_{xy} [cm];Entries",
3134 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsDCAXYPass);
3135 TH1F *gSecondaryAntiProtonsDCAXYTPCPass = new TH1F("gSecondaryAntiProtonsDCAXYTPCPass",
3136 ";DCA_{xy} [cm];Entries",
3138 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsDCAXYTPCPass);
3139 TH1F *gSecondaryAntiProtonsDCAZPass = new TH1F("gSecondaryAntiProtonsDCAZPass",
3140 ";DCA_{z} [cm];Entries",
3142 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsDCAZPass);
3143 TH1F *gSecondaryAntiProtonsDCAZTPCPass = new TH1F("gSecondaryAntiProtonsDCAZTPCPass",
3144 ";DCA_{z} [cm];Entries",
3146 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsDCAZTPCPass);
3147 TH1F *gSecondaryAntiProtonsConstrainChi2Pass = new TH1F("gSecondaryAntiProtonsConstrainChi2Pass",
3148 ";Log_{10}(#chi^{2});Entries",
3150 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsConstrainChi2Pass);
3151 TH1F *gSecondaryAntiProtonsITSRefitPass = new TH1F("gSecondaryAntiProtonsITSRefitPass",
3153 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsITSRefitPass);
3154 TH1F *gSecondaryAntiProtonsTPCRefitPass = new TH1F("gSecondaryAntiProtonsTPCRefitPass",
3156 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsTPCRefitPass);
3157 TH1F *gSecondaryAntiProtonsESDpidPass = new TH1F("gSecondaryAntiProtonsESDpidPass",
3159 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsESDpidPass);
3160 TH1F *gSecondaryAntiProtonsTPCpidPass = new TH1F("gSecondaryAntiProtonsTPCpidPass",
3162 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsTPCpidPass);
3163 TH1F *gSecondaryAntiProtonsPointOnITSLayer1Pass = new TH1F("gSecondaryAntiProtonsPointOnITSLayer1Pass",
3165 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsPointOnITSLayer1Pass);
3166 TH1F *gSecondaryAntiProtonsPointOnITSLayer2Pass = new TH1F("gSecondaryAntiProtonsPointOnITSLayer2Pass",
3168 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsPointOnITSLayer2Pass);
3169 TH1F *gSecondaryAntiProtonsPointOnITSLayer3Pass = new TH1F("gSecondaryAntiProtonsPointOnITSLayer3Pass",
3171 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsPointOnITSLayer3Pass);
3172 TH1F *gSecondaryAntiProtonsPointOnITSLayer4Pass = new TH1F("gSecondaryAntiProtonsPointOnITSLayer4Pass",
3174 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsPointOnITSLayer4Pass);
3175 TH1F *gSecondaryAntiProtonsPointOnITSLayer5Pass = new TH1F("gSecondaryAntiProtonsPointOnITSLayer5Pass",
3177 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsPointOnITSLayer5Pass);
3178 TH1F *gSecondaryAntiProtonsPointOnITSLayer6Pass = new TH1F("gSecondaryAntiProtonsPointOnITSLayer6Pass",
3180 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsPointOnITSLayer6Pass);
3181 TH1F *gSecondaryAntiProtonsNumberOfTPCdEdxPointsPass = new TH1F("gSecondaryAntiProtonsNumberOfTPCdEdxPointsPass","",100,0,200);
3182 fQASecondaryAntiProtonsAcceptedList->Add(gSecondaryAntiProtonsNumberOfTPCdEdxPointsPass);
3183 /*TH2F *gHistSecondaryAntiProtonsFromWeakDCAxyPtPass = new TH2F("gHistSecondaryAntiProtonsFromWeakDCAxyPtPass",
3184 ";P_{T} [GeV/c];dca_{xy} [cm]",
3187 gHistSecondaryAntiProtonsFromWeakDCAxyPtPass->SetStats(kFALSE);
3188 fQASecondaryAntiProtonsAcceptedList->Add(gHistSecondaryAntiProtonsFromWeakDCAxyPtPass);
3189 TH2F *gHistSecondaryAntiProtonsFromWeakDCAzPtPass = new TH2F("gHistSecondaryAntiProtonsFromWeakDCAzPtPass",
3190 ";P_{T} [GeV/c];dca_{z} [cm]",
3193 gHistSecondaryAntiProtonsFromWeakDCAzPtPass->SetStats(kFALSE);
3194 fQASecondaryAntiProtonsAcceptedList->Add(gHistSecondaryAntiProtonsFromWeakDCAzPtPass);
3195 TH2F *gHistSecondaryAntiProtonsFromHadronicDCAxyPtPass = new TH2F("gHistSecondaryAntiProtonsFromHadronicDCAxyPtPass",
3196 ";P_{T} [GeV/c];dca_{xy} [cm]",
3199 gHistSecondaryAntiProtonsFromHadronicDCAxyPtPass->SetStats(kFALSE);
3200 fQASecondaryAntiProtonsAcceptedList->Add(gHistSecondaryAntiProtonsFromHadronicDCAxyPtPass);
3201 TH2F *gHistSecondaryAntiProtonsFromHadronicDCAzPtPass = new TH2F("gHistSecondaryAntiProtonsFromHadronicDCAzPtPass",
3202 ";P_{T} [GeV/c];dca_{z} [cm]",
3205 gHistSecondaryAntiProtonsFromHadronicDCAzPtPass->SetStats(kFALSE);
3206 fQASecondaryAntiProtonsAcceptedList->Add(gHistSecondaryAntiProtonsFromHadronicDCAzPtPass);*/
3208 //Rejected secondary antiprotons
3209 /*gDirectory->cd("../");
3210 TDirectory *dirAntiProtonsSecondaryRejected = gDirectory->mkdir("Rejected");
3211 dirAntiProtonsSecondaryRejected->cd();*/
3213 TH1F *gSecondaryAntiProtonsITSClustersReject = new TH1F("gSecondaryAntiProtonsITSClustersReject",
3214 ";N_{clusters} (ITS);Entries",
3216 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsITSClustersReject);
3217 TH1F *gSecondaryAntiProtonsChi2PerClusterITSReject = new TH1F("gSecondaryAntiProtonsChi2PerClusterITSReject",
3218 ";x^{2}/N_{clusters} (ITS);Entries",
3220 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsChi2PerClusterITSReject);
3221 TH1F *gSecondaryAntiProtonsTPCClustersReject = new TH1F("gSecondaryAntiProtonsTPCClustersReject",
3222 ";N_{clusters} (TPC);Entries",
3224 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsTPCClustersReject);
3225 TH1F *gSecondaryAntiProtonsChi2PerClusterTPCReject = new TH1F("gSecondaryAntiProtonsChi2PerClusterTPCReject",
3226 ";x^{2}/N_{clusters} (TPC);Entries",
3228 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsChi2PerClusterTPCReject);
3229 TH1F *gSecondaryAntiProtonsExtCov11Reject = new TH1F("gSecondaryAntiProtonsExtCov11Reject",
3230 ";#sigma_{y} [cm];Entries",
3232 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsExtCov11Reject);
3233 TH1F *gSecondaryAntiProtonsExtCov22Reject = new TH1F("gSecondaryAntiProtonsExtCov22Reject",
3234 ";#sigma_{z} [cm];Entries",
3236 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsExtCov22Reject);
3237 TH1F *gSecondaryAntiProtonsExtCov33Reject = new TH1F("gSecondaryAntiProtonsExtCov33Reject",
3238 ";#sigma_{sin(#phi)};Entries",
3240 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsExtCov33Reject);
3241 TH1F *gSecondaryAntiProtonsExtCov44Reject = new TH1F("gSecondaryAntiProtonsExtCov44Reject",
3242 ";#sigma_{tan(#lambda)};Entries",
3244 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsExtCov44Reject);
3245 TH1F *gSecondaryAntiProtonsExtCov55Reject = new TH1F("gSecondaryAntiProtonsExtCov55Reject",
3246 ";#sigma_{1/P_{T}} [GeV/c]^{-1};Entries",
3248 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsExtCov55Reject);
3249 TH1F *gSecondaryAntiProtonsSigmaToVertexReject = new TH1F("gSecondaryAntiProtonsSigmaToVertexReject",
3250 ";#sigma_{Vertex};Entries",
3252 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsSigmaToVertexReject);
3253 TH1F *gSecondaryAntiProtonsSigmaToVertexTPCReject = new TH1F("gSecondaryAntiProtonsSigmaToVertexTPCReject",
3254 ";#sigma_{Vertex};Entries",
3256 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsSigmaToVertexTPCReject);
3257 TH1F *gSecondaryAntiProtonsDCAXYReject = new TH1F("gSecondaryAntiProtonsDCAXYReject",
3258 ";DCA_{xy} [cm];Entries",
3260 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsDCAXYReject);
3261 TH1F *gSecondaryAntiProtonsDCAXYTPCReject = new TH1F("gSecondaryAntiProtonsDCAXYTPCReject",
3262 ";DCA_{xy} [cm];Entries",
3264 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsDCAXYTPCReject);
3265 TH1F *gSecondaryAntiProtonsDCAZReject = new TH1F("gSecondaryAntiProtonsDCAZReject",
3266 ";DCA_{z} [cm];Entries",
3268 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsDCAZReject);
3269 TH1F *gSecondaryAntiProtonsDCAZTPCReject = new TH1F("gSecondaryAntiProtonsDCAZTPCReject",
3270 ";DCA_{z} [cm];Entries",
3272 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsDCAZTPCReject);
3273 TH1F *gSecondaryAntiProtonsConstrainChi2Reject = new TH1F("gSecondaryAntiProtonsConstrainChi2Reject",
3274 ";Log_{10}(#chi^{2});Entries",
3276 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsConstrainChi2Reject);
3277 TH1F *gSecondaryAntiProtonsITSRefitReject = new TH1F("gSecondaryAntiProtonsITSRefitReject",
3279 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsITSRefitReject);
3280 TH1F *gSecondaryAntiProtonsTPCRefitReject = new TH1F("gSecondaryAntiProtonsTPCRefitReject",
3282 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsTPCRefitReject);
3283 TH1F *gSecondaryAntiProtonsESDpidReject = new TH1F("gSecondaryAntiProtonsESDpidReject",
3285 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsESDpidReject);
3286 TH1F *gSecondaryAntiProtonsTPCpidReject = new TH1F("gSecondaryAntiProtonsTPCpidReject",
3288 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsTPCpidReject);
3289 TH1F *gSecondaryAntiProtonsPointOnITSLayer1Reject = new TH1F("gSecondaryAntiProtonsPointOnITSLayer1Reject",
3291 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsPointOnITSLayer1Reject);
3292 TH1F *gSecondaryAntiProtonsPointOnITSLayer2Reject = new TH1F("gSecondaryAntiProtonsPointOnITSLayer2Reject",
3294 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsPointOnITSLayer2Reject);
3295 TH1F *gSecondaryAntiProtonsPointOnITSLayer3Reject = new TH1F("gSecondaryAntiProtonsPointOnITSLayer3Reject",
3297 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsPointOnITSLayer3Reject);
3298 TH1F *gSecondaryAntiProtonsPointOnITSLayer4Reject = new TH1F("gSecondaryAntiProtonsPointOnITSLayer4Reject",
3300 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsPointOnITSLayer4Reject);
3301 TH1F *gSecondaryAntiProtonsPointOnITSLayer5Reject = new TH1F("gSecondaryAntiProtonsPointOnITSLayer5Reject",
3303 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsPointOnITSLayer5Reject);
3304 TH1F *gSecondaryAntiProtonsPointOnITSLayer6Reject = new TH1F("gSecondaryAntiProtonsPointOnITSLayer6Reject",
3306 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsPointOnITSLayer6Reject);
3307 TH1F *gSecondaryAntiProtonsNumberOfTPCdEdxPointsReject = new TH1F("gSecondaryAntiProtonsNumberOfTPCdEdxPointsReject","",100,0,200);
3308 fQASecondaryAntiProtonsRejectedList->Add(gSecondaryAntiProtonsNumberOfTPCdEdxPointsReject);
3309 /*TH2F *gHistSecondaryAntiProtonsFromWeakDCAxyPtReject = new TH2F("gHistSecondaryAntiProtonsFromWeakDCAxyPtReject",
3310 ";P_{T} [GeV/c];dca_{xy} [cm]",
3313 gHistSecondaryAntiProtonsFromWeakDCAxyPtReject->SetStats(kFALSE);
3314 fQASecondaryAntiProtonsRejectedList->Add(gHistSecondaryAntiProtonsFromWeakDCAxyPtReject);
3315 TH2F *gHistSecondaryAntiProtonsFromWeakDCAzPtReject = new TH2F("gHistSecondaryAntiProtonsFromWeakDCAzPtReject",
3316 ";P_{T} [GeV/c];dca_{z} [cm]",
3319 gHistSecondaryAntiProtonsFromWeakDCAzPtReject->SetStats(kFALSE);
3320 fQASecondaryAntiProtonsRejectedList->Add(gHistSecondaryAntiProtonsFromWeakDCAzPtReject);
3321 TH2F *gHistSecondaryAntiProtonsFromHadronicDCAxyPtReject = new TH2F("gHistSecondaryAntiProtonsFromHadronicDCAxyPtReject",
3322 ";P_{T} [GeV/c];dca_{xy} [cm]",
3325 gHistSecondaryAntiProtonsFromHadronicDCAxyPtReject->SetStats(kFALSE);
3326 fQASecondaryAntiProtonsRejectedList->Add(gHistSecondaryAntiProtonsFromHadronicDCAxyPtReject);
3327 TH2F *gHistSecondaryAntiProtonsFromHadronicDCAzPtReject = new TH2F("gHistSecondaryAntiProtonsFromHadronicDCAzPtReject",
3328 ";P_{T} [GeV/c];dca_{z} [cm]",
3331 gHistSecondaryAntiProtonsFromHadronicDCAzPtReject->SetStats(kFALSE);
3332 fQASecondaryAntiProtonsRejectedList->Add(gHistSecondaryAntiProtonsFromHadronicDCAzPtReject);*/
3335 //____________________________________________________________________//
3336 void AliProtonQAAnalysis::RunReconstructionEfficiencyAnalysis(AliMCEvent *const mcEvent,
3338 const AliESDVertex *vertex) {
3339 //Run the reconstruction efficiency code (primaries & secondaries)
3340 AliStack *stack = mcEvent->Stack();
3342 Int_t nMCParticles = mcEvent->GetNumberOfTracks();
3343 Int_t nMCLabelCounter = 0;
3344 TArrayI labelMCArray(nMCParticles);
3346 for (Int_t iTracks = 0; iTracks < mcEvent->GetNumberOfTracks(); iTracks++) {
3347 AliMCParticle *mcTrack = (AliMCParticle*) mcEvent->GetTrack(iTracks);
3349 Printf("ERROR: Could not receive track %d (mc loop)", iTracks);
3353 Double_t vz = mcTrack->Zv();
3354 if (TMath::Abs(vz) > 50.) continue;//exclude particles generated out of the acceptance
3356 if(TMath::Abs(mcTrack->Eta()) > 1.0) continue;//acceptance
3357 if((mcTrack->Pt() > fMaxPt)||(mcTrack->Pt() < fMinPt)) continue;
3358 if(fProtonAnalysisBase->GetEtaMode()) {
3359 if((mcTrack->Eta() > fMaxY)|| (mcTrack->Eta() < fMinY)) continue;
3362 if((fProtonAnalysisBase->Rapidity(mcTrack->Px(),mcTrack->Py(),mcTrack->Pz()) > fMaxY)||(fProtonAnalysisBase->Rapidity(mcTrack->Px(),mcTrack->Py(),mcTrack->Pz()) < fMinY)) continue;
3364 // Loop over Track References
3365 Bool_t labelTPC = kFALSE;
3366 AliTrackReference* trackRef = 0;
3367 for (Int_t iTrackRef = 0; iTrackRef < mcTrack->GetNumberOfTrackReferences(); iTrackRef++) {
3368 trackRef = mcTrack->GetTrackReference(iTrackRef);
3370 Int_t detectorId = trackRef->DetectorId();
3371 if (detectorId == AliTrackReference::kTPC) {
3380 TParticle* particle = mcTrack->Particle();
3381 if(!particle) continue;
3382 Int_t pdgcode = particle->GetPdgCode();
3383 if(TMath::Abs(pdgcode) != 2212) continue;
3385 labelMCArray.AddAt(iTracks,nMCLabelCounter);
3386 nMCLabelCounter += 1;
3388 if(iTracks <= stack->GetNprimary()) {
3389 if(pdgcode == 2212) {
3390 if(fProtonAnalysisBase->GetEtaMode())
3391 ((TH2D *)(fEfficiencyList->At(0)))->Fill(particle->Eta(),
3394 ((TH2D *)(fEfficiencyList->At(0)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3399 if(pdgcode == -2212) {
3400 if(fProtonAnalysisBase->GetEtaMode())
3401 ((TH2D *)(fEfficiencyList->At(1)))->Fill(particle->Eta(),
3404 ((TH2D *)(fEfficiencyList->At(1)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3412 Int_t lPartMother = -1;
3413 Int_t motherPDGCode = -1;
3414 lPartMother = particle->GetFirstMother();
3415 AliMCParticle *mcMotherTrack = (AliMCParticle*) mcEvent->GetTrack(lPartMother);
3416 TParticle *motherParticle = mcMotherTrack->Particle();
3417 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
3419 if(pdgcode == 2212) {
3420 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
3421 if(fProtonAnalysisBase->GetEtaMode())
3422 ((TH2D *)(fEfficiencyList->At(2)))->Fill(particle->Eta(),
3425 ((TH2D *)(fEfficiencyList->At(2)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3430 if((particle->GetUniqueID() == 13)) {
3431 if(fProtonAnalysisBase->GetEtaMode())
3432 ((TH2D *)(fEfficiencyList->At(4)))->Fill(particle->Eta(),
3435 ((TH2D *)(fEfficiencyList->At(4)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3439 }//hadronic interactions
3441 if(pdgcode == -2212) {
3442 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
3443 if(fProtonAnalysisBase->GetEtaMode())
3444 ((TH2D *)(fEfficiencyList->At(3)))->Fill(particle->Eta(),
3447 ((TH2D *)(fEfficiencyList->At(3)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3452 if((particle->GetUniqueID() == 13)) {
3453 if(fProtonAnalysisBase->GetEtaMode())
3454 ((TH2D *)(fEfficiencyList->At(5)))->Fill(particle->Eta(),
3457 ((TH2D *)(fEfficiencyList->At(5)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3461 }//hadronic interactions
3464 //}//findable tracks
3468 Bool_t iFound = kFALSE;
3469 Int_t mcGoods = nMCLabelCounter;
3470 for (Int_t k = 0; k < mcGoods; k++) {
3471 Int_t mcLabel = labelMCArray.At(k);
3474 Int_t nGoodTracks = esd->GetNumberOfTracks();
3475 TArrayI labelArray(nGoodTracks);
3476 Int_t labelCounter = 0;
3477 for(Int_t iTracks = 0; iTracks < nGoodTracks; iTracks++) {
3478 AliESDtrack* track = esd->GetTrack(iTracks);
3479 if(!track) continue;
3482 if((fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kTPC)||(fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kHybrid)) {
3483 AliExternalTrackParam *tpcTrack = (AliExternalTrackParam *)track->GetTPCInnerParam();
3484 if(!tpcTrack) continue;
3486 Int_t label = TMath::Abs(track->GetTPCLabel());
3487 if(IsLabelUsed(labelArray,label)) continue;
3488 labelArray.AddAt(label,labelCounter);
3491 if (mcLabel != TMath::Abs(label)) continue;
3492 if(mcLabel != label) continue;
3493 if(label > stack->GetNtrack()) continue;
3495 TParticle *particle = stack->Particle(label);
3496 if(!particle) continue;
3497 Int_t pdgcode = particle->GetPdgCode();
3498 if(TMath::Abs(particle->Eta()) > 1.0) continue;//acceptance
3499 if((particle->Pt() > fMaxPt)||(particle->Pt() < fMinPt)) continue;
3500 if(fProtonAnalysisBase->GetEtaMode()) {
3501 if((particle->Eta() > fMaxY)|| (particle->Eta() < fMinY)) continue;
3504 if((fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) > fMaxY)||(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) < fMinY)) continue;
3506 if(fUseCutsInEfficiency) {
3507 if(!fProtonAnalysisBase->IsPrimary(esd,vertex,track)) continue;
3508 if(!fProtonAnalysisBase->IsAccepted(track)) continue;
3510 //reconstructed primary (anti)protons
3511 if(pdgcode == 2212) {
3512 if(label <= stack->GetNprimary()) {
3513 if(fProtonAnalysisBase->GetEtaMode())
3514 ((TH2D *)(fEfficiencyList->At(6)))->Fill(particle->Eta(),
3517 ((TH2D *)(fEfficiencyList->At(6)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3522 if(label > stack->GetNprimary()) {
3523 Int_t lPartMother = -1;
3524 Int_t motherPDGCode = -1;
3525 lPartMother = particle->GetFirstMother();
3526 TParticle *motherParticle = stack->Particle(lPartMother);
3527 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
3529 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
3530 if(fProtonAnalysisBase->GetEtaMode())
3531 ((TH2D *)(fEfficiencyList->At(8)))->Fill(particle->Eta(),
3534 ((TH2D *)(fEfficiencyList->At(8)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3539 if((particle->GetUniqueID() == 13)) {
3540 if(fProtonAnalysisBase->GetEtaMode())
3541 ((TH2D *)(fEfficiencyList->At(10)))->Fill(particle->Eta(),
3544 ((TH2D *)(fEfficiencyList->At(10)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3548 }//hadronic interactions
3551 if(pdgcode == -2212) {
3552 if(label <= stack->GetNprimary()) {
3553 if(fProtonAnalysisBase->GetEtaMode())
3554 ((TH2D *)(fEfficiencyList->At(7)))->Fill(particle->Eta(),
3557 ((TH2D *)(fEfficiencyList->At(7)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3562 if(label > stack->GetNprimary()) {
3563 Int_t lPartMother = -1;
3564 Int_t motherPDGCode = -1;
3565 lPartMother = particle->GetFirstMother();
3566 TParticle *motherParticle = stack->Particle(lPartMother);
3567 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
3569 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
3570 if(fProtonAnalysisBase->GetEtaMode())
3571 ((TH2D *)(fEfficiencyList->At(9)))->Fill(particle->Eta(),
3574 ((TH2D *)(fEfficiencyList->At(9)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3579 if((particle->GetUniqueID() == 13)) {
3580 if(fProtonAnalysisBase->GetEtaMode())
3581 ((TH2D *)(fEfficiencyList->At(11)))->Fill(particle->Eta(),
3584 ((TH2D *)(fEfficiencyList->At(11)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3588 }//hadronic interactions
3590 }//initial antiprotons
3593 Int_t label = TMath::Abs(track->GetLabel());
3594 if(IsLabelUsed(labelArray,label)) continue;
3595 labelArray.AddAt(label,labelCounter);
3598 if (mcLabel != TMath::Abs(label)) continue;
3599 if(mcLabel != label) continue;
3600 if(label > stack->GetNtrack()) continue;
3602 TParticle *particle = stack->Particle(label);
3603 if(!particle) continue;
3604 Int_t pdgcode = particle->GetPdgCode();
3605 if(TMath::Abs(particle->Eta()) > 1.0) continue;//acceptance
3606 if((particle->Pt() > fMaxPt)||(particle->Pt() < fMinPt)) continue;
3607 if(fProtonAnalysisBase->GetEtaMode()) {
3608 if((particle->Eta() > fMaxY)|| (particle->Eta() < fMinY)) continue;
3611 if((fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) > fMaxY)||(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) < fMinY)) continue;
3613 //Double_t probability[5];
3615 if(fUseCutsInEfficiency) {
3616 if(!fProtonAnalysisBase->IsPrimary(esd,vertex,track)) continue;
3617 if(!fProtonAnalysisBase->IsAccepted(track)) continue;
3619 //reconstructed primary (anti)protons
3620 if(pdgcode == 2212) {
3621 if(label <= stack->GetNprimary()) {
3622 if(fProtonAnalysisBase->GetEtaMode())
3623 ((TH2D *)(fEfficiencyList->At(6)))->Fill(particle->Eta(),
3626 ((TH2D *)(fEfficiencyList->At(6)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3631 if(label > stack->GetNprimary()) {
3632 Int_t lPartMother = -1;
3633 Int_t motherPDGCode = -1;
3634 lPartMother = particle->GetFirstMother();
3635 TParticle *motherParticle = stack->Particle(lPartMother);
3636 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
3638 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
3639 if(fProtonAnalysisBase->GetEtaMode())
3640 ((TH2D *)(fEfficiencyList->At(8)))->Fill(particle->Eta(),
3643 ((TH2D *)(fEfficiencyList->At(8)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3648 if((particle->GetUniqueID() == 13)) {
3649 if(fProtonAnalysisBase->GetEtaMode())
3650 ((TH2D *)(fEfficiencyList->At(10)))->Fill(particle->Eta(),
3653 ((TH2D *)(fEfficiencyList->At(10)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3657 }//hadronic interactions
3660 if(pdgcode == -2212) {
3661 if(label <= stack->GetNprimary()) {
3662 if(fProtonAnalysisBase->GetEtaMode())
3663 ((TH2D *)(fEfficiencyList->At(7)))->Fill(particle->Eta(),
3666 ((TH2D *)(fEfficiencyList->At(7)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3671 if(label > stack->GetNprimary()) {
3672 Int_t lPartMother = -1;
3673 Int_t motherPDGCode = -1;
3674 lPartMother = particle->GetFirstMother();
3675 TParticle *motherParticle = stack->Particle(lPartMother);
3676 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
3678 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
3679 if(fProtonAnalysisBase->GetEtaMode())
3680 ((TH2D *)(fEfficiencyList->At(9)))->Fill(particle->Eta(),
3683 ((TH2D *)(fEfficiencyList->At(9)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3688 if((particle->GetUniqueID() == 13)) {
3689 if(fProtonAnalysisBase->GetEtaMode())
3690 ((TH2D *)(fEfficiencyList->At(11)))->Fill(particle->Eta(),
3693 ((TH2D *)(fEfficiencyList->At(11)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3697 }//hadronic interactions
3699 }//initial antiprotons
3703 }//loop over findable tracks
3705 labelMCArray.Reset();
3708 //____________________________________________________________________//
3709 void AliProtonQAAnalysis::RunPIDEfficiencyAnalysis(AliStack *const stack,
3711 const AliESDVertex *vertex) {
3712 //Runs the PID efficiency analysis
3713 Int_t nGoodTracks = esd->GetNumberOfTracks();
3714 TArrayI labelArray(nGoodTracks);
3715 Int_t labelCounter = 0;
3716 for(Int_t iTracks = 0; iTracks < nGoodTracks; iTracks++) {
3717 AliESDtrack* track = esd->GetTrack(iTracks);
3718 if(!track) continue;
3721 if((fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kTPC)||(fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kHybrid)) {
3722 AliExternalTrackParam *tpcTrack = (AliExternalTrackParam *)track->GetTPCInnerParam();
3723 if(!tpcTrack) continue;
3726 Int_t label = TMath::Abs(track->GetLabel());
3727 if(IsLabelUsed(labelArray,label)) continue;
3728 labelArray.AddAt(label,labelCounter);
3730 if(label > stack->GetNtrack()) continue;
3732 TParticle *particle = stack->Particle(label);
3733 if(!particle) continue;
3734 Int_t pdgcode = particle->GetPdgCode();
3736 Int_t nTPCpoints = track->GetTPCsignalN();
3738 if(fUseCutsInEfficiency) {
3739 if(!fProtonAnalysisBase->IsPrimary(esd,vertex,track)) continue;
3740 if(!fProtonAnalysisBase->IsAccepted(track)) continue;
3742 if(TMath::Abs(pdgcode) == 2212) {
3743 if(fProtonAnalysisBase->GetEtaMode())
3744 ((TH3D *)(fEfficiencyList->At(12)))->Fill(particle->Eta(),
3745 particle->Pt(),nTPCpoints);
3747 ((TH3D *)(fEfficiencyList->At(12)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()),particle->Pt(),nTPCpoints);
3751 if(fProtonAnalysisBase->IsProton(track)) {
3752 if(fProtonAnalysisBase->GetEtaMode())
3753 ((TH3D *)(fEfficiencyList->At(14)))->Fill(particle->Eta(),
3754 particle->Pt(),nTPCpoints);
3755 else ((TH3D *)(fEfficiencyList->At(14)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()),particle->Pt(),nTPCpoints);
3756 if(TMath::Abs(pdgcode) == 2212) {
3757 if(fProtonAnalysisBase->GetEtaMode())
3758 ((TH3D *)(fEfficiencyList->At(13)))->Fill(particle->Eta(),
3759 particle->Pt(),nTPCpoints);
3761 ((TH3D *)(fEfficiencyList->At(13)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()),particle->Pt(),nTPCpoints);
3762 }//properly identified as proton
3764 if(fProtonAnalysisBase->GetEtaMode())
3765 ((TH3D *)(fEfficiencyList->At(15)))->Fill(particle->Eta(),
3766 particle->Pt(),nTPCpoints);
3768 ((TH3D *)(fEfficiencyList->At(15)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()),particle->Pt(),nTPCpoints);
3770 }//identified as proton
3775 //____________________________________________________________________//
3776 void AliProtonQAAnalysis::RunCutEfficiencyAnalysis(AliStack *const stack,
3778 const AliESDVertex *vertex) {
3779 //Runs the cut efficiency analysis
3780 Int_t nGoodTracks = esd->GetNumberOfTracks();
3781 TArrayI labelArray(nGoodTracks);
3782 Int_t labelCounter = 0;
3783 Int_t nPrimaries = stack->GetNprimary();
3784 for(Int_t iTracks = 0; iTracks < nGoodTracks; iTracks++) {
3785 AliESDtrack* track = esd->GetTrack(iTracks);
3786 if(!track) continue;
3789 if((fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kTPC)||(fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kHybrid)) {
3790 AliExternalTrackParam *tpcTrack = (AliExternalTrackParam *)track->GetTPCInnerParam();
3791 if(!tpcTrack) continue;
3794 Int_t label = TMath::Abs(track->GetLabel());
3795 if(IsLabelUsed(labelArray,label)) continue;
3796 labelArray.AddAt(label,labelCounter);
3798 if(label > stack->GetNtrack()) continue;
3800 TParticle *particle = stack->Particle(label);
3801 if(!particle) continue;
3804 if(label > nPrimaries) continue;
3805 //select identified protons
3806 if(!fProtonAnalysisBase->IsProton(track)) continue;
3808 if(track->Charge() > 0) {
3809 if(fProtonAnalysisBase->GetEtaMode())
3810 ((TH2F *)(fCutEfficiencyList->At(0)))->Fill(particle->Eta(),
3813 ((TH2F *)(fCutEfficiencyList->At(0)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()),particle->Pt());
3816 if(track->Charge() < 0) {
3817 if(fProtonAnalysisBase->GetEtaMode())
3818 ((TH2F *)(fCutEfficiencyList->At(1)))->Fill(particle->Eta(),
3821 ((TH2F *)(fCutEfficiencyList->At(1)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()),particle->Pt());
3825 if(!fProtonAnalysisBase->IsPrimary(esd,vertex,track)) continue;
3826 if(!fProtonAnalysisBase->IsAccepted(track)) continue;
3827 if(track->Charge() > 0) {
3828 if(fProtonAnalysisBase->GetEtaMode())
3829 ((TH2F *)(fCutEfficiencyList->At(2)))->Fill(particle->Eta(),
3832 ((TH2F *)(fCutEfficiencyList->At(2)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()),particle->Pt());
3835 if(track->Charge() < 0) {
3836 if(fProtonAnalysisBase->GetEtaMode())
3837 ((TH2F *)(fCutEfficiencyList->At(3)))->Fill(particle->Eta(),
3840 ((TH2F *)(fCutEfficiencyList->At(3)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()),particle->Pt());
3846 //____________________________________________________________________//
3847 void AliProtonQAAnalysis::RunEfficiencyAnalysis(AliStack *const stack,
3849 const AliESDVertex *vertex) {
3850 //Runs the efficiency code
3852 Int_t nMCProtons = 0, nESDProtons = 0;
3853 for(Int_t iParticle = 0; iParticle < stack->GetNtrack(); iParticle++) {
3854 TParticle *particle = stack->Particle(iParticle);
3855 if(!particle) continue;
3857 if(TMath::Abs(particle->Eta()) > 1.0) continue;//acceptance
3858 if((particle->Pt() > fMaxPt)||(particle->Pt() < fMinPt)) continue;
3859 if(fProtonAnalysisBase->GetEtaMode()) {
3860 if((particle->Eta() > fMaxY)|| (particle->Eta() < fMinY)) continue;
3863 if((fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) > fMaxY)||(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) < fMinY)) continue;
3865 Int_t pdgcode = particle->GetPdgCode();
3866 if(TMath::Abs(pdgcode) != 2212) continue;
3868 if(iParticle <= stack->GetNprimary()) {
3869 if(pdgcode == 2212) {
3871 if(fProtonAnalysisBase->GetEtaMode())
3872 ((TH2D *)(fEfficiencyList->At(0)))->Fill(particle->Eta(),
3875 ((TH2D *)(fEfficiencyList->At(0)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3880 if(pdgcode == -2212) {
3881 if(fProtonAnalysisBase->GetEtaMode())
3882 ((TH2D *)(fEfficiencyList->At(1)))->Fill(particle->Eta(),
3885 ((TH2D *)(fEfficiencyList->At(1)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3893 Int_t lPartMother = -1;
3894 Int_t motherPDGCode = -1;
3895 lPartMother = particle->GetFirstMother();
3896 TParticle *motherParticle = stack->Particle(lPartMother);
3897 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
3899 if(pdgcode == 2212) {
3900 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
3901 if(fProtonAnalysisBase->GetEtaMode())
3902 ((TH2D *)(fEfficiencyList->At(2)))->Fill(particle->Eta(),
3905 ((TH2D *)(fEfficiencyList->At(2)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3910 if((particle->GetUniqueID() == 13)) {
3911 if(fProtonAnalysisBase->GetEtaMode())
3912 ((TH2D *)(fEfficiencyList->At(4)))->Fill(particle->Eta(),
3915 ((TH2D *)(fEfficiencyList->At(4)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3919 }//hadronic interactions
3921 if(pdgcode == -2212) {
3922 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
3923 if(fProtonAnalysisBase->GetEtaMode())
3924 ((TH2D *)(fEfficiencyList->At(3)))->Fill(particle->Eta(),
3927 ((TH2D *)(fEfficiencyList->At(3)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3932 if((particle->GetUniqueID() == 13)) {
3933 if(fProtonAnalysisBase->GetEtaMode())
3934 ((TH2D *)(fEfficiencyList->At(5)))->Fill(particle->Eta(),
3937 ((TH2D *)(fEfficiencyList->At(5)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3941 }//hadronic interactions
3948 Int_t nGoodTracks = esd->GetNumberOfTracks();
3949 TArrayI labelArray(nGoodTracks);
3950 Int_t labelCounter = 0;
3951 for(Int_t iTracks = 0; iTracks < nGoodTracks; iTracks++) {
3952 AliESDtrack* track = esd->GetTrack(iTracks);
3953 if(!track) continue;
3955 Int_t label = TMath::Abs(track->GetLabel());
3956 if(IsLabelUsed(labelArray,label)) continue;
3957 labelArray.AddAt(label,labelCounter);
3959 if(label > stack->GetNtrack()) continue;
3961 TParticle *particle = stack->Particle(label);
3962 if(!particle) continue;
3963 Int_t pdgcode = particle->GetPdgCode();
3964 if(TMath::Abs(particle->Eta()) > 1.0) continue;//acceptance
3966 Double_t gPt = 0.0, gP = 0.0;
3969 if((fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kTPC)||(fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kHybrid)) {
3970 AliExternalTrackParam *tpcTrack = (AliExternalTrackParam *)track->GetTPCInnerParam();
3971 if(!tpcTrack) continue;
3972 gPt = tpcTrack->Pt();
3975 if((particle->Pt() > fMaxPt)||(particle->Pt() < fMinPt)) continue;
3976 if(fProtonAnalysisBase->GetEtaMode()) {
3977 if((particle->Eta() > fMaxY)|| (particle->Eta() < fMinY)) continue;
3980 if((fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) > fMaxY)||(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) < fMinY)) continue;
3982 if(fUseCutsInEfficiency) {
3983 if(!fProtonAnalysisBase->IsPrimary(esd,vertex,track)) continue;
3984 if(!fProtonAnalysisBase->IsAccepted(track)) continue;
3986 //reconstructed primary (anti)protons
3987 if(pdgcode == 2212) {
3988 if(label <= stack->GetNprimary()) {
3990 if(fProtonAnalysisBase->GetEtaMode())
3991 ((TH2D *)(fEfficiencyList->At(6)))->Fill(particle->Eta(),
3994 ((TH2D *)(fEfficiencyList->At(6)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
3999 if(label > stack->GetNprimary()) {
4000 Int_t lPartMother = -1;
4001 Int_t motherPDGCode = -1;
4002 lPartMother = particle->GetFirstMother();
4003 TParticle *motherParticle = stack->Particle(lPartMother);
4004 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
4006 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
4007 if(fProtonAnalysisBase->GetEtaMode())
4008 ((TH2D *)(fEfficiencyList->At(8)))->Fill(particle->Eta(),
4011 ((TH2D *)(fEfficiencyList->At(8)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4016 if((particle->GetUniqueID() == 13)) {
4017 if(fProtonAnalysisBase->GetEtaMode())
4018 ((TH2D *)(fEfficiencyList->At(10)))->Fill(particle->Eta(),
4021 ((TH2D *)(fEfficiencyList->At(10)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4025 }//hadronic interactions
4028 if(pdgcode == -2212) {
4029 if(label <= stack->GetNprimary()) {
4030 if(fProtonAnalysisBase->GetEtaMode())
4031 ((TH2D *)(fEfficiencyList->At(7)))->Fill(particle->Eta(),
4034 ((TH2D *)(fEfficiencyList->At(7)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4039 if(label > stack->GetNprimary()) {
4040 Int_t lPartMother = -1;
4041 Int_t motherPDGCode = -1;
4042 lPartMother = particle->GetFirstMother();
4043 TParticle *motherParticle = stack->Particle(lPartMother);
4044 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
4046 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
4047 if(fProtonAnalysisBase->GetEtaMode())
4048 ((TH2D *)(fEfficiencyList->At(9)))->Fill(particle->Eta(),
4051 ((TH2D *)(fEfficiencyList->At(9)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4056 if((particle->GetUniqueID() == 13)) {
4057 if(fProtonAnalysisBase->GetEtaMode())
4058 ((TH2D *)(fEfficiencyList->At(11)))->Fill(particle->Eta(),
4061 ((TH2D *)(fEfficiencyList->At(11)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4065 }//hadronic interactions
4067 }//initial antiprotons
4070 if((particle->Pt() > fMaxPt)||(particle->Pt() < fMinPt)) continue;
4071 if(fProtonAnalysisBase->GetEtaMode()) {
4072 if((particle->Eta() > fMaxY)|| (particle->Eta() < fMinY)) continue;
4075 if((fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) > fMaxY)||(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) < fMinY)) continue;
4078 if(fUseCutsInEfficiency) {
4079 if(!fProtonAnalysisBase->IsPrimary(esd,vertex,track)) continue;
4080 if(!fProtonAnalysisBase->IsAccepted(track)) continue;
4082 //reconstructed primary (anti)protons
4083 if(pdgcode == 2212) {
4084 if(label <= stack->GetNprimary()) {
4086 if(fProtonAnalysisBase->GetEtaMode())
4087 ((TH2D *)(fEfficiencyList->At(6)))->Fill(particle->Eta(),
4090 ((TH2D *)(fEfficiencyList->At(6)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4095 if(label > stack->GetNprimary()) {
4096 Int_t lPartMother = -1;
4097 Int_t motherPDGCode = -1;
4098 lPartMother = particle->GetFirstMother();
4099 TParticle *motherParticle = stack->Particle(lPartMother);
4100 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
4102 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
4103 if(fProtonAnalysisBase->GetEtaMode())
4104 ((TH2D *)(fEfficiencyList->At(8)))->Fill(particle->Eta(),
4107 ((TH2D *)(fEfficiencyList->At(8)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4112 if((particle->GetUniqueID() == 13)) {
4113 if(fProtonAnalysisBase->GetEtaMode())
4114 ((TH2D *)(fEfficiencyList->At(10)))->Fill(particle->Eta(),
4117 ((TH2D *)(fEfficiencyList->At(10)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4121 }//hadronic interactions
4124 if(pdgcode == -2212) {
4125 if(fProtonAnalysisBase->GetEtaMode())
4126 ((TH2D *)(fEfficiencyList->At(12)))->Fill(particle->Eta(),
4129 ((TH2D *)(fEfficiencyList->At(12)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4133 if(label <= stack->GetNprimary()) {
4134 if(fProtonAnalysisBase->GetEtaMode())
4135 ((TH2D *)(fEfficiencyList->At(7)))->Fill(particle->Eta(),
4138 ((TH2D *)(fEfficiencyList->At(7)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4143 if(label > stack->GetNprimary()) {
4144 Int_t lPartMother = -1;
4145 Int_t motherPDGCode = -1;
4146 lPartMother = particle->GetFirstMother();
4147 TParticle *motherParticle = stack->Particle(lPartMother);
4148 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
4150 if((particle->GetUniqueID() == 4)&&(TMath::Abs(motherPDGCode) == 3122)) {
4151 if(fProtonAnalysisBase->GetEtaMode())
4152 ((TH2D *)(fEfficiencyList->At(9)))->Fill(particle->Eta(),
4155 ((TH2D *)(fEfficiencyList->At(9)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4160 if((particle->GetUniqueID() == 13)) {
4161 if(fProtonAnalysisBase->GetEtaMode())
4162 ((TH2D *)(fEfficiencyList->At(11)))->Fill(particle->Eta(),
4165 ((TH2D *)(fEfficiencyList->At(11)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4169 }//hadronic interactions
4171 }//initial antiprotons
4175 //Printf("MC protons: %d - ESD protons: %d",nMCProtons,nESDProtons);
4178 //____________________________________________________________________//
4179 Bool_t AliProtonQAAnalysis::IsLabelUsed(TArrayI labelArray,
4181 //Checks if the label is used already
4182 Bool_t status = kFALSE;
4183 for(Int_t i = 0; i < labelArray.GetSize(); i++) {
4184 if(labelArray.At(i) == label)
4191 //____________________________________________________________________//
4192 void AliProtonQAAnalysis::RunVertexQA(AliGenEventHeader *header,
4193 AliESDEvent *const esd) {
4194 //Runs the vertex QA
4196 TArrayF primaryVertex(3);
4197 header->PrimaryVertex(primaryVertex);
4199 //Int_t nPrimaries = stack->GetNprimary();
4200 ((TH1F *)(fQAVertexList->At(0)))->Fill(primaryVertex[2]);
4203 const AliESDVertex *vertexTPC = esd->GetPrimaryVertexTPC();
4205 Printf("ERROR: Could not retrieve the TPC vertex");
4208 if(vertexTPC->GetNContributors() > 0) {
4209 ((TH1F *)(fQAVertexList->At(1)))->Fill(primaryVertex[2]);
4210 ((TH2F *)(fQAVertexList->At(2)))->Fill(vertexTPC->GetXv(),
4211 vertexTPC->GetNContributors());
4212 ((TH2F *)(fQAVertexList->At(3)))->Fill(vertexTPC->GetYv(),
4213 vertexTPC->GetNContributors());
4214 ((TH2F *)(fQAVertexList->At(4)))->Fill(vertexTPC->GetZv(),
4215 vertexTPC->GetNContributors());
4216 ((TH1F *)(fQAVertexList->At(5)))->Fill((vertexTPC->GetXv()-primaryVertex[0])*10000.);
4217 ((TH1F *)(fQAVertexList->At(6)))->Fill((vertexTPC->GetYv()-primaryVertex[1])*10000.);
4218 ((TH1F *)(fQAVertexList->At(7)))->Fill((vertexTPC->GetZv()-primaryVertex[2])*10000.);
4219 ((TH1F *)(fQAVertexList->At(8)))->Fill(vertexTPC->GetXRes()*10000.);
4220 ((TH1F *)(fQAVertexList->At(9)))->Fill(vertexTPC->GetYRes()*10000.);
4221 ((TH1F *)(fQAVertexList->At(10)))->Fill(vertexTPC->GetZRes()*10000.);
4225 const AliESDVertex *vertexSPD = esd->GetPrimaryVertexSPD();
4227 Printf("ERROR: Could not retrieve the SPD vertex");
4230 if(vertexSPD->GetNContributors() > 0) {
4231 ((TH1F *)(fQAVertexList->At(11)))->Fill(primaryVertex[2]);
4232 ((TH2F *)(fQAVertexList->At(12)))->Fill(vertexSPD->GetXv(),
4233 vertexSPD->GetNContributors());
4234 ((TH2F *)(fQAVertexList->At(13)))->Fill(vertexSPD->GetYv(),
4235 vertexSPD->GetNContributors());
4236 ((TH2F *)(fQAVertexList->At(14)))->Fill(vertexSPD->GetZv(),
4237 vertexSPD->GetNContributors());
4238 ((TH1F *)(fQAVertexList->At(15)))->Fill((vertexSPD->GetXv()-primaryVertex[0])*10000.);
4239 ((TH1F *)(fQAVertexList->At(16)))->Fill((vertexSPD->GetYv()-primaryVertex[1])*10000.);
4240 ((TH1F *)(fQAVertexList->At(17)))->Fill((vertexSPD->GetZv()-primaryVertex[2])*10000.);
4241 ((TH1F *)(fQAVertexList->At(18)))->Fill(vertexSPD->GetXRes()*10000.);
4242 ((TH1F *)(fQAVertexList->At(19)))->Fill(vertexSPD->GetYRes()*10000.);
4243 ((TH1F *)(fQAVertexList->At(20)))->Fill(vertexSPD->GetZRes()*10000.);
4247 const AliESDVertex *vertexTracks = esd->GetPrimaryVertex();
4249 Printf("ERROR: Could not retrieve the Tracks vertex");
4252 if(vertexTracks->GetNContributors() > 0) {
4253 ((TH1F *)(fQAVertexList->At(21)))->Fill(primaryVertex[2]);
4254 ((TH2F *)(fQAVertexList->At(22)))->Fill(vertexTracks->GetXv(),
4255 vertexTracks->GetNContributors());
4256 ((TH2F *)(fQAVertexList->At(23)))->Fill(vertexTracks->GetYv(),
4257 vertexTracks->GetNContributors());
4258 ((TH2F *)(fQAVertexList->At(24)))->Fill(vertexTracks->GetZv(),
4259 vertexTracks->GetNContributors());
4260 ((TH1F *)(fQAVertexList->At(25)))->Fill((vertexTracks->GetXv()-primaryVertex[0])*10000.);
4261 ((TH1F *)(fQAVertexList->At(26)))->Fill((vertexTracks->GetYv()-primaryVertex[1])*10000.);
4262 ((TH1F *)(fQAVertexList->At(27)))->Fill((vertexTracks->GetZv()-primaryVertex[2])*10000.);
4263 ((TH1F *)(fQAVertexList->At(28)))->Fill(vertexTracks->GetXRes()*10000.);
4264 ((TH1F *)(fQAVertexList->At(29)))->Fill(vertexTracks->GetYRes()*10000.);
4265 ((TH1F *)(fQAVertexList->At(30)))->Fill(vertexTracks->GetZRes()*10000.);
4270 //____________________________________________________________________//
4271 void AliProtonQAAnalysis::RunQAAnalysis(AliStack *stack,
4273 const AliESDVertex *vertex) {
4276 for(Int_t iParticle = 0; iParticle < stack->GetNprimary(); iParticle++) {
4277 TParticle *particle = stack->Particle(iParticle);
4278 if(!particle) continue;
4280 if(TMath::Abs(particle->Eta()) > 1.0) continue;//acceptance
4281 if((particle->Pt() > fMaxPt)||(particle->Pt() < fMinPt)) continue;
4282 if(fProtonAnalysisBase->GetEtaMode()) {
4283 if((particle->Eta() > fMaxY)||(particle->Eta() < fMinY)) continue;
4286 if((fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) > fMaxY)||(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) < fMinY)) continue;
4288 Int_t pdgcode = particle->GetPdgCode();
4289 if(pdgcode == 2212) {
4290 if(fProtonAnalysisBase->GetEtaMode())
4291 ((TH2D *)(fQA2DList->At(8)))->Fill(particle->Eta(),
4294 ((TH2D *)(fQA2DList->At(8)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4299 if(pdgcode == -2212) {
4300 if(fProtonAnalysisBase->GetEtaMode())
4301 ((TH2D *)(fQA2DList->At(9)))->Fill(particle->Eta(),
4304 ((TH2D *)(fQA2DList->At(9)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
4311 Double_t dca[2] = {0.0,0.0}, cov[3] = {0.0,0.0,0.0};
4313 Int_t nGoodTracks = esd->GetNumberOfTracks();
4314 TArrayI labelArray(nGoodTracks);
4315 Int_t labelCounter = 0;
4316 for(Int_t iTracks = 0; iTracks < nGoodTracks; iTracks++) {
4317 AliESDtrack* track = esd->GetTrack(iTracks);
4318 if(!track) continue;
4320 Int_t label = TMath::Abs(track->GetLabel());
4321 if(IsLabelUsed(labelArray,label)) continue;
4322 labelArray.AddAt(label,labelCounter);
4324 if(label > stack->GetNtrack()) continue;
4326 TParticle *particle = stack->Particle(label);
4327 if(!particle) continue;
4328 if(TMath::Abs(particle->Eta()) > 1.0) continue;//acceptance
4330 AliESDtrack trackTPC;
4332 //in case it's a TPC only track relate it to the proper vertex
4333 //if((fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kTPC)&&(!fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kHybrid)) {
4334 //if((fUseTPCOnly)&&(!fUseHybridTPC)) {
4335 /*track->GetImpactParametersTPC(dca,cov);
4336 if (dca[0]==0 && dca[1]==0)
4337 track->RelateToVertexTPC(((AliESDEvent*)esd)->GetPrimaryVertexTPC(),esd->GetMagneticField(),kVeryBig);
4338 if (!track->FillTPCOnlyTrack(trackTPC)) {
4341 track = &trackTPC ;*/
4344 Double_t gPt = 0.0, gP = 0.0;
4345 //Double_t probability[5];
4346 //Float_t dcaXY = 0.0, dcaZ = 0.0;
4347 Double_t nSigmaToVertex = fProtonAnalysisBase->GetSigmaToVertex(track);
4349 Int_t nClustersITS = track->GetITSclusters(fIdxInt);
4350 Int_t nClustersTPC = track->GetTPCclusters(fIdxInt);
4352 Float_t chi2PerClusterITS = -1;
4353 if (nClustersITS!=0)
4354 chi2PerClusterITS = track->GetITSchi2()/Float_t(nClustersITS);
4355 Float_t chi2PerClusterTPC = -1;
4356 if (nClustersTPC!=0)
4357 chi2PerClusterTPC = track->GetTPCchi2()/Float_t(nClustersTPC);
4358 Double_t chi2ConstrainVertex = TMath::Log(track->GetConstrainedChi2());
4359 Double_t extCov[15];
4360 track->GetExternalCovariance(extCov);
4361 Int_t npointsTPCdEdx = track->GetTPCsignalN();
4364 if((fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kTPC)||(fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kHybrid)) {
4365 AliExternalTrackParam *tpcTrack = (AliExternalTrackParam *)track->GetTPCInnerParam();
4366 if(!tpcTrack) continue;
4367 gPt = tpcTrack->Pt();
4369 /*if(fProtonAnalysisBase->GetAnalysisMode()==AliProtonAnalysisBase::kHybrid)
4370 track->GetImpactParameters(dcaXY,dcaZ);
4371 else track->GetImpactParametersTPC(dcaXY,dcaZ);*/
4372 tpcTrack->PropagateToDCA(vertex,
4373 esd->GetMagneticField(),
4377 if(fProtonAnalysisBase->IsProton(track)) {
4378 if(!fProtonAnalysisBase->IsInPhaseSpace(track)) continue; //track outside the analyzed y-Pt
4380 FillQA(stack,esd,vertex,track);
4381 if(fProtonAnalysisBase->IsPrimary(esd,vertex,track)) {
4382 if(fProtonAnalysisBase->IsAccepted(track)) {
4383 if(label <= stack->GetNprimary()) {
4384 if(track->Charge() > 0) {
4385 for(Int_t iLayer = 0; iLayer < 6; iLayer++) {
4386 if(track->HasPointOnITSLayer(iLayer))
4387 ((TH1F *)(fAcceptedCutList->At(0)))->Fill(iLayer+1);
4389 ((TH1F *)(fAcceptedCutList->At(4)))->Fill(nClustersITS);
4390 ((TH1F *)(fAcceptedCutList->At(8)))->Fill(chi2PerClusterITS);
4391 ((TH1F *)(fAcceptedCutList->At(12)))->Fill(chi2ConstrainVertex);
4392 ((TH1F *)(fAcceptedCutList->At(16)))->Fill(nClustersTPC);
4393 ((TH1F *)(fAcceptedCutList->At(20)))->Fill(chi2PerClusterTPC);
4394 ((TH1F *)(fAcceptedCutList->At(24)))->Fill(extCov[0]);
4395 ((TH1F *)(fAcceptedCutList->At(28)))->Fill(extCov[2]);
4396 ((TH1F *)(fAcceptedCutList->At(32)))->Fill(extCov[5]);
4397 ((TH1F *)(fAcceptedCutList->At(36)))->Fill(extCov[9]);
4398 ((TH1F *)(fAcceptedCutList->At(40)))->Fill(extCov[14]);
4399 ((TH3D *)(fAcceptedCutList->At(44)))->Fill(tpcTrack->Eta(),
4400 tpcTrack->Phi()*180./TMath::Pi(),
4402 ((TH3D *)(fAcceptedCutList->At(48)))->Fill(tpcTrack->Eta(),
4403 tpcTrack->Phi()*180./TMath::Pi(),
4405 ((TH3D *)(fAcceptedCutList->At(52)))->Fill(tpcTrack->Eta(),
4406 tpcTrack->Phi()*180./TMath::Pi(),
4408 ((TH1D *)(fAcceptedCutList->At(56)))->Fill(npointsTPCdEdx);
4410 ((TH1F *)(fAcceptedDCAList->At(0)))->Fill(TMath::Abs(dca[0]));
4411 ((TH1F *)(fAcceptedDCAList->At(4)))->Fill(TMath::Abs(dca[1]));
4412 ((TH1F *)(fAcceptedDCAList->At(8)))->Fill(nSigmaToVertex);
4413 ((TH3F *)(fAcceptedDCAList->At(12)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[0]));
4414 ((TH3F *)(fAcceptedDCAList->At(18)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[1]));
4415 if(fProtonAnalysisBase->GetEtaMode())
4416 ((TH2D *)(fQA2DList->At(0)))->Fill(tpcTrack->Eta(),gPt);
4418 ((TH2D *)(fQA2DList->At(0)))->Fill(fProtonAnalysisBase->Rapidity(tpcTrack->Px(),
4422 }//accepted primary protons
4423 else if(track->Charge() < 0) {
4424 for(Int_t iLayer = 0; iLayer < 6; iLayer++) {
4425 if(track->HasPointOnITSLayer(iLayer))
4426 ((TH1F *)(fAcceptedCutList->At(1)))->Fill(iLayer+1);
4428 ((TH1F *)(fAcceptedCutList->At(5)))->Fill(nClustersITS);
4429 ((TH1F *)(fAcceptedCutList->At(9)))->Fill(chi2PerClusterITS);
4430 ((TH1F *)(fAcceptedCutList->At(13)))->Fill(chi2ConstrainVertex);
4431 ((TH1F *)(fAcceptedCutList->At(17)))->Fill(nClustersTPC);
4432 ((TH1F *)(fAcceptedCutList->At(21)))->Fill(chi2PerClusterTPC);
4433 ((TH1F *)(fAcceptedCutList->At(25)))->Fill(extCov[0]);
4434 ((TH1F *)(fAcceptedCutList->At(29)))->Fill(extCov[2]);
4435 ((TH1F *)(fAcceptedCutList->At(33)))->Fill(extCov[5]);
4436 ((TH1F *)(fAcceptedCutList->At(37)))->Fill(extCov[9]);
4437 ((TH1F *)(fAcceptedCutList->At(41)))->Fill(extCov[14]);
4438 ((TH3D *)(fAcceptedCutList->At(45)))->Fill(tpcTrack->Eta(),
4439 tpcTrack->Phi()*180./TMath::Pi(),
4441 ((TH3D *)(fAcceptedCutList->At(49)))->Fill(tpcTrack->Eta(),
4442 tpcTrack->Phi()*180./TMath::Pi(),
4444 ((TH3D *)(fAcceptedCutList->At(53)))->Fill(tpcTrack->Eta(),
4445 tpcTrack->Phi()*180./TMath::Pi(),
4447 ((TH1D *)(fAcceptedCutList->At(57)))->Fill(npointsTPCdEdx);
4449 ((TH1F *)(fAcceptedDCAList->At(1)))->Fill(TMath::Abs(dca[0]));
4450 ((TH1F *)(fAcceptedDCAList->At(5)))->Fill(TMath::Abs(dca[1]));
4451 ((TH1F *)(fAcceptedDCAList->At(9)))->Fill(nSigmaToVertex);
4452 ((TH3F *)(fAcceptedDCAList->At(13)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[0]));
4453 ((TH3F *)(fAcceptedDCAList->At(19)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[1]));
4454 if(fProtonAnalysisBase->GetEtaMode())
4455 ((TH2D *)(fQA2DList->At(4)))->Fill(tpcTrack->Eta(),gPt);
4457 ((TH2D *)(fQA2DList->At(4)))->Fill(fProtonAnalysisBase->Rapidity(tpcTrack->Px(),
4461 }//accepted primary antiprotons
4462 }//accepted primary particles
4463 else if(label > stack->GetNprimary()) {
4464 Int_t lPartMother = -1;
4465 Int_t motherPDGCode = -1;
4467 lPartMother = particle->GetFirstMother();
4468 TParticle *motherParticle = stack->Particle(lPartMother);
4469 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
4472 if(fMCProcessIdFlag)
4473 if(particle->GetUniqueID() != fMCProcessId) continue;
4474 if(fMotherParticlePDGCodeFlag)
4475 if(TMath::Abs(motherPDGCode) != fMotherParticlePDGCode) continue;
4477 if(track->Charge() > 0) {
4478 for(Int_t iLayer = 0; iLayer < 6; iLayer++) {
4479 if(track->HasPointOnITSLayer(iLayer))
4480 ((TH1F *)(fAcceptedCutList->At(2)))->Fill(iLayer+1);
4482 ((TH1F *)(fAcceptedCutList->At(6)))->Fill(nClustersITS);
4483 ((TH1F *)(fAcceptedCutList->At(10)))->Fill(chi2PerClusterITS);
4484 ((TH1F *)(fAcceptedCutList->At(14)))->Fill(chi2ConstrainVertex);
4485 ((TH1F *)(fAcceptedCutList->At(18)))->Fill(nClustersTPC);
4486 ((TH1F *)(fAcceptedCutList->At(22)))->Fill(chi2PerClusterTPC);
4487 ((TH1F *)(fAcceptedCutList->At(26)))->Fill(extCov[0]);
4488 ((TH1F *)(fAcceptedCutList->At(30)))->Fill(extCov[2]);
4489 ((TH1F *)(fAcceptedCutList->At(34)))->Fill(extCov[5]);
4490 ((TH1F *)(fAcceptedCutList->At(38)))->Fill(extCov[9]);
4491 ((TH1F *)(fAcceptedCutList->At(42)))->Fill(extCov[14]);
4492 ((TH3D *)(fAcceptedCutList->At(46)))->Fill(tpcTrack->Eta(),
4493 tpcTrack->Phi()*180./TMath::Pi(),
4495 ((TH3D *)(fAcceptedCutList->At(50)))->Fill(tpcTrack->Eta(),
4496 tpcTrack->Phi()*180./TMath::Pi(),
4498 ((TH3D *)(fAcceptedCutList->At(54)))->Fill(tpcTrack->Eta(),
4499 tpcTrack->Phi()*180./TMath::Pi(),
4501 ((TH1D *)(fAcceptedCutList->At(58)))->Fill(npointsTPCdEdx);
4503 ((TH1F *)(fAcceptedDCAList->At(2)))->Fill(TMath::Abs(dca[0]));
4504 ((TH1F *)(fAcceptedDCAList->At(6)))->Fill(TMath::Abs(dca[1]));
4505 ((TH1F *)(fAcceptedDCAList->At(10)))->Fill(nSigmaToVertex);
4506 if(particle->GetUniqueID() == 4) {
4507 ((TH3F *)(fAcceptedDCAList->At(14)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[0]));
4508 ((TH3F *)(fAcceptedDCAList->At(20)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[1]));
4510 if(particle->GetUniqueID() == 13) {
4511 ((TH3F *)(fAcceptedDCAList->At(16)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[0]));
4512 ((TH3F *)(fAcceptedDCAList->At(22)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[1]));
4514 if(fProtonAnalysisBase->GetEtaMode())
4515 ((TH2D *)(fQA2DList->At(2)))->Fill(tpcTrack->Eta(),gPt);
4517 ((TH2D *)(fQA2DList->At(2)))->Fill(fProtonAnalysisBase->Rapidity(tpcTrack->Px(),
4521 if(fProtonAnalysisBase->GetEtaMode())
4522 ((TH3F *)(fQA2DList->At(10)))->Fill(tpcTrack->Eta(),gPt,
4523 ConvertPDGToInt(motherPDGCode));
4525 ((TH3F *)(fQA2DList->At(10)))->Fill(fProtonAnalysisBase->Rapidity(tpcTrack->Px(),
4529 ConvertPDGToInt(motherPDGCode));
4530 }//accepted secondary protons
4531 else if(track->Charge() < 0) {
4532 for(Int_t iLayer = 0; iLayer < 6; iLayer++) {
4533 if(track->HasPointOnITSLayer(iLayer))
4534 ((TH1F *)(fAcceptedCutList->At(3)))->Fill(iLayer+1);
4536 ((TH1F *)(fAcceptedCutList->At(7)))->Fill(nClustersITS);
4537 ((TH1F *)(fAcceptedCutList->At(11)))->Fill(chi2PerClusterITS);
4538 ((TH1F *)(fAcceptedCutList->At(15)))->Fill(chi2ConstrainVertex);
4539 ((TH1F *)(fAcceptedCutList->At(19)))->Fill(nClustersTPC);
4540 ((TH1F *)(fAcceptedCutList->At(23)))->Fill(chi2PerClusterTPC);
4541 ((TH1F *)(fAcceptedCutList->At(27)))->Fill(extCov[0]);
4542 ((TH1F *)(fAcceptedCutList->At(31)))->Fill(extCov[2]);
4543 ((TH1F *)(fAcceptedCutList->At(35)))->Fill(extCov[5]);
4544 ((TH1F *)(fAcceptedCutList->At(39)))->Fill(extCov[9]);
4545 ((TH1F *)(fAcceptedCutList->At(43)))->Fill(extCov[14]);
4546 ((TH3D *)(fAcceptedCutList->At(47)))->Fill(tpcTrack->Eta(),
4547 tpcTrack->Phi()*180./TMath::Pi(),
4549 ((TH3D *)(fAcceptedCutList->At(51)))->Fill(tpcTrack->Eta(),
4550 tpcTrack->Phi()*180./TMath::Pi(),
4552 ((TH3D *)(fAcceptedCutList->At(55)))->Fill(tpcTrack->Eta(),
4553 tpcTrack->Phi()*180./TMath::Pi(),
4555 ((TH1F *)(fAcceptedCutList->At(59)))->Fill(npointsTPCdEdx);
4557 ((TH1F *)(fAcceptedDCAList->At(3)))->Fill(TMath::Abs(dca[0]));
4558 ((TH1F *)(fAcceptedDCAList->At(7)))->Fill(TMath::Abs(dca[1]));
4559 ((TH1F *)(fAcceptedDCAList->At(11)))->Fill(nSigmaToVertex);
4560 if(particle->GetUniqueID() == 4) {
4561 ((TH3F *)(fAcceptedDCAList->At(15)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[0]));
4562 ((TH3F *)(fAcceptedDCAList->At(21)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[1]));
4564 if(particle->GetUniqueID() == 13) {
4565 ((TH3F *)(fAcceptedDCAList->At(17)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[0]));
4566 ((TH3F *)(fAcceptedDCAList->At(23)))->Fill(tpcTrack->Eta(),gPt,TMath::Abs(dca[1]));
4568 if(fProtonAnalysisBase->GetEtaMode())
4569 ((TH2D *)(fQA2DList->At(6)))->Fill(tpcTrack->Eta(),gPt);
4571 ((TH2D *)(fQA2DList->At(6)))->Fill(fProtonAnalysisBase->Rapidity(tpcTrack->Px(),
4575 if(fProtonAnalysisBase->GetEtaMode())
4576 ((TH3F *)(fQA2DList->At(11)))->Fill(tpcTrack->Eta(),gPt,
4577 ConvertPDGToInt(motherPDGCode));
4579 ((TH3F *)(fQA2DList->At(11)))->Fill(fProtonAnalysisBase->Rapidity(tpcTrack->Px(),
4583 ConvertPDGToInt(motherPDGCode));
4584 }//accepted secondary antiprotons
4585 }//accepted secondary particles
4586 }//accepted - track cuts
4589 if(label <= stack->GetNprimary()) {
4590 if(track->Charge() > 0) {
4591 ((TH3D *)(fRejectedCutList->At(0)))->Fill(tpcTrack->Eta(),
4592 tpcTrack->Phi()*180./TMath::Pi(),
4594 ((TH3D *)(fRejectedCutList->At(4)))->Fill(tpcTrack->Eta(),
4595 tpcTrack->Phi()*180./TMath::Pi(),
4597 ((TH3D *)(fRejectedCutList->At(8)))->Fill(tpcTrack->Eta(),
4598 tpcTrack->Phi()*180./TMath::Pi(),
4601 if(fProtonAnalysisBase->GetEtaMode())
4602 ((TH2D *)(fQA2DList->At(1)))->Fill(tpcTrack->Eta(),gPt);
4604 ((TH2D *)(fQA2DList->At(1)))->Fill(fProtonAnalysisBase->Rapidity(tpcTrack->Px(),
4609 else if(track->Charge() < 0) {
4610 ((TH3D *)(fRejectedCutList->At(1)))->Fill(tpcTrack->Eta(),
4611 tpcTrack->Phi()*180./TMath::Pi(),
4613 ((TH3D *)(fRejectedCutList->At(5)))->Fill(tpcTrack->Eta(),
4614 tpcTrack->Phi()*180./TMath::Pi(),
4616 ((TH3D *)(fRejectedCutList->At(9)))->Fill(tpcTrack->Eta(),
4617 tpcTrack->Phi()*180./TMath::Pi(),
4619 if(fProtonAnalysisBase->GetEtaMode())
4620 ((TH2D *)(fQA2DList->At(5)))->Fill(tpcTrack->Eta(),gPt);
4622 ((TH2D *)(fQA2DList->At(5)))->Fill(fProtonAnalysisBase->Rapidity(tpcTrack->Px(),
4627 }//rejected primary particles
4628 else if(label > stack->GetNprimary()) {
4629 if(track->Charge() > 0) {
4630 ((TH3D *)(fRejectedCutList->At(2)))->Fill(tpcTrack->Eta(),
4631 tpcTrack->Phi()*180./TMath::Pi(),
4633 ((TH3D *)(fRejectedCutList->At(6)))->Fill(tpcTrack->Eta(),
4634 tpcTrack->Phi()*180./TMath::Pi(),
4636 ((TH3D *)(fRejectedCutList->At(10)))->Fill(tpcTrack->Eta(),
4637 tpcTrack->Phi()*180./TMath::Pi(),
4639 if(fProtonAnalysisBase->GetEtaMode())
4640 ((TH2D *)(fQA2DList->At(3)))->Fill(tpcTrack->Eta(),gPt);
4642 ((TH2D *)(fQA2DList->At(3)))->Fill(fProtonAnalysisBase->Rapidity(tpcTrack->Px(),
4647 else if(track->Charge() < 0) {
4648 ((TH3D *)(fRejectedCutList->At(3)))->Fill(tpcTrack->Eta(),
4649 tpcTrack->Phi()*180./TMath::Pi(),
4651 ((TH3D *)(fRejectedCutList->At(7)))->Fill(tpcTrack->Eta(),
4652 tpcTrack->Phi()*180./TMath::Pi(),
4654 ((TH3D *)(fRejectedCutList->At(11)))->Fill(tpcTrack->Eta(),
4655 tpcTrack->Phi()*180./TMath::Pi(),
4658 if(fProtonAnalysisBase->GetEtaMode())
4659 ((TH2D *)(fQA2DList->At(7)))->Fill(tpcTrack->Eta(),gPt);
4661 ((TH2D *)(fQA2DList->At(7)))->Fill(fProtonAnalysisBase->Rapidity(tpcTrack->Px(),
4666 }//rejected secondary particles
4667 }//rejected - track cuts
4674 track->PropagateToDCA(vertex,
4675 esd->GetMagneticField(),
4679 if(fProtonAnalysisBase->IsProton(track)) {
4680 if(!fProtonAnalysisBase->IsInPhaseSpace(track)) continue; //track outside the analyzed y-Pt
4682 FillQA(stack,esd,vertex,track);
4683 if(fProtonAnalysisBase->IsPrimary(esd,vertex,track)) {
4684 if(fProtonAnalysisBase->IsAccepted(track)) {
4685 if(label <= stack->GetNprimary()) {
4686 if(track->Charge() > 0) {
4687 for(Int_t iLayer = 0; iLayer < 6; iLayer++) {
4688 if(track->HasPointOnITSLayer(iLayer))
4689 ((TH1F *)(fAcceptedCutList->At(0)))->Fill(iLayer+1);
4691 ((TH1F *)(fAcceptedCutList->At(4)))->Fill(nClustersITS);
4692 ((TH1F *)(fAcceptedCutList->At(8)))->Fill(chi2PerClusterITS);
4693 ((TH1F *)(fAcceptedCutList->At(12)))->Fill(chi2ConstrainVertex);
4694 ((TH1F *)(fAcceptedCutList->At(16)))->Fill(nClustersTPC);
4695 ((TH1F *)(fAcceptedCutList->At(20)))->Fill(chi2PerClusterTPC);
4696 ((TH1F *)(fAcceptedCutList->At(24)))->Fill(extCov[0]);
4697 ((TH1F *)(fAcceptedCutList->At(28)))->Fill(extCov[2]);
4698 ((TH1F *)(fAcceptedCutList->At(32)))->Fill(extCov[5]);
4699 ((TH1F *)(fAcceptedCutList->At(36)))->Fill(extCov[9]);
4700 ((TH1F *)(fAcceptedCutList->At(40)))->Fill(extCov[14]);
4701 ((TH3D *)(fAcceptedCutList->At(44)))->Fill(track->Eta(),
4702 track->Phi()*180./TMath::Pi(),
4704 ((TH3D *)(fAcceptedCutList->At(48)))->Fill(track->Eta(),
4705 track->Phi()*180./TMath::Pi(),
4707 ((TH3D *)(fAcceptedCutList->At(52)))->Fill(track->Eta(),
4708 track->Phi()*180./TMath::Pi(),
4710 ((TH1F *)(fAcceptedCutList->At(56)))->Fill(npointsTPCdEdx);
4712 ((TH1F *)(fAcceptedDCAList->At(0)))->Fill(TMath::Abs(dca[0]));
4713 ((TH1F *)(fAcceptedDCAList->At(4)))->Fill(TMath::Abs(dca[1]));
4714 ((TH1F *)(fAcceptedDCAList->At(8)))->Fill(nSigmaToVertex);
4715 ((TH3F *)(fAcceptedDCAList->At(12)))->Fill(track->Eta(),gPt,TMath::Abs(dca[0]));
4716 ((TH3F *)(fAcceptedDCAList->At(18)))->Fill(track->Eta(),gPt,TMath::Abs(dca[0]));
4717 if(fProtonAnalysisBase->GetEtaMode())
4718 ((TH2D *)(fQA2DList->At(0)))->Fill(track->Eta(),gPt);
4720 ((TH2D *)(fQA2DList->At(0)))->Fill(fProtonAnalysisBase->Rapidity(track->Px(),
4725 else if(track->Charge() < 0) {
4726 for(Int_t iLayer = 0; iLayer < 6; iLayer++) {
4727 if(track->HasPointOnITSLayer(iLayer))
4728 ((TH1F *)(fAcceptedCutList->At(1)))->Fill(iLayer+1);
4730 ((TH1F *)(fAcceptedCutList->At(5)))->Fill(nClustersITS);
4731 ((TH1F *)(fAcceptedCutList->At(9)))->Fill(chi2PerClusterITS);
4732 ((TH1F *)(fAcceptedCutList->At(13)))->Fill(chi2ConstrainVertex);
4733 ((TH1F *)(fAcceptedCutList->At(17)))->Fill(nClustersTPC);
4734 ((TH1F *)(fAcceptedCutList->At(21)))->Fill(chi2PerClusterTPC);
4735 ((TH1F *)(fAcceptedCutList->At(25)))->Fill(extCov[0]);
4736 ((TH1F *)(fAcceptedCutList->At(29)))->Fill(extCov[2]);
4737 ((TH1F *)(fAcceptedCutList->At(33)))->Fill(extCov[5]);
4738 ((TH1F *)(fAcceptedCutList->At(37)))->Fill(extCov[9]);
4739 ((TH1F *)(fAcceptedCutList->At(41)))->Fill(extCov[14]);
4740 ((TH3D *)(fAcceptedCutList->At(45)))->Fill(track->Eta(),
4741 track->Phi()*180./TMath::Pi(),
4743 ((TH3D *)(fAcceptedCutList->At(49)))->Fill(track->Eta(),
4744 track->Phi()*180./TMath::Pi(),
4746 ((TH3D *)(fAcceptedCutList->At(53)))->Fill(track->Eta(),
4747 track->Phi()*180./TMath::Pi(),
4749 ((TH1F *)(fAcceptedCutList->At(57)))->Fill(npointsTPCdEdx);
4751 ((TH1F *)(fAcceptedDCAList->At(1)))->Fill(TMath::Abs(dca[0]));
4752 ((TH1F *)(fAcceptedDCAList->At(5)))->Fill(TMath::Abs(dca[1]));
4753 ((TH1F *)(fAcceptedDCAList->At(9)))->Fill(nSigmaToVertex);
4754 ((TH3F *)(fAcceptedDCAList->At(13)))->Fill(track->Eta(),gPt,TMath::Abs(dca[0]));
4755 ((TH3F *)(fAcceptedDCAList->At(19)))->Fill(track->Eta(),gPt,TMath::Abs(dca[0]));
4756 if(fProtonAnalysisBase->GetEtaMode())
4757 ((TH2D *)(fQA2DList->At(4)))->Fill(track->Eta(),gPt);
4759 ((TH2D *)(fQA2DList->At(4)))->Fill(fProtonAnalysisBase->Rapidity(track->Px(),
4764 }//primary particles
4765 else if(label > stack->GetNprimary()) {
4766 Int_t lPartMother = -1;
4767 Int_t motherPDGCode = -1;
4769 lPartMother = particle->GetFirstMother();
4770 TParticle *motherParticle = stack->Particle(lPartMother);
4771 if(motherParticle) motherPDGCode = motherParticle->GetPdgCode();
4774 if(fMCProcessIdFlag)
4775 if(particle->GetUniqueID() != fMCProcessId) continue;
4776 if(fMotherParticlePDGCodeFlag)
4777 if(TMath::Abs(motherPDGCode) != fMotherParticlePDGCode) continue;
4779 if(track->Charge() > 0) {
4780 for(Int_t iLayer = 0; iLayer < 6; iLayer++) {
4781 if(track->HasPointOnITSLayer(iLayer))
4782 ((TH1F *)(fAcceptedCutList->At(2)))->Fill(iLayer+1);
4784 ((TH1F *)(fAcceptedCutList->At(6)))->Fill(nClustersITS);
4785 ((TH1F *)(fAcceptedCutList->At(10)))->Fill(chi2PerClusterITS);
4786 ((TH1F *)(fAcceptedCutList->At(14)))->Fill(chi2ConstrainVertex);
4787 ((TH1F *)(fAcceptedCutList->At(18)))->Fill(nClustersTPC);
4788 ((TH1F *)(fAcceptedCutList->At(22)))->Fill(chi2PerClusterTPC);
4789 ((TH1F *)(fAcceptedCutList->At(26)))->Fill(extCov[0]);
4790 ((TH1F *)(fAcceptedCutList->At(30)))->Fill(extCov[2]);
4791 ((TH1F *)(fAcceptedCutList->At(34)))->Fill(extCov[5]);
4792 ((TH1F *)(fAcceptedCutList->At(38)))->Fill(extCov[9]);
4793 ((TH1F *)(fAcceptedCutList->At(42)))->Fill(extCov[14]);
4794 ((TH3D *)(fAcceptedCutList->At(46)))->Fill(track->Eta(),
4795 track->Phi()*180./TMath::Pi(),
4797 ((TH3D *)(fAcceptedCutList->At(50)))->Fill(track->Eta(),
4798 track->Phi()*180./TMath::Pi(),
4800 ((TH3D *)(fAcceptedCutList->At(54)))->Fill(track->Eta(),
4801 track->Phi()*180./TMath::Pi(),
4803 ((TH1F *)(fAcceptedCutList->At(58)))->Fill(npointsTPCdEdx);
4805 ((TH1F *)(fAcceptedDCAList->At(2)))->Fill(TMath::Abs(dca[0]));
4806 ((TH1F *)(fAcceptedDCAList->At(6)))->Fill(TMath::Abs(dca[1]));
4807 ((TH1F *)(fAcceptedDCAList->At(10)))->Fill(nSigmaToVertex);
4808 if(particle->GetUniqueID() == 4) {
4809 ((TH3F *)(fAcceptedDCAList->At(14)))->Fill(track->Eta(),gPt,TMath::Abs(dca[0]));
4810 ((TH3F *)(fAcceptedDCAList->At(20)))->Fill(track->Eta(),gPt,TMath::Abs(dca[1]));
4812 if(particle->GetUniqueID() == 13) {
4813 ((TH3F *)(fAcceptedDCAList->At(16)))->Fill(track->Eta(),gPt,TMath::Abs(dca[0]));
4814 ((TH3F *)(fAcceptedDCAList->At(22)))->Fill(track->Eta(),gPt,TMath::Abs(dca[1]));
4816 if(fProtonAnalysisBase->GetEtaMode())
4817 ((TH2D *)(fQA2DList->At(2)))->Fill(track->Eta(),gPt);
4819 ((TH2D *)(fQA2DList->At(2)))->Fill(fProtonAnalysisBase->Rapidity(track->Px(),
4823 if(fProtonAnalysisBase->GetEtaMode())
4824 ((TH3F *)(fQA2DList->At(10)))->Fill(track->Eta(),gPt,
4825 ConvertPDGToInt(motherPDGCode));
4827 ((TH3F *)(fQA2DList->At(10)))->Fill(fProtonAnalysisBase->Rapidity(track->Px(),
4831 ConvertPDGToInt(motherPDGCode));
4833 else if(track->Charge() < 0) {
4834 for(Int_t iLayer = 0; iLayer < 6; iLayer++) {
4835 if(track->HasPointOnITSLayer(iLayer))
4836 ((TH1F *)(fAcceptedCutList->At(3)))->Fill(iLayer+1);
4838 ((TH1F *)(fAcceptedCutList->At(7)))->Fill(nClustersITS);
4839 ((TH1F *)(fAcceptedCutList->At(11)))->Fill(chi2PerClusterITS);
4840 ((TH1F *)(fAcceptedCutList->At(15)))->Fill(chi2ConstrainVertex);
4841 ((TH1F *)(fAcceptedCutList->At(19)))->Fill(nClustersTPC);
4842 ((TH1F *)(fAcceptedCutList->At(23)))->Fill(chi2PerClusterTPC);
4843 ((TH1F *)(fAcceptedCutList->At(27)))->Fill(extCov[0]);
4844 ((TH1F *)(fAcceptedCutList->At(31)))->Fill(extCov[2]);
4845 ((TH1F *)(fAcceptedCutList->At(35)))->Fill(extCov[5]);
4846 ((TH1F *)(fAcceptedCutList->At(39)))->Fill(extCov[9]);
4847 ((TH1F *)(fAcceptedCutList->At(43)))->Fill(extCov[14]);
4848 ((TH3D *)(fAcceptedCutList->At(47)))->Fill(track->Eta(),
4849 track->Phi()*180./TMath::Pi(),
4851 ((TH3D *)(fAcceptedCutList->At(51)))->Fill(track->Eta(),
4852 track->Phi()*180./TMath::Pi(),
4854 ((TH3D *)(fAcceptedCutList->At(55)))->Fill(track->Eta(),
4855 track->Phi()*180./TMath::Pi(),
4857 ((TH1F *)(fAcceptedCutList->At(59)))->Fill(npointsTPCdEdx);
4859 ((TH1F *)(fAcceptedDCAList->At(3)))->Fill(TMath::Abs(dca[0]));
4860 ((TH1F *)(fAcceptedDCAList->At(7)))->Fill(TMath::Abs(dca[1]));
4861 ((TH1F *)(fAcceptedDCAList->At(11)))->Fill(nSigmaToVertex);
4862 if(particle->GetUniqueID() == 4) {
4863 ((TH3F *)(fAcceptedDCAList->At(15)))->Fill(track->Eta(),gPt,TMath::Abs(dca[0]));
4864 ((TH3F *)(fAcceptedDCAList->At(21)))->Fill(track->Eta(),gPt,TMath::Abs(dca[1]));
4866 if(particle->GetUniqueID() == 13) {
4867 ((TH3F *)(fAcceptedDCAList->At(17)))->Fill(track->Eta(),gPt,TMath::Abs(dca[0]));
4868 ((TH3F *)(fAcceptedDCAList->At(23)))->Fill(track->Eta(),gPt,TMath::Abs(dca[1]));
4870 if(fProtonAnalysisBase->GetEtaMode())
4871 ((TH2D *)(fQA2DList->At(6)))->Fill(track->Eta(),gPt);
4873 ((TH2D *)(fQA2DList->At(6)))->Fill(fProtonAnalysisBase->Rapidity(track->Px(),
4877 if(fProtonAnalysisBase->GetEtaMode())
4878 ((TH3F *)(fQA2DList->At(11)))->Fill(track->Eta(),gPt,
4879 ConvertPDGToInt(motherPDGCode));
4881 ((TH3F *)(fQA2DList->At(11)))->Fill(fProtonAnalysisBase->Rapidity(track->Px(),
4885 ConvertPDGToInt(motherPDGCode));
4887 }//secondary particles
4888 }//accepted - track cuts
4890 else if((!fProtonAnalysisBase->IsAccepted(track)) ||
4891 (!fProtonAnalysisBase->IsPrimary(esd,vertex,track))) {
4892 if(label <= stack->GetNprimary()) {
4893 if(track->Charge() > 0) {
4894 ((TH3D *)(fRejectedCutList->At(0)))->Fill(track->Eta(),
4895 track->Phi()*180./TMath::Pi(),
4897 ((TH3D *)(fRejectedCutList->At(4)))->Fill(track->Eta(),
4898 track->Phi()*180./TMath::Pi(),
4900 ((TH3D *)(fRejectedCutList->At(8)))->Fill(track->Eta(),
4901 track->Phi()*180./TMath::Pi(),
4903 if(fProtonAnalysisBase->GetEtaMode())
4904 ((TH2D *)(fQA2DList->At(1)))->Fill(track->Eta(),gPt);
4906 ((TH2D *)(fQA2DList->At(1)))->Fill(fProtonAnalysisBase->Rapidity(track->Px(),
4911 else if(track->Charge() < 0) {
4912 ((TH3D *)(fRejectedCutList->At(1)))->Fill(track->Eta(),
4913 track->Phi()*180./TMath::Pi(),
4915 ((TH3D *)(fRejectedCutList->At(5)))->Fill(track->Eta(),
4916 track->Phi()*180./TMath::Pi(),
4918 ((TH3D *)(fRejectedCutList->At(9)))->Fill(track->Eta(),
4919 track->Phi()*180./TMath::Pi(),
4922 if(fProtonAnalysisBase->GetEtaMode())
4923 ((TH2D *)(fQA2DList->At(5)))->Fill(track->Eta(),gPt);
4925 ((TH2D *)(fQA2DList->At(5)))->Fill(fProtonAnalysisBase->Rapidity(track->Px(),
4930 }//primary particles
4931 else if(label > stack->GetNprimary()) {
4932 if(track->Charge() > 0) {
4933 ((TH3D *)(fRejectedCutList->At(2)))->Fill(track->Eta(),
4934 track->Phi()*180./TMath::Pi(),
4936 ((TH3D *)(fRejectedCutList->At(6)))->Fill(track->Eta(),
4937 track->Phi()*180./TMath::Pi(),
4939 ((TH3D *)(fRejectedCutList->At(10)))->Fill(track->Eta(),
4940 track->Phi()*180./TMath::Pi(),
4942 if(fProtonAnalysisBase->GetEtaMode())
4943 ((TH2D *)(fQA2DList->At(3)))->Fill(track->Eta(),gPt);
4945 ((TH2D *)(fQA2DList->At(3)))->Fill(fProtonAnalysisBase->Rapidity(track->Px(),
4950 else if(track->Charge() < 0) {
4951 ((TH3D *)(fRejectedCutList->At(3)))->Fill(track->Eta(),
4952 track->Phi()*180./TMath::Pi(),
4954 ((TH3D *)(fRejectedCutList->At(7)))->Fill(track->Eta(),
4955 track->Phi()*180./TMath::Pi(),
4957 ((TH3D *)(fRejectedCutList->At(11)))->Fill(track->Eta(),
4958 track->Phi()*180./TMath::Pi(),
4960 if(fProtonAnalysisBase->GetEtaMode())
4961 ((TH2D *)(fQA2DList->At(7)))->Fill(track->Eta(),gPt);
4963 ((TH2D *)(fQA2DList->At(7)))->Fill(fProtonAnalysisBase->Rapidity(track->Px(),
4968 }//secondary particles
4969 }//rejected - track cuts
4971 }//combined tracking
4976 //____________________________________________________________________//
4977 void AliProtonQAAnalysis::InitMCAnalysis() {
4978 //MC analysis - 3D histograms: y-pT-pdg
4979 fPDGList = new TList();
4980 TH3F *gHistYPtPDGProtons = 0x0;
4981 if(fUseAsymmetricBinning) {
4982 Double_t gPDG[15] = {-0.5,0.5,1.5,2.5,3.5,4.5,5.5,6.5,7.5,8.5,9.5,10.5,11.5,12.5,13.5};
4983 gHistYPtPDGProtons = new TH3F("gHistYPtPDGProtons",
4984 ";;P_{T} [GeV/c];PDG",
4985 fNBinsY,fY,fNBinsPt,fPt,14,gPDG);
4988 gHistYPtPDGProtons = new TH3F("gHistYPtPDGProtons",
4989 ";;P_{T} [GeV/c];PDG",
4990 fNBinsY,fMinY,fMaxY,
4991 fNBinsPt,fMinPt,fMaxPt,
4993 if(fProtonAnalysisBase->GetEtaMode())
4994 gHistYPtPDGProtons->GetXaxis()->SetTitle("#eta");
4996 gHistYPtPDGProtons->GetXaxis()->SetTitle("y");
4997 fPDGList->Add(gHistYPtPDGProtons);
4998 TH3F *gHistYPtPDGAntiProtons = 0x0;
4999 if(fUseAsymmetricBinning) {
5000 Double_t gPDG[15] = {-0.5,0.5,1.5,2.5,3.5,4.5,5.5,6.5,7.5,8.5,9.5,10.5,11.5,12.5,13.5};
5001 gHistYPtPDGAntiProtons = new TH3F("gHistYPtPDGAntiProtons",
5002 ";;P_{T} [GeV/c];PDG",
5003 fNBinsY,fY,fNBinsPt,fPt,14,gPDG);
5006 gHistYPtPDGAntiProtons = new TH3F("gHistYPtPDGAntiProtons",
5007 ";;P_{T} [GeV/c];PDG",
5008 fNBinsY,fMinY,fMaxY,
5009 fNBinsPt,fMinPt,fMaxPt,
5011 if(fProtonAnalysisBase->GetEtaMode())
5012 gHistYPtPDGAntiProtons->GetXaxis()->SetTitle("#eta");
5014 gHistYPtPDGAntiProtons->GetXaxis()->SetTitle("y");
5015 fPDGList->Add(gHistYPtPDGAntiProtons);
5018 fMCProcessesList = new TList();
5019 TH1F *gHistProtonsFromKLProcess = new TH1F("gHistProtonsFromKLProcess","",51,-0.5,50.5);
5020 fMCProcessesList->Add(gHistProtonsFromKLProcess);
5021 TH1F *gHistProtonsFromPionProcess = new TH1F("gHistProtonsFromPionProcess","",51,-0.5,50.5);
5022 fMCProcessesList->Add(gHistProtonsFromPionProcess);
5023 TH1F *gHistProtonsFromKSProcess = new TH1F("gHistProtonsFromKSProcess","",51,-0.5,50.5);
5024 fMCProcessesList->Add(gHistProtonsFromKSProcess);
5025 TH1F *gHistProtonsFromKaonProcess = new TH1F("gHistProtonsFromKaonProcess","",51,-0.5,50.5);
5026 fMCProcessesList->Add(gHistProtonsFromKaonProcess);
5027 TH1F *gHistProtonsFromNeutronProcess = new TH1F("gHistProtonsFromNeutronProcess","",51,-0.5,50.5);
5028 fMCProcessesList->Add(gHistProtonsFromNeutronProcess);
5029 TH1F *gHistProtonsFromProtonProcess = new TH1F("gHistProtonsFromProtonProcess","",51,-0.5,50.5);
5030 fMCProcessesList->Add(gHistProtonsFromProtonProcess);
5031 TH1F *gHistProtonsFromSigmaMinusProcess = new TH1F("gHistProtonsFromSigmaMinusProcess","",51,-0.5,50.5);
5032 fMCProcessesList->Add(gHistProtonsFromSigmaMinusProcess);
5033 TH1F *gHistProtonsFromLambda0Process = new TH1F("gHistProtonsFromLambda0Process","",51,-0.5,50.5);
5034 fMCProcessesList->Add(gHistProtonsFromLambda0Process);
5035 TH1F *gHistProtonsFromSigmaPlusProcess = new TH1F("gHistProtonsFromSigmaPlusProcess","",51,-0.5,50.5);
5036 fMCProcessesList->Add(gHistProtonsFromSigmaPlusProcess);
5037 TH1F *gHistProtonsFromXiMinusProcess = new TH1F("gHistProtonsFromXiMinusProcess","",51,-0.5,50.5);
5038 fMCProcessesList->Add(gHistProtonsFromXiMinusProcess);
5039 TH1F *gHistProtonsFromXi0Process = new TH1F("gHistProtonsFromXi0Process","",51,-0.5,50.5);
5040 fMCProcessesList->Add(gHistProtonsFromXi0Process);
5041 TH1F *gHistProtonsFromOmegaProcess = new TH1F("gHistProtonsFromOmegaProcess","",51,-0.5,50.5);
5042 fMCProcessesList->Add(gHistProtonsFromOmegaProcess);
5044 TH1F *gHistAntiProtonsFromKLProcess = new TH1F("gHistAntiProtonsFromKLProcess","",51,-0.5,50.5);
5045 fMCProcessesList->Add(gHistAntiProtonsFromKLProcess);
5046 TH1F *gHistAntiProtonsFromPionProcess = new TH1F("gHistAntiProtonsFromPionProcess","",51,-0.5,50.5);
5047 fMCProcessesList->Add(gHistAntiProtonsFromPionProcess);
5048 TH1F *gHistAntiProtonsFromKSProcess = new TH1F("gHistAntiProtonsFromKSProcess","",51,-0.5,50.5);
5049 fMCProcessesList->Add(gHistAntiProtonsFromKSProcess);
5050 TH1F *gHistAntiProtonsFromKaonProcess = new TH1F("gHistAntiProtonsFromKaonProcess","",51,-0.5,50.5);
5051 fMCProcessesList->Add(gHistAntiProtonsFromKaonProcess);
5052 TH1F *gHistAntiProtonsFromNeutronProcess = new TH1F("gHistAntiProtonsFromNeutronProcess","",51,-0.5,50.5);
5053 fMCProcessesList->Add(gHistAntiProtonsFromNeutronProcess);
5054 TH1F *gHistAntiProtonsFromProtonProcess = new TH1F("gHistAntiProtonsFromProtonProcess","",51,-0.5,50.5);
5055 fMCProcessesList->Add(gHistAntiProtonsFromProtonProcess);
5056 TH1F *gHistAntiProtonsFromLambda0Process = new TH1F("gHistAntiProtonsFromLambda0Process","",51,-0.5,50.5);
5057 fMCProcessesList->Add(gHistAntiProtonsFromLambda0Process);
5058 TH1F *gHistAntiProtonsFromSigmaPlusProcess = new TH1F("gHistAntiProtonsFromSigmaPlusProcess","",51,-0.5,50.5);
5059 fMCProcessesList->Add(gHistAntiProtonsFromSigmaPlusProcess);
5062 //____________________________________________________________________//
5063 void AliProtonQAAnalysis::RunMCAnalysis(AliStack* const stack) {
5064 //Main analysis part - MC
5065 for(Int_t iParticle = 0; iParticle < stack->GetNtrack(); iParticle++) {
5066 TParticle *particle = stack->Particle(iParticle);
5067 if(!particle) continue;
5069 if(TMath::Abs(particle->Eta()) > 1.0) continue;//acceptance
5070 if((particle->Pt() > fMaxPt)||(particle->Pt() < fMinPt)) continue;
5071 if(fProtonAnalysisBase->GetEtaMode()) {
5072 if((particle->Eta() > fMaxY)||(particle->Eta() < fMinY)) continue;
5075 if((fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) > fMaxY)||(fProtonAnalysisBase->Rapidity(particle->Px(),particle->Py(),particle->Pz()) < fMinY)) continue;
5078 Int_t pdgcode = particle->GetPdgCode();
5079 if(pdgcode == 2212) {
5080 if(iParticle <= stack->GetNprimary()) {
5081 if(fProtonAnalysisBase->GetEtaMode())
5082 ((TH3F *)(fPDGList->At(0)))->Fill(particle->Eta(),particle->Pt(),0);
5084 ((TH3F *)(fPDGList->At(0)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
5089 else if(iParticle > stack->GetNprimary()) {
5090 Int_t lPartMother = particle->GetFirstMother();
5091 TParticle *motherParticle = stack->Particle(lPartMother);
5092 if(!motherParticle) continue;
5093 Int_t motherPDGCode = motherParticle->GetPdgCode();
5094 if(fMCProcessIdFlag)
5095 if(particle->GetUniqueID() != fMCProcessId) continue;
5096 if(fMotherParticlePDGCodeFlag)
5097 if(TMath::Abs(motherPDGCode) != fMotherParticlePDGCode) continue;
5099 if(fProtonAnalysisBase->GetEtaMode())
5100 ((TH3F *)(fPDGList->At(0)))->Fill(particle->Eta(),
5102 ConvertPDGToInt(motherParticle->GetPdgCode()));
5104 ((TH3F *)(fPDGList->At(0)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
5108 ConvertPDGToInt(motherParticle->GetPdgCode()));
5110 if(TMath::Abs(motherParticle->GetPdgCode()) == 130)
5111 ((TH1F *)(fMCProcessesList->At(0)))->Fill(particle->GetUniqueID());
5112 if(TMath::Abs(motherParticle->GetPdgCode()) == 211)
5113 ((TH1F *)(fMCProcessesList->At(1)))->Fill(particle->GetUniqueID());
5114 if(TMath::Abs(motherParticle->GetPdgCode()) == 310)
5115 ((TH1F *)(fMCProcessesList->At(2)))->Fill(particle->GetUniqueID());
5116 if(TMath::Abs(motherParticle->GetPdgCode()) == 321)
5117 ((TH1F *)(fMCProcessesList->At(3)))->Fill(particle->GetUniqueID());
5118 if(TMath::Abs(motherParticle->GetPdgCode()) == 2112)
5119 ((TH1F *)(fMCProcessesList->At(4)))->Fill(particle->GetUniqueID());
5120 if(TMath::Abs(motherParticle->GetPdgCode()) == 2212)
5121 ((TH1F *)(fMCProcessesList->At(5)))->Fill(particle->GetUniqueID());
5122 if(TMath::Abs(motherParticle->GetPdgCode()) == 3112)
5123 ((TH1F *)(fMCProcessesList->At(6)))->Fill(particle->GetUniqueID());
5124 if(TMath::Abs(motherParticle->GetPdgCode()) == 3122)
5125 ((TH1F *)(fMCProcessesList->At(7)))->Fill(particle->GetUniqueID());
5126 if(TMath::Abs(motherParticle->GetPdgCode()) == 3222)
5127 ((TH1F *)(fMCProcessesList->At(8)))->Fill(particle->GetUniqueID());
5128 if(TMath::Abs(motherParticle->GetPdgCode()) == 3312)
5129 ((TH1F *)(fMCProcessesList->At(9)))->Fill(particle->GetUniqueID());
5130 if(TMath::Abs(motherParticle->GetPdgCode()) == 3322)
5131 ((TH1F *)(fMCProcessesList->At(10)))->Fill(particle->GetUniqueID());
5132 if(TMath::Abs(motherParticle->GetPdgCode()) == 3334)
5133 ((TH1F *)(fMCProcessesList->At(11)))->Fill(particle->GetUniqueID());
5135 }//pdgcode of proton
5137 if(pdgcode == -2212) {
5138 if(iParticle <= stack->GetNprimary()) {
5139 if(fProtonAnalysisBase->GetEtaMode())
5140 ((TH3F *)(fPDGList->At(1)))->Fill(particle->Eta(),particle->Pt(),0);
5142 ((TH3F *)(fPDGList->At(1)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
5147 else if(iParticle > stack->GetNprimary()) {
5148 Int_t lPartMother = particle->GetFirstMother();
5149 TParticle *motherParticle = stack->Particle(lPartMother);
5150 if(!motherParticle) continue;
5151 Int_t motherPDGCode = motherParticle->GetPdgCode();
5152 if(fMCProcessIdFlag)
5153 if(particle->GetUniqueID() != fMCProcessId) continue;
5154 if(fMotherParticlePDGCodeFlag)
5155 if(TMath::Abs(motherPDGCode) != fMotherParticlePDGCode) continue;
5157 if(fProtonAnalysisBase->GetEtaMode())
5158 ((TH3F *)(fPDGList->At(1)))->Fill(particle->Eta(),
5160 ConvertPDGToInt(motherParticle->GetPdgCode()));
5162 ((TH3F *)(fPDGList->At(1)))->Fill(fProtonAnalysisBase->Rapidity(particle->Px(),
5166 ConvertPDGToInt(motherParticle->GetPdgCode()));
5169 if(TMath::Abs(motherParticle->GetPdgCode()) == 130)
5170 ((TH1F *)(fMCProcessesList->At(12)))->Fill(particle->GetUniqueID());
5171 if(TMath::Abs(motherParticle->GetPdgCode()) == 211)
5172 ((TH1F *)(fMCProcessesList->At(13)))->Fill(particle->GetUniqueID());
5173 if(TMath::Abs(motherParticle->GetPdgCode()) == 310)
5174 ((TH1F *)(fMCProcessesList->At(14)))->Fill(particle->GetUniqueID());
5175 if(TMath::Abs(motherParticle->GetPdgCode()) == 321)
5176 ((TH1F *)(fMCProcessesList->At(15)))->Fill(particle->GetUniqueID());
5177 if(TMath::Abs(motherParticle->GetPdgCode()) == 2112)
5178 ((TH1F *)(fMCProcessesList->At(16)))->Fill(particle->GetUniqueID());
5179 if(TMath::Abs(motherParticle->GetPdgCode()) == 2212)
5180 ((TH1F *)(fMCProcessesList->At(17)))->Fill(particle->GetUniqueID());
5181 if(TMath::Abs(motherParticle->GetPdgCode()) == 3122)
5182 ((TH1F *)(fMCProcessesList->At(18)))->Fill(particle->GetUniqueID());
5183 if(TMath::Abs(motherParticle->GetPdgCode()) == 3222)
5184 ((TH1F *)(fMCProcessesList->At(19)))->Fill(particle->GetUniqueID());
5185 }//secondary antiproton
5186 }//pdgcode of antiproton
5191 //____________________________________________________________________//
5192 Int_t AliProtonQAAnalysis::ConvertPDGToInt(Int_t pdgCode) const {
5193 //Converts the pdg code to an int based on the following scheme:
5194 //1: PDG code: 130 - Name: K_L0
5195 //2: PDG code: 211 - Name: pi+
5196 //3: PDG code: 310 - Name: K_S0
5197 //4: PDG code: 321 - Name: K+
5198 //5: PDG code: 2112 - Name: neutron
5199 //6: PDG code: 2212 - Name: proton
5200 //7: PDG code: 3112 - Name: Sigma-
5201 //8: PDG code: 3122 - Name: Lambda0
5202 //9: PDG code: 3222 - Name: Sigma+
5203 //10: PDG code: 3312 - Name: Xi-
5204 //11: PDG code: 3322 - Name: Xi0
5205 //12: PDG code: 3334 - Name: Omega-
5207 switch (TMath::Abs(pdgCode)) {