adapt to API changes

This commit is contained in:
Benoit Jacob 2009-08-20 01:29:38 -04:00
parent 59a0c4a0d2
commit c7ae261ac0

View File

@ -227,10 +227,9 @@ inline bool test_ei_isMuchSmallerThan(const MatrixBase<Derived>& m,
return m.isMuchSmallerThan(s, test_precision<typename ei_traits<Derived>::Scalar>()); return m.isMuchSmallerThan(s, test_precision<typename ei_traits<Derived>::Scalar>());
} }
template<typename Derived> template<typename MatrixType>
void createRandomMatrixOfRank(int desired_rank, int rows, int cols, Eigen::MatrixBase<Derived>& m) void createRandomMatrixOfRank(int desired_rank, int rows, int cols, MatrixType& m)
{ {
typedef Derived MatrixType;
typedef typename ei_traits<MatrixType>::Scalar Scalar; typedef typename ei_traits<MatrixType>::Scalar Scalar;
typedef Matrix<Scalar, MatrixType::ColsAtCompileTime, 1> VectorType; typedef Matrix<Scalar, MatrixType::ColsAtCompileTime, 1> VectorType;
@ -244,7 +243,7 @@ void createRandomMatrixOfRank(int desired_rank, int rows, int cols, Eigen::Matri
HouseholderQR<MatrixType> qra(a); HouseholderQR<MatrixType> qra(a);
HouseholderQR<MatrixType> qrb(b); HouseholderQR<MatrixType> qrb(b);
m = (qra.matrixQ() * d * qrb.matrixQ()).lazy(); m = qra.matrixQ() * d * qrb.matrixQ();
} }
} // end namespace Eigen } // end namespace Eigen