This project introduces two MATLAB functions designed to extract a few eigenpairs from large-scale matrices, focusing on efficiency and accuracy. The functions are:
myarnoldi.m
: Implements the Arnoldi method for eigenvalue computation.
myarnoldiro.m
: Enhances the Arnoldi method by incorporating reorthogonalization to improve numerical stability and accuracy.
- Sparse Matrix Support: Utilizes MATLAB's sparse matrix capabilities to efficiently handle large-scale problems.
- Demonstration with west0479 Matrix: The correctness of the implemented methods is verified using west0479, a MATLAB sparse demonstration matrix, showcasing the functions' ability to accurately compute eigenvalues and eigenvectors.
- Residuals Computation: Calculates residuals to ensure the accuracy of the computed eigenpairs, with expectations of achieving machine precision for small iteration counts (e.g., 20, 40).
- Ritz Values Computation: Involves computing and plotting Ritz values against the exact eigenvalues of the matrix to visually verify the effectiveness of the Arnoldi processes.
- Error Analysis: Employs relative error analysis for the top three largest eigenvalues, illustrating the convergence behavior and the benefits of reorthogonalization through iteration-based plots.
- Large Matrix Testing: Extends the validation to large matrices from the "SuiteSparse Matrix Collection," demonstrating the methods' scalability and efficiency on real-world datasets. Shift-and-Invert Spectral Transformation: Incorporates a shift-and-invert strategy in the reorthogonalized Arnoldi method to target eigenvalues near a specified value, enhancing the method's utility for specific applications.
To successfully run the provided MATLAB functions and test the algorithms with your matrices, follow these setup instructions carefully. This guide assumes you have MATLAB installed. If not, please visit the official MATLAB website to download and install MATLAB before proceeding.
The project uses west0479, a sparse demonstration matrix included in MATLAB, as a primary example for testing. To load this matrix into your workspace, execute the following commands in the MATLAB Command Window:
load west0479;
A = west0479;
Timothy Hwang