ATLAS Offline Software
Loading...
Searching...
No Matches
L1Muon::L1MM::MMT_Hit Class Reference

One MM strip hit as seen by the MM trigger processor. More...

#include <MMT_Hit.h>

Collaboration diagram for L1Muon::L1MM::MMT_Hit:

Public Member Functions

 MMT_Hit (const Identifier &id, const float stripTime, const int BC, const MuonGMR4::MuonDetectorManager *detManager, const ActsTrk::GeometryContext &gctx)
 ~MMT_Hit ()=default
int getART () const
int getAge () const
int getBC () const
int getChannel () const
int getGlobalStrip () const
 Strip index on the sector layer: (|stationEta|-1)*kStripsEta1 + channel.
int getPlane () const
char getSector () const
double getRZSlope () const
int getVMM () const
double getShift () const
int getStationEta () const
int getStationPhi () const
int getSectorPhi () const
double getR () const
double getRp () const
double getZ () const
double getPitchOverZ () const
float getTime () const
LayerType getType () const
bool isX () const
bool isU () const
bool isV () const
bool infSlope () const
double getRefR0 () const
 radius of the bottom edge of the eta=1 module
double getRefZ0 () const
 z of the first active strip, multilayer 1, gas gap 1
void setAge (int age)

Private Attributes

double m_RZslope {-1}
double m_Rp {-1}
double m_Z {-1}
double m_R {-1}
double m_PitchOverZ {-1}
double m_shift {-1}
double m_refR0 {-1}
double m_refZ0 {-1}
float m_time {-1.f}
int m_VMM_chip {-1}
int m_ART_ASIC {-1}
int m_plane {-1}
int m_station_eta {0}
int m_station_phi {0}
int m_sector_phi {0}
int m_strip {-1}
int m_globalStrip {-1}
int m_BC_time {-1}
int m_age {-1}
char m_sector {'-'}
LayerType m_type {LayerType::Undefined}

Detailed Description

One MM strip hit as seen by the MM trigger processor.

Built from one MM digit (strip identifier, strip time and the bunch crossing derived from it). Everything is computed once in the constructor:

  • the identifier fields (station eta/phi, sector, strip) and the plane 0-7, (multilayer-1)*4 + gasGap-1;
  • the layer type, X, U or V, from the stereo angle of the strip design of the layer;
  • the electronics mapping: the strip index on the sector layer, and the VMM (0-127) and ART ASIC (0-3) of the strip;
  • from the Phase-II geometry (with the alignment of the geometry context): the global R and Z of the strip centre, the slope R/Z, the strip pitch over Z, and the shift, i.e. the slope origin of the road windows of MMT_Road for this hit. Only the age changes afterwards (setAge), when the hit is copied into a road.

The caller must guarantee that the strip is inside the active range of its layer: the Phase-II strip position of a strip outside it is undefined.

Definition at line 39 of file Muon/L1MuonNSW/src/MMT_Hit.h.

Constructor & Destructor Documentation

◆ MMT_Hit()

MMT_Hit::MMT_Hit ( const Identifier & id,
const float stripTime,
const int BC,
const MuonGMR4::MuonDetectorManager * detManager,
const ActsTrk::GeometryContext & gctx )

Definition at line 12 of file Muon/L1MuonNSW/src/MMT_Hit.cxx.

