Skip to content

Commit 089bed5

Browse files
committed
PWGHF:added isolation cut based on track and apply the cuts on E/p
1 parent 87b0365 commit 089bed5

File tree

1 file changed

+39
-1
lines changed

1 file changed

+39
-1
lines changed

PWGHF/HFL/Tasks/taskElectronWeakBoson.cxx

Lines changed: 39 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,12 @@ struct HfTaskElectronWeakBoson {
6565
Configurable<float> m02Min{"m02Min", 0.1, "Minimum M02"};
6666
Configurable<float> m02Max{"m02Max", 0.9, "Maximum M02"};
6767
Configurable<float> rMatchMax{"rMatchMax", 0.05, "cluster - track matching cut"};
68+
Configurable<float> eopMin{"eopMin", 0.9, "Minimum eop"};
69+
Configurable<float> eopMax{"eopMax", 1.3, "Maximum eop"};
6870

6971
Configurable<float> rIsolation{"rIsolation", 0.3, "cone radius for isolation cut"};
7072
Configurable<float> energyIsolationMax{"energyIsolationMax", 0.1, "isolation cut on energy"};
73+
Configurable<int> trackIsolationMax{"trackIsolationMax", 3, "Maximum number of tracks in isolation cone"};
7174

7275
using SelectedClusters = o2::aod::EMCALClusters;
7376
// PbPb
@@ -114,6 +117,7 @@ struct HfTaskElectronWeakBoson {
114117
const AxisSpec axisITSNCls{20, 0.0, 20, "counts"};
115118
const AxisSpec axisEMCtime{200, -100.0, 100, "EMC time"};
116119
const AxisSpec axisIsoEnergy{100, 0, 1, "Isolation energy(GeV/C)"};
120+
const AxisSpec axisIsoTrack{20, -0.5, 19.5, "Isolation Track"};
117121

118122
// create registrygrams
119123
registry.add("hZvtx", "Z vertex", kTH1F, {axisZvtx});
@@ -138,6 +142,7 @@ struct HfTaskElectronWeakBoson {
138142
registry.add("hEopNsigTPC", "Eop vs. Nsigma", kTH2F, {{axisNsigma}, {axisEop}});
139143
registry.add("hEMCtime", "EMC timing", kTH1F, {axisEMCtime});
140144
registry.add("hIsolationEnergy", "Isolation Energy", kTH2F, {{axisE}, {axisIsoEnergy}});
145+
registry.add("hIsolationTrack", "Isolation Track", kTH2F, {{axisE}, {axisIsoTrack}});
141146
}
142147
bool isIsolatedCluster(const o2::aod::EMCALCluster& cluster,
143148
const SelectedClusters& clusters)
@@ -172,6 +177,33 @@ struct HfTaskElectronWeakBoson {
172177

173178
return (isoEnergy < energyIsolationMax);
174179
}
180+
bool isIsolatedTrack(double etaEle,
181+
double phiEle,
182+
float ptEle,
183+
TrackEle const& tracks)
184+
{
185+
int trackCount = 0;
186+
187+
for (const auto& track : tracks) {
188+
// skip the reference track
189+
if (std::abs(track.pt() - ptEle) < 1e-4)
190+
continue;
191+
192+
double dEta = track.eta() - etaEle;
193+
double dPhi = track.phi() - phiEle;
194+
dPhi = RecoDecay::constrainAngle(dPhi, -o2::constants::math::PI);
195+
196+
double deltaR = std::sqrt(dEta * dEta + dPhi * dPhi);
197+
198+
if (deltaR < rIsolation) {
199+
trackCount++;
200+
}
201+
}
202+
203+
registry.fill(HIST("hIsolationTrack"), ptEle, trackCount);
204+
205+
return (trackCount <= trackIsolationMax);
206+
}
175207

176208
void process(soa::Filtered<aod::Collisions>::iterator const& collision,
177209
SelectedClusters const& emcClusters,
@@ -226,6 +258,8 @@ struct HfTaskElectronWeakBoson {
226258
double rMin = 999.9;
227259
double dPhiMin = 999.9;
228260
double dEtaMin = 999.9;
261+
bool isIsolated = false;
262+
bool isIsolatedTr = false;
229263

230264
if (tracksofcluster.size()) {
231265
int nMatch = 0;
@@ -266,7 +300,6 @@ struct HfTaskElectronWeakBoson {
266300
continue;
267301

268302
const auto& cluster = match.emcalcluster_as<SelectedClusters>();
269-
bool isIsolated = isIsolatedCluster(cluster, emcClusters);
270303

271304
double eop = energyEmc / match.track_as<TrackEle>().p();
272305
// LOG(info) << "E/p" << eop;
@@ -276,6 +309,11 @@ struct HfTaskElectronWeakBoson {
276309
if (match.track_as<TrackEle>().tpcNSigmaEl() > nsigTpcMin && match.track_as<TrackEle>().tpcNSigmaEl() < nsigTpcMax) {
277310
registry.fill(HIST("hEop"), match.track_as<TrackEle>().pt(), eop);
278311

312+
if (eop > eopMin && eop < eopMax) {
313+
isIsolated = isIsolatedCluster(cluster, emcClusters);
314+
isIsolatedTr = isIsolatedTrack(track.phi(), track.eta(), track.pt(), tracks);
315+
}
316+
279317
if (isIsolated) {
280318
registry.fill(HIST("hEopIsolation"), match.track_as<TrackEle>().pt(), eop);
281319
}

0 commit comments

Comments
 (0)