no.uib.cipr.matrix.sparse
Interface IterativeSolver

All Known Implementing Classes:
AbstractIterativeSolver, BiCG, BiCGstab, CG, CGS, Chebyshev, GMRES, IR, QMR

public interface IterativeSolver

Iterative linear solver. Solves Ax=b for x, and it supports preconditioning and convergence monitoring.


Method Summary
 IterationMonitor getIterationMonitor()
          Gets the iteration monitor
 Preconditioner getPreconditioner()
          Gets preconditioner
 void setIterationMonitor(IterationMonitor iter)
          Sets iteration monitor
 void setPreconditioner(Preconditioner M)
          Sets preconditioner
 Vector solve(Matrix A, Vector b, Vector x)
          Solves the given problem, writing result into the vector.
 

Method Detail

solve

Vector solve(Matrix A,
             Vector b,
             Vector x)
             throws IterativeSolverNotConvergedException
Solves the given problem, writing result into the vector.

Parameters:
A - Matrix of the problem
b - Right hand side
x - Solution is stored here. Also used as initial guess
Returns:
The solution vector x
Throws:
IterativeSolverNotConvergedException

setPreconditioner

void setPreconditioner(Preconditioner M)
Sets preconditioner

Parameters:
M - Preconditioner to use

getPreconditioner

Preconditioner getPreconditioner()
Gets preconditioner

Returns:
Current preconditioner

setIterationMonitor

void setIterationMonitor(IterationMonitor iter)
Sets iteration monitor

Parameters:
iter - Iteration monitor

getIterationMonitor

IterationMonitor getIterationMonitor()
Gets the iteration monitor

Returns:
Current iteration monitor