diff options
author | Jitse Niesen <jitse@maths.leeds.ac.uk> | 2010-05-24 17:35:54 +0100 |
---|---|---|
committer | Jitse Niesen <jitse@maths.leeds.ac.uk> | 2010-05-24 17:35:54 +0100 |
commit | eb3ca68684c2fa4786578e618b04029a351c0fc1 (patch) | |
tree | 7acf145f860cd2ffd5edcba8151b6b87bb0b3701 /test/hessenberg.cpp | |
parent | 76dd0e5314aa4978b908323d47c735eb50168a17 (diff) |
Change return type of matrixH() method to HouseholderSequence.
This method is a member of Tridiagonalization and HessenbergDecomposition.
Diffstat (limited to 'test/hessenberg.cpp')
-rw-r--r-- | test/hessenberg.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/test/hessenberg.cpp b/test/hessenberg.cpp index ec1148bfc..61ff98150 100644 --- a/test/hessenberg.cpp +++ b/test/hessenberg.cpp @@ -34,8 +34,9 @@ template<typename Scalar,int Size> void hessenberg(int size = Size) for(int counter = 0; counter < g_repeat; ++counter) { MatrixType m = MatrixType::Random(size,size); HessenbergDecomposition<MatrixType> hess(m); - VERIFY_IS_APPROX(m, hess.matrixQ() * hess.matrixH() * hess.matrixQ().adjoint()); + MatrixType Q = hess.matrixQ(); MatrixType H = hess.matrixH(); + VERIFY_IS_APPROX(m, Q * H * Q.adjoint()); for(int row = 2; row < size; ++row) { for(int col = 0; col < row-1; ++col) { VERIFY(H(row,col) == (typename MatrixType::Scalar)0); @@ -48,8 +49,10 @@ template<typename Scalar,int Size> void hessenberg(int size = Size) HessenbergDecomposition<MatrixType> cs1; cs1.compute(A); HessenbergDecomposition<MatrixType> cs2(A); - VERIFY_IS_EQUAL(cs1.matrixQ(), cs2.matrixQ()); VERIFY_IS_EQUAL(cs1.matrixH(), cs2.matrixH()); + MatrixType cs1Q = cs1.matrixQ(); + MatrixType cs2Q = cs2.matrixQ(); + VERIFY_IS_EQUAL(cs1Q, cs2Q); // TODO: Add tests for packedMatrix() and householderCoefficients() } |