File indexing completed on 2024-04-06 12:14:50
0001 #ifndef HcalTrigTowerGeometry_h
0002 #define HcalTrigTowerGeometry_h
0003
0004 #include "Geometry/CaloTopology/interface/HcalTopology.h"
0005 #include "DataFormats/DetId/interface/DetId.h"
0006 #include <vector>
0007 class HcalTrigTowerDetId;
0008 class HcalDetId;
0009 class HcalZDCDetId;
0010
0011 class HcalTrigTowerGeometry {
0012 public:
0013 HcalTrigTowerGeometry(const HcalTopology* topology);
0014
0015
0016 std::vector<HcalTrigTowerDetId> towerIds(const HcalDetId& cellId) const;
0017 std::vector<HcalTrigTowerDetId> towerIds_ZDC(const HcalZDCDetId& cellId) const;
0018 std::vector<HcalDetId> detIds(const HcalTrigTowerDetId&) const;
0019
0020 int firstHFTower(int version) const { return (version == 1) ? (30) : (29); }
0021
0022
0023 void towerEtaBounds(int ieta, int version, double& eta1, double& eta2) const;
0024
0025
0026 int nTowers(int version) const { return (version == 1) ? (41) : (32); }
0027
0028
0029 const HcalTopology& topology() const { return *theTopology; }
0030
0031
0032 bool useRCT() const { return useRCT_; }
0033 bool use1x1() const { return use1x1_; }
0034
0035 private:
0036
0037 int nPhiBins(int ieta, int version) const {
0038 int nPhiBinsHF = (18);
0039 return (abs(ieta) < firstHFTower(version)) ? 72 : nPhiBinsHF;
0040 }
0041
0042
0043
0044 int hfTowerEtaSize(int ieta) const;
0045
0046
0047 int firstHFRingInTower(int ietaTower) const;
0048
0049 private:
0050 const HcalTopology* theTopology;
0051
0052 bool useRCT_;
0053 bool use1x1_;
0054 bool use2017_;
0055 };
0056
0057 #endif