Skip to content

Commit dc59c7b

Browse files
authored
Add histograms for protons and neutrons in h-d corr.
1 parent bcb2527 commit dc59c7b

1 file changed

Lines changed: 17 additions & 3 deletions

File tree

PWGLF/Tasks/Nuspex/hadronnucleicorrelation.cxx

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ struct HadronNucleiCorrelation {
269269
}
270270
registry.add("hMult", "multiplicity", {HistType::kTH1D, {{200, 0.f, 200.f, "N_{ch}"}}});
271271

272-
if (doQA) {
272+
if (doQA && (doprocessSameEvent || doprocessSameEventEvSel || doprocessMC)) {
273273
// Track QA
274274
registryQa.add("QA/hVtxZ_trk", "#it{z}_{vtx}", {HistType::kTH1D, {{150, -15.f, 15.f, "#it{z}_{vtx} (cm)"}}});
275275
registryQa.add("QA/hTPCnClusters", "N TPC Clusters; N TPC Clusters", {HistType::kTH1D, {{200, 0.f, 200.f}}});
@@ -428,8 +428,10 @@ struct HadronNucleiCorrelation {
428428
registry.addClone("Generated/hQADeuterons", "Generated/hQAAntiDeuterons");
429429

430430
const AxisSpec ptAxisGen = {100, 0.f, 10.f, "#it{p}_{T} GeV/#it{c}"};
431-
registry.add("Generated/hDeuteronsVsPt", "hDeuteronsVsPt;", {HistType::kTH1D, {ptAxisGen}});
432-
registry.add("Generated/hAntiDeuteronsVsPt", "hAntiDeuteronsVsPt;", {HistType::kTH1D, {ptAxisGen}});
431+
registry.add("Generated/hDeuteronsVsPt", "hDeuteronsVsPt", {HistType::kTH1D, {ptAxisGen}});
432+
registry.add("Generated/hAntiDeuteronsVsPt", "hAntiDeuteronsVsPt", {HistType::kTH1D, {ptAxisGen}});
433+
registry.add("Generated/hProtonsVsPt", "hProtonsVsPt", {HistType::kTH1D, {ptAxisGen}});
434+
registry.add("Generated/hAntiProtonsVsPt", "hAntiProtonsVsPt", {HistType::kTH1D, {ptAxisGen}});
433435
}
434436
}
435437

@@ -1843,6 +1845,12 @@ struct HadronNucleiCorrelation {
18431845
case -PDG_t::kProton:
18441846
registry.fill(HIST("Generated/hQAAntiProtons"), binPosition);
18451847
return true;
1848+
case o2::constants::physics::Pdg::kNeutron:
1849+
registry.fill(HIST("Generated/hQANeutrons"), binPosition);
1850+
return true;
1851+
case -o2::constants::physics::Pdg::kNeutron:
1852+
registry.fill(HIST("Generated/hQAAntiNeutrons"), binPosition);
1853+
return true;
18461854
case o2::constants::physics::Pdg::kDeuteron:
18471855
registry.fill(HIST("Generated/hQADeuterons"), binPosition);
18481856
return true;
@@ -1864,6 +1872,12 @@ struct HadronNucleiCorrelation {
18641872

18651873
if (std::abs(particle.y()) < yRap) {
18661874
switch (particle.pdgCode()) {
1875+
case o2::constants::physics::Pdg::kProton:
1876+
registry.fill(HIST("Generated/hProtonsVsPt"), particle.pt());
1877+
break;
1878+
case -o2::constants::physics::Pdg::kProton:
1879+
registry.fill(HIST("Generated/hAntiProtonsVsPt"), particle.pt());
1880+
break;
18671881
case o2::constants::physics::Pdg::kDeuteron:
18681882
registry.fill(HIST("Generated/hDeuteronsVsPt"), particle.pt());
18691883
break;

0 commit comments

Comments
 (0)