Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 19 additions & 1 deletion PWGLF/Tasks/Strangeness/cascadecorrelations.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,7 @@
casc.v0cosPA(pvx, pvy, pvz) < v0setting_cospa ||
casc.casccosPA(pvx, pvy, pvz) < cascadesetting_cospa ||
casc.dcav0topv(pvx, pvy, pvz) < cascadesetting_mindcav0topv ||
TMath::Abs(casc.mLambda() - 1.115683) > cascadesetting_v0masswindow) {

Check failure on line 291 in PWGLF/Tasks/Strangeness/cascadecorrelations.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
// It failed at least one topo selection
cascflags(0);
continue;
Expand All @@ -296,13 +296,13 @@
registry.fill(HIST("hSelectionStatus"), 3); // passes topo
// registry.fill(HIST("hMassXi3"), casc.mXi(), casc.pt());

if (TMath::Abs(posTrack.eta()) > etaTracks || TMath::Abs(negTrack.eta()) > etaTracks || TMath::Abs(bachTrack.eta()) > etaTracks) {

Check failure on line 299 in PWGLF/Tasks/Strangeness/cascadecorrelations.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
cascflags(0);
continue;
}
registry.fill(HIST("hSelectionStatus"), 4); // passes track eta

if (TMath::Abs(casc.eta()) > etaCascades) {

Check failure on line 305 in PWGLF/Tasks/Strangeness/cascadecorrelations.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
cascflags(0);
continue;
}
Expand All @@ -314,23 +314,23 @@
// Lambda check
if (casc.sign() < 0) {
// Proton check:
if (TMath::Abs(posTrack.tpcNSigmaPr()) > tpcNsigmaProton) {

Check failure on line 317 in PWGLF/Tasks/Strangeness/cascadecorrelations.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
cascflags(0);
continue;
}
// Pion check:
if (TMath::Abs(negTrack.tpcNSigmaPi()) > tpcNsigmaPion) {

Check failure on line 322 in PWGLF/Tasks/Strangeness/cascadecorrelations.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
cascflags(0);
continue;
}
} else {
// Proton check:
if (TMath::Abs(negTrack.tpcNSigmaPr()) > tpcNsigmaProton) {

Check failure on line 328 in PWGLF/Tasks/Strangeness/cascadecorrelations.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
cascflags(0);
continue;
}
// Pion check:
if (TMath::Abs(posTrack.tpcNSigmaPi()) > tpcNsigmaPion) {

Check failure on line 333 in PWGLF/Tasks/Strangeness/cascadecorrelations.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
cascflags(0);
continue;
}
Expand All @@ -339,8 +339,8 @@
// registry.fill(HIST("hMassXi4"), casc.mXi(), casc.pt());

// Bachelor check
if (TMath::Abs(bachTrack.tpcNSigmaPi()) < tpcNsigmaBachelor) {

Check failure on line 342 in PWGLF/Tasks/Strangeness/cascadecorrelations.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
if (TMath::Abs(bachTrack.tpcNSigmaKa()) < tpcNsigmaBachelor) {

Check failure on line 343 in PWGLF/Tasks/Strangeness/cascadecorrelations.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
// consistent with both!
cascflags(2);
registry.fill(HIST("hSelectionStatus"), 7); // passes bach PID
Expand All @@ -363,7 +363,7 @@
registry.fill(HIST("hMassXiPlus"), casc.mXi(), casc.pt(), casc.yXi());
}
continue;
} else if (TMath::Abs(bachTrack.tpcNSigmaKa()) < tpcNsigmaBachelor) {

Check failure on line 366 in PWGLF/Tasks/Strangeness/cascadecorrelations.cxx

View workflow job for this annotation

GitHub Actions / O2 linter

[root/entity]

Replace ROOT entities with equivalents from standard C++ or from O2.
cascflags(3);
registry.fill(HIST("hSelectionStatus"), 7); // passes bach PID
if (casc.sign() < 0) {
Expand Down Expand Up @@ -521,6 +521,11 @@
{"MC/hGenMultNoReco", "hGenMultNoReco", {HistType::kTH1I, {{100, 0, 100, "Number of generated charged primaries"}}}},
{"MC/hGenMultOneReco", "hGenMultOneReco", {HistType::kTH1I, {{100, 0, 100, "Number of generated charged primaries"}}}},
{"MC/hSplitEvents", "hSplitEvents", {HistType::kTH1I, {{10, 0, 10, "Number of rec. events per gen event"}}}},

// debug
{"MC/hPhi", "hPhi", {HistType::kTH1F, {{180, 0, TwoPI}}}},
{"MC/hEta", "hEta", {HistType::kTH1F, {{100, -2, 2}}}},
{"MC/hRapidity", "hRapidity", {HistType::kTH1F, {{100, -2, 2}}}},
},
};

Expand Down Expand Up @@ -924,7 +929,8 @@
} // collisions
} // process mixed events

Filter genCascadesFilter = nabs(aod::mcparticle::pdgCode) == 3312;
Configurable<float> etaGenCascades{"etaGenCascades", 0.8, "min/max of eta for generated cascades"};
Filter genCascadesFilter = (nabs(aod::mcparticle::pdgCode) == 3312 && nabs(aod::mcparticle::eta) < etaGenCascades);

void processMC(aod::McCollision const&, soa::SmallGroups<soa::Join<aod::McCollisionLabels, MyCollisionsMult>> const& collisions, soa::Filtered<aod::McParticles> const& genCascades, aod::McParticles const& mcParticles)
{
Expand All @@ -947,6 +953,15 @@
return;
}

// QA
for (auto& casc : genCascades) {
if (!casc.isPhysicalPrimary())
continue;
registry.fill(HIST("MC/hPhi"), casc.phi());
registry.fill(HIST("MC/hEta"), casc.eta());
registry.fill(HIST("MC/hRapidity"), casc.y());
}

for (auto& [c0, c1] : combinations(genCascades, genCascades)) { // combinations automatically applies strictly upper in case of 2 identical tables
// Define the trigger as the particle with the highest pT. As we can't swap the cascade tables themselves, we swap the addresses and later dereference them
auto* triggerAddress = &c0;
Expand All @@ -959,6 +974,9 @@

double dphi = RecoDecay::constrainAngle(trigger.phi() - assoc.phi(), -PIHalf);

if (!trigger.isPhysicalPrimary() || !assoc.isPhysicalPrimary())
continue; // require the cascades to be primaries

if (trigger.pdgCode() < 0) { // anti-trigg --> Plus
if (assoc.pdgCode() < 0) { // anti-assoc --> Plus
registry.fill(HIST("MC/hMCPlusPlus"), dphi, trigger.y() - assoc.y(), trigger.pt(), assoc.pt(), vtxz, FT0mult);
Expand Down
Loading