2020#include " PWGHF/HFC/DataModel/CorrelationTables.h"
2121#include " PWGHF/HFC/Utils/utilsCorrelations.h"
2222#include " PWGHF/Utils/utilsAnalysis.h"
23+ #include " PWGLF/DataModel/LFStrangenessPIDTables.h"
2324#include " PWGLF/DataModel/LFStrangenessTables.h"
2425
2526#include " Common/CCDB/EventSelectionParams.h"
@@ -377,14 +378,14 @@ struct HfCorrelatorXicHadrons {
377378 } cfgXicCand;
378379
379380 struct : ConfigurableGroup {
380- Configurable<float > cfgDaughPrPtMax{ " cfgDaughPrPtMax " , 5 ., " max. pT Daughter Proton" };
381- Configurable<float > cfgDaughPrPtMin{ " cfgDaughPrPtMin " , 0.3 , " min. pT Daughter Proton" };
382- Configurable<float > cfgDaughPiPtMax{ " cfgDaughPiPtMax " , 10 ., " max. pT Daughter Pion" };
383- Configurable<float > cfgDaughPiPtMin{ " cfgDaughPiPtMin " , 0.3 , " min. pT Daughter Pion" };
384- Configurable<float > cfgDaughPIDCutsTPCPr{ " cfgDaughPIDCutsTPCPr " , 2.5 , " max. TPCnSigma Proton" };
385- Configurable<float > cfgDaughPIDCutsTPCPi{ " cfgDaughPIDCutsTPCPi " , 2.5 , " max. TPCnSigma Pion" };
386- Configurable<float > cfgDaughPIDCutsTOFPi{ " cfgDaughPIDCutsTOFPi " , 2.5 , " max. TOFnSigma Pion" };
387- Configurable<float > cfgDaughPIDCutsTOFPr{ " cfgDaughPIDCutsTOFPr " , 2.5 , " max . TOFnSigma Pion " };
381+ Configurable<float > cfgV0DaughPrPtMax{ " cfgV0DaughPrPtMax " , 5 ., " max. pT Daughter Proton" };
382+ Configurable<float > cfgV0DaughPrPtMin{ " cfgV0DaughPrPtMin " , 0.3 , " min. pT Daughter Proton" };
383+ Configurable<float > cfgV0DaughPiPtMax{ " cfgV0DaughPiPtMax " , 10 ., " max. pT Daughter Pion" };
384+ Configurable<float > cfgV0DaughPiPtMin{ " cfgV0DaughPiPtMin " , 0.3 , " min. pT Daughter Pion" };
385+ Configurable<float > cfgV0DaughPIDCutsTPCPr{ " cfgV0DaughPIDCutsTPCPr " , 2.5 , " max. TPCnSigma Proton" };
386+ Configurable<float > cfgV0DaughPIDCutsTPCPi{ " cfgV0DaughPIDCutsTPCPi " , 2.5 , " max. TPCnSigma Pion" };
387+ Configurable<float > cfgV0DaughPIDCutsTOFPi{ " cfgV0DaughPIDCutsTOFPi " , 2.5 , " max. TOFnSigma Pion" };
388+ Configurable<float > cfgV0DaughPIDCutsTOFPr{ " cfgV0DaughPIDCutsTOFPr " , - 2.5 , " min . TOFnSigma Proton (put only negative value) " };
388389 Configurable<float > cfgHypMassWindow{" cfgHypMassWindow" , 0.1 , " single lambda mass selection" };
389390 Configurable<bool > cfgIsCorrCollMatchV0{" cfgIsCorrCollMatchV0" , true , " check if daughter and mother collision are same" };
390391 Configurable<bool > cfgCalDataDrivenEffPr{" cfgCalDataDrivenEffPr" , false , " calculate data driven efficiency of proton using Lambda" };
@@ -399,6 +400,7 @@ struct HfCorrelatorXicHadrons {
399400 Configurable<int > cfgMinOccupancy{" cfgMinOccupancy" , 0 , " maximum occupancy of tracks in neighbouring collisions in a given time range" };
400401 Configurable<float > cfgPV{" cfgPV" , 10 ., " maximum z-vertex" };
401402 Configurable<bool > calEffV0{" calEffV0" , false , " calculate lambda0 efficiency" };
403+ Configurable<bool > checkTOFForPion{" checkTOFForPion" , false , " if True, TOF selection on pion V0 wil only be applied if TOF present" };
402404 } cfgV0;
403405
404406 SliceCache cache;
@@ -649,7 +651,7 @@ struct HfCorrelatorXicHadrons {
649651 template <typename Tracktype, typename V0Type>
650652 bool isSelectedV0Daughter (Tracktype const & track, V0Type const & v0, int pid)
651653 {
652- if (std::abs (track.eta ()) > cfgCharmCand .etaTrackMax ) {
654+ if (std::abs (track.eta ()) > cfgXicCand .etaTrackMax ) {
653655 return false ;
654656 }
655657
@@ -664,7 +666,7 @@ struct HfCorrelatorXicHadrons {
664666 return false ;
665667 }
666668
667- if (hasTOFProton && (track.pt () > cfgCharmCand .tofPIDThreshold )) {
669+ if (hasTOFProton && (track.pt () > cfgXicCand .tofPIDThreshold )) {
668670 if constexpr (std::experimental::is_detected<HasStrangeTOFinV0, V0Type>::value) {
669671 // pid > 0: Proton from Lambda (LaPr)
670672 // pid < 0: Antiproton from Anti-Lambda (ALaPr)
@@ -694,7 +696,7 @@ struct HfCorrelatorXicHadrons {
694696 return false ;
695697 }
696698
697- if (hasTOFPion && (track.pt () > cfgCharmCand .tofPIDThreshold )) {
699+ if (hasTOFPion && (track.pt () > cfgXicCand .tofPIDThreshold )) {
698700 if constexpr (std::experimental::is_detected<HasStrangeTOFinV0, V0Type>::value) {
699701 // A pion can belong to either a Lambda/Anti-Lambda decay or a K0s decay.
700702 // We evaluate both applicable hypotheses based on charge sign and pick the best match.
@@ -855,12 +857,12 @@ struct HfCorrelatorXicHadrons {
855857
856858 if (std::abs (currentDaughter.pdgCode ()) == kProton ) {
857859
858- if (currentDaughter.pt () > cfgV0.cfgDaughPrPtMax || currentDaughter.pt () < cfgV0.cfgDaughPrPtMin ) {
860+ if (currentDaughter.pt () > cfgV0.cfgV0DaughPrPtMax || currentDaughter.pt () < cfgV0.cfgV0DaughPrPtMin ) {
859861 continue ;
860862 }
861863
862864 } else if (std::abs (currentDaughter.pdgCode ()) == kPiPlus ) {
863- if (currentDaughter.pt () > cfgV0.cfgDaughPiPtMax || currentDaughter.pt () < cfgV0.cfgDaughPiPtMin ) {
865+ if (currentDaughter.pt () > cfgV0.cfgV0DaughPiPtMax || currentDaughter.pt () < cfgV0.cfgV0DaughPiPtMin ) {
864866 continue ;
865867 }
866868
@@ -1490,14 +1492,14 @@ struct HfCorrelatorXicHadrons {
14901492 auto const & trackV0Pos = assocParticle.template posTrack_as <TrackType>();
14911493 auto const & trackV0Neg = assocParticle.template negTrack_as <TrackType>();
14921494
1493- if (std::abs (o2::constants::physics::MassLambda - assocParticle.mLambda ()) < cfgV0.cfgHypMassWindow && v0 .alpha () > 0 ) {
1495+ if (std::abs (o2::constants::physics::MassLambda - assocParticle.mLambda ()) < cfgV0.cfgHypMassWindow && assocParticle .alpha () > 0 ) {
14941496 if (isSelectedV0Daughter (trackV0Pos, assocParticle, kProton ) && isSelectedV0Daughter (trackV0Neg, assocParticle, kPiPlus )) {
14951497
14961498 fillCorrelationTable<IsMcRec, V0LambdaType::Lambda>(cfgXicCand.fillTrkPID , assocParticle, ptCand, etaCand, phiCand, outputMlXic, poolBin, correlationStatus, yCand, massCand, *mcParticles);
14971499 }
14981500 }
14991501
1500- if (std::abs (o2::constants::physics::MassLambda - assocParticle.mAntiLambda ()) < cfgV0.cfgHypMassWindow && v0 .alpha () < 0 ) {
1502+ if (std::abs (o2::constants::physics::MassLambda - assocParticle.mAntiLambda ()) < cfgV0.cfgHypMassWindow && assocParticle .alpha () < 0 ) {
15011503 if (isSelectedV0Daughter (trackV0Neg, assocParticle, -kProton ) && isSelectedV0Daughter (trackV0Pos, assocParticle, -kPiPlus )) {
15021504 fillCorrelationTable<IsMcRec, V0LambdaType::AntiLambda>(cfgXicCand.fillTrkPID , assocParticle, ptCand, etaCand, phiCand, outputMlXic, poolBin, correlationStatus, yCand, massCand, *mcParticles);
15031505 }
@@ -1688,7 +1690,7 @@ struct HfCorrelatorXicHadrons {
16881690 // / Data processing: XicPlus with V0 Lambda
16891691 void processDataXicPlusV0 (SelCollisions::iterator const & collision,
16901692 TracksData const & tracks,
1691- aod::V0Datas const & v0s,
1693+ soa::Join< aod::V0Datas, aod::V0TOFNSigmas> const & v0s,
16921694 CandsXicPlusDataFiltered const & candidates,
16931695 aod::BCsWithTimestamps const &)
16941696 {
@@ -1699,7 +1701,7 @@ struct HfCorrelatorXicHadrons {
16991701 // / MC Reco processing: XicPlus with V0 Lambda
17001702 void processMcRecXicPlusV0 (SelCollisions::iterator const & collision,
17011703 TracksWithMc const & tracks,
1702- soa::Join<aod::V0Datas, aod::McV0Labels> const & v0s,
1704+ soa::Join<aod::V0Datas, aod::V0TOFNSigmas, aod:: McV0Labels> const & v0s,
17031705 CandsXicPlusMcRecFiltered const & candidates,
17041706 aod::McParticles const & mcParticles)
17051707 {
@@ -1710,7 +1712,7 @@ struct HfCorrelatorXicHadrons {
17101712 // / Data processing: Xic0 with V0 Lambda
17111713 void processDataXic0V0 (SelCollisions::iterator const & collision,
17121714 TracksData const & tracks,
1713- aod::V0Datas const & v0s,
1715+ soa::Join< aod::V0Datas, aod::V0TOFNSigmas> const & v0s,
17141716 CandsXic0DataFiltered const & candidates,
17151717 aod::BCsWithTimestamps const &)
17161718 {
@@ -1721,7 +1723,7 @@ struct HfCorrelatorXicHadrons {
17211723 // / MC Reco processing: Xic0 with V0 Lambda
17221724 void processMcRecXic0V0 (SelCollisions::iterator const & collision,
17231725 TracksWithMc const & tracks,
1724- soa::Join<aod::V0Datas, aod::McV0Labels> const & v0s,
1726+ soa::Join<aod::V0Datas, aod::V0TOFNSigmas, aod:: McV0Labels> const & v0s,
17251727 CandsXic0McRecFiltered const & candidates,
17261728 aod::McParticles const & mcParticles)
17271729 {
@@ -1732,7 +1734,7 @@ struct HfCorrelatorXicHadrons {
17321734 // / MC Reco processing: Xic0 with V0 Lambda
17331735 void processV0McRec (SelCollisions::iterator const & collision,
17341736 TracksWithMc const & tracks,
1735- soa::Join<aod::V0Datas, aod::McV0Labels> const & v0s,
1737+ soa::Join<aod::V0Datas, aod::V0TOFNSigmas, aod:: McV0Labels> const & v0s,
17361738 aod::McParticles const & mcParticles)
17371739 {
17381740 fillEffV0<true >(collision, v0s, tracks, mcParticles);
@@ -1789,7 +1791,7 @@ struct HfCorrelatorXicHadrons {
17891791 // / NOTE: V0 mixed events are more complex - need proper binning and collision matching
17901792 void processDataMixedEventXicPlusV0 (SelCollisions const & collisions,
17911793 CandsXicPlusDataFiltered const & candidates,
1792- aod::V0Datas const & v0s,
1794+ soa::Join< aod::V0Datas, aod::V0TOFNSigmas> const & v0s,
17931795 TracksData const & tracks)
17941796 {
17951797 doMixEvent<false , 1 , 1 >(collisions, v0s, candidates, tracks);
@@ -1799,7 +1801,7 @@ struct HfCorrelatorXicHadrons {
17991801 // / MC Reco Mixed Event: XicPlus with V0 Lambda
18001802 void processMcRecMixedEventXicPlusV0 (SelCollisions const & collisions,
18011803 CandsXicPlusMcRecFiltered const & candidates,
1802- soa::Join<aod::V0Datas, aod::McV0Labels> const & v0s,
1804+ soa::Join<aod::V0Datas, aod::V0TOFNSigmas, aod:: McV0Labels> const & v0s,
18031805 TracksWithMc const & tracks,
18041806 aod::McParticles const & mcParticles)
18051807 {
@@ -1810,7 +1812,7 @@ struct HfCorrelatorXicHadrons {
18101812 // / Data Mixed Event: Xic0 with V0 Lambda
18111813 void processDataMixedEventXic0V0 (SelCollisions const & collisions,
18121814 CandsXic0DataFiltered const & candidates,
1813- aod::V0Datas const & v0s,
1815+ soa::Join< aod::V0Datas, aod::V0TOFNSigmas> const & v0s,
18141816 TracksData const & tracks)
18151817 {
18161818 doMixEvent<false , 0 , 1 >(collisions, v0s, candidates, tracks);
@@ -1820,7 +1822,7 @@ struct HfCorrelatorXicHadrons {
18201822 // / MC Reco Mixed Event: Xic0 with V0 Lambda
18211823 void processMcRecMixedEventXic0V0 (SelCollisions const & collisions,
18221824 CandsXic0McRecFiltered const & candidates,
1823- soa::Join<aod::V0Datas, aod::McV0Labels> const & v0s,
1825+ soa::Join<aod::V0Datas, aod::V0TOFNSigmas, aod:: McV0Labels> const & v0s,
18241826 TracksWithMc const & tracks,
18251827 aod::McParticles const & mcParticles)
18261828 {
0 commit comments