diff --git a/PWGCF/FemtoUniverse/Core/FemtoUniverseCascadeSelection.h b/PWGCF/FemtoUniverse/Core/FemtoUniverseCascadeSelection.h index bb3f4a76028..972305765c5 100644 --- a/PWGCF/FemtoUniverse/Core/FemtoUniverseCascadeSelection.h +++ b/PWGCF/FemtoUniverse/Core/FemtoUniverseCascadeSelection.h @@ -9,7 +9,7 @@ // granted to it by virtue of its status as an Intergovernmental Organization // or submit itself to any jurisdiction. -/// \file femtoUniverseCascadeSelection.h +/// \file FemtoUniverseCascadeSelection.h /// \brief Definition of the femtoUniverseCascadeSelection /// \author Valentina Mantovani Sarti, TU München valentina.mantovani-sarti@tum.de /// \author Andi Mathis, TU München, andreas.mathis@ph.tum.de @@ -21,12 +21,9 @@ #ifndef PWGCF_FEMTOUNIVERSE_CORE_FEMTOUNIVERSECASCADESELECTION_H_ #define PWGCF_FEMTOUNIVERSE_CORE_FEMTOUNIVERSECASCADESELECTION_H_ -#include #include #include -#include // FIXME - #include "PWGCF/FemtoUniverse/Core/FemtoUniverseObjectSelection.h" #include "PWGCF/FemtoUniverse/Core/FemtoUniverseSelection.h" #include "PWGCF/FemtoUniverse/Core/FemtoUniverseTrackSelection.h" @@ -35,11 +32,9 @@ #include "Framework/HistogramRegistry.h" #include "ReconstructionDataFormats/PID.h" -using namespace o2::framework; - -namespace o2::analysis::femtoUniverse +namespace o2::analysis::femtoUniverse // o2-linter: disable=name/namespace { -namespace femtoUniverseCascadeSelection +namespace femtoUniverseCascadeSelection // o2-linter: disable=name/namespace { /// The different selections this task is capable of doing enum CascadeSel { @@ -88,7 +83,7 @@ class FemtoUniverseCascadeSelection public: FemtoUniverseCascadeSelection() - : nPtCascadeMinSel(0), nPtCascadeMaxSel(0), nEtaCascadeMaxSel(0), nDCAV0DaughMax(0), nCPAV0Min(0), nTranRadV0Min(0), nTranRadV0Max(0), nV0DecVtxMax(0), nDCACascadeDaughMax(0), nCPACascadeMin(0), nTranRadCascadeMin(0), nTranRadCascadeMax(0), nDecVtxMax(0), nDCAPosToPV(0), nDCANegToPV(0), nDCABachToPV(0), nDCAV0ToPV(0), pTCascadeMin(9999999.), pTCascadeMax(-9999999.), etaCascadeMax(-9999999.), DCAV0DaughMax(-9999999.), CPAV0Min(9999999.), TranRadV0Min(9999999.), TranRadV0Max(-9999999.), V0DecVtxMax(-9999999.), DCACascadeDaughMax(-9999999.), CPACascadeMin(9999999.), TranRadCascadeMin(9999999.), TranRadCascadeMax(-9999999.), DecVtxMax(-9999999.), DCAPosToPV(9999999.), DCANegToPV(9999999.), DCABachToPV(9999999.), DCAV0ToPV(9999999.), fV0InvMassLowLimit(1.05), fV0InvMassUpLimit(1.3), fInvMassLowLimit(1.25), fInvMassUpLimit(1.4), fRejectCompetingMass(false), fInvMassCompetingLowLimit(1.5), fInvMassCompetingUpLimit(2.0), isCascOmega(false) /*, nSigmaPIDOffsetTPC(0.)*/ + : nPtCascadeMinSel(0), nPtCascadeMaxSel(0), nEtaCascadeMaxSel(0), nDCAV0DaughMax(0), nCPAV0Min(0), nTranRadV0Min(0), nTranRadV0Max(0), nV0DecVtxMax(0), nDCACascadeDaughMax(0), nCPACascadeMin(0), nTranRadCascadeMin(0), nTranRadCascadeMax(0), nDecVtxMax(0), nDCAPosToPV(0), nDCANegToPV(0), nDCABachToPV(0), nDCAV0ToPV(0), pTCascadeMin(9999999.), pTCascadeMax(-9999999.), etaCascadeMax(-9999999.), fDCAV0DaughMax(-9999999.), fCPAV0Min(9999999.), fTranRadV0Min(9999999.), fTranRadV0Max(-9999999.), fV0DecVtxMax(-9999999.), fDCACascadeDaughMax(-9999999.), fCPACascadeMin(9999999.), fTranRadCascadeMin(9999999.), fTranRadCascadeMax(-9999999.), fDecVtxMax(-9999999.), fDCAPosToPV(9999999.), fDCANegToPV(9999999.), fDCABachToPV(9999999.), fDCAV0ToPV(9999999.), fV0InvMassLowLimit(1.05), fV0InvMassUpLimit(1.3), fInvMassLowLimit(1.25), fInvMassUpLimit(1.4), fRejectCompetingMass(false), fInvMassCompetingLowLimit(1.5), fInvMassCompetingUpLimit(2.0), isCascOmega(false) /*, nSigmaPIDOffsetTPC(0.)*/ { } @@ -110,11 +105,11 @@ class FemtoUniverseCascadeSelection T2 selVar, femtoUniverseSelection::SelectionType selType) { if (child == femtoUniverseCascadeSelection::kPosTrack) { - PosDaughTrack.setSelection(selVal, selVar, selType); + posDaughTrack.setSelection(selVal, selVar, selType); } else if (child == femtoUniverseCascadeSelection::kNegTrack) { - NegDaughTrack.setSelection(selVal, selVar, selType); + negDaughTrack.setSelection(selVal, selVar, selType); } else if (child == femtoUniverseCascadeSelection::kBachTrack) { - BachTrack.setSelection(selVal, selVar, selType); + bachTrackSel.setSelection(selVal, selVar, selType); } } @@ -123,11 +118,11 @@ class FemtoUniverseCascadeSelection T& pids) { if (child == femtoUniverseCascadeSelection::kPosTrack) { - PosDaughTrack.setPIDSpecies(pids); + posDaughTrack.setPIDSpecies(pids); } else if (child == femtoUniverseCascadeSelection::kNegTrack) { - NegDaughTrack.setPIDSpecies(pids); + negDaughTrack.setPIDSpecies(pids); } else if (child == femtoUniverseCascadeSelection::kBachTrack) { - BachTrack.setPIDSpecies(pids); + bachTrackSel.setPIDSpecies(pids); } } @@ -140,7 +135,7 @@ class FemtoUniverseCascadeSelection std::string_view suffix = "") { std::string outString = static_cast(prefix); - outString += static_cast(mSelectionNames[iSel]); + outString += static_cast(SelectionNames[iSel]); outString += suffix; return outString; } @@ -153,7 +148,7 @@ class FemtoUniverseCascadeSelection std::string_view prefix = "") { std::string outString = static_cast(prefix); - outString += static_cast(mSelectionHelper[iSel]); + outString += static_cast(SelectionHelper[iSel]); return outString; } @@ -197,20 +192,20 @@ class FemtoUniverseCascadeSelection float pTCascadeMin; float pTCascadeMax; float etaCascadeMax; - float DCAV0DaughMax; - float CPAV0Min; - float TranRadV0Min; - float TranRadV0Max; - float V0DecVtxMax; - float DCACascadeDaughMax; - float CPACascadeMin; - float TranRadCascadeMin; - float TranRadCascadeMax; - float DecVtxMax; - float DCAPosToPV; - float DCANegToPV; - float DCABachToPV; - float DCAV0ToPV; + float fDCAV0DaughMax; + float fCPAV0Min; + float fTranRadV0Min; + float fTranRadV0Max; + float fV0DecVtxMax; + float fDCACascadeDaughMax; + float fCPACascadeMin; + float fTranRadCascadeMin; + float fTranRadCascadeMax; + float fDecVtxMax; + float fDCAPosToPV; + float fDCANegToPV; + float fDCABachToPV; + float fDCAV0ToPV; float fV0InvMassLowLimit; float fV0InvMassUpLimit; @@ -226,13 +221,13 @@ class FemtoUniverseCascadeSelection // float nSigmaPIDOffsetTPC; - FemtoUniverseTrackSelection PosDaughTrack; - FemtoUniverseTrackSelection NegDaughTrack; - FemtoUniverseTrackSelection BachTrack; + FemtoUniverseTrackSelection posDaughTrack; + FemtoUniverseTrackSelection negDaughTrack; + FemtoUniverseTrackSelection bachTrackSel; static constexpr int kNcascadeSelection = 20; // can I do less ? - static constexpr std::string_view mSelectionNames[kNcascadeSelection] = { + static constexpr std::string_view SelectionNames[kNcascadeSelection] = { "Sign", "PtMin", "PtMax", "EtaMax", "DCAv0daughMax", "v0CPAMin", "v0TranRadMin", "v0TranRadMax", "v0DecVecMax", "DCAcascDaugh", "CPAMin", "TranRadMin", "TranRadMax", "DecVtxMax", @@ -265,7 +260,7 @@ class FemtoUniverseCascadeSelection }; ///< Map to match a variable with ///< its type - static constexpr std::string_view mSelectionHelper[kNcascadeSelection] = { + static constexpr std::string_view SelectionHelper[kNcascadeSelection] = { "Cascade particle sign (+1 or -1)", "Minimum pT (GeV/c)", "Maximum pT (GeV/c)", @@ -302,12 +297,12 @@ void FemtoUniverseCascadeSelection::init(HistogramRegistry* registry, bool isSel AxisSpec massAxisCascade = {2200, 1.25f, 1.8f, "m_{Cascade} (GeV/#it{c}^{2})"}; AxisSpec massAxisV0 = {600, 0.0f, 3.0f, "m_{V0} (GeV/#it{c}^{2})"}; - AxisSpec DCADaughAxis = {1000, 0.0f, 2.0f, "DCA (cm)"}; - AxisSpec DCAToPVAxis = {1000, -10.0f, 10.0f, "DCA to PV (cm)"}; + AxisSpec aDCADaughAxis = {1000, 0.0f, 2.0f, "DCA (cm)"}; + AxisSpec aDCAToPVAxis = {1000, -10.0f, 10.0f, "DCA to PV (cm)"}; AxisSpec ptAxis = {100, 0.0f, 10.0f, "#it{p}_{T} (GeV/#it{c})"}; AxisSpec etaAxis = {100, -2.0f, 2.0f, "#it{#eta}"}; AxisSpec phiAxis = {100, 0.0f, 6.0f, "#it{#phi}"}; - AxisSpec CPAAxis = {1000, 0.95f, 1.0f, "#it{cos #theta_{p}}"}; + AxisSpec aCPAAxis = {1000, 0.95f, 1.0f, "#it{cos #theta_{p}}"}; AxisSpec tranRadAxis = {1000, 0.0f, 100.0f, "#it{r}_{xy} (cm)"}; /// \todo this should be an automatic check in the parent class, and the @@ -318,24 +313,24 @@ void FemtoUniverseCascadeSelection::init(HistogramRegistry* registry, bool isSel "container - quitting!"; } - PosDaughTrack.init( mHistogramRegistry); - NegDaughTrack.init( mHistogramRegistry); - BachTrack.init( + bachTrackSel.init( mHistogramRegistry); // V0 (Lambda) // mHistogramRegistry->add("CascadeQA/hInvMassV0NoCuts", "No cuts", kTH1F, {massAxisV0}); mHistogramRegistry->add("CascadeQA/hInvMassV0Cut", "Invariant mass cut", kTH1F, {massAxisV0}); - mHistogramRegistry->add("CascadeQA/hDCAV0Daugh", "V0-daughters DCA", kTH1F, {DCADaughAxis}); - mHistogramRegistry->add("CascadeQA/hV0CPA", "V0 cos PA", kTH1F, {CPAAxis}); + mHistogramRegistry->add("CascadeQA/hDCAV0Daugh", "V0-daughters DCA", kTH1F, {aDCADaughAxis}); + mHistogramRegistry->add("CascadeQA/hV0CPA", "V0 cos PA", kTH1F, {aCPAAxis}); mHistogramRegistry->add("CascadeQA/hV0TranRad", "V0 transverse radius", kTH1F, {tranRadAxis}); // mHistogramRegistry->add("CascadeQA/hV0DecVtxMax", "V0 maximum distance on decay vertex", kTH1F, {massAxisV0}); @@ -345,13 +340,13 @@ void FemtoUniverseCascadeSelection::init(HistogramRegistry* registry, bool isSel mHistogramRegistry->add("CascadeQA/hCascadePt", "pT distribution", kTH1F, {ptAxis}); mHistogramRegistry->add("CascadeQA/hCascadeEta", "Eta distribution", kTH1F, {etaAxis}); mHistogramRegistry->add("CascadeQA/hCascadePhi", "Phi distribution", kTH1F, {phiAxis}); - mHistogramRegistry->add("CascadeQA/hDCACascadeDaugh", "Cascade-daughters DCA", kTH1F, {DCADaughAxis}); - mHistogramRegistry->add("CascadeQA/hCascadeCPA", "Cos PA", kTH1F, {CPAAxis}); + mHistogramRegistry->add("CascadeQA/hDCACascadeDaugh", "Cascade-daughters DCA", kTH1F, {aDCADaughAxis}); + mHistogramRegistry->add("CascadeQA/hCascadeCPA", "Cos PA", kTH1F, {aCPAAxis}); mHistogramRegistry->add("CascadeQA/hCascadeTranRad", "Transverse radius", kTH1F, {tranRadAxis}); - mHistogramRegistry->add("CascadeQA/hDCAPosToPV", "Pos V0 daughter DCA to primary vertex", kTH1F, {DCAToPVAxis}); - mHistogramRegistry->add("CascadeQA/hDCANegToPV", "Neg V0 daughter DCA to primary vertex", kTH1F, {DCAToPVAxis}); - mHistogramRegistry->add("CascadeQA/hDCABachToPV", "Bachelor DCA to primary vertex", kTH1F, {DCAToPVAxis}); - mHistogramRegistry->add("CascadeQA/hDCAV0ToPV", "V0 DCA to primary vertex", kTH1F, {DCAToPVAxis}); + mHistogramRegistry->add("CascadeQA/hDCAPosToPV", "Pos V0 daughter DCA to primary vertex", kTH1F, {aDCAToPVAxis}); + mHistogramRegistry->add("CascadeQA/hDCANegToPV", "Neg V0 daughter DCA to primary vertex", kTH1F, {aDCAToPVAxis}); + mHistogramRegistry->add("CascadeQA/hDCABachToPV", "Bachelor DCA to primary vertex", kTH1F, {aDCAToPVAxis}); + mHistogramRegistry->add("CascadeQA/hDCAV0ToPV", "V0 DCA to primary vertex", kTH1F, {aDCAToPVAxis}); } /// check whether the most open cuts are fulfilled - most of this should have @@ -381,34 +376,34 @@ void FemtoUniverseCascadeSelection::init(HistogramRegistry* registry, bool isSel femtoUniverseSelection::kUpperLimit); etaCascadeMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeetaMax, femtoUniverseSelection::kAbsUpperLimit); - DCAV0DaughMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0DCADaughMax, + fDCAV0DaughMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0DCADaughMax, + femtoUniverseSelection::kUpperLimit); + fCPAV0Min = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0CPAMin, + femtoUniverseSelection::kLowerLimit); + fTranRadV0Min = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0TranRadMin, + femtoUniverseSelection::kLowerLimit); + fTranRadV0Max = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0TranRadMax, femtoUniverseSelection::kUpperLimit); - CPAV0Min = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0CPAMin, - femtoUniverseSelection::kLowerLimit); - TranRadV0Min = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0TranRadMin, - femtoUniverseSelection::kLowerLimit); - TranRadV0Max = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0TranRadMax, - femtoUniverseSelection::kUpperLimit); - V0DecVtxMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0DecVtxMax, - femtoUniverseSelection::kAbsUpperLimit); - DCACascadeDaughMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDCADaughMax, + fV0DecVtxMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0DecVtxMax, + femtoUniverseSelection::kAbsUpperLimit); + fDCACascadeDaughMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDCADaughMax, + femtoUniverseSelection::kUpperLimit); + fCPACascadeMin = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeCPAMin, + femtoUniverseSelection::kLowerLimit); + fTranRadCascadeMin = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeTranRadMin, + femtoUniverseSelection::kLowerLimit); + fTranRadCascadeMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeTranRadMax, femtoUniverseSelection::kUpperLimit); - CPACascadeMin = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeCPAMin, - femtoUniverseSelection::kLowerLimit); - TranRadCascadeMin = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeTranRadMin, - femtoUniverseSelection::kLowerLimit); - TranRadCascadeMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeTranRadMax, - femtoUniverseSelection::kUpperLimit); - DecVtxMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDecVtxMax, - femtoUniverseSelection::kAbsUpperLimit); - DCAPosToPV = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDCAPosToPV, - femtoUniverseSelection::kLowerLimit); - DCANegToPV = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDCANegToPV, - femtoUniverseSelection::kLowerLimit); - DCABachToPV = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDCABachToPV, + fDecVtxMax = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDecVtxMax, + femtoUniverseSelection::kAbsUpperLimit); + fDCAPosToPV = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDCAPosToPV, femtoUniverseSelection::kLowerLimit); - DCAV0ToPV = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDCAV0ToPV, - femtoUniverseSelection::kLowerLimit); + fDCANegToPV = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDCANegToPV, + femtoUniverseSelection::kLowerLimit); + fDCABachToPV = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDCABachToPV, + femtoUniverseSelection::kLowerLimit); + fDCAV0ToPV = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeDCAV0ToPV, + femtoUniverseSelection::kLowerLimit); fV0InvMassLowLimit = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0MassMin, femtoUniverseSelection::kLowerLimit); fV0InvMassUpLimit = getMinimalSelection(femtoUniverseCascadeSelection::kCascadeV0MassMax, @@ -458,70 +453,70 @@ bool FemtoUniverseCascadeSelection::isSelectedMinimal(Col const& col, Casc const if (nEtaCascadeMaxSel > 0 && std::abs(cascade.eta()) > etaCascadeMax) { return false; } - if (nDCAV0DaughMax > 0 && cascade.dcaV0daughters() > DCAV0DaughMax) { + if (nDCAV0DaughMax > 0 && cascade.dcaV0daughters() > fDCAV0DaughMax) { return false; } - if (nCPAV0Min > 0 && cpav0 < CPAV0Min) { + if (nCPAV0Min > 0 && cpav0 < fCPAV0Min) { return false; } - if (nTranRadV0Min > 0 && cascade.v0radius() < TranRadV0Min) { + if (nTranRadV0Min > 0 && cascade.v0radius() < fTranRadV0Min) { return false; } - if (nTranRadV0Max > 0 && cascade.v0radius() > TranRadV0Max) { + if (nTranRadV0Max > 0 && cascade.v0radius() > fTranRadV0Max) { return false; } - if (nDCACascadeDaughMax > 0 && cascade.dcacascdaughters() > DCACascadeDaughMax) { + if (nDCACascadeDaughMax > 0 && cascade.dcacascdaughters() > fDCACascadeDaughMax) { return false; } - if (nCPACascadeMin > 0 && cpaCasc < CPACascadeMin) { + if (nCPACascadeMin > 0 && cpaCasc < fCPACascadeMin) { return false; } - if (nTranRadCascadeMin > 0 && cascade.cascradius() < TranRadCascadeMin) { + if (nTranRadCascadeMin > 0 && cascade.cascradius() < fTranRadCascadeMin) { return false; } - if (nTranRadCascadeMax > 0 && cascade.cascradius() > TranRadCascadeMax) { + if (nTranRadCascadeMax > 0 && cascade.cascradius() > fTranRadCascadeMax) { return false; } for (size_t i = 0; i < decVtx.size(); i++) { - if (nDecVtxMax > 0 && decVtx.at(i) > DecVtxMax) { + if (nDecVtxMax > 0 && decVtx.at(i) > fDecVtxMax) { return false; } } - if (nDCAPosToPV > 0 && abs(cascade.dcapostopv()) < DCAPosToPV) { + if (nDCAPosToPV > 0 && std::abs(cascade.dcapostopv()) < fDCAPosToPV) { return false; } - if (nDCANegToPV > 0 && abs(cascade.dcanegtopv()) < DCANegToPV) { + if (nDCANegToPV > 0 && std::abs(cascade.dcanegtopv()) < fDCANegToPV) { return false; } - if (nDCABachToPV > 0 && abs(cascade.dcabachtopv()) < DCABachToPV) { + if (nDCABachToPV > 0 && std::abs(cascade.dcabachtopv()) < fDCABachToPV) { return false; } - if (nDCAV0ToPV > 0 && abs(dcav0topv) < DCAV0ToPV) { + if (nDCAV0ToPV > 0 && std::abs(dcav0topv) < fDCAV0ToPV) { return false; } - if (!PosDaughTrack.isSelectedMinimal(posTrack)) { + if (!posDaughTrack.isSelectedMinimal(posTrack)) { return false; } - if (!NegDaughTrack.isSelectedMinimal(negTrack)) { + if (!negDaughTrack.isSelectedMinimal(negTrack)) { return false; } - if (!BachTrack.isSelectedMinimal(bachTrack)) { + if (!bachTrackSel.isSelectedMinimal(bachTrack)) { return false; } /* // check that track combinations for V0 or antiV0 would be fulfilling PID - float nSigmaPIDMax = PosDaughTrack.getSigmaPIDMax(); + float nSigmaPIDMax = posDaughTrack.getSigmaPIDMax(); // antiV0 auto nSigmaPrNeg = negTrack.tpcNSigmaPr(); auto nSigmaPiPos = posTrack.tpcNSigmaPi(); // v0 auto nSigmaPiNeg = negTrack.tpcNSigmaPi(); auto nSigmaPrPos = posTrack.tpcNSigmaPr(); - if (!(abs(nSigmaPrNeg - nSigmaPIDOffsetTPC) < nSigmaPIDMax && - abs(nSigmaPiPos - nSigmaPIDOffsetTPC) < nSigmaPIDMax) && - !(abs(nSigmaPrPos - nSigmaPIDOffsetTPC) < nSigmaPIDMax && - abs(nSigmaPiNeg - nSigmaPIDOffsetTPC) < nSigmaPIDMax)) { + if (!(std::abs(nSigmaPrNeg - nSigmaPIDOffsetTPC) < nSigmaPIDMax && + std::abs(nSigmaPiPos - nSigmaPIDOffsetTPC) < nSigmaPIDMax) && + !(std::abs(nSigmaPrPos - nSigmaPIDOffsetTPC) < nSigmaPIDMax && + std::abs(nSigmaPiNeg - nSigmaPIDOffsetTPC) < nSigmaPIDMax)) { return false; } */ @@ -578,12 +573,12 @@ void FemtoUniverseCascadeSelection::fillCascadeQA(Col const& col, Casc const& ca template void FemtoUniverseCascadeSelection::fillQA(Col const& /*col*/, Casc const& /*cascade*/, Track const& posTrack, Track const& negTrack, Track const& bachTrack) { - PosDaughTrack.fillQA(posTrack); - NegDaughTrack.fillQA(negTrack); - BachTrack.fillQA(bachTrack); + bachTrackSel.fillQA(bachTrack); } } // namespace o2::analysis::femtoUniverse diff --git a/PWGCF/FemtoUniverse/Core/FemtoUniverseParticleHisto.h b/PWGCF/FemtoUniverse/Core/FemtoUniverseParticleHisto.h index 409736fd1dd..81572be5cbb 100644 --- a/PWGCF/FemtoUniverse/Core/FemtoUniverseParticleHisto.h +++ b/PWGCF/FemtoUniverse/Core/FemtoUniverseParticleHisto.h @@ -24,10 +24,11 @@ #include #include "PWGCF/FemtoUniverse/DataModel/FemtoDerived.h" #include "Framework/HistogramRegistry.h" +#include "CommonConstants/MathConstants.h" -using namespace o2::framework; +using namespace o2::framework; // o2-linter: disable=using-directive -namespace o2::analysis::femtoUniverse +namespace o2::analysis::femtoUniverse // o2-linter: disable=name/namespace { /// \class FemtoUniverseParticleHisto @@ -50,14 +51,14 @@ class FemtoUniverseParticleHisto /// \param tempFitVarpTAxis axis object for the pT axis in the pT vs. tempFitVar plots /// \param tempFitVarAxis axis object for the tempFitVar axis template - void init_base(std::string folderName, std::string tempFitVarAxisTitle, T& tempFitVarpTAxis, T& tempFitVarAxis) + void init_base(std::string folderName, std::string tempFitVarAxisTitle, T& tempFitVarpTAxis, T& tempFitVarAxis) // o2-linter: disable=name/function-variable { std::string folderSuffix = static_cast(o2::aod::femtouniverseMCparticle::MCTypeName[mc]).c_str(); /// Histograms of the kinematic properties mHistogramRegistry->add((folderName + folderSuffix + "/hPt").c_str(), "; #it{p}_{T} (GeV/#it{c}); Entries", kTH1F, {{240, 0, 6}}); mHistogramRegistry->add((folderName + folderSuffix + "/hEta").c_str(), "; #eta; Entries", kTH1F, {{200, -1.5, 1.5}}); - mHistogramRegistry->add((folderName + folderSuffix + "/hPhi").c_str(), "; #phi; Entries", kTH1F, {{200, 0, 2. * M_PI}}); - mHistogramRegistry->add((folderName + folderSuffix + "/hPhiEta").c_str(), "; #phi; #eta", kTH2F, {{200, 0, 2. * M_PI}, {200, -1.5, 1.5}}); + mHistogramRegistry->add((folderName + folderSuffix + "/hPhi").c_str(), "; #phi; Entries", kTH1F, {{200, 0, o2::constants::math::TwoPI}}); + mHistogramRegistry->add((folderName + folderSuffix + "/hPhiEta").c_str(), "; #phi; #eta", kTH2F, {{200, 0, o2::constants::math::TwoPI}, {200, -1.5, 1.5}}); /// particle specific histogramms for the TempFitVar column in FemtoUniverseParticles if constexpr (o2::aod::femtouniverseMCparticle::MCType::kRecon == mc) { @@ -67,7 +68,7 @@ class FemtoUniverseParticleHisto // comment template - void init_debug(std::string folderName) + void init_debug(std::string folderName) // o2-linter: disable=name/function-variable { std::string folderSuffix = static_cast(o2::aod::femtouniverseMCparticle::MCTypeName[mc]).c_str(); if constexpr (mParticleType == o2::aod::femtouniverseparticle::ParticleType::kTrack || mParticleType == o2::aod::femtouniverseparticle::ParticleType::kV0Child || mParticleType == o2::aod::femtouniverseparticle::ParticleType::kCascadeBachelor || mParticleType == o2::aod::femtouniverseparticle::ParticleType::kMCTruthTrack) { @@ -126,7 +127,7 @@ class FemtoUniverseParticleHisto /// \param tempFitVarpTAxis axis object for the pT axis in the pT vs. tempFitVar plots /// \param tempFitVarAxis axis object for the tempFitVar axis template - void init_MC(std::string folderName, std::string /*tempFitVarAxisTitle*/, T& tempFitVarpTAxis, T& tempFitVarAxis) + void init_MC(std::string folderName, std::string /*tempFitVarAxisTitle*/, T& tempFitVarpTAxis, T& tempFitVarAxis) // o2-linter: disable=name/function-variable { /// Particle-type specific histograms std::string folderSuffix = static_cast(o2::aod::femtouniverseMCparticle::MCTypeName[o2::aod::femtouniverseMCparticle::MCType::kTruth]).c_str(); @@ -221,7 +222,7 @@ class FemtoUniverseParticleHisto /// \tparam T Data type of the particle /// \param part Particle template - void fillQA_base(T const& part, H const& histFolder) + void fillQA_base(T const& part, H const& histFolder) // o2-linter: disable=name/function-variable { /// Histograms of the kinematic properties mHistogramRegistry->fill(histFolder + HIST(o2::aod::femtouniverseMCparticle::MCTypeName[mc]) + HIST("/hPt"), part.pt()); @@ -236,7 +237,7 @@ class FemtoUniverseParticleHisto } template - void fillQA_debug(T const& part, H const& histFolder) + void fillQA_debug(T const& part, H const& histFolder) // o2-linter: disable=name/function-variable { // Histograms holding further debug information if constexpr (mParticleType == o2::aod::femtouniverseparticle::ParticleType::kTrack || mParticleType == o2::aod::femtouniverseparticle::ParticleType::kV0Child || mParticleType == o2::aod::femtouniverseparticle::ParticleType::kCascadeBachelor || mParticleType == o2::aod::femtouniverseparticle::ParticleType::kMCTruthTrack) { @@ -295,13 +296,13 @@ class FemtoUniverseParticleHisto /// \param mctruthorigin Origin of the associated mc Truth particle /// \param pdgcode PDG of the associated mc Truth particle associated to the reconstructed particle part template - void fillQA_MC(T const& part, int mctruthorigin, int pdgcode, H const& histFolder) + void fillQA_MC(T const& part, int mctruthorigin, int pdgcode, H const& histFolder) // o2-linter: disable=name/function-variable { if (mHistogramRegistry) { mHistogramRegistry->fill(histFolder + HIST("_MC/hPDG"), pdgcode); mHistogramRegistry->fill(histFolder + HIST("_MC/hOrigin_MC"), mctruthorigin); - if (abs(pdgcode) == mPDG) { // fill this histogramm only for TRUE protons (independently of their origin) for the track purity estimation + if (std::abs(pdgcode) == mPDG) { // fill this histogramm only for TRUE protons (independently of their origin) for the track purity estimation mHistogramRegistry->fill(histFolder + HIST("_MC/hPt_ReconNoFake"), part.pt()); } @@ -383,9 +384,9 @@ class FemtoUniverseParticleHisto private: HistogramRegistry* mHistogramRegistry; ///< For QA output - static constexpr o2::aod::femtouniverseparticle::ParticleType mParticleType = particleType; ///< Type of the particle under analysis - static constexpr int mFolderSuffixType = suffixType; ///< Counter for the folder suffix specified below - static constexpr std::string_view mFolderSuffix[5] = {"", "_one", "_two", "_pos", "_neg"}; ///< Suffix for the folder name in case of analyses of pairs of the same kind (T-T, V-V, C-C) + static constexpr o2::aod::femtouniverseparticle::ParticleType mParticleType = particleType; ///< Type of the particle under analysis // o2-linter: disable=name/constexpr-constant + static constexpr int mFolderSuffixType = suffixType; ///< Counter for the folder suffix specified below // o2-linter: disable=name/constexpr-constant + static constexpr std::string_view mFolderSuffix[5] = {"", "_one", "_two", "_pos", "_neg"}; ///< Suffix for the folder name in case of analyses of pairs of the same kind (T-T, V-V, C-C) // o2-linter: disable=name/constexpr-constant int mPDG = 0; ///< PDG code of the selected particle }; } // namespace o2::analysis::femtoUniverse diff --git a/PWGCF/FemtoUniverse/Tasks/femtoUniversePairTaskTrackCascadeExtended.cxx b/PWGCF/FemtoUniverse/Tasks/femtoUniversePairTaskTrackCascadeExtended.cxx index 75398b979b5..e0197fb8958 100644 --- a/PWGCF/FemtoUniverse/Tasks/femtoUniversePairTaskTrackCascadeExtended.cxx +++ b/PWGCF/FemtoUniverse/Tasks/femtoUniversePairTaskTrackCascadeExtended.cxx @@ -9,9 +9,11 @@ // granted to it by virtue of its status as an Intergovernmental Organization // or submit itself to any jurisdiction. +/// \file femtoUniversePairTaskTrackCascadeExtended.cxx /// \brief Task for cascade QA; in the future: for cascade correlations /// \author Barbara Chytla, WUT Warsaw, barbara.chytla@cern.ch /// \author Shirajum Monira, WUT Warsaw, shirajum.monira@cern.ch +// o2-linter: disable=name/workflow-file #include #include "Framework/AnalysisTask.h" @@ -35,60 +37,60 @@ using namespace o2::framework::expressions; using namespace o2::analysis::femtoUniverse; using namespace o2::aod::pidutils; -struct femtoUniversePairTaskTrackCascadeExtended { +struct femtoUniversePairTaskTrackCascadeExtended { // o2-linter: disable=name/struct SliceCache cache; using FemtoFullParticles = soa::Join; Preslice perCol = aod::femtouniverseparticle::fdCollisionId; - Configurable ConfZVertexCut{"ConfZVertexCut", 10.f, "Event sel: Maximum z-Vertex (cm)"}; + Configurable confZVertexCut{"ConfZVertexCut", 10.f, "Event sel: Maximum z-Vertex (cm)"}; // o2-linter: disable=name/configurable - Filter collisionFilter = (nabs(aod::collision::posZ) < ConfZVertexCut); + Filter collisionFilter = (nabs(aod::collision::posZ) < confZVertexCut); using FilteredFDCollisions = soa::Filtered; using FilteredFDCollision = FilteredFDCollisions::iterator; - ConfigurableAxis ConfChildTempFitVarpTBins{"ConfChildTempFitVarpTBins", {20, 0.5, 4.05}, "V0 child: pT binning of the pT vs. TempFitVar plot"}; - ConfigurableAxis ConfChildTempFitVarBins{"ConfChildTempFitVarBins", {300, -0.15, 0.15}, "V0 child: binning of the TempFitVar in the pT vs. TempFitVar plot"}; - Configurable ConfCascInvMassLowLimit{"ConfCascInvMassLowLimit", 1.315, "Lower limit of the Casc invariant mass"}; - Configurable ConfCascInvMassUpLimit{"ConfCascInvMassUpLimit", 1.325, "Upper limit of the Casc invariant mass"}; - Configurable ConfCascTranRad{"ConfCascTranRad", 0.5, "Cascade transverse radius"}; + ConfigurableAxis confChildTempFitVarpTBins{"ConfChildTempFitVarpTBins", {20, 0.5, 4.05}, "V0 child: pT binning of the pT vs. TempFitVar plot"}; // o2-linter: disable=name/configurable + ConfigurableAxis confChildTempFitVarBins{"ConfChildTempFitVarBins", {300, -0.15, 0.15}, "V0 child: binning of the TempFitVar in the pT vs. TempFitVar plot"}; // o2-linter: disable=name/configurable + Configurable confCascInvMassLowLimit{"ConfCascInvMassLowLimit", 1.315, "Lower limit of the Casc invariant mass"}; // o2-linter: disable=name/configurable + Configurable confCascInvMassUpLimit{"ConfCascInvMassUpLimit", 1.325, "Upper limit of the Casc invariant mass"}; // o2-linter: disable=name/configurable + Configurable confCascTranRad{"ConfCascTranRad", 0.5, "Cascade transverse radius"}; // o2-linter: disable=name/configurable - Configurable NSigmaTPCPion{"NSigmaTPCPion", 4, "NSigmaTPCPion"}; - Configurable NSigmaTPCProton{"NSigmaTPCProton", 4, "NSigmaTPCProton"}; + Configurable confNSigmaTPCPion{"NSigmaTPCPion", 4, "NSigmaTPCPion"}; // o2-linter: disable=name/configurable + Configurable confNSigmaTPCProton{"NSigmaTPCProton", 4, "NSigmaTPCProton"}; // o2-linter: disable=name/configurable // configs for correlation part - Configurable ConfTrackChoicePartOne{"ConfTrackChoicePartOne", 0, "0:Proton, 1:Pion, 2:Kaon"}; - Configurable ConfTrkPDGCodePartOne{"ConfTrkPDGCodePartOne", 2212, "Particle 1 (Track) - PDG code"}; - Configurable ConfCascType1{"ConfCascType1", 0, "select one of the V0s (Omega = 0, Xi = 1, anti-Omega = 2, anti-Xi = 3) for track-cascade combination"}; - Configurable ConfCascType2{"ConfCascType2", 0, "select one of the V0s (Omega = 0, Xi = 1, anti-Omega = 2, anti-Xi = 3) for cascade-cascade combination"}; - Configurable ConfChargePart1{"ConfChargePart1", 1, "sign of particle 1"}; - Configurable ConfHPtPart1{"ConfHPtPart1", 4.0f, "higher limit for pt of particle 1"}; - Configurable ConfLPtPart1{"ConfLPtPart1", 0.5f, "lower limit for pt of particle 1"}; - Configurable ConfHPtPart2{"ConfHPtPart2", 4.0f, "higher limit for pt of particle 2"}; - Configurable ConfLPtPart2{"ConfLPtPart2", 0.3f, "lower limit for pt of particle 2"}; - Configurable Confmom{"Confmom", 0.75, "momentum threshold for particle identification using TOF"}; - Configurable ConfNsigmaTPCParticle{"ConfNsigmaTPCParticle", 3.0, "TPC Sigma for particle momentum < Confmom"}; - Configurable ConfNsigmaCombinedParticle{"ConfNsigmaCombinedParticle", 3.0, "TPC and TOF Sigma (combined) for particle momentum > Confmom"}; - - ConfigurableAxis ConfkstarBins{"ConfkstarBins", {1500, 0., 6.}, "binning kstar"}; - ConfigurableAxis ConfMultBins{"ConfMultBins", {VARIABLE_WIDTH, 0.0f, 20.0f, 40.0f, 60.0f, 80.0f, 100.0f, 200.0f, 99999.f}, "Mixing bins - multiplicity"}; - ConfigurableAxis ConfkTBins{"ConfkTBins", {150, 0., 9.}, "binning kT"}; - ConfigurableAxis ConfmTBins{"ConfmTBins", {225, 0., 7.5}, "binning mT"}; - ConfigurableAxis ConfmultBins3D{"ConfMultBins3D", {VARIABLE_WIDTH, 0.0f, 20.0f, 30.0f, 40.0f, 99999.0f}, "multiplicity Binning for the 3Dimensional plot: k* vs multiplicity vs mT (set <> to true in order to use)"}; - ConfigurableAxis ConfmTBins3D{"ConfmTBins3D", {VARIABLE_WIDTH, 1.02f, 1.14f, 1.20f, 1.26f, 1.38f, 1.56f, 1.86f, 4.50f}, "mT Binning for the 3Dimensional plot: k* vs multiplicity vs mT (set <> to true in order to use)"}; - Configurable ConfEtaBins{"ConfEtaBins", 29, "Number of eta bins in deta dphi"}; - Configurable ConfPhiBins{"ConfPhiBins", 29, "Number of phi bins in deta dphi"}; - Configurable ConfIsMC{"ConfIsMC", false, "Enable additional Histograms in the case of a MonteCarlo Run"}; - Configurable ConfUse3D{"ConfUse3D", false, "Enable three dimensional histogramms (to be used only for analysis with high statistics): k* vs mT vs multiplicity"}; - ConfigurableAxis ConfVtxBins{"ConfVtxBins", {VARIABLE_WIDTH, -10.0f, -8.f, -6.f, -4.f, -2.f, 0.f, 2.f, 4.f, 6.f, 8.f, 10.f}, "Mixing bins - z-vertex"}; - ConfigurableAxis ConfTrkTempFitVarpTBins{"ConfTrkTempFitVarpTBins", {20, 0.5, 4.05}, "pT binning of the pT vs. TempFitVar plot"}; - ConfigurableAxis ConfTrkTempFitVarBins{"ConfTrkDTempFitVarBins", {300, -0.15, 0.15}, "binning of the TempFitVar in the pT vs. TempFitVar plot"}; + Configurable confTrackChoicePartOne{"ConfTrackChoicePartOne", 0, "0:Proton, 1:Pion, 2:Kaon"}; // o2-linter: disable=name/configurable + Configurable confTrkPDGCodePartOne{"ConfTrkPDGCodePartOne", 2212, "Particle 1 (Track) - PDG code"}; // o2-linter: disable=name/configurable + Configurable confCascType1{"ConfCascType1", 0, "select one of the V0s (Omega = 0, Xi = 1, anti-Omega = 2, anti-Xi = 3) for track-cascade combination"}; // o2-linter: disable=name/configurable + Configurable confCascType2{"ConfCascType2", 0, "select one of the V0s (Omega = 0, Xi = 1, anti-Omega = 2, anti-Xi = 3) for cascade-cascade combination"}; // o2-linter: disable=name/configurable + Configurable confChargePart1{"ConfChargePart1", 1, "sign of particle 1"}; // o2-linter: disable=name/configurable + Configurable confHPtPart1{"ConfHPtPart1", 4.0f, "higher limit for pt of particle 1"}; // o2-linter: disable=name/configurable + Configurable confLPtPart1{"ConfLPtPart1", 0.5f, "lower limit for pt of particle 1"}; // o2-linter: disable=name/configurable + Configurable confHPtPart2{"ConfHPtPart2", 4.0f, "higher limit for pt of particle 2"}; // o2-linter: disable=name/configurable + Configurable confLPtPart2{"ConfLPtPart2", 0.3f, "lower limit for pt of particle 2"}; // o2-linter: disable=name/configurable + Configurable confmom{"Confmom", 0.75, "momentum threshold for particle identification using TOF"}; // o2-linter: disable=name/configurable + Configurable confNsigmaTPCParticle{"ConfNsigmaTPCParticle", 3.0, "TPC Sigma for particle momentum < Confmom"}; // o2-linter: disable=name/configurable + Configurable confNsigmaCombinedParticle{"ConfNsigmaCombinedParticle", 3.0, "TPC and TOF Sigma (combined) for particle momentum > Confmom"}; // o2-linter: disable=name/configurable + + ConfigurableAxis confkstarBins{"ConfkstarBins", {1500, 0., 6.}, "binning kstar"}; // o2-linter: disable=name/configurable + ConfigurableAxis confMultBins{"ConfMultBins", {VARIABLE_WIDTH, 0.0f, 20.0f, 40.0f, 60.0f, 80.0f, 100.0f, 200.0f, 99999.f}, "Mixing bins - multiplicity"}; // o2-linter: disable=name/configurable + ConfigurableAxis confkTBins{"ConfkTBins", {150, 0., 9.}, "binning kT"}; // o2-linter: disable=name/configurable + ConfigurableAxis confmTBins{"ConfmTBins", {225, 0., 7.5}, "binning mT"}; // o2-linter: disable=name/configurable + ConfigurableAxis confmultBins3D{"ConfMultBins3D", {VARIABLE_WIDTH, 0.0f, 20.0f, 30.0f, 40.0f, 99999.0f}, "multiplicity Binning for the 3Dimensional plot: k* vs multiplicity vs mT (set <> to true in order to use)"}; // o2-linter: disable=name/configurable + ConfigurableAxis confmTBins3D{"ConfmTBins3D", {VARIABLE_WIDTH, 1.02f, 1.14f, 1.20f, 1.26f, 1.38f, 1.56f, 1.86f, 4.50f}, "mT Binning for the 3Dimensional plot: k* vs multiplicity vs mT (set <> to true in order to use)"}; // o2-linter: disable=name/configurable + Configurable confEtaBins{"ConfEtaBins", 29, "Number of eta bins in deta dphi"}; // o2-linter: disable=name/configurable + Configurable confPhiBins{"ConfPhiBins", 29, "Number of phi bins in deta dphi"}; // o2-linter: disable=name/configurable + Configurable confIsMC{"ConfIsMC", false, "Enable additional Histograms in the case of a MonteCarlo Run"}; // o2-linter: disable=name/configurable + Configurable confUse3D{"ConfUse3D", false, "Enable three dimensional histogramms (to be used only for analysis with high statistics): k* vs mT vs multiplicity"}; // o2-linter: disable=name/configurable + ConfigurableAxis confVtxBins{"ConfVtxBins", {VARIABLE_WIDTH, -10.0f, -8.f, -6.f, -4.f, -2.f, 0.f, 2.f, 4.f, 6.f, 8.f, 10.f}, "Mixing bins - z-vertex"}; // o2-linter: disable=name/configurable + ConfigurableAxis confTrkTempFitVarpTBins{"ConfTrkTempFitVarpTBins", {20, 0.5, 4.05}, "pT binning of the pT vs. TempFitVar plot"}; // o2-linter: disable=name/configurable + ConfigurableAxis confTrkTempFitVarBins{"ConfTrkDTempFitVarBins", {300, -0.15, 0.15}, "binning of the TempFitVar in the pT vs. TempFitVar plot"}; // o2-linter: disable=name/configurable /// Partition for particle 1 (track) - Partition partsOne = (aod::femtouniverseparticle::partType == uint8_t(aod::femtouniverseparticle::ParticleType::kTrack)) && (aod::femtouniverseparticle::sign == ConfChargePart1) && (aod::femtouniverseparticle::pt < ConfHPtPart1) && (aod::femtouniverseparticle::pt > ConfLPtPart1); + Partition partsOne = (aod::femtouniverseparticle::partType == uint8_t(aod::femtouniverseparticle::ParticleType::kTrack)) && (aod::femtouniverseparticle::sign == confChargePart1) && (aod::femtouniverseparticle::pt < confHPtPart1) && (aod::femtouniverseparticle::pt > confLPtPart1); /// Partition for particle 2 (cascade) - Partition partsTwo = (aod::femtouniverseparticle::partType == uint8_t(aod::femtouniverseparticle::ParticleType::kCascade)) && (aod::femtouniverseparticle::pt < ConfHPtPart2) && (aod::femtouniverseparticle::pt > ConfLPtPart2); + Partition partsTwo = (aod::femtouniverseparticle::partType == uint8_t(aod::femtouniverseparticle::ParticleType::kCascade)) && (aod::femtouniverseparticle::pt < confHPtPart2) && (aod::femtouniverseparticle::pt > confLPtPart2); /// Partition for cascades Partition cascs = (aod::femtouniverseparticle::partType == uint8_t(aod::femtouniverseparticle::ParticleType::kCascade)); @@ -113,103 +115,103 @@ struct femtoUniversePairTaskTrackCascadeExtended { // Table to select cascade daughters // Charges: = +--, +--, +-+, +-+ - static constexpr UInt_t CascChildTable[][3] = {{0, 1, 2}, {0, 1, 1}, {1, 0, 2}, {1, 0, 1}}; + static constexpr unsigned int CascChildTable[][3] = {{0, 1, 2}, {0, 1, 1}, {1, 0, 2}, {1, 0, 1}}; bool invMCascade(float invMassCascade, float invMassAntiCascade) { - if ((invMassCascade < ConfCascInvMassLowLimit || invMassCascade > ConfCascInvMassUpLimit) && (invMassAntiCascade < ConfCascInvMassLowLimit || invMassAntiCascade > ConfCascInvMassUpLimit)) { + if ((invMassCascade < confCascInvMassLowLimit || invMassCascade > confCascInvMassUpLimit) && (invMassAntiCascade < confCascInvMassLowLimit || invMassAntiCascade > confCascInvMassUpLimit)) { return false; } return true; } - bool IsNSigmaTPC(float nsigmaTPCParticle) + bool isNSigmaTPC(float nsigmaTPCParticle) { - if (TMath::Abs(nsigmaTPCParticle) < ConfNsigmaTPCParticle) { + if (std::abs(nsigmaTPCParticle) < confNsigmaTPCParticle) { return true; } else { return false; } } - bool IsNSigmaCombined(float mom, float nsigmaTPCParticle, float nsigmaTOFParticle) + bool isNSigmaCombined(float mom, float nsigmaTPCParticle, float nsigmaTOFParticle) { - if (mom <= Confmom) { - return (TMath::Abs(nsigmaTPCParticle) < ConfNsigmaTPCParticle); + if (mom <= confmom) { + return (std::abs(nsigmaTPCParticle) < confNsigmaTPCParticle); } else { - return (TMath::Hypot(nsigmaTOFParticle, nsigmaTPCParticle) < ConfNsigmaCombinedParticle); + return (TMath::Hypot(nsigmaTOFParticle, nsigmaTPCParticle) < confNsigmaCombinedParticle); // o2-linter: disable=root-entity } } template - bool IsParticleTPC(const T& part, int id) + bool isParticleTPC(const T& part, int id) { const float tpcNSigmas[3] = {unPackInTable(part.tpcNSigmaStorePr()), unPackInTable(part.tpcNSigmaStorePi()), unPackInTable(part.tpcNSigmaStoreKa())}; - return IsNSigmaTPC(tpcNSigmas[id]); + return isNSigmaTPC(tpcNSigmas[id]); } template - bool IsParticleCombined(const T& part, int id) + bool isParticleCombined(const T& part, int id) { const float tpcNSigmas[3] = {unPackInTable(part.tpcNSigmaStorePr()), unPackInTable(part.tpcNSigmaStorePi()), unPackInTable(part.tpcNSigmaStoreKa())}; const float tofNSigmas[3] = {unPackInTable(part.tofNSigmaStorePr()), unPackInTable(part.tofNSigmaStorePi()), unPackInTable(part.tofNSigmaStoreKa())}; - return IsNSigmaCombined(part.p(), tpcNSigmas[id], tofNSigmas[id]); + return isNSigmaCombined(part.p(), tpcNSigmas[id], tofNSigmas[id]); } void init(InitContext const&) { // Axes - AxisSpec XiMassAxis = {200, 1.28f, 1.36f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; + AxisSpec aXiMassAxis = {200, 1.28f, 1.36f, "#it{M}_{inv} [GeV/#it{c}^{2}]"}; AxisSpec ptAxis = {100, 0.0f, 10.0f, "#it{p}_{T} (GeV/#it{c})"}; AxisSpec etaAxis = {100, -2.0f, 2.0f, "#it{#eta}"}; AxisSpec phiAxis = {100, 0.0f, 6.0f, "#it{#phi}"}; - AxisSpec DCADaughAxis = {1000, 0.0f, 2.0f, "DCA (cm)"}; - AxisSpec CPAAxis = {1000, 0.95f, 1.0f, "#it{cos #theta_{p}}"}; + AxisSpec aDCADaughAxis = {1000, 0.0f, 2.0f, "DCA (cm)"}; + AxisSpec aCPAAxis = {1000, 0.95f, 1.0f, "#it{cos #theta_{p}}"}; AxisSpec tranRadAxis = {1000, 0.0f, 100.0f, "#it{r}_{xy} (cm)"}; - AxisSpec DCAToPVAxis = {1000, -10.0f, 10.0f, "DCA to PV (cm)"}; + AxisSpec aDCAToPVAxis = {1000, -10.0f, 10.0f, "DCA to PV (cm)"}; // Histograms - rXiQA.add("hMassXi", "hMassXi", {HistType::kTH1F, {XiMassAxis}}); - rXiQA.add("hMassXiSelected", "hMassXiSelected", {HistType::kTH1F, {XiMassAxis}}); + rXiQA.add("hMassXi", "hMassXi", {HistType::kTH1F, {aXiMassAxis}}); + rXiQA.add("hMassXiSelected", "hMassXiSelected", {HistType::kTH1F, {aXiMassAxis}}); rXiQA.add("hPtXi", "hPtXi", {HistType::kTH1F, {{ptAxis}}}); rXiQA.add("hEtaXi", "hEtaXi", {HistType::kTH1F, {{etaAxis}}}); rXiQA.add("hPhiXi", "hPhiXi", {HistType::kTH1F, {{phiAxis}}}); - rXiQA.add("hDCAV0Daughters", "hDCAV0Daughters", {HistType::kTH1F, {DCADaughAxis}}); - rXiQA.add("hV0CosPA", "hV0CosPA", {HistType::kTH1F, {CPAAxis}}); + rXiQA.add("hDCAV0Daughters", "hDCAV0Daughters", {HistType::kTH1F, {aDCADaughAxis}}); + rXiQA.add("hV0CosPA", "hV0CosPA", {HistType::kTH1F, {aCPAAxis}}); rXiQA.add("hV0TranRad", "hV0TranRad", {HistType::kTH1F, {tranRadAxis}}); - rXiQA.add("hDCACascDaughters", "hDCACascDaughters", {HistType::kTH1F, {DCADaughAxis}}); - rXiQA.add("hCascCosPA", "hCascCosPA", {HistType::kTH1F, {CPAAxis}}); + rXiQA.add("hDCACascDaughters", "hDCACascDaughters", {HistType::kTH1F, {aDCADaughAxis}}); + rXiQA.add("hCascCosPA", "hCascCosPA", {HistType::kTH1F, {aCPAAxis}}); rXiQA.add("hCascTranRad", "hCascTranRad", {HistType::kTH1F, {tranRadAxis}}); - rXiQA.add("hDcaPostoPV", "hDcaPostoPV", {HistType::kTH1F, {DCAToPVAxis}}); - rXiQA.add("hDcaNegtoPV", "hDcaNegtoPV", {HistType::kTH1F, {DCAToPVAxis}}); - rXiQA.add("hDcaBachtoPV", "hDcaBachtoPV", {HistType::kTH1F, {DCAToPVAxis}}); - rXiQA.add("hDcaV0toPV", "hDcaV0toPV", {HistType::kTH1F, {DCAToPVAxis}}); + rXiQA.add("hDcaPostoPV", "hDcaPostoPV", {HistType::kTH1F, {aDCAToPVAxis}}); + rXiQA.add("hDcaNegtoPV", "hDcaNegtoPV", {HistType::kTH1F, {aDCAToPVAxis}}); + rXiQA.add("hDcaBachtoPV", "hDcaBachtoPV", {HistType::kTH1F, {aDCAToPVAxis}}); + rXiQA.add("hDcaV0toPV", "hDcaV0toPV", {HistType::kTH1F, {aDCAToPVAxis}}); qaRegistry.add("Tracks_pos/nSigmaTPC", "; #it{p} (GeV/#it{c}); n#sigma_{TPC}", kTH2F, {{100, 0, 10}, {200, -4.975, 5.025}}); qaRegistry.add("Tracks_pos/nSigmaTOF", "; #it{p} (GeV/#it{c}); n#sigma_{TOF}", kTH2F, {{100, 0, 10}, {200, -4.975, 5.025}}); qaRegistry.add("Tracks_neg/nSigmaTPC", "; #it{p} (GeV/#it{c}); n#sigma_{TPC}", kTH2F, {{100, 0, 10}, {200, -4.975, 5.025}}); qaRegistry.add("Tracks_neg/nSigmaTOF", "; #it{p} (GeV/#it{c}); n#sigma_{TOF}", kTH2F, {{100, 0, 10}, {200, -4.975, 5.025}}); - trackHistoPartOnePos.init(&qaRegistry, ConfTrkTempFitVarpTBins, ConfTrkTempFitVarBins, ConfIsMC, ConfTrkPDGCodePartOne); - trackHistoPartOneNeg.init(&qaRegistry, ConfTrkTempFitVarpTBins, ConfTrkTempFitVarBins, ConfIsMC, ConfTrkPDGCodePartOne); - posChildHistos.init(&qaRegistry, ConfChildTempFitVarpTBins, ConfChildTempFitVarBins, false, 0, true); - negChildHistos.init(&qaRegistry, ConfChildTempFitVarpTBins, ConfChildTempFitVarBins, false, 0, true); - bachHistos.init(&qaRegistry, ConfChildTempFitVarpTBins, ConfChildTempFitVarBins, false, 0, true, "hBachelor"); - cascQAHistos.init(&qaRegistry, ConfChildTempFitVarpTBins, ConfChildTempFitVarBins, false, 0, true); + trackHistoPartOnePos.init(&qaRegistry, confTrkTempFitVarpTBins, confTrkTempFitVarBins, confIsMC, confTrkPDGCodePartOne); + trackHistoPartOneNeg.init(&qaRegistry, confTrkTempFitVarpTBins, confTrkTempFitVarBins, confIsMC, confTrkPDGCodePartOne); + posChildHistos.init(&qaRegistry, confChildTempFitVarpTBins, confChildTempFitVarBins, false, 0, true); + negChildHistos.init(&qaRegistry, confChildTempFitVarpTBins, confChildTempFitVarBins, false, 0, true); + bachHistos.init(&qaRegistry, confChildTempFitVarpTBins, confChildTempFitVarBins, false, 0, true, "hBachelor"); + cascQAHistos.init(&qaRegistry, confChildTempFitVarpTBins, confChildTempFitVarBins, false, 0, true); - sameEventCont.init(&resultRegistry, ConfkstarBins, ConfMultBins, ConfkTBins, ConfmTBins, ConfmultBins3D, ConfmTBins3D, ConfEtaBins, ConfPhiBins, ConfIsMC, ConfUse3D); - mixedEventCont.init(&resultRegistry, ConfkstarBins, ConfMultBins, ConfkTBins, ConfmTBins, ConfmultBins3D, ConfmTBins3D, ConfEtaBins, ConfPhiBins, ConfIsMC, ConfUse3D); + sameEventCont.init(&resultRegistry, confkstarBins, confMultBins, confkTBins, confmTBins, confmultBins3D, confmTBins3D, confEtaBins, confPhiBins, confIsMC, confUse3D); + mixedEventCont.init(&resultRegistry, confkstarBins, confMultBins, confkTBins, confmTBins, confmultBins3D, confmTBins3D, confEtaBins, confPhiBins, confIsMC, confUse3D); pairCleaner.init(&qaRegistry); } - void processCascades(FilteredFDCollision& col, FemtoFullParticles& parts) + void processCascades(const FilteredFDCollision& col, const FemtoFullParticles& parts) { auto groupCascs = cascs->sliceByCached(aod::femtouniverseparticle::fdCollisionId, col.globalIndex(), cache); // const int multCol = col.multNtr(); - for (auto& casc : groupCascs) { + for (const auto& casc : groupCascs) { rXiQA.fill(HIST("hMassXi"), casc.mLambda()); // if (!invMCascade(casc.mLambda(), casc.mAntiLambda())) @@ -219,28 +221,28 @@ struct femtoUniversePairTaskTrackCascadeExtended { const auto& negChild = parts.iteratorAt(casc.index() - 2); const auto& bachelor = parts.iteratorAt(casc.index() - 1); - // if (casc.transRadius() < ConfCascTranRad) + // if (casc.transRadius() < confCascTranRad) // continue; // std::cout< NSigmaTPCProton) { + if (std::abs(posChild.tpcNSigmaPr()) > confNSigmaTPCProton) { continue; } - if (TMath::Abs(negChild.tpcNSigmaPi()) > NSigmaTPCPion) { + if (std::abs(negChild.tpcNSigmaPi()) > confNSigmaTPCPion) { continue; } } else { - if (TMath::Abs(negChild.tpcNSigmaPr()) > NSigmaTPCProton) { + if (std::abs(negChild.tpcNSigmaPr()) > confNSigmaTPCProton) { continue; } - if (TMath::Abs(posChild.tpcNSigmaPi()) > NSigmaTPCPion) { + if (std::abs(posChild.tpcNSigmaPi()) > confNSigmaTPCPion) { continue; } } - if (TMath::Abs(bachelor.tpcNSigmaPi()) > NSigmaTPCPion) { + if (std::abs(bachelor.tpcNSigmaPi()) > confNSigmaTPCPion) { continue; } @@ -266,12 +268,12 @@ struct femtoUniversePairTaskTrackCascadeExtended { } PROCESS_SWITCH(femtoUniversePairTaskTrackCascadeExtended, processCascades, "Enable processing cascades", false); /// track - cascade - void processSameEvent(FilteredFDCollision& col, FemtoFullParticles& parts) + void processSameEvent(const FilteredFDCollision& col, const FemtoFullParticles& parts) { auto groupPartsOne = partsOne->sliceByCached(aod::femtouniverseparticle::fdCollisionId, col.globalIndex(), cache); auto groupPartsTwo = partsTwo->sliceByCached(aod::femtouniverseparticle::fdCollisionId, col.globalIndex(), cache); - for (auto& part : groupPartsTwo) { + for (const auto& part : groupPartsTwo) { if (!invMCascade(part.mLambda(), part.mAntiLambda())) continue; @@ -281,7 +283,7 @@ struct femtoUniversePairTaskTrackCascadeExtended { const auto& negChild = parts.iteratorAt(part.index() - 2); const auto& bachelor = parts.iteratorAt(part.index() - 1); /// Child particles must pass this condition to be selected - if (!IsParticleTPC(posChild, CascChildTable[ConfCascType1][0]) || !IsParticleTPC(negChild, CascChildTable[ConfCascType1][1]) || !IsParticleTPC(bachelor, CascChildTable[ConfCascType1][2])) + if (!isParticleTPC(posChild, CascChildTable[confCascType1][0]) || !isParticleTPC(negChild, CascChildTable[confCascType1][1]) || !isParticleTPC(bachelor, CascChildTable[confCascType1][2])) continue; posChildHistos.fillQA(posChild); @@ -289,31 +291,31 @@ struct femtoUniversePairTaskTrackCascadeExtended { bachHistos.fillQABase(bachelor, HIST("hBachelor")); } - for (auto& part : groupPartsOne) { + for (const auto& part : groupPartsOne) { /// PID plot for track particle const float tpcNSigmas[3] = {unPackInTable(part.tpcNSigmaStorePr()), unPackInTable(part.tpcNSigmaStorePi()), unPackInTable(part.tpcNSigmaStoreKa())}; const float tofNSigmas[3] = {unPackInTable(part.tofNSigmaStorePr()), unPackInTable(part.tofNSigmaStorePi()), unPackInTable(part.tofNSigmaStoreKa())}; - if (!IsNSigmaCombined(part.p(), tpcNSigmas[ConfTrackChoicePartOne], tofNSigmas[ConfTrackChoicePartOne])) + if (!isNSigmaCombined(part.p(), tpcNSigmas[confTrackChoicePartOne], tofNSigmas[confTrackChoicePartOne])) continue; if (part.sign() > 0) { - qaRegistry.fill(HIST("Tracks_pos/nSigmaTPC"), part.p(), tpcNSigmas[ConfTrackChoicePartOne]); - qaRegistry.fill(HIST("Tracks_pos/nSigmaTOF"), part.p(), tofNSigmas[ConfTrackChoicePartOne]); + qaRegistry.fill(HIST("Tracks_pos/nSigmaTPC"), part.p(), tpcNSigmas[confTrackChoicePartOne]); + qaRegistry.fill(HIST("Tracks_pos/nSigmaTOF"), part.p(), tofNSigmas[confTrackChoicePartOne]); trackHistoPartOnePos.fillQA(part); } else if (part.sign() < 0) { - qaRegistry.fill(HIST("Tracks_neg/nSigmaTPC"), part.p(), tpcNSigmas[ConfTrackChoicePartOne]); - qaRegistry.fill(HIST("Tracks_neg/nSigmaTOF"), part.p(), tofNSigmas[ConfTrackChoicePartOne]); + qaRegistry.fill(HIST("Tracks_neg/nSigmaTPC"), part.p(), tpcNSigmas[confTrackChoicePartOne]); + qaRegistry.fill(HIST("Tracks_neg/nSigmaTOF"), part.p(), tofNSigmas[confTrackChoicePartOne]); trackHistoPartOneNeg.fillQA(part); } } - for (auto& [p1, p2] : combinations(CombinationsFullIndexPolicy(groupPartsOne, groupPartsTwo))) { + for (const auto& [p1, p2] : combinations(CombinationsFullIndexPolicy(groupPartsOne, groupPartsTwo))) { // Cascade invariant mass cut if (!invMCascade(p2.mLambda(), p2.mAntiLambda())) continue; // PID - if (!IsParticleCombined(p1, ConfTrackChoicePartOne)) + if (!isParticleCombined(p1, confTrackChoicePartOne)) continue; // track cleaning if (!pairCleaner.isCleanPair(p1, p2, parts)) { @@ -323,19 +325,19 @@ struct femtoUniversePairTaskTrackCascadeExtended { const auto& negChild = parts.iteratorAt(p2.index() - 2); const auto& bachelor = parts.iteratorAt(p2.index() - 1); /// Child particles must pass this condition to be selected - if (!IsParticleTPC(posChild, CascChildTable[ConfCascType1][0]) || !IsParticleTPC(negChild, CascChildTable[ConfCascType1][1]) || !IsParticleTPC(bachelor, CascChildTable[ConfCascType1][2])) + if (!isParticleTPC(posChild, CascChildTable[confCascType1][0]) || !isParticleTPC(negChild, CascChildTable[confCascType1][1]) || !isParticleTPC(bachelor, CascChildTable[confCascType1][2])) continue; - sameEventCont.setPair(p1, p2, col.multNtr(), ConfUse3D, 1.0f); + sameEventCont.setPair(p1, p2, col.multNtr(), confUse3D, 1.0f); } } PROCESS_SWITCH(femtoUniversePairTaskTrackCascadeExtended, processSameEvent, "Enable processing same event for track - cascade", false); /// cascade - cascade - void processSameEventCasc(FilteredFDCollision& col, FemtoFullParticles& parts) + void processSameEventCasc(const FilteredFDCollision& col, const FemtoFullParticles& parts) { auto groupPartsTwo = partsTwo->sliceByCached(aod::femtouniverseparticle::fdCollisionId, col.globalIndex(), cache); - for (auto& part : groupPartsTwo) { + for (const auto& part : groupPartsTwo) { if (!invMCascade(part.mLambda(), part.mAntiLambda())) continue; @@ -345,14 +347,14 @@ struct femtoUniversePairTaskTrackCascadeExtended { const auto& negChild = parts.iteratorAt(part.index() - 2); const auto& bachelor = parts.iteratorAt(part.index() - 1); /// Check daughters of first cascade - if (IsParticleTPC(posChild, CascChildTable[ConfCascType1][0]) && IsParticleTPC(negChild, CascChildTable[ConfCascType1][1]) && IsParticleTPC(bachelor, CascChildTable[ConfCascType1][2])) { + if (isParticleTPC(posChild, CascChildTable[confCascType1][0]) && isParticleTPC(negChild, CascChildTable[confCascType1][1]) && isParticleTPC(bachelor, CascChildTable[confCascType1][2])) { posChildHistos.fillQA(posChild); negChildHistos.fillQA(negChild); bachHistos.fillQABase(bachelor, HIST("hBachelor")); } /// Check daughters of second cascade - /*if (IsParticleTPC(posChild, CascChildTable[ConfCascType2][0]) && IsParticleTPC(negChild, CascChildTable[ConfCascType2][1]) && IsParticleTPC(bachelor, CascChildTable[ConfCascType2][2])) { + /*if (isParticleTPC(posChild, CascChildTable[confCascType2][0]) && isParticleTPC(negChild, CascChildTable[confCascType2][1]) && isParticleTPC(bachelor, CascChildTable[confCascType2][2])) { }*/ } @@ -371,36 +373,36 @@ struct femtoUniversePairTaskTrackCascadeExtended { const auto& negChild1 = parts.iteratorAt(p1.index() - 2); const auto& bachelor1 = parts.iteratorAt(p1.index() - 1); /// Child particles must pass this condition to be selected - if (!IsParticleTPC(posChild1, CascChildTable[ConfCascType1][0]) || !IsParticleTPC(negChild1, CascChildTable[ConfCascType1][1]) || !IsParticleTPC(bachelor1, CascChildTable[ConfCascType1][2])) + if (!isParticleTPC(posChild1, CascChildTable[confCascType1][0]) || !isParticleTPC(negChild1, CascChildTable[confCascType1][1]) || !isParticleTPC(bachelor1, CascChildTable[confCascType1][2])) return; const auto& posChild2 = parts.iteratorAt(p2.index() - 3); const auto& negChild2 = parts.iteratorAt(p2.index() - 2); const auto& bachelor2 = parts.iteratorAt(p2.index() - 1); /// Child particles must pass this condition to be selected - if (!IsParticleTPC(posChild2, CascChildTable[ConfCascType2][0]) || !IsParticleTPC(negChild2, CascChildTable[ConfCascType2][1]) || !IsParticleTPC(bachelor2, CascChildTable[ConfCascType2][2])) + if (!isParticleTPC(posChild2, CascChildTable[confCascType2][0]) || !isParticleTPC(negChild2, CascChildTable[confCascType2][1]) || !isParticleTPC(bachelor2, CascChildTable[confCascType2][2])) return; - sameEventCont.setPair(p1, p2, col.multNtr(), ConfUse3D, 1.0f); + sameEventCont.setPair(p1, p2, col.multNtr(), confUse3D, 1.0f); }; - if (ConfCascType1 == ConfCascType2) { + if (confCascType1 == confCascType2) { /// Now build the combinations for identical cascades - for (auto& [p1, p2] : combinations(CombinationsStrictlyUpperIndexPolicy(groupPartsTwo, groupPartsTwo))) { + for (const auto& [p1, p2] : combinations(CombinationsStrictlyUpperIndexPolicy(groupPartsTwo, groupPartsTwo))) { pairProcessFunc(p1, p2); } } else { /// Now build the combinations for non-identical cascades - for (auto& [p1, p2] : combinations(CombinationsFullIndexPolicy(groupPartsTwo, groupPartsTwo))) { + for (const auto& [p1, p2] : combinations(CombinationsFullIndexPolicy(groupPartsTwo, groupPartsTwo))) { pairProcessFunc(p1, p2); } } } PROCESS_SWITCH(femtoUniversePairTaskTrackCascadeExtended, processSameEventCasc, "Enable processing same event for cascade - cascade", false); /// track - cascade - void processMixedEvent(FilteredFDCollisions& cols, FemtoFullParticles& parts) + void processMixedEvent(const FilteredFDCollisions& cols, const FemtoFullParticles& parts) { - ColumnBinningPolicy colBinning{{ConfVtxBins, ConfMultBins}, true}; + ColumnBinningPolicy colBinning{{confVtxBins, confMultBins}, true}; - for (auto& [collision1, collision2] : soa::selfCombinations(colBinning, 5, -1, cols, cols)) { + for (const auto& [collision1, collision2] : soa::selfCombinations(colBinning, 5, -1, cols, cols)) { auto groupPartsOne = partsOne->sliceByCached(aod::femtouniverseparticle::fdCollisionId, collision1.globalIndex(), cache); auto groupPartsTwo = partsTwo->sliceByCached(aod::femtouniverseparticle::fdCollisionId, collision2.globalIndex(), cache); @@ -411,36 +413,36 @@ struct femtoUniversePairTaskTrackCascadeExtended { if (magFieldTesla1 != magFieldTesla2) { continue; } - for (auto& [p1, p2] : combinations(CombinationsFullIndexPolicy(groupPartsOne, groupPartsTwo))) { + for (const auto& [p1, p2] : combinations(CombinationsFullIndexPolicy(groupPartsOne, groupPartsTwo))) { // Cascade invariant mass cut if (!invMCascade(p2.mLambda(), p2.mAntiLambda())) continue; // PID - if (!IsParticleCombined(p1, ConfTrackChoicePartOne)) + if (!isParticleCombined(p1, confTrackChoicePartOne)) continue; const auto& posChild = parts.iteratorAt(p2.index() - 3); const auto& negChild = parts.iteratorAt(p2.index() - 2); const auto& bachelor = parts.iteratorAt(p2.index() - 1); /// Child particles must pass this condition to be selected - if (!IsParticleTPC(posChild, CascChildTable[ConfCascType1][0]) || !IsParticleTPC(negChild, CascChildTable[ConfCascType1][1]) || !IsParticleTPC(bachelor, CascChildTable[ConfCascType1][2])) + if (!isParticleTPC(posChild, CascChildTable[confCascType1][0]) || !isParticleTPC(negChild, CascChildTable[confCascType1][1]) || !isParticleTPC(bachelor, CascChildTable[confCascType1][2])) continue; // track cleaning if (!pairCleaner.isCleanPair(p1, p2, parts)) { continue; } - mixedEventCont.setPair(p1, p2, collision1.multNtr(), ConfUse3D, 1.0f); + mixedEventCont.setPair(p1, p2, collision1.multNtr(), confUse3D, 1.0f); } } } PROCESS_SWITCH(femtoUniversePairTaskTrackCascadeExtended, processMixedEvent, "Enable processing mixed event for track - cascade", false); /// cascade - cascade - void processMixedEventCasc(FilteredFDCollisions& cols, FemtoFullParticles& parts) + void processMixedEventCasc(const FilteredFDCollisions& cols, const FemtoFullParticles& parts) { - ColumnBinningPolicy colBinning{{ConfVtxBins, ConfMultBins}, true}; + ColumnBinningPolicy colBinning{{confVtxBins, confMultBins}, true}; - for (auto& [collision1, collision2] : soa::selfCombinations(colBinning, 5, -1, cols, cols)) { + for (const auto& [collision1, collision2] : soa::selfCombinations(colBinning, 5, -1, cols, cols)) { auto groupPartsOne = partsTwo->sliceByCached(aod::femtouniverseparticle::fdCollisionId, collision1.globalIndex(), cache); auto groupPartsTwo = partsTwo->sliceByCached(aod::femtouniverseparticle::fdCollisionId, collision2.globalIndex(), cache); @@ -451,7 +453,7 @@ struct femtoUniversePairTaskTrackCascadeExtended { if (magFieldTesla1 != magFieldTesla2) { continue; } - for (auto& [p1, p2] : combinations(CombinationsFullIndexPolicy(groupPartsOne, groupPartsTwo))) { + for (const auto& [p1, p2] : combinations(CombinationsFullIndexPolicy(groupPartsOne, groupPartsTwo))) { // Cascade invariant mass cut for p1 if (!invMCascade(p1.mLambda(), p1.mAntiLambda())) continue; @@ -463,20 +465,20 @@ struct femtoUniversePairTaskTrackCascadeExtended { const auto& negChild1 = parts.iteratorAt(p1.index() - 2); const auto& bachelor1 = parts.iteratorAt(p1.index() - 1); /// Child particles must pass this condition to be selected - if (!IsParticleTPC(posChild1, CascChildTable[ConfCascType1][0]) || !IsParticleTPC(negChild1, CascChildTable[ConfCascType1][1]) || !IsParticleTPC(bachelor1, CascChildTable[ConfCascType1][2])) + if (!isParticleTPC(posChild1, CascChildTable[confCascType1][0]) || !isParticleTPC(negChild1, CascChildTable[confCascType1][1]) || !isParticleTPC(bachelor1, CascChildTable[confCascType1][2])) return; const auto& posChild2 = parts.iteratorAt(p2.index() - 3); const auto& negChild2 = parts.iteratorAt(p2.index() - 2); const auto& bachelor2 = parts.iteratorAt(p2.index() - 1); /// Child particles must pass this condition to be selected - if (!IsParticleTPC(posChild2, CascChildTable[ConfCascType2][0]) || !IsParticleTPC(negChild2, CascChildTable[ConfCascType2][1]) || !IsParticleTPC(bachelor2, CascChildTable[ConfCascType2][2])) + if (!isParticleTPC(posChild2, CascChildTable[confCascType2][0]) || !isParticleTPC(negChild2, CascChildTable[confCascType2][1]) || !isParticleTPC(bachelor2, CascChildTable[confCascType2][2])) return; // track cleaning if (!pairCleaner.isCleanPair(p1, p2, parts)) { continue; } - mixedEventCont.setPair(p1, p2, collision1.multNtr(), ConfUse3D, 1.0f); + mixedEventCont.setPair(p1, p2, collision1.multNtr(), confUse3D, 1.0f); } } }