Test Matrices for Eigenvalue Analysis

TEST_EIGEN, a MATLAB library which generates eigenvalue tests.

The current version of the code can only generate a symmetric or nonsymmetric matrix of arbitrary size, with eigenvalues distributed according to a normal distribution whose mean and standard deviation are specified by the user (subroutines R8SYMM_GEN and R8NSYMM_GEN).


The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.


TEST_EIGEN is available in a C version and a C++ version and a FORTRAN90 version and a MATLAB version and a Python version.

Related Data and Programs:

ARPACK, MATLAB programs which illustrate the use of the ARPACK libraruy to compute eigenvalues of large matrices.

EISPACK, a FORTRAN90 library which carries out eigenvalue computations; superseded by LAPACK;

JACOBI_EIGENVALUE, a MATLAB library which implements the Jacobi iteration for the iterative determination of the eigenvalues and eigenvectors of a real symmetric matrix.

LAPACK_EXAMPLES, a FORTRAN90 program which demonstrates the use of the LAPACK linear algebra library.

POWER_METHOD, a MATLAB library which carries out the power method for finding a dominant eigenvalue and its eigenvector.


TEST_MAT, a MATLAB library which defines test matrices.


  1. Robert Gregory, David Karney,
    A Collection of Matrices for Testing Computational Algorithms,
    Wiley, 1969,
    ISBN: 0882756494,
    LC: QA263.G68.
  2. Pete Stewart,
    Efficient Generation of Random Orthogonal Matrices With an Application to Condition Estimators,
    SIAM Journal on Numerical Analysis,
    Volume 17, Number 3, June 1980, pages 403-409.

Source Code:

Last revised on 28 March 2019.