From f604a9784de84a3c9699be737f295e77976b9a5b Mon Sep 17 00:00:00 2001 From: jingwuOUO Date: Sun, 1 Nov 2020 20:45:59 -0500 Subject: [PATCH] Delete forcing compare eigenvector in unittest --- gtsam/linear/tests/testAcceleratedPowerMethod.cpp | 6 ------ gtsam/linear/tests/testPowerMethod.cpp | 5 ----- 2 files changed, 11 deletions(-) diff --git a/gtsam/linear/tests/testAcceleratedPowerMethod.cpp b/gtsam/linear/tests/testAcceleratedPowerMethod.cpp index 228ce157c..dd593e7d3 100644 --- a/gtsam/linear/tests/testAcceleratedPowerMethod.cpp +++ b/gtsam/linear/tests/testAcceleratedPowerMethod.cpp @@ -76,11 +76,6 @@ TEST(AcceleratedPowerMethod, useFactorGraph) { auto L = fg.hessian(); Eigen::EigenSolver solver(L.first); - // Check that we get zero eigenvalue and "constant" eigenvector - EXPECT_DOUBLES_EQUAL(0.0, solver.eigenvalues()[0].real(), 1e-9); - auto v0 = solver.eigenvectors().col(0); - for (size_t j = 0; j < 3; j++) EXPECT_DOUBLES_EQUAL(-0.5, v0[j].real(), 1e-9); - // find the index of the max eigenvalue size_t maxIdx = 0; for (auto i = 0; i < solver.eigenvalues().rows(); ++i) { @@ -105,7 +100,6 @@ TEST(AcceleratedPowerMethod, useFactorGraph) { const double ritzValue = actual1.dot(L.first * actual1); const double ritzResidual = (L.first * actual1 - ritzValue * actual1).norm(); EXPECT_DOUBLES_EQUAL(0, ritzResidual, 1e-5); - // Check } /* ************************************************************************* */ diff --git a/gtsam/linear/tests/testPowerMethod.cpp b/gtsam/linear/tests/testPowerMethod.cpp index 4c96c5bca..ccac4556c 100644 --- a/gtsam/linear/tests/testPowerMethod.cpp +++ b/gtsam/linear/tests/testPowerMethod.cpp @@ -74,11 +74,6 @@ TEST(PowerMethod, useFactorGraph) { auto L = fg.hessian(); Eigen::EigenSolver solver(L.first); - // Check that we get zero eigenvalue and "constant" eigenvector - EXPECT_DOUBLES_EQUAL(0.0, solver.eigenvalues()[0].real(), 1e-9); - auto v0 = solver.eigenvectors().col(0); - for (size_t j = 0; j < 3; j++) EXPECT_DOUBLES_EQUAL(-0.5, v0[j].real(), 1e-9); - // find the index of the max eigenvalue size_t maxIdx = 0; for (auto i = 0; i < solver.eigenvalues().rows(); ++i) {