From 24a09ceae86590925102493fffcf3973ff2c8358 Mon Sep 17 00:00:00 2001 From: Benoit Jacob Date: Mon, 11 Jan 2010 08:48:39 -0500 Subject: * Fix a bug in HouseholderQR with mixed fixed/dynamic size: must use EIGEN_SIZE_MIN instead of EIGEN_ENUM_MIN, and there are many other occurences throughout Eigen! * HouseholderSequence: - add shift parameter - add essentialVector() method to start abstracting the direction - add unit test in householder.cpp --- test/qr.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'test/qr.cpp') diff --git a/test/qr.cpp b/test/qr.cpp index 3848ce0a5..f2393c13b 100644 --- a/test/qr.cpp +++ b/test/qr.cpp @@ -36,14 +36,11 @@ template void qr(const MatrixType& m) MatrixType a = MatrixType::Random(rows,cols); HouseholderQR qrOfA(a); - MatrixType r = qrOfA.matrixQR(); MatrixQType q = qrOfA.householderQ(); VERIFY_IS_UNITARY(q); - // FIXME need better way to construct trapezoid - for(int i = 0; i < rows; i++) for(int j = 0; j < cols; j++) if(i>j) r(i,j) = Scalar(0); - + MatrixType r = qrOfA.matrixQR().template triangularView(); VERIFY_IS_APPROX(a, qrOfA.householderQ() * r); } @@ -114,7 +111,7 @@ template void qr_verify_assert() void test_qr() { - for(int i = 0; i < 1; i++) { + for(int i = 0; i < g_repeat; i++) { CALL_SUBTEST_1( qr(MatrixXf(47,40)) ); CALL_SUBTEST_2( qr(MatrixXcd(17,7)) ); CALL_SUBTEST_3(( qr_fixedsize, 2 >() )); -- cgit v1.2.3