3.5-git
DUNE for Multi-{Phase, Component, Scale, Physics, ...} flow and transport in porous media
Public Types | Public Member Functions | List of all members
Dumux::LinearSolver Class Reference

Base class for linear solvers. More...

#include <dumux/linear/solver.hh>

Inheritance diagram for Dumux::LinearSolver:

Description

Base class for linear solvers.

Public Types

using Scalar = double
 

Public Member Functions

 LinearSolver (const std::string &paramGroup="")
 Contruct the solver. More...
 
template<class Matrix , class Vector >
bool solve (const Matrix &A, Vector &x, const Vector &b)
 Solve the linear system Ax = b. More...
 
std::string name () const
 the name of the linear solver More...
 
const std::string & paramGroup () const
 the parameter group for getting parameter from the parameter tree More...
 
int verbosity () const
 the verbosity level More...
 
void setVerbosity (int v)
 set the verbosity level More...
 
int maxIter () const
 the maximum number of linear solver iterations More...
 
void setMaxIter (int i)
 set the maximum number of linear solver iterations More...
 
Scalar residReduction () const
 the linear solver residual reduction More...
 
void setResidualReduction (Scalar r)
 set the linear solver residual reduction More...
 
Scalar relaxation () const
 the linear solver relaxation factor More...
 
void setRelaxation (Scalar r)
 set the linear solver relaxation factor More...
 
int precondIter () const
 the number of preconditioner iterations More...
 
void setPrecondIter (int i)
 set the number of preconditioner iterations More...
 
int precondVerbosity () const
 the preconditioner verbosity More...
 
void setPrecondVerbosity (int verbosityLevel)
 set the preconditioner verbosity More...
 

Member Typedef Documentation

◆ Scalar

export Scalar type (might be needed to set parameters from output) TODO: Do we need this?

Constructor & Destructor Documentation

◆ LinearSolver()

Dumux::LinearSolver::LinearSolver ( const std::string &  paramGroup = "")
inline

Contruct the solver.

Note
Read parameters from the parameter tree
  • LinearSolver.Verbosity the verbosity level of the linear solver
  • LinearSolver.MaxIterations the maximum iterations of the solver
  • LinearSolver.ResidualReduction the residual reduction threshold, i.e. stopping criterion
  • LinearSolver.Preconditioner.Relaxation precondition relaxation
  • LinearSolver.Preconditioner.Iterations the number of preconditioner iterations
  • LinearSolver.Preconditioner.Verbosity the preconditioner verbosity level

Member Function Documentation

◆ maxIter()

int Dumux::LinearSolver::maxIter ( ) const
inline

the maximum number of linear solver iterations

◆ name()

std::string Dumux::LinearSolver::name ( ) const
inline

the name of the linear solver

◆ paramGroup()

const std::string & Dumux::LinearSolver::paramGroup ( ) const
inline

the parameter group for getting parameter from the parameter tree

◆ precondIter()

int Dumux::LinearSolver::precondIter ( ) const
inline

the number of preconditioner iterations

◆ precondVerbosity()

int Dumux::LinearSolver::precondVerbosity ( ) const
inline

the preconditioner verbosity

◆ relaxation()

Scalar Dumux::LinearSolver::relaxation ( ) const
inline

the linear solver relaxation factor

◆ residReduction()

Scalar Dumux::LinearSolver::residReduction ( ) const
inline

the linear solver residual reduction

◆ setMaxIter()

void Dumux::LinearSolver::setMaxIter ( int  i)
inline

set the maximum number of linear solver iterations

◆ setPrecondIter()

void Dumux::LinearSolver::setPrecondIter ( int  i)
inline

set the number of preconditioner iterations

◆ setPrecondVerbosity()

void Dumux::LinearSolver::setPrecondVerbosity ( int  verbosityLevel)
inline

set the preconditioner verbosity

◆ setRelaxation()

void Dumux::LinearSolver::setRelaxation ( Scalar  r)
inline

set the linear solver relaxation factor

◆ setResidualReduction()

void Dumux::LinearSolver::setResidualReduction ( Scalar  r)
inline

set the linear solver residual reduction

◆ setVerbosity()

void Dumux::LinearSolver::setVerbosity ( int  v)
inline

set the verbosity level

◆ solve()

template<class Matrix , class Vector >
bool Dumux::LinearSolver::solve ( const Matrix &  A,
Vector &  x,
const Vector &  b 
)
inline

Solve the linear system Ax = b.

Note
This has to be overloaded by the actual solver

◆ verbosity()

int Dumux::LinearSolver::verbosity ( ) const
inline

the verbosity level


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