![]() |
|
|||
File indexing completed on 2025-03-13 09:12:19
0001 //----------------------------------*-C++-*----------------------------------// 0002 // Copyright 2024 UT-Battelle, LLC, and other Celeritas developers. 0003 // See the top-level COPYRIGHT file for details. 0004 // SPDX-License-Identifier: (Apache-2.0 OR MIT) 0005 //---------------------------------------------------------------------------// 0006 //! \file geocel/detail/LengthUnits.hh 0007 //! \brief NOTE: only use inside geocel; prefer celeritas/Units.hh 0008 //---------------------------------------------------------------------------// 0009 #pragma once 0010 0011 #include "corecel/Config.hh" 0012 0013 #include "corecel/Types.hh" 0014 0015 #define CELER_ICRT inline constexpr real_type 0016 0017 namespace celeritas 0018 { 0019 namespace lengthunits 0020 { 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 //---------------------------------------------------------------------------// 0039 } // namespace lengthunits 0040 } // namespace celeritas
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
![]() ![]() |