CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
MET.h
Go to the documentation of this file.
1 #ifndef METRECO_MET_H
2 #define METRECO_MET_H
3 
25 #include <cmath>
26 #include <vector>
27 #include <cstring>
28 #include "TMatrixD.h"
29 
30 namespace reco
31 {
32  class MET : public RecoCandidate
33  {
34  public:
35  //-----------------------------------------------------------------
36  //Define Constructors
37  MET();
38  MET( const LorentzVector& p4_, const Point& vtx_ );
39  MET( double sumet_, const LorentzVector& p4_, const Point& vtx_ );
40  MET( double sumet_, std::vector<CorrMETData> corr_,
41  const LorentzVector& p4_, const Point& vtx_ );
42  //-----------------------------------------------------------------
43  //explicit clone function
44  MET * clone() const;
45  //-----------------------------------------------------------------
46  //Define methods to extract elements related to MET
47  //scalar sum of transverse energy over all objects
48  double sumEt() const { return sumet; }
49  //MET Significance = MET / std::sqrt(SumET)
50  double mEtSig() const { return ( sumet ? (this->et() / std::sqrt(sumet)) : (0.0) ); }
51  //real MET significance
52  double significance() const;
53  //longitudinal component of the vector sum of energy over all object
54  //(useful for data quality monitoring)
55  double e_longitudinal() const {return elongit; }
56  //-----------------------------------------------------------------
57  //Define different methods for the corrections to individual MET elements
58  std::vector<double> dmEx() const ;
59  std::vector<double> dmEy() const ;
60  std::vector<double> dsumEt() const ;
61  std::vector<double> dSignificance() const ;
62  //Define method to extract the entire "block" of MET corrections
63  std::vector<CorrMETData> mEtCorr() const { return corr; }
64  //-----------------------------------------------------------------
65  void setSignificanceMatrix(const TMatrixD& matrix);
66  TMatrixD getSignificanceMatrix(void) const;
67  private:
68  virtual bool overlap( const Candidate & ) const;
69  double sumet;
70  double elongit;
71  // bookkeeping for the significance
72  double signif_dxx;
73  double signif_dyy;
74  double signif_dyx;
75  double signif_dxy;
76  std::vector<CorrMETData> corr;
77  };
78 }
79 
80 #endif // METRECO_MET_H
std::vector< double > dsumEt() const
Definition: MET.cc:134
double e_longitudinal() const
Definition: MET.h:55
double signif_dyx
Definition: MET.h:74
MET * clone() const
returns a clone of the Candidate object
Definition: MET.cc:77
double signif_dxy
Definition: MET.h:75
virtual double et() const
transverse energy
double signif_dxx
Definition: MET.h:72
std::vector< double > dmEx() const
Definition: MET.cc:102
MET()
Definition: MET.cc:15
double mEtSig() const
Definition: MET.h:50
double sumEt() const
Definition: MET.h:48
TMatrixD getSignificanceMatrix(void) const
Definition: MET.cc:149
Definition: MET.h:32
T sqrt(T t)
Definition: SSEVec.h:46
std::vector< CorrMETData > corr
Definition: MET.h:76
void setSignificanceMatrix(const TMatrixD &matrix)
Definition: MET.cc:185
std::vector< double > dmEy() const
Definition: MET.cc:118
double signif_dyy
Definition: MET.h:73
std::vector< CorrMETData > mEtCorr() const
Definition: MET.h:63
math::XYZTLorentzVector LorentzVector
Lorentz vector.
Definition: Candidate.h:38
virtual bool overlap(const Candidate &) const
check overlap with another candidate
Definition: MET.cc:178
std::vector< double > dSignificance() const
Definition: MET.cc:163
math::XYZPoint Point
point in the space
Definition: Candidate.h:42
double elongit
Definition: MET.h:70
double significance() const
Definition: MET.cc:83
double sumet
Definition: MET.h:69