CMS 3D CMS Logo

AlignTrackSegments.cc
Go to the documentation of this file.
1 //-------------------------------------------------
2 //
3 // Class: AlignTrackSegments
4 //
5 // AlignTrackSegments
6 //
7 //
8 // Author :
9 // G. Flouris U Ioannina Mar. 2015
10 //modifications: GKarathanasis U Athens
11 //--------------------------------------------------
12 #include <iostream>
13 #include <iomanip>
14 #include <iterator>
15 #include <memory>
17 
18 using namespace std;
19 
21  : m_phiDigis(inm_phiDigis){
22  // m_phiDigis = inm_phiDigis;
23  };
24 
26  std::vector<L1MuDTChambPhDigi> l1ttma_out;
27 
28  for (int bx = -3; bx <= 3; bx++) {
29  for (int wheel = -3; wheel <= 3; wheel++) {
30  for (int sector = 0; sector < 12; sector++) {
31  for (int station = 1; station <= 4; station++) {
33  L1MuDTChambPhDigi const* ts1 = m_phiDigis.chPhiSegm1(wheel, station, sector, bx);
35  L1MuDTChambPhDigi const* ts2 = m_phiDigis.chPhiSegm2(wheel, station, sector, bx);
37  if (ts1 != nullptr && ts1->code() != 7) {
38  l1ttma_out.emplace_back(bx,
39  ts1->whNum(),
40  ts1->scNum(),
41  ts1->stNum(),
42  ts1->phi(),
43  ts1->phiB(),
44  ts1->code(),
45  ts1->Ts2Tag(),
46  ts1->BxCnt(),
47  0);
48  }
49  if ((ts1 == nullptr || ts1->code() == 7) && ts2 && ts2->code() != 7) {
50  l1ttma_out.emplace_back(ts2->bxNum(),
51  ts2->whNum(),
52  ts2->scNum(),
53  ts2->stNum(),
54  ts2->phi(),
55  ts2->phiB(),
56  ts2->code(),
57  ts2->Ts2Tag(),
58  ts2->BxCnt(),
59  0);
60  }
62  if (ts1 != nullptr && ts1->code() != 7 && ts2 && ts2->code() != 7) {
63  l1ttma_out.emplace_back(ts2->bxNum() - ts2->Ts2Tag(),
64  ts2->whNum(),
65  ts2->scNum(),
66  ts2->stNum(),
67  ts2->phi(),
68  ts2->phiB(),
69  ts2->code(),
70  ts2->Ts2Tag(),
71  ts2->BxCnt(),
72  0);
73  }
74  }
75  }
76  }
77  }
78 
79  m_dt_tsshifted.setContainer(l1ttma_out);
80 }
L1MuDTChambPhDigi::stNum
int stNum() const
Definition: L1MuDTChambPhDigi.cc:72
L1MuDTChambPhContainer::chPhiSegm1
L1MuDTChambPhDigi const * chPhiSegm1(int wheel, int stat, int sect, int bx) const
Definition: L1MuDTChambPhContainer.cc:67
relativeConstraints.station
station
Definition: relativeConstraints.py:67
L1MuDTChambPhDigi::whNum
int whNum() const
Definition: L1MuDTChambPhDigi.cc:70
l1GtPatternGenerator_cfi.bx
bx
Definition: l1GtPatternGenerator_cfi.py:18
AlignTrackSegments::AlignTrackSegments
AlignTrackSegments(L1MuDTChambPhContainer inphiDigis)
Definition: AlignTrackSegments.cc:20
L1MuDTChambPhDigi::phiB
int phiB() const
Definition: L1MuDTChambPhDigi.cc:76
AlignTrackSegments.h
L1MuDTChambPhContainer
Definition: L1MuDTChambPhContainer.h:33
AlignTrackSegments::m_dt_tsshifted
L1MuDTChambPhContainer m_dt_tsshifted
Output PhContainer.
Definition: AlignTrackSegments.h:43
L1MuDTChambPhContainer::setContainer
void setContainer(Phi_Container inputSegments)
Definition: L1MuDTChambPhContainer.cc:39
L1MuDTChambPhDigi::BxCnt
int BxCnt() const
Definition: L1MuDTChambPhDigi.cc:82
L1MuDTChambPhDigi::phi
int phi() const
Definition: L1MuDTChambPhDigi.cc:74
L1MuDTChambPhDigi::bxNum
int bxNum() const
Definition: L1MuDTChambPhDigi.cc:68
L1MuDTChambPhContainer::chPhiSegm2
L1MuDTChambPhDigi const * chPhiSegm2(int wheel, int stat, int sect, int bx) const
Definition: L1MuDTChambPhContainer.cc:78
AlignTrackSegments::m_phiDigis
L1MuDTChambPhContainer m_phiDigis
Definition: AlignTrackSegments.h:44
makeMuonMisalignmentScenario.wheel
wheel
Definition: makeMuonMisalignmentScenario.py:319
edm::EventSetup
Definition: EventSetup.h:57
L1MuDTChambPhDigi::scNum
int scNum() const
Definition: L1MuDTChambPhDigi.cc:71
HltBtagPostValidation_cff.c
c
Definition: HltBtagPostValidation_cff.py:31
std
Definition: JetResolutionObject.h:76
AlignTrackSegments::run
void run(const edm::EventSetup &c)
Definition: AlignTrackSegments.cc:25
L1MuDTChambPhDigi::Ts2Tag
int Ts2Tag() const
Definition: L1MuDTChambPhDigi.cc:80
L1MuDTChambPhDigi::code
int code() const
Definition: L1MuDTChambPhDigi.cc:78
L1MuDTChambPhDigi
Definition: L1MuDTChambPhDigi.h:31