numpy.linalg.eigvals

numpy.linalg.eigvals(a)

Compute the eigenvalues of a general matrix.

Parameters:

a : array_like, shape (M, M)

A complex or real matrix whose eigenvalues and eigenvectors will be computed.

Returns:

w : ndarray, shape (M,)

The eigenvalues, each repeated according to its multiplicity. They are not necessarily ordered, nor are they necessarily real for real matrices.

Raises:

LinAlgError :

If the eigenvalue computation does not converge.

See also

eig
eigenvalues and right eigenvectors of general arrays
eigvalsh
eigenvalues of symmetric or Hemitiean arrays.
eigh
eigenvalues and eigenvectors of symmetric/Hermitean arrays.

Notes

This is a simple interface to the LAPACK routines dgeev and zgeev that sets the flags to return only the eigenvalues of general real and complex arrays respectively.

The number w is an eigenvalue of a if there exists a vector v satisfying the equation dot(a,v) = w*v. Alternately, if w is a root of the characteristic equation det(a - w[i]*I) = 0, where det is the determinant and I is the identity matrix.

Previous topic

numpy.linalg.eigh

Next topic

numpy.linalg.eigvalsh

This Page

Quick search