NeoPZ
Functions
ir.h File Reference

Contains the implementation of the IR function which solves the unsymmetric linear system using the Iterative Refinement method. More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

template<class Matrix , class Vector , class Preconditioner , class Real >
int IR (Matrix &A, Vector &x, const Vector &b, Preconditioner &M, Vector *residual, int64_t &max_iter, Real &tol, const int FromCurrent)
 IR solves the unsymmetric linear system Ax = b using Iterative Refinement (preconditioned Richardson iteration). More...
 

Detailed Description

Contains the implementation of the IR function which solves the unsymmetric linear system using the Iterative Refinement method.

Definition in file ir.h.

Function Documentation

◆ IR()

template<class Matrix , class Vector , class Preconditioner , class Real >
int IR ( Matrix &  A,
Vector x,
const Vector b,
Preconditioner &  M,
Vector residual,
int64_t &  max_iter,
Real &  tol,
const int  FromCurrent 
)

IR solves the unsymmetric linear system Ax = b using Iterative Refinement (preconditioned Richardson iteration).

Returns
The return value indicates convergence within max_iter (input) iterations (0), or no convergence within max_iter iterations (1).
Upon successful return, output arguments have the following values:
Parameters
A– matrix of the system
b– vector of the system
M– preconditioner matrix
x– approximate solution to Ax = b
max_iter– the number of iterations performed before the tolerance was reached
tol– the residual after the final iteration
residual– residual vector (return)
FromCurrent– for type of operation (MultAdd) Iterative template routine – Preconditioned Richardson

Definition at line 24 of file ir.h.

References Norm(), test::res, and TPZExtractVal::val().

Referenced by TPZMatrix< STATE >::SolveIR().