Classes | Public Types | Public Member Functions | Protected Attributes | List of all members
g2o::SparseBlockMatrixCCS< MatrixType > Class Template Reference

Sparse matrix which uses blocks. More...

#include <sparse_block_matrix_ccs.h>

Classes

struct  RowBlock
 A block within a column. More...
 

Public Types

typedef std::vector< RowBlockSparseColumn
 
typedef MatrixType SparseMatrixBlock
 this is the type of the elementary block, it is an Eigen::Matrix. More...
 

Public Member Functions

const std::vector< SparseColumn > & blockCols () const
 the block matrices per block-column More...
 
std::vector< SparseColumn > & blockCols ()
 
int colBaseOfBlock (int c) const
 where does the col at block-col r start? More...
 
const std::vector< int > & colBlockIndices () const
 indices of the column blocks More...
 
int cols () const
 columns of the matrix More...
 
int colsOfBlock (int c) const
 how many cols does the block at block-col c has? More...
 
int fillCCS (int *Cp, int *Ci, double *Cx, bool upperTriangle=false) const
 
int fillCCS (double *Cx, bool upperTriangle=false) const
 
void rightMultiply (double *&dest, const double *src) const
 
int rowBaseOfBlock (int r) const
 where does the row at block-row r start? More...
 
const std::vector< int > & rowBlockIndices () const
 indices of the row blocks More...
 
int rows () const
 rows of the matrix More...
 
int rowsOfBlock (int r) const
 how many rows does the block at block-row r has? More...
 
void sortColumns ()
 
 SparseBlockMatrixCCS (const std::vector< int > &rowIndices, const std::vector< int > &colIndices)
 

Protected Attributes

std::vector< SparseColumn_blockCols
 the matrices stored in CCS order More...
 
const std::vector< int > & _colBlockIndices
 vector of the indices of the blocks along the cols More...
 
const std::vector< int > & _rowBlockIndices
 vector of the indices of the blocks along the rows. More...
 

Detailed Description

template<class MatrixType>
class g2o::SparseBlockMatrixCCS< MatrixType >

Sparse matrix which uses blocks.

This class is used as a const view on a SparseBlockMatrix which allows a faster iteration over the elements of the matrix.

Definition at line 53 of file sparse_block_matrix_ccs.h.

Member Typedef Documentation

template<class MatrixType>
typedef std::vector<RowBlock> g2o::SparseBlockMatrixCCS< MatrixType >::SparseColumn

Definition at line 75 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
typedef MatrixType g2o::SparseBlockMatrixCCS< MatrixType >::SparseMatrixBlock

this is the type of the elementary block, it is an Eigen::Matrix.

Definition at line 57 of file sparse_block_matrix_ccs.h.

Constructor & Destructor Documentation

template<class MatrixType>
g2o::SparseBlockMatrixCCS< MatrixType >::SparseBlockMatrixCCS ( const std::vector< int > &  rowIndices,
const std::vector< int > &  colIndices 
)
inline

Definition at line 77 of file sparse_block_matrix_ccs.h.

Member Function Documentation

template<class MatrixType>
const std::vector<SparseColumn>& g2o::SparseBlockMatrixCCS< MatrixType >::blockCols ( ) const
inline

the block matrices per block-column

Definition at line 94 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
std::vector<SparseColumn>& g2o::SparseBlockMatrixCCS< MatrixType >::blockCols ( )
inline

Definition at line 95 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
int g2o::SparseBlockMatrixCCS< MatrixType >::colBaseOfBlock ( int  c) const
inline

where does the col at block-col r start?

Definition at line 91 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
const std::vector<int>& g2o::SparseBlockMatrixCCS< MatrixType >::colBlockIndices ( ) const
inline

indices of the column blocks

Definition at line 101 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
int g2o::SparseBlockMatrixCCS< MatrixType >::cols ( ) const
inline

columns of the matrix

Definition at line 60 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
int g2o::SparseBlockMatrixCCS< MatrixType >::colsOfBlock ( int  c) const
inline

how many cols does the block at block-col c has?

Definition at line 85 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
int g2o::SparseBlockMatrixCCS< MatrixType >::fillCCS ( int *  Cp,
int *  Ci,
double *  Cx,
bool  upperTriangle = false 
) const
inline

fill the CCS arrays of a matrix, arrays have to be allocated beforehand

Definition at line 143 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
int g2o::SparseBlockMatrixCCS< MatrixType >::fillCCS ( double *  Cx,
bool  upperTriangle = false 
) const
inline

fill the CCS arrays of a matrix, arrays have to be allocated beforehand. This function only writes the values and assumes that column and row structures have already been written.

Definition at line 176 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
void g2o::SparseBlockMatrixCCS< MatrixType >::rightMultiply ( double *&  dest,
const double *  src 
) const
inline

Definition at line 103 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
int g2o::SparseBlockMatrixCCS< MatrixType >::rowBaseOfBlock ( int  r) const
inline

where does the row at block-row r start?

Definition at line 88 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
const std::vector<int>& g2o::SparseBlockMatrixCCS< MatrixType >::rowBlockIndices ( ) const
inline

indices of the row blocks

Definition at line 98 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
int g2o::SparseBlockMatrixCCS< MatrixType >::rows ( ) const
inline

rows of the matrix

Definition at line 62 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
int g2o::SparseBlockMatrixCCS< MatrixType >::rowsOfBlock ( int  r) const
inline

how many rows does the block at block-row r has?

Definition at line 82 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
void g2o::SparseBlockMatrixCCS< MatrixType >::sortColumns ( )
inline

sort the blocks in each column

Definition at line 133 of file sparse_block_matrix_ccs.h.

Member Data Documentation

template<class MatrixType>
std::vector<SparseColumn> g2o::SparseBlockMatrixCCS< MatrixType >::_blockCols
protected

the matrices stored in CCS order

Definition at line 204 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
const std::vector<int>& g2o::SparseBlockMatrixCCS< MatrixType >::_colBlockIndices
protected

vector of the indices of the blocks along the cols

Definition at line 203 of file sparse_block_matrix_ccs.h.

template<class MatrixType>
const std::vector<int>& g2o::SparseBlockMatrixCCS< MatrixType >::_rowBlockIndices
protected

vector of the indices of the blocks along the rows.

Definition at line 202 of file sparse_block_matrix_ccs.h.


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


orb_slam2_ros
Author(s):
autogenerated on Wed Apr 21 2021 02:53:06