CMS 3D CMS Logo

GeometryTranslator.h
Go to the documentation of this file.
1 #ifndef __L1TMuon_GeometryTranslator_h__
2 #define __L1TMuon_GeometryTranslator_h__
3 //
4 // Class: L1TMuon::GeometryTranslator
5 //
6 // Info: This class implements a the translations from packed bits or
7 // digi information into local or global CMS coordinates for all
8 // types of L1 trigger primitives that we want to consider for
9 // use in the integrated muon trigger.
10 //
11 // Note: This should be considered as a base class to some sort of global
12 // look-up table
13 //
14 // Author: L. Gray (FNAL)
15 // Some pieces of code lifted from: Matt Carver & Bobby Scurlock (UF)
16 //
17 
18 #include <memory>
19 
24 
25 // Forward declarations
26 namespace edm {
27  class EventSetup;
28  class ConsumesCollector;
29 } // namespace edm
30 
31 class DTGeometry;
32 class CSCGeometry;
33 class CSCLayer;
34 class RPCGeometry;
35 class GEMGeometry;
36 class ME0Geometry;
37 class MagneticField;
38 
39 namespace L1TMuon {
40 
41  // Forward declaration
42  class TriggerPrimitive;
43 
45  public:
48 
49  double calculateGlobalEta(const TriggerPrimitive&) const;
50  double calculateGlobalPhi(const TriggerPrimitive&) const;
51  double calculateBendAngle(const TriggerPrimitive&) const;
52 
54 
56 
57  const DTGeometry& getDTGeometry() const { return *_geodt; }
58  const CSCGeometry& getCSCGeometry() const { return *_geocsc; }
59  const RPCGeometry& getRPCGeometry() const { return *_georpc; }
60  const GEMGeometry& getGEMGeometry() const { return *_geogem; }
61  const ME0Geometry& getME0Geometry() const { return *_geome0; }
62 
63  const MagneticField& getMagneticField() const { return *_magfield; }
64 
65  private:
66  unsigned long long _geom_cache_id;
72 
78 
79  unsigned long long _magfield_cache_id;
82 
84  double calcME0SpecificEta(const TriggerPrimitive&) const;
85  double calcME0SpecificPhi(const TriggerPrimitive&) const;
86  double calcME0SpecificBend(const TriggerPrimitive&) const;
87 
89  double calcGEMSpecificEta(const TriggerPrimitive&) const;
90  double calcGEMSpecificPhi(const TriggerPrimitive&) const;
91  double calcGEMSpecificBend(const TriggerPrimitive&) const;
92 
94  double calcRPCSpecificEta(const TriggerPrimitive&) const;
95  double calcRPCSpecificPhi(const TriggerPrimitive&) const;
96  double calcRPCSpecificBend(const TriggerPrimitive&) const;
97 
99  double calcCSCSpecificEta(const TriggerPrimitive&) const;
100  double calcCSCSpecificPhi(const TriggerPrimitive&) const;
101  double calcCSCSpecificBend(const TriggerPrimitive&) const;
102  bool isCSCCounterClockwise(const std::unique_ptr<const CSCLayer>&) const;
103 
105  double calcDTSpecificEta(const TriggerPrimitive&) const;
106  double calcDTSpecificPhi(const TriggerPrimitive&) const;
107  double calcDTSpecificBend(const TriggerPrimitive&) const;
108  };
109 
110 } // namespace L1TMuon
111 
112 #endif
DTGeometry
Definition: DTGeometry.h:28
L1TMuon::GeometryTranslator::getME0SpecificPoint
GlobalPoint getME0SpecificPoint(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:153
L1TMuon::GeometryTranslator::_magfield_cache_id
unsigned long long _magfield_cache_id
Definition: GeometryTranslator.h:79
ESHandle.h
L1TMuon::GeometryTranslator::calcGEMSpecificPhi
double calcGEMSpecificPhi(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:201
L1TMuon::GeometryTranslator::calcME0SpecificPhi
double calcME0SpecificPhi(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:175
L1TMuon::GeometryTranslator::getCSCSpecificPoint
GlobalPoint getCSCSpecificPoint(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:240
edm
HLT enums.
Definition: AlignableModifier.h:19
L1TMuon::GeometryTranslator::calcCSCSpecificPhi
double calcCSCSpecificPhi(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:299
ME0Geometry
Definition: ME0Geometry.h:12
L1TMuon::GeometryTranslator::getGlobalPoint
GlobalPoint getGlobalPoint(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:106
CSCLayer
Definition: CSCLayer.h:24
L1TMuon::GeometryTranslator::geodtToken_
edm::ESGetToken< DTGeometry, MuonGeometryRecord > geodtToken_
Definition: GeometryTranslator.h:73
L1TMuon::GeometryTranslator::_georpc
edm::ESHandle< RPCGeometry > _georpc
Definition: GeometryTranslator.h:69
L1TMuon::GeometryTranslator::_geome0
edm::ESHandle< ME0Geometry > _geome0
Definition: GeometryTranslator.h:71
L1TMuon::GeometryTranslator::calcRPCSpecificEta
double calcRPCSpecificEta(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:221
L1TMuon::GeometryTranslator::getGEMGeometry
const GEMGeometry & getGEMGeometry() const
Definition: GeometryTranslator.h:60
L1TMuon::GeometryTranslator::calculateGlobalPhi
double calculateGlobalPhi(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:60
CSCGeometry
Definition: CSCGeometry.h:24
L1TMuon::GeometryTranslator::calcRPCSpecificPhi
double calcRPCSpecificPhi(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:225
L1TMuon::GeometryTranslator::_geogem
edm::ESHandle< GEMGeometry > _geogem
Definition: GeometryTranslator.h:70
L1TMuon::GeometryTranslator::_geocsc
edm::ESHandle< CSCGeometry > _geocsc
Definition: GeometryTranslator.h:68
L1TMuon::GeometryTranslator::calcGEMSpecificBend
double calcGEMSpecificBend(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:205
IdealMagneticFieldRecord.h
edm::ESHandle< DTGeometry >
L1TMuon::GeometryTranslator::calcCSCSpecificEta
double calcCSCSpecificEta(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:295
L1TMuon::GeometryTranslator::GeometryTranslator
GeometryTranslator(edm::ConsumesCollector)
Definition: GeometryTranslator.cc:25
L1TMuon::GeometryTranslator::getRPCGeometry
const RPCGeometry & getRPCGeometry() const
Definition: GeometryTranslator.h:59
L1TMuon::TriggerPrimitive
Definition: MuonTriggerPrimitive.h:57
Point3DBase< float, GlobalTag >
L1TMuon::GeometryTranslator::calcDTSpecificBend
double calcDTSpecificBend(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:351
L1TMuon::GeometryTranslator::calcGEMSpecificEta
double calcGEMSpecificEta(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:197
L1TMuon::GeometryTranslator::_magfield
edm::ESHandle< MagneticField > _magfield
Definition: GeometryTranslator.h:80
L1TMuon::GeometryTranslator::calcME0SpecificEta
double calcME0SpecificEta(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:171
L1TMuon::GeometryTranslator::getRPCSpecificPoint
GlobalPoint getRPCSpecificPoint(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:209
L1TMuon::GeometryTranslator::calcCSCSpecificBend
double calcCSCSpecificBend(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:303
L1TMuon::GeometryTranslator::checkAndUpdateGeometry
void checkAndUpdateGeometry(const edm::EventSetup &)
Definition: GeometryTranslator.cc:131
L1TMuon::GeometryTranslator::calculateGlobalEta
double calculateGlobalEta(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:37
edm::EventSetup
Definition: EventSetup.h:58
L1TMuon::GeometryTranslator::georpcToken_
edm::ESGetToken< RPCGeometry, MuonGeometryRecord > georpcToken_
Definition: GeometryTranslator.h:75
L1TMuon::GeometryTranslator::magfieldToken_
edm::ESGetToken< MagneticField, IdealMagneticFieldRecord > magfieldToken_
Definition: GeometryTranslator.h:81
L1TMuon
Definition: L1TMuonSubsystems.h:4
edm::ESGetToken< DTGeometry, MuonGeometryRecord >
L1TMuon::GeometryTranslator::calcDTSpecificPhi
double calcDTSpecificPhi(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:348
L1TMuon::GeometryTranslator::calcME0SpecificBend
double calcME0SpecificBend(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:179
L1TMuon::GeometryTranslator
Definition: GeometryTranslator.h:44
L1TMuon::GeometryTranslator::geome0Token_
edm::ESGetToken< ME0Geometry, MuonGeometryRecord > geome0Token_
Definition: GeometryTranslator.h:77
L1TMuon::GeometryTranslator::isCSCCounterClockwise
bool isCSCCounterClockwise(const std::unique_ptr< const CSCLayer > &) const
Definition: GeometryTranslator.cc:305
L1TMuon::GeometryTranslator::~GeometryTranslator
~GeometryTranslator()
Definition: GeometryTranslator.cc:35
L1TMuon::GeometryTranslator::getDTGeometry
const DTGeometry & getDTGeometry() const
Definition: GeometryTranslator.h:57
L1TMuon::GeometryTranslator::calcDTSpecificPoint
GlobalPoint calcDTSpecificPoint(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:314
GEMGeometry
Definition: GEMGeometry.h:24
RPCGeometry
Definition: RPCGeometry.h:20
L1TMuon::GeometryTranslator::getCSCGeometry
const CSCGeometry & getCSCGeometry() const
Definition: GeometryTranslator.h:58
EventSetup
MuonGeometryRecord.h
L1TMuon::GeometryTranslator::getME0Geometry
const ME0Geometry & getME0Geometry() const
Definition: GeometryTranslator.h:61
L1TMuon::GeometryTranslator::getMagneticField
const MagneticField & getMagneticField() const
Definition: GeometryTranslator.h:63
L1TMuon::GeometryTranslator::calcRPCSpecificBend
double calcRPCSpecificBend(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:231
L1TMuon::GeometryTranslator::geocscToken_
edm::ESGetToken< CSCGeometry, MuonGeometryRecord > geocscToken_
Definition: GeometryTranslator.h:74
MagneticField
Definition: MagneticField.h:19
L1TMuon::GeometryTranslator::calculateBendAngle
double calculateBendAngle(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:83
GlobalPoint.h
L1TMuon::GeometryTranslator::calcDTSpecificEta
double calcDTSpecificEta(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:346
edm::ConsumesCollector
Definition: ConsumesCollector.h:45
L1TMuon::GeometryTranslator::getGEMSpecificPoint
GlobalPoint getGEMSpecificPoint(const TriggerPrimitive &) const
Definition: GeometryTranslator.cc:185
L1TMuon::GeometryTranslator::_geom_cache_id
unsigned long long _geom_cache_id
Definition: GeometryTranslator.h:66
L1TMuon::GeometryTranslator::_geodt
edm::ESHandle< DTGeometry > _geodt
Definition: GeometryTranslator.h:67
L1TMuon::GeometryTranslator::geogemToken_
edm::ESGetToken< GEMGeometry, MuonGeometryRecord > geogemToken_
Definition: GeometryTranslator.h:76