@@ -85,6 +85,7 @@ struct TrackEfficiency {
8585 Configurable<float > ptHatMax{" ptHatMax" , 999 , " max pT hat of collisions" };
8686 Configurable<float > pTHatExponent{" pTHatExponent" , 4.0 , " exponent of the event weight for the calculation of pTHat" };
8787 Configurable<float > pTHatMaxFractionMCD{" pTHatMaxFractionMCD" , 999.0 , " maximum fraction of hard scattering for reconstructed track acceptance in MC" };
88+ Configurable<float > pTHatMaxFractionMCP{" pTHatMaxFractionMCP" , 999.0 , " maximum fraction of hard scattering for particle acceptance in MC" };
8889
8990 Configurable<bool > useTrueTrackWeight{" useTrueTrackWeight" , true , " test configurable, should be set to 1 then config removed once well tested" };
9091
@@ -174,6 +175,10 @@ struct TrackEfficiency {
174175 float centrality = checkCentFT0M ? collisions.begin ().centFT0M () : collisions.begin ().centFT0C ();
175176
176177 for (auto const & mcparticle : mcparticles) {
178+ float pTHat = simPtRef / (std::pow (weight, 1.0 / pTHatExponent));
179+ if (mcparticle.pt () > pTHatMaxFractionMCP * pTHat) {
180+ continue ;
181+ }
177182 registry.fill (HIST (" h2_centrality_particle_pt" ), centrality, mcparticle.pt (), weight);
178183 registry.fill (HIST (" h2_centrality_particle_eta" ), centrality, mcparticle.eta (), weight);
179184 registry.fill (HIST (" h2_centrality_particle_phi" ), centrality, mcparticle.phi (), weight);
@@ -657,6 +662,9 @@ struct TrackEfficiency {
657662 registry.fill (HIST (" hMcCollCutsCounts" ), 6.5 , mcCollision.weight ()); // ptHat condition
658663
659664 for (auto const & jMcParticle : jMcParticles) {
665+ if (jMcParticle.pt () > pTHatMaxFractionMCP * pTHat) {
666+ continue ;
667+ }
660668 registry.fill (HIST (" hMcPartCutsCounts" ), 0.5 , mcCollision.weight ()); // allPartsInSelMcColl
661669
662670 if (!isChargedParticle (jMcParticle.pdgCode ())) {
@@ -720,6 +728,9 @@ struct TrackEfficiency {
720728 float trueTrackCollEventWeight = useTrueTrackWeight ? trueTrackMcCollision.weight () : mcCollEventWeight;
721729
722730 auto jMcParticleFromTrack = track.mcParticle_as <JetParticlesWithOriginal>();
731+ if (jMcParticleFromTrack.pt () > pTHatMaxFractionMCP * pTHat) {
732+ continue ;
733+ }
723734 if (!jMcParticleFromTrack.isPhysicalPrimary ()) {
724735 registry.fill (HIST (" h3_track_pt_track_eta_track_phi_associatedtrack_nonprimary" ), track.pt (), track.eta (), track.phi (), trueTrackCollEventWeight);
725736 registry.fill (HIST (" h3_particle_pt_particle_eta_particle_phi_associatedtrack_nonprimary" ), jMcParticleFromTrack.pt (), jMcParticleFromTrack.eta (), jMcParticleFromTrack.phi (), trueTrackCollEventWeight);
0 commit comments