@@ -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,90 @@ 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 ()) return ;
835+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 1 ); // After TriggerTVX
836+
837+ if (cEvtMCVtxIn10 && !collision.isVtxIn10 ()) return ;
838+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 2 ); // After VtxIn10
839+
840+ if (cEvtMCINELgt0 && !collision.isINELgt0 ()) return ;
841+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 3 ); // After INELgt0
842+
843+ if (cEvtMCSel8 && !collision.isInSel8 ()) return ;
844+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 4 ); // After Sel8
845+
846+ if (cEvtMCRecINELgt0 && !collision.isRecINELgt0 ()) return ;
847+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 5 ); // After RecINELgt0
848+
849+ if (cEvtMCAfterAllCuts && !collision.isInAfterAllCuts ()) return ;
850+ histos.fill (HIST (" SignalLoss/hMCEventCutflow" ), 6 ); // After AfterAllCuts
851+
852+ for (auto const & part : resoParents) {
853+
854+ float _yshift = std::abs (part.y ()) - cfgRapidityShift;
855+
856+ if (std::abs (_yshift) > cfgRapidityCut)
857+ continue ;
858+
859+ int pdg = part.pdgCode ();
860+ float ptRef = part.pt ();
861+ double ptSq = -1.0 ;
862+
863+ if (pdg == 2212 ) {
864+ ptSq = (ptRef * ptRef) + (mMassProton * mMassProton ) - (mMassLambda1520 * mMassLambda1520 );
865+ if (ptSq > 0 ) histos.fill (HIST (" SignalLoss/hGen_mT_scaled_Proton" ), std::sqrt (ptSq), centrality);
866+ }
867+ else if (pdg == -2212 ) {
868+ ptSq = (ptRef * ptRef) + (mMassProton * mMassProton ) - (mMassLambda1520 * mMassLambda1520 );
869+ if (ptSq > 0 ) histos.fill (HIST (" SignalLoss/hGen_mT_scaled_AntiProton" ), std::sqrt (ptSq), centrality);
870+ }
871+ else if (pdg == 3122 ) {
872+ ptSq = (ptRef * ptRef) + (mMassLambda0 * mMassLambda0 ) - (mMassLambda1520 * mMassLambda1520 );
873+ if (ptSq > 0 ) histos.fill (HIST (" SignalLoss/hGen_mT_scaled_Lambda0" ), std::sqrt (ptSq), centrality);
874+ }
875+ else if (pdg == -3122 ) {
876+ ptSq = (ptRef * ptRef) + (mMassLambda0 * mMassLambda0 ) - (mMassLambda1520 * mMassLambda1520 );
877+ if (ptSq > 0 ) histos.fill (HIST (" SignalLoss/hGen_mT_scaled_AntiLambda0" ), std::sqrt (ptSq), centrality);
878+ }
879+ else if (pdg == 3312 ) {
880+ ptSq = (ptRef * ptRef) + (mMassXiMinus * mMassXiMinus ) - (mMassLambda1520 * mMassLambda1520 );
881+ if (ptSq > 0 ) histos.fill (HIST (" SignalLoss/hGen_mT_scaled_XiMinus" ), std::sqrt (ptSq), centrality);
882+ }
883+ else if (pdg == -3312 ) {
884+ ptSq = (ptRef * ptRef) + (mMassXiMinus * mMassXiMinus ) - (mMassLambda1520 * mMassLambda1520 );
885+ if (ptSq > 0 ) histos.fill (HIST (" SignalLoss/hGen_mT_scaled_XiPlus" ), std::sqrt (ptSq), centrality);
886+ }
887+ else if (pdg == 3322 ) {
888+ ptSq = (ptRef * ptRef) + (mMassXi0 * mMassXi0 ) - (mMassLambda1520 * mMassLambda1520 );
889+ if (ptSq > 0 ) histos.fill (HIST (" SignalLoss/hGen_mT_scaled_Xi0" ), std::sqrt (ptSq), centrality);
890+ }
891+ else if (pdg == -3322 ) {
892+ ptSq = (ptRef * ptRef) + (mMassXi0 * mMassXi0 ) - (mMassLambda1520 * mMassLambda1520 );
893+ if (ptSq > 0 ) histos.fill (HIST (" SignalLoss/hGen_mT_scaled_AntiXi0" ), std::sqrt (ptSq), centrality);
894+ }
895+ else if (pdg == 3334 ) {
896+ ptSq = (ptRef * ptRef) + (mMassOmegaMinus * mMassOmegaMinus ) - (mMassLambda1520 * mMassLambda1520 );
897+ if (ptSq > 0 ) histos.fill (HIST (" SignalLoss/hGen_mT_scaled_OmegaMinus" ), std::sqrt (ptSq), centrality);
898+ }
899+ else if (pdg == -3334 ) {
900+ ptSq = (ptRef * ptRef) + (mMassOmegaMinus * mMassOmegaMinus ) - (mMassLambda1520 * mMassLambda1520 );
901+ if (ptSq > 0 ) histos.fill (HIST (" SignalLoss/hGen_mT_scaled_OmegaPlus" ), std::sqrt (ptSq), centrality);
902+ }
903+ }
904+ }
905+
906+
907+ PROCESS_SWITCH (lambdaAnalysis_pb, processMCGen, " Process Event for MC" , false );
908+
800909 using BinningType2 = ColumnBinningPolicy<aod::collision::PosZ, aod::resocollision::Cent>;
801910
802911 void processMix (resoCols& collisions, resoTracks const & tracks)
0 commit comments