@@ -120,7 +120,8 @@ struct ThreeParticleCorrelations {
120120 SameKindPair<MyFilteredMCGenCollisions, MyFilteredMCParticles, BinningTypeMC> pairMC{collBinningMC, 5 , -1 , &cache};
121121
122122 // Process configurables
123- Configurable<bool > confFilterSwitch{" confFilterSwitch" , false , " Switch for the fakeV0Filter function" };
123+ Configurable<bool > confFakeV0Switch{" confFakeV0Switch" , false , " Switch for the fakeV0Filter function" };
124+ Configurable<bool > confRDSwitch{" confRDSwitch" , true , " Switch for the radialDistanceFilter function" };
124125
125126 // Efficiency histograms
126127 TH2D** hEffPions = new TH2D*[2 ];
@@ -770,7 +771,7 @@ struct ThreeParticleCorrelations {
770771 bool fakeV0Filter (const V0Cand& v0, const TrackCand& track)
771772 {
772773
773- if (confFilterSwitch ) {
774+ if (confFakeV0Switch ) {
774775
775776 if (trackPID (track)[0 ] == kaonID) { // Kaons
776777 return kTRUE ;
@@ -814,41 +815,44 @@ struct ThreeParticleCorrelations {
814815 bool radialDistanceFilter (const V0Cand& v0, const TrackCand& track, double B, bool Mix)
815816 {
816817
817- auto proton = v0.template posTrack_as <MyFilteredTracks>();
818- if (v0Sign (v0) == -1 ) {
819- proton = v0.template negTrack_as <MyFilteredTracks>();
820- }
818+ if (confRDSwitch) {
821819
822- double dEta = proton. eta () - track. eta ();
823- if (std::abs (dEta) > dEtaMin ) {
824- return kTRUE ;
825- }
820+ auto proton = v0. template posTrack_as <MyFilteredTracks> ();
821+ if (v0Sign (v0) == - 1 ) {
822+ proton = v0. template negTrack_as <MyFilteredTracks>() ;
823+ }
826824
827- double dPhiStar;
828- double dPhi = proton.phi () - track.phi ();
829- double phaseProton = (-0.3 * B * proton.sign ()) / (2 * proton.pt ());
830- double phaseTrack = (-0.3 * B * track.sign ()) / (2 * track.pt ());
825+ double dEta = proton.eta () - track.eta ();
826+ if (std::abs (dEta) > dEtaMin) {
827+ return kTRUE ;
828+ }
829+
830+ double dPhiStar;
831+ double dPhi = proton.phi () - track.phi ();
832+ double phaseProton = (-0.3 * B * proton.sign ()) / (2 * proton.pt ());
833+ double phaseTrack = (-0.3 * B * track.sign ()) / (2 * track.pt ());
831834
832- for (double r = rMin; r <= rMax; r += 0.01 ) {
833- dPhiStar = RecoDecay::constrainAngle (dPhi + std::asin (phaseProton * r) - std::asin (phaseTrack * r), -constants::math::PIHalf);
835+ for (double r = rMin; r <= rMax; r += 0.01 ) {
836+ dPhiStar = RecoDecay::constrainAngle (dPhi + std::asin (phaseProton * r) - std::asin (phaseTrack * r), -constants::math::PIHalf);
834837
835- if (r == rMin) {
836- if (!Mix) {
837- rPhiStarRegistry.fill (HIST (" hSEProtonPreCut" ), dPhiStar, dEta);
838- } else {
839- rPhiStarRegistry.fill (HIST (" hMEProtonPreCut" ), dPhiStar, dEta);
838+ if (r == rMin) {
839+ if (!Mix) {
840+ rPhiStarRegistry.fill (HIST (" hSEProtonPreCut" ), dPhiStar, dEta);
841+ } else {
842+ rPhiStarRegistry.fill (HIST (" hMEProtonPreCut" ), dPhiStar, dEta);
843+ }
840844 }
841- }
842845
843- if (std::abs (dPhiStar) < dPhiStarMin) {
844- return kFALSE ;
845- }
846+ if (std::abs (dPhiStar) < dPhiStarMin) {
847+ return kFALSE ;
848+ }
846849
847- if (r == rMin) {
848- if (!Mix) {
849- rPhiStarRegistry.fill (HIST (" hSEProtonPostCut" ), dPhiStar, dEta);
850- } else {
851- rPhiStarRegistry.fill (HIST (" hMEProtonPostCut" ), dPhiStar, dEta);
850+ if (r == rMin) {
851+ if (!Mix) {
852+ rPhiStarRegistry.fill (HIST (" hSEProtonPostCut" ), dPhiStar, dEta);
853+ } else {
854+ rPhiStarRegistry.fill (HIST (" hMEProtonPostCut" ), dPhiStar, dEta);
855+ }
852856 }
853857 }
854858 }
0 commit comments