#include <jrl/mal/boostmatrixsvd.hh>
Public Member Functions | |
MatrixSvd (const unsigned int rows=0, const unsigned int cols=0) | |
MatrixSvd (InternalMatrix *clone, const bool=false) | |
MatrixSvd (const MatrixSvd ©) | |
virtual Matrix & | pseudoInverse (Matrix &invMatrix, const FloatType threshold=1e-6, Matrix *Uref=NULL, Vector *Sref=NULL, Matrix *Vref=NULL) const |
Compute the pseudo-inverse of the matrix. | |
virtual Matrix & | dampedInverse (Matrix &invMatrix, const FloatType threshold=1e-6, Matrix *Uref=NULL, Vector *Sref=NULL, Matrix *Vref=NULL) const |
Compute the pseudo-inverse of the matrix. | |
Protected Member Functions | |
bool | reviseMemory (void) const |
void | initSvdMemory (void) const |
Protected Attributes | |
size_t | nbrows |
size_t | nbcols |
size_t | nmajor |
size_t | nminor |
bool | toTranspose |
mutable::boost::numeric::ublas::matrix < FloatType,::boost::numeric::ublas::column_major > | McolMajor |
mutable::boost::numeric::ublas::matrix < FloatType,::boost::numeric::ublas::column_major > | U |
mutable::boost::numeric::ublas::matrix < FloatType,::boost::numeric::ublas::column_major > | VT |
mutable::boost::numeric::ublas::vector < FloatType > | s |
mutable::boost::numeric::ublas::vector < double > | w |
mutable::boost::numeric::ublas::vector < FloatType > | sp |
int | lw |
int | lda |
int | lu |
int | lvt |
unsigned int | rankJ |
maal::boost::MatrixSvd::MatrixSvd | ( | const unsigned int | rows = 0 , |
const unsigned int | cols = 0 |
||
) | [inline] |
maal::boost::MatrixSvd::MatrixSvd | ( | InternalMatrix * | clone, |
const bool | = false |
||
) | [inline] |
maal::boost::MatrixSvd::MatrixSvd | ( | const MatrixSvd & | copy | ) | [inline] |
virtual Matrix& maal::boost::MatrixSvd::dampedInverse | ( | Matrix & | invMatrix, |
const FloatType | threshold = 1e-6 , |
||
Matrix * | Uref = NULL , |
||
Vector * | Sref = NULL , |
||
Matrix * | Vref = NULL |
||
) | const [inline, virtual] |
Compute the pseudo-inverse of the matrix.
By default, the function uses the dgesvd_ fortran routine. It should be provided by the host software.
Reimplemented from maal::boost::Matrix.
References maal::boost::Matrix::_resizeInv(), dgesvd_(), initSvdMemory(), lda, lu, lvt, lw, maal::boost::Matrix::matrix, maal::boost::Matrix::max(), McolMajor, MRAWDATA, nbcols, nbrows, nminor, rankJ, s, sp, toTranspose, U, VRAWDATA, VT, and w.
void maal::boost::MatrixSvd::initSvdMemory | ( | void | ) | const [inline, protected] |
References dgesvd_(), lda, lw, maal::boost::Matrix::matrix, maal::boost::Matrix::max(), McolMajor, MRAWDATA, nbcols, nbrows, nmajor, nminor, reviseMemory(), s, sp, toTranspose, U, VT, and w.
Referenced by dampedInverse(), and pseudoInverse().
virtual Matrix& maal::boost::MatrixSvd::pseudoInverse | ( | Matrix & | invMatrix, |
const FloatType | threshold = 1e-6 , |
||
Matrix * | Uref = NULL , |
||
Vector * | Sref = NULL , |
||
Matrix * | Vref = NULL |
||
) | const [inline, virtual] |
Compute the pseudo-inverse of the matrix.
By default, the function uses the dgesvd_ fortran routine. It should be provided by the host software.
Reimplemented from maal::boost::Matrix.
References maal::boost::Matrix::_resizeInv(), dgesvd_(), initSvdMemory(), lda, lu, lvt, lw, maal::boost::Matrix::matrix, maal::boost::Matrix::max(), McolMajor, MRAWDATA, nbcols, nbrows, nminor, rankJ, s, sp, toTranspose, U, VRAWDATA, VT, and w.
bool maal::boost::MatrixSvd::reviseMemory | ( | void | ) | const [inline, protected] |
References maal::boost::Matrix::matrix, nbcols, nbrows, and toTranspose.
Referenced by initSvdMemory().
int maal::boost::MatrixSvd::lda [mutable, protected] |
Referenced by dampedInverse(), initSvdMemory(), and pseudoInverse().
int maal::boost::MatrixSvd::lu [mutable, protected] |
Referenced by dampedInverse(), and pseudoInverse().
int maal::boost::MatrixSvd::lvt [mutable, protected] |
Referenced by dampedInverse(), and pseudoInverse().
int maal::boost::MatrixSvd::lw [mutable, protected] |
Referenced by dampedInverse(), initSvdMemory(), and pseudoInverse().
mutable ::boost::numeric::ublas::matrix<FloatType,::boost::numeric::ublas::column_major> maal::boost::MatrixSvd::McolMajor [protected] |
Referenced by dampedInverse(), initSvdMemory(), and pseudoInverse().
size_t maal::boost::MatrixSvd::nbcols [mutable, protected] |
Referenced by dampedInverse(), initSvdMemory(), pseudoInverse(), and reviseMemory().
size_t maal::boost::MatrixSvd::nbrows [mutable, protected] |
Referenced by dampedInverse(), initSvdMemory(), pseudoInverse(), and reviseMemory().
size_t maal::boost::MatrixSvd::nmajor [mutable, protected] |
Referenced by initSvdMemory().
size_t maal::boost::MatrixSvd::nminor [mutable, protected] |
Referenced by dampedInverse(), initSvdMemory(), and pseudoInverse().
unsigned int maal::boost::MatrixSvd::rankJ [mutable, protected] |
Referenced by dampedInverse(), and pseudoInverse().
mutable ::boost::numeric::ublas::vector<FloatType> maal::boost::MatrixSvd::s [protected] |
Referenced by dampedInverse(), initSvdMemory(), and pseudoInverse().
mutable ::boost::numeric::ublas::vector<FloatType> maal::boost::MatrixSvd::sp [protected] |
Referenced by dampedInverse(), initSvdMemory(), and pseudoInverse().
bool maal::boost::MatrixSvd::toTranspose [mutable, protected] |
Referenced by dampedInverse(), initSvdMemory(), pseudoInverse(), and reviseMemory().
mutable ::boost::numeric::ublas::matrix<FloatType,::boost::numeric::ublas::column_major> maal::boost::MatrixSvd::U [protected] |
Referenced by dampedInverse(), initSvdMemory(), and pseudoInverse().
mutable ::boost::numeric::ublas::matrix<FloatType,::boost::numeric::ublas::column_major> maal::boost::MatrixSvd::VT [protected] |
Referenced by dampedInverse(), initSvdMemory(), and pseudoInverse().
mutable ::boost::numeric::ublas::vector<double> maal::boost::MatrixSvd::w [protected] |
Referenced by dampedInverse(), initSvdMemory(), and pseudoInverse().