Public Member Functions | Protected Attributes
pcl::on_nurbs::SparseMat Class Reference

Sparse matrix implementation. More...

#include <sparse_mat.h>

List of all members.

Public Member Functions

void clear ()
 Clear memory of matrix (=set to zero)
void deleteColumn (int j)
 Delete column at index j (= set to zero)
void deleteRow (int i)
 Delete row at index i (= set to zero)
void get (std::vector< int > &i, std::vector< int > &j, std::vector< double > &v)
 Get a set of values defined by index vectors.
double get (int i, int j)
 Get matrix values at index pair (i,j)
int nonzeros ()
 Get number of non-zero entries in matrix.
void print ()
 Print indices and values of non-zero entries.
void printLong ()
 Print all matrix entries with respect to size.
void set (int i, int j, double v)
 Set matrix values at index pair (i,j)
void size (int &si, int &sj)
 Get size of matrix with respect to last non-zero entries.
 SparseMat ()
 Constructor clearing memory of matrix (=set to zero)

Protected Attributes

std::map< int, std::map< int,
double > > 
m_mat

Detailed Description

Sparse matrix implementation.

Definition at line 51 of file sparse_mat.h.


Constructor & Destructor Documentation

Constructor clearing memory of matrix (=set to zero)

Definition at line 58 of file sparse_mat.h.


Member Function Documentation

void pcl::on_nurbs::SparseMat::clear ( void  ) [inline]

Clear memory of matrix (=set to zero)

Definition at line 91 of file sparse_mat.h.

void SparseMat::deleteColumn ( int  j)

Delete column at index j (= set to zero)

Definition at line 140 of file sparse_mat.cpp.

void SparseMat::deleteRow ( int  i)

Delete row at index i (= set to zero)

Definition at line 128 of file sparse_mat.cpp.

void SparseMat::get ( std::vector< int > &  i,
std::vector< int > &  j,
std::vector< double > &  v 
)

Get a set of values defined by index vectors.

Parameters:
[in]ivector of row indices
[in]jvector of column indices
[out]vvector of matrix entries at (i,j)

Definition at line 44 of file sparse_mat.cpp.

double SparseMat::get ( int  i,
int  j 
)

Get matrix values at index pair (i,j)

Parameters:
[in]irow index
[in]jcolumn index return v matrix value at (i,j)

Definition at line 70 of file sparse_mat.cpp.

Get number of non-zero entries in matrix.

Definition at line 190 of file sparse_mat.cpp.

void SparseMat::print ( )

Print indices and values of non-zero entries.

Definition at line 227 of file sparse_mat.cpp.

Print all matrix entries with respect to size.

Definition at line 208 of file sparse_mat.cpp.

void SparseMat::set ( int  i,
int  j,
double  v 
)

Set matrix values at index pair (i,j)

Parameters:
[in]irow index
[in]jcolumn index
[in]vmatrix value at (i,j)

Definition at line 88 of file sparse_mat.cpp.

void SparseMat::size ( int &  si,
int &  sj 
)

Get size of matrix with respect to last non-zero entries.

Definition at line 157 of file sparse_mat.cpp.


Member Data Documentation

std::map<int, std::map<int, double> > pcl::on_nurbs::SparseMat::m_mat [protected]

Definition at line 54 of file sparse_mat.h.


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


pcl
Author(s): Open Perception
autogenerated on Wed Aug 26 2015 15:44:32