extended precision for intrinsic functions



On 7/22/07, sen1 at math.msu.edu <sen1 at math.msu.edu> wrote:
>   Is there a flag which can be set to force maxima to do all
>   computations in the given session in arbitrary precision, say
>   64 or 128  bit precision?

I think what you are looking for is a way of specifying that all
floating-point calculations be carried out using given precision.
Maxima does not have a way of doing that directly.  But if you convert
all your inputs to bigfloats, I think you will get what you want.

Calculations on integers and rationals are always performed exactly,
and left in symbolic form if they cannot be performed exactly, e.g.
1/3*6 => 2, sin(1/3) => sin(1/3).

Calculations on floating-point numbers (represented as 2.3 or 2.3e4)
are performed using the native floating-point (64-bit on all
platforms, I believe).

Calculations on bigfloats (represented as 2.3b0) are performed using
fpprec decimal digits.  fpprec should be set before any calculations
are performed, and before the bigfloat numbers are read in, so that
the input routine will convert them at the desired precision.

There is not currently a way to have 2.3 be interpreted as 2.3b0
(though I think it has been proposed).

If you have an exact expression, you can have it evaluated using
bigfloats using bfloat(...), e.g. bfloat(sin(1/3)) => 3.27b-1.

All that said, some Maxima functions do not have bigfloat
computational routines, e.g. erf, gamma.  And some parts of Maxima do
not handle bigfloats reasonably, e.g. the rational function package,
some matrix operations, etc.

          -s