public class Lanczos
extends java.lang.Object
Although computationally efficient in principle, the method as initially formulated was not useful, due to its numerical instability. In this implementation, we use partial reorthogonalization to make the method numerically stable.
| Constructor and Description |
|---|
Lanczos() |
| Modifier and Type | Method and Description |
|---|---|
static EigenValueDecomposition |
eigen(Matrix A,
int k)
Find k largest approximate eigen pairs of a symmetric matrix by the
Lanczos algorithm.
|
static EigenValueDecomposition |
eigen(Matrix A,
int k,
double kappa)
Find k largest approximate eigen pairs of a symmetric matrix by the
Lanczos algorithm.
|
static SingularValueDecomposition |
svd(Matrix A,
int k)
Find k largest approximate singular triples of a matrix by the
Lanczos algorithm.
|
static SingularValueDecomposition |
svd(Matrix A,
int k,
double kappa)
Find k largest approximate singular triples of a matrix by the
Lanczos algorithm.
|
public static SingularValueDecomposition svd(Matrix A, int k)
A - the matrix supporting matrix vector multiplication operation.k - the number of singular triples we wish to compute for the input matrix.
This number cannot exceed the size of A.public static SingularValueDecomposition svd(Matrix A, int k, double kappa)
A - the matrix supporting matrix vector multiplication operation.k - the number of singular triples we wish to compute for the input matrix.
This number cannot exceed the size of A.kappa - relative accuracy of ritz values acceptable as singular values.public static EigenValueDecomposition eigen(Matrix A, int k)
A - the matrix supporting matrix vector multiplication operation.k - the number of eigenvalues we wish to compute for the input matrix.
This number cannot exceed the size of A.public static EigenValueDecomposition eigen(Matrix A, int k, double kappa)
A - the matrix supporting matrix vector multiplication operation.k - the number of eigenvalues we wish to compute for the input matrix.
This number cannot exceed the size of A.kappa - relative accuracy of ritz values acceptable as eigenvalues.