On Nov 25, 1:28 pm, Daniel Fetchinson <fetchin...@googlemail.com> wrote:
> Okay, I see your point and I completely agree. > Surely it will be faster to do it with integers, will give it a shot. > > Cheers, > Daniel > > -- > Psss, psss, put it down! -http://www.cafepress.com/putitdown You may want to look at using GMPY. GMPY wraps the Gnu Multiple- precision library and includes support for rational arithmetic. I just tested a few calculations involving rational numbers with hundreds to thousands of digits and GMPY's mpq type was between 10x and 100x faster than fractions.Fractions. GMPY is availabe at http://code.google.com/p/gmpy/ casevh Disclaimer: I'm the current maintainer of GMPY. -- http://mail.python.org/mailman/listinfo/python-list