Re: [Scheme-reports] More NaN and Infsanity John Cowan (30 Apr 2012 07:43 UTC)
Re: [Scheme-reports] More NaN and Infsanity Peter Bex (30 Apr 2012 09:16 UTC)
Re: [Scheme-reports] More NaN and Infsanity Jussi Piitulainen (30 Apr 2012 10:51 UTC)
Re: [Scheme-reports] More NaN and Infsanity John Cowan (30 Apr 2012 17:02 UTC)
Re: [Scheme-reports] More NaN and Infsanity Jussi Piitulainen (30 Apr 2012 18:40 UTC)
Re: [Scheme-reports] More NaN and Infsanity John Cowan (30 Apr 2012 17:01 UTC)
Re: [Scheme-reports] More NaN and Infsanity Peter Bex (30 Apr 2012 17:34 UTC)

Re: [Scheme-reports] More NaN and Infsanity Jussi Piitulainen 30 Apr 2012 18:39 UTC

John Cowan writes:
> Jussi Piitulainen scripsit:
>
> > The construction of the Stern-Brocot tree that I've seen (related to
> > the notion of the simplest rational in an interval) starts with two
> > extreme "values", 0/1 and 1/0. All positive rationals are built
> > between these. The pretense is that 1/0 is the simplest rational
> > representation of "infinity". So it may make sense to return +inf.0.
>
> Except that +inf.0 is not rational, so it can't be returned.

Yes, I just tried to give a bit of context, perhaps not the best.
Would it be a good idea to add some reference to the text? Rationalize
may be the least-well-known of Scheme's mathematical functions. I
don't know what to cite, though.

> > (Does the spec really say "rational but not real"?)
>
> No, the converse:  +inf.0, -inf.0, and +nan.0 are real but not rational.
> R6RS says the same.

Good. The other way it sounded weird.

_______________________________________________
Scheme-reports mailing list
Scheme-reports@scheme-reports.org
http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports