9 #include <boost/test/data/test_case.hpp>
10 #include <boost/test/tools/output_test_stream.hpp>
11 #include <boost/test/unit_test.hpp>
26 using namespace Acts::UnitLiterals;
32 using Propagator = Propagator<EigenStepper<ConstantBField>>;
33 using Linearizer = HelicalTrackLinearizer<Propagator>;
40 std::uniform_real_distribution<>
vXYDist(-0.1_mm, 0.1_mm);
42 std::uniform_real_distribution<>
vZDist(-20_mm, 20_mm);
44 std::uniform_real_distribution<>
d0Dist(-0.01_mm, 0.01_mm);
46 std::uniform_real_distribution<>
z0Dist(-0.2_mm, 0.2_mm);
48 std::uniform_real_distribution<>
pTDist(0.4_GeV, 10_GeV);
54 std::uniform_real_distribution<>
qDist(-1, 1);
56 std::uniform_real_distribution<>
resIPDist(0., 100_um);
58 std::uniform_real_distribution<>
resAngDist(0., 0.1);
60 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);
87 IPEstimator ip3dEst(ip3dEstConfig);
97 std::shared_ptr<PerigeeSurface> perigeeSurface =
98 Surface::makeShared<PerigeeSurface>(
Vector3D(0., 0., 0.));
104 for (
unsigned int i = 0; i < nTests; ++i) {
106 double q =
qDist(gen) < 0 ? -1. : 1.;
115 std::cout <<
"Creating track parameters: " << paramVec << std::endl;
128 covMat << res_d0 * res_d0, 0., 0., 0., 0., 0., 0., res_z0 * res_z0, 0., 0.,
129 0., 0., 0., 0., res_ph * res_ph, 0., 0., 0., 0., 0., 0.,
130 res_th * res_th, 0., 0., 0., 0., 0., 0., res_qp * res_qp, 0., 0., 0.,
155 KalmanVertexTrackUpdater::update<BoundTrackParameters>(trkAtVtx,
vtx);
159 ip3dEst.calculate3dDistance(
geoContext, fittedParamsCopy, vtxPos, state)
165 .calculate3dDistance(
geoContext, trkAtVtx.fittedParams, vtxPos,
169 std::cout <<
"Old distance: " << oldDistance << std::endl;
170 std::cout <<
"New distance: " << newDistance << std::endl;
174 BOOST_CHECK_NE(fittedParamsCopy, trkAtVtx.fittedParams);
177 BOOST_CHECK(newDistance < oldDistance);