CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
L1MuDTEUX.h
Go to the documentation of this file.
1 //-------------------------------------------------
2 //
17 //
18 //--------------------------------------------------
19 #ifndef L1MUDT_EUX_H
20 #define L1MUDT_EUX_H
21 
22 //---------------
23 // C++ Headers --
24 //---------------
25 
26 #include <utility>
27 #include <map>
28 
29 //----------------------
30 // Base Class Headers --
31 //----------------------
32 
34 
35 //------------------------------------
36 // Collaborating Class Declarations --
37 //------------------------------------
38 
40 class L1MuDTTrackSegPhi;
42 class L1MuDTSEU;
43 class L1MuDTExtLut;
44 class L1MuDTTFParameters;
45 
46 // ---------------------
47 // -- Class Interface --
48 // ---------------------
49 
51 
52  public:
53 
55  L1MuDTEUX(const L1MuDTSectorProcessor& sp, const L1MuDTSEU& seu, int id );
56 
58  virtual ~L1MuDTEUX();
59 
61  bool operator==(const L1MuDTEUX&) const;
62 
64  virtual void run(const edm::EventSetup& c);
65 
67  virtual void reset();
68 
70  void load(const L1MuDTTrackSegPhi* start_ts, const L1MuDTTrackSegPhi* target_ts);
71 
73  std::pair<const L1MuDTTrackSegPhi*, const L1MuDTTrackSegPhi*> ts() const;
74 
76  static void setPrecision();
77 
79  class EUX_Comp : std::binary_function< L1MuDTEUX*, L1MuDTEUX*, bool> {
80  public :
81  EUX_Comp( const L1MuDTEUX* k = 0 ) : _not(k) {}
82  bool operator()( const L1MuDTEUX* first, const L1MuDTEUX* second ) const {
83  if ( !second->result() ) return false;
84  if ( _not != 0 && *first == *_not ) return true;
85  if ( _not != 0 && *second == *_not ) return false;
86  return ( first->quality() < second->quality() );
87  }
88  private:
89  const L1MuDTEUX* _not;
90  };
91 
93  inline int id() const { return m_id; }
94 
96  inline bool result() const { return m_result; }
97 
99  inline unsigned int quality() const { return m_quality; }
100 
102  inline unsigned short int address() const { return m_address; }
103 
104  private:
105 
107  int sec_mod(int) const;
108 
109  private:
110 
112  const L1MuDTSEU& m_seu; // reference to Single Extrapolation Unit
113  int m_id; // index of start TS
114 
115  bool m_result; //@@ 1 bit
116  unsigned short int m_quality; //@@ 1 bit
117  unsigned short int m_address; //@@ 4 bits
118 
119  const L1MuDTTrackSegPhi* m_start; // start track segment
120  const L1MuDTTrackSegPhi* m_target; // target track segment
121 
122  edm::ESHandle< L1MuDTExtLut > theExtLUTs; // extrapolation look-up tables
123  static int theExtFilter; // extrapolation quality filter
124  static unsigned short nbit_phi; // number of bits used for phi
125  static unsigned short nbit_phib; // number of bits used for phib
126 
128 
129 };
130 
131 #endif
bool m_result
Definition: L1MuDTEUX.h:115
edm::ESHandle< L1MuDTExtLut > theExtLUTs
Definition: L1MuDTEUX.h:122
const L1MuDTEUX * _not
Definition: L1MuDTEUX.h:89
virtual void reset()
reset Extrapolator
Definition: L1MuDTEUX.cc:211
bool operator()(const L1MuDTEUX *first, const L1MuDTEUX *second) const
Definition: L1MuDTEUX.h:82
const L1MuDTSEU & m_seu
Definition: L1MuDTEUX.h:112
void load(const L1MuDTTrackSegPhi *start_ts, const L1MuDTTrackSegPhi *target_ts)
load data into EUX
Definition: L1MuDTEUX.cc:192
int sec_mod(int) const
output sector numbers in the range -6 to +5
Definition: L1MuDTEUX.cc:237
U second(std::pair< T, U > const &p)
bool operator==(const L1MuDTEUX &) const
equal operator
Definition: L1MuDTEUX.cc:76
virtual void run()
run processor logic
static void setPrecision()
set precision of phi and phib
Definition: L1MuDTEUX.cc:254
bool first
Definition: L1TdeRCT.cc:94
virtual ~L1MuDTEUX()
destructor
Definition: L1MuDTEUX.cc:66
static int theExtFilter
Definition: L1MuDTEUX.h:123
static unsigned short nbit_phi
Definition: L1MuDTEUX.h:124
static unsigned short nbit_phib
Definition: L1MuDTEUX.h:125
edm::ESHandle< L1MuDTTFParameters > pars
Definition: L1MuDTEUX.h:127
unsigned short int address() const
return extrapolation address (0-11) (address = 15 indicates negative ext. result) ...
Definition: L1MuDTEUX.h:102
int k[5][pyjets_maxn]
helper class for finding the best and second best extrapolation
Definition: L1MuDTEUX.h:79
EUX_Comp(const L1MuDTEUX *k=0)
Definition: L1MuDTEUX.h:81
L1MuDTEUX(const L1MuDTSectorProcessor &sp, const L1MuDTSEU &seu, int id)
constructor
Definition: L1MuDTEUX.cc:52
const L1MuDTTrackSegPhi * m_target
Definition: L1MuDTEUX.h:120
unsigned short int m_quality
Definition: L1MuDTEUX.h:116
const L1MuDTSectorProcessor & m_sp
Definition: L1MuDTEUX.h:111
std::pair< const L1MuDTTrackSegPhi *, const L1MuDTTrackSegPhi * > ts() const
return pointer to start and target track segment
Definition: L1MuDTEUX.cc:226
int id() const
return Extrapolation identifier
Definition: L1MuDTEUX.h:93
unsigned int quality() const
return extrapolation quality
Definition: L1MuDTEUX.h:99
int m_id
Definition: L1MuDTEUX.h:113
const L1MuDTTrackSegPhi * m_start
Definition: L1MuDTEUX.h:119
unsigned short int m_address
Definition: L1MuDTEUX.h:117
bool result() const
return extrapolation result
Definition: L1MuDTEUX.h:96