00001
00002
00003
00004
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef CondFormatsL1TObjects_L1MuGMTScales_h
00023 #define CondFormatsL1TObjects_L1MuGMTScales_h
00024
00025 #include <cmath>
00026 #include <iostream>
00027
00028 #include "CondFormats/L1TObjects/interface/L1MuScale.h"
00029
00030 #include "FWCore/MessageLogger/interface/MessageLogger.h"
00031
00032 class L1MuGMTScales {
00033 public:
00034
00036 L1MuGMTScales() {}
00037
00038 L1MuGMTScales( int nbitPackingReducedEta,
00039 int nbinsReducedEta,
00040 const std::vector<double>& scaleReducedEtaDT,
00041 const std::vector<double>& scaleReducedEtaBrlRPC,
00042 const std::vector<double>& scaleReducedEtaCSC,
00043 const std::vector<double>& scaleReducedEtaFwdRPC,
00044
00045 int nbitPackingDeltaEta,
00046 bool signedPackingDeltaEta,
00047 int nbinsDeltaEta,
00048 float minDeltaEta,
00049 float maxDeltaEta,
00050 int offsetDeltaEta,
00051
00052 int nbitPackingDeltaPhi,
00053 bool signedPackingDeltaPhi,
00054 int nbinsDeltaPhi,
00055 float minDeltaPhi,
00056 float maxDeltaPhi,
00057 int offsetDeltaPhi,
00058
00059 int nbitPackingOvlEtaDT,
00060 int nbinsOvlEtaDT,
00061 float minOvlEtaDT,
00062 float maxOvlEtaDT,
00063
00064 int nbitPackingOvlEtaCSC,
00065 int nbinsOvlEtaCSC,
00066 float minOvlEtaCSC,
00067 float maxOvlEtaCSC,
00068
00069 const std::vector<double>& scaleOvlEtaRPC,
00070 int nbitPackingOvlEtaBrlRPC,
00071 int nbinsOvlEtaBrlRPC,
00072 int nbitPackingOvlEtaFwdRPC,
00073 int nbinsOvlEtaFwdRPC
00074
00075 ) {
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091 m_ReducedEtaScale[0] = L1MuSymmetricBinnedScale( nbitPackingReducedEta,
00092 nbinsReducedEta,
00093 scaleReducedEtaDT ) ;
00094 m_ReducedEtaScale[1] = L1MuSymmetricBinnedScale( nbitPackingReducedEta,
00095 nbinsReducedEta,
00096 scaleReducedEtaBrlRPC ) ;
00097 m_ReducedEtaScale[2] = L1MuSymmetricBinnedScale( nbitPackingReducedEta,
00098 nbinsReducedEta,
00099 scaleReducedEtaCSC ) ;
00100 m_ReducedEtaScale[3] = L1MuSymmetricBinnedScale( nbitPackingReducedEta,
00101 nbinsReducedEta,
00102 scaleReducedEtaFwdRPC ) ;
00103
00104
00105
00106
00107
00108
00109
00110
00111
00112
00113
00114
00115
00116
00117 for( int i = 0 ; i < 6 ; ++i )
00118 m_DeltaEtaScale[i] = L1MuBinnedScale( nbitPackingDeltaEta,
00119 signedPackingDeltaEta,
00120 nbinsDeltaEta,
00121 minDeltaEta,
00122 maxDeltaEta,
00123 offsetDeltaEta ) ;
00124
00125
00126
00127 m_DeltaPhiScale = L1MuBinnedScale( nbitPackingDeltaPhi,
00128 signedPackingDeltaPhi,
00129 nbinsDeltaPhi,
00130 minDeltaPhi,
00131 maxDeltaPhi,
00132 offsetDeltaPhi ) ;
00133
00134
00135
00136
00137
00138
00139
00140
00141
00142
00143
00144
00145
00146
00147
00148
00149
00150 m_OvlEtaScale[0] = L1MuSymmetricBinnedScale (nbitPackingOvlEtaDT,
00151 nbinsOvlEtaDT,
00152 minOvlEtaDT,
00153 maxOvlEtaDT);
00154
00155
00156
00157 m_OvlEtaScale[1] = L1MuSymmetricBinnedScale (nbitPackingOvlEtaBrlRPC,
00158 nbinsOvlEtaBrlRPC,
00159 scaleOvlEtaRPC) ;
00160 m_OvlEtaScale[2] = L1MuSymmetricBinnedScale (nbitPackingOvlEtaCSC,
00161 nbinsOvlEtaCSC,
00162 minOvlEtaCSC,
00163 maxOvlEtaCSC);
00164 m_OvlEtaScale[3] = L1MuSymmetricBinnedScale (nbitPackingOvlEtaFwdRPC,
00165 nbinsOvlEtaFwdRPC,
00166 scaleOvlEtaRPC) ;
00167
00168
00169
00170
00171
00172
00173
00174
00175
00176
00177
00178
00179
00180
00181
00182
00183
00184
00185
00186
00187
00188
00189
00190
00191 };
00192
00194 virtual ~L1MuGMTScales() {
00195
00196
00197
00198
00199
00200
00201
00202
00203
00204
00205 };
00206
00208 const L1MuScale* getReducedEtaScale(int isys) const {
00209 if (isys<0 || isys>3) edm::LogWarning("GMTScaleRangeViolation") << "Error in L1MuGMTScales:: isys out of range: " << isys;
00210 return &( m_ReducedEtaScale[isys] );
00211 };
00212
00214 const L1MuScale* getDeltaEtaScale(int idx) const {
00215 if (idx<0 || idx>5) edm::LogWarning("GMTScaleRangeViolation") << "Error in L1MuGMTScales:: isys out of range: " << idx;
00216 return &( m_DeltaEtaScale[idx] );
00217 };
00218
00220 const L1MuScale* getDeltaPhiScale() const { return &m_DeltaPhiScale; };
00221
00223 const L1MuScale* getOvlEtaScale(int isys) const {
00224 if (isys<0 || isys>3) edm::LogWarning("GMTScaleRangeViolation") << "Error in L1MuGMTScales:: isys out of range: " << isys;
00225 return &( m_OvlEtaScale[isys] );
00226 };
00227
00228
00229
00230
00231
00232
00233 private:
00234 L1MuSymmetricBinnedScale m_ReducedEtaScale[4];
00235 L1MuBinnedScale m_DeltaEtaScale[6];
00236 L1MuBinnedScale m_DeltaPhiScale;
00237 L1MuSymmetricBinnedScale m_OvlEtaScale[4];
00238
00239 };
00240
00241
00242 #endif