9 #include <boost/test/unit_test.hpp>
23 using namespace Acts::UnitLiterals;
26 constexpr
auto eps = std::numeric_limits<Particle::Scalar>::epsilon();
29 BOOST_AUTO_TEST_SUITE(FatrasParticle)
38 BOOST_CHECK_EQUAL(
particle.fourPosition(), Particle::Vector4::Zero());
39 BOOST_CHECK_EQUAL(
particle.position(), Particle::Vector3::Zero());
59 BOOST_CHECK_EQUAL(
particle.mass(), 1_GeV);
61 BOOST_CHECK_EQUAL(
particle.fourMomentum().x(), 2_GeV);
62 BOOST_CHECK_EQUAL(
particle.fourMomentum().y(), 0_GeV);
63 BOOST_CHECK_EQUAL(
particle.fourMomentum().z(), 0_GeV);
64 BOOST_CHECK_EQUAL(
particle.fourMomentum().w(), std::hypot(1_GeV, 2_GeV));
65 BOOST_CHECK_EQUAL(
particle.transverseMomentum(), 2_GeV);
66 BOOST_CHECK_EQUAL(
particle.absoluteMomentum(), 2_GeV);
67 BOOST_CHECK_EQUAL(
particle.energy(), std::hypot(1_GeV, 2_GeV));
73 BOOST_CHECK_LT(
particle.transverseMomentum(), 2_GeV);
74 BOOST_CHECK_LT(
particle.absoluteMomentum(), 2_GeV);
83 BOOST_CHECK_LT(
particle.transverseMomentum(), 2_GeV);
84 BOOST_CHECK_LT(
particle.absoluteMomentum(), 2_GeV);
107 BOOST_CHECK(not
particle.isAlive());
110 BOOST_AUTO_TEST_SUITE_END()