PARCEL SYCL v1.2 / API Reference User Guide API Reference Search Download 日本語

16 parcel::krylov::inverse_power

16.1 inverse_power (class)

Description Inverse power method. Computes the eigenpair of smallest absolute value of AA (AK−1AK^{-1} when set_precon_spectrum(true) is set). In each iteration, an inner linear solver solves Ay=xAy = x.

Synopsis

template< class Tspmv = parcel_double, class Tprecon = parcel_double,
          class Taxpy = parcel_double, class Tdot    = parcel_double >
class inverse_power : public eigen_param;

Notes There are no class-specific member functions. The inner linear solver is configured with the set_linsolve_* member functions common to the eigenvalue solvers (for the defaults, see the common settings). set_tolerance() / set_max_iteration() apply to the outer eigenvalue iteration (defaults 1.0e-8 / 10000). The convergence check and breakdowns are described in Convergence by Solver.

16.2 solver()

Description Computes the eigenvalue of smallest absolute value and its eigenvector.

Synopsis

template< class Tmat, class Teigen_val, class Teigen_vec, class Tvec = parcel_double,
          class Tprecon_mat = parcel_double, class Tprecon_vec = parcel_double >
void solver(parcel::matrix<Tmat> &Mat,
            parcel::vector<Teigen_val> &EigenValue, parcel::vector<Teigen_vec> &EigenVec);

Arguments Same as solver() of power.

Requirements Satisfy the common requirements (an in-order queue, a registered matrix, and the queues and lengths of the vectors). The inner linear solver uses the same queue. AA is nonsingular. The eigenvalue of smallest absolute value is real. With set_linsolve_algo(LINSOLVE_PCG), AA is symmetric (positive definite or negative definite). The last three are not checked.

Return Value None.

MPI Collective. All ranks must call it with the same settings.

Notes For a nonsymmetric matrix whose eigenvalues of smallest absolute value form a complex conjugate pair, the Rayleigh quotient does not converge. In that case, use shift-invert of ks_arnoldi with σ=0\sigma = 0.

See Also get_linsolve_failures(), the “Eigenvalue Solvers” chapter

Example

parcel::krylov::inverse_power<> ip;
ip.solver(A, lam, v);