On Fri, Mar 03, 2006 at 01:29:06PM +0100, Henning Thielemann wrote:
> To: Matthias Fischmann <[EMAIL PROTECTED]>
> cc: [email protected]
> From: Henning Thielemann <[EMAIL PROTECTED]>
> Date: Fri, 3 Mar 2006 13:29:06 +0100 (MET)
> Subject: Re: [Haskell-cafe] rounding errors with real numbers.
> 
> 
> On Thu, 2 Mar 2006, Matthias Fischmann wrote:
> 
> > > cancellation happens for instance here: 1 + 1e-50 - 1 == 0
> >
> > the function again (in the wasteful original form, for clarity).
> > where do you think cancellation may take place?  isn't what you call
> > canellation a generic rounding error?
> 
>  Cancellation is a special kind of rounding error. Rounding errors appear
> everywhere, in (*), sin, exp and so on, but cancellations only arise on
> differences. They are especially bad, because as the example above shows,
> even if all numbers are given in double precision in the computation
> a+b-a, no digit of the result is correct, that is 100% rounding error! The
> danger of cancellation is everywhere where you subtract numbers of similar
> magnitude.

1 + epsilon - 1 == epsilon, which is zero except for a very small
rounding error somewhere deep in the e-minus-somethings.  how is the
error getting worse than that, for which numbers?



m.

Attachment: signature.asc
Description: Digital signature

_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to