@@ -93,6 +93,7 @@ using DaughterTracks = soa::Join<aod::Tracks, aod::TracksIU, aod::TracksExtra, a
9393 aod::pidTPCFullPi, aod::pidTPCFullKa, aod::pidTPCFullPr,
9494 aod::pidTOFFullPi, aod::pidTOFFullKa, aod::pidTOFFullPr>;
9595using DaughterTracksMC = soa::Join<DaughterTracks, aod::McTrackLabels>;
96+ using DaughterTracksMB = soa::Join<DaughterTracks, aod::TrackSelection>;
9697
9798struct StrangenessInJetsIons {
9899
@@ -135,6 +136,7 @@ struct StrangenessInJetsIons {
135136 Configurable<int > centrEstimator{" centrEstimator" , 1 , " Select centrality estimator. Options: 0 = FT0C, 1 = FT0M. CCDB objects available only for FT0M." };
136137 Configurable<bool > calculateFeeddownMatrix{" calculateFeeddownMatrix" , true , " Fill feeddown matrix for Lambda if MC" };
137138 Configurable<bool > useV0inJetRec{" useV0inJetRec" , true , " Include V0s in jet reconstruction" };
139+ Configurable<bool > saveChargedParticleMB{" saveChargedParticleMB" , false , " Store charged particle information to build inclusive spectra." };
138140
139141 // Event selection
140142 Configurable<bool > requireNoSameBunchPileup{" requireNoSameBunchPileup" , true , " Require kNoSameBunchPileup selection" };
@@ -287,7 +289,7 @@ struct StrangenessInJetsIons {
287289 registryData.add (" number_of_events_vsmultiplicity" , " number of events in data vs multiplicity" , HistType::kTH1D , {{101 , 0 , 101 , " Multiplicity percentile" }});
288290
289291 // For MB
290- registryData.add (" number_of_events_vsmultiplicity_MB" , " number of events in data vs multiplicity (MB)" , HistType::kTH1D , {{101 , 0 , 101 , " Multiplicity percentile" }});
292+ // registryData.add("number_of_events_vsmultiplicity_MB", "number of events in data vs multiplicity (MB)", HistType::kTH1D, {{101, 0, 101, "Multiplicity percentile"}});
291293
292294 registryData.get <TH1>(HIST (" number_of_events_data" ))->GetXaxis ()->SetBinLabel (1 , " All collisions" );
293295 registryData.get <TH1>(HIST (" number_of_events_data" ))->GetXaxis ()->SetBinLabel (2 , " Zorro selection" );
@@ -555,17 +557,17 @@ struct StrangenessInJetsIons {
555557 if (doprocessDataMB) {
556558
557559 // Event counters
558- registryDataMB.add (" number_of_events_data " , " number of events in data" , HistType::kTH1D , {{20 , 0 , 20 , " Event Cuts" }});
559- registryDataMB.add (" number_of_events_vsmultiplicity " , " number of events in data vs multiplicity" , HistType::kTH1D , {{101 , 0 , 101 , " Multiplicity percentile" }});
560-
561- registryDataMB.get <TH1>(HIST (" number_of_events_data " ))->GetXaxis ()->SetBinLabel (1 , " All collisions" );
562- registryDataMB.get <TH1>(HIST (" number_of_events_data " ))->GetXaxis ()->SetBinLabel (2 , " Zorro selection" );
563- registryDataMB.get <TH1>(HIST (" number_of_events_data " ))->GetXaxis ()->SetBinLabel (3 , " sel8" );
564- registryDataMB.get <TH1>(HIST (" number_of_events_data " ))->GetXaxis ()->SetBinLabel (4 , " posZ cut" );
565- registryDataMB.get <TH1>(HIST (" number_of_events_data " ))->GetXaxis ()->SetBinLabel (5 , " kNoSameBunchPileup" );
566- registryDataMB.get <TH1>(HIST (" number_of_events_data " ))->GetXaxis ()->SetBinLabel (6 , " kIsGoodZvtxFT0vsPV" );
567- registryDataMB.get <TH1>(HIST (" number_of_events_data " ))->GetXaxis ()->SetBinLabel (7 , " No empty events" );
568- registryDataMB.get <TH1>(HIST (" number_of_events_data " ))->GetXaxis ()->SetBinLabel (8 , " At least one jet" );
560+ registryDataMB.add (" number_of_events_data_MB " , " number of events in data (MB) " , HistType::kTH1D , {{20 , 0 , 20 , " Event Cuts" }});
561+ registryDataMB.add (" number_of_events_vsmultiplicity_MB " , " number of events in data vs multiplicity (MB) " , HistType::kTH1D , {{101 , 0 , 101 , " Multiplicity percentile" }});
562+
563+ registryDataMB.get <TH1>(HIST (" number_of_events_data_MB " ))->GetXaxis ()->SetBinLabel (1 , " All collisions" );
564+ registryDataMB.get <TH1>(HIST (" number_of_events_data_MB " ))->GetXaxis ()->SetBinLabel (2 , " Zorro selection" );
565+ registryDataMB.get <TH1>(HIST (" number_of_events_data_MB " ))->GetXaxis ()->SetBinLabel (3 , " sel8" );
566+ registryDataMB.get <TH1>(HIST (" number_of_events_data_MB " ))->GetXaxis ()->SetBinLabel (4 , " posZ cut" );
567+ registryDataMB.get <TH1>(HIST (" number_of_events_data_MB " ))->GetXaxis ()->SetBinLabel (5 , " kNoSameBunchPileup" );
568+ registryDataMB.get <TH1>(HIST (" number_of_events_data_MB " ))->GetXaxis ()->SetBinLabel (6 , " kIsGoodZvtxFT0vsPV" );
569+ registryDataMB.get <TH1>(HIST (" number_of_events_data_MB " ))->GetXaxis ()->SetBinLabel (7 , " No empty events" );
570+ registryDataMB.get <TH1>(HIST (" number_of_events_data_MB " ))->GetXaxis ()->SetBinLabel (8 , " At least one jet" );
569571
570572 // Histograms for analysis of strange hadrons
571573 if (particleOfInterestDict[ParticleOfInterest::kV0Particles ]) {
@@ -588,6 +590,9 @@ struct StrangenessInJetsIons {
588590 if (particleOfInterestDict[ParticleOfInterest::kProtons ]) {
589591 registryDataMB.add (" Proton_in_MB" , " Proton_in_MB" , HistType::kTHnSparseF , {multAxis, ptAxisLongLived, nsigmaTPCAxis, nsigmaTOFAxis, dcaAxis});
590592 }
593+ if (saveChargedParticleMB) {
594+ registryDataMB.add (" ChargedTrack_in_MB" , " ChargedTrack_in_MB" , HistType::kTH2F , {multAxis, ptAxis});
595+ }
591596 }
592597 }
593598
@@ -1189,6 +1194,64 @@ struct StrangenessInJetsIons {
11891194 return true ;
11901195 }
11911196
1197+ // --- MB Selections ------------------------------------
1198+ // The rapidty cut is added, which is not required in jet and UE
1199+ // K0s selections (MB)
1200+ template <typename K0short, typename TrackPos, typename TrackNeg>
1201+ bool passedK0ShortSelectionMB (const K0short& v0, const TrackPos& ptrack, const TrackNeg& ntrack, const TVector3& vtxPos)
1202+ {
1203+ bool passedSel = passedK0ShortSelection (v0, ptrack, ntrack, vtxPos);
1204+
1205+ if (!passedRapidityCut (v0.yK0Short (), configV0.rapidityMax ))
1206+ return false ;
1207+ return passedSel;
1208+ }
1209+
1210+ // Lambda selections (MB)
1211+ template <typename Lambda, typename TrackPos, typename TrackNeg>
1212+ bool passedLambdaSelectionMB (const Lambda& v0, const TrackPos& ptrack, const TrackNeg& ntrack, const TVector3& vtxPos)
1213+ {
1214+ bool passedSel = passedLambdaSelection (v0, ptrack, ntrack, vtxPos);
1215+
1216+ if (!passedRapidityCut (v0.yLambda (), configV0.rapidityMax ))
1217+ return false ;
1218+ return passedSel;
1219+ }
1220+
1221+ // AntiLambda selections (MB)
1222+ template <typename AntiLambda, typename TrackPos, typename TrackNeg>
1223+ bool passedAntiLambdaSelectionMB (const AntiLambda& v0, const TrackPos& ptrack, const TrackNeg& ntrack, const TVector3& vtxPos)
1224+ {
1225+ bool passedSel = passedAntiLambdaSelection (v0, ptrack, ntrack, vtxPos);
1226+
1227+ if (!passedRapidityCut (v0.yLambda (), configV0.rapidityMax ))
1228+ return false ;
1229+ return passedSel;
1230+ }
1231+
1232+ // Xi Selections (MB)
1233+ template <typename Xi, typename TrackPos, typename TrackNeg, typename TrackBac, typename Coll>
1234+ bool passedXiSelectionMB (const Xi& casc, const TrackPos& ptrack, const TrackNeg& ntrack, const TrackBac& btrack, const Coll& coll)
1235+ {
1236+ bool passedSel = passedXiSelection (casc, ptrack, ntrack, btrack, coll);
1237+
1238+ if (!passedRapidityCut (casc.yXi (), configV0.rapidityMax ))
1239+ return false ;
1240+ return passedSel;
1241+ }
1242+
1243+ // Omega selections (MB)
1244+ template <typename Omega, typename TrackPos, typename TrackNeg, typename TrackBac, typename Coll>
1245+ bool passedOmegaSelectionMB (const Omega& casc, const TrackPos& ptrack, const TrackNeg& ntrack, const TrackBac& btrack, const Coll& coll)
1246+ {
1247+ bool passedSel = passedOmegaSelection (casc, ptrack, ntrack, btrack, coll);
1248+
1249+ if (!passedRapidityCut (casc.yOmega (), configV0.rapidityMax ))
1250+ return false ;
1251+ return passedSel;
1252+ }
1253+ // ------------------------------------------------------
1254+
11921255 // Event selection for MC Reco collision
11931256 template <typename coll>
11941257 bool selectRecoEvent (const coll& recoColl)
@@ -1911,13 +1974,13 @@ struct StrangenessInJetsIons {
19111974 registryData.fill (HIST (" number_of_events_data" ), 5.5 );
19121975
19131976 // Event multiplicity
1914- float centrality;
1915- if (centrEstimator == 0 ) {
1916- centrality = collision.centFT0C ();
1917- } else {
1918- centrality = collision.centFT0M ();
1919- }
1920- registryData.fill (HIST (" number_of_events_vsmultiplicity_MB" ), centrality);
1977+ // float centrality;
1978+ // if (centrEstimator == 0) {
1979+ // centrality = collision.centFT0C();
1980+ // } else {
1981+ // centrality = collision.centFT0M();
1982+ // }
1983+ // registryData.fill(HIST("number_of_events_vsmultiplicity_MB"), centrality);
19211984
19221985 // Loop over reconstructed tracks
19231986 std::vector<fastjet::PseudoJet> fjParticles;
@@ -2331,7 +2394,7 @@ struct StrangenessInJetsIons {
23312394
23322395 // Set up two perpendicular cone axes for underlying event estimation
23332396 TVector3 jetAxis (jet.px (), jet.py (), jet.pz ());
2334- double coneRadius = std::sqrt (jet.area () / PI);
2397+ double coneRadius = std::sqrt (jet.area () / PI); // TODO: replace with rJet (similar results)
23352398 TVector3 ueAxis1 (0 , 0 , 0 ), ueAxis2 (0 , 0 , 0 );
23362399 getPerpendicularDirections (jetAxis, ueAxis1, ueAxis2);
23372400 if (ueAxis1.Mag () == 0 || ueAxis2.Mag () == 0 ) {
@@ -3225,14 +3288,14 @@ struct StrangenessInJetsIons {
32253288 // --- Process Minimum Bias events ---
32263289 // Process data MB
32273290 void processDataMB (SelCollisions::iterator const & collision, aod::V0Datas const & fullV0s,
3228- aod::CascDataExt const & Cascades, DaughterTracks const & tracks,
3291+ aod::CascDataExt const & Cascades, DaughterTracksMB const & tracks,
32293292 aod::BCsWithTimestamps const &)
32303293 {
32313294 // Vertex position vector
32323295 TVector3 vtxPos (collision.posX (), collision.posY (), collision.posZ ());
32333296
32343297 // Fill event counter before event selection
3235- registryDataMB.fill (HIST (" number_of_events_data " ), 0.5 );
3298+ registryDataMB.fill (HIST (" number_of_events_data_MB " ), 0.5 );
32363299
32373300 // Get the bunch crossing (BC) information associated with the collision
32383301 auto bc = collision.template bc_as <aod::BCsWithTimestamps>();
@@ -3246,35 +3309,35 @@ struct StrangenessInJetsIons {
32463309 }
32473310
32483311 // Fill event counter after zorro selection
3249- registryDataMB.fill (HIST (" number_of_events_data " ), 1.5 );
3312+ registryDataMB.fill (HIST (" number_of_events_data_MB " ), 1.5 );
32503313
32513314 // Event selection
32523315 if (!collision.sel8 ())
32533316 return ;
32543317
32553318 // Fill event counter after sel8 selection
3256- registryDataMB.fill (HIST (" number_of_events_data " ), 2.5 );
3319+ registryDataMB.fill (HIST (" number_of_events_data_MB " ), 2.5 );
32573320
32583321 // Require vertex position within the allowed z range
32593322 if (std::fabs (collision.posZ ()) > zVtx)
32603323 return ;
32613324
32623325 // Fill event counter after z vertex selection
3263- registryDataMB.fill (HIST (" number_of_events_data " ), 3.5 );
3326+ registryDataMB.fill (HIST (" number_of_events_data_MB " ), 3.5 );
32643327
32653328 // Reject collisions associated to the same found BC
32663329 if (requireNoSameBunchPileup && !collision.selection_bit (o2::aod::evsel::kNoSameBunchPileup ))
32673330 return ;
32683331
32693332 // Fill event counter after selection kNoSameBunchPileup
3270- registryDataMB.fill (HIST (" number_of_events_data " ), 4.5 );
3333+ registryDataMB.fill (HIST (" number_of_events_data_MB " ), 4.5 );
32713334
32723335 // Compatible z_vtx from FT0 and from PV
32733336 if (requireGoodZvtxFT0vsPV && !collision.selection_bit (o2::aod::evsel::kIsGoodZvtxFT0vsPV ))
32743337 return ;
32753338
32763339 // Fill event counter after selection kIsGoodZvtxFT0vsPV
3277- registryDataMB.fill (HIST (" number_of_events_data " ), 5.5 );
3340+ registryDataMB.fill (HIST (" number_of_events_data_MB " ), 5.5 );
32783341
32793342 // Event multiplicity
32803343 float centrality;
@@ -3283,26 +3346,35 @@ struct StrangenessInJetsIons {
32833346 } else {
32843347 centrality = collision.centFT0M ();
32853348 }
3286- registryDataMB.fill (HIST (" number_of_events_vsmultiplicity" ), centrality);
3349+ registryDataMB.fill (HIST (" number_of_events_vsmultiplicity_MB" ), centrality);
3350+
3351+ if (saveChargedParticleMB) {
3352+ for (const auto & trk : tracks) {
3353+ if (!passedTrackSelectionForJetReconstruction (trk) || !trk.isGlobalTrack ()) {
3354+ continue ;
3355+ }
3356+ registryDataMB.fill (HIST (" ChargedTrack_in_MB" ), centrality, trk.pt ());
3357+ }
3358+ }
32873359
32883360 if (particleOfInterestDict[ParticleOfInterest::kV0Particles ]) { // V0s
32893361 for (const auto & v0 : fullV0s) {
32903362
32913363 // Get V0 daughters
3292- const auto & pos = v0.posTrack_as <DaughterTracks >();
3293- const auto & neg = v0.negTrack_as <DaughterTracks >();
3364+ const auto & pos = v0.posTrack_as <DaughterTracksMB >();
3365+ const auto & neg = v0.negTrack_as <DaughterTracksMB >();
32943366 TVector3 v0dir (v0.px (), v0.py (), v0.pz ());
32953367
32963368 // K0s
3297- if (passedK0ShortSelection (v0, pos, neg, vtxPos)) {
3369+ if (passedK0ShortSelectionMB (v0, pos, neg, vtxPos)) {
32983370 registryDataMB.fill (HIST (" K0s_in_MB" ), centrality, v0.pt (), v0.mK0Short ());
32993371 }
33003372 // Lambda
3301- if (passedLambdaSelection (v0, pos, neg, vtxPos)) {
3373+ if (passedLambdaSelectionMB (v0, pos, neg, vtxPos)) {
33023374 registryDataMB.fill (HIST (" Lambda_in_MB" ), centrality, v0.pt (), v0.mLambda ());
33033375 }
33043376 // AntiLambda
3305- if (passedAntiLambdaSelection (v0, pos, neg, vtxPos)) {
3377+ if (passedAntiLambdaSelectionMB (v0, pos, neg, vtxPos)) {
33063378 registryDataMB.fill (HIST (" AntiLambda_in_MB" ), centrality, v0.pt (), v0.mAntiLambda ());
33073379 }
33083380 }
@@ -3317,19 +3389,19 @@ struct StrangenessInJetsIons {
33173389 TVector3 cascadeDir (casc.px (), casc.py (), casc.pz ());
33183390
33193391 // Xi+
3320- if (passedXiSelection (casc, pos, neg, bach, collision) && bach.sign () > 0 ) {
3392+ if (passedXiSelectionMB (casc, pos, neg, bach, collision) && bach.sign () > 0 ) {
33213393 registryDataMB.fill (HIST (" XiPos_in_MB" ), centrality, casc.pt (), casc.mXi ());
33223394 }
33233395 // Xi-
3324- if (passedXiSelection (casc, pos, neg, bach, collision) && bach.sign () < 0 ) {
3396+ if (passedXiSelectionMB (casc, pos, neg, bach, collision) && bach.sign () < 0 ) {
33253397 registryDataMB.fill (HIST (" XiNeg_in_MB" ), centrality, casc.pt (), casc.mXi ());
33263398 }
33273399 // Omega+
3328- if (passedOmegaSelection (casc, pos, neg, bach, collision) && bach.sign () > 0 ) {
3400+ if (passedOmegaSelectionMB (casc, pos, neg, bach, collision) && bach.sign () > 0 ) {
33293401 registryDataMB.fill (HIST (" OmegaPos_in_MB" ), centrality, casc.pt (), casc.mOmega ());
33303402 }
33313403 // Omega-
3332- if (passedOmegaSelection (casc, pos, neg, bach, collision) && bach.sign () < 0 ) {
3404+ if (passedOmegaSelectionMB (casc, pos, neg, bach, collision) && bach.sign () < 0 ) {
33333405 registryDataMB.fill (HIST (" OmegaNeg_in_MB" ), centrality, casc.pt (), casc.mOmega ());
33343406 }
33353407 }
0 commit comments