15 : m_time(stripTime),
16 m_BC_time(BC), m_age(BC)
17 {
18 const Muon::IMuonIdHelperSvc* idHelperSvc = detManager->idHelperSvc();
19 const MmIdHelper& idHelper = idHelperSvc->mmIdHelper();
20 const std::string stationName = idHelperSvc->chamberNameString(id);
21 m_station_eta = idHelperSvc->stationEta(id);
22 m_station_phi = idHelperSvc->stationPhi(id);
23 m_sector_phi = idHelperSvc->sector(id);
24 m_strip = idHelper.channel(id);
25 m_sector = stationName[2]; // 'L' for MML, 'S' for MMS
26 m_plane = (idHelper.multilayer(id)-1)*4 + idHelper.gasGap(id)-1;
27
28 const MuonGMR4::MmReadoutElement* readout = detManager->getMmReadoutElement(id);
29 const MuonGMR4::StripDesign& design = readout->stripLayer(id).design();
30
31 // Layer type from the strip design: X layers have no stereo angle, U layers +1.5 deg, V layers -1.5 deg
32 if (!design.hasStereoAngle()) m_type = LayerType::X;
33 else m_type = (design.stereoAngle() > 0.) ? LayerType::U : LayerType::V;
34
35 // Strip index on the sector layer (the channel restarts at each module, up to 5120 for |stationEta| = 1)
37
38 // region represent the index of the MMFE8 board in the plane
39 const int region = m_globalStrip / kStripsPerMMFE8;
40
41 // map of mmfe8s layer,radius(MMFE8 index on sector)
42 std::array<std::array<unsigned int, kMMFE8sPerLayer>, kPlanes> mmfe8s{};
43 // loop on layers
44 for( unsigned int L=0; L<kPlanes; L++){
45 // loop on pcbs
46 for(unsigned int p=1; p<=kPCBsPerLayer; p++){
47 // loop on sides
48 for(unsigned int s=0; s<2; s++){ //loop on 0 (Left) and 1 (Right), same convention used also later
49 unsigned int R = (L%2==s) ? (p-1)*2 : (p-1)*2+1;
50 mmfe8s[L][R]=s;
51 }
52 }
53 }
54
55 m_VMM_chip = m_globalStrip / kStripsPerVMM; // index of the VMM chip on the layer
56 // art asic id: radial half of the layer (0 inner, 1 outer), swapped on the second gas-gap pair
57 const int half = region / kMMFE8sPerHalfLayer;
58 if(!((m_plane/2)%2)){
59 if (mmfe8s[m_plane][region]==1){ //Right
60 m_ART_ASIC = 1-half;
61 }else{
62 m_ART_ASIC = half;
63 }
64 }else{
65 if (mmfe8s[m_plane][region]==0){ //Left
66 m_ART_ASIC = 1-half;
67 }else{
68 m_ART_ASIC = half;
69 }
70 }
71
72 // if Left side add 2 to the ART Asic Index
73 if(mmfe8s[m_plane][region]==0){
74 m_ART_ASIC+=2;
75 }
76
77 // Geometry: global position of the strip centre, with the alignment of the geometry context
78 const Amg::Vector3D globalPos = readout->stripPosition(gctx, id);
79 m_R = globalPos.perp();
80 m_Z = globalPos.z();
81 m_PitchOverZ = design.stripPitch()/m_Z;
82 m_RZslope = m_R / m_Z;
83
84 // Reference: the eta=1 module of this sector type (MML/MMS), phi=1, side A, multilayer 1, gas gap 1
85 const Identifier refId = idHelper.channelID(stationName, 1, 1, 1, 1, 1);
86 const MuonGMR4::MmReadoutElement* roEl = detManager->getMmReadoutElement(refId);
87 const double distanceFromZAxis = roEl->center(gctx).perp() - 0.5*roEl->moduleHeight();
88 const int firstActiveStrip = roEl->firstStrip(roEl->layerHash(refId));
89 const Identifier refStripId = idHelper.channelID(stationName, 1, 1, 1, 1, firstActiveStrip);
90 const Amg::Vector3D refPos = roEl->stripPosition(gctx, refStripId);
91
92 m_refR0 = distanceFromZAxis;
93 m_refZ0 = refPos.z();
94
95 double index = std::round((std::abs(m_RZslope)-0.1)/5e-04); // 0.0005 is approx. the step in slope achievable with a road size of 8 strips
96 m_Rp = distanceFromZAxis + (0.1 + index*((0.6 - 0.1)/1000.))*(std::abs(m_Z) - refPos.z());
97 m_shift = m_Rp / m_Z;
98}
Identifier channelID(int stationName, int stationEta, int stationPhi, int multilayer, int gasGap, int channel) const
int channel(const Identifier &id) const override
int gasGap(const Identifier &id) const override
get the hashes
int multilayer(const Identifier &id) const
double moduleHeight() const
Returns the height along the z-axis.
const StripLayer & stripLayer(const Identifier &measId) const
IdentifierHash layerHash(const Identifier &measId) const override final
The layer hash removes the bits from the IdentifierHash corresponding to the measurement's channel nu...
unsigned int firstStrip(const IdentifierHash &layerHash) const
Returns the first active strip.
Amg::Vector3D stripPosition(const ActsTrk::GeometryContext &ctx, const Identifier &measId) const
Returns the position of the strip center.
const Muon::IMuonIdHelperSvc * idHelperSvc() const
Returns a pointer to the central MuonIdHelperSvc.
Amg::Vector3D center(const ActsTrk::GeometryContext &ctx) const
Returns the geometrical center point of the readout element.
double stereoAngle() const
Returns the value of the stereo angle.
double stripPitch() const
Distance between two adjacent strips.
bool hasStereoAngle() const
Returns whether a stereo angle is defined.
const StripDesign & design(bool phiView=false) const
Returns the underlying strip design.
virtual const MmIdHelper & mmIdHelper() const =0
access to CscIdHelper
virtual int stationPhi(const Identifier &id) const =0
Return stationPhi for all technologies.
virtual int stationEta(const Identifier &id) const =0
Return stationEta for all technologies.
virtual std::string chamberNameString(const Identifier &id) const =0
print chamber name to string
virtual int sector(const Identifier &id) const =0
return sector number 1-16, odd=large, even=small
Eigen::Matrix< double, 3, 1 > Vector3D
double R(const INavigable4Momentum *p1, const double v_eta, const double v_phi)
str index
Definition DeMoScan.py:362
constexpr int kStripsEta1
Nominal strips of one layer of the |stationEta| = 1 module (5120).
constexpr int kStripsPerVMM
Strips read out by one VMM.
constexpr int kStripsPerMMFE8
Strips read out by one MMFE8 board.
constexpr int kPlanes
Planes of the MM octuplet (2 multilayers x 4 gas gaps).
constexpr int kMMFE8sPerHalfLayer
MMFE8 boards in each radial half of the layer (inner: 0-7, outer: 8-15).
constexpr int kPCBsPerLayer
PCBs of one sector layer (2 MMFE8 boards per PCB).

