You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: PWGCF/TwoParticleCorrelations/Tasks/identifiedbf.cxx
+74Lines changed: 74 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -100,6 +100,7 @@ struct IdentifiedbfTask {
100
100
std::vector<TH3F*> fhN1VsZEtaPhiPt{nch + 1, nullptr}; //!<! single particle distribution vs \f$\mbox{vtx}_z,\; \eta,\;\phi,\;p_T\f$, for the different species
101
101
std::vector<TH3F*> fhN1VsZEtaPhiPtPrimary{nch, nullptr}; //!<! single particle distribution of primary particles vs \f$\mbox{vtx}_z,\; \eta,\;\phi,\;p_T\f$, for the different species
102
102
std::vector<TH3F*> fhN1VsZEtaPhiPtSecondary{nch, nullptr}; //!<! single particle distribution of primary particles vs \f$\mbox{vtx}_z,\; \eta,\;\phi,\;p_T\f$, for the different species
103
+
std::vector<TH3F*> fhN1VsZEtaPhiPtPure{nch + 1, nullptr}; //!<! single particle distribution of pure particles vs \f$\mbox{vtx}_z,\; \eta,\;\phi,\;p_T\f$, for the different species
103
104
std::vector<TH3F*> fhSum1PtVsZEtaPhiPt{nch, nullptr}; //!<! accumulated sum of weighted \f$p_T\f$ vs \f$\mbox{vtx}_z,\; \eta,\;\phi,\;p_T\f$, for the different species
104
105
std::vector<TH3*> fhNuaNueVsZEtaPhiPt{nch, nullptr}; //!<! NUA+NUE correction vs \f$\mbox{vtx}_z,\; \eta,\;\phi,\;p_T\f$, for the differents species
105
106
std::vector<TH2*> fhPtAvgVsEtaPhi{nch, nullptr}; //!<! average \f$p_T\f$ vs \f$\eta,\;\phi\f$, for the different species
@@ -297,6 +298,56 @@ struct IdentifiedbfTask {
297
298
return particle.isPhysicalPrimary();
298
299
}
299
300
301
+
/// \brief checks whether MC track is a physical primary or secondary
302
+
/// \param particle passed MC track converted to MCParticle
303
+
template <typename ParticleObject>
304
+
boolisSpeciesCheck(ParticleObject const& particle, int trkId)
305
+
{
306
+
int pdgcode = particle.pdgCode();
307
+
int realPID = -1;
308
+
switch (pdgcode) {
309
+
casekPositron:
310
+
realPID = 0;
311
+
break;
312
+
casekElectron:
313
+
realPID = 1;
314
+
break;
315
+
casekPiPlus:
316
+
realPID = 2;
317
+
break;
318
+
casekPiMinus:
319
+
realPID = 3;
320
+
break;
321
+
casekKPlus:
322
+
realPID = 4;
323
+
break;
324
+
casekKMinus:
325
+
realPID = 5;
326
+
break;
327
+
casekProton:
328
+
realPID = 6;
329
+
break;
330
+
casekProtonBar:
331
+
realPID = 7;
332
+
break;
333
+
default:
334
+
realPID = -1;
335
+
break;
336
+
}
337
+
return (realPID == trkId);
338
+
}
339
+
340
+
/// \brief checks whether MC track is a physical primary or secondary
341
+
/// \param particle passed MC track converted to MCParticle
342
+
template <typename TrackObject>
343
+
boolisPrimarySpeciesCheck(TrackObject const& track, int trkId)
0 commit comments