Re: [prolog-standard] Re: log10/1, log/2, min/2, and max/2

From: Mary Kroening <mary_at_amzi.com>
Date: Thu, 16 Nov 2006 19:53:25 -0500

We (Amzi!) allows infinite precision real numbers with as many digits
as you want left and right of the decimal point. All our predicates
and operators calculate and compare numbers without regard to any
internal representation.

Regards,
Mary Kroening

At 02:39 PM 11/16/2006, you wrote:
>On Thursday 16 November 2006 19:37, Paulo Moura wrote:
> > > Why is this desirable, when it leads to the problems indicated?
> > > After all, this is an arithmetic function, so there is no reason
> > > why it should not use the same floating-point contagion rule
> > > like all other symmetric binary operations,
> >
> > Agree.
>
>First of all, in practice min and max are rarely used with mixed types.
>Second, most implementations providing unbounded integer arithmetic do
>not provide unbounded floats, so max(2<<10000, 2.0) raises an error if
>we promote the floats. Before that you may loose acuracy in the
>unnecessary promotion to float. Select semantics avoids all these
>problems.
>
> > See the Jan reply he sent this morning. In the current version
> > (5.6.23) the result also depends on the argument order, which I think
> > is buggy behavior.
>
>If you leave it undefined, there is no problem. I can't see realistic
>scenarios where it matters.
>
> --- Jan
>
>
>_______________________________________________
>prolog-standard mailing list
>prolog-standard_at_neve.di.ubi.pt
>http://neve.di.ubi.pt/mailman/listinfo/prolog-standard

----------------------------------------------------
   Amzi! inc.
     47 Redwood Road
     Asheville, NC 28804 U.S.A.
   www.amzi.com
   www.arulesxl.com
   tel +1 828 350 0350
----------------------------------------------------

_______________________________________________
prolog-standard mailing list
prolog-standard_at_neve.di.ubi.pt
http://neve.di.ubi.pt/mailman/listinfo/prolog-standard
Received on Mon Jul 14 2008 - 13:01:02 EST

This archive was generated by hypermail 2.2.0 : Wed Sep 08 2010 - 23:28:17 EST