25 #ifndef EIGEN_SPARSE_DOT_H
26 #define EIGEN_SPARSE_DOT_H
30 template<
typename Derived>
31 template<
typename OtherDerived>
32 typename internal::traits<Derived>::Scalar
39 YOU_MIXED_DIFFERENT_NUMERIC_TYPES__YOU_NEED_TO_USE_THE_CAST_METHOD_OF_MATRIXBASE_TO_CAST_NUMERIC_TYPES_EXPLICITLY)
42 eigen_assert(other.size()>0 &&
"you are using a non initialized vector");
44 typename Derived::InnerIterator i(derived(),0);
54 template<
typename Derived>
55 template<
typename OtherDerived>
56 typename internal::traits<Derived>::Scalar
63 YOU_MIXED_DIFFERENT_NUMERIC_TYPES__YOU_NEED_TO_USE_THE_CAST_METHOD_OF_MATRIXBASE_TO_CAST_NUMERIC_TYPES_EXPLICITLY)
67 typedef typename Derived::Nested Nested;
68 typedef typename OtherDerived::Nested OtherNested;
69 typedef typename internal::remove_all<Nested>::type NestedCleaned;
70 typedef typename internal::remove_all<OtherNested>::type OtherNestedCleaned;
72 const Nested nthis(derived());
73 const OtherNested nother(other.
derived());
75 typename NestedCleaned::InnerIterator i(nthis,0);
76 typename OtherNestedCleaned::InnerIterator j(nother,0);
80 if (i.index()==j.index())
85 else if (i.index()<j.index())
93 template<
typename Derived>
100 template<
typename Derived>
109 #endif // EIGEN_SPARSE_DOT_H