10#ifndef EIGEN_CXX11_TENSOR_TENSOR_INDEX_LIST_H
11#define EIGEN_CXX11_TENSOR_TENSOR_INDEX_LIST_H
14#if EIGEN_HAS_CONSTEXPR && EIGEN_HAS_VARIADIC_TEMPLATES
16#define EIGEN_HAS_INDEX_LIST
22 static const Index value = n;
23 EIGEN_DEVICE_FUNC
constexpr operator Index()
const {
return n; }
24 EIGEN_DEVICE_FUNC
void set(Index val) {
25 eigen_assert(val == n);
31template <Index f, Index s>
32struct type2indexpair {
33 static const Index first = f;
34 static const Index second = s;
36 constexpr EIGEN_DEVICE_FUNC
operator IndexPair<Index>()
const {
37 return IndexPair<Index>(f, s);
40 EIGEN_DEVICE_FUNC
void set(
const IndexPair<Index>& val) {
41 eigen_assert(val.first == f);
42 eigen_assert(val.second == s);
47template<Index n>
struct NumTraits<type2index<n> >
52 RequireInitialization =
false,
58 EIGEN_DEVICE_FUNC
static EIGEN_CONSTEXPR EIGEN_STRONG_INLINE Real epsilon() {
return 0; }
59 EIGEN_DEVICE_FUNC
static EIGEN_CONSTEXPR EIGEN_STRONG_INLINE Real dummy_precision() {
return 0; }
60 EIGEN_DEVICE_FUNC
static EIGEN_CONSTEXPR EIGEN_STRONG_INLINE Real highest() {
return n; }
61 EIGEN_DEVICE_FUNC
static EIGEN_CONSTEXPR EIGEN_STRONG_INLINE Real lowest() {
return n; }
66EIGEN_DEVICE_FUNC
void update_value(T& val,
Index new_val) {
67 val = internal::convert_index<T>(new_val);
70EIGEN_DEVICE_FUNC
void update_value(type2index<n>& val,
Index new_val) {
75EIGEN_DEVICE_FUNC
void update_value(T& val, IndexPair<Index> new_val) {
78template <Index f, Index s>
79EIGEN_DEVICE_FUNC
void update_value(type2indexpair<f, s>& val, IndexPair<Index> new_val) {
85struct is_compile_time_constant {
86 static constexpr bool value =
false;
90struct is_compile_time_constant<type2index<idx> > {
91 static constexpr bool value =
true;
94struct is_compile_time_constant<const type2index<idx> > {
95 static constexpr bool value =
true;
98struct is_compile_time_constant<type2index<idx>& > {
99 static constexpr bool value =
true;
102struct is_compile_time_constant<const type2index<idx>& > {
103 static constexpr bool value =
true;
106template <Index f, Index s>
107struct is_compile_time_constant<type2indexpair<f, s> > {
108 static constexpr bool value =
true;
110template <Index f, Index s>
111struct is_compile_time_constant<const type2indexpair<f, s> > {
112 static constexpr bool value =
true;
114template <Index f, Index s>
115struct is_compile_time_constant<type2indexpair<f, s>& > {
116 static constexpr bool value =
true;
118template <Index f, Index s>
119struct is_compile_time_constant<const type2indexpair<f, s>& > {
120 static constexpr bool value =
true;
124template<
typename... T>
127template<
typename T,
typename... O>
128struct IndexTuple<T, O...> {
129 EIGEN_DEVICE_FUNC
constexpr IndexTuple() : head(), others() { }
130 EIGEN_DEVICE_FUNC
constexpr IndexTuple(
const T& v,
const O... o) : head(v), others(o...) { }
132 constexpr static int count = 1 +
sizeof...(O);
134 IndexTuple<O...> others;
136 typedef IndexTuple<O...> Other;
140 struct IndexTuple<T> {
141 EIGEN_DEVICE_FUNC
constexpr IndexTuple() : head() { }
142 EIGEN_DEVICE_FUNC
constexpr IndexTuple(
const T& v) : head(v) { }
144 constexpr static int count = 1;
150template<
int N,
typename... T>
151struct IndexTupleExtractor;
153template<
int N,
typename T,
typename... O>
154struct IndexTupleExtractor<N, T, O...> {
156 typedef typename IndexTupleExtractor<N-1, O...>::ValType ValType;
158 EIGEN_DEVICE_FUNC
static constexpr ValType& get_val(IndexTuple<T, O...>& val) {
159 return IndexTupleExtractor<N-1, O...>::get_val(val.others);
162 EIGEN_DEVICE_FUNC
static constexpr const ValType& get_val(
const IndexTuple<T, O...>& val) {
163 return IndexTupleExtractor<N-1, O...>::get_val(val.others);
165 template <
typename V>
166 EIGEN_DEVICE_FUNC
static void set_val(IndexTuple<T, O...>& val, V& new_val) {
167 IndexTupleExtractor<N-1, O...>::set_val(val.others, new_val);
172template<
typename T,
typename... O>
173 struct IndexTupleExtractor<0, T, O...> {
177 EIGEN_DEVICE_FUNC
static constexpr ValType& get_val(IndexTuple<T, O...>& val) {
180 EIGEN_DEVICE_FUNC
static constexpr const ValType& get_val(
const IndexTuple<T, O...>& val) {
183 template <
typename V>
184 EIGEN_DEVICE_FUNC
static void set_val(IndexTuple<T, O...>& val, V& new_val) {
191template <
int N,
typename T,
typename... O>
192EIGEN_DEVICE_FUNC
constexpr typename IndexTupleExtractor<N, T, O...>::ValType& array_get(IndexTuple<T, O...>& tuple) {
193 return IndexTupleExtractor<N, T, O...>::get_val(tuple);
195template <
int N,
typename T,
typename... O>
196EIGEN_DEVICE_FUNC
constexpr const typename IndexTupleExtractor<N, T, O...>::ValType& array_get(
const IndexTuple<T, O...>& tuple) {
197 return IndexTupleExtractor<N, T, O...>::get_val(tuple);
199template <
typename T,
typename... O>
200 struct array_size<IndexTuple<T, O...> > {
201 static const size_t value = IndexTuple<T, O...>::count;
203template <
typename T,
typename... O>
204 struct array_size<const IndexTuple<T, O...> > {
205 static const size_t value = IndexTuple<T, O...>::count;
211template <Index Idx,
typename ValueT>
213 template <
typename... T>
214 EIGEN_DEVICE_FUNC
static constexpr ValueT get(
const Index i,
const IndexTuple<T...>& t) {
216 return (i == Idx ? array_get<Idx>(t) : tuple_coeff<Idx-1, ValueT>::get(i, t));
218 template <
typename... T>
219 EIGEN_DEVICE_FUNC
static void set(
const Index i, IndexTuple<T...>& t,
const ValueT& value) {
221 update_value(array_get<Idx>(t), value);
223 tuple_coeff<Idx-1, ValueT>::set(i, t, value);
227 template <
typename... T>
228 EIGEN_DEVICE_FUNC
static constexpr bool value_known_statically(
const Index i,
const IndexTuple<T...>& t) {
229 return ((i == Idx) && is_compile_time_constant<
typename IndexTupleExtractor<Idx, T...>::ValType>::value) ||
230 tuple_coeff<Idx-1, ValueT>::value_known_statically(i, t);
233 template <
typename... T>
234 EIGEN_DEVICE_FUNC
static constexpr bool values_up_to_known_statically(
const IndexTuple<T...>& t) {
235 return is_compile_time_constant<
typename IndexTupleExtractor<Idx, T...>::ValType>::value &&
236 tuple_coeff<Idx-1, ValueT>::values_up_to_known_statically(t);
239 template <
typename... T>
240 EIGEN_DEVICE_FUNC
static constexpr bool values_up_to_statically_known_to_increase(
const IndexTuple<T...>& t) {
241 return is_compile_time_constant<
typename IndexTupleExtractor<Idx, T...>::ValType>::value &&
242 is_compile_time_constant<
typename IndexTupleExtractor<Idx, T...>::ValType>::value &&
243 array_get<Idx>(t) > array_get<Idx-1>(t) &&
244 tuple_coeff<Idx-1, ValueT>::values_up_to_statically_known_to_increase(t);
248template <
typename ValueT>
249struct tuple_coeff<0, ValueT> {
250 template <
typename... T>
251 EIGEN_DEVICE_FUNC
static constexpr ValueT get(
const Index ,
const IndexTuple<T...>& t) {
253 return array_get<0>(t);
255 template <
typename... T>
256 EIGEN_DEVICE_FUNC
static void set(
const Index i, IndexTuple<T...>& t,
const ValueT value) {
257 eigen_assert (i == 0);
258 update_value(array_get<0>(t), value);
260 template <
typename... T>
261 EIGEN_DEVICE_FUNC
static constexpr bool value_known_statically(
const Index i,
const IndexTuple<T...>&) {
262 return is_compile_time_constant<
typename IndexTupleExtractor<0, T...>::ValType>::value && (i == 0);
265 template <
typename... T>
266 EIGEN_DEVICE_FUNC
static constexpr bool values_up_to_known_statically(
const IndexTuple<T...>&) {
267 return is_compile_time_constant<
typename IndexTupleExtractor<0, T...>::ValType>::value;
270 template <
typename... T>
271 EIGEN_DEVICE_FUNC
static constexpr bool values_up_to_statically_known_to_increase(
const IndexTuple<T...>&) {
296template <
typename FirstType,
typename... OtherTypes>
297struct IndexList : internal::IndexTuple<FirstType, OtherTypes...> {
298 EIGEN_STRONG_INLINE EIGEN_DEVICE_FUNC
constexpr Index operator[] (
const Index i)
const {
299 return internal::tuple_coeff<internal::array_size<internal::IndexTuple<FirstType, OtherTypes...> >::value-1,
Index>::get(i, *
this);
301 EIGEN_STRONG_INLINE EIGEN_DEVICE_FUNC
constexpr Index get(
const Index i)
const {
302 return internal::tuple_coeff<internal::array_size<internal::IndexTuple<FirstType, OtherTypes...> >::value-1,
Index>::get(i, *
this);
304 EIGEN_STRONG_INLINE EIGEN_DEVICE_FUNC
void set(
const Index i,
const Index value) {
305 return internal::tuple_coeff<internal::array_size<internal::IndexTuple<FirstType, OtherTypes...> >::value-1,
Index>::set(i, *
this, value);
308 EIGEN_DEVICE_FUNC
constexpr IndexList(
const internal::IndexTuple<FirstType, OtherTypes...>& other) : internal::IndexTuple<FirstType, OtherTypes...>(other) { }
309 EIGEN_DEVICE_FUNC
constexpr IndexList(FirstType& first, OtherTypes... other) : internal::IndexTuple<FirstType, OtherTypes...>(first, other...) { }
310 EIGEN_DEVICE_FUNC
constexpr IndexList() : internal::IndexTuple<FirstType, OtherTypes...>() { }
312 EIGEN_DEVICE_FUNC
constexpr bool value_known_statically(
const Index i)
const {
313 return internal::tuple_coeff<internal::array_size<internal::IndexTuple<FirstType, OtherTypes...> >::value-1,
Index>::value_known_statically(i, *
this);
315 EIGEN_DEVICE_FUNC
constexpr bool all_values_known_statically()
const {
316 return internal::tuple_coeff<internal::array_size<internal::IndexTuple<FirstType, OtherTypes...> >::value-1,
Index>::values_up_to_known_statically(*
this);
319 EIGEN_DEVICE_FUNC
constexpr bool values_statically_known_to_increase()
const {
320 return internal::tuple_coeff<internal::array_size<internal::IndexTuple<FirstType, OtherTypes...> >::value-1,
Index>::values_up_to_statically_known_to_increase(*
this);
324template <
typename FirstType,
typename... OtherTypes>
325std::ostream& operator<<(std::ostream& os,
326 const IndexList<FirstType, OtherTypes...>& dims) {
328 for (
size_t i = 0; i < 1 +
sizeof...(OtherTypes); ++i) {
329 if (i > 0) os <<
", ";
336template<
typename FirstType,
typename... OtherTypes>
337constexpr IndexList<FirstType, OtherTypes...> make_index_list(FirstType val1, OtherTypes... other_vals) {
338 return IndexList<FirstType, OtherTypes...>(val1, other_vals...);
342template<
typename FirstType,
typename... OtherTypes>
343struct IndexPairList : internal::IndexTuple<FirstType, OtherTypes...> {
344 EIGEN_STRONG_INLINE EIGEN_DEVICE_FUNC
constexpr IndexPair<Index> operator[] (
const Index i)
const {
345 return internal::tuple_coeff<internal::array_size<internal::IndexTuple<FirstType, OtherTypes...> >::value-1, IndexPair<Index>>::get(i, *
this);
347 EIGEN_STRONG_INLINE EIGEN_DEVICE_FUNC
void set(
const Index i,
const IndexPair<Index> value) {
348 return internal::tuple_coeff<internal::array_size<internal::IndexTuple<FirstType, OtherTypes...>>::value-1, IndexPair<Index> >::set(i, *
this, value);
351 EIGEN_DEVICE_FUNC
constexpr IndexPairList(
const internal::IndexTuple<FirstType, OtherTypes...>& other) : internal::IndexTuple<FirstType, OtherTypes...>(other) { }
352 EIGEN_DEVICE_FUNC
constexpr IndexPairList() : internal::IndexTuple<FirstType, OtherTypes...>() { }
354 EIGEN_DEVICE_FUNC
constexpr bool value_known_statically(
const Index i)
const {
355 return internal::tuple_coeff<internal::array_size<internal::IndexTuple<FirstType, OtherTypes...> >::value-1,
Index>::value_known_statically(i, *
this);
361template<
typename FirstType,
typename... OtherTypes>
362EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE
Index array_prod(
const IndexList<FirstType, OtherTypes...>& sizes) {
365 for (
size_t i = 0; i < array_size<IndexList<FirstType, OtherTypes...> >::value; ++i) {
371template<
typename FirstType,
typename... OtherTypes>
struct array_size<IndexList<FirstType, OtherTypes...> > {
372 static const size_t value = array_size<IndexTuple<FirstType, OtherTypes...> >::value;
374template<
typename FirstType,
typename... OtherTypes>
struct array_size<const IndexList<FirstType, OtherTypes...> > {
375 static const size_t value = array_size<IndexTuple<FirstType, OtherTypes...> >::value;
378template<
typename FirstType,
typename... OtherTypes>
struct array_size<IndexPairList<FirstType, OtherTypes...> > {
379 static const size_t value = std::tuple_size<std::tuple<FirstType, OtherTypes...> >::value;
381template<
typename FirstType,
typename... OtherTypes>
struct array_size<const IndexPairList<FirstType, OtherTypes...> > {
382 static const size_t value = std::tuple_size<std::tuple<FirstType, OtherTypes...> >::value;
385template<
Index N,
typename FirstType,
typename... OtherTypes> EIGEN_DEVICE_FUNC
constexpr Index array_get(IndexList<FirstType, OtherTypes...>& a) {
386 return IndexTupleExtractor<N, FirstType, OtherTypes...>::get_val(a);
388template<
Index N,
typename FirstType,
typename... OtherTypes> EIGEN_DEVICE_FUNC
constexpr Index array_get(
const IndexList<FirstType, OtherTypes...>& a) {
389 return IndexTupleExtractor<N, FirstType, OtherTypes...>::get_val(a);
393struct index_known_statically_impl {
394 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index) {
399template <
typename FirstType,
typename... OtherTypes>
400struct index_known_statically_impl<IndexList<FirstType, OtherTypes...> > {
401 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i) {
402 return IndexList<FirstType, OtherTypes...>().value_known_statically(i);
406template <
typename FirstType,
typename... OtherTypes>
407struct index_known_statically_impl<const IndexList<FirstType, OtherTypes...> > {
408 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i) {
409 return IndexList<FirstType, OtherTypes...>().value_known_statically(i);
415struct all_indices_known_statically_impl {
416 static constexpr bool run() {
421template <
typename FirstType,
typename... OtherTypes>
422struct all_indices_known_statically_impl<IndexList<FirstType, OtherTypes...> > {
423 EIGEN_DEVICE_FUNC
static constexpr bool run() {
424 return IndexList<FirstType, OtherTypes...>().all_values_known_statically();
428template <
typename FirstType,
typename... OtherTypes>
429struct all_indices_known_statically_impl<const IndexList<FirstType, OtherTypes...> > {
430 EIGEN_DEVICE_FUNC
static constexpr bool run() {
431 return IndexList<FirstType, OtherTypes...>().all_values_known_statically();
437struct indices_statically_known_to_increase_impl {
438 EIGEN_DEVICE_FUNC
static constexpr bool run() {
443template <
typename FirstType,
typename... OtherTypes>
444 struct indices_statically_known_to_increase_impl<IndexList<FirstType, OtherTypes...> > {
445 EIGEN_DEVICE_FUNC
static constexpr bool run() {
446 return Eigen::IndexList<FirstType, OtherTypes...>().values_statically_known_to_increase();
450template <
typename FirstType,
typename... OtherTypes>
451 struct indices_statically_known_to_increase_impl<const IndexList<FirstType, OtherTypes...> > {
452 EIGEN_DEVICE_FUNC
static constexpr bool run() {
453 return Eigen::IndexList<FirstType, OtherTypes...>().values_statically_known_to_increase();
458template <
typename Tx>
459struct index_statically_eq_impl {
460 EIGEN_DEVICE_FUNC
static constexpr bool run(
Index,
Index) {
465template <
typename FirstType,
typename... OtherTypes>
466struct index_statically_eq_impl<IndexList<FirstType, OtherTypes...> > {
467 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
468 return IndexList<FirstType, OtherTypes...>().value_known_statically(i) &&
469 (IndexList<FirstType, OtherTypes...>().get(i) == value);
473template <
typename FirstType,
typename... OtherTypes>
474struct index_statically_eq_impl<const IndexList<FirstType, OtherTypes...> > {
475 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
476 return IndexList<FirstType, OtherTypes...>().value_known_statically(i) &&
477 (IndexList<FirstType, OtherTypes...>().get(i) == value);
483struct index_statically_ne_impl {
484 EIGEN_DEVICE_FUNC
static constexpr bool run(
Index,
Index) {
489template <
typename FirstType,
typename... OtherTypes>
490struct index_statically_ne_impl<IndexList<FirstType, OtherTypes...> > {
491 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
492 return IndexList<FirstType, OtherTypes...>().value_known_statically(i) &&
493 (IndexList<FirstType, OtherTypes...>().get(i) != value);
497template <
typename FirstType,
typename... OtherTypes>
498struct index_statically_ne_impl<const IndexList<FirstType, OtherTypes...> > {
499 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
500 return IndexList<FirstType, OtherTypes...>().value_known_statically(i) &&
501 (IndexList<FirstType, OtherTypes...>().get(i) != value);
507struct index_statically_gt_impl {
508 EIGEN_DEVICE_FUNC
static constexpr bool run(
Index,
Index) {
513template <
typename FirstType,
typename... OtherTypes>
514struct index_statically_gt_impl<IndexList<FirstType, OtherTypes...> > {
515 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
516 return IndexList<FirstType, OtherTypes...>().value_known_statically(i) &&
517 (IndexList<FirstType, OtherTypes...>().get(i) > value);
521template <
typename FirstType,
typename... OtherTypes>
522struct index_statically_gt_impl<const IndexList<FirstType, OtherTypes...> > {
523 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
524 return IndexList<FirstType, OtherTypes...>().value_known_statically(i) &&
525 (IndexList<FirstType, OtherTypes...>().get(i) > value);
532struct index_statically_lt_impl {
533 EIGEN_DEVICE_FUNC
static constexpr bool run(
Index,
Index) {
538template <
typename FirstType,
typename... OtherTypes>
539struct index_statically_lt_impl<IndexList<FirstType, OtherTypes...> > {
540 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
541 return IndexList<FirstType, OtherTypes...>().value_known_statically(i) &&
542 (IndexList<FirstType, OtherTypes...>().get(i) < value);
546template <
typename FirstType,
typename... OtherTypes>
547struct index_statically_lt_impl<const IndexList<FirstType, OtherTypes...> > {
548 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
549 return IndexList<FirstType, OtherTypes...>().value_known_statically(i) &&
550 (IndexList<FirstType, OtherTypes...>().get(i) < value);
556template <
typename Tx>
557struct index_pair_first_statically_eq_impl {
558 EIGEN_DEVICE_FUNC
static constexpr bool run(
Index,
Index) {
563template <
typename FirstType,
typename... OtherTypes>
564struct index_pair_first_statically_eq_impl<IndexPairList<FirstType, OtherTypes...> > {
565 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
566 return IndexPairList<FirstType, OtherTypes...>().value_known_statically(i) &&
567 (IndexPairList<FirstType, OtherTypes...>().operator[](i).first == value);
571template <
typename FirstType,
typename... OtherTypes>
572struct index_pair_first_statically_eq_impl<const IndexPairList<FirstType, OtherTypes...> > {
573 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
574 return IndexPairList<FirstType, OtherTypes...>().value_known_statically(i) &&
575 (IndexPairList<FirstType, OtherTypes...>().operator[](i).first == value);
581template <
typename Tx>
582struct index_pair_second_statically_eq_impl {
583 EIGEN_DEVICE_FUNC
static constexpr bool run(
Index,
Index) {
588template <
typename FirstType,
typename... OtherTypes>
589struct index_pair_second_statically_eq_impl<IndexPairList<FirstType, OtherTypes...> > {
590 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
591 return IndexPairList<FirstType, OtherTypes...>().value_known_statically(i) &&
592 (IndexPairList<FirstType, OtherTypes...>().operator[](i).second == value);
596template <
typename FirstType,
typename... OtherTypes>
597struct index_pair_second_statically_eq_impl<const IndexPairList<FirstType, OtherTypes...> > {
598 EIGEN_DEVICE_FUNC
static constexpr bool run(
const Index i,
const Index value) {
599 return IndexPairList<FirstType, OtherTypes...>().value_known_statically(i) &&
600 (IndexPairList<FirstType, OtherTypes...>().operator[](i).second == value);
614struct index_known_statically_impl {
615 static EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE
bool run(
const Index) {
621struct all_indices_known_statically_impl {
622 static EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE
bool run() {
628struct indices_statically_known_to_increase_impl {
629 static EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE
bool run() {
635struct index_statically_eq_impl {
636 static EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE
bool run(
Index,
Index) {
642struct index_statically_ne_impl {
643 static EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE
bool run(
Index,
Index) {
649struct index_statically_gt_impl {
650 static EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE
bool run(
Index,
Index) {
656struct index_statically_lt_impl {
657 static EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE
bool run(
Index,
Index) {
662template <
typename Tx>
663struct index_pair_first_statically_eq_impl {
664 static EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE
bool run(
Index,
Index) {
669template <
typename Tx>
670struct index_pair_second_statically_eq_impl {
671 static EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE
bool run(
Index,
Index) {
687static EIGEN_DEVICE_FUNC EIGEN_CONSTEXPR
bool index_known_statically(
Index i) {
688 return index_known_statically_impl<T>::run(i);
692static EIGEN_DEVICE_FUNC EIGEN_CONSTEXPR
bool all_indices_known_statically() {
693 return all_indices_known_statically_impl<T>::run();
697static EIGEN_DEVICE_FUNC EIGEN_CONSTEXPR
bool indices_statically_known_to_increase() {
698 return indices_statically_known_to_increase_impl<T>::run();
702static EIGEN_DEVICE_FUNC EIGEN_CONSTEXPR
bool index_statically_eq(
Index i,
Index value) {
703 return index_statically_eq_impl<T>::run(i, value);
707static EIGEN_DEVICE_FUNC EIGEN_CONSTEXPR
bool index_statically_ne(
Index i,
Index value) {
708 return index_statically_ne_impl<T>::run(i, value);
712static EIGEN_DEVICE_FUNC EIGEN_CONSTEXPR
bool index_statically_gt(
Index i,
Index value) {
713 return index_statically_gt_impl<T>::run(i, value);
717static EIGEN_DEVICE_FUNC EIGEN_CONSTEXPR
bool index_statically_lt(
Index i,
Index value) {
718 return index_statically_lt_impl<T>::run(i, value);
722static EIGEN_DEVICE_FUNC EIGEN_CONSTEXPR
bool index_pair_first_statically_eq(
Index i,
Index value) {
723 return index_pair_first_statically_eq_impl<T>::run(i, value);
727static EIGEN_DEVICE_FUNC EIGEN_CONSTEXPR
bool index_pair_second_statically_eq(
Index i,
Index value) {
728 return index_pair_second_statically_eq_impl<T>::run(i, value);
Namespace containing all symbols from the Eigen library.
EIGEN_DEFAULT_DENSE_INDEX_TYPE Index