Eigenvalues and eigenvectors of a Hermitian or real symmetric matrix.
Parameters: | a : array_like, shape (M, M)
UPLO : {‘L’, ‘U’}, optional
|
---|---|
Returns: | w : ndarray, shape (M,)
v : ndarray, shape (M, M)
|
Raises: | LinAlgError :
|
See also
Notes
A simple interface to the LAPACK routines dsyevd and zheevd that compute the eigenvalues and eigenvectors of real symmetric and complex Hermitian 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. The eigenvalues of real symmetric or complex Hermitean matrices are always real. The array v of eigenvectors is unitary and a, w, and v satisfy the equation dot(a,v[i]) = w[i]*v[:,i].