mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-01-18 14:34:17 +08:00
Pass a const matrix to sparseQR
This commit is contained in:
parent
33febdb48b
commit
121f3bdf04
@ -79,13 +79,13 @@ class SparseQR
|
||||
{
|
||||
compute(mat);
|
||||
}
|
||||
void compute(/*const*/ MatrixType& mat)
|
||||
void compute(const MatrixType& mat)
|
||||
{
|
||||
analyzePattern(mat);
|
||||
factorize(mat);
|
||||
}
|
||||
void analyzePattern(const MatrixType& mat);
|
||||
void factorize(/*const*/ MatrixType& mat);
|
||||
void factorize(const MatrixType& mat);
|
||||
|
||||
/**
|
||||
* Get the number of rows of the triangular matrix.
|
||||
@ -223,7 +223,7 @@ void SparseQR<MatrixType,OrderingType>::analyzePattern(const MatrixType& mat)
|
||||
* \param mat The sparse column-major matrix
|
||||
*/
|
||||
template <typename MatrixType, typename OrderingType>
|
||||
void SparseQR<MatrixType,OrderingType>::factorize(MatrixType& mat)
|
||||
void SparseQR<MatrixType,OrderingType>::factorize(const MatrixType& mat)
|
||||
{
|
||||
eigen_assert(m_analysisIsok && "analyzePattern() should be called before this step");
|
||||
Index m = mat.rows();
|
||||
|
Loading…
Reference in New Issue
Block a user