Skip to content

Commit 663b702

Browse files
lhusovaLucia Anna Tarasovicova
andauthored
[PWGLF] Change in hStrangeCorrelation (#11466)
Co-authored-by: Lucia Anna Tarasovicova <lucia.anna.husova@cern.ch>
1 parent 1184be4 commit 663b702

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

PWGLF/Tasks/Strangeness/hStrangeCorrelation.cxx

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -581,6 +581,13 @@ struct HStrangeCorrelation {
581581
hEfficiencyV0[0] = hEfficiencyK0Short;
582582
hEfficiencyV0[1] = hEfficiencyLambda;
583583
hEfficiencyV0[2] = hEfficiencyAntiLambda;
584+
585+
float etaWeight = 1;
586+
if (systCuts.doOnTheFlyFlattening) {
587+
float preWeight = 1 - std::abs(deltaeta) / 1.6;
588+
etaWeight = preWeight != 0 ? 1.0f / preWeight : 0.0f;
589+
}
590+
584591
static_for<0, 2>([&](auto i) {
585592
constexpr int Index = i.value;
586593
float efficiency = 1.0f;
@@ -595,6 +602,7 @@ struct HStrangeCorrelation {
595602
}
596603

597604
float weight = (applyEfficiencyCorrection || applyEfficiencyForTrigger) ? 1. / efficiency : 1.0f;
605+
weight = weight * etaWeight;
598606
if (TESTBIT(doCorrelation, Index) && (!applyEfficiencyCorrection || efficiency != 0) && (doPPAnalysis || (TESTBIT(selMap, Index) && TESTBIT(selMap, Index + 3)))) {
599607
if (assocCandidate.compatible(Index, systCuts.dEdxCompatibility) && (!doMCassociation || assocCandidate.mcTrue(Index)) && (!doAssocPhysicalPrimary || assocCandidate.mcPhysicalPrimary()) && !mixing && -massWindowConfigurations.maxBgNSigma < assocCandidate.invMassNSigma(Index) && assocCandidate.invMassNSigma(Index) < -massWindowConfigurations.minBgNSigma)
600608
histos.fill(HIST("sameEvent/LeftBg/") + HIST(kV0names[Index]), deltaphi, deltaeta, ptassoc, pttrigger, pvz, mult, weight);
@@ -703,6 +711,12 @@ struct HStrangeCorrelation {
703711
hEfficiencyCascade[2] = hEfficiencyOmegaMinus;
704712
hEfficiencyCascade[3] = hEfficiencyOmegaPlus;
705713

714+
float etaWeight = 1;
715+
if (systCuts.doOnTheFlyFlattening) {
716+
float preWeight = 1 - std::abs(deltaeta) / 1.6;
717+
etaWeight = preWeight != 0 ? 1.0f / preWeight : 0.0f;
718+
}
719+
706720
static_for<0, 3>([&](auto i) {
707721
constexpr int Index = i.value;
708722
float efficiency = 1.0f;
@@ -716,6 +730,7 @@ struct HStrangeCorrelation {
716730
efficiency = 1;
717731
}
718732
float weight = (applyEfficiencyCorrection || applyEfficiencyForTrigger) ? 1. / efficiency : 1.0f;
733+
weight = weight * etaWeight;
719734
if (TESTBIT(doCorrelation, Index + 3) && (!applyEfficiencyCorrection || efficiency != 0) && (doPPAnalysis || (TESTBIT(CascselMap, Index) && TESTBIT(CascselMap, Index + 4) && TESTBIT(CascselMap, Index + 8) && TESTBIT(CascselMap, Index + 12)))) {
720735
if (assocCandidate.compatible(Index, systCuts.dEdxCompatibility) && (!doMCassociation || assocCandidate.mcTrue(Index)) && (!doAssocPhysicalPrimary || assocCandidate.mcPhysicalPrimary()) && !mixing && -massWindowConfigurations.maxBgNSigma < assocCandidate.invMassNSigma(Index) && assocCandidate.invMassNSigma(Index) < -massWindowConfigurations.minBgNSigma)
721736
histos.fill(HIST("sameEvent/LeftBg/") + HIST(kCascadenames[Index]), deltaphi, deltaeta, ptassoc, pttrigger, pvz, mult, weight);

0 commit comments

Comments
 (0)