File indexing completed on 2025-09-16 08:57:15
0001
0002
0003
0004
0005
0006
0007
0008 #pragma once
0009
0010 #include "corecel/Config.hh"
0011
0012 #include "corecel/Types.hh"
0013 #include "corecel/math/Constant.hh"
0014
0015 namespace celeritas
0016 {
0017 namespace lengthunits
0018 {
0019
0020 #define CELER_ICRT inline constexpr Constant
0021
0022 #if CELERITAS_UNITS == CELERITAS_UNITS_CGS
0023 CELER_ICRT meter{100};
0024 CELER_ICRT centimeter{1};
0025 CELER_ICRT millimeter{0.1};
0026 #elif CELERITAS_UNITS == CELERITAS_UNITS_SI
0027 CELER_ICRT meter{1};
0028 CELER_ICRT centimeter{0.01};
0029 CELER_ICRT millimeter{0.001};
0030 #elif CELERITAS_UNITS == CELERITAS_UNITS_CLHEP
0031 CELER_ICRT meter{1000};
0032 CELER_ICRT centimeter{10};
0033 CELER_ICRT millimeter{1};
0034 #else
0035 # error "CELERITAS_UNITS is undefined"
0036 #endif
0037
0038 #undef CELER_ICRT
0039
0040 }
0041 }