Hello,
>>>>> "Hans" == Hans Aberg <[EMAIL PROTECTED]> writes:
Hans> The idea with calling the floating numbers floating numbers
Hans> is that it is possible to implement real numbers too, as in
Hans> computer algebra programs.
we have to distinguish between 3 sets:
(1) The set of algebraic numbers (rationals + roots etc.).
An arbitrary finite subset of this set can be represented in the machine.
Each element can be represented as a root of a polynomial
with rational coefficients.
An exact representation will be appropriate for things like testing,
whether the square of the square root of 2 is 2.
I guess (I don't know) that it is possible to test whether
two representations represent the same number or not.
(2) The set of all real numbers.
An arbitrary finite subset cannot be represented in the machine.
Specific subsets can be represented, if we agree upon codes
for "e", "pi", "sum from i=a to b of ...", "integral" etc.
The question is: how does evaluation of expressions with these
numbers look like? Simplification based on heuristics?
(3) The set of finite prefixes of a radix representation
of real numbers.
This set will be appropriate for
approximating real numbers. To make this set really useful
there must be a function (less :: "Real" -> "Real" -> Bool),
which always terminates and checks absolutely sure, if the
first argument is less than the second.
Then, numerical mathematicians will damn Haskell, I suppose.
The last set (3) might be a good argument for people to use
Haskell because of its laziness. It also seems to be of most
practical interest.
-------------------------------------------------------------------------------
Christoph Herrmann
E-mail: [EMAIL PROTECTED]
WWW: http://brahms.fmi.uni-passau.de/cl/staff/herrmann.html