11 #ifndef EIGEN_EIGENBASE_H 12 #define EIGEN_EIGENBASE_H 30 typedef typename internal::traits<Derived>::StorageKind StorageKind;
31 typedef typename internal::traits<Derived>::Index Index;
34 Derived&
derived() {
return *static_cast<Derived*>(
this); }
36 const Derived&
derived()
const {
return *static_cast<const Derived*>(
this); }
38 inline Derived& const_cast_derived()
const 39 {
return *static_cast<Derived*>(const_cast<EigenBase*>(
this)); }
40 inline const Derived& const_derived()
const 41 {
return *static_cast<const Derived*>(
this); }
52 template<
typename Dest>
inline void evalTo(Dest& dst)
const 56 template<
typename Dest>
inline void addTo(Dest& dst)
const 60 typename Dest::PlainObject res(
rows(),
cols());
66 template<
typename Dest>
inline void subTo(Dest& dst)
const 70 typename Dest::PlainObject res(
rows(),
cols());
76 template<
typename Dest>
inline void applyThisOnTheRight(Dest& dst)
const 84 template<
typename Dest>
inline void applyThisOnTheLeft(Dest& dst)
const 105 template<
typename Derived>
106 template<
typename OtherDerived>
109 other.
derived().evalTo(derived());
113 template<
typename Derived>
114 template<
typename OtherDerived>
117 other.
derived().addTo(derived());
121 template<
typename Derived>
122 template<
typename OtherDerived>
123 Derived& DenseBase<Derived>::operator-=(
const EigenBase<OtherDerived> &other)
125 other.derived().subTo(derived());
133 template<
typename Derived>
134 template<
typename OtherDerived>
138 other.
derived().applyThisOnTheRight(derived());
143 template<
typename Derived>
144 template<
typename OtherDerived>
147 other.
derived().applyThisOnTheRight(derived());
151 template<
typename Derived>
152 template<
typename OtherDerived>
155 other.
derived().applyThisOnTheLeft(derived());
160 #endif // EIGEN_EIGENBASE_H Index rows() const
Definition: EigenBase.h:44
Derived & operator=(const DenseBase< OtherDerived > &other)
Definition: Assign.h:541
Base class for all dense matrices, vectors, and arrays.
Definition: DenseBase.h:31
Definition: EigenBase.h:26
void applyOnTheLeft(const EigenBase< OtherDerived > &other)
Definition: EigenBase.h:153
void applyOnTheRight(const EigenBase< OtherDerived > &other)
Definition: EigenBase.h:145
const Derived & derived() const
Definition: EigenBase.h:36
Derived & derived()
Definition: EigenBase.h:34
Derived & operator *=(const EigenBase< OtherDerived > &other)
Definition: EigenBase.h:136
Index size() const
Definition: EigenBase.h:49
Index cols() const
Definition: EigenBase.h:46