@@ -1688,7 +1688,7 @@ struct Kstarqa {
16881688 }
16891689 PROCESS_SWITCH (Kstarqa, processEvtLossSigLossMC, " Process Signal Loss, Event Loss" , false );
16901690
1691- void processRec (EventCandidatesMC::iterator const & collision, TrackCandidatesMC const & tracks, aod::McParticles const &, aod::McCollisions const &)
1691+ void processRec (EventCandidatesMC::iterator const & collision, TrackCandidatesMC const & tracks, aod::McParticles const &, EventMCGenerated const &)
16921692 {
16931693
16941694 if (!collision.has_mcCollision ()) {
@@ -1705,8 +1705,6 @@ struct Kstarqa {
17051705 }
17061706 // multiplicity = collision.centFT0M();
17071707
1708- multiplicity = -1.0 ;
1709-
17101708 if (cSelectMultEstimator == kFT0M ) {
17111709 multiplicity = collision.centFT0M ();
17121710 } else if (cSelectMultEstimator == kFT0A ) {
@@ -1934,20 +1932,22 @@ struct Kstarqa {
19341932 }
19351933 PROCESS_SWITCH (Kstarqa, processRec, " Process Reconstructed" , false );
19361934
1937- void processRec2 (EventCandidatesMC::iterator const & collision, TrackCandidatesMC const & tracks, aod::McParticles const &, aod::McCollisions const & /* mcCollisions */ )
1935+ void processRec2 (EventCandidatesMC::iterator const & collision, TrackCandidatesMC const & tracks, aod::McParticles const &, EventMCGenerated const &)
19381936 {
19391937
19401938 if (!collision.has_mcCollision ()) {
19411939 return ;
19421940 }
19431941
1942+ double multiplicityRec = -1.0 ;
1943+ const auto & mcCollisionRec = collision.mcCollision_as <EventMCGenerated>();
1944+ multiplicityRec = mcCollisionRec.centFT0M ();
1945+
19441946 if (selectionConfig.isINELgt0 && !collision.isInelGt0 ()) {
19451947 return ;
19461948 }
19471949 // multiplicity = collision.centFT0M();
19481950
1949- multiplicity = -1.0 ;
1950-
19511951 if (cSelectMultEstimator == kFT0M ) {
19521952 multiplicity = collision.centFT0M ();
19531953 } else if (cSelectMultEstimator == kFT0A ) {
@@ -1961,50 +1961,14 @@ struct Kstarqa {
19611961 }
19621962
19631963 hInvMass.fill (HIST (" hAllRecCollisions" ), multiplicity);
1964+ hInvMass.fill (HIST (" hAllRecCollisionsCalib" ), multiplicityRec);
19641965
19651966 if (!selectionEvent (collision, false )) {
19661967 return ;
19671968 }
19681969
1969- // // if (std::abs(collision.mcCollision().posZ()) > selectionConfig.cutzvertex || !collision.sel8()) {
1970- // if (std::abs(collision.mcCollision().posZ()) > selectionConfig.cutzvertex) {
1971- // return;
1972- // }
1973-
1974- // if (selectionConfig.isNoTimeFrameBorder && !collision.selection_bit(aod::evsel::kNoTimeFrameBorder)) {
1975- // return;
1976- // }
1977-
1978- // if (selectionConfig.isTriggerTVX && !collision.selection_bit(aod::evsel::kIsTriggerTVX)) {
1979- // return;
1980- // }
1981-
1982- // if (!collision.sel8()) {
1983- // return;
1984- // }
1985-
1986- // if (selectionConfig.isNoSameBunchPileup && !collision.selection_bit(aod::evsel::kNoSameBunchPileup)) {
1987- // return;
1988- // }
1989- // if (selectionConfig.isGoodZvtxFT0vsPV && !collision.selection_bit(aod::evsel::kIsGoodZvtxFT0vsPV)) {
1990- // return;
1991- // }
1992-
1993- // multiplicity = collision.centFT0M();
1994-
1995- multiplicity = -1.0 ;
1996-
1997- if (cSelectMultEstimator == kFT0M ) {
1998- multiplicity = collision.centFT0M ();
1999- } else if (cSelectMultEstimator == kFT0A ) {
2000- multiplicity = collision.centFT0A ();
2001- } else if (cSelectMultEstimator == kFT0C ) {
2002- multiplicity = collision.centFT0C ();
2003- } else if (cSelectMultEstimator == kFV0A ) {
2004- multiplicity = collision.centFV0A ();
2005- } else {
2006- multiplicity = collision.centFT0M (); // default
2007- }
1970+ hInvMass.fill (HIST (" h1RecMult" ), multiplicity);
1971+ hInvMass.fill (HIST (" h1RecMult2" ), multiplicityRec);
20081972
20091973 hInvMass.fill (HIST (" h1RecMult" ), multiplicity);
20101974
@@ -2169,13 +2133,15 @@ struct Kstarqa {
21692133 mother = daughter1 + daughter2; // Kstar meson
21702134
21712135 hInvMass.fill (HIST (" h2KstarRecpt2" ), mothertrack1.pt (), multiplicity, std::sqrt (mothertrack1.e () * mothertrack1.e () - mothertrack1.p () * mothertrack1.p ()));
2136+ hInvMass.fill (HIST (" h2KstarRecptCalib2" ), mothertrack1.pt (), multiplicityRec, std::sqrt (mothertrack1.e () * mothertrack1.e () - mothertrack1.p () * mothertrack1.p ()));
21722137
21732138 if (applyRecMotherRapidity && mother.Rapidity () >= selectionConfig.rapidityMotherData ) {
21742139 continue ;
21752140 }
21762141
21772142 hInvMass.fill (HIST (" h1KstarRecMass" ), mother.M ());
21782143 hInvMass.fill (HIST (" h2KstarRecpt1" ), mother.Pt (), multiplicity, mother.M ());
2144+ hInvMass.fill (HIST (" h2KstarRecptCalib1" ), mother.Pt (), multiplicityRec, mother.M ());
21792145 }
21802146 }
21812147 }
0 commit comments