◆ ~MMT_Hit()

L1Muon::L1MM::MMT_Hit::~MMT_Hit ( )
default

Member Function Documentation

◆ getAge()

int L1Muon::L1MM::MMT_Hit::getAge ( ) const
inline

Definition at line 49 of file Muon/L1MuonNSW/src/MMT_Hit.h.

49{ return m_age; }

◆ getART()

int L1Muon::L1MM::MMT_Hit::getART ( ) const
inline

Definition at line 48 of file Muon/L1MuonNSW/src/MMT_Hit.h.

48{ return m_ART_ASIC; }

◆ getBC()

int L1Muon::L1MM::MMT_Hit::getBC ( ) const
inline

Definition at line 50 of file Muon/L1MuonNSW/src/MMT_Hit.h.

50{ return m_BC_time; }

◆ getChannel()

int L1Muon::L1MM::MMT_Hit::getChannel ( ) const
inline

Definition at line 51 of file Muon/L1MuonNSW/src/MMT_Hit.h.

51{ return m_strip; }

◆ getGlobalStrip()

int L1Muon::L1MM::MMT_Hit::getGlobalStrip ( ) const
inline

Strip index on the sector layer: (|stationEta|-1)*kStripsEta1 + channel.

Definition at line 53 of file Muon/L1MuonNSW/src/MMT_Hit.h.

53{ return m_globalStrip; }

◆ getPitchOverZ()

double L1Muon::L1MM::MMT_Hit::getPitchOverZ ( ) const
inline

Definition at line 65 of file Muon/L1MuonNSW/src/MMT_Hit.h.

65{ return m_PitchOverZ; }

◆ getPlane()

int L1Muon::L1MM::MMT_Hit::getPlane ( ) const
inline

Definition at line 54 of file Muon/L1MuonNSW/src/MMT_Hit.h.

54{ return m_plane; }

◆ getR()

double L1Muon::L1MM::MMT_Hit::getR ( ) const
inline

Definition at line 62 of file Muon/L1MuonNSW/src/MMT_Hit.h.

62{ return m_R; }

◆ getRefR0()

double L1Muon::L1MM::MMT_Hit::getRefR0 ( ) const
inline

radius of the bottom edge of the eta=1 module

