math module for Decimals

rlbuvel at gmail.com rlbuvel at gmail.com
Mon Dec 29 11:42:59 EST 2008


On Dec 29, 10:22 am, Steve Holden <st... at holdenweb.com> wrote:
> Raymond L. Buvel wrote:
> > Since the interest is more in extended precision than in decimal
> > representation, there is another module that may be of interest.
>
> >http://calcrpnpy.sourceforge.net/clnum.html
>
> > It interfaces to the Class Library for Numbers (CLN) library to provide
> > both arbitrary precision floating point and complex floating point
> > numbers and the usual math functions.
>
> > While I am the author of this module, I agree with Mark that a module
> > based on MPFR would be better since you have better control over
> > precision and rounding.
>
> > I have looked at Sage (which uses MPFR) but it is a huge integrated
> > package so you can't just import what you need into one of your usual
> > Python scripts.
>
> > I wrote the clnum module mainly to support arbitrary precision in an RPN
> > calculator available from the same SourceForge project.  However, it
> > also works nicely as a stand-alone module.
>
> > At this time, there is no Windows installer available for Python 2.6
> > because I don't use Windows at home and the person who normally builds
> > the installer for me is no longer interested.  If someone wants to
> > follow the published instructions and send me the resulting installer, I
> > will put it up on SourceForge.
>
> I'm not sure why nobody has mentioned gmpy, except possibly because it
> advertises its alpha status and doesn't have many active developers.
>
> regards
>  Steve
> --
> Steve Holden        +1 571 484 6266   +1 800 494 3119
> Holden Web LLC              http://www.holdenweb.com/

The main reason is that it doesn't support the functions the OP wanted
(sin, cos, log, etc.).  This was one of the reasons I developed clnum
(in addition to needing complex numbers).

Ray



More information about the Python-list mailing list