9 #include <boost/test/data/test_case.hpp>
10 #include <boost/test/tools/output_test_stream.hpp>
11 #include <boost/test/unit_test.hpp>
25 using namespace Acts::UnitLiterals;
31 using Propagator = Propagator<EigenStepper<ConstantBField>>;
32 using Linearizer = HelicalTrackLinearizer<Propagator>;
43 std::uniform_real_distribution<>
d0Dist(-0.01
_mm, 0.01
_mm);
45 std::uniform_real_distribution<>
z0Dist(-0.2
_mm, 0.2
_mm);
53 std::uniform_real_distribution<>
qDist(-1, 1);
57 std::uniform_real_distribution<>
resAngDist(0., 0.1);
59 std::uniform_real_distribution<>
resQoPDist(-0.01, 0.01);
69 unsigned int nTests = 10;
73 std::mt19937 gen(mySeed);
82 auto propagator = std::make_shared<Propagator>(
stepper);
89 std::shared_ptr<PerigeeSurface> perigeeSurface =
90 Surface::makeShared<PerigeeSurface>(
Vector3D(0., 0., 0.));
95 for (
unsigned int i = 0; i < nTests; ++i) {
97 std::cout <<
"Test " << i + 1 << std::endl;
100 double q =
qDist(gen) < 0 ? -1. : 1.;
109 std::cout <<
"Creating track parameters: " << paramVec << std::endl;
122 covMat << res_d0 * res_d0, 0., 0., 0., 0., 0., 0., res_z0 * res_z0, 0., 0.,
123 0., 0., 0., 0., res_ph * res_ph, 0., 0., 0., 0., 0., 0.,
124 res_th * res_th, 0., 0., 0., 0., 0., 0., res_qp * res_qp, 0., 0., 0.,
148 KalmanVertexUpdater::updateVertexWithTrack<BoundParameters>(vtx, trkAtVtx);
151 std::cout <<
"Old vertex position: " << vtxPos << std::endl;
152 std::cout <<
"New vertex position: " << vtx.position() << std::endl;
155 double oldDistance = vtxPos.norm();
156 double newDistance = vtx.position().norm();
159 std::cout <<
"Old distance: " << oldDistance << std::endl;
160 std::cout <<
"New distance: " << newDistance << std::endl;
164 BOOST_CHECK(newDistance < oldDistance);
170 BOOST_CHECK(vtx.tracks().size() == 0);