Re: Portable syntax of interval literals
Dmitry Nadezhin wrote:
> When an implementation refuses to support rational notation in interval
> literals, it shall check only syntax and it may avoid any computations
> by returning "Entire". It shall return:
> textToInterval("[1\3,0.4]")=NaI
> but it may return
> textToInterval("[1/3,0.4]")=Entire
> textToInterval("[1/3,0.3]")=Entire
I think this is going too far. I get it that an implementation that
returns Entire for everything would not sell well on grounds of quality
of service, but I also believe that there are algorithms that depend on
known error bounds, so that any input method less than accurate would be
impossible to deal with. If your parser scans the entire given rational
to make sure it is syntactically correct, it is not much more trouble to
compute an enclosure with an error bound of somewhere between half an ulp
and one ulp. The same reasoning led to 754-2008 requiring that ALL given
digits (no bound on number of digits) be significant, even though digits
beyond a required minimum can be condensed into a sticky bit, which allows
correctly-rounded conversion (first in decimal, for excess digits, then in
binary for the minimum required precision) to be performed with fixed space
requirements.
Michel.
---Sent: 2013-09-29 05:48:41 UTC