solvers Package
solvers Package
-
exception fipy.solvers.SolverConvergenceWarning(solver, iter, relres)
Bases: exceptions.Warning
-
exception fipy.solvers.MaximumIterationWarning(solver, iter, relres)
Bases: fipy.solvers.solver.SolverConvergenceWarning
-
exception fipy.solvers.PreconditionerWarning(solver, iter, relres)
Bases: fipy.solvers.solver.SolverConvergenceWarning
-
exception fipy.solvers.IllConditionedPreconditionerWarning(solver, iter, relres)
Bases: fipy.solvers.solver.PreconditionerWarning
-
exception fipy.solvers.PreconditionerNotPositiveDefiniteWarning(solver, iter, relres)
Bases: fipy.solvers.solver.PreconditionerWarning
-
exception fipy.solvers.MatrixIllConditionedWarning(solver, iter, relres)
Bases: fipy.solvers.solver.SolverConvergenceWarning
-
exception fipy.solvers.StagnatedSolverWarning(solver, iter, relres)
Bases: fipy.solvers.solver.SolverConvergenceWarning
-
exception fipy.solvers.ScalarQuantityOutOfRangeWarning(solver, iter, relres)
Bases: fipy.solvers.solver.SolverConvergenceWarning
-
class fipy.solvers.Solver(tolerance=1e-10, iterations=1000, precon=None)
Bases: object
The base LinearXSolver class.
Attention
This class is abstract. Always create one of its subclasses.
Create a Solver object.
| Parameters : |
- tolerance: The required error tolerance.
- iterations: The maximum number of iterative steps to perform.
- precon: Preconditioner to use. This parameter is only available for Trilinos solvers.
|
-
fipy.solvers.DefaultSolver
alias of LinearPCGSolver
-
fipy.solvers.DummySolver
alias of LinearPCGSolver
-
fipy.solvers.DefaultAsymmetricSolver
alias of LinearLUSolver
-
fipy.solvers.GeneralSolver
alias of LinearLUSolver
-
class fipy.solvers.LinearCGSSolver(precon=None, *args, **kwargs)
Bases: fipy.solvers.pysparse.pysparseSolver.PysparseSolver
The LinearCGSSolver solves a linear system of equations using
the conjugate gradient squared method (CGS), a variant of the
biconjugate gradient method (BiCG). CGS solves linear systems with
a general non-symmetric coefficient matrix.
The LinearCGSSolver is a wrapper class for the the PySparse
itsolvers.cgs() method.
| Parameters : |
- precon: Preconditioner to use
|
-
class fipy.solvers.LinearPCGSolver(precon=<fipy.solvers.pysparse.preconditioners.ssorPreconditioner.SsorPreconditioner instance at 0x107c8c638>, *args, **kwargs)
Bases: fipy.solvers.pysparse.pysparseSolver.PysparseSolver
The LinearPCGSolver solves a linear system of equations using the
preconditioned conjugate gradient method (PCG) with symmetric successive
over-relaxation (SSOR) preconditioning by default. Alternatively,
Jacobi preconditioning can be specified through precon.
The PCG method solves systems with
a symmetric positive definite coefficient matrix.
The LinearPCGSolver is a wrapper class for the the PySparse
itsolvers.pcg() and precon.ssor() methods.
| Parameters : |
- precon: Preconditioner to use
|
-
class fipy.solvers.LinearGMRESSolver(precon=<fipy.solvers.pysparse.preconditioners.jacobiPreconditioner.JacobiPreconditioner instance at 0x107c8c7e8>, *args, **kwargs)
Bases: fipy.solvers.pysparse.pysparseSolver.PysparseSolver
The LinearGMRESSolver solves a linear system of equations using the
generalised minimal residual method (GMRES) with Jacobi
preconditioning. GMRES solves systems with a general non-symmetric
coefficient matrix.
The LinearGMRESSolver is a wrapper class for the the PySparse
itsolvers.gmres() and precon.jacobi() methods.
| Parameters : |
- precon: Preconditioner to use
|
-
class fipy.solvers.LinearLUSolver(tolerance=1e-10, iterations=10, maxIterations=10, precon=None)
Bases: fipy.solvers.pysparse.pysparseSolver.PysparseSolver
The LinearLUSolver solves a linear system of equations using
LU-factorisation. This method solves systems with a general
non-symmetric coefficient matrix using partial pivoting.
The LinearLUSolver is a wrapper class for the the PySparse
superlu.factorize() method.
Creates a LinearLUSolver.
| Parameters : |
- tolerance: The required error tolerance.
- iterations: The number of LU decompositions to perform.
For large systems a number of iterations is generally required.
- precon: not used but maintains a common interface.
|
-
class fipy.solvers.LinearJORSolver(tolerance=1e-10, iterations=1000, relaxation=1.0)
Bases: fipy.solvers.pysparse.pysparseSolver.PysparseSolver
The LinearJORSolver solves a linear system of equations using
Jacobi over-relaxation. This method solves systems with a general
non-symmetric coefficient matrix.
The Solver class should not be invoked directly.
| Parameters : |
- tolerance: The required error tolerance.
- iterations: The maximum number of iterative steps to perform.
- relaxation: The relaxation.
|
-
class fipy.solvers.JacobiPreconditioner
Bases: fipy.solvers.pysparse.preconditioners.preconditioner.Preconditioner
Jacobi preconditioner for PySparse.
Really just a wrapper class for pysparse.precon.jacobi.
Create a Preconditioner object.
-
class fipy.solvers.SsorPreconditioner
Bases: fipy.solvers.pysparse.preconditioners.preconditioner.Preconditioner
SSOR preconditioner for PySparse.
Really just a wrapper class for pysparse.precon.jacobi.
Create a Preconditioner object.
pysparseMatrixSolver Module
solver Module
The iterative solvers may output warnings if the solution is considered
unsatisfactory. If you are not interested in these warnings, you can invoke
python with a warning filter such as:
$ python -Wignore::fipy.SolverConvergenceWarning myscript.py
If you are extremely concerned about your preconditioner for some reason, you
can abort whenever it has problems with:
$ python -Werror::fipy.PreconditionerWarning myscript.py
-
exception fipy.solvers.solver.SolverConvergenceWarning(solver, iter, relres)
Bases: exceptions.Warning
-
exception fipy.solvers.solver.MaximumIterationWarning(solver, iter, relres)
Bases: fipy.solvers.solver.SolverConvergenceWarning
-
exception fipy.solvers.solver.PreconditionerWarning(solver, iter, relres)
Bases: fipy.solvers.solver.SolverConvergenceWarning
-
exception fipy.solvers.solver.IllConditionedPreconditionerWarning(solver, iter, relres)
Bases: fipy.solvers.solver.PreconditionerWarning
-
exception fipy.solvers.solver.PreconditionerNotPositiveDefiniteWarning(solver, iter, relres)
Bases: fipy.solvers.solver.PreconditionerWarning
-
exception fipy.solvers.solver.MatrixIllConditionedWarning(solver, iter, relres)
Bases: fipy.solvers.solver.SolverConvergenceWarning
-
exception fipy.solvers.solver.StagnatedSolverWarning(solver, iter, relres)
Bases: fipy.solvers.solver.SolverConvergenceWarning
-
exception fipy.solvers.solver.ScalarQuantityOutOfRangeWarning(solver, iter, relres)
Bases: fipy.solvers.solver.SolverConvergenceWarning
-
class fipy.solvers.solver.Solver(tolerance=1e-10, iterations=1000, precon=None)
Bases: object
The base LinearXSolver class.
Attention
This class is abstract. Always create one of its subclasses.
Create a Solver object.
| Parameters : |
- tolerance: The required error tolerance.
- iterations: The maximum number of iterative steps to perform.
- precon: Preconditioner to use. This parameter is only available for Trilinos solvers.
|