Skip to content

Commit 54f8ade

Browse files
authored
Update hStrangeCorrelation.cxx
1 parent 63e664f commit 54f8ade

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

PWGLF/Tasks/Strangeness/hStrangeCorrelation.cxx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@ struct HStrangeCorrelation {
8484
Configurable<bool> doMCassociation{"doMCassociation", false, "fill everything only for MC associated"};
8585
Configurable<bool> doTriggPhysicalPrimary{"doTriggPhysicalPrimary", false, "require physical primary for trigger particles"};
8686
Configurable<bool> doAssocPhysicalPrimary{"doAssocPhysicalPrimary", false, "require physical primary for associated particles"};
87+
Configurable<bool> doAssocPhysicalPrimaryInGen{"doAssocPhysicalPrimaryInGen", false, "require physical primary for associated particles in Generated Partilces"};
8788
Configurable<bool> doLambdaPrimary{"doLambdaPrimary", false, "do primary selection for lambda"};
8889
Configurable<bool> doAutocorrelationRejection{"doAutocorrelationRejection", true, "reject pairs where trigger Id is the same as daughter particle Id"};
8990
Configurable<bool> doMixingQAandEventQA{"doMixingQAandEventQA", true, "if true, add EvnetQA and MixingQA hist to histos"};
@@ -1843,7 +1844,7 @@ struct HStrangeCorrelation {
18431844
}
18441845

18451846
for (auto const& mcParticle : mcParticles) {
1846-
if (!mcParticle.isPhysicalPrimary())
1847+
if (doAssocPhysicalPrimaryInGen && !mcParticle.isPhysicalPrimary())
18471848
continue;
18481849
static_for<0, 7>([&](auto i) {
18491850
constexpr int Index = i.value;
@@ -1881,7 +1882,7 @@ struct HStrangeCorrelation {
18811882

18821883
if (collisions.size() > 1) {
18831884
for (auto const& mcParticle : mcParticles) {
1884-
if (!mcParticle.isPhysicalPrimary())
1885+
if (doAssocPhysicalPrimaryInGen && !mcParticle.isPhysicalPrimary())
18851886
continue;
18861887
if (std::abs(mcParticle.y()) > ySel)
18871888
continue;
@@ -1936,7 +1937,7 @@ struct HStrangeCorrelation {
19361937
}
19371938

19381939
for (auto const& mcParticle : mcParticles) {
1939-
if (!mcParticle.isPhysicalPrimary()) {
1940+
if (doAssocPhysicalPrimaryInGen && !mcParticle.isPhysicalPrimary()) {
19401941
continue;
19411942
}
19421943
double geta = mcParticle.eta();

0 commit comments

Comments
 (0)