[Scheme-reports] Mixed exactness in complex numbers? Peter Bex (23 Mar 2012 19:13 UTC)
Re: [Scheme-reports] Mixed exactness in complex numbers? Andrew Robbins (23 Mar 2012 19:48 UTC)
Re: [Scheme-reports] Mixed exactness in complex numbers? Peter Bex (23 Mar 2012 19:59 UTC)

Re: [Scheme-reports] Mixed exactness in complex numbers? Peter Bex 23 Mar 2012 19:59 UTC

On Fri, Mar 23, 2012 at 03:48:20PM -0400, Andrew Robbins wrote:
> Peter,
>
> I hope this isn't considered too off-topic, but Mathematica has 4
> distinct infinities.
> The usual Infinity (+inf.0 in Scheme), -Infinity (-inf.0 in Scheme),
> and the following:
>
> - ComplexInfinity (might be represented in Scheme as (make-polar
> +inf.0 +nan.0)), and

What about the negative version of this one?

> - DirectedInfinity[z] (might be represented in Scheme as (make-polar
> +inf.0 (angle z))).

Same question here.  And what about (make-polar +nan.0 +nan.0)?

If I'm asking stupid questions, pardon my ignorance.  I don't really
know anything about complex numbers.

> If y is an exact number, then (imag-part (log ...)) should also be exact.
> I'm not sure how many Scheme implementations actually store exact polar
> complex numbers this way, but it helps keep numbers exact.

I wonder about that too.  Even Gambit doesn't represent exact polar complex
numbers exactly.  Perhaps John could provide a list of Schemes that do.

Cheers,
Peter
--
http://sjamaan.ath.cx
--
"The process of preparing programs for a digital computer
 is especially attractive, not only because it can be economically
 and scientifically rewarding, but also because it can be an aesthetic
 experience much like composing poetry or music."
							-- Donald Knuth

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