CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
MuonPathAnalyticAnalyzer.h
Go to the documentation of this file.
1 #ifndef L1Trigger_DTTriggerPhase2_MuonPathAnalyticAnalyzer_h
2 #define L1Trigger_DTTriggerPhase2_MuonPathAnalyticAnalyzer_h
3 
5 
6 // ===============================================================================
7 // Previous definitions and declarations
8 // ===============================================================================
9 
10 struct MAGNITUDE {
11  int add;
12  int coeff[4];
13  int mult;
14 };
15 
16 struct CONSTANTS {
21 };
22 
24  int latcomb;
26 };
27 
30  int valid[4];
31 };
32 
36 };
37 
38 // ===============================================================================
39 // Class declarations
40 // ===============================================================================
41 
43 public:
44  // Constructors and destructor
47  std::shared_ptr<GlobalCoordsObtainer> &globalcoordsobtainer);
48  ~MuonPathAnalyticAnalyzer() override;
49 
50  // Main methods
51  void initialise(const edm::EventSetup &iEventSetup) override;
52  void run(edm::Event &iEvent,
53  const edm::EventSetup &iEventSetup,
54  MuonPathPtrs &inMpath,
55  std::vector<cmsdt::metaPrimitive> &metaPrimitives) override;
56  void run(edm::Event &iEvent,
57  const edm::EventSetup &iEventSetup,
58  MuonPathPtrs &inMpath,
59  MuonPathPtrs &outMPath) override{};
60 
61  void finish() override;
62 
63  // Other public methods
64 
65  bool hasPosRF(int wh, int sec) { return wh > 0 || (wh == 0 && sec % 4 > 1); };
66 
67  // Public attributes
68  DTGeometry const *dtGeo_;
70 
71  //shift
73  std::map<int, float> shiftinfo_;
74 
75  //shift theta
77  std::map<int, float> shiftthetainfo_;
78 
80 
81 private:
82  // Private methods
83  void analyze(MuonPathPtr &inMPath, std::vector<cmsdt::metaPrimitive> &metaPrimitives);
85  void segment_fitter(DTSuperLayerId MuonPathSLId,
86  int wires[4],
87  int t0s[4],
88  int valid[4],
89  int reduced_times[4],
90  int cell_horiz_layout[4],
91  LATCOMB_CONSTANTS latcomb_consts,
92  int xwire_mm[4],
93  int coarse_pos,
94  int coarse_offset,
95  std::vector<cmsdt::metaPrimitive> &metaPrimitives);
96  int compute_parameter(MAGNITUDE constants, int t0s[4], int DIV_SHR_BITS, int INCREASED_RES);
97  std::vector<int> getLateralityCombination(int latcomb);
98 
99  // Private attributes
100 
101  bool debug_;
102  double chi2Th_;
103  double tanPhiTh_;
108  double tanPhiThw0_;
111  std::vector<CELL_VALID_LAYOUT_CONSTANTS> LAYOUT_VALID_TO_LATCOMB_CONSTS_ENCODER;
112 
113  // global coordinates
114  std::shared_ptr<GlobalCoordsObtainer> globalcoordsobtainer_;
115 };
116 
117 #endif
std::vector< CELL_VALID_LAYOUT_CONSTANTS > LAYOUT_VALID_TO_LATCOMB_CONSTS_ENCODER
std::vector< MuonPathPtr > MuonPathPtrs
Definition: MuonPath.h:128
std::map< int, float > shiftthetainfo_
bool hasPosRF(int wh, int sec)
int iEvent
Definition: GenABIO.cc:224
void run(edm::Event &iEvent, const edm::EventSetup &iEventSetup, MuonPathPtrs &inMpath, MuonPathPtrs &outMPath) override
LATCOMB_CONSTANTS latcomb_constants[6]
MuonPathAnalyticAnalyzer(const edm::ParameterSet &pset, edm::ConsumesCollector &iC, std::shared_ptr< GlobalCoordsObtainer > &globalcoordsobtainer)
void segment_fitter(DTSuperLayerId MuonPathSLId, int wires[4], int t0s[4], int valid[4], int reduced_times[4], int cell_horiz_layout[4], LATCOMB_CONSTANTS latcomb_consts, int xwire_mm[4], int coarse_pos, int coarse_offset, std::vector< cmsdt::metaPrimitive > &metaPrimitives)
std::vector< int > getLateralityCombination(int latcomb)
void run(edm::Event &iEvent, const edm::EventSetup &iEventSetup, MuonPathPtrs &inMpath, std::vector< cmsdt::metaPrimitive > &metaPrimitives) override
void initialise(const edm::EventSetup &iEventSetup) override
edm::ESGetToken< DTGeometry, MuonGeometryRecord > dtGeomH
int cellLayout_[cmsdt::NUM_LAYERS]
void analyze(MuonPathPtr &inMPath, std::vector< cmsdt::metaPrimitive > &metaPrimitives)
std::map< int, float > shiftinfo_
std::shared_ptr< MuonPath > MuonPathPtr
Definition: MuonPath.h:127
constexpr int NUM_LAYERS
Definition: constants.h:219
tuple wires
Definition: DigiDM_cff.py:33
std::shared_ptr< GlobalCoordsObtainer > globalcoordsobtainer_
int compute_parameter(MAGNITUDE constants, int t0s[4], int DIV_SHR_BITS, int INCREASED_RES)