|
Celeritas 0.7+28f01d9
|
Create and convert arrays of quantities. More...
#include <cstddef>#include <type_traits>#include "corecel/Types.hh"#include "corecel/cont/Array.hh"#include "Quantity.hh"Functions | |
| template<class Q , class... Args> | |
| constexpr Array< Q, sizeof...(Args)> | celeritas::make_quantity_array (Args const &... args) noexcept |
| Construct an array of quantities from raw values. | |
| template<class Q , size_type N> | |
| constexpr Array< Q, N > | celeritas::make_quantity_array (Array< typename Q::value_type, N > const &arr) noexcept |
| Construct an array of quantities from raw values. | |
| template<class UnitT , class ValueT , size_type N> | |
| constexpr auto | celeritas::native_value_from (Array< Quantity< UnitT, ValueT >, N > const &quant) noexcept |
| Convert an array of quantities to native values. | |
| template<class Q , class T , size_type N> | |
| constexpr auto | celeritas::native_value_to (Array< T, N > const &value) noexcept |
| Convert an array of native values to an array of quantities. | |
| template<class Q , size_type N> | |
| constexpr auto | celeritas::value_as (Array< Q, N > const &quant) noexcept -> std::enable_if_t< is_quantity_v< Q >, Array< typename Q::value_type, N > > |
| Get the values from an array of quantities. | |
Create and convert arrays of quantities.
|
inlineconstexprnoexcept |
Construct an array of quantities from raw values.
This helper function allows concise construction of arrays of quantities:
|
inlineconstexprnoexcept |
Construct an array of quantities from raw values.
This helper function allows concise construction of arrays of quantities:
|
inlineconstexprnoexcept |
Convert an array of quantities to native values.
This applies native_value_from element-wise to each component.
|
inlineconstexprnoexcept |
Convert an array of native values to an array of quantities.
This applies native_value_to element-wise to each component.