Re: IEEEP1788
On 2015-04-27 17:13:24 -0700, Richard Fateman wrote:
> 2. Arbitrary precision floats and many operations on them
> are supported by existing programming packages such as MPFR,
> or any number of computer algebra systems.
> In fact these provide much more: truly arbitrary precision floats, directed
> roundings,
> elementary function evaluation, input and output.
>
> I expect that a system such as MPFR could be set up to include
> a component that provides exact/complete dot product.
In MPFR, dot product is more or less equivalent to a sum since one
can first compute the exact products[*]. Then, concerning the sum,
the main issue is the exponent range: the result could require much
more memory than available (something like 2^60 bytes). What could
be possible is that the user carefully chooses a bound on the size
of the destination based on the magnitude of the inputs, but then
this is just a particular case of a correctly rounded sum (where
the result is expected to be exact).
FYI, until very recently, mpfr_sum could take too much memory even if
the exact result could be represented in a not too large precision.
I've entirely redesigned the sum algorithm and rewritten mpfr_sum,
and since 2015-04-10, the MPFR trunk has this new implementation,
which should be very efficient.
[*] assuming you don't have overflows/underflows. But the large
exponent range in MPFR should be sufficient in practice.
--
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)