https://github.com/cran/pracma
Tip revision: 708a2ad382a163d1eef5af0665e3ae2aad200ced authored by HwB on 21 March 2013, 00:00:00 UTC
version 1.4.5
version 1.4.5
Tip revision: 708a2ad
eig.Rd
\name{eig}
\alias{eig}
\title{Eigenvalue Function (Matlab Style)}
\description{
Eigenvalues of a matrix
}
\usage{
eig(a)
}
\arguments{
\item{a}{real or complex square matrix}
}
\details{
Computes the eigenvalues of a square matrix of real or complex numbers,
using the R routine \code{eigen} without computing the eigenvectors.
}
\value{
Vector of eigenvalues
}
\seealso{
\code{\link{compan}}
}
\examples{
eig(matrix(c(1,-1,-1,1), 2, 2)) #=> 2 0
eig(matrix(c(1,1,-1,1), 2, 2)) # complex values
eig(matrix(c(0,1i,-1i,0), 2, 2)) # real values
}
\keyword{ array }