From 96a18ef230e36d4cde6235bf5a7a41b077efc7ef Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Fri, 23 Dec 2011 23:15:08 +0100 Subject: add a reconstruction test --- test/jacobisvd.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'test/jacobisvd.cpp') diff --git a/test/jacobisvd.cpp b/test/jacobisvd.cpp index f44e66c94..cf8c76055 100644 --- a/test/jacobisvd.cpp +++ b/test/jacobisvd.cpp @@ -132,6 +132,11 @@ void jacobisvd_test_all_computation_options(const MatrixType& m) jacobisvd_solve(m, ComputeThinU | ComputeFullV); jacobisvd_solve(m, ComputeThinU | ComputeThinV); } + + { + JacobiSVD svd(m, ComputeThinU | ComputeThinV); + VERIFY_IS_APPROX(m, svd.matrixU() * svd.singularValues().asDiagonal() * svd.matrixV().transpose()); + } } template -- cgit v1.2.3