#include <vector>
#include <Eigen/SparseCore>
|
| template<typename Scalar, int Options, typename StorageIndex> |
| std::vector< Eigen::Triplet< Scalar > > | SparseMatrixToTriplets (const Eigen::SparseMatrix< Scalar, Options, StorageIndex > &matrix) |
| | For a sparse matrix, return a vector of triplets, such that we can reconstruct the matrix using setFromTriplet function.
|
| template<typename Derived> |
| void | SparseMatrixToRowColumnValueVectors (const Derived &matrix, std::vector< Eigen::Index > &row_indices, std::vector< Eigen::Index > &col_indices, std::vector< typename Derived::Scalar > &val) |
| | For a sparse matrix, return the row indices, the column indices, and value of the non-zero entries.
|