# [SciPy-user] genaralised eigen value problem

Perez Kawumi pepe_kawumi@yahoo.co...
Thu Sep 20 22:27:11 CDT 2007

```Just dont know why the value of my third eigen value is incorrect

Matlab
>> a=([1,2,3;4,5,6;7,8,9])
a =
1     2     3
4     5     6
7     8     9
>> b=([9,8,7;6,5,4;3,2,1])
b =
9     8     7
6     5     4
3     2     1
>> [c,d]=eig(a,b)
c =
-0.1538 - 0.0000i  -0.1538 + 0.0000i  -0.5000
-0.8462 - 0.0000i  -0.8462 + 0.0000i   1.0000
1.0000 + 0.0000i   1.0000 - 0.0000i  -0.5000

d =
-1.0000 + 0.0000i        0                  0
0            -1.0000 - 0.0000i        0
0                  0                       0.0172

Python

>>> a=array(([1,2,3],[4,5,6],[7,8,9]))
>>> b=array(([9,8,7],[6,5,4],[3,2,1]))
>>> [d,c]= linalg.eig(a,b)
>>> d
array([-1.         +1.50395773e-08j, -1.         -1.50395773e-08j,
0.01724138 +0.00000000e+00j])
>>> c
array([[-0.15384615 -1.73705175e-09j, -0.15384615 +1.73705175e-09j,
-0.5        +0.00000000e+00j],
[-0.84615385 -9.43749936e-12j, -0.84615385 +9.43749936e-12j,
1.         +0.00000000e+00j],
[ 1.         +1.11534083e-11j,  1.         -1.11534083e-11j,
-0.5        +0.00000000e+00j]])

___________________________________________________________
Want ideas for reducing your carbon footprint? Visit Yahoo! For Good  http://uk.promotions.yahoo.com/forgood/environment.html
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://projects.scipy.org/pipermail/scipy-user/attachments/20070921/e49dce03/attachment.html
```