http://www.emgu.com
Computes eigenvalues and eigenvectors of a symmetric matrix
Namespace:
Emgu.CV
Assembly:
Emgu.CV.World (in Emgu.CV.World.dll) Version: 4.1.1.3497 (4.1.1.3497)
Syntaxpublic static void Eigen(
IInputArray src,
IOutputArray eigenValues,
IOutputArray eigenVectors = null
)
Public Shared Sub Eigen (
src As IInputArray,
eigenValues As IOutputArray,
Optional eigenVectors As IOutputArray = Nothing
)
public:
static void Eigen(
IInputArray^ src,
IOutputArray^ eigenValues,
IOutputArray^ eigenVectors = nullptr
)
static member Eigen :
src : IInputArray *
eigenValues : IOutputArray *
?eigenVectors : IOutputArray
(* Defaults:
let _eigenVectors = defaultArg eigenVectors null
*)
-> unit
Parameters
- src
- Type: Emgu.CVIInputArray
The input symmetric square matrix, modified during the processing - eigenValues
- Type: Emgu.CVIOutputArray
The output vector of eigenvalues, stored in the descending order (order of eigenvalues and eigenvectors is syncronized, of course) - eigenVectors (Optional)
- Type: Emgu.CVIOutputArray
The output matrix of eigenvectors, stored as subsequent rows
RemarksCurrently the function is slower than cvSVD yet less accurate, so if A is known to be positivelydefined (for example, it is a covariance matrix)it is recommended to use cvSVD to find eigenvalues and eigenvectors of A, especially if eigenvectors are not required.
ExamplesTo calculate the largest eigenvector/-value set lowindex = highindex = 1. For legacy reasons this function always returns a square matrix the same size as the source matrix with eigenvectors and a vector the length of the source matrix with eigenvalues. The selected eigenvectors/-values are always in the first highindex - lowindex + 1 rows.
See Also