Skip to content

Commit cf45351

Browse files
[PWGLF] Added histograms for FV0 Mult vs Flattenicity (#9876)
1 parent cc38057 commit cf45351

File tree

1 file changed

+77
-66
lines changed

1 file changed

+77
-66
lines changed

PWGLF/Tasks/Strangeness/lambdak0sflattenicity.cxx

Lines changed: 77 additions & 66 deletions
Original file line numberDiff line numberDiff line change
@@ -134,42 +134,42 @@ struct Lambdak0sflattenicity {
134134
Configurable<bool> flattenicityforLossCorrRec{"flattenicityforLossCorrRec", true,
135135
"Flattenicity from Rec Tracks are used for Signal and Event loss calculations"};
136136
// Common Configurable parameters for V0 selection
137-
Configurable<float> v0settingDcav0dau{"v0settingDcav0dau", 1,
138-
"DCA V0 Daughters"};
139-
Configurable<float> v0settingDcapostopv{"v0settingDcapostopv", 0.06,
140-
"DCA Pos To PV"};
141-
Configurable<float> v0settingDcanegtopv{"v0settingDcanegtopv", 0.06,
142-
"DCA Neg To PV"};
143-
Configurable<float> v0settingRapidity{"v0settingRapidity", 0.5,
144-
"V0 rapidity cut"};
137+
Configurable<float> v0setting_dcav0dau{"v0setting_dcav0dau", 1,
138+
"DCA V0 Daughters"};
139+
Configurable<float> v0setting_dcapostopv{"v0setting_dcapostopv", 0.06,
140+
"DCA Pos To PV"};
141+
Configurable<float> v0setting_dcanegtopv{"v0setting_dcanegtopv", 0.06,
142+
"DCA Neg To PV"};
143+
Configurable<float> v0setting_rapidity{"v0setting_rapidity", 0.5,
144+
"V0 rapidity cut"};
145145

146146
// Configurable parameters for V0 selection for KOs
147-
Configurable<double> v0settingCospaK0s{"v0settingCospaK0s", 0.97,
148-
"V0 CosPA for K0s"};
149-
Configurable<float> v0settingRadiusK0s{"v0settingRadiusK0s", 0.5,
150-
"v0radius for K0s"};
151-
Configurable<float> v0settingctauK0s{"v0settingctauK0s", 20,
152-
"v0ctau for K0s"};
153-
Configurable<float> v0settingMassRejectionK0s{"v0settingMassRejectionK0s", 0.005,
154-
"Competing Mass Rejection cut for K0s"};
147+
Configurable<double> v0setting_cospaK0s{"v0setting_cospaK0s", 0.97,
148+
"V0 CosPA for K0s"};
149+
Configurable<float> v0setting_radiusK0s{"v0setting_radiusK0s", 0.5,
150+
"v0radius for K0s"};
151+
Configurable<float> v0setting_ctauK0s{"v0setting_ctauK0s", 20,
152+
"v0ctau for K0s"};
153+
Configurable<float> v0setting_massrejectionK0s{"v0setting_massrejectionK0s", 0.005,
154+
"Competing Mass Rejection cut for K0s"};
155155

156156
// Configurable parameters for V0 selection for Lambda
157-
Configurable<double> v0settingCospaLambda{"v0settingCospaLambda", 0.995,
158-
"V0 CosPA for Lambda"};
159-
Configurable<float> v0settingRadiusLambda{"v0settingRadiusLambda", 0.5,
160-
"v0radius for Lambda"};
161-
Configurable<float> v0settingctauLambda{"v0settingctauLambda", 30,
162-
"v0ctau for Lambda"};
163-
Configurable<float> v0settingMassRejectionLambda{"v0settingMassRejectionLambda", 0.01,
164-
"Competing Mass Rejection cut for Lambda"};
157+
Configurable<double> v0setting_cospaLambda{"v0setting_cospaLambda", 0.995,
158+
"V0 CosPA for Lambda"};
159+
Configurable<float> v0setting_radiusLambda{"v0setting_radiusLambda", 0.5,
160+
"v0radius for Lambda"};
161+
Configurable<float> v0setting_ctauLambda{"v0setting_ctauLambda", 30,
162+
"v0ctau for Lambda"};
163+
Configurable<float> v0setting_massrejectionLambda{"v0setting_massrejectionLambda", 0.01,
164+
"Competing Mass Rejection cut for Lambda"};
165165

166166
// Configurable parameters for PID selection
167167
Configurable<float> nSigmaTPCPion{"nSigmaTPCPion", 5, "nSigmaTPCPion"};
168168
Configurable<float> nSigmaTPCProton{"nSigmaTPCProton", 5, "nSigmaTPCProton"};
169169

170170
// Configurable<float> v0daughter_etacut{"V0DaughterEtaCut", 0.8,
171171
// "V0DaughterEtaCut"};
172-
Configurable<float> v0etacut{"v0etacut", 0.8, "v0etacut"};
172+
// Configurable<float> v0etacut{"v0etacut", 0.8, "v0etacut"};
173173

174174
// acceptance cuts for Flattenicity correlation
175175
Configurable<float> cfgTrkEtaCut{"cfgTrkEtaCut", 0.8f,
@@ -270,6 +270,8 @@ struct Lambdak0sflattenicity {
270270
rEventSelection.get<TH1>(HIST("hNEventsMCReco"))->GetXaxis()->SetBinLabel(2, "pass ev sel");
271271
rEventSelection.get<TH1>(HIST("hNEventsMCReco"))->GetXaxis()->SetBinLabel(3, "INELgt0");
272272
rEventSelection.get<TH1>(HIST("hNEventsMCReco"))->GetXaxis()->SetBinLabel(4, "check");
273+
rEventSelection.add("hTrueFV0amplvsFlat", "TrueFV0MvsFlat", HistType::kTH2D,
274+
{{500, -0.5, +499.5, "True Nch in FV0 region"}, flatAxis});
273275
}
274276
// K0s reconstruction
275277
// Mass
@@ -427,6 +429,8 @@ struct Lambdak0sflattenicity {
427429
{{50000, -0.5, 199999.5, "FT0C amplitudes"}});
428430
rFlattenicity.add("hFT0A", "FT0A", HistType::kTH1D,
429431
{{2000, -0.5, 1999.5, "FT0A amplitudes"}});
432+
rFlattenicity.add("hFV0amplvsFlat", "FV0MvsFlat", HistType::kTH2D,
433+
{{4000, -0.5, +49999.5, "FV0 amplitude"}, flatAxis});
430434

431435
// estimators
432436
for (int iEe = 0; iEe < 8; ++iEe) {
@@ -503,12 +507,12 @@ struct Lambdak0sflattenicity {
503507
"Both Data and MC set to false; try again with only one of "
504508
"them set to false");
505509
}
506-
if ((doprocessRecMC && !doprocessGenMC) ||
507-
(!doprocessRecMC && doprocessGenMC)) {
508-
LOGF(fatal,
509-
"MCRec and MCGen are set to opposite switches, try again "
510-
"with both set to either true or false");
511-
}
510+
// if ((doprocessRecMC && !doprocessGenMC) ||
511+
// (!doprocessRecMC && doprocessGenMC)) {
512+
// LOGF(fatal,
513+
// "MCRec and MCGen are set to opposite switches, try again "
514+
// "with both set to either true or false");
515+
// }
512516
}
513517

514518
int getT0ASector(int iCh)
@@ -1126,6 +1130,8 @@ struct Lambdak0sflattenicity {
11261130
}
11271131
}
11281132
float finalflattenicity = estimator[2];
1133+
rFlattenicity.fill(HIST("hFV0amplvsFlat"), sumAmpFV0, estimator[2]);
1134+
11291135
if (flattenicityforanalysis == 1) {
11301136
finalflattenicity = estimator[4];
11311137
}
@@ -1142,6 +1148,8 @@ struct Lambdak0sflattenicity {
11421148
float flattenicity = -1;
11431149
float etamin, etamax, minphi, maxphi, dphi;
11441150
int isegment = 0, nsectors;
1151+
int multFV0 = 0;
1152+
11451153
for (const auto& mcParticle : mcParticles) {
11461154
if (!(mcParticle.isPhysicalPrimary() && mcParticle.pt() > 0)) {
11471155
continue;
@@ -1155,6 +1163,7 @@ struct Lambdak0sflattenicity {
11551163
float etap = mcParticle.eta();
11561164
float phip = mcParticle.phi();
11571165
isegment = 0;
1166+
11581167
for (int ieta = 0; ieta < 5; ieta++) {
11591168
etamax = kMaxEtaFV0 - ieta * kDetaFV0;
11601169
if (ieta == 0) {
@@ -1174,6 +1183,7 @@ struct Lambdak0sflattenicity {
11741183
dphi = std::abs(maxphi - minphi);
11751184
if (etap >= etamin && etap < etamax && phip >= minphi && phip < maxphi) {
11761185
rhoLatticeFV0AMC[isegment] += 1.0 / std::abs(dphi * kDetaFV0);
1186+
multFV0++;
11771187
}
11781188
isegment++;
11791189
}
@@ -1182,16 +1192,17 @@ struct Lambdak0sflattenicity {
11821192

11831193
flattenicity =
11841194
1.0 - getFlatenicity({rhoLatticeFV0AMC.data(), rhoLatticeFV0AMC.size()});
1195+
rEventSelection.fill(HIST("hTrueFV0amplvsFlat"), multFV0, estimator[2]);
11851196
return flattenicity;
11861197
}
11871198
// ====================== Flattenicity estimation ends =====================
11881199

11891200
// Filters on V0s
11901201
// Cannot filter on dynamic columns, so we cut on DCA to PV and DCA between
11911202
// daughters only
1192-
Filter preFilterV0 = (nabs(aod::v0data::dcapostopv) > v0settingDcapostopv &&
1193-
nabs(aod::v0data::dcanegtopv) > v0settingDcanegtopv &&
1194-
aod::v0data::dcaV0daughters < v0settingDcav0dau);
1203+
Filter preFilterV0 = (nabs(aod::v0data::dcapostopv) > v0setting_dcapostopv &&
1204+
nabs(aod::v0data::dcanegtopv) > v0setting_dcanegtopv &&
1205+
aod::v0data::dcaV0daughters < v0setting_dcav0dau);
11951206

11961207
Filter trackFilter =
11971208
(nabs(aod::track::eta) < cfgTrkEtaCut && aod::track::pt > cfgTrkLowPtCut);
@@ -1255,15 +1266,15 @@ struct Lambdak0sflattenicity {
12551266

12561267
// Cut on dynamic columns for K0s
12571268

1258-
if (v0.v0cosPA() >= v0settingCospaK0s &&
1259-
v0.v0radius() >= v0settingRadiusK0s &&
1269+
if (v0.v0cosPA() >= v0setting_cospaK0s &&
1270+
v0.v0radius() >= v0setting_radiusK0s &&
12601271
std::abs(posDaughterTrack.tpcNSigmaPi()) <= nSigmaTPCPion &&
12611272
std::abs(negDaughterTrack.tpcNSigmaPi()) <= nSigmaTPCPion &&
1262-
ctauK0s < v0settingctauK0s &&
1263-
std::abs(v0.rapidity(0)) <= v0settingRapidity &&
1264-
std::abs(massLambda - pdgmassLambda) > v0settingMassRejectionK0s &&
1273+
ctauK0s < v0setting_ctauK0s &&
1274+
std::abs(v0.rapidity(0)) <= v0setting_rapidity &&
1275+
std::abs(massLambda - pdgmassLambda) > v0setting_massrejectionK0s &&
12651276
std::abs(massAntiLambda - pdgmassLambda) >
1266-
v0settingMassRejectionK0s) {
1277+
v0setting_massrejectionK0s) {
12671278

12681279
rKzeroShort.fill(HIST("hMassK0sSelected"), massK0s);
12691280
rKzeroShort.fill(HIST("hDCAV0DaughtersK0s"), v0.dcaV0daughters());
@@ -1286,13 +1297,13 @@ struct Lambdak0sflattenicity {
12861297
}
12871298

12881299
// Cut on dynamic columns for Lambda
1289-
if (v0.v0cosPA() >= v0settingCospaLambda &&
1290-
v0.v0radius() >= v0settingRadiusLambda &&
1300+
if (v0.v0cosPA() >= v0setting_cospaLambda &&
1301+
v0.v0radius() >= v0setting_radiusLambda &&
12911302
std::abs(posDaughterTrack.tpcNSigmaPr()) <= nSigmaTPCProton &&
12921303
std::abs(negDaughterTrack.tpcNSigmaPi()) <= nSigmaTPCPion &&
1293-
ctauLambda < v0settingctauLambda &&
1294-
std::abs(v0.rapidity(1)) <= v0settingRapidity &&
1295-
std::abs(massK0s - pdgmassK0s) > v0settingMassRejectionLambda) {
1304+
ctauLambda < v0setting_ctauLambda &&
1305+
std::abs(v0.rapidity(1)) <= v0setting_rapidity &&
1306+
std::abs(massK0s - pdgmassK0s) > v0setting_massrejectionLambda) {
12961307

12971308
rLambda.fill(HIST("hMassLambdaSelected"), massLambda);
12981309
rLambda.fill(HIST("hDCAV0DaughtersLambda"), v0.dcaV0daughters());
@@ -1315,13 +1326,13 @@ struct Lambdak0sflattenicity {
13151326
}
13161327

13171328
// Cut on dynamic columns for AntiLambda
1318-
if (v0.v0cosPA() >= v0settingCospaLambda &&
1319-
v0.v0radius() >= v0settingRadiusLambda &&
1329+
if (v0.v0cosPA() >= v0setting_cospaLambda &&
1330+
v0.v0radius() >= v0setting_radiusLambda &&
13201331
std::abs(posDaughterTrack.tpcNSigmaPi()) <= nSigmaTPCPion &&
13211332
std::abs(negDaughterTrack.tpcNSigmaPr()) <= nSigmaTPCProton &&
1322-
ctauAntiLambda < v0settingctauLambda &&
1323-
std::abs(v0.rapidity(2)) <= v0settingRapidity &&
1324-
std::abs(massK0s - pdgmassK0s) > v0settingMassRejectionLambda) {
1333+
ctauAntiLambda < v0setting_ctauLambda &&
1334+
std::abs(v0.rapidity(2)) <= v0setting_rapidity &&
1335+
std::abs(massK0s - pdgmassK0s) > v0setting_massrejectionLambda) {
13251336

13261337
rAntiLambda.fill(HIST("hMassAntiLambdaSelected"), massAntiLambda);
13271338
rAntiLambda.fill(HIST("hDCAV0DaughtersAntiLambda"),
@@ -1421,15 +1432,15 @@ struct Lambdak0sflattenicity {
14211432
auto v0mcParticle = v0.mcParticle();
14221433
// Cut on dynamic columns for K0s
14231434

1424-
if (v0mcParticle.pdgCode() == 310 && v0.v0cosPA() >= v0settingCospaK0s &&
1425-
v0.v0radius() >= v0settingRadiusK0s &&
1435+
if (v0mcParticle.pdgCode() == 310 && v0.v0cosPA() >= v0setting_cospaK0s &&
1436+
v0.v0radius() >= v0setting_radiusK0s &&
14261437
std::abs(posDaughterTrack.tpcNSigmaPi()) <= nSigmaTPCPion &&
14271438
std::abs(negDaughterTrack.tpcNSigmaPi()) <= nSigmaTPCPion &&
1428-
ctauK0s < v0settingctauK0s &&
1429-
std::abs(v0.rapidity(0)) <= v0settingRapidity &&
1430-
std::abs(massLambda - pdgmassLambda) > v0settingMassRejectionK0s &&
1439+
ctauK0s < v0setting_ctauK0s &&
1440+
std::abs(v0.rapidity(0)) <= v0setting_rapidity &&
1441+
std::abs(massLambda - pdgmassLambda) > v0setting_massrejectionK0s &&
14311442
std::abs(massAntiLambda - pdgmassLambda) >
1432-
v0settingMassRejectionK0s) {
1443+
v0setting_massrejectionK0s) {
14331444

14341445
rKzeroShort.fill(HIST("hMassK0sSelected"), massK0s);
14351446
rKzeroShort.fill(HIST("hDCAV0DaughtersK0s"), v0.dcaV0daughters());
@@ -1453,13 +1464,13 @@ struct Lambdak0sflattenicity {
14531464

14541465
// Cut on dynamic columns for Lambda
14551466
if (v0mcParticle.pdgCode() == 3122 &&
1456-
v0.v0cosPA() >= v0settingCospaLambda &&
1457-
v0.v0radius() >= v0settingRadiusLambda &&
1467+
v0.v0cosPA() >= v0setting_cospaLambda &&
1468+
v0.v0radius() >= v0setting_radiusLambda &&
14581469
std::abs(posDaughterTrack.tpcNSigmaPr()) <= nSigmaTPCProton &&
14591470
std::abs(negDaughterTrack.tpcNSigmaPi()) <= nSigmaTPCPion &&
1460-
ctauLambda < v0settingctauLambda &&
1461-
std::abs(v0.rapidity(1)) <= v0settingRapidity &&
1462-
std::abs(massK0s - pdgmassK0s) > v0settingMassRejectionLambda) {
1471+
ctauLambda < v0setting_ctauLambda &&
1472+
std::abs(v0.rapidity(1)) <= v0setting_rapidity &&
1473+
std::abs(massK0s - pdgmassK0s) > v0setting_massrejectionLambda) {
14631474

14641475
rLambda.fill(HIST("hMassLambdaSelected"), massLambda);
14651476
rLambda.fill(HIST("hDCAV0DaughtersLambda"), v0.dcaV0daughters());
@@ -1483,13 +1494,13 @@ struct Lambdak0sflattenicity {
14831494

14841495
// Cut on dynamic columns for AntiLambda
14851496
if (v0mcParticle.pdgCode() == -3122 &&
1486-
v0.v0cosPA() >= v0settingCospaLambda &&
1487-
v0.v0radius() >= v0settingRadiusLambda &&
1497+
v0.v0cosPA() >= v0setting_cospaLambda &&
1498+
v0.v0radius() >= v0setting_radiusLambda &&
14881499
std::abs(posDaughterTrack.tpcNSigmaPi()) <= nSigmaTPCPion &&
14891500
std::abs(negDaughterTrack.tpcNSigmaPr()) <= nSigmaTPCProton &&
1490-
ctauAntiLambda < v0settingctauLambda &&
1491-
std::abs(v0.rapidity(2)) <= v0settingRapidity &&
1492-
std::abs(massK0s - pdgmassK0s) > v0settingMassRejectionLambda) {
1501+
ctauAntiLambda < v0setting_ctauLambda &&
1502+
std::abs(v0.rapidity(2)) <= v0setting_rapidity &&
1503+
std::abs(massK0s - pdgmassK0s) > v0setting_massrejectionLambda) {
14931504

14941505
rAntiLambda.fill(HIST("hMassAntiLambdaSelected"), massAntiLambda);
14951506
rAntiLambda.fill(HIST("hDCAV0DaughtersAntiLambda"),

0 commit comments

Comments
 (0)