2 #include <Math/VectorUtil.h> 30 const double innerDR) {
33 for (reco::TrackCollection::const_iterator recTrack = recCollection->begin(); recTrack != recCollection->end();
39 double pt = recTrack->pt();
41 if (dR2 >= (0.01 * x * x))
43 if (dR2 < innerDR * innerDR)
46 TotalPt = TotalPt +
pt;
55 const double innerDR) {
56 double SClusterEta = cluster.
eta();
61 for (reco::TrackCollection::const_iterator recTrack = recCollection->begin(); recTrack != recCollection->end();
67 double pt = recTrack->pt();
68 double eta2 = recTrack->eta();
69 double dEta = fabs(eta2 - SClusterEta);
73 if (dR2 < innerDR * innerDR)
77 TotalPt = TotalPt +
pt;
80 double Tx = getTrackIso(cluster, x, threshold, innerDR);
81 double CTx = (Tx - TotalPt / 40.0 * x) * (1 / (1 - x / 40.));
double eta() const final
momentum pseudorapidity
double getBkgSubTrackIso(const reco::Photon clus, const double i, const double threshold, const double innerDR=0)
Return the background-subtracted tracker energy in a cone around the photon.
constexpr auto deltaR2(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
static TrackQuality qualityByName(const std::string &name)
TrackIsoCalculator(const edm::Event &iEvent, const edm::EventSetup &iSetup, const edm::Handle< reco::TrackCollection > trackLabel, const std::string trackQuality_)
double getTrackIso(const reco::Photon clus, const double i, const double threshold, const double innerDR=0)
Return the tracker energy in a cone around the photon.