From: bangerth Date: Wed, 20 Mar 2013 03:20:45 +0000 (+0000) Subject: Use SSOR as preconditioner. X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3dfbec7e2abfa8fcddfddcead36a96fdcafa64d0;p=dealii-svn.git Use SSOR as preconditioner. git-svn-id: https://svn.dealii.org/trunk@28948 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/examples/step-26/step-26.cc b/deal.II/examples/step-26/step-26.cc index 91de3ff1a3..39d037c00f 100644 --- a/deal.II/examples/step-26/step-26.cc +++ b/deal.II/examples/step-26/step-26.cc @@ -188,7 +188,10 @@ namespace Step26 SolverControl solver_control(1000, 1e-8 * system_rhs.l2_norm()); SolverCG<> cg(solver_control); - cg.solve(matrix_u, solution_u, system_rhs, PreconditionIdentity()); + PreconditionSSOR<> preconditioner; + preconditioner.initialize(matrix_u, 1.0); + + cg.solve(matrix_u, solution_u, system_rhs, preconditioner); std::cout << " u-equation: " << solver_control.last_step() << " CG iterations." << std::endl;