Definition at line 75 of file Muon/L1MuonNSW/src/MMT_Hit.h.

75{ return m_refR0; }

◆ getRefZ0()

double L1Muon::L1MM::MMT_Hit::getRefZ0 ( ) const
inline

z of the first active strip, multilayer 1, gas gap 1

Definition at line 77 of file Muon/L1MuonNSW/src/MMT_Hit.h.

77{ return m_refZ0; }

◆ getRp()

double L1Muon::L1MM::MMT_Hit::getRp ( ) const
inline

Definition at line 63 of file Muon/L1MuonNSW/src/MMT_Hit.h.

63{ return m_Rp; }

◆ getRZSlope()

double L1Muon::L1MM::MMT_Hit::getRZSlope ( ) const
inline

Definition at line 56 of file Muon/L1MuonNSW/src/MMT_Hit.h.

56{ return m_RZslope; }

◆ getSector()

char L1Muon::L1MM::MMT_Hit::getSector ( ) const
inline

Definition at line 55 of file Muon/L1MuonNSW/src/MMT_Hit.h.

55{ return m_sector; }

◆ getSectorPhi()

int L1Muon::L1MM::MMT_Hit::getSectorPhi ( ) const
inline

Definition at line 61 of file Muon/L1MuonNSW/src/MMT_Hit.h.

61{ return m_sector_phi; }

◆ getShift()

double L1Muon::L1MM::MMT_Hit::getShift ( ) const
inline

Definition at line 58 of file Muon/L1MuonNSW/src/MMT_Hit.h.

58{ return m_shift; }

◆ getStationEta()

int L1Muon::L1MM::MMT_Hit::getStationEta ( ) const
inline

Definition at line 59 of file Muon/L1MuonNSW/src/MMT_Hit.h.

59{ return m_station_eta; }

◆ getStationPhi()

int L1Muon::L1MM::MMT_Hit::getStationPhi ( ) const
inline

Definition at line 60 of file Muon/L1MuonNSW/src/MMT_Hit.h.

60{ return m_station_phi; }

◆ getTime()

float L1Muon::L1MM::MMT_Hit::getTime ( ) const
inline

Definition at line 66 of file Muon/L1MuonNSW/src/MMT_Hit.h.

66{ return m_time; }

◆ getType()

LayerType L1Muon::L1MM::MMT_Hit::getType ( ) const
inline

Definition at line 67 of file Muon/L1MuonNSW/src/MMT_Hit.h.

67{ return m_type; }

◆ getVMM()

int L1Muon::L1MM::MMT_Hit::getVMM ( ) const
inline

Definition at line 57 of file Muon/L1MuonNSW/src/MMT_Hit.h.

57{ return m_VMM_chip; }

◆ getZ()

double L1Muon::L1MM::MMT_Hit::getZ ( ) const
inline

Definition at line 64 of file Muon/L1MuonNSW/src/MMT_Hit.h.

64{ return m_Z; }

◆ infSlope()

bool L1Muon::L1MM::MMT_Hit::infSlope ( ) const
inline

Definition at line 71 of file Muon/L1MuonNSW/src/MMT_Hit.h.

71{ return std::isinf(m_RZslope); }

◆ isU()

bool L1Muon::L1MM::MMT_Hit::isU ( ) const
inline

Definition at line 69 of file Muon/L1MuonNSW/src/MMT_Hit.h.

69{ return m_type == LayerType::U; }

◆ isV()

bool L1Muon::L1MM::MMT_Hit::isV ( ) const
inline

Definition at line 70 of file Muon/L1MuonNSW/src/MMT_Hit.h.

70{ return m_type == LayerType::V; }

◆ isX()

bool L1Muon::L1MM::MMT_Hit::isX ( ) const
inline

Definition at line 68 of file Muon/L1MuonNSW/src/MMT_Hit.h.

68{ return m_type == LayerType::X; }

◆ setAge()

void L1Muon::L1MM::MMT_Hit::setAge ( int age)
inline

Definition at line 80 of file Muon/L1MuonNSW/src/MMT_Hit.h.

80{ m_age = age; }

Member Data Documentation

◆ m_age

int L1Muon::L1MM::MMT_Hit::m_age {-1}
private

Definition at line 101 of file Muon/L1MuonNSW/src/MMT_Hit.h.

