@@ -115,7 +115,7 @@ struct K892analysispbpb {
115115 Configurable<bool > cTOFonlyHighpt{" cTOFonlyHighpt" , false , " apply TOF only at high pt" };
116116 Configurable<bool > cTOFandTPCHighpt{" cTOFandTPCHighpt" , false , " apply TOF and TPC at high pt" };
117117 Configurable<bool > circularCut{" circularCut" , false , " apply TOF and TPC circular cut (applied only if cTOFandTPCHighpt is true)" };
118-
118+
119119 // rotational bkg
120120 Configurable<int > cfgNoRotations{" cfgNoRotations" , 3 , " Number of rotations per pair for rotbkg" };
121121 Configurable<int > rotationalCut{" rotationalCut" , 10 , " Cut value (Rotation angle pi - pi/cut and pi + pi/cut)" };
@@ -240,7 +240,7 @@ struct K892analysispbpb {
240240 histos.add (" h3k892invmassDSAnti" , " Invariant mass of Anti-K(892)0 differnt sign" , kTH3F , {centAxis, ptAxis, invMassAxis});
241241 histos.add (" h3k892invmassLS" , " Invariant mass of K(892)0 same sign" , kTH3F , {centAxis, ptAxis, invMassAxis});
242242 histos.add (" h3k892invmassLSAnti" , " Invariant mass of Anti-K(892)0 same sign" , kTH3F , {centAxis, ptAxis, invMassAxis});
243-
243+
244244 if (doprocessRotationalBkg || doprocessRotationalBkgMC) {
245245 histos.add (" k892invmassRotDS" , " Invariant mass of K(892)0 RotBkg" , kTH1F , {invMassAxis});
246246 histos.add (" k892invmassRotDSAnti" , " Invariant mass of Anti-K(892)0 RotBkg" , kTH1F , {invMassAxis});
@@ -410,16 +410,15 @@ struct K892analysispbpb {
410410
411411 } else if (cTOFandTPCHighpt) {
412412
413- if (circularCut) {
413+ if (circularCut) {
414+
415+ if (candidate.hasTOF () && candidate.hasTPC () && std::sqrt (std::pow (candidate.tpcNSigmaKa (), 2 ) + std::pow (candidate.tofNSigmaKa (), 2 )) <= cMaxTPCnSigmaKaon) // tof and tpc circular cut
416+ return true ;
414417
415- if (candidate.hasTOF () && candidate.hasTPC () && std::sqrt ( std::pow (candidate.tpcNSigmaKa (),2 ) + std::pow (candidate.tofNSigmaKa (),2 ) ) <= cMaxTPCnSigmaKaon) // tof and tpc circular cut
416- return true ;
417-
418418 } else {
419419
420- if (candidate.hasTOF () && std::abs (candidate.tofNSigmaKa ()) <= cMaxTOFnSigmaKaon && candidate.hasTPC () && std::abs (candidate.tpcNSigmaKa ()) <= cMaxTPCnSigmaKaon) // tof and tpc cut
421- return true ;
422-
420+ if (candidate.hasTOF () && std::abs (candidate.tofNSigmaKa ()) <= cMaxTOFnSigmaKaon && candidate.hasTPC () && std::abs (candidate.tpcNSigmaKa ()) <= cMaxTPCnSigmaKaon) // tof and tpc cut
421+ return true ;
423422 }
424423 } else {
425424
@@ -455,15 +454,15 @@ struct K892analysispbpb {
455454
456455 } else if (cTOFandTPCHighpt) {
457456
458- if (circularCut) {
457+ if (circularCut) {
458+
459+ if (candidate.hasTOF () && candidate.hasTPC () && std::sqrt (std::pow (candidate.tpcNSigmaPi (), 2 ) + std::pow (candidate.tofNSigmaPi (), 2 )) <= cMaxTPCnSigmaPion) // tof and tpc circular cut
460+ return true ;
459461
460- if (candidate.hasTOF () && candidate.hasTPC () && std::sqrt ( std::pow (candidate.tpcNSigmaPi (),2 ) + std::pow (candidate.tofNSigmaPi (),2 ) ) <= cMaxTPCnSigmaPion) // tof and tpc circular cut
461- return true ;
462-
463462 } else {
464463
465- if (candidate.hasTOF () && std::abs (candidate.tofNSigmaPi ()) <= cMaxTOFnSigmaPion && candidate.hasTPC () && std::abs (candidate.tpcNSigmaPi ()) <= cMaxTPCnSigmaPion) // tof and tpc cut
466- return true ;
464+ if (candidate.hasTOF () && std::abs (candidate.tofNSigmaPi ()) <= cMaxTOFnSigmaPion && candidate.hasTPC () && std::abs (candidate.tpcNSigmaPi ()) <= cMaxTPCnSigmaPion) // tof and tpc cut
465+ return true ;
467466 }
468467
469468 } else {
@@ -866,51 +865,49 @@ struct K892analysispbpb {
866865 auto candPosKatpc = posKatpc->sliceByCached (aod::track::collisionId, collision2.globalIndex (), cache);
867866
868867 if constexpr (!isLikeSig) {
869- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitpc, candNegKatpc);
870- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitpc, candPosKatpc);
868+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitpc, candNegKatpc);
869+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitpc, candPosKatpc);
871870 } else {
872- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitpc, candPosKatpc);
873- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitpc, candNegKatpc);
871+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitpc, candPosKatpc);
872+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitpc, candNegKatpc);
874873 }
875874
876875 } else if (cTOFandTPCHighpt) {
877876 // +-
878877 auto candPosPitoftpc = posPitoftpc->sliceByCached (aod::track::collisionId, collision1.globalIndex (), cache);
879878 auto candNegKatoftpc = negKatoftpc->sliceByCached (aod::track::collisionId, collision2.globalIndex (), cache);
880-
879+
881880 // -+
882881 auto candNegPitoftpc = negPitoftpc->sliceByCached (aod::track::collisionId, collision1.globalIndex (), cache);
883882 auto candPosKatoftpc = posKatoftpc->sliceByCached (aod::track::collisionId, collision2.globalIndex (), cache);
884883
885884 if constexpr (!isLikeSig) {
886- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitoftpc, candNegKatoftpc);
887- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitoftpc, candPosKatoftpc);
885+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitoftpc, candNegKatoftpc);
886+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitoftpc, candPosKatoftpc);
888887 } else {
889- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitoftpc, candPosKatoftpc);
890- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitoftpc, candNegKatoftpc);
888+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitoftpc, candPosKatoftpc);
889+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitoftpc, candNegKatoftpc);
891890 }
892891
893892 } else if (cTOFonlyHighpt) {
894893 // +-
895894 auto candPosPitof = posPitof->sliceByCached (aod::track::collisionId, collision1.globalIndex (), cache);
896895 auto candNegKatof = negKatof->sliceByCached (aod::track::collisionId, collision2.globalIndex (), cache);
897-
896+
898897 // -+
899898 auto candNegPitof = negPitof->sliceByCached (aod::track::collisionId, collision1.globalIndex (), cache);
900899 auto candPosKatof = posKatof->sliceByCached (aod::track::collisionId, collision2.globalIndex (), cache);
901900
902901 if constexpr (!isLikeSig) {
903- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitof, candNegKatof);
904- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitof, candPosKatof);
902+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitof, candNegKatof);
903+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitof, candPosKatof);
905904 } else {
906- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitof, candPosKatof);
907- fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitof, candNegKatof);
908- }
909-
905+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candPosPitof, candPosKatof);
906+ fillHistograms<IsMC, IsMix, IsRot, IsRun2>(collision1, candNegPitof, candNegKatof);
907+ }
910908 }
911909 }
912910
913-
914911 void processSameEvent (EventCandidates::iterator const & collision, TrackCandidates const & tracks, aod::BCs const &)
915912 {
916913
@@ -974,7 +971,6 @@ struct K892analysispbpb {
974971 }
975972 PROCESS_SWITCH (K892analysispbpb, processRotationalBkgMC, " Process Rotational Background MC" , false );
976973
977-
978974 void processLikeSign (EventCandidates::iterator const & collision, TrackCandidates const & tracks, aod::BCs const &)
979975 {
980976
@@ -986,7 +982,6 @@ struct K892analysispbpb {
986982 }
987983 PROCESS_SWITCH (K892analysispbpb, processLikeSign, " Process Like Sign" , false );
988984
989-
990985 void processMixedEvent (EventCandidates const & collisions, TrackCandidates const & tracks)
991986 {
992987 auto tracksTuple = std::make_tuple (tracks);
0 commit comments