|
MRPT
1.9.9
|
#include <mrpt/math/CSparseMatrix.h>#include <mrpt/random.h>#include <CTraitsTest.h>#include <gtest/gtest.h>
Go to the source code of this file.
Typedefs | |
| using | TMatrixSMOperator = void(*)(const CSparseMatrix &M1, const CSparseMatrix &M2, CSparseMatrix &res) |
| using | TMatrixDenseOperator = void(*)(const CMatrixDouble &M1, const CMatrixDouble &M2, CMatrixDouble &res) |
Functions | |
| void | generateRandomSparseMatrix (size_t N, size_t M, size_t nEntries, CSparseMatrix &MAT) |
| void | do_test_init_to_unit (size_t N) |
| TEST (SparseMatrix, InitFromDenseUnit) | |
| void | do_test_init_random (size_t N) |
| TEST (SparseMatrix, InitFromDenseRandom) | |
| TEST (SparseMatrix, InitFromTriplet) | |
| TEST (SparseMatrix, InitFromSparse) | |
| TEST (SparseMatrix, InitFromRandom) | |
| void | do_matrix_op_test (size_t nRows1, size_t nCols1, size_t nNonZeros1, size_t nRows2, size_t nCols2, size_t nNonZeros2, TMatrixSMOperator op1, TMatrixDenseOperator op2) |
| void | op_sparse_add (const CSparseMatrix &M1, const CSparseMatrix &M2, CSparseMatrix &res) |
| void | op_dense_add (const CMatrixDouble &M1, const CMatrixDouble &M2, CMatrixDouble &res) |
| TEST (SparseMatrix, Op_Add) | |
| void | op_sparse_multiply_AB (const CSparseMatrix &M1, const CSparseMatrix &M2, CSparseMatrix &res) |
| void | op_dense_multiply_AB (const CMatrixDouble &M1, const CMatrixDouble &M2, CMatrixDouble &res) |
| TEST (SparseMatrix, Op_Multiply_AB) | |
| TEST (SparseMatrix, CholeskyDecomp) | |
| using TMatrixDenseOperator = void (*)( const CMatrixDouble& M1, const CMatrixDouble& M2, CMatrixDouble& res) |
Definition at line 130 of file CSparseMatrix_unittest.cpp.
| using TMatrixSMOperator = void (*)( const CSparseMatrix& M1, const CSparseMatrix& M2, CSparseMatrix& res) |
Definition at line 128 of file CSparseMatrix_unittest.cpp.
| void do_matrix_op_test | ( | size_t | nRows1, |
| size_t | nCols1, | ||
| size_t | nNonZeros1, | ||
| size_t | nRows2, | ||
| size_t | nCols2, | ||
| size_t | nNonZeros2, | ||
| TMatrixSMOperator | op1, | ||
| TMatrixDenseOperator | op2 | ||
| ) |
Definition at line 132 of file CSparseMatrix_unittest.cpp.
References generateRandomSparseMatrix(), and mrpt::math::CSparseMatrix::get_dense().
Referenced by TEST().
| void do_test_init_random | ( | size_t | N | ) |
Definition at line 61 of file CSparseMatrix_unittest.cpp.
References mrpt::random::CRandomGenerator::drawGaussian1DMatrix(), mrpt::math::CSparseMatrix::get_dense(), and mrpt::random::getRandomGenerator().
Referenced by TEST().
| void do_test_init_to_unit | ( | size_t | N | ) |
Definition at line 41 of file CSparseMatrix_unittest.cpp.
References mrpt::math::CSparseMatrix::get_dense().
Referenced by TEST().
| void generateRandomSparseMatrix | ( | size_t | N, |
| size_t | M, | ||
| size_t | nEntries, | ||
| CSparseMatrix & | MAT | ||
| ) |
Definition at line 21 of file CSparseMatrix_unittest.cpp.
References mrpt::math::CSparseMatrix::clear(), mrpt::math::CSparseMatrix::compressFromTriplet(), mrpt::random::getRandomGenerator(), mrpt::math::CSparseMatrix::insert_entry(), mrpt::math::CSparseMatrix::setColCount(), and mrpt::math::CSparseMatrix::setRowCount().
Referenced by do_matrix_op_test(), and TEST().
| void op_dense_add | ( | const CMatrixDouble & | M1, |
| const CMatrixDouble & | M2, | ||
| CMatrixDouble & | res | ||
| ) |
Definition at line 168 of file CSparseMatrix_unittest.cpp.
Referenced by TEST().
| void op_dense_multiply_AB | ( | const CMatrixDouble & | M1, |
| const CMatrixDouble & | M2, | ||
| CMatrixDouble & | res | ||
| ) |
Definition at line 188 of file CSparseMatrix_unittest.cpp.
Referenced by TEST().
| void op_sparse_add | ( | const CSparseMatrix & | M1, |
| const CSparseMatrix & | M2, | ||
| CSparseMatrix & | res | ||
| ) |
Definition at line 163 of file CSparseMatrix_unittest.cpp.
Referenced by TEST().
| void op_sparse_multiply_AB | ( | const CSparseMatrix & | M1, |
| const CSparseMatrix & | M2, | ||
| CSparseMatrix & | res | ||
| ) |
Definition at line 183 of file CSparseMatrix_unittest.cpp.
Referenced by TEST().
| TEST | ( | SparseMatrix | , |
| InitFromDenseUnit | |||
| ) |
Definition at line 54 of file CSparseMatrix_unittest.cpp.
References do_test_init_to_unit().
| TEST | ( | SparseMatrix | , |
| InitFromDenseRandom | |||
| ) |
Definition at line 71 of file CSparseMatrix_unittest.cpp.
References do_test_init_random().
| TEST | ( | SparseMatrix | , |
| InitFromTriplet | |||
| ) |
| TEST | ( | SparseMatrix | , |
| InitFromSparse | |||
| ) |
Definition at line 102 of file CSparseMatrix_unittest.cpp.
References mrpt::math::CSparseMatrix::get_dense().
| TEST | ( | SparseMatrix | , |
| InitFromRandom | |||
| ) |
Definition at line 120 of file CSparseMatrix_unittest.cpp.
References generateRandomSparseMatrix().
| TEST | ( | SparseMatrix | , |
| Op_Add | |||
| ) |
Definition at line 174 of file CSparseMatrix_unittest.cpp.
References do_matrix_op_test(), op_dense_add(), and op_sparse_add().
| TEST | ( | SparseMatrix | , |
| Op_Multiply_AB | |||
| ) |
Definition at line 194 of file CSparseMatrix_unittest.cpp.
References do_matrix_op_test(), op_dense_multiply_AB(), and op_sparse_multiply_AB().
| TEST | ( | SparseMatrix | , |
| CholeskyDecomp | |||
| ) |
Definition at line 208 of file CSparseMatrix_unittest.cpp.
References mrpt::math::CSparseMatrix::compressFromTriplet(), mrpt::random::CRandomGenerator::drawDefinitePositiveMatrix(), mrpt::math::CSparseMatrix::get_dense(), mrpt::math::CSparseMatrix::CholeskyDecomp::get_L(), mrpt::random::getRandomGenerator(), and mrpt::math::CSparseMatrix::insert_submatrix().
| Page generated by Doxygen 1.8.14 for MRPT 1.9.9 Git: 7d5e6d718 Fri Aug 24 01:51:28 2018 +0200 at lun nov 2 08:35:50 CET 2020 |