File indexing completed on 2025-01-18 09:13:06
0001
0002
0003
0004
0005
0006
0007
0008
0009 #pragma once
0010
0011 #include <boost/test/data/test_case.hpp>
0012
0013 #include "Acts/Definitions/PdgParticle.hpp"
0014 #include "Acts/Definitions/Units.hpp"
0015 #include "Acts/Material/MaterialSlab.hpp"
0016 #include "Acts/Tests/CommonHelpers/PredefinedMaterials.hpp"
0017 #include "Acts/Utilities/UnitVectors.hpp"
0018 #include "ActsFatras/EventData/Particle.hpp"
0019
0020 #include <cstdint>
0021
0022 namespace Dataset {
0023
0024 namespace data = boost::unit_test::data;
0025 using namespace Acts::UnitLiterals;
0026
0027
0028 const auto particlePdg = data::make(std::vector<Acts::PdgParticle>{
0029 Acts::PdgParticle::eElectron,
0030 Acts::PdgParticle::ePositron,
0031 Acts::PdgParticle::eMuon,
0032 Acts::PdgParticle::eAntiMuon,
0033 });
0034
0035
0036 const auto momentumPhi = data::xrange(0_degree, 360_degree, 60_degree);
0037 const auto momentumTheta = data::xrange(-45_degree, 45_degree, 15_degree);
0038 const auto momentumAbs = data::xrange(500_MeV, 10_GeV, 500_MeV);
0039
0040
0041 const auto rngSeed =
0042 data::xrange<std::uint32_t>((data::begin = 2u, data::step = 3u));
0043
0044
0045 const auto parameters =
0046 particlePdg * momentumPhi * momentumTheta * momentumAbs ^ rngSeed;
0047
0048 const auto parametersPhotonConversion = momentumPhi * momentumTheta ^ rngSeed;
0049
0050
0051 inline ActsFatras::Particle makeParticle(Acts::PdgParticle pdg, double phi,
0052 double theta, double p) {
0053 const auto id = ActsFatras::Barcode().setVertexPrimary(1).setParticle(1);
0054 return ActsFatras::Particle(id, pdg)
0055 .setPosition4(0, 0, 0, 0)
0056 .setDirection(Acts::makeDirectionFromPhiTheta(phi, theta))
0057 .setAbsoluteMomentum(p);
0058 }
0059
0060 }