29 double cR = cBounds.get(CylinderBounds::eR);
31 throw(std::invalid_argument(
32 "CylinderVolumeBounds: invalid extrusion thickness."));
36 m_values[eHalfLengthZ] = cBounds.get(CylinderBounds::eHalfLengthZ);
37 m_values[eHalfPhiSector] = cBounds.get(CylinderBounds::eHalfPhiSector);
38 m_values[eAveragePhi] = cBounds.get(CylinderBounds::eAveragePhi);
46 throw(std::invalid_argument(
47 "CylinderVolumeBounds: invalid extrusion thickness."));
49 m_values[eMinR] = rBounds.get(RadialBounds::eMinR);
50 m_values[eMaxR] = rBounds.get(RadialBounds::eMaxR);
52 m_values[eHalfPhiSector] = rBounds.get(RadialBounds::eHalfPhiSector);
53 m_values[eAveragePhi] = rBounds.get(RadialBounds::eAveragePhi);
57 std::vector<std::shared_ptr<const Acts::Surface>>
60 std::vector<std::shared_ptr<const Surface>> rSurfaces;
65 (transformPtr ==
nullptr) ? Transform3D::Identity() : (*transformPtr);
66 auto trfShared = std::make_shared<Transform3D>(
transform);
69 Vector3D cylCenter(transform.translation());
75 rSurfaces.push_back(Surface::makeShared<DiscSurface>(
76 std::shared_ptr<const Transform3D>(tTransform),
m_discBounds));
80 rSurfaces.push_back(Surface::makeShared<DiscSurface>(
81 std::shared_ptr<const Transform3D>(tTransform),
m_discBounds));
100 rSurfaces.push_back(Surface::makeShared<PlaneSurface>(
107 rSurfaces.push_back(Surface::makeShared<PlaneSurface>(
115 m_innerCylinderBounds = std::make_shared<const CylinderBounds>(
116 get(eMinR),
get(eHalfLengthZ),
get(eHalfPhiSector),
get(eAveragePhi));
118 m_outerCylinderBounds = std::make_shared<const CylinderBounds>(
119 get(eMaxR),
get(eHalfLengthZ),
get(eHalfPhiSector),
get(eAveragePhi));
120 m_discBounds = std::make_shared<const RadialBounds>(
121 get(eMinR),
get(eMaxR),
get(eHalfPhiSector),
get(eAveragePhi));
124 m_sectorPlaneBounds = std::make_shared<const RectangleBounds>(
125 0.5 * (
get(eMaxR) -
get(eMinR)),
get(eHalfLengthZ));
130 return dumpT<std::ostream>(sl);
135 const Volume* entity)
const {
139 if (
get(eHalfPhiSector) >
M_PI / 2.) {
143 xmin = xmax * std::cos(
get(eHalfPhiSector));
146 ymax =
get(eMaxR) * std::sin(
get(eHalfPhiSector));
149 xmin =
get(eMinR) * std::cos(
get(eHalfPhiSector));
152 Vector3D vmin(xmin, ymin, -
get(eHalfLengthZ));
153 Vector3D vmax(xmax, ymax,
get(eHalfLengthZ));
157 return trf ==
nullptr ?
box :
box.transformed(*trf);