diff --git a/examples/boundary_example.cpp b/examples/boundary_example.cpp index 6e369e8a2085c66a9e9f3e31da4db3d8dc3eb9ed..8b28769038504483db2cc3b516d62f162d2dbd10 100644 --- a/examples/boundary_example.cpp +++ b/examples/boundary_example.cpp @@ -103,7 +103,7 @@ int main() { auto const props = world->setModelProperties<MyHomogeneousModel>( Medium::AirDry1Atm, Vector(rootCS, 0_T, 0_T, 0_T), 1_kg / (1_m * 1_m * 1_m), - NuclearComposition(std::vector<Code>{Code::Proton}, std::vector<float>{1.f})); + NuclearComposition({Code::Proton}, {1.})); // add a "target" sphere with 5km readius at 0,0,0 auto target = EnvType::createNode<Sphere>(Point{rootCS, 0_m, 0_m, 0_m}, 5_km); diff --git a/examples/cascade_example.cpp b/examples/cascade_example.cpp index dde77011d5888a9266b5d9a981f44a1d5d8cfd91..06a3756f4b0adbdc8161ad122987b737476f956a 100644 --- a/examples/cascade_example.cpp +++ b/examples/cascade_example.cpp @@ -78,12 +78,11 @@ int main() { UniformMagneticField<HomogeneousMedium<setup::EnvironmentInterface>>>; // fraction of oxygen - float const fox = 0.20946; + double const fox = 0.20946; auto const props = world->setModelProperties<MyHomogeneousModel>( Medium::AirDry1Atm, MagneticFieldVector(rootCS, 0_T, 0_T, 0_T), 1_kg / (1_m * 1_m * 1_m), - NuclearComposition(std::vector<Code>{Code::Nitrogen, Code::Oxygen}, - std::vector<float>{1.f - fox, fox})); + NuclearComposition({Code::Nitrogen, Code::Oxygen}, {1. - fox, fox})); auto innerMedium = setup::Environment::createNode<Sphere>(Point{rootCS, 0_m, 0_m, 0_m}, 5000_m); diff --git a/examples/cascade_proton_example.cpp b/examples/cascade_proton_example.cpp index 053a0c13e2529bd1ae1883fa0b52b661413b2c3c..fda0a3af6062b3011ee073c30e7fd2438349ae91 100644 --- a/examples/cascade_proton_example.cpp +++ b/examples/cascade_proton_example.cpp @@ -80,9 +80,7 @@ int main() { world->setModelProperties<MyHomogeneousModel>( Medium::AirDry1Atm, MagneticFieldVector(rootCS, 0_T, 0_T, 1_mT), - 1_kg / (1_m * 1_m * 1_m), - NuclearComposition(std::vector<Code>{Code::Hydrogen}, - std::vector<float>{(float)1.})); + 1_kg / (1_m * 1_m * 1_m), NuclearComposition({Code::Hydrogen}, {1.})); universe.addChild(std::move(world)); diff --git a/examples/corsika.cpp b/examples/corsika.cpp index a3db1ccfa0c4d35899c25d9603e9655c69a7443d..86734017907bd60e4b1c8013bb3185781aa5b19d 100644 --- a/examples/corsika.cpp +++ b/examples/corsika.cpp @@ -240,11 +240,11 @@ int main(int argc, char** argv) { HEPEnergyType mass = get_mass(beamCode); // particle energy - HEPEnergyType const E0 = 1_GeV * app["--energy"]->as<float>(); + HEPEnergyType const E0 = 1_GeV * app["--energy"]->as<double>(); // direction of the shower in (theta, phi) space - auto const thetaRad = app["--zenith"]->as<float>() / 180. * M_PI; - auto const phiRad = app["--azimuth"]->as<float>() / 180. * M_PI; + auto const thetaRad = app["--zenith"]->as<double>() / 180. * M_PI; + auto const phiRad = app["--azimuth"]->as<double>() / 180. * M_PI; // convert Elab to Plab HEPMomentumType P0 = sqrt((E0 - mass) * (E0 + mass)); diff --git a/examples/mars.cpp b/examples/mars.cpp index 14eab4096b2c07aa34d65ffa7fafdc3e12d3f1e7..e5deda39179da90e1b0934607d30961bb2348ed4 100644 --- a/examples/mars.cpp +++ b/examples/mars.cpp @@ -271,11 +271,11 @@ int main(int argc, char** argv) { HEPEnergyType const mass = get_mass(beamCode); // particle energy - HEPEnergyType const E0 = 1_GeV * app["--energy"]->as<float>(); + HEPEnergyType const E0 = 1_GeV * app["--energy"]->as<double>(); // direction of the shower in (theta, phi) space - auto const thetaRad = app["--zenith"]->as<float>() / 180. * M_PI; - auto const phiRad = app["--azimuth"]->as<float>() / 180. * M_PI; + auto const thetaRad = app["--zenith"]->as<double>() / 180. * M_PI; + auto const phiRad = app["--azimuth"]->as<double>() / 180. * M_PI; // convert Elab to Plab HEPMomentumType P0 = sqrt((E0 - mass) * (E0 + mass));