ANN: DecInt 0.3 - Arithmetic for very large decimal integers

Discussion in 'Python' started by casevh@comcast.net, Nov 30, 2005.

  1. Guest

    DecInt is a class that support arithmetic on very large decimal
    integers.

    For example, it can calculate the decimal form of the 42nd Mersenne
    prime, all 7,816,230 digits, in less than 21 seconds. And less than 6
    seconds if gmpy 1.01 is available.

    This version is significantly faster than the prior version.

    Multiplication used a combination of 4-way Toom-Cook and Nussbaumer
    convolution. Pure Python multiplication is less than 10x slower than
    GMP's hand optimised assembler code!

    Division uses a new algorithm based on David M. Smith's division
    algorithm. Pure Python division is 16x slower than GMP but can actually
    be faster in some instances; for example, dividing a 2,000,000 digit
    number by an 800,000 digit number.

    DecInt can be found at http://home.comcast.net/~casevh/

    (DecInt used to be called BigDecimal; I renamed it to avoid confusion
    with the "decimal" class include with Python.)

    Enjoy,

    casevh
     
    , Nov 30, 2005
    #1
    1. Advertisements

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Raymond Arthur St. Marie II of III

    very Very VERY dumb Question About The new Set( ) 's

    Raymond Arthur St. Marie II of III, Jul 23, 2003, in forum: Python
    Replies:
    4
    Views:
    724
    Raymond Hettinger
    Jul 27, 2003
  2. M.-A. Lemburg
    Replies:
    3
    Views:
    777
    M.-A. Lemburg
    Apr 4, 2005
  3. Replies:
    1
    Views:
    341
    Alex Martelli
    Dec 20, 2005
  4. shanx__=|;-

    very very very long integer

    shanx__=|;-, Oct 16, 2004, in forum: C Programming
    Replies:
    19
    Views:
    2,054
    Merrill & Michele
    Oct 19, 2004
  5. Abhishek Jha

    very very very long integer

    Abhishek Jha, Oct 16, 2004, in forum: C Programming
    Replies:
    4
    Views:
    726
    jacob navia
    Oct 17, 2004
  6. Peter

    Very very very basic question

    Peter, Feb 8, 2005, in forum: C Programming
    Replies:
    14
    Views:
    816
    Dave Thompson
    Feb 14, 2005
  7. very large integers

    , Oct 8, 2006, in forum: C++
    Replies:
    13
    Views:
    706
    Ivan Vecerina
    Oct 9, 2006
  8. GGP
    Replies:
    3
    Views:
    1,540
    Andrew Thompson via JavaKB.com
    Apr 2, 2007
Loading...