@@ -140,6 +140,12 @@ struct lambdaAnalysis_pb {
140140 Configurable<bool > cEvtMCVtxIn10{" cEvtMCVtxIn10" , false , " MC event sel: isVtxIn10" };
141141 Configurable<bool > cEvtMCTriggerTVX{" cEvtMCTriggerTVX" , false , " MC event sel: isTriggerTVX" };
142142 Configurable<bool > cEvtMCRecINELgt0{" cEvtMCRecINELgt0" , false , " MC event sel: isRecINELgt0" };
143+ const double mMassLambda1520 = 1.5195 ;
144+ const double mMassProton = 0.93827 ;
145+ const double mMassLambda0 = 1.11568 ;
146+ const double mMassXiMinus = 1.32171 ;
147+ const double mMassXi0 = 1.31486 ;
148+ const double mMassOmegaMinus = 1.67245 ;
143149 // Histogram Registry.
144150 HistogramRegistry histos{" histos" , {}, OutputObjHandlingPolicy::AnalysisObject};
145151
@@ -239,6 +245,24 @@ struct lambdaAnalysis_pb {
239245 histos.add (" Analysis/h3d_reso_lstar_PM" , " Resolution #Lambda(1520) p_{T}" , kTHnSparseF , {{200 , -0.05 , 0.05 }, axisPt, axisCent});
240246 histos.add (" Analysis/h3d_reso_lstar_MP" , " Resolution #bar{#Lambda}(1520) p_{T}" , kTHnSparseF , {{200 , -0.05 , 0.05 }, axisPt, axisCent});
241247 }
248+
249+ if (doprocessMCGen) {
250+ histos.add (" SignalLoss/hMCEventCutflow" , " MC Event Cutflow" , kTH1F , {{7 , 0 , 7 }});
251+ histos.add (" SignalLoss/hGen_mT_scaled_Proton" , " mT Scaled #Lambda(1520) from Proton" , kTHnSparseF , {axisPt, axisCent});
252+ histos.add (" SignalLoss/hGen_mT_scaled_AntiProton" , " mT Scaled #bar{#Lambda}(1520) from AntiProton" , kTHnSparseF , {axisPt, axisCent});
253+
254+ histos.add (" SignalLoss/hGen_mT_scaled_Lambda0" , " mT Scaled #Lambda(1520) from Lambda0" , kTHnSparseF , {axisPt, axisCent});
255+ histos.add (" SignalLoss/hGen_mT_scaled_AntiLambda0" , " mT Scaled #bar{#Lambda}(1520) from AntiLambda0" , kTHnSparseF , {axisPt, axisCent});
256+
257+ histos.add (" SignalLoss/hGen_mT_scaled_XiMinus" , " mT Scaled #Lambda(1520) from Xi-" , kTHnSparseF , {axisPt, axisCent});
258+ histos.add (" SignalLoss/hGen_mT_scaled_XiPlus" , " mT Scaled #bar{#Lambda}(1520) from Xi+" , kTHnSparseF , {axisPt, axisCent});
259+
260+ histos.add (" SignalLoss/hGen_mT_scaled_Xi0" , " mT Scaled #Lambda(1520) from Xi0" , kTHnSparseF , {axisPt, axisCent});
261+ histos.add (" SignalLoss/hGen_mT_scaled_AntiXi0" , " mT Scaled #bar{#Lambda}(1520) from AntiXi0" , kTHnSparseF , {axisPt, axisCent});
262+
263+ histos.add (" SignalLoss/hGen_mT_scaled_OmegaMinus" , " mT Scaled #Lambda(1520) from Omega-" , kTHnSparseF , {axisPt, axisCent});
264+ histos.add (" SignalLoss/hGen_mT_scaled_OmegaPlus" , " mT Scaled #bar{#Lambda}(1520) from Omega+" , kTHnSparseF , {axisPt, axisCent});
265+ }
242266 }
243267
244268 template <typename T>
@@ -771,10 +795,11 @@ struct lambdaAnalysis_pb {
771795 for (auto const & part : resoParents) {
772796 if (std::abs (part.pdgCode ()) != lambda1520id) // // L* pdg_code = 3124
773797 continue ;
774- // if (std::abs(part.y()) > 0.5) { // rapidity cut
775- // continue;
776- // }
777798
799+ float _yshift = std::abs (part.y ()) - cfgRapidityShift;
800+
801+ if (std::abs (_yshift) > cfgRapidityCut)
802+ continue ;
778803 bool pass1 = false ;
779804 bool pass2 = false ;
780805
@@ -797,6 +822,96 @@ struct lambdaAnalysis_pb {
797822 }
798823 PROCESS_SWITCH (lambdaAnalysis_pb, processMC, " Process Event for MC" , false );
799824
825+ void processMCGen (resoMCCols::iterator const & collision,
826+ soa::Join<aod::ResoTracks, aod::ResoMCTracks> const & tracks,
827+ aod::ResoMCParents const & resoParents)
828+ {
829+
830+ float centrality = collision.cent ();
831+
832+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 0 ); // All collisions
833+
834+ if (cEvtMCTriggerTVX && !collision.isTriggerTVX ())
835+ return ;
836+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 1 ); // After TriggerTVX
837+
838+ if (cEvtMCVtxIn10 && !collision.isVtxIn10 ())
839+ return ;
840+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 2 ); // After VtxIn10
841+
842+ if (cEvtMCINELgt0 && !collision.isINELgt0 ())
843+ return ;
844+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 3 ); // After INELgt0
845+
846+ if (cEvtMCSel8 && !collision.isInSel8 ())
847+ return ;
848+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 4 ); // After Sel8
849+
850+ if (cEvtMCRecINELgt0 && !collision.isRecINELgt0 ())
851+ return ;
852+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 5 ); // After RecINELgt0
853+
854+ if (cEvtMCAfterAllCuts && !collision.isInAfterAllCuts ())
855+ return ;
856+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 6 ); // After AfterAllCuts
857+
858+ for (auto const & part : resoParents) {
859+
860+ float _yshift = std::abs (part.y ()) - cfgRapidityShift;
861+
862+ if (std::abs (_yshift) > cfgRapidityCut)
863+ continue ;
864+
865+ int pdg = part.pdgCode ();
866+ float ptRef = part.pt ();
867+ double ptSq = -1.0 ;
868+
869+ if (pdg == 2212 ) {
870+ ptSq = (ptRef * ptRef) + (mMassProton * mMassProton ) - (mMassLambda1520 * mMassLambda1520 );
871+ if (ptSq > 0 )
872+ histos.fill (HIST (" SignalLoss/hGen_mT_scaled_Proton" ), std::sqrt (ptSq), centrality);
873+ } else if (pdg == -2212 ) {
874+ ptSq = (ptRef * ptRef) + (mMassProton * mMassProton ) - (mMassLambda1520 * mMassLambda1520 );
875+ if (ptSq > 0 )
876+ histos.fill (HIST (" SignalLoss/hGen_mT_scaled_AntiProton" ), std::sqrt (ptSq), centrality);
877+ } else if (pdg == 3122 ) {
878+ ptSq = (ptRef * ptRef) + (mMassLambda0 * mMassLambda0 ) - (mMassLambda1520 * mMassLambda1520 );
879+ if (ptSq > 0 )
880+ histos.fill (HIST (" SignalLoss/hGen_mT_scaled_Lambda0" ), std::sqrt (ptSq), centrality);
881+ } else if (pdg == -3122 ) {
882+ ptSq = (ptRef * ptRef) + (mMassLambda0 * mMassLambda0 ) - (mMassLambda1520 * mMassLambda1520 );
883+ if (ptSq > 0 )
884+ histos.fill (HIST (" SignalLoss/hGen_mT_scaled_AntiLambda0" ), std::sqrt (ptSq), centrality);
885+ } else if (pdg == 3312 ) {
886+ ptSq = (ptRef * ptRef) + (mMassXiMinus * mMassXiMinus ) - (mMassLambda1520 * mMassLambda1520 );
887+ if (ptSq > 0 )
888+ histos.fill (HIST (" SignalLoss/hGen_mT_scaled_XiMinus" ), std::sqrt (ptSq), centrality);
889+ } else if (pdg == -3312 ) {
890+ ptSq = (ptRef * ptRef) + (mMassXiMinus * mMassXiMinus ) - (mMassLambda1520 * mMassLambda1520 );
891+ if (ptSq > 0 )
892+ histos.fill (HIST (" SignalLoss/hGen_mT_scaled_XiPlus" ), std::sqrt (ptSq), centrality);
893+ } else if (pdg == 3322 ) {
894+ ptSq = (ptRef * ptRef) + (mMassXi0 * mMassXi0 ) - (mMassLambda1520 * mMassLambda1520 );
895+ if (ptSq > 0 )
896+ histos.fill (HIST (" SignalLoss/hGen_mT_scaled_Xi0" ), std::sqrt (ptSq), centrality);
897+ } else if (pdg == -3322 ) {
898+ ptSq = (ptRef * ptRef) + (mMassXi0 * mMassXi0 ) - (mMassLambda1520 * mMassLambda1520 );
899+ if (ptSq > 0 )
900+ histos.fill (HIST (" SignalLoss/hGen_mT_scaled_AntiXi0" ), std::sqrt (ptSq), centrality);
901+ } else if (pdg == 3334 ) {
902+ ptSq = (ptRef * ptRef) + (mMassOmegaMinus * mMassOmegaMinus ) - (mMassLambda1520 * mMassLambda1520 );
903+ if (ptSq > 0 )
904+ histos.fill (HIST (" SignalLoss/hGen_mT_scaled_OmegaMinus" ), std::sqrt (ptSq), centrality);
905+ } else if (pdg == -3334 ) {
906+ ptSq = (ptRef * ptRef) + (mMassOmegaMinus * mMassOmegaMinus ) - (mMassLambda1520 * mMassLambda1520 );
907+ if (ptSq > 0 )
908+ histos.fill (HIST (" SignalLoss/hGen_mT_scaled_OmegaPlus" ), std::sqrt (ptSq), centrality);
909+ }
910+ }
911+ }
912+
913+ PROCESS_SWITCH (lambdaAnalysis_pb, processMCGen, " Process Event for MC" , false );
914+
800915 using BinningType2 = ColumnBinningPolicy<aod::collision::PosZ, aod::resocollision::Cent>;
801916
802917 void processMix (resoCols& collisions, resoTracks const & tracks)
0 commit comments