CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PFJet.h
Go to the documentation of this file.
1 #ifndef JetReco_PFJet_h
2 #define JetReco_PFJet_h
3 
19 
20 namespace reco {
21 class PFJet : public Jet {
22  public:
23 
26 
27  struct Specific {
28  Specific () :
31  mPhotonEnergy (0),
32  mElectronEnergy (0),
33  mMuonEnergy (0),
34  mHFHadronEnergy (0),
35  mHFEMEnergy (0),
36 
44 
45  mChargedEmEnergy (0),
46  mChargedMuEnergy (0),
47  mNeutralEmEnergy (0),
48 
51 
52  mHOEnergy (0)
53  {}
58  float mMuonEnergy;
60  float mHFEMEnergy;
61 
69 
70  //old (deprecated) data members
71  //kept only for backwards compatibility:
77 
78  float mHOEnergy;
79  };
80 
82  PFJet() {}
83 
85  PFJet(const LorentzVector& fP4, const Point& fVertex, const Specific& fSpecific,
86  const Jet::Constituents& fConstituents);
87 
88  PFJet(const LorentzVector& fP4, const Point& fVertex, const Specific& fSpecific);
89 
91  PFJet(const LorentzVector& fP4, const Specific& fSpecific,
92  const Jet::Constituents& fConstituents);
93 
94 
95  virtual ~PFJet() {};
96 
100  float chargedHadronEnergyFraction () const {return chargedHadronEnergy () / energy ();}
104  float neutralHadronEnergyFraction () const {return neutralHadronEnergy () / energy ();}
106  float photonEnergy () const {return m_specific.mPhotonEnergy;}
108  float photonEnergyFraction () const {return photonEnergy () / energy ();}
110  float electronEnergy () const {return m_specific.mElectronEnergy;}
112  float electronEnergyFraction () const {return electronEnergy () / energy ();}
114  float muonEnergy () const {return m_specific.mMuonEnergy;}
116  float muonEnergyFraction () const {return muonEnergy () / energy ();}
118  float HFHadronEnergy () const {return m_specific.mHFHadronEnergy;}
120  float HFHadronEnergyFraction () const {return HFHadronEnergy () / energy ();}
122  float HFEMEnergy () const {return m_specific.mHFEMEnergy;}
124  float HFEMEnergyFraction () const {return HFEMEnergy () / energy ();}
125 
140 
142  float chargedEmEnergy () const {return m_specific.mChargedEmEnergy;}
144  float chargedEmEnergyFraction () const {return chargedEmEnergy () / energy ();}
146  float chargedMuEnergy () const {return m_specific.mChargedMuEnergy;}
148  float chargedMuEnergyFraction () const {return chargedMuEnergy () / energy ();}
150  float neutralEmEnergy () const {return m_specific.mNeutralEmEnergy;}
152  float neutralEmEnergyFraction () const {return neutralEmEnergy () / energy ();}
153 
158 
160  float hoEnergy () const {return m_specific.mHOEnergy;}
162  float hoEnergyFraction () const {return hoEnergy () / energy ();}
163 
165  virtual reco::PFCandidatePtr getPFConstituent (unsigned fIndex) const;
166 
168  virtual std::vector <reco::PFCandidatePtr> getPFConstituents () const;
169 
174 
175  // block accessors
176 
177  const Specific& getSpecific () const {return m_specific;}
178 
180  virtual PFJet* clone () const;
181 
183  virtual std::string print () const;
184 
185 
186  private:
188  virtual bool overlap( const Candidate & ) const;
189 
190  //Variables specific to to the PFJet class
192 };
193 
194 // streamer
195  std::ostream& operator<<(std::ostream& out, const reco::PFJet& jet);
196 }
197 // temporary fix before include_checcker runs globally
198 #include "DataFormats/JetReco/interface/PFJetCollection.h" //INCLUDECHECKER:SKIP
199 #endif
float photonEnergy() const
photonEnergy
Definition: PFJet.h:106
int photonMultiplicity() const
photonMultiplicity
Definition: PFJet.h:131
float muonEnergy() const
muonEnergy
Definition: PFJet.h:114
virtual bool overlap(const Candidate &) const
Polymorphic overlap.
Definition: PFJet.cc:79
float chargedEmEnergy() const
chargedEmEnergy
Definition: PFJet.h:142
reco::PFCandidatePtr ConstituentTypePtr
Definition: PFJet.h:24
int mChargedMultiplicity
Definition: PFJet.h:75
float chargedHadronEnergyFraction() const
chargedHadronEnergyFraction
Definition: PFJet.h:100
Base class for all types of Jets.
Definition: Jet.h:20
math::XYZTLorentzVector LorentzVector
PFJet()
Definition: PFJet.h:82
std::vector< Constituent > Constituents
Definition: Jet.h:23
float HFEMEnergyFraction() const
HFEMEnergyFraction.
Definition: PFJet.h:124
int mPhotonMultiplicity
Definition: PFJet.h:64
float mNeutralHadronEnergy
Definition: PFJet.h:55
float mChargedMuEnergy
Definition: PFJet.h:73
float HFHadronEnergy() const
HFHadronEnergy.
Definition: PFJet.h:118
int chargedMultiplicity() const
chargedMultiplicity
Definition: PFJet.h:155
float photonEnergyFraction() const
photonEnergyFraction
Definition: PFJet.h:108
Jets made from PFObjects.
Definition: PFJet.h:21
float neutralEmEnergy() const
neutralEmEnergy
Definition: PFJet.h:150
virtual reco::PFCandidatePtr getPFConstituent(unsigned fIndex) const
get specific constituent
Definition: PFJet.cc:35
float mChargedHadronEnergy
Definition: PFJet.h:54
virtual ~PFJet()
Definition: PFJet.h:95
float electronEnergy() const
electronEnergy
Definition: PFJet.h:110
float mChargedEmEnergy
Definition: PFJet.h:72
float neutralEmEnergyFraction() const
neutralEmEnergyFraction
Definition: PFJet.h:152
virtual double energy() const
energy
std::ostream & operator<<(std::ostream &, BeamSpot beam)
Definition: BeamSpot.cc:71
float mElectronEnergy
Definition: PFJet.h:57
float HFEMEnergy() const
HFEMEnergy.
Definition: PFJet.h:122
int mChargedHadronMultiplicity
Definition: PFJet.h:62
virtual std::string print() const
Print object in details.
Definition: PFJet.cc:83
float mPhotonEnergy
Definition: PFJet.h:56
float mNeutralEmEnergy
Definition: PFJet.h:74
math::XYZPoint Point
int neutralHadronMultiplicity() const
neutralHadronMultiplicity
Definition: PFJet.h:129
float neutralHadronEnergyFraction() const
neutralHadronEnergyFraction
Definition: PFJet.h:104
virtual PFJet * clone() const
Polymorphic clone.
Definition: PFJet.cc:75
int neutralMultiplicity() const
neutralMultiplicity
Definition: PFJet.h:157
int mElectronMultiplicity
Definition: PFJet.h:65
tuple out
Definition: dbtoconf.py:99
int mNeutralHadronMultiplicity
Definition: PFJet.h:63
float chargedEmEnergyFraction() const
chargedEmEnergyFraction
Definition: PFJet.h:144
float hoEnergyFraction() const
hoEnergyFraction
Definition: PFJet.h:162
float HFHadronEnergyFraction() const
HFHadronEnergyFraction.
Definition: PFJet.h:120
int mNeutralMultiplicity
Definition: PFJet.h:76
float electronEnergyFraction() const
electronEnergyFraction
Definition: PFJet.h:112
float hoEnergy() const
hoEnergy
Definition: PFJet.h:160
int chargedHadronMultiplicity() const
chargedHadronMultiplicity
Definition: PFJet.h:127
int muonMultiplicity() const
muonMultiplicity
Definition: PFJet.h:135
int HFEMMultiplicity() const
HFEMMultiplicity.
Definition: PFJet.h:139
float mHFHadronEnergy
Definition: PFJet.h:59
reco::PFCandidateFwdPtr ConstituentTypeFwdPtr
Definition: PFJet.h:25
Specific m_specific
Definition: PFJet.h:191
virtual std::vector< reco::PFCandidatePtr > getPFConstituents() const
get all constituents
Definition: PFJet.cc:52
reco::TrackRefVector getTrackRefs() const
Definition: PFJet.cc:59
float neutralHadronEnergy() const
neutralHadronEnergy
Definition: PFJet.h:102
float chargedMuEnergyFraction() const
chargedMuEnergyFraction
Definition: PFJet.h:148
float chargedMuEnergy() const
chargedMuEnergy
Definition: PFJet.h:146
const Specific & getSpecific() const
Definition: PFJet.h:177
float muonEnergyFraction() const
muonEnergyFraction
Definition: PFJet.h:116
int mHFHadronMultiplicity
Definition: PFJet.h:67
int HFHadronMultiplicity() const
HFHadronMultiplicity.
Definition: PFJet.h:137
float chargedHadronEnergy() const
chargedHadronEnergy
Definition: PFJet.h:98
int electronMultiplicity() const
electronMultiplicity
Definition: PFJet.h:133