CMS 3D CMS Logo

L1MuDTEUX.h
Go to the documentation of this file.
1 //-------------------------------------------------
2 //
15 //
16 //--------------------------------------------------
17 #ifndef L1MUDT_EUX_H
18 #define L1MUDT_EUX_H
19 
20 //---------------
21 // C++ Headers --
22 //---------------
23 
24 #include <utility>
25 #include <map>
26 
27 //----------------------
28 // Base Class Headers --
29 //----------------------
30 
32 
33 //------------------------------------
34 // Collaborating Class Declarations --
35 //------------------------------------
36 
38 class L1MuDTTrackSegPhi;
40 class L1MuDTSEU;
41 class L1MuDTExtLut;
42 class L1MuDTTFParameters;
43 
44 // ---------------------
45 // -- Class Interface --
46 // ---------------------
47 
49 public:
51  L1MuDTEUX(const L1MuDTSectorProcessor& sp, const L1MuDTSEU& seu, int id);
52 
54  ~L1MuDTEUX() override;
55 
57  bool operator==(const L1MuDTEUX&) const;
58 
60  void run(const edm::EventSetup& c) override;
61 
63  void reset() override;
64 
66  void load(const L1MuDTTrackSegPhi* start_ts, const L1MuDTTrackSegPhi* target_ts);
67 
69  std::pair<const L1MuDTTrackSegPhi*, const L1MuDTTrackSegPhi*> ts() const;
70 
72  class EUX_Comp {
73  public:
74  EUX_Comp(const L1MuDTEUX* k = nullptr) : _not(k) {}
75  bool operator()(const L1MuDTEUX* first, const L1MuDTEUX* second) const {
76  if (!second->result())
77  return false;
78  if (_not != nullptr && *first == *_not)
79  return true;
80  if (_not != nullptr && *second == *_not)
81  return false;
82  return (first->quality() < second->quality());
83  }
84 
85  private:
86  const L1MuDTEUX* _not;
87  };
88 
90  inline int id() const { return m_id; }
91 
93  inline bool result() const { return m_result; }
94 
96  inline unsigned int quality() const { return m_quality; }
97 
99  inline unsigned short int address() const { return m_address; }
100 
101 private:
103  int sec_mod(int) const;
104 
105 private:
107  const L1MuDTSEU& m_seu; // reference to Single Extrapolation Unit
108  int m_id; // index of start TS
109 
110  bool m_result; //@@ 1 bit
111  unsigned short int m_quality; //@@ 1 bit
112  unsigned short int m_address; //@@ 4 bits
113 
114  const L1MuDTTrackSegPhi* m_start; // start track segment
115  const L1MuDTTrackSegPhi* m_target; // target track segment
116 
117  edm::ESHandle<L1MuDTExtLut> theExtLUTs; // extrapolation look-up tables
118  int const theExtFilter = 1; // extrapolation quality filter
119  unsigned short const nbit_phi = 12; // number of bits used for phi
120  unsigned short const nbit_phib = 10; // number of bits used for phib
121 
123 };
124 
125 #endif
L1MuDTEUX::EUX_Comp::operator()
bool operator()(const L1MuDTEUX *first, const L1MuDTEUX *second) const
Definition: L1MuDTEUX.h:75
ESHandle.h
L1MuDTEUX
Definition: L1MuDTEUX.h:48
L1MuDTEUX::m_start
const L1MuDTTrackSegPhi * m_start
Definition: L1MuDTEUX.h:114
L1MuDTExtLut
Definition: L1MuDTExtLut.h:39
edm::second
U second(std::pair< T, U > const &p)
Definition: ParameterSet.cc:215
L1MuDTEUX::L1MuDTEUX
L1MuDTEUX(const L1MuDTSectorProcessor &sp, const L1MuDTSEU &seu, int id)
constructor
Definition: L1MuDTEUX.cc:51
L1MuDTEUX::reset
void reset() override
reset Extrapolator
Definition: L1MuDTEUX.cc:228
L1MuDTEUX::quality
unsigned int quality() const
return extrapolation quality
Definition: L1MuDTEUX.h:96
L1MuDTEUX::result
bool result() const
return extrapolation result
Definition: L1MuDTEUX.h:93
dqmdumpme.first
first
Definition: dqmdumpme.py:55
L1MuDTEUX::pars
edm::ESHandle< L1MuDTTFParameters > pars
Definition: L1MuDTEUX.h:122
L1MuDTEUX::sec_mod
int sec_mod(int) const
output sector numbers in the range -6 to +5
Definition: L1MuDTEUX.cc:248
L1MuDTEUX::load
void load(const L1MuDTTrackSegPhi *start_ts, const L1MuDTTrackSegPhi *target_ts)
load data into EUX
Definition: L1MuDTEUX.cc:213
L1MuDTEUX::address
unsigned short int address() const
return extrapolation address (0-11) (address = 15 indicates negative ext. result)
Definition: L1MuDTEUX.h:99
edm::ESHandle< L1MuDTExtLut >
L1MuDTEUX::id
int id() const
return Extrapolation identifier
Definition: L1MuDTEUX.h:90
L1MuDTEUX::nbit_phi
unsigned const short nbit_phi
Definition: L1MuDTEUX.h:119
L1AbstractProcessor
Definition: L1AbstractProcessor.h:34
dqmdumpme.k
k
Definition: dqmdumpme.py:60
L1MuDTEUX::m_target
const L1MuDTTrackSegPhi * m_target
Definition: L1MuDTEUX.h:115
L1MuDTEUX::theExtFilter
const int theExtFilter
Definition: L1MuDTEUX.h:118
L1MuDTEUX::m_seu
const L1MuDTSEU & m_seu
Definition: L1MuDTEUX.h:107
L1MuDTEUX::nbit_phib
unsigned const short nbit_phib
Definition: L1MuDTEUX.h:120
L1MuDTEUX::~L1MuDTEUX
~L1MuDTEUX() override
destructor
Definition: L1MuDTEUX.cc:68
L1AbstractProcessor::run
virtual void run()
run processor logic
Definition: L1AbstractProcessor.h:40
L1MuDTEUX::EUX_Comp::_not
const L1MuDTEUX * _not
Definition: L1MuDTEUX.h:86
edm::EventSetup
Definition: EventSetup.h:57
HltBtagPostValidation_cff.c
c
Definition: HltBtagPostValidation_cff.py:31
L1MuDTEUX::operator==
bool operator==(const L1MuDTEUX &) const
equal operator
Definition: L1MuDTEUX.cc:77
L1MuDTEUX::EUX_Comp::EUX_Comp
EUX_Comp(const L1MuDTEUX *k=nullptr)
Definition: L1MuDTEUX.h:74
L1AbstractProcessor.h
L1MuDTEUX::m_sp
const L1MuDTSectorProcessor & m_sp
Definition: L1MuDTEUX.h:106
L1MuDTEUX::m_result
bool m_result
Definition: L1MuDTEUX.h:110
L1MuDTEUX::m_id
int m_id
Definition: L1MuDTEUX.h:108
L1MuDTSectorProcessor
Definition: L1MuDTSectorProcessor.h:53
L1MuDTEUX::EUX_Comp
helper class for finding the best and second best extrapolation
Definition: L1MuDTEUX.h:72
L1MuDTEUX::ts
std::pair< const L1MuDTTrackSegPhi *, const L1MuDTTrackSegPhi * > ts() const
return pointer to start and target track segment
Definition: L1MuDTEUX.cc:240
L1MuDTTrackSegPhi
Definition: L1MuDTTrackSegPhi.h:36
L1MuDTSEU
Definition: L1MuDTSEU.h:48
L1MuDTEUX::m_quality
unsigned short int m_quality
Definition: L1MuDTEUX.h:111
L1MuDTEUX::theExtLUTs
edm::ESHandle< L1MuDTExtLut > theExtLUTs
Definition: L1MuDTEUX.h:117
L1MuDTEUX::m_address
unsigned short int m_address
Definition: L1MuDTEUX.h:112
L1MuDTTFParameters
Definition: L1MuDTTFParameters.h:36