Your construction gives a rank 1 matrix, so there's a double
eigenvalue of zero.  The two eigenvectors which are found for that
eigenvalue need not be orthogonal, they are just some basis for the
eigenspace.  The entries you thought should be zero are the inner
product of those eigenvectors with each other.

It would be possible for the eigenvector/space functions to detect
when a matrix was real and symmetric, and in that case return
orthgonal eigenvectors, but that is not the way it is at present.
Unless there are other functions which I don't know about.

John Cremona

2008/9/4 chris75de <[EMAIL PROTECTED]>:
>
> Hi,
>
> the following code
>
> b=matrix(3,1,[random() for i in [1..3]])
> B=b*b.transpose()
> lb,Sb=B.right_eigenvectors()
> print lb
> print
> print Sb.transpose()*B*Sb
> print
> print Sb.transpose()*Sb
>
> give's in my sage version 3.0.6 the following result:
>
>
> [1.844328223, 4.46105473802e-17, -3.42287439238e-16]
>
> [       1.844328223 -1.11022302463e-16  2.91433543964e-16]
> [-8.30521194918e-17 -3.99656191956e-18  2.92386038647e-19]
> [ 2.73402117214e-16    2.893962297e-17 -5.58462128744e-17]
>
> [               1.0 -1.66533453694e-16  -7.6327832943e-17]
> [-1.66533453694e-16                1.0     0.709678542323]
> [ -7.6327832943e-17     0.709678542323                1.0]
>
> I think the last matrix have to be the identity matrix, but there are
> two times 0.709678542323 instead of zero.
>
> Christian
>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sage-devel
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to