Skip to content

Commit aa4f230

Browse files
Paola Vargas TorresPaola Vargas Torres
authored andcommitted
Correct logical condition in DCA to PV cuts
1 parent 8ba9f45 commit aa4f230

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

PWGLF/Tasks/Nuspex/dedxPidAnalysis.cxx

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -797,7 +797,9 @@ struct DedxPidAnalysis {
797797
if (fillHist)
798798
registryDeDx.fill(HIST("trackselSec"), TrkSecCutLabel::V0TypeK0s);
799799

800-
if (std::fabs(v0.dcapostopv()) < dcaPionsFromK0s && std::fabs(v0.dcanegtopv()) < dcaPionsFromK0s) // DCA selection
800+
if (std::fabs(v0.dcapostopv()) < dcaPionsFromK0s) // DCA selection
801+
return false;
802+
if (std::fabs(v0.dcanegtopv()) < dcaPionsFromK0s) // DCA selection
801803
return false;
802804
if (fillHist)
803805
registryDeDx.fill(HIST("trackselSec"), TrkSecCutLabel::DCAtoVtxK0s);
@@ -876,7 +878,9 @@ struct DedxPidAnalysis {
876878
if (fillHist)
877879
registryDeDx.fill(HIST("trackselSec"), TrkSecCutLabel::V0TypeLambda);
878880

879-
if (std::fabs(v0.dcapostopv()) < dcaProtonsFromLambda && std::fabs(v0.dcanegtopv()) < dcaPionsFromLambda) // DCA selection
881+
if (std::fabs(v0.dcapostopv()) < dcaProtonsFromLambda) // DCA selection
882+
return false;
883+
if (std::fabs(v0.dcanegtopv()) < dcaPionsFromLambda) // DCA selection
880884
return false;
881885
if (fillHist)
882886
registryDeDx.fill(HIST("trackselSec"), TrkSecCutLabel::DCAtoVtxLambda);
@@ -949,7 +953,9 @@ struct DedxPidAnalysis {
949953
if (fillHist)
950954
registryDeDx.fill(HIST("trackselSec"), TrkSecCutLabel::V0TypeAntiLambda);
951955

952-
if (std::fabs(v0.dcapostopv()) < dcaPionsFromLambda && std::fabs(v0.dcanegtopv()) < dcaProtonsFromLambda) // DCA selection
956+
if (std::fabs(v0.dcapostopv()) < dcaPionsFromLambda) // DCA selection
957+
return false;
958+
if (std::fabs(v0.dcanegtopv()) < dcaProtonsFromLambda) // DCA selection
953959
return false;
954960
if (fillHist)
955961
registryDeDx.fill(HIST("trackselSec"), TrkSecCutLabel::DCAtoVtxAntiLambda);

0 commit comments

Comments
 (0)