arbitrary precision linear algebra

Nobody nobody at nowhere.com
Wed Mar 2 17:48:15 EST 2011


On Wed, 02 Mar 2011 06:42:22 -0800, Ben123 wrote:

> Hello. I have a written Python program which currently uses numpy to
> perform linear algebra operations. Specifically, I do matrix*matrix,
> matrix*vector, numpy.linalg.inv(matrix), and linalg.eig(matrix)
> operations. Now I am interested in allowing arbitrary precision. I
> have tried gmpy, bigfloat, mpmath, and decimal but I have been unable
> to easily implement any with my current program. I suspect I have to
> change some commands but I am unsure what.

numpy is implemented in C, and is limited to the language's primitive
types. It provides a "float96" type which I would guess is actually a
"long double" (80 bits on x86). You can't extend numpy's precision by
using a separate arbitary-precision library.




More information about the Python-list mailing list