101{-1};

◆ m_ART_ASIC

int L1Muon::L1MM::MMT_Hit::m_ART_ASIC {-1}
private

Definition at line 93 of file Muon/L1MuonNSW/src/MMT_Hit.h.

93{-1};

◆ m_BC_time

int L1Muon::L1MM::MMT_Hit::m_BC_time {-1}
private

Definition at line 100 of file Muon/L1MuonNSW/src/MMT_Hit.h.

100{-1};

◆ m_globalStrip

int L1Muon::L1MM::MMT_Hit::m_globalStrip {-1}
private

Definition at line 99 of file Muon/L1MuonNSW/src/MMT_Hit.h.

99{-1};

◆ m_PitchOverZ

double L1Muon::L1MM::MMT_Hit::m_PitchOverZ {-1}
private

Definition at line 87 of file Muon/L1MuonNSW/src/MMT_Hit.h.

87{-1};

◆ m_plane

int L1Muon::L1MM::MMT_Hit::m_plane {-1}
private

Definition at line 94 of file Muon/L1MuonNSW/src/MMT_Hit.h.

94{-1};

◆ m_R

double L1Muon::L1MM::MMT_Hit::m_R {-1}
private

Definition at line 86 of file Muon/L1MuonNSW/src/MMT_Hit.h.

86{-1};

◆ m_refR0

double L1Muon::L1MM::MMT_Hit::m_refR0 {-1}
private

Definition at line 89 of file Muon/L1MuonNSW/src/MMT_Hit.h.

89{-1};

◆ m_refZ0

double L1Muon::L1MM::MMT_Hit::m_refZ0 {-1}
private

Definition at line 90 of file Muon/L1MuonNSW/src/MMT_Hit.h.

90{-1};

◆ m_Rp

double L1Muon::L1MM::MMT_Hit::m_Rp {-1}
private

Definition at line 84 of file Muon/L1MuonNSW/src/MMT_Hit.h.

84{-1};

◆ m_RZslope

double L1Muon::L1MM::MMT_Hit::m_RZslope {-1}
private

Definition at line 83 of file Muon/L1MuonNSW/src/MMT_Hit.h.

83{-1};

◆ m_sector

char L1Muon::L1MM::MMT_Hit::m_sector {'-'}
private

Definition at line 102 of file Muon/L1MuonNSW/src/MMT_Hit.h.

102{'-'};

◆ m_sector_phi

int L1Muon::L1MM::MMT_Hit::m_sector_phi {0}
private

Definition at line 97 of file Muon/L1MuonNSW/src/MMT_Hit.h.

97{0};

◆ m_shift

double L1Muon::L1MM::MMT_Hit::m_shift {-1}
private

Definition at line 88 of file Muon/L1MuonNSW/src/MMT_Hit.h.

88{-1};

◆ m_station_eta

int L1Muon::L1MM::MMT_Hit::m_station_eta {0}
private

Definition at line 95 of file Muon/L1MuonNSW/src/MMT_Hit.h.

95{0};

◆ m_station_phi

int L1Muon::L1MM::MMT_Hit::m_station_phi {0}
private

Definition at line 96 of file Muon/L1MuonNSW/src/MMT_Hit.h.

96{0};

◆ m_strip

int L1Muon::L1MM::MMT_Hit::m_strip {-1}
private

Definition at line 98 of file Muon/L1MuonNSW/src/MMT_Hit.h.

98{-1};

◆ m_time

float L1Muon::L1MM::MMT_Hit::m_time {-1.f}
private

Definition at line 91 of file Muon/L1MuonNSW/src/MMT_Hit.h.

91{-1.f};

◆ m_type

LayerType L1Muon::L1MM::MMT_Hit::m_type {LayerType::Undefined}
private

◆ m_VMM_chip

int L1Muon::L1MM::MMT_Hit::m_VMM_chip {-1}
private

Definition at line 92 of file Muon/L1MuonNSW/src/MMT_Hit.h.

92{-1};

◆ m_Z

double L1Muon::L1MM::MMT_Hit::m_Z {-1}
private

Definition at line 85 of file Muon/L1MuonNSW/src/MMT_Hit.h.

85{-1};

The documentation for this class was generated from the following files: