6 RPCGeomServ::RPCGeomServ::RPCGeomServ(
const RPCDetId&
id)
7 :
_id(&id), _n(
""), _sn(
""), _cn(
""), _t(-99), _z(
true), _a(
true) {}
17 int layer =
_id->layer();
18 int sector =
_id->sector();
19 int subsector =
_id->subsector();
25 os << std::setw(2) << std::setfill(
'+') << ring << std::setfill(
' ') <<
"_";
29 (layer == 1) ? os <<
"in" : os <<
"out";
31 }
else if (station > 2) {
32 if (sector == 4 && station == 4) {
35 }
else if (subsector == 2) {
37 }
else if (subsector == 3) {
39 }
else if (subsector == 4) {
49 }
else if (station == 4 && sector != 9 && sector != 11 && sector != 4) {
58 os <<
"S" << std::setw(2) << std::setfill(
'0') << sector << std::setfill(
' ');
68 os << std::setw(2) << std::setfill(
'+') << station * region << std::setfill(
' ') <<
"_";
71 os <<
"_CH" << std::setw(2) << std::setfill(
'0') << this->segment();
94 int layer =
_id->layer();
95 int sector =
_id->sector();
96 int subsector =
_id->subsector();
103 os << std::setw(2) << std::setfill(
'+') << ring << std::setfill(
' ') <<
"_";
107 (layer == 1) ? os <<
"in" : os <<
"out";
109 }
else if (station > 2) {
110 if (sector == 4 && station == 4) {
111 if (subsector == 1) {
113 }
else if (subsector == 2) {
115 }
else if (subsector == 3) {
117 }
else if (subsector == 4) {
127 }
else if (station == 4 && sector != 9 && sector != 11 && sector != 4) {
136 os <<
"S" << std::setw(2) << std::setfill(
'0') << sector << std::setfill(
' ');
140 os << std::setw(2) << std::setfill(
'+') << station * region << std::setfill(
' ') <<
"_";
143 os <<
"_CH" << std::setw(2) << std::setfill(
'0') << this->segment();
156 int layer =
_id->layer();
157 int sector =
_id->sector();
158 int subsector =
_id->subsector();
160 std::stringstream os;
165 (layer == 1) ? os <<
"in" : os <<
"out";
168 if (sector == 4 && station == 4) {
169 if (subsector == 1) {
171 }
else if (subsector == 2) {
173 }
else if (subsector == 3) {
175 }
else if (subsector == 4) {
192 os <<
"Ri" << ring <<
" Su" << subsector;
201 std::vector<int> chipCh(4, 8);
203 if (
_id->region() == 0) {
208 if (station < 3 && _id->layer() == 1) {
209 chipCh.emplace_back(7);
210 chipCh.emplace_back(8);
211 }
else if (station == 1 || station == 3) {
212 chipCh.emplace_back(7);
213 chipCh.emplace_back(7);
214 }
else if (station == 2) {
215 chipCh.emplace_back(6);
216 chipCh.emplace_back(8);
217 }
else if (
_id->sector() == 4 ||
_id->sector() == 10 || (
_id->sector() == 8 &&
_id->subsector() != 1) ||
218 (
_id->sector() == 12 &&
_id->subsector() == 1)) {
219 chipCh.emplace_back(6);
220 chipCh.emplace_back(6);
222 chipCh.emplace_back(8);
223 chipCh.emplace_back(8);
232 if (
_id->region() == 0) {
233 if (this->inverted()) {
234 _t = 3 * (
_id->ring()) + (3 -
_id->roll()) - 1;
236 _t = 3 * (
_id->ring()) +
_id->roll() - 2;
239 _t =
_id->region() * (3 * (3 -
_id->ring()) +
_id->roll() + 7);
247 if (
_id->station() == 1) {
249 if (
_id->layer() == 1) {
250 if (
_id->roll() == 1)
257 if (
_id->roll() == 1)
265 if (
_id->station() == 2) {
267 if (
_id->layer() == 1) {
268 if (
_id->roll() == 1)
270 if (
_id->roll() == 3)
272 if (
_id->roll() == 2)
277 if (
_id->roll() == 2)
281 if (
_id->roll() == 1)
283 if (
_id->roll() == 3)
289 if (
_id->station() == 3) {
290 if (
_id->subsector() == 1) {
291 if (
_id->roll() == 1)
296 if (
_id->roll() == 1)
304 if (
_id->station() == 4) {
305 if (
_id->sector() == 4) {
306 if (
_id->subsector() == 2) {
308 if (
_id->roll() == 1)
314 if (
_id->subsector() == 3) {
316 if (
_id->roll() == 1)
322 if (
_id->subsector() == 1) {
324 if (
_id->roll() == 1)
330 if (
_id->subsector() == 4) {
332 if (
_id->roll() == 1)
343 if (
_id->subsector() == 1) {
344 if (
_id->roll() == 1)
349 if (
_id->roll() == 1)
365 (ring == 1 && station > 1) ? nsub = 3 : nsub = 6;
367 return (
_id->subsector() + nsub * (
_id->sector() - 1));
372 return !(this->zpositive());
376 if (
_id->region() == 0 && _t < -90) {
377 if (
_id->ring() < 0) {
380 if (
_id->ring() == 0) {
381 if (
_id->sector() == 1 ||
_id->sector() == 4 ||
_id->sector() == 5 ||
_id->sector() == 8 ||
_id->sector() == 9 ||
382 _id->sector() == 12) {
392 if (
_id->region() == 0 && _t < -90) {
393 if (
_id->ring() > 0) {
394 if (
_id->layer() == 2) {
397 }
else if (
_id->ring() < 0) {
398 if (
_id->layer() == 1) {
401 }
else if (
_id->ring() == 0) {
402 if ((
_id->sector() == 1 ||
_id->sector() == 4 ||
_id->sector() == 5 ||
_id->sector() == 8 ||
_id->sector() == 9 ||
403 _id->sector() == 12) &&
406 else if ((
_id->sector() == 2 ||
_id->sector() == 3 ||
_id->sector() == 6 ||
_id->sector() == 7 ||
407 _id->sector() == 10 ||
_id->sector() == 11) &&
virtual std::string chambername()
virtual int eta_partition()
std::vector< int > channelInChip()
virtual std::string name()
virtual bool aclockwise()
virtual std::string shortname()
const RPCRoll * roll(RPCDetId id) const
Return a roll given its id.