9 #include <boost/test/data/test_case.hpp>
10 #include <boost/test/tools/output_test_stream.hpp>
11 #include <boost/test/unit_test.hpp>
27 namespace tt = boost::test_tools;
28 using namespace Acts::UnitLiterals;
51 auto rb = std::make_shared<RectangleBounds>(1
_m, 1
_m);
52 auto aPlane = Surface::makeShared<PlaneSurface>(
53 std::make_shared<Transform3D>(
at), std::move(
rb));
56 auto db = std::make_shared<RadialBounds>(0.2_m, 1.2_m);
57 auto aDisc = Surface::makeShared<DiscSurface>(std::make_shared<Transform3D>(
at),
61 auto cb = std::make_shared<CylinderBounds>(10
_m, 100
_m);
62 auto aCylinder = Surface::makeShared<CylinderSurface>(
63 std::make_shared<Transform3D>(
at), std::move(
cb));
66 auto aStraw = Surface::makeShared<StrawSurface>(
67 std::make_shared<Transform3D>(
at), 50
_cm, 2
_m);
75 template <
typename surface_t>
79 double cosPhi = std::cos(phi);
80 double sinPhi = std::sin(phi);
81 double cosTheta = std::cos(theta);
82 double sinTheta = std::sin(theta);
84 Vector3D direction(cosPhi * sinTheta, sinPhi * sinTheta, cosTheta);
94 benchmark_surface_intersections,
97 bdata::distribution = std::uniform_real_distribution<>(-
M_PI,
M_PI))) ^
100 std::uniform_real_distribution<>(-0.3, 0.3))) ^
105 std::cout << std::endl
106 <<
"Benchmarking theta=" <<
theta <<
", phi=" <<
phi <<
"..."
109 std::cout <<
"- Plane: "
114 std::cout <<
"- Disc: " << intersectionTest<DiscSurface>(*
aDisc,
phi,
theta)
118 std::cout <<
"- Cylinder: "
123 std::cout <<
"- Straw: "