@@ -123,6 +123,7 @@ struct HfElectronSelectionWithTpcEmcal {
123123 Configurable<float > m20EmcClusterElectronMin{" m20EmcClusterElectronMin" , 0 .0f , " min Electron EMCal Cluster M20" };
124124 Configurable<float > tpcNsigmaElectronMin{" tpcNsigmaElectronMin" , -0 .5f , " min Electron TPCnsigma" };
125125 Configurable<float > tpcNsigmaElectronMax{" tpcNsigmaElectronMax" , 3 .0f , " max Electron TPCnsigma" };
126+ Configurable<float > tofNSigmaEl{" tofNSigmaEl" , 3.0 , " Sigma cut for electrons not in EMCal" };
126127 Configurable<int > pdgCodeCharmMin{" pdgCodeCharmMin" , 400 , " Min Charm Hadron PdgCode" };
127128 Configurable<int > pdgCodeCharmMax{" pdgCodeCharmMax" , 600 , " Max Charm Hadron PdgCode" };
128129 Configurable<int > pdgCodeBeautyMin{" pdgCodeBeautyMin" , 4000 , " Min beauty Hadron PdgCode" };
@@ -224,6 +225,8 @@ struct HfElectronSelectionWithTpcEmcal {
224225
225226 registry.add (" hPIDAfterPIDCuts" , " PID Info after PID cuts; E/P;#it{p}_{T} (GeV#it{/c});n#sigma;m02; m20;" , {HistType::kTHnSparseF , {{axisEoP}, {axisPt}, {axisnSigma}, {axisM02}, {axisM20}}});
226227 registry.add (" hEmcClsTrkEtaPhiDiffTime" , " EmcClsTrkEtaPhiDiffTime;#Delta#eta;#Delta#varphi;Sec;" , {HistType::kTH3F , {{axisDeltaEta}, {axisDeltaPhi}, {axisEmcClsTime}}});
228+ registry.add (" hTofNSigmaVsPt" , " TOF nSigma vs pt; n#sigma;#it{pt} (GeV/#it{c});" , {HistType::kTH2F , {{axisnSigma}, {axisPt}}});
229+ registry.add (" hTpcNSigmaVsPt" , " TPC nSigma vs pt; n#sigma;#it{pt} (GeV/#it{c});" , {HistType::kTH2F , {{axisnSigma}, {axisPt}}});
227230 }
228231 // Track Selection Cut
229232 template <typename T>
@@ -292,12 +295,11 @@ struct HfElectronSelectionWithTpcEmcal {
292295 {
293296 int nElPairsLS = 0 ;
294297 int nElPairsUS = 0 ;
295- bool isLSElectron = false ;
296- bool isULSElectron = false ;
297298 float invMassElectron = 0 .;
298299 float massLike = 0 ;
299300 float massUnLike = 0 ;
300-
301+ std::vector<float > vecLSMass;
302+ std::vector<float > vecULSMass;
301303 for (const auto & pTrack : tracks) {
302304 if (pTrack.globalIndex () == electron.globalIndex ()) {
303305 continue ;
@@ -339,10 +341,12 @@ struct HfElectronSelectionWithTpcEmcal {
339341 }
340342
341343 invMassElectron = RecoDecay::m (std::array{pTrack.pVector (), electron.pVector ()}, std::array{MassElectron, MassElectron});
342-
344+ bool isLSElectron = false ;
345+ bool isULSElectron = false ;
343346 // for like charge
344347 if (pTrack.sign () == electron.sign ()) {
345348 massLike = invMassElectron;
349+ vecLSMass.push_back (massLike);
346350 isLSElectron = true ;
347351 if (isEMcal) {
348352 registry.fill (HIST (" hLikeMass" ), massLike);
@@ -351,6 +355,7 @@ struct HfElectronSelectionWithTpcEmcal {
351355 // for unlike charge
352356 if (pTrack.sign () != electron.sign ()) {
353357 massUnLike = invMassElectron;
358+ vecULSMass.push_back (massUnLike);
354359 isULSElectron = true ;
355360 if (isEMcal) {
356361 registry.fill (HIST (" hUnLikeMass" ), massUnLike);
@@ -375,7 +380,8 @@ struct HfElectronSelectionWithTpcEmcal {
375380 }
376381 }
377382 // Pass multiplicities and other required parameters for this electron
378- hfElectronSelection (electron.collisionId (), electron.globalIndex (), electron.eta (), electron.phi (), electron.pt (), electron.tpcNSigmaEl (), electron.tofNSigmaEl (), invMassElectron, nElPairsLS, nElPairsUS, isEMcal);
383+ // Pass multiplicities and other required parameters for this electron
384+ hfElectronSelection (electron.collisionId (), electron.globalIndex (), electron.eta (), electron.phi (), electron.pt (), electron.tpcNSigmaEl (), electron.tofNSigmaEl (), vecLSMass, vecULSMass, nElPairsLS, nElPairsUS, isEMcal);
379385 }
380386 // Electron Identification
381387 template <bool IsMc, typename TracksType, typename EmcClusterType, typename MatchType, typename CollisionType, typename ParticleType>
@@ -525,13 +531,22 @@ struct HfElectronSelectionWithTpcEmcal {
525531
526532 nonHfe (matchTrack, tracks, true );
527533
528- electronSel (track.collisionId (), matchTrack.globalIndex (), etaMatchTrack, phiMatchTrack, ptMatchTrack, pMatchTrack, trackRapidity, matchTrack.dcaXY (), matchTrack.dcaZ (), matchTrack.tpcNSigmaEl (), matchTrack.tofNSigmaEl (),
534+ // /////////////// NonHf electron Selection without Emcal ////////////////////////
535+ electronSel (track.collisionId (), track.globalIndex (), etaTrack, phiTrack, ptTrack, pTrack, trackRapidity, dcaxyTrack, dcazTrack, track.tpcNSigmaEl (), track.tofNSigmaEl (),
529536 eMatchEmcCluster, etaMatchEmcCluster, phiMatchEmcCluster, m02MatchEmcCluster, m20MatchEmcCluster, cellEmcCluster, timeEmcCluster, deltaEtaMatch, deltaPhiMatch, isEMcal);
530537 }
531538 // / Electron information without Emcal and use TPC and TOF
532539 if (isEMcal) {
533540 continue ;
534541 }
542+ if (std::abs (track.tofNSigmaEl ()) > tofNSigmaEl)
543+ continue ;
544+ registry.fill (HIST (" hTofNSigmaVsPt" ), track.tofNSigmaEl (), track.pt ());
545+ registry.fill (HIST (" hTpcNSigmaVsPt" ), track.tpcNSigmaEl (), track.pt ());
546+
547+ if ((track.tpcNSigmaEl () < tpcNsigmaElectronMin || track.tpcNSigmaEl () > tpcNsigmaElectronMax))
548+ continue ;
549+
535550 nonHfe (track, tracks, false );
536551 // /////////////// NonHf electron Selection without Emcal ////////////////////////
537552 electronSel (track.collisionId (), track.globalIndex (), etaTrack, phiTrack, ptTrack, pTrack, trackRapidity, dcaxyTrack, dcazTrack, track.tpcNSigmaEl (), track.tofNSigmaEl (),
0 commit comments