@@ -213,7 +213,7 @@ class FemtoUniverseDetaDphiStar
213213 }
214214
215215 // / Check if pair is close or not
216- template <typename Part, typename Parts>
216+ template <bool V0V0rect = true , typename Part, typename Parts>
217217 bool isClosePair (Part const & part1, Part const & part2, Parts const & particles, float lmagfield, uint8_t ChosenEventType)
218218 {
219219 magfield = lmagfield;
@@ -307,8 +307,9 @@ class FemtoUniverseDetaDphiStar
307307 LOG (fatal) << " FemtoUniverseDetaDphiStar: passed arguments don't agree with FemtoUniverseDetaDphiStar's type of events! Please provide same or mixed." ;
308308 }
309309
310- // if (std::pow(dphiAvg, 2) / std::pow(cutDeltaPhiStarMax, 2) + std::pow(deta, 2) / std::pow(cutDeltaEtaMax, 2) < 1.) {
311- if ((dphiAvg > cutDeltaPhiStarMin) && (dphiAvg < cutDeltaPhiStarMax) && (deta > cutDeltaEtaMin) && (deta < cutDeltaEtaMax)) {
310+ if (V0V0rect && (dphiAvg > cutDeltaPhiStarMin) && (dphiAvg < cutDeltaPhiStarMax) && (deta > cutDeltaEtaMin) && (deta < cutDeltaEtaMax)) {
311+ pass = true ;
312+ } else if (!V0V0rect && std::pow (dphiAvg, 2 ) / std::pow (cutDeltaPhiStarMax, 2 ) + std::pow (deta, 2 ) / std::pow (cutDeltaEtaMax, 2 ) < 1 .) {
312313 pass = true ;
313314 } else {
314315 if (ChosenEventType == femto_universe_container::EventType::same) {
@@ -321,7 +322,6 @@ class FemtoUniverseDetaDphiStar
321322 }
322323 }
323324 return pass;
324-
325325 } else if constexpr (kPartOneType == o2::aod::femtouniverseparticle::ParticleType::kCascade && kPartTwoType == o2::aod::femtouniverseparticle::ParticleType::kCascade ) {
326326 // / Cascade-Cascade combination
327327 if (part1.partType () != o2::aod::femtouniverseparticle::ParticleType::kCascade || part2.partType () != o2::aod::femtouniverseparticle::ParticleType::kCascade ) {
@@ -361,7 +361,6 @@ class FemtoUniverseDetaDphiStar
361361 }
362362 }
363363 return pass;
364-
365364 } else if constexpr (kPartOneType == o2::aod::femtouniverseparticle::ParticleType::kTrack && kPartTwoType == o2::aod::femtouniverseparticle::ParticleType::kCascade ) {
366365 // / Track-Cascade combination
367366 if (part1.partType () != o2::aod::femtouniverseparticle::ParticleType::kTrack || part2.partType () != o2::aod::femtouniverseparticle::ParticleType::kCascade ) {
@@ -398,7 +397,6 @@ class FemtoUniverseDetaDphiStar
398397 }
399398 }
400399 return pass;
401-
402400 } else if constexpr (kPartOneType == o2::aod::femtouniverseparticle::ParticleType::kV0 && kPartTwoType == o2::aod::femtouniverseparticle::ParticleType::kCascade ) {
403401 // / V0-Cascade combination
404402 if (part1.partType () != o2::aod::femtouniverseparticle::ParticleType::kV0 || part2.partType () != o2::aod::femtouniverseparticle::ParticleType::kCascade ) {
@@ -438,7 +436,6 @@ class FemtoUniverseDetaDphiStar
438436 }
439437 }
440438 return pass;
441-
442439 } else if constexpr (kPartOneType == o2::aod::femtouniverseparticle::ParticleType::kTrack && kPartTwoType == o2::aod::femtouniverseparticle::ParticleType::kD0 ) {
443440 // / Track-D0 combination
444441 // check if provided particles are in agreement with the class instantiation
0 commit comments