sfepy.solvers.eigen module

class sfepy.solvers.eigen.LOBPCGEigenvalueSolver(conf, **kwargs)[source]

SciPy-based LOBPCG solver for sparse symmetric problems.

Kind: ‘eig.scipy_lobpcg’

For common configuration parameters, see Solver.

Specific configuration parameters:

Parameters:
i_max : int (default: 20)

The maximum number of iterations.

eps_a : float

The absolute tolerance for the convergence.

largest : bool (default: True)

If True, solve for the largest eigenvalues, otherwise the smallest.

precond : {dense matrix, sparse matrix, LinearOperator}

The preconditioner.

name = ‘eig.scipy_lobpcg’
class sfepy.solvers.eigen.PysparseEigenvalueSolver(conf, **kwargs)[source]

Pysparse-based eigenvalue solver for sparse symmetric problems.

Kind: ‘eig.pysparse’

For common configuration parameters, see Solver.

Specific configuration parameters:

Parameters:
i_max : int (default: 100)

The maximum number of iterations.

eps_a : float (default: 1e-05)

The absolute tolerance for the convergence.

tau : float (default: 0.0)

The target value.

method : {‘cgs’, ‘qmrs’} (default: ‘qmrs’)

The linear iterative solver supported by pysparse.

verbosity : int (default: 0)

The pysparse verbosity level.

strategy : {0, 1} (default: 1)

The shifting and sorting strategy of JDSYM: strategy=0 enables the default JDSYM algorithm, strategy=1 enables JDSYM to avoid convergence to eigenvalues smaller than tau.

* : *

Additional parameters supported by the solver.

name = ‘eig.pysparse’
class sfepy.solvers.eigen.ScipyEigenvalueSolver(conf, **kwargs)[source]

SciPy-based solver for both dense and sparse problems.

The problem is consirered sparse if n_eigs argument is not None.

Kind: ‘eig.scipy’

For common configuration parameters, see Solver.

Specific configuration parameters:

Parameters:
method : {‘eig’, ‘eigh’} (default: ‘eig’)

The method for solving general or symmetric eigenvalue problems: for dense problems eig() or eigh() are used, for sparse problems (if n_eigs is given) eigs() or eigsh() are used.

which : ‘LM’ | ‘SM’ | ‘LR’ | ‘SR’ | ‘LI’ | ‘SI’ (default: ‘SM’)

Which eigenvectors and eigenvalues to find, see scipy.sparse.linalg.eigs() or scipy.sparse.linalg.eigsh().

* : *

Additional parameters supported by the method.

name = ‘eig.scipy’
class sfepy.solvers.eigen.ScipySGEigenvalueSolver(conf, **kwargs)[source]

SciPy-based solver for dense symmetric problems.

Kind: ‘eig.sgscipy’

For common configuration parameters, see Solver.

Specific configuration parameters:

name = ‘eig.sgscipy’
sfepy.solvers.eigen.eig(mtx_a, mtx_b=None, n_eigs=None, eigenvectors=True, return_time=None, method=’eig.scipy’, **ckwargs)[source]

Utility function that constructs an eigenvalue solver given by method, calls it and returns solution.

sfepy.solvers.eigen.standard_call(call)[source]

Decorator handling argument preparation and timing for eigensolvers.