Go to the documentation of this file.
11 #ifndef EIGEN_DIAGONALMATRIX_H
12 #define EIGEN_DIAGONALMATRIX_H
16 #ifndef EIGEN_PARSED_BY_DOXYGEN
17 template<
typename Derived>
41 inline const Derived&
derived()
const {
return *
static_cast<const Derived*
>(
this); }
43 inline Derived&
derived() {
return *
static_cast<Derived*
>(
this); }
58 template<
typename MatrixDerived>
87 template<
typename OtherDerived>
89 #ifdef EIGEN_PARSED_BY_DOXYGEN
90 inline unspecified_expression_type
99 template<
typename OtherDerived>
101 #ifdef EIGEN_PARSED_BY_DOXYGEN
102 inline unspecified_expression_type
128 template<
typename _Scalar,
int SizeAtCompileTime,
int MaxSizeAtCompileTime>
130 :
traits<Matrix<_Scalar,SizeAtCompileTime,SizeAtCompileTime,0,MaxSizeAtCompileTime,MaxSizeAtCompileTime> >
139 template<
typename _Scalar,
int SizeAtCompileTime,
int MaxSizeAtCompileTime>
141 :
public DiagonalBase<DiagonalMatrix<_Scalar,SizeAtCompileTime,MaxSizeAtCompileTime> >
144 #ifndef EIGEN_PARSED_BY_DOXYGEN
192 template <
typename... ArgTypes>
203 #endif // EIGEN_HAS_CXX11
206 template<
typename OtherDerived>
210 #ifndef EIGEN_PARSED_BY_DOXYGEN
216 template<
typename OtherDerived>
222 template<
typename OtherDerived>
230 #ifndef EIGEN_PARSED_BY_DOXYGEN
274 template<
typename _DiagonalVectorType>
283 RowsAtCompileTime = DiagonalVectorType::SizeAtCompileTime,
284 ColsAtCompileTime = DiagonalVectorType::SizeAtCompileTime,
285 MaxRowsAtCompileTime = DiagonalVectorType::MaxSizeAtCompileTime,
286 MaxColsAtCompileTime = DiagonalVectorType::MaxSizeAtCompileTime,
292 template<
typename _DiagonalVectorType>
297 #ifndef EIGEN_PARSED_BY_DOXYGEN
323 template<
typename Derived>
338 template<
typename Derived>
346 if(absOnDiagonal > maxAbsOnDiagonal) maxAbsOnDiagonal = absOnDiagonal;
366 template<
typename DstXprType,
typename SrcXprType,
typename Functor>
371 Index dstRows = src.rows();
372 Index dstCols = src.cols();
373 if((dst.rows()!=dstRows) || (dst.cols()!=dstCols))
374 dst.resize(dstRows, dstCols);
377 dst.diagonal() = src.diagonal();
381 { dst.diagonal() += src.diagonal(); }
384 { dst.diagonal() -= src.diagonal(); }
391 #endif // EIGEN_DIAGONALMATRIX_H
DiagonalMatrix< Scalar, DiagonalVectorType::SizeAtCompileTime, DiagonalVectorType::MaxSizeAtCompileTime > PlainObject
DenseMatrixType DenseType
_DiagonalVectorType DiagonalVectorType
#define EIGEN_DEVICE_FUNC
Namespace containing all symbols from the Eigen library.
DiagonalVectorType::Scalar Scalar
Represents a diagonal matrix with its storage.
EIGEN_DEVICE_FUNC Index cols() const
DiagonalVectorType::Scalar Scalar
EIGEN_DEVICE_FUNC DenseMatrixType toDenseMatrix() const
Eigen::Index Index
The interface type of indices.
const EIGEN_DEVICE_FUNC DiagonalWrapper< const Derived > asDiagonal() const
EIGEN_DEVICE_FUNC const friend DiagonalWrapper< const EIGEN_SCALAR_BINARYOP_EXPR_RETURN_TYPE(Scalar, DiagonalVectorType, product) > operator*(const Scalar &scalar, const DiagonalBase &other)
EIGEN_DEVICE_FUNC Index rows() const
set noclip points set clip one set noclip two set bar set border lt lw set xdata set ydata set zdata set x2data set y2data set boxwidth set dummy x
EIGEN_DEVICE_FUNC DiagonalMatrix()
EIGEN_DEVICE_FUNC EIGEN_CONSTEXPR Index size() const EIGEN_NOEXCEPT
DiagonalShape StorageKind
const EIGEN_DEVICE_FUNC DiagonalWrapper< const EIGEN_CWISE_BINARY_RETURN_TYPE(DiagonalVectorType, typename OtherDerived::DiagonalVectorType, difference) > operator-(const DiagonalBase< OtherDerived > &other) const
EIGEN_DEVICE_FUNC bool isMuchSmallerThan(const Scalar &x, const OtherScalar &y, const typename NumTraits< Scalar >::Real &precision=NumTraits< Scalar >::dummy_precision())
EIGEN_DEVICE_FUNC DiagonalMatrix(const Scalar &x, const Scalar &y)
const EIGEN_DEVICE_FUNC Derived & derived() const
EIGEN_DEVICE_FUNC DiagonalMatrix(Index dim)
EIGEN_DEVICE_FUNC DiagonalVectorType & diagonal()
EIGEN_DEVICE_FUNC void setIdentity(Index size)
const EIGEN_DEVICE_FUNC DiagonalVectorType & diagonal() const
NumTraits< Scalar >::Real RealScalar
Matrix< Scalar, RowsAtCompileTime, ColsAtCompileTime, 0, MaxRowsAtCompileTime, MaxColsAtCompileTime > DenseMatrixType
internal::traits< Derived >::StorageIndex StorageIndex
EIGEN_DEVICE_FUNC void resize(Index size)
bool isDiagonal(const RealScalar &prec=NumTraits< Scalar >::dummy_precision()) const
const unsigned int LvalueBit
internal::traits< Derived >::StorageKind StorageKind
mxArray * scalar(mxClassID classid)
internal::traits< DiagonalMatrix >::StorageKind StorageKind
const EIGEN_DEVICE_FUNC DiagonalVectorType & diagonal() const
internal::traits< DiagonalMatrix >::StorageIndex StorageIndex
#define EIGEN_SCALAR_BINARYOP_EXPR_RETURN_TYPE(SCALAR, EXPR, OPNAME)
#define EIGEN_STRONG_INLINE
_DiagonalVectorType DiagonalVectorType
DiagonalVectorType::Nested m_diagonal
Expression of the product of two arbitrary matrices or vectors.
const EIGEN_DEVICE_FUNC CwiseInverseReturnType cwiseInverse() const
internal::traits< Derived >::DiagonalVectorType DiagonalVectorType
EIGEN_DEVICE_FUNC DiagonalVectorType & diagonal()
Matrix< _Scalar, SizeAtCompileTime, 1, 0, MaxSizeAtCompileTime, 1 > DiagonalVectorType
#define EIGEN_EXPR_BINARYOP_SCALAR_RETURN_TYPE(EXPR, SCALAR, OPNAME)
EIGEN_DEVICE_FUNC DiagonalMatrix & operator=(const DiagonalBase< OtherDerived > &other)
Expression of a diagonal matrix.
const EIGEN_DEVICE_FUNC InverseReturnType inverse() const
DiagonalVectorType::RealScalar RealScalar
Map< Matrix< T, Dynamic, Dynamic, ColMajor >, 0, OuterStride<> > matrix(T *data, int rows, int cols, int stride)
DiagonalVectorType m_diagonal
EIGEN_DEVICE_FUNC DiagonalMatrix & operator=(const DiagonalMatrix &other)
DiagonalWrapper< const CwiseUnaryOp< internal::scalar_inverse_op< Scalar >, const DiagonalVectorType > > InverseReturnType
static void run(DstXprType &dst, const SrcXprType &src, const internal::add_assign_op< typename DstXprType::Scalar, typename SrcXprType::Scalar > &)
EIGEN_DEVICE_FUNC DiagonalWrapper(DiagonalVectorType &a_diagonal)
NumTraits< Scalar >::Real RealScalar
DiagonalShape StorageKind
internal::traits< DiagonalMatrix >::DiagonalVectorType DiagonalVectorType
const EIGEN_DEVICE_FUNC Product< Derived, MatrixDerived, LazyProduct > operator*(const MatrixBase< MatrixDerived > &matrix) const
const typedef DiagonalMatrix & Nested
const EIGEN_DEVICE_FUNC DiagonalVectorType & diagonal() const
DiagonalVectorType::StorageIndex StorageIndex
void product(const MatrixType &m)
static void run(DstXprType &dst, const SrcXprType &src, const internal::assign_op< typename DstXprType::Scalar, typename SrcXprType::Scalar > &)
DiagonalMatrix(const DiagonalMatrix &other)
The matrix class, also used for vectors and row-vectors.
EIGEN_DEVICE_FUNC EIGEN_ALWAYS_INLINE internal::enable_if< NumTraits< T >::IsSigned||NumTraits< T >::IsComplex, typename NumTraits< T >::Real >::type abs(const T &x)
const EIGEN_DEVICE_FUNC DiagonalWrapper< const EIGEN_CWISE_BINARY_RETURN_TYPE(DiagonalVectorType, typename OtherDerived::DiagonalVectorType, sum) > operator+(const DiagonalBase< OtherDerived > &other) const
Base class for all dense matrices, vectors, and expressions.
static void run(DstXprType &dst, const SrcXprType &src, const internal::sub_assign_op< typename DstXprType::Scalar, typename SrcXprType::Scalar > &)
EIGEN_DEVICE_FUNC DiagonalMatrix(const DiagonalBase< OtherDerived > &other)
const unsigned int NoPreferredStorageOrderBit
EIGEN_DEVICE_FUNC DiagonalMatrix(const Scalar &x, const Scalar &y, const Scalar &z)
traits< DiagonalVectorType >::XprKind XprKind
EIGEN_DEVICE_FUNC void setZero(Index size)
EIGEN_DEVICE_FUNC void setIdentity()
EIGEN_DEVICE_FUNC DiagonalMatrix(const MatrixBase< OtherDerived > &other)
const EIGEN_DEVICE_FUNC DiagonalWrapper< const EIGEN_EXPR_BINARYOP_SCALAR_RETURN_TYPE(DiagonalVectorType, Scalar, product) > operator*(const Scalar &scalar) const
EIGEN_DEVICE_FUNC void setZero()
#define EIGEN_CWISE_BINARY_RETURN_TYPE(LHS, RHS, OPNAME)
EIGEN_DEVICE_FUNC Derived & derived()
EIGEN_DEFAULT_DENSE_INDEX_TYPE Index
The Index type as used for the API.
gtsam
Author(s):
autogenerated on Fri Nov 1 2024 03:32:26