16 #ifndef OPENKALMAN_MAKE_DENSE_OBJECT_HPP 17 #define OPENKALMAN_MAKE_DENSE_OBJECT_HPP 31 template<indexible T, Layout layout = Layout::none, values::number Scalar = scalar_type_of_t<T>, pattern_collection Descriptors>
33 interface::make_default_defined_for<T, layout, Scalar, decltype(internal::to_euclidean_vector_space_descriptor_collection(std::declval<Descriptors&&>()))>
34 constexpr writable
auto 36 template<
typename T,
Layout layout =
Layout::none,
typename Scalar = scalar_type_of_t<T>,
typename Descriptors, std::enable_if_t<
37 indexible<T> and values::number<Scalar> and pattern_collection<D> and (layout !=
Layout::stride) and
38 interface::make_default_defined_for<T, layout, Scalar, decltype(internal::to_euclidean_vector_space_descriptor_collection(std::declval<Descriptors&&>()))>,
int> = 0>
43 decltype(
auto) d = internal::remove_trailing_1D_descriptors(std::forward<Descriptors>(descriptors));
44 using D = decltype(d);
46 if constexpr (coordinates::euclidean_pattern_collection<D>)
48 return Traits::template make_default<layout, Scalar>(std::forward<D>(d));
52 auto ed = internal::to_euclidean_vector_space_descriptor_collection(d);
63 template<indexible T, Layout layout = Layout::none, values::number Scalar = scalar_type_of_t<T>, coordinates::pattern...Ds>
65 interface::make_default_defined_for<T, layout, Scalar, decltype(std::tuple {get_dimension(std::declval<Ds&&>())...})>
66 constexpr writable
auto 69 indexible<T> and values::number<Scalar> and (... and coordinates::pattern<Ds>) and (layout !=
Layout::stride) and
70 interface::make_default_defined_for<T, layout, Scalar, std::tuple<Ds&&...>>,
int> = 0>
75 return make_dense_object<T, layout, Scalar>(std::tuple {std::forward<Ds>(ds)...});
81 #endif //OPENKALMAN_MAKE_DENSE_OBJECT_HPP No storage layout (e.g., if the elements are calculated rather than stored).
auto make_vector_space_adapter(Arg &&arg, Descriptors &&descriptors)
If necessary, wrap an object in a wrapper that adds vector space descriptors for each index...
Definition: make_vector_space_adapter.hpp:37
typename scalar_type_of< T >::type scalar_type_of_t
helper template for scalar_type_of.
Definition: scalar_type_of.hpp:54
constexpr auto make_dense_object(Descriptors &&descriptors)
Make a default, dense, writable matrix with a set of coordinates::pattern objects defining the dimens...
Definition: make_dense_object.hpp:41
The root namespace for OpenKalman.
Definition: basics.hpp:34
An interface to various routines from the linear algebra library associated with indexible object T...
Definition: library_interface.hpp:37
A generalization of the above: a custom stride is specified for each index.
Layout
The layout format of a multidimensional array.
Definition: global-definitions.hpp:47