Re: [eigen] Eigenvalue calculation on integer matrices

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]


On 25.02.2014 13:19, Felix wrote:
Hello,

I noticed big errors when trying to calculate the eigenvalues of Integer
matrices. When using SelfAdjointEigenSolver<MatrixXi> the Eigenvalues
don't match the real ones at all. When calling eigenvalues on MatrixXi I
just get a floating point exception. This probably has to do with
Integer Matrices not having integer Eigenvalues. However there should be
an implicit conversion or an error message the way it is right now if I
hadn't compared the results to the ones from octave I would not have
noticed that anything is wrong at all.

Yes, our algorithm uses floating point operations, and for integers they simply convert the result back to an integer (which usually generates bogus results). I agree that we should forbid to compile decompositions which depend on non-supported operations. E.g. LU/LDLT can be allowed for floating point and rational types but should not be allowed for integer types. Most other decompositions are only available if sqrt (and possibly other functions) are available.

I thought I filed a bug for that once, but I can't find it, so I made a new:
http://eigen.tuxfamily.org/bz/show_bug.cgi?id=750

Christoph



--
----------------------------------------------
Dipl.-Inf., Dipl.-Math. Christoph Hertzberg
Cartesium 0.049
Universität Bremen
Enrique-Schmidt-Straße 5
28359 Bremen

Tel: +49 (421) 218-64252
----------------------------------------------



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/