1 #ifndef DataFormats_L1Trigger_HGCalClusterT_h 2 #define DataFormats_L1Trigger_HGCalClusterT_h 15 #include "Math/Vector3D.h" 17 #include <unordered_map> 56 double cMipt = c->mipPt() *
fraction;
80 fraction = fraction_itr->second;
112 DetId id(id_constituent.first);
118 pt_em += id_constituent.second->pt() *
fraction;
124 pt_had += id_constituent.second->pt() *
fraction;
128 hOe = pt_had / pt_em;
167 bool operator<(const HGCalClusterT<C>&
cl)
const {
return mipPt() <
cl.mipPt(); }
169 bool operator<=(const HGCalClusterT<C>&
cl)
const {
return !(
cl > *
this); }
205 double cMipt = c->mipPt() *
fraction;
212 clusterCentre = clusterCentre * mipPt_ + constituentCentre * cMipt;
213 if ((mipPt_ + cMipt) > 0) {
214 clusterCentre /= (mipPt_ + cMipt);
218 if (clusterCentre.
z() != 0) {
219 centreProj_ =
GlobalPoint(clusterCentre / clusterCentre.
z());
void addConstituent(const edm::Ptr< C > &c, bool updateCentre=true, float fraction=1.)
double distance(const l1t::HGCalTriggerCell &tc) const
void sigmaRRTot(float sigmaRRTot)
const_iterator constituents_end() const
void sigmaEtaEtaMax(float sigmaEtaEtaMax)
double eta() const final
momentum pseudorapidity
void showerLength(int showerLength)
HGCalTriggerSubdetector subdet() const
get the subdetector
void firstLayer(int firstLayer)
float sigmaPhiPhiTot() const
T mag() const
The vector magnitude. Equivalent to sqrt(vec.mag2())
HGCalClusterT(const LorentzVector p4, int pt=0, int eta=0, int phi=0)
float sigmaEtaEtaMax() const
Global3DPoint GlobalPoint
constexpr uint32_t rawId() const
get the raw id
uint32_t subdetId() const
double pt() const final
transverse momentum
std::unordered_map< uint32_t, edm::Ptr< C > > constituents_
const GlobalPoint & centreProj() const
const GlobalPoint & position() const
std::unordered_map< uint32_t, edm::Ptr< C > >::const_iterator const_iterator
PtEtaPhiMLorentzVectorD PtEtaPhiMLorentzVector
Lorentz vector with cartesian internal representation.
void sigmaRRMax(float sigmaRRMax)
const_iterator constituents_begin() const
void removeConstituent(const edm::Ptr< C > &c, bool updateCentre=true)
T z() const
Cartesian z coordinate.
~HGCalClusterT() override
void updateP4AndPosition(const edm::Ptr< C > &c, bool updateCentre=true, float fraction=1.)
bool operator>(const HGCalClusterT< C > &cl) const
void sigmaPhiPhiMax(float sigmaPhiPhiMax)
std::unordered_map< uint32_t, double > constituentsFraction_
const GlobalPoint & centre() const
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
void sigmaZZ(float sigmaZZ)
const LorentzVector & p4() const final
four-momentum Lorentz vector
void sigmaPhiPhiTot(float sigmaPhiPhiTot)
float sigmaEtaEtaTot() const
HGCalClusterT(const edm::Ptr< C > &c, float fraction=1.)
int coreShowerLength() const
float sigmaRRMean() const
math::XYZTLorentzVector LorentzVector
Lorentz vector.
const GlobalPoint & position() const
void maxLayer(int maxLayer)
bool operator>=(const HGCalClusterT< C > &cl) const
float sigmaPhiPhiMax() const
void sigmaEtaEtaTot(float sigmaEtaEtaTot)
void sigmaRRMean(float sigmaRRMean)
double phi() const final
momentum azimuthal angle
void setValid(bool valid)
void setP4(const LorentzVector &p4) final
set 4-momentum
void coreShowerLength(int coreShowerLength)
double mass() const final
mass
const std::unordered_map< uint32_t, edm::Ptr< C > > & constituents() const