Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner > Class Template Reference

Implements a preconditioned stabilized BiCG linear solver. More...

#include <bicgstabsolver.hh>

Public Member Functions

 BiCGStabSolver (Preconditioner &preconditioner, ConvergenceCriterion &convergenceCriterion, Dune::ScalarProduct< Vector > &scalarProduct)
 
void setMaxIterations (unsigned value)
 Set the maximum number of iterations before we give up without achieving convergence. More...
 
unsigned maxIterations () const
 Return the maximum number of iterations before we give up without achieving convergence. More...
 
void setVerbosity (unsigned value)
 Set the verbosity level of the linear solver. More...
 
unsigned verbosity () const
 Return the verbosity level of the linear solver. More...
 
void setLinearOperator (const LinearOperator *A)
 Set the matrix "A" of the linear system. More...
 
void setRhs (const Vector *b)
 Set the right hand side "b" of the linear system. More...
 
bool apply (Vector &x)
 Run the stabilized BiCG solver and store the result into the "x" vector. More...
 
void setConvergenceCriterion (ConvergenceCriterion &crit)
 
const SolverReportreport () const
 

Detailed Description

template<class LinearOperator, class Vector, class Preconditioner>
class Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner >

Implements a preconditioned stabilized BiCG linear solver.

This solves a linear system of equations Ax = b, where the matrix A is sparse and may be unsymmetric.

See https://en.wikipedia.org/wiki/Biconjugate_gradient_stabilized_method, (article date: December 19, 2016)

Constructor & Destructor Documentation

◆ BiCGStabSolver()

template<class LinearOperator , class Vector , class Preconditioner >
Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner >::BiCGStabSolver ( Preconditioner &  preconditioner,
ConvergenceCriterion convergenceCriterion,
Dune::ScalarProduct< Vector > &  scalarProduct 
)
inline

Member Function Documentation

◆ apply()

◆ maxIterations()

template<class LinearOperator , class Vector , class Preconditioner >
unsigned Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner >::maxIterations ( ) const
inline

Return the maximum number of iterations before we give up without achieving convergence.

◆ report()

template<class LinearOperator , class Vector , class Preconditioner >
const SolverReport & Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner >::report ( ) const
inline

◆ setConvergenceCriterion()

template<class LinearOperator , class Vector , class Preconditioner >
void Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner >::setConvergenceCriterion ( ConvergenceCriterion crit)
inline

◆ setLinearOperator()

template<class LinearOperator , class Vector , class Preconditioner >
void Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner >::setLinearOperator ( const LinearOperator *  A)
inline

Set the matrix "A" of the linear system.

◆ setMaxIterations()

template<class LinearOperator , class Vector , class Preconditioner >
void Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner >::setMaxIterations ( unsigned  value)
inline

Set the maximum number of iterations before we give up without achieving convergence.

◆ setRhs()

template<class LinearOperator , class Vector , class Preconditioner >
void Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner >::setRhs ( const Vector *  b)
inline

Set the right hand side "b" of the linear system.

◆ setVerbosity()

template<class LinearOperator , class Vector , class Preconditioner >
void Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner >::setVerbosity ( unsigned  value)
inline

Set the verbosity level of the linear solver.

The levels correspont to those used by the dune-istl solvers:

  • 0: no output
  • 1: summary output at the end of the solution proceedure (if no exception was thrown)
  • 2: detailed output after each iteration

◆ verbosity()

template<class LinearOperator , class Vector , class Preconditioner >
unsigned Opm::Linear::BiCGStabSolver< LinearOperator, Vector, Preconditioner >::verbosity ( ) const
inline

Return the verbosity level of the linear solver.


The documentation for this class was generated from the following file: