Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 13:34:20

0001 #ifndef RecoEgamma_EgammaTools_HGCalClusterTools_h
0002 #define RecoEgamma_EgammaTools_HGCalClusterTools_h
0003 
0004 #include "DataFormats/CaloRecHit/interface/CaloClusterFwd.h"
0005 #include <vector>
0006 
0007 class HGCalClusterTools {
0008 public:
0009   enum class EType { ET, ENERGY };
0010 
0011   static float energyInCone(const float eta,
0012                             const float phi,
0013                             const std::vector<reco::CaloCluster>& layerClusters,
0014                             const float minDR,
0015                             const float maxDR,
0016                             const float minEt,
0017                             const float minEnergy,
0018                             const std::vector<DetId::Detector>& subDets,
0019                             const HGCalClusterTools::EType& eType = EType::ENERGY);
0020 
0021   static float hadEnergyInCone(const float eta,
0022                                const float phi,
0023                                const std::vector<reco::CaloCluster>& layerClusters,
0024                                const float minDR,
0025                                const float maxDR,
0026                                const float minEt,
0027                                const float minEnergy,
0028                                const HGCalClusterTools::EType& eType = EType::ENERGY) {
0029     return energyInCone(
0030         eta, phi, layerClusters, minDR, maxDR, minEt, minEnergy, {DetId::HGCalHSi, DetId::HGCalHSc}, eType);
0031   }
0032   static float emEnergyInCone(const float eta,
0033                               const float phi,
0034                               const std::vector<reco::CaloCluster>& layerClusters,
0035                               const float minDR,
0036                               const float maxDR,
0037                               const float minEt,
0038                               const float minEnergy,
0039                               const HGCalClusterTools::EType& eType = EType::ENERGY) {
0040     return energyInCone(eta, phi, layerClusters, minDR, maxDR, minEt, minEnergy, {DetId::HGCalEE}, eType);
0041   }
0042 };
0043 
0044 #endif