53 :
54 GeoVDetectorElement{detElem.getMaterialGeom()},
56 m_type{detElem.
isPixel() ? DetectorType::Pixel : DetectorType::Sct},
59{
60
61
63
65
66
68
69 const InDetDD::SiDetectorDesign &design = detElem.
design();
72
73 auto rectangleBounds = std::make_shared<const Acts::RectangleBounds>(hlX, hlY);
74
76 m_surface = Acts::Surface::makeShared<Acts::PlaneSurface>(rectangleBounds, *
this);
77
79
80 const InDetDD::SiDetectorDesign &design = detElem.
design();
81
85
86 auto trapezoidBounds =
87 std::make_shared<const Acts::TrapezoidBounds>(minHlX, maxHlX, hlY);
88
90
91 m_surface = Acts::Surface::makeShared<Acts::PlaneSurface>(trapezoidBounds, *
this);
92
93
95
96 const InDetDD::SiDetectorDesign &design = detElem.
design();
97 const auto *annulus = dynamic_cast<const InDetDD::StripStereoAnnulusDesign *>(&design);
98 if (annulus == nullptr) {
99 throw std::domain_error("ActsDetectorElement got inconsistent surface");
100 }
101
102 double phi = annulus->phiWidth();
103 double phiS = annulus->stereo();
104 double R = annulus->waferCentreR();
105 double maxR = annulus->maxR();
106 double minR = annulus->minR();
107
108
109 double phiAvg = 0;
110
111 double phiMax =
phi / 2.;
112 double phiMin = -phiMax;
113
114
116 R * std::sin(-phiS));
117
118 auto annulusBounds = std::make_shared<Acts::AnnulusBounds>(
119 minR, maxR, phiMin, phiMax, originStripXYRotated, phiAvg);
121
122 m_surface = Acts::Surface::makeShared<Acts::DiscSurface>(annulusBounds, *
this);
123
124 } else {
125 std::cout << boundsType << std::endl;
126 throw std::domain_error("ActsDetectorElement does not support this surface type");
127 }
128}
constexpr double length_unit
Scalar phi() const
phi method
Identifier m_explicitIdentifier
double m_thickness
Thickness of this detector element.
std::shared_ptr< const Acts::SurfaceBounds > m_bounds
Boundaries of the detector element.
std::shared_ptr< Acts::Surface > m_surface
Corresponding Surface.
const GeoVDetectorElement * m_detElement
Detector element as variant.
virtual double maxWidth() const =0
Method to calculate maximum width of a module.
virtual double minWidth() const =0
Method to calculate minimum width of a module.
virtual double length() const =0
Method to calculate length of a module.
virtual double width() const =0
Method to calculate average width of a module.
virtual const SiDetectorDesign & design() const override final
access to the local description (inline):
virtual IdentifierHash identifyHash() const override final
identifier hash (inline)
virtual const Trk::SurfaceBounds & bounds() const override final
Return the boundaries of the element.
virtual Identifier identify() const override final
identifier of this detector element (inline)
virtual BoundsType type() const =0
Return the bounds type - for persistency optimization.
Eigen::Matrix< double, 2, 1 > Vector2D
double R(const INavigable4Momentum *p1, const double v_eta, const double v_phi)