gmp does integers and ratios. mpf does bigfloats. mpfr does bigfloats
with rounding. using gmp...
just to clarify.
there is also other stuff e.g. interval, that might be worth importing.
or see the boatload of random stuff in sage.
rjf
On 10/20/13 12:44 PM, Stavros Macrakis wrote:
> Fateman implemented Maxima bigfloats long before GMP (1979 vs. 1991).
> Fateman has also implemented interfaces between Lisp and GMP.
>
> Presumably the reasons that Maxima doesn't use GMP are:
>
> 1) Someone would have to implement it, and no one has. This means not
> just changing the bfloat package, but also checking the rest of the
> Maxima codebase for obscure dependencies on the bfloat representation.
> 2) Not all Lisps that Maxima runs on support the standard FFI. In
> particular, if I remember correctly, there is no Lisp implementation
> that: supports FFI; can recover cleanly from stack overflow; and runs
> on Windows (probably the largest group of users).
> 3) There doesn't seem to be any compelling reason to change. (If it
> ain't broke, don't fix it.)
>
> -s
>
> On Sun, Oct 20, 2013 at 3:28 PM, Raymond Toy <toy.raymond at gmail.com
> <mailto:toy.raymond at gmail.com>> wrote:
>
> >>>>> "Henry" == Henry Baker <hbaker1 at pipeline.com
> <mailto:hbaker1 at pipeline.com>> writes:
>
> Henry> Thanks for the pointers; I wasn't aware of these packages.
> Henry> While we're talking about this stuff, how come Common
> Lisp & Maxima don't simply use GNU MP (GMP) ?
>
> Perhaps CL predates GMP? In any case, I suspect that bignums in most
> applications are less than a 5 words (160 bits or so), so having
> to call out to GMP is probably not worth the effort. Only in special
> applications like crypto and math are bignums really big, so perhaps
> it wasn't worth the effort to hook in gmp when the implementations
> were being created.
>
> (There's a comment in the CMUCL sources, I think, that says most
> bignums are just one word bigger than a fixnum, Don't know how true
> that was back then and whether that's still true today.)
>
> Henry> http://gmplib.org/
>
> Henry> A lot of Common Lisp's have a foreign function interface
> Henry> which should enable the ability to call at least some of
> Henry> these functions.
>
> GCL uses GMP. I don't know of any other implementation that uses
> GMP. (Clisp has it's own specialized implementation which is, by all
> accounts, as good as GMP.)
>
> Ray
>
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu <mailto:Maxima at math.utexas.edu>
> http://www.math.utexas.edu/mailman/listinfo/maxima
>
>
>
>
> _______________________________________________
> Maxima mailing list
> Maxima at math.utexas.edu
> http://www.math.utexas.edu/mailman/listinfo/maxima