Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 12:54:06

0001 #ifndef METReco_GenMET_h
0002 #define METReco_GenMET_h
0003 
0004 /** \class GenMET
0005  *
0006  * \short MET made from Generator level HEPMC particles
0007  *
0008  * GenMET represents MET made from HEPMC particles
0009  * Provide energy contributions from different particles
0010  * in addition to generic MET parameters
0011  *
0012  * \author    R. Cavanaugh, UFL (inspiration taken from F. Ratnikov)
0013  *
0014  ************************************************************/
0015 
0016 #include "DataFormats/METReco/interface/SpecificGenMETData.h"
0017 #include "DataFormats/METReco/interface/MET.h"
0018 
0019 namespace reco {
0020   class GenMET : public MET {
0021   public:
0022     /* Constructors*/
0023     GenMET();
0024     GenMET(const SpecificGenMETData& gen_data_, double sumet_, const LorentzVector& fP4, const Point& fVertex)
0025         : MET(sumet_, fP4, fVertex), gen_data(gen_data_) {}
0026     /* Default destructor*/
0027     ~GenMET() override {}
0028 
0029     //Get Neutral EM Et Fraction
0030     double NeutralEMEtFraction() const { return gen_data.NeutralEMEtFraction; }
0031 
0032     //Get Neutral EM Et
0033     double NeutralEMEt() const { return gen_data.NeutralEMEtFraction * sumEt(); }
0034 
0035     //Get Charged EM Et Fraction
0036     double ChargedEMEtFraction() const { return gen_data.ChargedEMEtFraction; }
0037 
0038     //Get Charged EM Et
0039     double ChargedEMEt() const { return gen_data.ChargedEMEtFraction * sumEt(); }
0040 
0041     //Get Neutral Had Et Fraction
0042     double NeutralHadEtFraction() const { return gen_data.NeutralHadEtFraction; }
0043 
0044     //Get Neutral Had Et
0045     double NeutralHadEt() const { return gen_data.NeutralHadEtFraction * sumEt(); }
0046 
0047     //Get Charged Had Et Fraction
0048     double ChargedHadEtFraction() const { return gen_data.ChargedHadEtFraction; }
0049 
0050     //Get Charged Had Et
0051     double ChargedHadEt() const { return gen_data.ChargedHadEtFraction * sumEt(); }
0052 
0053     //Get Muon Et Fraction
0054     double MuonEtFraction() const { return gen_data.MuonEtFraction; }
0055 
0056     //Get Muon Et
0057     double MuonEt() const { return gen_data.MuonEtFraction * sumEt(); }
0058 
0059     //Get Invisible Et Fraction
0060     double InvisibleEtFraction() const { return gen_data.InvisibleEtFraction; }
0061 
0062     //Get Invisible Et
0063     double InvisibleEt() const { return gen_data.InvisibleEtFraction * sumEt(); }
0064 
0065     // Old Accessors (to be removed as soon as possible)
0066     /** Returns energy of electromagnetic particles*/
0067     double emEnergy() const { return gen_data.m_EmEnergy; };
0068     /** Returns energy of hadronic particles*/
0069     double hadEnergy() const { return gen_data.m_HadEnergy; };
0070     /** Returns invisible energy*/
0071     double invisibleEnergy() const { return gen_data.m_InvisibleEnergy; };
0072     /** Returns other energy (undecayed Sigmas etc.)*/
0073     double auxiliaryEnergy() const { return gen_data.m_AuxiliaryEnergy; };
0074     // block accessors
0075 
0076     // block accessors
0077   private:
0078     bool overlap(const Candidate&) const override;
0079     // Data members
0080     //Variables specific to to the GenMET class
0081     SpecificGenMETData gen_data;
0082   };
0083 }  // namespace reco
0084 #endif