Skip to main content

sparse_eig

Function sparse_eig 

Source
pub fn sparse_eig<F>(
    matrix: &CsrMatrix<F>,
    config: &SparseEigenConfig,
    preconditioner: Option<&dyn Preconditioner<F>>,
) -> SparseResult<SparseEigenResult<F>>
where F: Float + NumAssign + Sum + SparseElement + Debug + 'static,
Expand description

Compute eigenvalues and eigenvectors of a sparse matrix.

This is the primary entry point. It selects the best algorithm based on the configuration and matrix properties.

§Arguments

  • matrix - Square sparse matrix in CSR format
  • config - Solver configuration
  • preconditioner - Optional preconditioner (used by LOBPCG)

§Returns

SparseEigenResult with eigenvalues, eigenvectors, and convergence info.