From ebe14aae7d39fb16d173d8db68e0ea439c4f87fc Mon Sep 17 00:00:00 2001 From: Gael Guennebaud Date: Wed, 29 Oct 2008 15:24:08 +0000 Subject: add transposeInPlace (not optimized yet for rectangular matrix) --- test/adjoint.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'test/adjoint.cpp') diff --git a/test/adjoint.cpp b/test/adjoint.cpp index 9a50e076e..18256a124 100644 --- a/test/adjoint.cpp +++ b/test/adjoint.cpp @@ -90,6 +90,14 @@ template void adjoint(const MatrixType& m) // normalized() in order to produce a consistent result. VERIFY_IS_APPROX(VectorType::Random(rows).normalized().norm(), RealScalar(1)); } + + // check inplace transpose + m3 = m1; + m3.transposeInPlace(); + VERIFY_IS_APPROX(m3,m1.transpose()); + m3.transposeInPlace(); + VERIFY_IS_APPROX(m3,m1); + } void test_adjoint() -- cgit v1.2.3