Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PWGLF: Fix a bug of TPC nclusters cut and change the order of cuts on tracks for analysis of hypertriton 3body decay #8180

Merged
merged 1 commit into from
Oct 28, 2024
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion PWGLF/TableProducer/Nuspex/decay3bodybuilder.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,7 @@ struct decay3bodyBuilder {
auto t1 = vtx3body.template track1_as<TTrackClass>();
auto t2 = vtx3body.template track2_as<TTrackClass>();

if (t0.tpcNClsFound() < mintpcNCls && t1.tpcNClsFound() < mintpcNCls && t2.tpcNClsFound() < mintpcNCls) {
if (t0.tpcNClsFound() < mintpcNCls || t1.tpcNClsFound() < mintpcNCls || t2.tpcNClsFound() < mintpcNCls) {
continue;
}
registry.fill(HIST("hVtx3BodyCounter"), kVtxTPCNcls);
Expand Down
20 changes: 12 additions & 8 deletions PWGLF/TableProducer/Nuspex/threebodyRecoTask.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -150,9 +150,9 @@ struct threebodyRecoTask {
kCandRapidity,
kCandct,
kCandDcaDau,
kCandTOFPID,
kCandTPCPID,
kCandTPCNcls,
kCandTPCPID,
kCandTOFPID,
kCandDauPt,
kCandDcaToPV,
kCandInvMass,
Expand Down Expand Up @@ -281,40 +281,44 @@ struct threebodyRecoTask {
return;
}
FillCandCounter(kCandCosPA, isTrueCand);

if (std::abs(trackProton.eta()) > etacut || std::abs(trackPion.eta()) > etacut || std::abs(trackDeuteron.eta()) > etacut) {
return;
}
FillCandCounter(kCandDauEta, isTrueCand);

if (std::abs(candData.yHypertriton()) > rapiditycut) {
return;
}
FillCandCounter(kCandRapidity, isTrueCand);

double ct = candData.distovertotmom(dCollision.posX(), dCollision.posY(), dCollision.posZ()) * o2::constants::physics::MassHyperTriton;
if (ct > lifetimecut) {
return;
}
FillCandCounter(kCandct, isTrueCand);

if (candData.dcaVtxdaughters() > dcavtxdau) {
return;
}
FillCandCounter(kCandDcaDau, isTrueCand);

registry.fill(HIST("hDeuteronTOFVsPBeforeTOFCut"), trackDeuteron.sign() * trackDeuteron.p(), candData.tofNSigmaBachDe());
if ((candData.tofNSigmaBachDe() < TofPidNsigmaMin || candData.tofNSigmaBachDe() > TofPidNsigmaMax) && trackDeuteron.p() > minDeuteronPUseTOF) {
if (trackProton.tpcNClsFound() < mintpcNClsproton || trackPion.tpcNClsFound() < mintpcNClspion || trackDeuteron.tpcNClsFound() < mintpcNClsdeuteron) {
return;
}
FillCandCounter(kCandTOFPID, isTrueCand);
registry.fill(HIST("hDeuteronTOFVsPAtferTOFCut"), trackDeuteron.sign() * trackDeuteron.p(), candData.tofNSigmaBachDe());
FillCandCounter(kCandTPCNcls, isTrueCand);

if (std::abs(trackProton.tpcNSigmaPr()) > TpcPidNsigmaCut || std::abs(trackPion.tpcNSigmaPi()) > TpcPidNsigmaCut || std::abs(trackDeuteron.tpcNSigmaDe()) > TpcPidNsigmaCut) {
return;
}
FillCandCounter(kCandTPCPID, isTrueCand);

if (trackProton.tpcNClsFound() < mintpcNClsproton || trackPion.tpcNClsFound() < mintpcNClspion || trackDeuteron.tpcNClsFound() < mintpcNClsdeuteron) {
registry.fill(HIST("hDeuteronTOFVsPBeforeTOFCut"), trackDeuteron.sign() * trackDeuteron.p(), candData.tofNSigmaBachDe());
if ((candData.tofNSigmaBachDe() < TofPidNsigmaMin || candData.tofNSigmaBachDe() > TofPidNsigmaMax) && trackDeuteron.p() > minDeuteronPUseTOF) {
return;
}
FillCandCounter(kCandTPCNcls, isTrueCand);
FillCandCounter(kCandTOFPID, isTrueCand);
registry.fill(HIST("hDeuteronTOFVsPAtferTOFCut"), trackDeuteron.sign() * trackDeuteron.p(), candData.tofNSigmaBachDe());

if (trackProton.pt() < minProtonPt || trackProton.pt() > maxProtonPt || trackPion.pt() < minPionPt || trackPion.pt() > maxPionPt || trackDeuteron.pt() < minDeuteronPt || trackDeuteron.pt() > maxDeuteronPt) {
return;
Expand Down
32 changes: 18 additions & 14 deletions PWGLF/Tasks/Nuspex/hypertriton3bodyanalysis.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -236,9 +236,9 @@ struct hypertriton3bodyAnalysis {
kCandRapidity,
kCandct,
kCandDcaDau,
kCandTOFPID,
kCandTPCPID,
kCandTPCNcls,
kCandTPCPID,
kCandTOFPID,
kCandDauPt,
kCandDcaToPV,
kCandInvMass,
Expand Down Expand Up @@ -329,24 +329,38 @@ struct hypertriton3bodyAnalysis {
return;
}
FillCandCounter(kCandCosPA, isTrueCand);
if (TMath::Abs(trackProton.eta()) > etacut || TMath::Abs(trackPion.eta()) > etacut || TMath::Abs(trackDeuteron.eta()) > etacut) {

if (std::abs(trackProton.eta()) > etacut || std::abs(trackPion.eta()) > etacut || std::abs(trackDeuteron.eta()) > etacut) {
return;
}
FillCandCounter(kCandDauEta, isTrueCand);
if (TMath::Abs(candData.yHypertriton()) > rapiditycut) {

if (std::abs(candData.yHypertriton()) > rapiditycut) {
return;
}
FillCandCounter(kCandRapidity, isTrueCand);

double ct = candData.distovertotmom(dCollision.posX(), dCollision.posY(), dCollision.posZ()) * o2::constants::physics::MassHyperTriton;
if (ct > lifetimecut) {
return;
}
FillCandCounter(kCandct, isTrueCand);

if (candData.dcaVtxdaughters() > dcavtxdau) {
return;
}
FillCandCounter(kCandDcaDau, isTrueCand);

if (trackProton.tpcNClsFound() < mintpcNClsproton || trackPion.tpcNClsFound() < mintpcNClspion || trackDeuteron.tpcNClsFound() < mintpcNClsdeuteron) {
return;
}
FillCandCounter(kCandTPCNcls, isTrueCand);

if (TMath::Abs(trackProton.tpcNSigmaPr()) > TpcPidNsigmaCut || TMath::Abs(trackPion.tpcNSigmaPi()) > TpcPidNsigmaCut || TMath::Abs(trackDeuteron.tpcNSigmaDe()) > TpcPidNsigmaCut) {
return;
}
FillCandCounter(kCandTPCPID, isTrueCand);

// registry.fill(HIST("hDeuteronDefaultTOFVsPBeforeTOFCut"), trackDeuteron.sign() * trackDeuteron.p(), trackDeuteron.tofNSigmaDe());
registry.fill(HIST("hDeuteronTOFVsPBeforeTOFCut"), trackDeuteron.sign() * trackDeuteron.p(), candData.tofNSigmaBachDe());
if (isTrueCand) {
Expand All @@ -364,16 +378,6 @@ struct hypertriton3bodyAnalysis {
registry.fill(HIST("hDeuteronTOFVsPAfterTOFCutSig"), trackDeuteron.sign() * trackDeuteron.p(), candData.tofNSigmaBachDe());
}

if (TMath::Abs(trackProton.tpcNSigmaPr()) > TpcPidNsigmaCut || TMath::Abs(trackPion.tpcNSigmaPi()) > TpcPidNsigmaCut || TMath::Abs(trackDeuteron.tpcNSigmaDe()) > TpcPidNsigmaCut) {
return;
}
FillCandCounter(kCandTPCPID, isTrueCand);

if (trackProton.tpcNClsFound() < mintpcNClsproton || trackPion.tpcNClsFound() < mintpcNClspion || trackDeuteron.tpcNClsFound() < mintpcNClsdeuteron) {
return;
}
FillCandCounter(kCandTPCNcls, isTrueCand);

if (trackProton.pt() < minProtonPt || trackProton.pt() > maxProtonPt || trackPion.pt() < minPionPt || trackPion.pt() > maxPionPt || trackDeuteron.pt() < minDeuteronPt || trackDeuteron.pt() > maxDeuteronPt) {
return;
}
Expand Down
Loading