krypy.recycling.evaluators - evaluators for deflation vector candidates¶
- class krypy.recycling.evaluators.RitzApproxKrylov(mode='extrapolate', tol=None, pseudospectra=False, bound_pseudo_kwargs=None, deflweight=1.0)¶
Bases: krypy.recycling.evaluators._RitzSubsetEvaluator
Evaluates a choice of Ritz vectors with a tailored approximate Krylov subspace method.
Parameters: - mode –
(optional) determines how the number of iterations is estimated. Must be one of the following:
- extrapolate (default): use the iteration count where the extrapolation of the smallest residual reduction over all steps drops below the tolerance.
- direct: use the iteration count where the predicted residual bound drops below the tolerance. May result in severe underestimation if pseudospectra==False.
- pseudospectra – (optional) should pseudospectra be computed for the given problem? With pseudospectra=True, a prediction may not be possible due to unfulfilled assumptions for the computation of the pseudospectral bound.
- bound_pseudo_kwargs – (optional) a dictionary with arguments that are passed to bound_pseudo().
- deflweight – (optional) see estimate_time(). Defaults to 1.
- evaluate(ritz, subset)¶
- mode –
- class krypy.recycling.evaluators.RitzApriori(Bound, tol=None, strategy='simple', deflweight=1.0)¶
Bases: krypy.recycling.evaluators._RitzSubsetEvaluator
Evaluates a choice of Ritz vectors with an a-priori bound for self-adjoint problems.
Parameters: - Bound – the a-priori bound which is used for estimating the convergence behavior.
- tol – (optional) the tolerance for the stopping criterion, see _KrylovSolver. If None is provided (default), then the tolerance is retrieved from ritz._deflated_solver.tol in the call to evaluate().
- strategy –
(optional) the following strategies are available
- simple: (default) uses the Ritz values that are complementary to the deflated ones for the evaluation of the bound.
- intervals: uses intervals around the Ritz values that are considered with simple. The intervals incorporate possible changes in the operators.
- evaluate(ritz, subset)¶