CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Lepjets_Event_Lep.h
Go to the documentation of this file.
1 //
2 // $Id: Lepjets_Event_Lep.h,v 1.1 2011/05/26 09:46:53 mseidel Exp $
3 //
4 // File: hitfit/Lepjets_Event_Lep.h
5 // Purpose: Represent a `lepton' in a Lepjets_Event class.
6 // Created: Jul, 2000, sss, based on run 1 mass analysis code.
7 //
8 // For each lepton, we store:
9 //
10 // - 4-momentum
11 // - type code
12 // - Vector_Resolution
13 //
14 // CMSSW File : interface/Lepjets_Event_Lep.h
15 // Original Author : Scott Stuart Snyder <snyder@bnl.gov> for D0
16 // Imported to CMSSW by Haryo Sumowidagdo <Suharyo.Sumowidagdo@cern.ch>
17 //
18 
19 
41 #ifndef HITFIT_LEPJETS_EVENT_LEP_H
42 #define HITFIT_LEPJETS_EVENT_LEP_H
43 
44 
47 #include <iosfwd>
48 
49 
50 namespace hitfit {
51 
56  lepton_label = 1, // generic lepton
59 };
60 
61 
70 //
71 // Purpose: Represent a `lepton' in a Lepjets_Event class.
72 //
73 {
74 public:
75  // Constructor.
85  Lepjets_Event_Lep (const Fourvec& p,
86  int type,
87  const Vector_Resolution& res);
88 
89  // Access the 4-momentum.
93  Fourvec& p ();
94 
98  const Fourvec& p () const;
99 
100  // Access the type code.
104  int& type ();
105 
109  int type () const;
110 
111  // Access the resolution.
115  const Vector_Resolution& res () const;
116 
121 
122  // Return resolutions for this object.
127  double p_sigma () const;
128 
132  double eta_sigma () const;
133 
137  double phi_sigma () const;
138 
139  // Smear this object.
140  // If SMEAR_DIR is false, smear the momentum only.
149  void smear (CLHEP::HepRandomEngine& engine, bool smear_dir = false);
150 
151  // Dump out this object.
162  std::ostream& dump (std::ostream& s, bool full = false) const;
163 
164  // Sort on pt.
171  bool operator< (const Lepjets_Event_Lep& x) const;
172 
173 
174 private:
175  // The object state.
176 
181 
185  int _type;
186 
191 };
192 
193 
194 // Print the object.
195 std::ostream& operator<< (std::ostream& s, const Lepjets_Event_Lep& ev);
196 
197 
198 } // namespace hitfit
199 
200 
201 #endif // not HITFIT_LEPJETS_EVENT_LEP_H
202 
type
Definition: HCALResponse.h:22
std::ostream & dump(std::ostream &s, bool full=false) const
Print the content of this object.
Calculate and represent resolution for a vector of momentum , pseudorapidity , and azimuthal angle ...
Represent a lepton in an instance of Lepjets_Event class. This class hold the following information: ...
Define three-vector and four-vector classes for the HitFit package, and supply a few additional opera...
void smear(CLHEP::HepRandomEngine &engine, bool smear_dir=false)
Smear this object.
Lepjets_Event_Lep(const Fourvec &p, int type, const Vector_Resolution &res)
Constructor, create a new instance of Lepjets_Event_Lep.
double eta_sigma() const
Return the uncertainty in pseudorapidity .
int & type()
Return a reference to the type code.
const Vector_Resolution & res() const
Return a constant reference to the resolution.
double phi_sigma() const
Return the uncertainty in azimuthal angle .
double p_sigma() const
Return the uncertainty in momentum or ( or if the lepton is a tracking object).
Definition: GenABIO.cc:193
CLHEP::HepLorentzVector Fourvec
Typedef for a HepLorentzVector.
Definition: fourvec.h:58
Fourvec & p()
Return a reference to the four-momentum.
bool operator<(const Lepjets_Event_Lep &x) const
Comparison operator for sorting purpose, based on $p_{T}$.
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: DDAxes.h:10
Calculate and represent resolution for a vector of , pseudorapidity , and azimuthal angle ...