From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from majordomo@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id AAA11018; Sat, 22 Sep 2001 00:25:43 +0200 (MET DST) X-Authentication-Warning: pauillac.inria.fr: majordomo set sender to owner-caml-list@pauillac.inria.fr using -f Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id AAA11014 for ; Sat, 22 Sep 2001 00:25:42 +0200 (MET DST) Received: from mail.virginia.edu (mail.Virginia.EDU [128.143.2.9]) by concorde.inria.fr (8.11.1/8.10.0) with SMTP id f8LMPfn06669 for ; Sat, 22 Sep 2001 00:25:41 +0200 (MET DST) Received: from config.mail.virginia.edu by mail.virginia.edu id aa08021; 21 Sep 2001 18:25 EDT Received: from localhost (fjr6b@localhost) by config.mail.Virginia.EDU (8.9.3/8.9.3) with ESMTP id SAA25522 for ; Fri, 21 Sep 2001 18:25:39 -0400 (EDT) Date: Fri, 21 Sep 2001 18:25:39 -0400 (EDT) From: Post Office!~/sentmail X-X-Sender: To: caml-list@inria.fr MMDF-Warning: Parse error in original version of preceding line at mail.virginia.edu Subject: [Caml-list] Complex numbers in ocaml Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-caml-list@pauillac.inria.fr Precedence: bulk I'm trying to write a system for complex numbers in ocaml for some numerical work I'm doing, and I thought I'd ask if anyone else has such code already existant. Otherwise, given an abstract for numbers type number = Int of int | Float of float | Complex of float * float | Error;; is there an easy way to coerce numbers back out of type number in order to operate on them? Fred Ross ------------------- Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr