Classes | Public Types | Public Member Functions | Static Protected Member Functions | Protected Attributes | Private Types | Friends
Eigen::SparseVector< _Scalar, _Options, _Index > Class Template Reference

a sparse vector class More...

#include <SparseVector.h>

Inheritance diagram for Eigen::SparseVector< _Scalar, _Options, _Index >:
Inheritance graph
[legend]

List of all members.

Classes

class  InnerIterator
class  ReverseInnerIterator

Public Types

enum  { IsColVector = internal::traits<SparseVector>::IsColVector }
enum  { Options = _Options }
typedef
internal::CompressedStorage
< Scalar, Index
Storage

Public Member Functions

EIGEN_DEPRECATED Storage_data ()
EIGEN_DEPRECATED const Storage_data () const
Scalar coeff (Index row, Index col) const
Scalar coeff (Index i) const
ScalarcoeffRef (Index row, Index col)
ScalarcoeffRef (Index i)
EIGEN_STRONG_INLINE Index cols () const
Storagedata ()
const Storagedata () const
EIGEN_DEPRECATED void endFill ()
EIGEN_DEPRECATED Scalarfill (Index r, Index c)
EIGEN_DEPRECATED Scalarfill (Index i)
EIGEN_DEPRECATED Scalarfillrand (Index r, Index c)
EIGEN_DEPRECATED Scalarfillrand (Index i)
void finalize ()
EIGEN_STRONG_INLINE const IndexinnerIndexPtr () const
EIGEN_STRONG_INLINE IndexinnerIndexPtr ()
EIGEN_STRONG_INLINE Index innerSize () const
Scalarinsert (Index row, Index col)
Scalarinsert (Index i)
ScalarinsertBack (Index i)
ScalarinsertBackByOuterInner (Index outer, Index inner)
Index nonZeros () const
SparseVectoroperator= (const SparseVector &other)
template<typename OtherDerived >
SparseVectoroperator= (const SparseMatrixBase< OtherDerived > &other)
template<typename Lhs , typename Rhs >
SparseVectoroperator= (const SparseSparseProduct< Lhs, Rhs > &product)
EIGEN_STRONG_INLINE Index outerSize () const
void prune (const Scalar &reference, const RealScalar &epsilon=NumTraits< RealScalar >::dummy_precision())
void reserve (Index reserveSize)
void resize (Index rows, Index cols)
void resize (Index newSize)
void resizeNonZeros (Index size)
EIGEN_STRONG_INLINE Index rows () const
void setZero ()
 SparseVector ()
 SparseVector (Index size)
 SparseVector (Index rows, Index cols)
template<typename OtherDerived >
 SparseVector (const SparseMatrixBase< OtherDerived > &other)
 SparseVector (const SparseVector &other)
EIGEN_DEPRECATED void startFill (Index reserve)
void startVec (Index outer)
Scalar sum () const
void swap (SparseVector &other)
EIGEN_STRONG_INLINE const ScalarvaluePtr () const
EIGEN_STRONG_INLINE ScalarvaluePtr ()
 ~SparseVector ()

Static Protected Member Functions

static void check_template_parameters ()

Protected Attributes

Storage m_data
Index m_size

Private Types

typedef SparseMatrixBase
< SparseVector
SparseBase

Friends

std::ostream & operator<< (std::ostream &s, const SparseVector &m)

Detailed Description

template<typename _Scalar, int _Options, typename _Index>
class Eigen::SparseVector< _Scalar, _Options, _Index >

a sparse vector class

Template Parameters:
_Scalarthe scalar type, i.e. the type of the coefficients

See http://www.netlib.org/linalg/html_templates/node91.html for details on the storage scheme.

This class can be extended with the help of the plugin mechanism described on the page TopicCustomizingEigen by defining the preprocessor symbol EIGEN_SPARSEVECTOR_PLUGIN.

Definition at line 65 of file SparseVector.h.


Member Typedef Documentation

template<typename _Scalar , int _Options, typename _Index >
typedef SparseMatrixBase<SparseVector> Eigen::SparseVector< _Scalar, _Options, _Index >::SparseBase [private]

Definition at line 68 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
typedef internal::CompressedStorage<Scalar,Index> Eigen::SparseVector< _Scalar, _Options, _Index >::Storage

Definition at line 75 of file SparseVector.h.


Member Enumeration Documentation

template<typename _Scalar , int _Options, typename _Index >
anonymous enum
Enumerator:
IsColVector 

Definition at line 76 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
anonymous enum
Enumerator:
Options 

Definition at line 78 of file SparseVector.h.


Constructor & Destructor Documentation

template<typename _Scalar , int _Options, typename _Index >
Eigen::SparseVector< _Scalar, _Options, _Index >::SparseVector ( ) [inline]

Definition at line 210 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Eigen::SparseVector< _Scalar, _Options, _Index >::SparseVector ( Index  size) [inline]

Definition at line 212 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Eigen::SparseVector< _Scalar, _Options, _Index >::SparseVector ( Index  rows,
Index  cols 
) [inline]

Definition at line 214 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
template<typename OtherDerived >
Eigen::SparseVector< _Scalar, _Options, _Index >::SparseVector ( const SparseMatrixBase< OtherDerived > &  other) [inline]

Definition at line 217 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Eigen::SparseVector< _Scalar, _Options, _Index >::SparseVector ( const SparseVector< _Scalar, _Options, _Index > &  other) [inline]

Definition at line 224 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Eigen::SparseVector< _Scalar, _Options, _Index >::~SparseVector ( ) [inline]

Destructor

Definition at line 281 of file SparseVector.h.


Member Function Documentation

template<typename _Scalar , int _Options, typename _Index >
EIGEN_DEPRECATED Storage& Eigen::SparseVector< _Scalar, _Options, _Index >::_data ( ) [inline]

Definition at line 327 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_DEPRECATED const Storage& Eigen::SparseVector< _Scalar, _Options, _Index >::_data ( ) const [inline]

Definition at line 329 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
static void Eigen::SparseVector< _Scalar, _Options, _Index >::check_template_parameters ( ) [inline, static, protected]

Definition at line 337 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Scalar Eigen::SparseVector< _Scalar, _Options, _Index >::coeff ( Index  row,
Index  col 
) const [inline]

Definition at line 98 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Scalar Eigen::SparseVector< _Scalar, _Options, _Index >::coeff ( Index  i) const [inline]

Definition at line 103 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Scalar& Eigen::SparseVector< _Scalar, _Options, _Index >::coeffRef ( Index  row,
Index  col 
) [inline]

Definition at line 109 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Scalar& Eigen::SparseVector< _Scalar, _Options, _Index >::coeffRef ( Index  i) [inline]
Returns:
a reference to the coefficient value at given index i This operation involes a log(rho*size) binary search. If the coefficient does not exist yet, then a sorted insertion into a sequential buffer is performed.

This insertion might be very costly if the number of nonzeros above i is large.

Definition at line 121 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_STRONG_INLINE Index Eigen::SparseVector< _Scalar, _Options, _Index >::cols ( void  ) const [inline]
Returns:
the number of columns.
See also:
rows()

Reimplemented from Eigen::SparseMatrixBase< SparseVector< _Scalar, _Options, _Index > >.

Definition at line 83 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Storage& Eigen::SparseVector< _Scalar, _Options, _Index >::data ( ) [inline]

Definition at line 94 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
const Storage& Eigen::SparseVector< _Scalar, _Options, _Index >::data ( ) const [inline]

Definition at line 96 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_DEPRECATED void Eigen::SparseVector< _Scalar, _Options, _Index >::endFill ( ) [inline]

Definition at line 323 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_DEPRECATED Scalar& Eigen::SparseVector< _Scalar, _Options, _Index >::fill ( Index  r,
Index  c 
) [inline]

Definition at line 296 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_DEPRECATED Scalar& Eigen::SparseVector< _Scalar, _Options, _Index >::fill ( Index  i) [inline]

Definition at line 303 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_DEPRECATED Scalar& Eigen::SparseVector< _Scalar, _Options, _Index >::fillrand ( Index  r,
Index  c 
) [inline]

Definition at line 310 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_DEPRECATED Scalar& Eigen::SparseVector< _Scalar, _Options, _Index >::fillrand ( Index  i) [inline]

Definition at line 317 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
void Eigen::SparseVector< _Scalar, _Options, _Index >::finalize ( ) [inline]

Definition at line 189 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_STRONG_INLINE const Index* Eigen::SparseVector< _Scalar, _Options, _Index >::innerIndexPtr ( ) const [inline]

Definition at line 90 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_STRONG_INLINE Index* Eigen::SparseVector< _Scalar, _Options, _Index >::innerIndexPtr ( ) [inline]

Definition at line 91 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_STRONG_INLINE Index Eigen::SparseVector< _Scalar, _Options, _Index >::innerSize ( ) const [inline]
Returns:
the size of the inner dimension according to the storage order, i.e., the number of rows for a columns major matrix, and the number of cols otherwise

Reimplemented from Eigen::SparseMatrixBase< SparseVector< _Scalar, _Options, _Index > >.

Definition at line 84 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Scalar& Eigen::SparseVector< _Scalar, _Options, _Index >::insert ( Index  row,
Index  col 
) [inline]

Definition at line 155 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Scalar& Eigen::SparseVector< _Scalar, _Options, _Index >::insert ( Index  i) [inline]

Definition at line 164 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Scalar& Eigen::SparseVector< _Scalar, _Options, _Index >::insertBack ( Index  i) [inline]

Definition at line 149 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Scalar& Eigen::SparseVector< _Scalar, _Options, _Index >::insertBackByOuterInner ( Index  outer,
Index  inner 
) [inline]

Definition at line 143 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Index Eigen::SparseVector< _Scalar, _Options, _Index >::nonZeros ( ) const [inline]
Returns:
the number of non zero coefficients

Reimplemented from Eigen::SparseMatrixBase< SparseVector< _Scalar, _Options, _Index > >.

Definition at line 135 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
SparseVector& Eigen::SparseVector< _Scalar, _Options, _Index >::operator= ( const SparseVector< _Scalar, _Options, _Index > &  other) [inline]
template<typename _Scalar , int _Options, typename _Index >
template<typename OtherDerived >
SparseVector& Eigen::SparseVector< _Scalar, _Options, _Index >::operator= ( const SparseMatrixBase< OtherDerived > &  other) [inline]
template<typename _Scalar , int _Options, typename _Index >
template<typename Lhs , typename Rhs >
SparseVector& Eigen::SparseVector< _Scalar, _Options, _Index >::operator= ( const SparseSparseProduct< Lhs, Rhs > &  product) [inline]
template<typename _Scalar , int _Options, typename _Index >
EIGEN_STRONG_INLINE Index Eigen::SparseVector< _Scalar, _Options, _Index >::outerSize ( ) const [inline]
Returns:
the size of the storage major dimension, i.e., the number of columns for a columns major matrix, and the number of rows otherwise

Reimplemented from Eigen::SparseMatrixBase< SparseVector< _Scalar, _Options, _Index > >.

Definition at line 85 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
void Eigen::SparseVector< _Scalar, _Options, _Index >::prune ( const Scalar reference,
const RealScalar epsilon = NumTraits<RealScalar>::dummy_precision() 
) [inline]

Definition at line 191 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
void Eigen::SparseVector< _Scalar, _Options, _Index >::reserve ( Index  reserveSize) [inline]

Definition at line 186 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
void Eigen::SparseVector< _Scalar, _Options, _Index >::resize ( Index  rows,
Index  cols 
) [inline]

Definition at line 196 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
void Eigen::SparseVector< _Scalar, _Options, _Index >::resize ( Index  newSize) [inline]

Definition at line 202 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
void Eigen::SparseVector< _Scalar, _Options, _Index >::resizeNonZeros ( Index  size) [inline]

Definition at line 208 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_STRONG_INLINE Index Eigen::SparseVector< _Scalar, _Options, _Index >::rows ( void  ) const [inline]
Returns:
the number of rows.
See also:
cols()

Reimplemented from Eigen::SparseMatrixBase< SparseVector< _Scalar, _Options, _Index > >.

Definition at line 82 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
void Eigen::SparseVector< _Scalar, _Options, _Index >::setZero ( ) [inline]

Definition at line 132 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_DEPRECATED void Eigen::SparseVector< _Scalar, _Options, _Index >::startFill ( Index  reserve) [inline]

Definition at line 289 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
void Eigen::SparseVector< _Scalar, _Options, _Index >::startVec ( Index  outer) [inline]

Definition at line 137 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
internal::traits< SparseVector< _Scalar, _Options, _Index > >::Scalar Eigen::SparseVector< _Scalar, _Options, _Index >::sum ( ) const

Overloaded for performance

Reimplemented from Eigen::SparseMatrixBase< SparseVector< _Scalar, _Options, _Index > >.

Definition at line 37 of file SparseRedux.h.

template<typename _Scalar , int _Options, typename _Index >
void Eigen::SparseVector< _Scalar, _Options, _Index >::swap ( SparseVector< _Scalar, _Options, _Index > &  other) [inline]

Swaps the values of *this and other. Overloaded for performance: this version performs a shallow swap by swaping pointers and attributes only.

See also:
SparseMatrixBase::swap()

Definition at line 235 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_STRONG_INLINE const Scalar* Eigen::SparseVector< _Scalar, _Options, _Index >::valuePtr ( ) const [inline]

Definition at line 87 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
EIGEN_STRONG_INLINE Scalar* Eigen::SparseVector< _Scalar, _Options, _Index >::valuePtr ( ) [inline]

Definition at line 88 of file SparseVector.h.


Friends And Related Function Documentation

template<typename _Scalar , int _Options, typename _Index >
std::ostream& operator<< ( std::ostream &  s,
const SparseVector< _Scalar, _Options, _Index > &  m 
) [friend]

Definition at line 272 of file SparseVector.h.


Member Data Documentation

template<typename _Scalar , int _Options, typename _Index >
Storage Eigen::SparseVector< _Scalar, _Options, _Index >::m_data [protected]

Definition at line 343 of file SparseVector.h.

template<typename _Scalar , int _Options, typename _Index >
Index Eigen::SparseVector< _Scalar, _Options, _Index >::m_size [protected]

Definition at line 344 of file SparseVector.h.


The documentation for this class was generated from the following files:


acado
Author(s): Milan Vukov, Rien Quirynen
autogenerated on Sat Jun 8 2019 19:40:54