Difference between revisions of "ApCoCoA-1:Num.EigenValuesAndVectors"

From ApCoCoAWiki
(adding keys and types)
m (short descriptions don't start with capitals)
Line 1: Line 1:
 
   <command>
 
   <command>
 
     <title>Numerical.EigenValuesAndVectors</title>
 
     <title>Numerical.EigenValuesAndVectors</title>
     <short_description>Eigenvalues of a matrix</short_description>
+
     <short_description>eigenvalues of a matrix</short_description>
 
<syntax>
 
<syntax>
 
$numerical.EigenValuesAndVectors(A:Matrix):List
 
$numerical.EigenValuesAndVectors(A:Matrix):List

Revision as of 17:58, 7 November 2007

Numerical.EigenValuesAndVectors

eigenvalues of a matrix

Syntax

$numerical.EigenValuesAndVectors(A:Matrix):List

Description

This function returns a List of two matrices, containing numerical approximation to A's eigenvalues and (right hand) eigenvectors.

Therefore the input matrix A has to be rectangular!

It is implemented in the ApCoCoA server, so you need a running server. It was not implemented in version 0.99.4 or previous. Also please keep in mind this method is based on blas/Lapack's eigenvalue solver and uses floating point arithmetic. This is not an exact, algebraic method! The output contains first of a matrix B, where the number of rows contains one of A's eigenvalues. The first column contains the eigenvalue's real part, the second the imaginary. The second part of the list is a matrix of the size of A, containing A's (right hand) eigenvectors. To compute only the left hand's eigenvectors apply this method to Transposed(A).

Example

A:=Mat([[1,2,7,18],[2,4,9,12],[23,8,9,10],[7,5,3,2]]); 
Numerical.EigenValuesAndVectors(A); 
-- CoCoAServer: computing Cpu Time = 0.0038
-------------------------------
[Mat([
  [2038617447977453/70368744177664, 1593056728295919/4503599627370496, 0, 1717983664400761/562949953421312],
  [-3850002255576293/281474976710656, 1593056728295919/4503599627370496, 0, -1717983664400761/562949953421312]
]), Mat([
  [-7110239176083849/18014398509481984, -5241040126502889/9007199254740992, -569232410323621/18014398509481984, 4695168387448581/18014398509481984],
  [-7846388397589843/18014398509481984, -3981313256671163/9007199254740992, -2719422585742633/9007199254740992, -4930385173711605/9007199254740992],
  [-3437594604471165/4503599627370496, 2800381393796867/4503599627370496, 6128985174171139/9007199254740992, 0],
  [-1207381852306067/4503599627370496, 634514467740541/2251799813685248, -2469130937097749/9007199254740992, 6644460631770309/144115188075855872]
])]
-------------------------------

See also

Introduction to CoCoAServer

Numerical.QR

Numerical.SVD

Numerical.EigenValues

Numerical.EigenValuesAndAllVectors