aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/adjoint.cpp
diff options
context:
space:
mode:
authorGravatar Gael Guennebaud <g.gael@free.fr>2008-10-29 15:24:08 +0000
committerGravatar Gael Guennebaud <g.gael@free.fr>2008-10-29 15:24:08 +0000
commitebe14aae7d39fb16d173d8db68e0ea439c4f87fc (patch)
tree79d6a94c70cc0a15e6f854a3dc7fe7607a8f8c79 /test/adjoint.cpp
parent48137e28d8abe8464ffbc422333e26b91cd8e3b0 (diff)
add transposeInPlace (not optimized yet for rectangular matrix)
Diffstat (limited to 'test/adjoint.cpp')
-rw-r--r--test/adjoint.cpp8
1 files changed, 8 insertions, 0 deletions
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<typename MatrixType> 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()