Package no.uib.cipr.matrix.sparse
Interface IterativeSolver
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description IterationMonitorgetIterationMonitor()Gets the iteration monitorPreconditionergetPreconditioner()Gets preconditionervoidsetIterationMonitor(IterationMonitor iter)Sets iteration monitorvoidsetPreconditioner(Preconditioner M)Sets preconditionerVectorsolve(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 problemb- Right hand sidex- 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
-
-