CMS 3D CMS Logo

Lepjets_Event_Lep.h
Go to the documentation of this file.
1 //
2 //
3 // File: hitfit/Lepjets_Event_Lep.h
4 // Purpose: Represent a `lepton' in a Lepjets_Event class.
5 // Created: Jul, 2000, sss, based on run 1 mass analysis code.
6 //
7 // For each lepton, we store:
8 //
9 // - 4-momentum
10 // - type code
11 // - Vector_Resolution
12 //
13 // CMSSW File : interface/Lepjets_Event_Lep.h
14 // Original Author : Scott Stuart Snyder <snyder@bnl.gov> for D0
15 // Imported to CMSSW by Haryo Sumowidagdo <Suharyo.Sumowidagdo@cern.ch>
16 //
17 
39 #ifndef HITFIT_LEPJETS_EVENT_LEP_H
40 #define HITFIT_LEPJETS_EVENT_LEP_H
41 
44 #include <iosfwd>
45 
46 namespace hitfit {
47 
52  lepton_label = 1, // generic lepton
55  };
56 
65  //
66  // Purpose: Represent a `lepton' in a Lepjets_Event class.
67  //
68  {
69  public:
70  // Constructor.
80  Lepjets_Event_Lep(const Fourvec& p, int type, const Vector_Resolution& res);
81 
82  // Access the 4-momentum.
86  Fourvec& p();
87 
91  const Fourvec& p() const;
92 
93  // Access the type code.
97  int& type();
98 
102  int type() const;
103 
104  // Access the resolution.
108  const Vector_Resolution& res() const;
109 
114 
115  // Return resolutions for this object.
120  double p_sigma() const;
121 
125  double eta_sigma() const;
126 
130  double phi_sigma() const;
131 
132  // Smear this object.
133  // If SMEAR_DIR is false, smear the momentum only.
142  void smear(CLHEP::HepRandomEngine& engine, bool smear_dir = false);
143 
144  // Dump out this object.
155  std::ostream& dump(std::ostream& s, bool full = false) const;
156 
157  // Sort on pt.
164  bool operator<(const Lepjets_Event_Lep& x) const;
165 
166  private:
167  // The object state.
168 
173 
177  int _type;
178 
183  };
184 
185  // Print the object.
186  std::ostream& operator<<(std::ostream& s, const Lepjets_Event_Lep& ev);
187 
188 } // namespace hitfit
189 
190 #endif // not HITFIT_LEPJETS_EVENT_LEP_H
hitfit::Lepjets_Event_Lep::eta_sigma
double eta_sigma() const
Return the uncertainty in pseudorapidity .
Definition: Lepjets_Event_Lep.cc:126
hitfit
Definition: Base_Constrainer.h:43
hitfit::Fourvec
CLHEP::HepLorentzVector Fourvec
Typedef for a HepLorentzVector.
Definition: fourvec.h:55
hitfit::Vector_Resolution
Definition: Vector_Resolution.h:89
hitfit::Lepjets_Event_Lep::smear
void smear(CLHEP::HepRandomEngine &engine, bool smear_dir=false)
Smear this object.
Definition: Lepjets_Event_Lep.cc:148
hitfit::Lepjets_Event_Lep::phi_sigma
double phi_sigma() const
Return the uncertainty in azimuthal angle .
Definition: Lepjets_Event_Lep.cc:137
full
Definition: GenABIO.cc:168
hitfit::Lepjets_Event_Lep::operator<
bool operator<(const Lepjets_Event_Lep &x) const
Comparison operator for sorting purpose, based on $p_{T}$.
Definition: Lepjets_Event_Lep.cc:202
alignCSCRings.s
s
Definition: alignCSCRings.py:92
Vector_Resolution.h
Calculate and represent resolution for a vector of momentum , pseudorapidity , and azimuthal angle .
hitfit::operator<<
std::ostream & operator<<(std::ostream &s, const Constraint_Intermed &ci)
Output stream operator, print the content of this Constraint_Intermed to an output stream.
Definition: Constraint_Intermed.cc:268
hitfit::Lepjets_Event_Lep::Lepjets_Event_Lep
Lepjets_Event_Lep(const Fourvec &p, int type, const Vector_Resolution &res)
Constructor, create a new instance of Lepjets_Event_Lep.
Definition: Lepjets_Event_Lep.cc:38
type
type
Definition: SiPixelVCal_PayloadInspector.cc:37
hitfit::Lepjets_Event_Lep::p
Fourvec & p()
Return a reference to the four-momentum.
Definition: Lepjets_Event_Lep.cc:49
hitfit::Lepjets_Event_Lep::_p
Fourvec _p
Definition: Lepjets_Event_Lep.h:172
hitfit::Lepjets_Event_Lep::type
int & type()
Return a reference to the type code.
Definition: Lepjets_Event_Lep.cc:71
res
Definition: Electron.h:6
hitfit::Lepjets_Event_Lep::_type
int _type
Definition: Lepjets_Event_Lep.h:177
hitfit::electron_label
Definition: Lepjets_Event_Lep.h:53
hitfit::Lepton_Labels
Lepton_Labels
Definition: Lepjets_Event_Lep.h:51
hitfit::Lepjets_Event_Lep::res
const Vector_Resolution & res() const
Return a constant reference to the resolution.
Definition: Lepjets_Event_Lep.cc:93
ev
bool ev
Definition: Hydjet2Hadronizer.cc:95
hitfit::muon_label
Definition: Lepjets_Event_Lep.h:54
fourvec.h
Define three-vector and four-vector classes for the HitFit package, and supply a few additional opera...
hitfit::Lepjets_Event_Lep::p_sigma
double p_sigma() const
Return the uncertainty in momentum or ( or if the lepton is a tracking object).
Definition: Lepjets_Event_Lep.cc:115
hitfit::Lepjets_Event_Lep::dump
std::ostream & dump(std::ostream &s, bool full=false) const
Print the content of this object.
Definition: Lepjets_Event_Lep.cc:160
hitfit::Lepjets_Event_Lep::_res
Vector_Resolution _res
Definition: Lepjets_Event_Lep.h:182
hitfit::lepton_label
Definition: Lepjets_Event_Lep.h:52
hitfit::Lepjets_Event_Lep
Represent a lepton in an instance of Lepjets_Event class. This class hold the following information:
Definition: Lepjets_Event_Lep.h:64