27 double ros =
perp(gpos);
29 bool insideR = (ros >=
get(
eMinR) - tol) && (ros <=
get(
eMaxR) + tol);
32 if (!insideR || !insideZ) {
38 bool insideRInner = ros <=
get(
eMedR) - tol;
41 return !insideRInner || !insideZInner;
44 std::vector<std::shared_ptr<const Acts::Surface>>
47 std::vector<std::shared_ptr<const Acts::Surface>> surfaces;
50 std::shared_ptr<const Transform3D> trf;
51 if (transform !=
nullptr) {
52 trf = std::make_shared<const Transform3D>(*transform);
54 trf = std::make_shared<const Transform3D>(Transform3D::Identity());
57 if (
get(eMinR) == 0.) {
65 std::make_shared<CylinderBounds>(
get(eMaxR),
get(eHalfLengthZ));
66 auto outer = Surface::makeShared<CylinderSurface>(trf, outerBounds);
70 auto ctr_innerBounds =
71 std::make_shared<CylinderBounds>(
get(eMedR),
get(eHalfLengthZcutout));
72 auto ctr_inner = Surface::makeShared<CylinderSurface>(trf, ctr_innerBounds);
76 double hlChoke = (
get(eHalfLengthZ) -
get(eHalfLengthZcutout)) * 0.5;
77 double zChoke =
get(eHalfLengthZcutout) + hlChoke;
79 if (
get(eMinR) > 0.) {
80 auto posChokeTrf = std::make_shared<const Transform3D>(
83 Surface::makeShared<CylinderSurface>(posChokeTrf,
get(eMinR), hlChoke);
84 surfaces.at(
index7) = posInner;
86 auto negChokeTrf = std::make_shared<const Transform3D>(
89 Surface::makeShared<CylinderSurface>(negChokeTrf,
get(eMinR), hlChoke);
90 surfaces.at(
index6) = negInner;
94 auto posOutDiscTrf = std::make_shared<const Transform3D>(
97 Surface::makeShared<DiscSurface>(posOutDiscTrf,
get(eMinR),
get(eMaxR));
100 auto negOutDiscTrf = std::make_shared<const Transform3D>(
104 Surface::makeShared<DiscSurface>(negOutDiscTrf,
get(eMinR),
get(eMaxR));
108 auto posInDiscTrf = std::make_shared<const Transform3D>(
111 Surface::makeShared<DiscSurface>(posInDiscTrf,
get(eMinR),
get(eMedR));
112 surfaces.at(
index5) = posInDisc;
114 auto negInDiscTrf = std::make_shared<const Transform3D>(
118 Surface::makeShared<DiscSurface>(negInDiscTrf,
get(eMinR),
get(eMedR));
119 surfaces.at(
index4) = negInDisc;
132 vmax = {
get(eMaxR),
get(eMaxR),
get(eHalfLengthZ)};
133 vmin = {-
get(eMaxR), -
get(eMaxR), -
get(eHalfLengthZ)};
137 return trf ==
nullptr ? box : box.
transformed(*trf);
141 std::ostream& sl)
const {
142 sl <<
"Acts::CutoutCylinderVolumeBounds(\n";
143 sl <<
"rmin = " <<
get(eMinR) <<
" rmed = " <<
get(eMedR)
144 <<
" rmax = " <<
get(eMaxR) <<
"\n";
145 sl <<
"dz1 = " <<
get(eHalfLengthZ) <<
" dz2 = " <<
get(eHalfLengthZcutout);