File indexing completed on 2025-08-05 08:09:41
0001
0002
0003
0004
0005
0006
0007
0008
0009 #include "Acts/Surfaces/RadialBounds.hpp"
0010
0011 #include "Acts/Definitions/TrackParametrization.hpp"
0012 #include "Acts/Surfaces/detail/VerticesHelper.hpp"
0013 #include "Acts/Utilities/detail/periodic.hpp"
0014
0015 #include <iomanip>
0016 #include <iostream>
0017
0018 Acts::SurfaceBounds::BoundsType Acts::RadialBounds::type() const {
0019 return SurfaceBounds::eDisc;
0020 }
0021
0022 Acts::Vector2 Acts::RadialBounds::shifted(
0023 const Acts::Vector2& lposition) const {
0024 Vector2 tmp;
0025 tmp[eBoundLoc0] = lposition[eBoundLoc0];
0026 tmp[eBoundLoc1] =
0027 detail::radian_sym(lposition[eBoundLoc1] - get(eAveragePhi));
0028 return tmp;
0029 }
0030
0031 bool Acts::RadialBounds::inside(const Acts::Vector2& lposition,
0032 const Acts::BoundaryCheck& bcheck) const {
0033 return bcheck.isInside(shifted(lposition),
0034 Vector2(get(eMinR), -get(eHalfPhiSector)),
0035 Vector2(get(eMaxR), get(eHalfPhiSector)));
0036 }
0037
0038 std::vector<Acts::Vector2> Acts::RadialBounds::vertices(
0039 unsigned int lseg) const {
0040 return detail::VerticesHelper::circularVertices(
0041 get(eMinR), get(eMaxR), get(eAveragePhi), get(eHalfPhiSector), lseg);
0042 }
0043
0044 std::ostream& Acts::RadialBounds::toStream(std::ostream& sl) const {
0045 sl << std::setiosflags(std::ios::fixed);
0046 sl << std::setprecision(7);
0047 sl << "Acts::RadialBounds: (innerRadius, outerRadius, hPhiSector, "
0048 "averagePhi) = ";
0049 sl << "(" << get(eMinR) << ", " << get(eMaxR) << ", " << get(eHalfPhiSector)
0050 << ", " << get(eAveragePhi) << ")";
0051 sl << std::setprecision(-1);
0052 return sl;
0053 }