From 0407f80275d65d7ca10ca36d6843c0f6a1925848 Mon Sep 17 00:00:00 2001 From: Matthias Maier Date: Sun, 10 May 2020 21:01:07 -0500 Subject: [PATCH] Test lac/gmres_reorthogonalize_04: Only output iteration count In reference to #10073 See also: https://cdash.43-1.org/testDetails.php?test=43916417&build=6239 --- tests/lac/gmres_reorthogonalize_04.cc | 15 ++++++++++----- tests/lac/gmres_reorthogonalize_04.output | 6 ++---- 2 files changed, 12 insertions(+), 9 deletions(-) diff --git a/tests/lac/gmres_reorthogonalize_04.cc b/tests/lac/gmres_reorthogonalize_04.cc index 6cfdd0c9f3..588c322d98 100644 --- a/tests/lac/gmres_reorthogonalize_04.cc +++ b/tests/lac/gmres_reorthogonalize_04.cc @@ -54,7 +54,7 @@ namespace dealii template void -test() +test(const unsigned int n_expected_steps) { const unsigned int n = 200; Vector rhs(n), sol(n); @@ -81,19 +81,24 @@ test() << accumulated_iterations << std::endl; }; solver.connect_re_orthogonalization_slot(print_re_orthogonalization); - solver.solve(matrix, sol, rhs, PreconditionIdentity()); + + check_solver_within_range( + solver.solve(matrix, sol, rhs, PreconditionIdentity()), + control.last_step(), + n_expected_steps - 3, + n_expected_steps + 3); } int main() { initlog(); - deallog << std::setprecision(3); + deallog << std::setprecision(10); deallog.push("double"); - test(); + test(105); deallog.pop(); deallog.push("float"); - test(); + test(59); deallog.pop(); } diff --git a/tests/lac/gmres_reorthogonalize_04.output b/tests/lac/gmres_reorthogonalize_04.output index 093ab7f072..8b74f405ad 100644 --- a/tests/lac/gmres_reorthogonalize_04.output +++ b/tests/lac/gmres_reorthogonalize_04.output @@ -1,5 +1,3 @@ -DEAL:double:GMRES::Starting value 14.1 -DEAL:double:GMRES::Convergence step 105 value 1.56e-13 -DEAL:float:GMRES::Starting value 14.1 -DEAL:float:GMRES::Convergence step 59 value 0.000110 +DEAL:double::Solver stopped within 102 - 108 iterations +DEAL:float::Solver stopped within 56 - 62 iterations -- 2.39.5