caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* Complex NaN / infinity?
@ 2006-11-16 18:02 Chris King
  0 siblings, 0 replies; only message in thread
From: Chris King @ 2006-11-16 18:02 UTC (permalink / raw)
  To: OCaml Mailing List

Hi,

It's been reported before as a bug [1] that Caml's Complex module
doesn't properly support complex NaN and infinities: the current
behavior is that expressions such as "div one zero" return a complex
number with real and imaginary parts both set to NaN.  The proper
behavior would be to return a value representing directed or complex
infinity, depending on whether "zero" is directed or not.  Avoiding
infinite results doesn't help either, since expressions such as "pow
zero one" rely on infinity internally.

Has anyone made a replacement module fixing these problems?  I've
started work on a replacement which uses both polar and Cartesian
representations internally but I figure I'd ask before duplicating
work.

- Chris King

[1] http://caml.inria.fr/mantis/view.php?id=1817


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-11-16 18:02 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-11-16 18:02 Complex NaN / infinity? Chris King

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).