00001
00002
00003 #ifndef ETAPHI_BINNING_CLASS_H
00004 #define ETAPHI_BINNING_CLASS_H
00005
00006 #include "TLorentzVector.h"
00007 #include <iostream>
00008
00009
00010 class EtaPhiBinning {
00011
00012 public:
00013 EtaPhiBinning(){ };
00014 virtual ~EtaPhiBinning() {;};
00015
00016 virtual int bin(const TLorentzVector *m) const {
00017 if(m->Eta() > 0)
00018 return this->symmetricBin(m) + 11;
00019
00020 return 11 - this->symmetricBin(m);
00021 }
00022 virtual int symmetricBin(const TLorentzVector *m) const;
00023
00024 enum binregion{ binUNKNOWN=0, bin1BARRELLG=1, bin1BARRELSM=2, bin2BARREL=3, binFEET=4,
00025 binTRANSITION=5, binENDCAPLG=6, binENDCAPSM=7, binBEE=8, binFORWARDLG=9,
00026 binFORWARDSM=10};
00027
00028 private:
00029 int getCoarseNSector(double phi) const;
00030 int getSector(double phi) const;
00031 int getECSector(double phi) const;
00032
00033 };
00034
00035 #endif