3737#include " Math/Vector4D.h"
3838#include " TPDGCode.h"
3939#include " TRandom.h"
40- #include " TVector3.h"
4140
4241using namespace o2 ;
4342using namespace o2 ::soa;
@@ -189,18 +188,18 @@ struct Lstaranalysis {
189188
190189 // Pre-filters for efficient process
191190 Filter zVtxFilter = (nabs(o2::aod::collision::posZ) <= configEvents.cfgEvtZvtx);
192- Filter collisionFilter_MC = nabs(aod::mccollision::posZ) <= configEvents.cfgEvtZvtx;
191+ Filter collisionFilterMC = nabs(aod::mccollision::posZ) <= configEvents.cfgEvtZvtx;
193192 // Filter centralityFilter = nabs(aod::cent::centFT0C) <= cfg_Event_CentralityMax;
194193 // Filter triggerFilter = (o2::aod::evsel::sel8 == true);
195194
196195 Filter tofPIDFilter = aod::track::tofExpMom < 0 .f || ((aod::track::tofExpMom > 0 .f) && (/* (nabs(aod::pidtof::tofNSigmaPi) < configPID.pidnSigmaPreSelectionCut) || */ (nabs(aod::pidtof::tofNSigmaKa) < configPID.pidnSigmaPreSelectionCut) || (nabs(aod::pidtof::tofNSigmaPr) < configPID.pidnSigmaPreSelectionCut))); // TOF
197196 Filter tpcPIDFilter = /* nabs(aod::pidtpc::tpcNSigmaPi) < configPID.pidnSigmaPreSelectionCut || */ nabs(aod::pidtpc::tpcNSigmaKa) < configPID.pidnSigmaPreSelectionCut || nabs(aod::pidtpc::tpcNSigmaPr) < configPID.pidnSigmaPreSelectionCut; // TPC
198- Filter trackFilter = (configTracks.trackSelection == 0 ) ||
199- ((configTracks.trackSelection == 1 ) && requireGlobalTrackInFilter()) ||
200- ((configTracks.trackSelection == 2 ) && requireGlobalTrackWoPtEtaInFilter()) ||
201- ((configTracks.trackSelection == 3 ) && requireGlobalTrackWoDCAInFilter()) ||
202- ((configTracks.trackSelection == 4 ) && requireQualityTracksInFilter()) ||
203- ((configTracks.trackSelection == 5 ) && requireTrackCutInFilter(TrackSelectionFlags::kInAcceptanceTracks ));
197+ Filter trackFilter = (configTracks.trackSelection == static_cast < int >( 0 ) ) ||
198+ ((configTracks.trackSelection == static_cast < int >( 1 ) ) && requireGlobalTrackInFilter()) ||
199+ ((configTracks.trackSelection == static_cast < int >( 2 ) ) && requireGlobalTrackWoPtEtaInFilter()) ||
200+ ((configTracks.trackSelection == static_cast < int >( 3 ) ) && requireGlobalTrackWoDCAInFilter()) ||
201+ ((configTracks.trackSelection == static_cast < int >( 4 ) ) && requireQualityTracksInFilter()) ||
202+ ((configTracks.trackSelection == static_cast < int >( 5 ) ) && requireTrackCutInFilter(TrackSelectionFlags::kInAcceptanceTracks ));
204203 Filter acceptanceFilter = (nabs(aod::track::eta) < configTracks.cfgCutEta && nabs(aod::track::pt) > configTracks.cMinPtcut);
205204 // Filter DCAcutFilter = (nabs(aod::track::dcaXY) < configTracks.cfgCutDCAxy) && (nabs(aod::track::dcaZ) < configTracks.cfgCutDCAz);
206205 // Filter primarytrackFilter = requirePVContributor() && requirePrimaryTrack() && requireGlobalTrackWoDCA();
@@ -454,8 +453,8 @@ struct Lstaranalysis {
454453 continue ;
455454 auto p = pdg->GetParticle (mcparticle.pdgCode ());
456455 if (p != nullptr ) {
457- if (std::abs (p->Charge ()) >= 3 ) {
458- if (std::abs (mcparticle.eta ()) < 1 )
456+ if (std::abs (p->Charge ()) >= static_cast < int >( 3 ) ) {
457+ if (std::abs (mcparticle.eta ()) < static_cast < float >( 1.0 ) )
459458 return true ;
460459 }
461460 }
@@ -555,7 +554,7 @@ struct Lstaranalysis {
555554 return true ;
556555 }
557556 }
558- } else if (configPID.cPIDcutType == 2 ) {
557+ } else if (configPID.cPIDcutType == static_cast < int >( 2 ) ) {
559558 // Circular cut
560559 for (size_t i = 0 ; i < vProtonTPCTOFCombinedpTintv.size (); ++i) {
561560 if (pt < vProtonTPCTOFCombinedpTintv[i]) {
@@ -627,7 +626,7 @@ struct Lstaranalysis {
627626 }
628627 }
629628 }
630- } else if (configPID.cPIDcutType == 2 ) {
629+ } else if (configPID.cPIDcutType == static_cast < int >( 2 ) ) {
631630 // Circular cut
632631 for (size_t i = 0 ; i < vKaonTPCTOFCombinedpTintv.size (); ++i) {
633632 if (pt < vKaonTPCTOFCombinedpTintv[i]) {
@@ -855,7 +854,7 @@ struct Lstaranalysis {
855854 auto resonanceRotPt = lResonanceRot.Pt ();
856855
857856 // Rapidity cut
858- if (std::abs (lResonanceRot.Rapidity ()) >= 0.5 )
857+ if (std::abs (lResonanceRot.Rapidity ()) >= static_cast < float >( 0.5 ) )
859858 continue ;
860859
861860 if (cfgUseCutsOnMother) {
@@ -937,7 +936,7 @@ struct Lstaranalysis {
937936 motherstrk1 = getMothersIndeces (mctrk1);
938937 mothersPDGtrk1 = getMothersPDGCodes (mctrk1);
939938 }
940- while (motherstrk1.size () > 2 ) {
939+ while (motherstrk1.size () > static_cast < int >( 2 ) ) {
941940 motherstrk1.pop_back ();
942941 mothersPDGtrk1.pop_back ();
943942 }
@@ -947,18 +946,18 @@ struct Lstaranalysis {
947946 motherstrk2 = getMothersIndeces (mctrk2);
948947 mothersPDGtrk2 = getMothersPDGCodes (mctrk2);
949948 }
950- while (motherstrk2.size () > 2 ) {
949+ while (motherstrk2.size () > static_cast < int >( 2 ) ) {
951950 motherstrk2.pop_back ();
952951 mothersPDGtrk2.pop_back ();
953952 }
954953
955- if (std::abs (mctrk1.pdgCode ()) != 2212 || std::abs (mctrk2.pdgCode ()) != 321 )
954+ if (std::abs (mctrk1.pdgCode ()) != kProton || std::abs (mctrk2.pdgCode ()) != kKPlus )
956955 continue ;
957956
958957 if (motherstrk1[0 ] != motherstrk2[0 ]) // Same mother
959958 continue ;
960959
961- if (std::abs (mothersPDGtrk1[0 ]) != 102134 )
960+ if (std::abs (mothersPDGtrk1[0 ]) != kLambda1520PDG )
962961 continue ;
963962
964963 // LOGF(info, "mother trk1 id: %d, mother trk1: %d, trk1 id: %d, trk1 pdgcode: %d, mother trk2 id: %d, mother trk2: %d, trk2 id: %d, trk2 pdgcode: %d", motherstrk1[0], mothersPDGtrk1[0], trk1.globalIndex(), mctrk1.pdgCode(), motherstrk2[0], mothersPDGtrk2[0], trk2.globalIndex(), mctrk2.pdgCode());
@@ -1062,12 +1061,12 @@ struct Lstaranalysis {
10621061 }
10631062 PROCESS_SWITCH (Lstaranalysis, processMC, " Process Event for MC Light without partition" , false );
10641063
1065- Partition<aod::McParticles> selectedMCParticles = (nabs(aod::mcparticle::pdgCode) == 102134 ); // Lambda(1520)
1064+ Partition<aod::McParticles> selectedMCParticles = (nabs(aod::mcparticle::pdgCode) == kLambda1520PDG ); // Lambda(1520)
10661065
10671066 void processMCTrue (MCEventCandidates::iterator const & collision, aod::McCollisions const &, aod::McParticles const & mcParticles)
10681067 {
10691068 bool isInAfterAllCuts = colCuts.isSelected (collision);
1070- bool inVtx10 = (std::abs (collision.mcCollision ().posZ ()) > 10 .) ? false : true ;
1069+ bool inVtx10 = (std::abs (collision.mcCollision ().posZ ()) > static_cast < float >( 10.0 ) ) ? false : true ;
10711070 bool isTriggerTVX = collision.selection_bit (aod::evsel::kIsTriggerTVX );
10721071 bool isSel8 = collision.sel8 ();
10731072 bool isTrueINELgt0 = isTrueINEL0 (collision, mcParticles);
@@ -1106,7 +1105,7 @@ struct Lstaranalysis {
11061105 continue ;
11071106
11081107 if (cfgUseDaughterEtaCutMC) {
1109- for (auto & daughters : part.daughters_as <aod::McParticles>()) {
1108+ for (auto const & daughters : part.daughters_as <aod::McParticles>()) {
11101109 if (std::fabs (daughters.eta ()) > configTracks.cfgCutEta )
11111110 continue ; // eta cut for daughters
11121111 } // loop over daughters
0 commit comments