36 for (
int ieta = LowerEta; ieta != UpperEta + 1; ++ieta) {
37 if (ieta == 0 && ecap ==
'E')
continue;
39 (ieta < 0) ? eta_s +=
"C" : ((ieta > 0) ? eta_s +=
"A" : eta_s +=
"B");
46 for (
int iphi = 1; iphi <= 16; iphi++) {
51 if (ecap ==
'B' && (iphi == 11 || iphi == 15)) {
52 h->Fill(eta_s,
"I," + phi_s +
",R", 0);
53 h->Fill(eta_s,
"I," + phi_s +
",M", 0);
54 h->Fill(eta_s,
"M," + phi_s, 0);
55 h->Fill(eta_s,
"O," + phi_s, 0);
57 h->Fill(eta_s,
"I," + phi_s, 0);
58 h->Fill(eta_s,
"M," + phi_s, 0);
59 h->Fill(eta_s,
"O," + phi_s, 0);
60 if (iphi % 2 == 0 && ecap ==
'B')
61 h->Fill(eta_s,
"E," + phi_s, 0);
63 h->Fill(eta_s,
"E," + phi_s, 0);
67 h->LabelsDeflate(
"X");
68 h->LabelsDeflate(
"Y");
69 h->LabelsOption(
"a",
"Y");
72 return StatusCode::SUCCESS;
79 if (xAxis.substr(0, 2) ==
"BO" || xAxis.substr(0, 2) ==
"BI") {
82 }
else if (xAxis.substr(0, 2) ==
"BM" || xAxis.substr(0, 2) ==
"EO") {
85 }
else if (xAxis.substr(0, 2) ==
"EM" || xAxis.substr(0, 2) ==
"EI") {
95 for (
int ieta = LowerEta; ieta != UpperEta + 1; ++ieta) {
96 if (xAxis.substr(2, 1) ==
"A" && ieta < 0)
continue;
97 if (xAxis.substr(2, 1) ==
"C" && ieta == 0)
break;
98 if (ieta == 0 && xAxis.substr(0, 2) ==
"BO")
103 eta_s = xAxis.substr(0, 3);
105 h->Fill(eta_s, 1, 0);
108 bool barrelExtra = (xAxis ==
"BEA" || xAxis ==
"BEC");
111 for (
int iphi = 1; iphi <= 16; iphi++) {
118 if (xAxis.substr(0, 2) ==
"BI" && (iphi == 11 || iphi == 15)) {
119 h->Fill(eta_s, phi_s +
",1,R", 0);
120 h->Fill(eta_s, phi_s +
",2,R", 0);
121 h->Fill(eta_s, phi_s +
",1,M", 0);
122 h->Fill(eta_s, phi_s +
",2,M", 0);
124 h->Fill(eta_s, phi_s +
",1", 0);
125 h->Fill(eta_s, phi_s +
",2", 0);
127 }
else if (iphi % 2 == 0)
128 h->Fill(eta_s, phi_s +
",1", 0);
131 h->LabelsDeflate(
"X");
132 h->LabelsDeflate(
"Y");
135 return StatusCode::SUCCESS;
140 TString phiString =
"";
145 TString phiString_ml1 = phiString +
",1";
146 TString phiString_ml2 = phiString +
",2";
148 TString phiString_ml1_BIR = phiString +
",1,R";
149 TString phiString_ml2_BIR = phiString +
",2,R";
150 nHits_In->Fill(
"EIC5", phiString_ml1_BIR, 0.);
151 nHits_In->Fill(
"EIC5", phiString_ml2_BIR, 0.);
152 TString phiString_ml1_BIM = phiString +
",1,M";
153 TString phiString_ml2_BIM = phiString +
",2,M";
154 nHits_In->Fill(
"EIC5", phiString_ml1_BIM, 0.);
155 nHits_In->Fill(
"EIC5", phiString_ml2_BIM, 0.);
157 nHits_In->Fill(
"EIC5", phiString_ml1, 0.);
158 nHits_In->Fill(
"EIC5", phiString_ml2, 0.);
160 nHits_Mid->Fill(
"EMC5", phiString_ml1, 0.);
161 nHits_Mid->Fill(
"EMC5", phiString_ml2, 0.);
162 nHits_Out->Fill(
"EOC6", phiString_ml1, 0.);
163 nHits_Out->Fill(
"EOC6", phiString_ml2, 0.);
171 nHits_In->Fill(etaIn,
"01,1", 0);
172 nHits_Mid->Fill(etaMid,
"01,1", 0);
174 nHits_Out->Fill(etaOut,
"01,1", 0);
176 nHits_In->Fill(
"",
"01,1", 0);
177 nHits_Mid->Fill(
"",
"01,1", 0);
178 nHits_Out->Fill(
"",
"01,1", 0);
188 nHits_In->Fill(etaIn,
"01,1", 0);
189 }
else if (
iEta < 0) {
191 nHits_In->Fill(etaIn,
"01,1", 0);
193 nHits_In->Fill(
" ",
"01,1", 0);
204 }
else if (
iEta == 0) {
206 }
else if (
iEta < 9) {
212 nHits_In->Fill(etaIn,
"01,1", 0);
213 nHits_Mid->Fill(etaMid,
"01,1", 0);
214 nHits_Out->Fill(etaOut,
"01,1", 0);
216 nHits_In->Fill(
" ",
"01,1", 0);
217 nHits_Mid->Fill(
" ",
"01,1", 0);
218 nHits_Out->Fill(
" ",
"01,1", 0);
227 nHits_In->Fill(etaIn,
"01,1", 0);
228 }
else if (
iEta < 5) {
230 nHits_In->Fill(etaIn,
"01,1", 0);
232 nHits_In->Fill(
" ",
"01,1", 0);
240 nHits_In->Fill(etaIn,
"01,1", 0);
241 nHits_Mid->Fill(etaMid,
"01,1", 0);
243 nHits_Out->Fill(etaOut,
"01,1", 0);
246 nHits_In->LabelsDeflate(
"X");
247 nHits_In->LabelsDeflate(
"Y");
248 nHits_In->LabelsOption(
"v",
"x");
250 nHits_Mid->LabelsDeflate(
"X");
251 nHits_Mid->LabelsDeflate(
"Y");
252 nHits_Mid->LabelsOption(
"v",
"x");
254 nHits_Out->LabelsDeflate(
"X");
255 nHits_Out->LabelsDeflate(
"Y");
256 nHits_Out->LabelsOption(
"v",
"x");
259 return StatusCode::SUCCESS;
265 if (hardware_name.substr(0, 4) ==
"BMS4" || hardware_name.substr(0, 4) ==
"BMS6") {
268 if (hardware_name.substr(0, 3) ==
"BIR" &&
numLayers <= 3) {
269 if (hardware_name.substr(5, 2) ==
"11" || hardware_name.substr(5, 2) ==
"15") {
270 if (hardware_name.substr(3, 1) ==
"1") tubeNum = tubePos + 6 +
numLayers * 30;
271 if (hardware_name.substr(3, 1) ==
"2") tubeNum = tubePos +
numLayers * 30;
272 if (hardware_name.substr(3, 1) ==
"4") tubeNum = tubePos + 3 +
numLayers * 30;
273 if (hardware_name.substr(3, 1) ==
"5") tubeNum = tubePos +
numLayers * 24;
276 if (hardware_name.substr(0, 3) ==
"BIR" && hardware_name.substr(3, 1) ==
"3") tubeNum = tubePos +
numLayers * 36;
277 if (hardware_name ==
"EEL1A05" || hardware_name ==
"EEL1C05")
283 if (hardware_name ==
"EEL1A05" || hardware_name ==
"EEL1C05") numTubes = 48;
288 if (hardware_name ==
"EEL1A05" || hardware_name ==
"EEL1C05")
numLayers = 3;
297 std::vector<Identifier>::const_iterator idfirst =
m_idHelperSvc->mdtIdHelper().module_begin();
298 std::vector<Identifier>::const_iterator idlast =
m_idHelperSvc->mdtIdHelper().module_end();
303 for (std::vector<Identifier>::const_iterator
i = idfirst;
i != idlast; ++
i) {
305 int gethash_code =
m_idHelperSvc->mdtIdHelper().get_hash(Id, Idhash, &mdtModuleContext);
309 std::string extid =
m_idHelperSvc->mdtIdHelper().show_to_string(Id);
311 if (gethash_code == 0) {
322 int TotmezzTubes = 8;
324 int Imezz = (
int)((
m_idHelperSvc->mdtIdHelper().tube(digcoll_id) - 1) / TotmezzTubes) +
335 if (hardware_name.substr(0, 4) ==
"BIS8") {
337 }
else if (hardware_name.substr(0, 4) ==
"BIR5") {
340 }
else if (hardware_name.substr(0, 4) ==
"BIR2" || hardware_name.substr(0, 4) ==
"BIR4") {
343 }
else if (hardware_name.substr(0, 4) ==
"BIR3") {
345 }
else if (hardware_name.substr(0, 4) ==
"BIR1") {
348 }
else if (hardware_name.substr(0, 4) ==
"BMS4" || hardware_name.substr(0, 4) ==
"BMS6") {
351 }
else if (hardware_name ==
"EEL1A05" || hardware_name ==
"EEL1C05") {
353 }
else if (hardware_name.substr(0, 3) ==
"BME") {
356 int numtubes =
m_idHelperSvc->mdtIdHelper().tubeMax(digcoll_id);
357 int numlayers =
m_idHelperSvc->mdtIdHelper().tubeLayerMax(digcoll_id);
358 int numML =
m_idHelperSvc->mdtIdHelper().numberOfMultilayers(digcoll_id);
359 tubeMax = numtubes * numlayers * numML;
366 if (
i ==
A)
return true;
381 bool filterresult(
true);
384 for (; filterresult && (ifilter != filterend); ++ifilter) { filterresult = (filterresult && (*ifilter)->accept()); }
403 if (!
chamber)
return StatusCode::FAILURE;
405 return StatusCode::SUCCESS;
409 if (region == 0 || region == 1) {
413 if (
phi < 11 && !isBIM)
414 return 18 * (
eta - 1) +
phi;
415 else if ((
phi == 10 && isBIM) || (
phi < 15 && !isBIM))
416 return 18 * (
eta - 1) +
phi + 1;
418 return 18 * (
eta - 1) +
phi + 2;
422 return 106 + (
phi / 2);
424 return 114 + (
phi / 2);
427 else if (
layer == 1) {
432 return 16 * (
eta - 1) +
phi - 1;
434 return 16 * (
eta - 1) +
phi;
436 }
else if (
layer == 2 && region == 0) {
437 if (
eta == 0 &&
phi == 11)
439 else if (
eta == 0 &&
phi == 13)
442 return 16 * (
eta - 1) +
phi + 2;
443 else if (
eta == 7 &&
phi == 11)
445 else if (
eta == 7 &&
phi == 13)
447 else if (
eta == 8 &&
phi == 11)
449 else if (
eta == 8 &&
phi == 13)
451 }
else if (
layer == 3 && region == 0) {
452 return 102 + 8 * (
eta - 1) + (
phi - 1) / 2;
453 }
else if (
layer == 2 && region == 1) {
455 return 16 * (
eta - 1) +
phi;
456 else if (
eta == 7 &&
phi == 11)
458 else if (
eta == 7 &&
phi == 13)
460 else if (
eta == 8 &&
phi == 11)
462 else if (
eta == 8 &&
phi == 13)
464 }
else if (
layer == 3 && region == 1) {
465 return 100 + 8 * (
eta - 1) + (
phi - 1) / 2;
475 return 16 * (
eta - 1) +
phi - run3_offset;
477 return 32 +
phi / 2 - run3_offset;
479 return 40 +
phi / 2 - run3_offset;
481 return 48 +
phi / 8 - run3_offset;
483 }
else if (
layer == 1) {
484 return 16 * (
eta - 1) +
phi;
485 }
else if (
layer == 2) {
486 return 16 * (
eta - 1) +
phi;
487 }
else if (
layer == 3 && region == 2) {
488 if (
eta == 1 &&
phi == 2)
return 96;
489 if (
eta == 1 &&
phi == 4)
return 97;
490 if (
eta == 1 &&
phi == 10)
return 98;
491 if (
eta == 1 &&
phi == 12)
return 99;
492 if (
eta == 2 &&
phi == 2)
return 100;
493 if (
eta == 2 &&
phi == 10)
return 101;
494 if (
eta == 2 &&
phi == 12)
return 102;
495 }
else if (
layer == 3 && region == 3) {
497 return 80 + 16 *
eta +
phi;
499 return 79 + 16 *
eta +
phi;
507 if (region == 0 || region == 1) {
510 h->SetBins(834, 1, 2502, 122, 0, 122);
511 h->GetYaxis()->SetBinLabel(1,
"BI1");
512 h->GetYaxis()->SetBinLabel(19,
"BI2");
513 h->GetYaxis()->SetBinLabel(37,
"BI3");
514 h->GetYaxis()->SetBinLabel(55,
"BI4");
515 h->GetYaxis()->SetBinLabel(73,
"BI5");
516 h->GetYaxis()->SetBinLabel(91,
"BI6");
517 h->GetYaxis()->SetBinLabel(107,
"BI7");
518 h->GetYaxis()->SetBinLabel(115,
"BI8");
520 h->GetYaxis()->SetTickLength(0);
521 for (
int i = 0;
i < 6;
i++) {
522 TLine*
l =
new TLine(1, 18 *
i, 50, 18 *
i);
523 h->GetListOfFunctions()->Add(
l);
525 TLine*
l2 =
new TLine(1, 106, 50, 106);
526 h->GetListOfFunctions()->Add(
l2);
527 TLine* l3 =
new TLine(1, 114, 50, 114);
528 h->GetListOfFunctions()->Add(l3);
529 for (
int i = 1;
i < 122;
i++) {
530 if (
i < 90 && (
i % 18 == 11 ||
i % 18 == 16)) {
531 TLine*
l =
new TLine(1,
i, 10,
i);
532 h->GetListOfFunctions()->Add(
l);
534 TLine*
l =
new TLine(1,
i, 20,
i);
535 h->GetListOfFunctions()->Add(
l);
540 else if (
layer == 1) {
541 h->SetBins(834, 1, 2502, 95, 0, 95);
545 h->GetYaxis()->SetBinLabel(1,
"BM1");
546 h->GetYaxis()->SetBinLabel(17,
"BM2");
547 h->GetYaxis()->SetBinLabel(33,
"BM3");
548 h->GetYaxis()->SetBinLabel(49,
"BM4");
549 h->GetYaxis()->SetBinLabel(65,
"BM5");
550 h->GetYaxis()->SetBinLabel(81,
"BM6");
552 h->GetYaxis()->SetTickLength(0);
553 for (
int i = 1;
i < 95;
i++) {
554 TLine*
l =
new TLine(1,
i, 20,
i);
555 h->GetListOfFunctions()->Add(
l);
557 TLine*
l1 =
new TLine(1, 16, 50, 16);
558 h->GetListOfFunctions()->Add(
l1);
559 TLine*
l2 =
new TLine(1, 32, 50, 32);
560 h->GetListOfFunctions()->Add(
l2);
561 TLine* l3 =
new TLine(1, 48, 50, 48);
562 h->GetListOfFunctions()->Add(l3);
563 TLine* l4 =
new TLine(1, 64, 50, 64);
564 h->GetListOfFunctions()->Add(l4);
565 TLine* l5 =
new TLine(1, 80, 50, 80);
566 h->GetListOfFunctions()->Add(l5);
569 else if (
layer == 2 && region == 0) {
570 h->SetBins(834, 1, 2502, 118, 0, 118);
572 h->GetYaxis()->SetBinLabel(1,
"BO0");
573 h->GetYaxis()->SetBinLabel(4,
"BO1");
574 h->GetYaxis()->SetBinLabel(19,
"BO2");
575 h->GetYaxis()->SetBinLabel(35,
"BO3");
576 h->GetYaxis()->SetBinLabel(51,
"BO4");
577 h->GetYaxis()->SetBinLabel(67,
"BO5");
578 h->GetYaxis()->SetBinLabel(83,
"BO6");
579 h->GetYaxis()->SetBinLabel(99,
"BO7,8");
581 h->GetYaxis()->SetBinLabel(103,
"BE1");
582 h->GetYaxis()->SetBinLabel(111,
"BE2");
584 h->GetYaxis()->SetTickLength(0);
585 for (
int i = 1;
i < 118;
i++) {
586 TLine*
l =
new TLine(1,
i, 20,
i);
587 h->GetListOfFunctions()->Add(
l);
589 TLine*
l1 =
new TLine(1, 2, 50, 2);
590 h->GetListOfFunctions()->Add(
l1);
591 TLine*
l2 =
new TLine(1, 18, 50, 18);
592 h->GetListOfFunctions()->Add(
l2);
593 TLine* l3 =
new TLine(1, 34, 50, 34);
594 h->GetListOfFunctions()->Add(l3);
595 TLine* l4 =
new TLine(1, 50, 50, 50);
596 h->GetListOfFunctions()->Add(l4);
597 TLine* l5 =
new TLine(1, 66, 50, 66);
598 h->GetListOfFunctions()->Add(l5);
599 TLine* l6 =
new TLine(1, 82, 50, 82);
600 h->GetListOfFunctions()->Add(l6);
601 TLine* l7 =
new TLine(1, 98, 50, 98);
602 h->GetListOfFunctions()->Add(l7);
603 TLine* l8 =
new TLine(1, 100, 50, 100);
604 h->GetListOfFunctions()->Add(l8);
605 TLine* l9 =
new TLine(1, 102, 50, 102);
606 h->GetListOfFunctions()->Add(l9);
607 TLine* l10 =
new TLine(1, 110, 50, 110);
608 h->GetListOfFunctions()->Add(l10);
611 else if (
layer == 2 && region == 1) {
612 h->SetBins(834, 1, 2502, 116, 0, 116);
614 h->GetYaxis()->SetBinLabel(1,
"BO1");
615 h->GetYaxis()->SetBinLabel(17,
"BO2");
616 h->GetYaxis()->SetBinLabel(33,
"BO3");
617 h->GetYaxis()->SetBinLabel(49,
"BO4");
618 h->GetYaxis()->SetBinLabel(65,
"BO5");
619 h->GetYaxis()->SetBinLabel(81,
"BO6");
620 h->GetYaxis()->SetBinLabel(97,
"BO7,8");
622 h->GetYaxis()->SetBinLabel(101,
"BE1");
623 h->GetYaxis()->SetBinLabel(109,
"BE2");
625 h->GetYaxis()->SetTickLength(0);
626 for (
int i = 1;
i < 116;
i++) {
627 TLine*
l =
new TLine(1,
i, 20,
i);
628 h->GetListOfFunctions()->Add(
l);
630 TLine*
l1 =
new TLine(1, 16, 50, 16);
631 h->GetListOfFunctions()->Add(
l1);
632 TLine*
l2 =
new TLine(1, 32, 50, 32);
633 h->GetListOfFunctions()->Add(
l2);
634 TLine* l3 =
new TLine(1, 48, 50, 48);
635 h->GetListOfFunctions()->Add(l3);
636 TLine* l4 =
new TLine(1, 64, 50, 64);
637 h->GetListOfFunctions()->Add(l4);
638 TLine* l5 =
new TLine(1, 80, 50, 80);
639 h->GetListOfFunctions()->Add(l5);
640 TLine* l6 =
new TLine(1, 96, 50, 96);
641 h->GetListOfFunctions()->Add(l6);
642 TLine* l7 =
new TLine(1, 98, 50, 98);
643 h->GetListOfFunctions()->Add(l7);
644 TLine* l8 =
new TLine(1, 100, 50, 100);
645 h->GetListOfFunctions()->Add(l8);
646 TLine* l9 =
new TLine(1, 108, 50, 108);
647 h->GetListOfFunctions()->Add(l9);
653 h->SetBins(834, 1, 2502, 50, 0, 50);
655 h->GetYaxis()->SetBinLabel(1,
"EI1");
656 h->GetYaxis()->SetBinLabel(17,
"EI2");
657 h->GetYaxis()->SetBinLabel(33,
"EI3");
658 h->GetYaxis()->SetBinLabel(41,
"EI4");
659 h->GetYaxis()->SetBinLabel(49,
"EI5");
661 h->GetYaxis()->SetTickLength(0);
662 for (
int i = 1;
i < 50;
i++) {
663 TLine*
l =
new TLine(1,
i, 20,
i);
664 h->GetListOfFunctions()->Add(
l);
666 TLine*
l1 =
new TLine(1, 16, 50, 16);
667 h->GetListOfFunctions()->Add(
l1);
668 TLine*
l2 =
new TLine(1, 32, 50, 32);
669 h->GetListOfFunctions()->Add(
l2);
670 TLine* l3 =
new TLine(1, 40, 50, 40);
671 h->GetListOfFunctions()->Add(l3);
672 TLine* l4 =
new TLine(1, 48, 50, 48);
673 h->GetListOfFunctions()->Add(l4);
676 else if (
layer == 1) {
677 h->SetBins(834, 1, 2502, 80, 0, 80);
679 h->GetYaxis()->SetBinLabel(1,
"EM1");
680 h->GetYaxis()->SetBinLabel(17,
"EM2");
681 h->GetYaxis()->SetBinLabel(33,
"EM3");
682 h->GetYaxis()->SetBinLabel(49,
"EM4");
683 h->GetYaxis()->SetBinLabel(65,
"EM5");
685 h->GetYaxis()->SetTickLength(0);
686 for (
int i = 1;
i < 80;
i++) {
687 TLine*
l =
new TLine(1,
i, 20,
i);
688 h->GetListOfFunctions()->Add(
l);
690 TLine*
l1 =
new TLine(1, 16, 50, 16);
691 h->GetListOfFunctions()->Add(
l1);
692 TLine*
l2 =
new TLine(1, 32, 50, 32);
693 h->GetListOfFunctions()->Add(
l2);
694 TLine* l3 =
new TLine(1, 48, 50, 48);
695 h->GetListOfFunctions()->Add(l3);
696 TLine* l4 =
new TLine(1, 64, 50, 64);
697 h->GetListOfFunctions()->Add(l4);
700 else if (
layer == 2) {
703 h->SetBins(834, 1, 2502, 103, 0, 103);
705 h->GetYaxis()->SetBinLabel(1,
"EO1");
706 h->GetYaxis()->SetBinLabel(17,
"EO2");
707 h->GetYaxis()->SetBinLabel(33,
"EO3");
708 h->GetYaxis()->SetBinLabel(49,
"EO4");
709 h->GetYaxis()->SetBinLabel(65,
"EO5");
710 h->GetYaxis()->SetBinLabel(81,
"EO6");
711 h->GetYaxis()->SetBinLabel(97,
"EE1,2");
713 h->GetYaxis()->SetTickLength(0);
714 for (
int i = 1;
i < 103;
i++) {
715 TLine*
l =
new TLine(1,
i, 20,
i);
716 h->GetListOfFunctions()->Add(
l);
718 TLine*
l1 =
new TLine(1, 16, 50, 16);
719 h->GetListOfFunctions()->Add(
l1);
720 TLine*
l2 =
new TLine(1, 32, 50, 32);
721 h->GetListOfFunctions()->Add(
l2);
722 TLine* l3 =
new TLine(1, 48, 50, 48);
723 h->GetListOfFunctions()->Add(l3);
724 TLine* l4 =
new TLine(1, 64, 50, 64);
725 h->GetListOfFunctions()->Add(l4);
726 TLine* l5 =
new TLine(1, 80, 50, 80);
727 h->GetListOfFunctions()->Add(l5);
728 TLine* l6 =
new TLine(1, 96, 50, 96);
729 h->GetListOfFunctions()->Add(l6);
730 TLine* l7 =
new TLine(1, 100, 50, 100);
731 h->GetListOfFunctions()->Add(l7);
732 }
else if (region == 3) {
733 h->SetBins(834, 1, 2502, 127, 0, 127);
735 h->GetYaxis()->SetBinLabel(1,
"EO1");
736 h->GetYaxis()->SetBinLabel(17,
"EO2");
737 h->GetYaxis()->SetBinLabel(33,
"EO3");
738 h->GetYaxis()->SetBinLabel(49,
"EO4");
739 h->GetYaxis()->SetBinLabel(65,
"EO5");
740 h->GetYaxis()->SetBinLabel(81,
"EO6");
741 h->GetYaxis()->SetBinLabel(97,
"EE1");
742 h->GetYaxis()->SetBinLabel(113,
"EE2");
744 h->GetYaxis()->SetTickLength(0);
745 for (
int i = 1;
i < 127;
i++) {
746 TLine*
l =
new TLine(1,
i, 20,
i);
747 h->GetListOfFunctions()->Add(
l);
749 TLine*
l1 =
new TLine(1, 16, 50, 16);
750 h->GetListOfFunctions()->Add(
l1);
751 TLine*
l2 =
new TLine(1, 32, 50, 32);
752 h->GetListOfFunctions()->Add(
l2);
753 TLine* l3 =
new TLine(1, 48, 50, 48);
754 h->GetListOfFunctions()->Add(l3);
755 TLine* l4 =
new TLine(1, 64, 50, 64);
756 h->GetListOfFunctions()->Add(l4);
757 TLine* l5 =
new TLine(1, 80, 50, 80);
758 h->GetListOfFunctions()->Add(l5);
759 TLine* l6 =
new TLine(1, 96, 50, 96);
760 h->GetListOfFunctions()->Add(l6);
761 TLine* l7 =
new TLine(1, 112, 50, 112);
762 h->GetListOfFunctions()->Add(l7);
767 return StatusCode::SUCCESS;
771 if (region == 0 || region == 1) {
774 h->SetBins(834, 1, 2502, 73, 0, 73);
775 h->GetYaxis()->SetBinLabel(1,
"BIL");
776 h->GetYaxis()->SetBinLabel(13,
"BIS");
777 h->GetYaxis()->SetBinLabel(25,
"BME");
778 h->GetYaxis()->SetBinLabel(26,
"BML");
779 h->GetYaxis()->SetBinLabel(38,
"BMS");
780 h->GetYaxis()->SetBinLabel(50,
"BOL");
781 h->GetYaxis()->SetBinLabel(62,
"BOS");
783 h->GetYaxis()->SetTickLength(0);
784 for (
int i = 0;
i < 73;
i++) {
785 TLine*
l =
new TLine(1,
i, 20,
i);
786 h->GetListOfFunctions()->Add(
l);
788 TLine*
l2 =
new TLine(1, 0, 50, 0);
789 h->GetListOfFunctions()->Add(
l2);
790 TLine* l3 =
new TLine(1, 12, 50, 12);
791 h->GetListOfFunctions()->Add(l3);
792 TLine* l4 =
new TLine(1, 24, 50, 24);
793 h->GetListOfFunctions()->Add(l4);
794 TLine* l5 =
new TLine(1, 25, 50, 25);
795 h->GetListOfFunctions()->Add(l5);
796 TLine* l6 =
new TLine(1, 37, 50, 37);
797 h->GetListOfFunctions()->Add(l6);
798 TLine* l8 =
new TLine(1, 49, 50, 49);
799 h->GetListOfFunctions()->Add(l8);
800 TLine* l9 =
new TLine(1, 61, 50, 61);
801 h->GetListOfFunctions()->Add(l9);
804 else if (crate == 1) {
805 h->SetBins(834, 1, 2502, 73, 0, 73);
807 h->GetYaxis()->SetBinLabel(1,
"BIL");
808 h->GetYaxis()->SetBinLabel(13,
"BIS");
809 h->GetYaxis()->SetBinLabel(25,
"BME");
810 h->GetYaxis()->SetBinLabel(37,
"BMS");
811 h->GetYaxis()->SetBinLabel(49,
"BOL");
812 h->GetYaxis()->SetBinLabel(61,
"BOS");
814 h->GetYaxis()->SetTickLength(0);
815 for (
int i = 1;
i < 73;
i++) {
816 TLine*
l =
new TLine(1,
i, 20,
i);
817 h->GetListOfFunctions()->Add(
l);
819 TLine*
l1 =
new TLine(1, 12, 50, 12);
820 h->GetListOfFunctions()->Add(
l1);
821 TLine*
l2 =
new TLine(1, 24, 50, 24);
822 h->GetListOfFunctions()->Add(
l2);
823 TLine* l3 =
new TLine(1, 36, 50, 36);
824 h->GetListOfFunctions()->Add(l3);
825 TLine* l4 =
new TLine(1, 48, 50, 48);
826 h->GetListOfFunctions()->Add(l4);
827 TLine* l6 =
new TLine(1, 60, 50, 60);
828 h->GetListOfFunctions()->Add(l6);
830 }
else if (crate == 2) {
832 h->SetBins(834, 1, 2502, 80, 0, 80);
833 h->GetYaxis()->SetBinLabel(1,
"BIL");
834 h->GetYaxis()->SetBinLabel(7,
"BIM");
835 h->GetYaxis()->SetBinLabel(12,
"BIR");
836 h->GetYaxis()->SetBinLabel(18,
"BIS");
837 h->GetYaxis()->SetBinLabel(30,
"BMF");
838 h->GetYaxis()->SetBinLabel(33,
"BMG");
839 h->GetYaxis()->SetBinLabel(36,
"BML");
840 h->GetYaxis()->SetBinLabel(48,
"BMS");
841 h->GetYaxis()->SetBinLabel(54,
"BOF");
842 h->GetYaxis()->SetBinLabel(58,
"BOG");
844 h->GetYaxis()->SetBinLabel(63,
"BOL");
845 h->GetYaxis()->SetBinLabel(75,
"BOS");
846 }
else if (region == 1) {
847 h->GetYaxis()->SetBinLabel(62,
"BOL");
848 h->GetYaxis()->SetBinLabel(74,
"BOS");
851 h->GetYaxis()->SetTickLength(0);
852 for (
int i = 0;
i < 80;
i++) {
853 TLine*
l =
new TLine(1,
i, 20,
i);
854 h->GetListOfFunctions()->Add(
l);
856 TLine*
l2 =
new TLine(1, 6, 50, 6);
857 h->GetListOfFunctions()->Add(
l2);
858 TLine* l3 =
new TLine(1, 11, 50, 11);
859 h->GetListOfFunctions()->Add(l3);
860 TLine* l3b =
new TLine(1, 17, 50, 17);
861 h->GetListOfFunctions()->Add(l3b);
864 TLine* l5 =
new TLine(1, 29, 50, 29);
865 h->GetListOfFunctions()->Add(l5);
866 TLine* l6 =
new TLine(1, 32, 50, 32);
867 h->GetListOfFunctions()->Add(l6);
868 TLine* l7 =
new TLine(1, 35, 50, 35);
869 h->GetListOfFunctions()->Add(l7);
870 TLine* l8 =
new TLine(1, 47, 50, 47);
871 h->GetListOfFunctions()->Add(l8);
872 TLine* l9 =
new TLine(1, 53, 50, 53);
873 h->GetListOfFunctions()->Add(l9);
874 TLine* l9b =
new TLine(1, 57, 50, 57);
875 h->GetListOfFunctions()->Add(l9b);
877 TLine* l10 =
new TLine(1, 62, 50, 62);
878 h->GetListOfFunctions()->Add(l10);
879 TLine* l11 =
new TLine(1, 74, 50, 74);
880 h->GetListOfFunctions()->Add(l11);
881 }
else if (region == 1) {
882 TLine* l10 =
new TLine(1, 61, 50, 61);
883 h->GetListOfFunctions()->Add(l10);
884 TLine* l11 =
new TLine(1, 73, 50, 73);
885 h->GetListOfFunctions()->Add(l11);
889 else if (crate == 3) {
891 h->SetBins(834, 1, 2502, 79, 0, 79);
892 h->GetYaxis()->SetBinLabel(1,
"BIL");
893 h->GetYaxis()->SetBinLabel(7,
"BIM");
894 h->GetYaxis()->SetBinLabel(12,
"BIR");
895 h->GetYaxis()->SetBinLabel(18,
"BIS");
896 h->GetYaxis()->SetBinLabel(30,
"BMF");
897 h->GetYaxis()->SetBinLabel(33,
"BMG");
898 h->GetYaxis()->SetBinLabel(36,
"BML");
899 h->GetYaxis()->SetBinLabel(47,
"BMS");
900 h->GetYaxis()->SetBinLabel(53,
"BOF");
901 h->GetYaxis()->SetBinLabel(57,
"BOG");
903 h->GetYaxis()->SetBinLabel(62,
"BOL");
904 h->GetYaxis()->SetBinLabel(75,
"BOS");
905 }
else if (region == 1) {
906 h->GetYaxis()->SetBinLabel(61,
"BOL");
907 h->GetYaxis()->SetBinLabel(74,
"BOS");
911 h->GetYaxis()->SetTickLength(0);
912 for (
int i = 0;
i < 79;
i++) {
913 TLine*
l =
new TLine(1,
i, 20,
i);
914 h->GetListOfFunctions()->Add(
l);
916 TLine*
l2 =
new TLine(1, 6, 50, 6);
917 h->GetListOfFunctions()->Add(
l2);
918 TLine* l3 =
new TLine(1, 11, 50, 11);
919 h->GetListOfFunctions()->Add(l3);
920 TLine* l3b =
new TLine(1, 17, 50, 17);
921 h->GetListOfFunctions()->Add(l3b);
924 TLine* l5 =
new TLine(1, 29, 50, 29);
925 h->GetListOfFunctions()->Add(l5);
926 TLine* l6 =
new TLine(1, 32, 50, 32);
927 h->GetListOfFunctions()->Add(l6);
928 TLine* l7 =
new TLine(1, 35, 50, 35);
929 h->GetListOfFunctions()->Add(l7);
930 TLine* l8 =
new TLine(1, 46, 50, 46);
931 h->GetListOfFunctions()->Add(l8);
932 TLine* l9 =
new TLine(1, 52, 50, 52);
933 h->GetListOfFunctions()->Add(l9);
934 TLine* l9b =
new TLine(1, 56, 50, 56);
935 h->GetListOfFunctions()->Add(l9b);
937 TLine* l10 =
new TLine(1, 61, 50, 61);
938 h->GetListOfFunctions()->Add(l10);
939 TLine* l11 =
new TLine(1, 74, 50, 74);
940 h->GetListOfFunctions()->Add(l11);
941 }
else if (region == 1) {
942 TLine* l10 =
new TLine(1, 60, 50, 60);
943 h->GetListOfFunctions()->Add(l10);
944 TLine* l11 =
new TLine(1, 73, 50, 73);
945 h->GetListOfFunctions()->Add(l11);
951 if (crate == 0 || crate == 2) {
952 h->SetBins(834, 1, 2502, 73, 0, 73);
954 h->GetYaxis()->SetBinLabel(1,
"BEE");
955 h->GetYaxis()->SetBinLabel(5,
"BIS");
956 h->GetYaxis()->SetBinLabel(9,
"EEL");
957 h->GetYaxis()->SetBinLabel(13,
"EES");
958 h->GetYaxis()->SetBinLabel(17,
"EIL");
959 h->GetYaxis()->SetBinLabel(26,
"EIS");
960 h->GetYaxis()->SetBinLabel(30,
"EML");
961 h->GetYaxis()->SetBinLabel(40,
"EMS");
962 h->GetYaxis()->SetBinLabel(50,
"EOL");
963 h->GetYaxis()->SetBinLabel(62,
"EOS");
965 h->GetYaxis()->SetTickLength(0);
966 for (
int i = 1;
i < 73;
i++) {
967 TLine*
l =
new TLine(1,
i, 20,
i);
968 h->GetListOfFunctions()->Add(
l);
970 TLine*
l2 =
new TLine(1, 4, 50, 4);
971 h->GetListOfFunctions()->Add(
l2);
972 TLine* l3 =
new TLine(1, 8, 50, 8);
973 h->GetListOfFunctions()->Add(l3);
974 TLine* l4 =
new TLine(1, 12, 50, 12);
975 h->GetListOfFunctions()->Add(l4);
976 TLine* l5 =
new TLine(1, 16, 50, 16);
977 h->GetListOfFunctions()->Add(l5);
978 TLine* l6 =
new TLine(1, 25, 50, 25);
979 h->GetListOfFunctions()->Add(l6);
980 TLine* l7 =
new TLine(1, 29, 50, 29);
981 h->GetListOfFunctions()->Add(l7);
982 TLine* l8 =
new TLine(1, 39, 50, 39);
983 h->GetListOfFunctions()->Add(l8);
984 TLine* l9 =
new TLine(1, 49, 50, 49);
985 h->GetListOfFunctions()->Add(l9);
986 TLine* l10 =
new TLine(1, 61, 50, 61);
987 h->GetListOfFunctions()->Add(l10);
988 }
else if (crate == 1) {
989 h->SetBins(834, 1, 2502, 71, 0, 71);
991 h->GetYaxis()->SetBinLabel(1,
"BEE");
992 h->GetYaxis()->SetBinLabel(5,
"BIS");
993 h->GetYaxis()->SetBinLabel(9,
"EEL");
994 h->GetYaxis()->SetBinLabel(12,
"EES");
995 h->GetYaxis()->SetBinLabel(16,
"EIL");
996 h->GetYaxis()->SetBinLabel(24,
"EIS");
997 h->GetYaxis()->SetBinLabel(28,
"EML");
998 h->GetYaxis()->SetBinLabel(38,
"EMS");
999 h->GetYaxis()->SetBinLabel(48,
"EOL");
1000 h->GetYaxis()->SetBinLabel(60,
"EOS");
1002 h->GetYaxis()->SetTickLength(0);
1003 for (
int i = 1;
i < 71;
i++) {
1004 TLine*
l =
new TLine(1,
i, 20,
i);
1005 h->GetListOfFunctions()->Add(
l);
1007 TLine*
l2 =
new TLine(1, 4, 50, 4);
1008 h->GetListOfFunctions()->Add(
l2);
1009 TLine* l3 =
new TLine(1, 8, 50, 8);
1010 h->GetListOfFunctions()->Add(l3);
1011 TLine* l4 =
new TLine(1, 11, 50, 11);
1012 h->GetListOfFunctions()->Add(l4);
1013 TLine* l5 =
new TLine(1, 15, 50, 15);
1014 h->GetListOfFunctions()->Add(l5);
1015 TLine* l6 =
new TLine(1, 23, 50, 23);
1016 h->GetListOfFunctions()->Add(l6);
1017 TLine* l7 =
new TLine(1, 27, 50, 27);
1018 h->GetListOfFunctions()->Add(l7);
1019 TLine* l8 =
new TLine(1, 37, 50, 37);
1020 h->GetListOfFunctions()->Add(l8);
1021 TLine* l9 =
new TLine(1, 47, 50, 47);
1022 h->GetListOfFunctions()->Add(l9);
1023 TLine* l10 =
new TLine(1, 59, 50, 59);
1024 h->GetListOfFunctions()->Add(l10);
1025 }
else if (crate == 3) {
1026 h->SetBins(834, 1, 2502, 72, 0, 72);
1028 h->GetYaxis()->SetBinLabel(1,
"BEE");
1029 h->GetYaxis()->SetBinLabel(5,
"BIS");
1030 h->GetYaxis()->SetBinLabel(9,
"EEL");
1031 h->GetYaxis()->SetBinLabel(13,
"EES");
1032 h->GetYaxis()->SetBinLabel(17,
"EIL");
1033 h->GetYaxis()->SetBinLabel(25,
"EIS");
1034 h->GetYaxis()->SetBinLabel(29,
"EML");
1035 h->GetYaxis()->SetBinLabel(39,
"EMS");
1036 h->GetYaxis()->SetBinLabel(49,
"EOL");
1037 h->GetYaxis()->SetBinLabel(61,
"EOS");
1039 h->GetYaxis()->SetTickLength(0);
1040 for (
int i = 1;
i < 72;
i++) {
1041 TLine*
l =
new TLine(1,
i, 20,
i);
1042 h->GetListOfFunctions()->Add(
l);
1044 TLine*
l2 =
new TLine(1, 4, 50, 4);
1045 h->GetListOfFunctions()->Add(
l2);
1046 TLine* l3 =
new TLine(1, 8, 50, 8);
1047 h->GetListOfFunctions()->Add(l3);
1048 TLine* l4 =
new TLine(1, 12, 50, 12);
1049 h->GetListOfFunctions()->Add(l4);
1050 TLine* l5 =
new TLine(1, 16, 50, 16);
1051 h->GetListOfFunctions()->Add(l5);
1052 TLine* l6 =
new TLine(1, 24, 50, 24);
1053 h->GetListOfFunctions()->Add(l6);
1054 TLine* l7 =
new TLine(1, 28, 50, 28);
1055 h->GetListOfFunctions()->Add(l7);
1056 TLine* l8 =
new TLine(1, 38, 50, 38);
1057 h->GetListOfFunctions()->Add(l8);
1058 TLine* l9 =
new TLine(1, 48, 50, 48);
1059 h->GetListOfFunctions()->Add(l9);
1060 TLine* l10 =
new TLine(1, 60, 50, 60);
1061 h->GetListOfFunctions()->Add(l10);
1065 return StatusCode::SUCCESS;
1070 std::string_view stName =
chamber.substr(0, 3);
1071 if (region == 0 || region == 1) {
1073 if (stName ==
"BIL")
1074 binNum = 2 *
eta + (
phi - 1) / 2 - 1;
1075 else if (stName ==
"BIS")
1076 binNum = 12 + 2 *
eta + (
phi - 2) / 2 - 1;
1077 else if (stName ==
"BME")
1079 else if (stName ==
"BML")
1080 binNum = 25 + 2 *
eta + (
phi - 1) / 2 - 1;
1081 else if (stName ==
"BMS")
1082 binNum = 37 + 2 *
eta + (
phi - 2) / 2 - 1;
1083 else if (stName ==
"BOL")
1084 binNum = 49 + 2 *
eta + (
phi - 1) / 2 - 1;
1085 else if (stName ==
"BOS")
1086 binNum = 61 + 2 *
eta + (
phi - 2) / 2 - 1;
1090 }
else if (crate == 2) {
1092 if (stName ==
"BIL")
1093 binNum = 2 *
eta + (
phi - 5) / 2 - 1;
1094 else if (stName ==
"BIS")
1095 binNum = 12 + 2 *
eta + (
phi - 6) / 2 - 1;
1096 else if (stName ==
"BML")
1097 binNum = 24 + 2 *
eta + (
phi - 5) / 2 - 1;
1098 else if (stName ==
"BMS")
1099 binNum = 36 + 2 *
eta + (
phi - 6) / 2 - 1;
1100 else if (stName ==
"BOL")
1101 binNum = 48 + 2 *
eta + (
phi - 5) / 2 - 1;
1102 else if (stName ==
"BOS")
1103 binNum = 60 + 2 *
eta + (
phi - 6) / 2 - 1;
1107 }
else if (crate == 3) {
1108 if (stName ==
"BIL")
1110 else if (stName ==
"BIM")
1112 else if (stName ==
"BIR")
1114 else if (stName ==
"BIS")
1115 binNum = 17 + 2 *
eta + (
phi - 10) / 2 - 1;
1116 else if (stName ==
"BMF")
1117 binNum = 29 + (
eta + 1) / 2;
1118 else if (stName ==
"BMG")
1119 binNum = 32 +
eta / 2;
1120 else if (stName ==
"BML")
1121 binNum = 35 + 2 *
eta + (
phi - 9) / 2 - 1;
1122 else if (stName ==
"BMS")
1124 else if (stName ==
"BOF")
1125 binNum = 53 + (
eta + 1) / 2;
1126 else if (
chamber.substr(0, 4) ==
"BOG0" && region == 0)
1128 else if (stName ==
"BOG")
1129 binNum = 58 +
eta / 2 - region;
1130 else if (stName ==
"BOL")
1131 binNum = 62 + 2 *
eta + (
phi - 9) / 2 - 1 - region;
1132 else if (stName ==
"BOS")
1133 binNum = 74 +
eta - region;
1137 }
else if (crate == 4) {
1139 if (stName ==
"BIL")
1141 else if (stName ==
"BIM")
1143 else if (stName ==
"BIR")
1145 else if (stName ==
"BIS")
1146 binNum = 17 + 2 *
eta + (
phi - 14) / 2 - 1;
1147 else if (stName ==
"BMF")
1148 binNum = 29 + (
eta + 1) / 2;
1149 else if (stName ==
"BMG")
1150 binNum = 32 +
eta / 2;
1151 else if (stName ==
"BML" &&
eta < 6)
1152 binNum = 35 + 2 *
eta + (
phi - 13) / 2 - 1;
1153 else if (
chamber.substr(0, 7) ==
"BML6A15" ||
chamber.substr(0, 7) ==
"BML6C15")
1155 else if (stName ==
"BMS")
1157 else if (stName ==
"BOF")
1158 binNum = 52 + (
eta + 1) / 2;
1159 else if (
chamber.substr(0, 4) ==
"BOG0" && region == 0)
1161 else if (stName ==
"BOG")
1162 binNum = 57 +
eta / 2 - region;
1163 else if (stName ==
"BOL")
1164 binNum = 61 + 2 *
eta + (
phi - 13) / 2 - 1 - region;
1165 else if (stName ==
"BOS")
1166 binNum = 74 +
eta - region;
1171 }
else if (region == 2 || region == 3) {
1173 if (stName ==
"BEE")
1174 binNum = 2 *
eta + (
phi - 2) / 2 - 1;
1175 else if (stName ==
"BIS")
1176 binNum = 4 + 2 * (
eta - 6) + (
phi - 2) / 2 - 1;
1177 else if (stName ==
"EEL")
1178 binNum = 8 + 2 *
eta + (
phi - 1) / 2 - 1;
1179 else if (stName ==
"EES")
1180 binNum = 12 + 2 *
eta + (
phi - 2) / 2 - 1;
1181 else if (stName ==
"EIL" &&
eta < 5)
1182 binNum = 16 + 2 *
eta + (
phi - 1) / 2 - 1;
1183 else if (stName ==
"EIL" &&
eta == 5)
1185 else if (stName ==
"EIS")
1186 binNum = 25 + 2 *
eta + (
phi - 2) / 2 - 1;
1187 else if (stName ==
"EML")
1188 binNum = 29 + 2 *
eta + (
phi - 1) / 2 - 1;
1189 else if (stName ==
"EMS")
1190 binNum = 39 + 2 *
eta + (
phi - 2) / 2 - 1;
1191 else if (stName ==
"EOL")
1192 binNum = 49 + 2 *
eta + (
phi - 1) / 2 - 1;
1193 else if (stName ==
"EOS")
1194 binNum = 61 + 2 *
eta + (
phi - 2) / 2 - 1;
1199 if (binNum > 8 && binNum < 23)
1200 binNum = binNum - 2;
1201 else if (binNum > 22 && binNum < 30)
1202 binNum = binNum - 8;
1203 else if (binNum > 29)
1204 binNum = binNum - 12;
1205 }
else if (region == 3) {
1206 if (binNum > 22 && binNum < 30)
1207 binNum = binNum - 6;
1208 else if (binNum > 29)
1209 binNum = binNum - 10;
1213 }
else if (crate == 2) {
1214 if (stName ==
"BEE")
1215 binNum = 2 *
eta + (
phi - 6) / 2 - 1;
1216 else if (stName ==
"BIS")
1217 binNum = 4 + 2 * (
eta - 6) + (
phi - 6) / 2 - 1;
1218 else if (
chamber.substr(0, 4) ==
"EEL1")
1219 binNum = 9 + (
phi - 3) / 2 - 1;
1220 else if (
chamber.substr(0, 4) ==
"EEL2")
1222 else if (stName ==
"EES")
1223 binNum = 11 + 2 *
eta + (
phi - 6) / 2 - 1;
1224 else if (stName ==
"EIL")
1225 binNum = 15 + 2 *
eta + (
phi - 5) / 2 - 1;
1226 else if (stName ==
"EIS")
1227 binNum = 23 + 2 *
eta + (
phi - 6) / 2 - 1;
1228 else if (stName ==
"EML")
1229 binNum = 27 + 2 *
eta + (
phi - 5) / 2 - 1;
1230 else if (stName ==
"EMS")
1231 binNum = 37 + 2 *
eta + (
phi - 6) / 2 - 1;
1232 else if (stName ==
"EOL")
1233 binNum = 47 + 2 *
eta + (
phi - 5) / 2 - 1;
1234 else if (stName ==
"EOS")
1235 binNum = 59 + 2 *
eta + (
phi - 6) / 2 - 1;
1240 if (binNum > 8 && binNum < 22)
1241 binNum = binNum - 2;
1242 else if (binNum > 21 && binNum < 28)
1243 binNum = binNum - 8;
1244 else if (binNum > 27)
1245 binNum = binNum - 12;
1246 }
else if (region == 3) {
1247 if (binNum > 21 && binNum < 28)
1248 binNum = binNum - 6;
1249 else if (binNum > 27)
1250 binNum = binNum - 10;
1254 }
else if (crate == 3) {
1256 if (stName ==
"BEE")
1257 binNum = 2 *
eta + (
phi - 10) / 2 - 1;
1258 else if (stName ==
"BIS")
1259 binNum = 4 + 2 * (
eta - 6) + (
phi - 10) / 2 - 1;
1260 else if (stName ==
"EEL")
1261 binNum = 8 + 2 *
eta + (
phi - 9) / 2 - 1;
1262 else if (stName ==
"EES")
1263 binNum = 12 + 2 *
eta + (
phi - 10) / 2 - 1;
1264 else if (stName ==
"EIL" &&
eta < 5)
1265 binNum = 16 + 2 *
eta + (
phi - 9) / 2 - 1;
1266 else if (
chamber.substr(0, 4) ==
"EIL5")
1268 else if (stName ==
"EIS")
1269 binNum = 25 + 2 *
eta + (
phi - 10) / 2 - 1;
1270 else if (stName ==
"EML")
1271 binNum = 29 + 2 *
eta + (
phi - 9) / 2 - 1;
1272 else if (stName ==
"EMS")
1273 binNum = 39 + 2 *
eta + (
phi - 10) / 2 - 1;
1274 else if (stName ==
"EOL")
1275 binNum = 49 + 2 *
eta + (
phi - 9) / 2 - 1;
1276 else if (stName ==
"EOS")
1277 binNum = 61 + 2 *
eta + (
phi - 10) / 2 - 1;
1282 if (binNum > 8 && binNum < 23)
1283 binNum = binNum - 2;
1284 else if (binNum > 22 && binNum < 30)
1285 binNum = binNum - 8;
1286 else if (binNum > 29)
1287 binNum = binNum - 12;
1290 if (binNum > 22 && binNum < 30)
1291 binNum = binNum - 6;
1292 else if (binNum > 29)
1293 binNum = binNum - 10;
1297 }
else if (crate == 4) {
1298 if (stName ==
"BEE")
1299 binNum = 2 *
eta + (
phi - 14) / 2 - 1;
1300 else if (stName ==
"BIS")
1301 binNum = 4 + 2 * (
eta - 6) + (
phi - 14) / 2 - 1;
1302 else if (stName ==
"EEL")
1303 binNum = 8 + 2 *
eta + (
phi - 13) / 2 - 1;
1304 else if (stName ==
"EES")
1305 binNum = 12 + 2 *
eta + (
phi - 14) / 2 - 1;
1306 else if (stName ==
"EIL")
1307 binNum = 16 + 2 *
eta + (
phi - 13) / 2 - 1;
1308 else if (stName ==
"EIS")
1309 binNum = 24 + 2 *
eta + (
phi - 14) / 2 - 1;
1310 else if (stName ==
"EML")
1311 binNum = 28 + 2 *
eta + (
phi - 13) / 2 - 1;
1312 else if (stName ==
"EMS")
1313 binNum = 38 + 2 *
eta + (
phi - 14) / 2 - 1;
1314 else if (stName ==
"EOL")
1315 binNum = 48 + 2 *
eta + (
phi - 13) / 2 - 1;
1316 else if (stName ==
"EOS")
1317 binNum = 60 + 2 *
eta + (
phi - 14) / 2 - 1;
1322 if (binNum > 8 && binNum < 23)
1323 binNum = binNum - 2;
1324 else if (binNum > 22 && binNum < 29)
1325 binNum = binNum - 8;
1326 else if (binNum > 28)
1327 binNum = binNum - 12;
1330 if (binNum > 22 && binNum < 28)
1331 binNum = binNum - 6;
1332 else if (binNum > 28)
1333 binNum = binNum - 10;