Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:14:36

0001 #ifndef EcalTestBeam_EcalTBCrystalMap_h
0002 #define EcalTestBeam_EcalTBCrystalMap_h
0003 
0004 /*
0005  *
0006  *
0007  */
0008 
0009 #include <map>
0010 #include <iostream>
0011 #include <fstream>
0012 #include <string>
0013 
0014 #include "FWCore/Utilities/interface/Exception.h"
0015 #include "FWCore/MessageLogger/interface/MessageLogger.h"
0016 
0017 class EcalTBCrystalMap {
0018 public:
0019   typedef std::map<std::pair<double, double>, int> CrystalTBIndexMap;
0020 
0021   EcalTBCrystalMap(std::string const& MapFileName);
0022   ~EcalTBCrystalMap();
0023 
0024   int CrystalIndex(double thisEta, double thisPhi);
0025   void findCrystalAngles(const int thisCrysIndex, double& thisEta, double& thisPhi);
0026 
0027   static const int NCRYSTAL = 1700;
0028 
0029 private:
0030   double crysEta, crysPhi;
0031   int crysIndex;
0032 
0033   CrystalTBIndexMap map_;
0034 };
0035 
0036 #endif