ATLAS Offline Software
StripLayer.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 #ifndef MUONREADOUTGEOMETRYR4_STRIPLAYER_H
5 #define MUONREADOUTGEOMETRYR4_STRIPLAYER_H
6 
10 
11 #include <GeoModelKernel/GeoTransform.h>
12 #include <GaudiKernel/SystemOfUnits.h>
13 
14 namespace MuonGMR4{
19  class StripLayer {
20  public:
21  using TransformPtr = GeoIntrusivePtr<const GeoTransform>;
29  StripLayer(TransformPtr layerTransform,
31  const IdentifierHash hash);
38  StripLayer(TransformPtr layerTransform,
39  StripDesignPtr etaDesign,
40  StripDesignPtr phiDesign,
41  const IdentifierHash hash);
42 
45  const Amg::Transform3D& toOrigin() const;
49  const StripDesign& design(bool phiView = false) const;
51  const IdentifierHash hash() const;
56  Amg::Vector3D localStripPosition(unsigned int stripum,
57  bool phiView = false) const;
63  Amg::Vector3D localStripLeftEdge(unsigned int stripNum,
64  bool phiView = false) const;
70  Amg::Vector3D localStripRightEdge(unsigned int stripNum,
71  bool phiView = false) const;
73  bool operator<(const StripLayer& other) const;
75  bool hasPhiDesign() const;
81  Amg::Vector3D to3D(CheckVector2D&& vec, const bool phiView) const;
86  Amg::Vector2D to2D(const Amg::Vector3D& vec, const bool phiView) const;
88  void flipPhiRotation();
89  private:
99  };
103  bool operator()( const StripLayerPtr&a, const StripLayerPtr& b) const{
104  return (*a) < (*b);
105  }
106  };
107  std::ostream& operator<<(std::ostream& ostr, const StripLayer& lay);
108 }
109 
111 #endif
StripLayer.icc
GeoModel::TransientConstSharedPtr< StripDesign >
MuonGMR4::StripLayer::CheckVector2D
StripDesign::CheckVector2D CheckVector2D
Definition: StripLayer.h:76
MuonGMR4::StripLayerSorter::operator()
bool operator()(const StripLayerPtr &a, const StripLayerPtr &b) const
Definition: StripLayer.h:103
MuonGMR4::StripDesign
Definition: StripDesign.h:30
MuonGMR4::StripLayer::m_hash
IdentifierHash m_hash
Hash of the strip layer.
Definition: StripLayer.h:97
MuonGMR4::StripLayer::operator<
bool operator<(const StripLayer &other) const
Comparison operator to recycle equivalent StripLayers for multiple readout elements.
Definition: StripLayer.cxx:30
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
MuonGMR4::StripLayer::toOrigin
const Amg::Transform3D & toOrigin() const
Returns the transformation to go from the strip layer center to the origin of the Strip chamber.
MuonGMR4::StripLayer::m_phiRot
double m_phiRot
Definition: StripLayer.h:98
MuonGMR4::StripLayer::flipPhiRotation
void flipPhiRotation()
Flips the phi rotation from 90 -> -90 degrees.
Definition: StripLayer.cxx:14
deg
#define deg
Definition: SbPolyhedron.cxx:17
StripDesign.h
vec
std::vector< size_t > vec
Definition: CombinationsGeneratorTest.cxx:9
MuonGMR4::StripLayer::localStripRightEdge
Amg::Vector3D localStripRightEdge(unsigned int stripNum, bool phiView=false) const
Returns the position of the right strip edge at (negative y in the strip design description) in the l...
MuonGMR4::StripLayer::m_etaDesign
StripDesignPtr m_etaDesign
Pointer to the eta strip design.
Definition: StripLayer.h:93
MuonGMR4::StripLayer::StripLayer
StripLayer(TransformPtr layerTransform, StripDesignPtr design, const IdentifierHash hash)
Standard constructor taking the transform to decribe a strip layer, a pointer to the eta strip design...
Definition: StripLayer.cxx:17
MuonGMR4::StripLayer::to2D
Amg::Vector2D to2D(const Amg::Vector3D &vec, const bool phiView) const
Transforms a 3D vector from the strip design into a 2D vector.
GeoPrimitives.h
MuonGMR4
The ReadoutGeomCnvAlg converts the Run4 Readout geometry build from the GeoModelXML into the legacy M...
Definition: MdtCalibInput.h:19
MuonGMR4::StripLayer::TransformPtr
GeoIntrusivePtr< const GeoTransform > TransformPtr
Definition: StripLayer.h:21
MuonGMR4::StripLayer::localStripPosition
Amg::Vector3D localStripPosition(unsigned int stripum, bool phiView=false) const
Returns the position of the strip centre expressed in the frame of the local readout plane.
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
MuonGMR4::StripLayer::hasPhiDesign
bool hasPhiDesign() const
Returns whether the strip layer also describes strips in the phi direction.
MuonGMR4::StripLayer::to3D
Amg::Vector3D to3D(CheckVector2D &&vec, const bool phiView) const
Transforms the 2D vector from the strip design into a 3D vector If phi view is switched on,...
MuonGMR4::StripLayer::localStripLeftEdge
Amg::Vector3D localStripLeftEdge(unsigned int stripNum, bool phiView=false) const
Returns the position of the strip edge at (positive y in the strip design description) in the local c...
MuonGMR4::StripLayer::design
const StripDesign & design(bool phiView=false) const
Returns the underlying strip design.
plotBeamSpotMon.b
b
Definition: plotBeamSpotMon.py:76
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
MuonGMR4::StripLayer::m_transform
TransformPtr m_transform
Pointer to the GeoModelTransform
Definition: StripLayer.h:91
MuonGMR4::StripLayer
The StripLayer interfaces the 2D description of the strip plane layout with the 3D description of the...
Definition: StripLayer.h:19
a
TList * a
Definition: liststreamerinfos.cxx:10
InDetDD::other
@ other
Definition: InDetDD_Defs.h:16
TransientConstSharedPtr.h
MuonGMR4::StripLayer::m_phiDesign
StripDesignPtr m_phiDesign
Pointer to the phi strip design.
Definition: StripLayer.h:95
MuonGMR4::StripLayer::hash
const IdentifierHash hash() const
Returns the hash of the strip layer.
MuonGMR4::StripLayerSorter
Helper struct to share strip layer instances across the readout elements.
Definition: StripLayer.h:102
IdentifierHash
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
Definition: IdentifierHash.h:25
MuonGMR4::operator<<
std::ostream & operator<<(std::ostream &ostr, const Chamber::defineArgs &args)
Definition: Chamber.cxx:15
MuonGMR4::StripDesign::CheckVector2D
std::optional< Amg::Vector2D > CheckVector2D
Definition: StripDesign.h:82