pymor.solvers.default¶
Module Contents¶
- class pymor.solvers.default.DefaultSolver(try_to_matrix=True)[source]¶
Bases:
pymor.solvers.interface.SolverDefault
Solver.This
Solveris used byapply_inverseandapply_inverse_adjointwhen theOperatorhas nosolverand no solver is specified in the method call.DefaultSolveruses the following strategy:Try to call
operator._apply_inverse.Assemble
operator. Tryassembled_operator._apply_inverse.If
operatoris linear, try to convertassembled_operatorto aNumpyMatrixOperatorusingto_matrixand callapply_inverseon the converted operator.If
operatoris non-linear, useNewtonSolver.
- Parameters:
try_to_matrix – If
False, do not try to convert linear operators toNumpyMatrixOperator. Fail instead.