Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-19 Thread Jonathan Cast

On 19 Jan 2008, at 2:52 AM, Kalman Noel wrote:


Jonathan Cast wrote:

On 12 Jan 2008, at 3:23 AM, Kalman Noel wrote:

   (2) lim a_n  = ∞

[...]

   (2) means that the sequence does not converge,


To a value in R.  Again, inf is a perfectly well defined extended
real number, and behaves like any other element of R u {-inf, inf}.
(Although that structure isn't quite a field --- 0 * inf isn't
defined, nor is inf - inf).


Out of curiosity, is there some typical application domain for  
extended real

numbers?


In calculus and elementary analysis, the notion of limits at/to  
infinity, improper Riemann integrals, etc., are introduced by a  
succession of `special notations'.  Taking the extended real numbers  
as the underlying space permits these notations to be defined more  
compositionally, because ∞ is now an ordinary mathematical object.


For example, if f is a nonnegative measurable function, ∫f on a  
measurable set is /always/ defined (as an extended real number) and  
the special case of an `integrable' function is simply one where the  
integral (which is an actual mathematical value) is an element of R.   
So, when we say ∫f ∈ R, that notation is compositional --- that's  
real set membership there.  Similarly, ∫_{-∞}^∞ f is defined (as  
a Lebesgue integral) the same way any other integral is, because the  
interval [-∞, ∞] is a perfectly good mathematical object.


jcc

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-18 Thread Ben Franksen
Benja Fallenstein wrote:
 On Jan 10, 2008 9:22 AM, Mitar [EMAIL PROTECTED] wrote:
 I understand that proper mathematical behavior would be that as 0/0 is
 mathematically undefined that 0/0 cannot be even compared to 1.
 
 My understanding is that common mathematical practice is that
 comparing an undefined value to anything (including itself) always
 yields false; x /= x is sometimes used to formalize x is
 undefined.

In Mathematics one usually avoids comparing undefined values. If one does
the result is undefined, too, of course. IOW, the whole calculation is
worthless scribble.

Cheers
Ben

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-14 Thread David Roundy
On Fri, Jan 11, 2008 at 07:10:20PM -0800, Jonathan Cast wrote:
 On 11 Jan 2008, at 10:12 AM, Achim Schneider wrote:
 
 David Roundy [EMAIL PROTECTED] wrote:
 
 Prelude let x=1e-300/1e300
 Prelude x
 0.0
 Prelude x/x
 NaN
 
 The true answer here is that x/x == 1.0 (not 0 or +Infinity), but
 there's no way for the computer to know this, so it's NaN.
 
 Didn't catch this the first time around, but: only to a physicist.

I don't understand what you're saying below.  Do you mean that the
true answer is not 1.0, or that it's not reasonable for the computer to
call it NaN?  Since 1.0 is the answer you get for high-precision
computations, it's hard to see how you can argue that it's a wrong answer.

 (I mean no disrespect to the author of darcs, but nevertheless the  
 point stands).  Back in the real world, 0 / 0 may be defined  
 arbitrarily, or left undefined.  (Defining it breaks the wonderful  
 property that, if lim (xn) = x, lim (yn) = y, and x/y = z, then lim  
 (xn / yn) = z.  This is considered a Bad Thing by real  
 mathematicians).  In fact, in integration theory 0 * inf = 0 for  
 certain 'multiplications', which gives the lie to 0 / 0.
-- 
David Roundy
Department of Physics
Oregon State University
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-14 Thread Jonathan Cast

On 14 Jan 2008, at 9:56 AM, David Roundy wrote:


On Fri, Jan 11, 2008 at 07:10:20PM -0800, Jonathan Cast wrote:

On 11 Jan 2008, at 10:12 AM, Achim Schneider wrote:


David Roundy [EMAIL PROTECTED] wrote:


Prelude let x=1e-300/1e300
Prelude x
0.0
Prelude x/x
NaN

The true answer here is that x/x == 1.0 (not 0 or +Infinity), but
there's no way for the computer to know this, so it's NaN.


Ah.  My apologies.  Must remember to read first, then flame...

You are right that, in Ratio Integer, you get this result.  But you  
can't get that answer in Double.


jcc

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-13 Thread Jonathan Cast

On 11 Jan 2008, at 11:25 PM, Achim Schneider wrote:


Jonathan Cast [EMAIL PROTECTED] wrote:


On 11 Jan 2008, at 10:12 AM, Achim Schneider wrote:


David Roundy [EMAIL PROTECTED] wrote:


Prelude let x=1e-300/1e300
Prelude x
0.0
Prelude x/x
NaN

The true answer here is that x/x == 1.0 (not 0 or +Infinity), but
there's no way for the computer to know this, so it's NaN.


Didn't catch this the first time around, but: only to a physicist.
(I mean no disrespect to the author of darcs, but nevertheless the
point stands).  Back in the real world, 0 / 0 may be defined
arbitrarily, or left undefined.  (Defining it breaks the wonderful
property that, if lim (xn) = x, lim (yn) = y, and x/y = z, then lim
(xn / yn) = z.  This is considered a Bad Thing by real
mathematicians).  In fact, in integration theory 0 * inf = 0 for
certain 'multiplications', which gives the lie to 0 / 0.


whereas lim( 0 ) * lim( inf ) is anything you want, or, more  
precisely,

the area of the thing you started with.


I think you're thinking of the Riemann integral (I was thinking of  
the Lebesgue integral, and in particular the definition of the  
integral for step functions).  That integral can be informally  
characterized as the sum of infinitely many terms, each zero (it's a  
limit of finite sums, where the largest (in the sense of absolute  
value) term in each sum goes to 0 as the sequence proceeds).  That's  
scarcely a rigorous characterization, and it overlooks a ton of  
issues (like the fact that neither an infinite sum nor a sum  
identically 0 terms is actually involved), and it's scarcely relevant  
to the numerical analysis question of what 0/0 should return except  
to point out that any definition is going to make *somebody*'s  
algorithm silently go wrong...


jcc


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-13 Thread Jonathan Cast

On 12 Jan 2008, at 3:23 AM, Kalman Noel wrote:


Achim Schneider wrote:

Actually, lim( 0 ) * lim( inf ) isn't anything but equals one, and
the anything is defined to one (or, rather, is _one_ anything) to be
able to use the abstraction. It's a bit like the difference between
eight pens and a box of pens. If someone knows how to properly
formalise n = 1, please speak up.


Sorry if I still don't follow at all.


That's ok, neither does he.


  Here is how I understand (i. e.
have learnt) lim notation, with n ∈ N, a_n ∈ R.  (Excuse my poor
terminology, I have to translate this in my mind from German maths
language ;-).


OK so far.  I actually had a professor in uni who would randomly  
switch to German during lectures; I'll do my best to follow your  
notation :)



  My point of posting this is that I don't see how to
accommodate the lim notation as I know it with your term. The limit of
infinity?  What is the limit of infinity,


If you extend your concept of `sequence' to include sequences of  
extended real numbers, the limit of the sequence that is identically  
inf is inf.  Otherwise, the notation isn't really meaningful.



and why should I multiplicate
it with 0?  Why should I get 1?

(1) lim a_n  = a(where a ∈ R)
(2) lim a_n  = ∞
(3) lim a_n  = − ∞
(4) lim { x → x0 } f(x) = y (where f is a function into R)

(1) means that the sequence of reals a_n converges towards a.

(2) means that the sequence does not converge,


To a value in R.  Again, inf is a perfectly well defined extended  
real number, and behaves like any other element of R u {-inf, inf}.   
(Although that structure isn't quite a field --- 0 * inf isn't  
defined, nor is inf - inf).



because you can
always find a value that is /larger/ than what you hoped might
be the limit.

(3) means that the sequence does not converge, because you can
always find a value that is /smaller/ than what you hoped  
might

be the limit.

(4) means that for any sequence of reals (x_n ∈ dom f)  
converging
towards x0, we have lim f(x_n) = y.  For this equation  
again, we

have the three cases above.


jcc

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-13 Thread Jonathan Cast

On 12 Jan 2008, at 3:33 AM, Cristian Baboi wrote:

On Sat, 12 Jan 2008 13:23:41 +0200, Kalman Noel  
[EMAIL PROTECTED] wrote:



Achim Schneider wrote:

Actually, lim( 0 ) * lim( inf ) isn't anything but equals one, and
the anything is defined to one (or, rather, is _one_ anything) to be
able to use the abstraction. It's a bit like the difference between
eight pens and a box of pens. If someone knows how to properly
formalise n = 1, please speak up.


Sorry if I still don't follow at all.  Here is how I understand  
(i. e.

have learnt) lim notation, with n ∈ N, a_n ∈ R.  (Excuse my poor
terminology, I have to translate this in my mind from German maths
language ;-).  My point of posting this is that I don't see how to
accommodate the lim notation as I know it with your term. The  
limit of
infinity?  What is the limit of infinity, and why should I  
multiplicate

it with 0?  Why should I get 1?

(1) lim a_n  = a(where a ∈ R)
(2) lim a_n  = ∞
(3) lim a_n  = − ∞
(4) lim { x → x0 } f(x) = y (where f is a function into R)

(1) means that the sequence of reals a_n converges towards a.

(2) means that the sequence does not converge, because you can
always find a value that is /larger/ than what you hoped  
might

be the limit.
   (3) means that the sequence does not converge, because you can
always find a value that is /smaller/ than what you hoped  
might

be the limit.

(4) means that for any sequence of reals (x_n ∈ dom f)  
converging
towards x0, we have lim f(x_n) = y.  For this equation  
again, we

have the three cases above.


Suppose lim a_n = a , lim b_n = b, c_2n = a_n, c_2n+1 = b_n.

What is lim c_n ?


If a = b, lim c_n = a = b.  Otherwise lim c_n is undefined, in the  
sense that there is no number c such that the assertion lim c_n = c  
is true.  The `=' in this assertion isn't an equality; it's just a  
bit of math syntax, used in the special case where it isn't overly  
confusing.


jcc

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-13 Thread Jonathan Cast

On 12 Jan 2008, at 4:06 AM, Achim Schneider wrote:


Kalman Noel [EMAIL PROTECTED] wrote:


Achim Schneider wrote:

Actually, lim( 0 ) * lim( inf ) isn't anything but equals one, and
the anything is defined to one (or, rather, is _one_ anything) to be
able to use the abstraction. It's a bit like the difference between
eight pens and a box of pens. If someone knows how to properly
formalise n = 1, please speak up.


Sorry if I still don't follow at all.  Here is how I understand  
(i. e.

have learnt) lim notation, with n ∈ N, a_n ∈ R.  (Excuse my poor
terminology, I have to translate this in my mind from German maths
language ;-).  My point of posting this is that I don't see how to
accommodate the lim notation as I know it with your term. The  
limit of

infinity?  What is the limit of infinity, and why should I
multiplicate it with 0?  Why should I get 1?



n * n = 1 where

  lim   lim
 n - 0   n - oo


wtf?





You don't get 1, you start off with it.


If you start off with anything, you can often end up with it as  
well.  Enlightenment comes when you realize that sometimes you don't,  
and you acquire the ability to change your mind.



If you want to find the area
of a function,


Under, not of.


you slice 1^2 into infinitely many parts and then look
how much every single slice differs from lim( 0 ) * 1


Beg pardon?  lim(0) = 0.  lim(0) * 1 = 0.


, all that
lim( inf ) many times.


You can't do this.  lim(inf) = inf is an extended real number, and is  
completely unrelated to aleph_0 = the least upper bound of N.  inf is  
not a cardinality and cannot be a number of times.



When you've finished counting pebble, you know
how to scale this 1^2 to match it with your normal value of 1.

n = 12
n = 1 * n

now, 1 is twelve. QED: The wrath of algebra.


`Algebra'


One as a pure concept is
a very strange beast, as it can mean anything.


To you.  Mathematicians assign a different meaning to the concept.




jcc

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-13 Thread Achim Schneider
Jonathan Cast [EMAIL PROTECTED] wrote:

  You don't get 1, you start off with it.
 
 If you start off with anything, you can often end up with it as  
 well.  Enlightenment comes when you realize that sometimes you
 don't, and you acquire the ability to change your mind.
 
  n = 12
  n = 1 * n
 
  now, 1 is twelve. QED: The wrath of algebra.
 
 `Algebra'
 
Damnit, this is exactly what I meant. It's all about analysing some
1, until you found something interesting, and then continue all over
with that new interesting thing that is now also a 1, 'cos you want
to re-use your framework.

I'll better stop right here.

-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Kalman Noel
Achim Schneider wrote:
 whereas lim( 0 ) * lim( inf ) is anything you want

Indeed I suppose that »lim inf«, which is a notation I'm not familiar
with, is not actually defined to mean anything?

Kalman

--
Find out how you can get spam free email.
http://www.bluebottle.com/tag/3

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Achim Schneider
Kalman Noel [EMAIL PROTECTED] wrote:

 Achim Schneider wrote:
  whereas lim( 0 ) * lim( inf ) is anything you want
 
 Indeed I suppose that »lim inf«, which is a notation I'm not familiar
 with, is not actually defined to mean anything?
 
It's an ad-hoc expression of as the slices approach zero size, their
number approaches infinity. It's more an observation than anything
else. I have no idea how a professional mathematician would formalise
it.


-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Henning Thielemann

On Sat, 12 Jan 2008, Achim Schneider wrote:

 Kalman Noel [EMAIL PROTECTED] wrote:

  Achim Schneider wrote:
   whereas lim( 0 ) * lim( inf ) is anything you want
 
  Indeed I suppose that »lim inf«, which is a notation I'm not familiar
  with, is not actually defined to mean anything?
 
 It's an ad-hoc expression of as the slices approach zero size, their
 number approaches infinity. It's more an observation than anything
 else. I have no idea how a professional mathematician would formalise
 it.

In Haskell you could professionally formalize it, if you would have a
function, which computes the limit of a sequence:
   limit :: [Real] - Real
  (Cf. Why functional progrmaming matters
 http://www.math.chalmers.se/~rjmh/Papers/whyfp.html)


let xs = iterate (1+) 1-- example for lim (inf)
ys = map recip xs  -- example for lim (0)
in  limit (zipWith (*) xs ys)

If 'limit xs' and 'limit ys' are defined, then it holds
   limit (zipWith (*) xs ys)   ==   limit xs * limit ys
 but in your case 'limit xs' does not exist. You can imagine it as
infinity, but to make it formally safe, you need something non-standard
analysis.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Achim Schneider
Achim Schneider [EMAIL PROTECTED] wrote:

 Kalman Noel [EMAIL PROTECTED] wrote:
 
  Achim Schneider wrote:
   whereas lim( 0 ) * lim( inf ) is anything you want
  
  Indeed I suppose that »lim inf«, which is a notation I'm not
  familiar with, is not actually defined to mean anything?
  
 It's an ad-hoc expression of as the slices approach zero size, their
 number approaches infinity. It's more an observation than anything
 else. I have no idea how a professional mathematician would formalise
 it.
 
Actually, lim( 0 ) * lim( inf ) isn't anything but equals one, and
the anything is defined to one (or, rather, is _one_ anything) to be
able to use the abstraction. It's a bit like the difference between
eight pens and a box of pens. If someone knows how to properly
formalise n = 1, please speak up.


-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Kalman Noel
Achim Schneider wrote:
 Actually, lim( 0 ) * lim( inf ) isn't anything but equals one, and
 the anything is defined to one (or, rather, is _one_ anything) to be
 able to use the abstraction. It's a bit like the difference between
 eight pens and a box of pens. If someone knows how to properly
 formalise n = 1, please speak up.

Sorry if I still don't follow at all.  Here is how I understand (i. e.
have learnt) lim notation, with n ∈ N, a_n ∈ R.  (Excuse my poor
terminology, I have to translate this in my mind from German maths
language ;-).  My point of posting this is that I don't see how to
accommodate the lim notation as I know it with your term. The limit of
infinity?  What is the limit of infinity, and why should I multiplicate
it with 0?  Why should I get 1?

(1) lim a_n  = a(where a ∈ R)
(2) lim a_n  = ∞
(3) lim a_n  = − ∞
(4) lim { x → x0 } f(x) = y (where f is a function into R)

(1) means that the sequence of reals a_n converges towards a.

(2) means that the sequence does not converge, because you can
always find a value that is /larger/ than what you hoped might
be the limit.

(3) means that the sequence does not converge, because you can
always find a value that is /smaller/ than what you hoped might
be the limit.

(4) means that for any sequence of reals (x_n ∈ dom f) converging
towards x0, we have lim f(x_n) = y.  For this equation again, we
have the three cases above.

Kalman

--
Find out how you can get spam free email.
http://www.bluebottle.com/tag/3

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Cristian Baboi
On Sat, 12 Jan 2008 13:23:41 +0200, Kalman Noel  
[EMAIL PROTECTED] wrote:



Achim Schneider wrote:

Actually, lim( 0 ) * lim( inf ) isn't anything but equals one, and
the anything is defined to one (or, rather, is _one_ anything) to be
able to use the abstraction. It's a bit like the difference between
eight pens and a box of pens. If someone knows how to properly
formalise n = 1, please speak up.


Sorry if I still don't follow at all.  Here is how I understand (i. e.
have learnt) lim notation, with n ∈ N, a_n ∈ R.  (Excuse my poor
terminology, I have to translate this in my mind from German maths
language ;-).  My point of posting this is that I don't see how to
accommodate the lim notation as I know it with your term. The limit of
infinity?  What is the limit of infinity, and why should I multiplicate
it with 0?  Why should I get 1?

(1) lim a_n  = a(where a ∈ R)
(2) lim a_n  = ∞
(3) lim a_n  = − ∞
(4) lim { x → x0 } f(x) = y (where f is a function into R)

(1) means that the sequence of reals a_n converges towards a.

(2) means that the sequence does not converge, because you can
always find a value that is /larger/ than what you hoped might
be the limit.
   (3) means that the sequence does not converge, because you can
always find a value that is /smaller/ than what you hoped might
be the limit.

(4) means that for any sequence of reals (x_n ∈ dom f) converging
towards x0, we have lim f(x_n) = y.  For this equation again, we
have the three cases above.


Suppose lim a_n = a , lim b_n = b, c_2n = a_n, c_2n+1 = b_n.

What is lim c_n ?


 Information from NOD32 
This message was checked by NOD32 Antivirus System for Linux Mail Servers.
 part000.txt - is OK
http://www.eset.com
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Achim Schneider
Kalman Noel [EMAIL PROTECTED] wrote:

 Achim Schneider wrote:
  Actually, lim( 0 ) * lim( inf ) isn't anything but equals one, and
  the anything is defined to one (or, rather, is _one_ anything) to be
  able to use the abstraction. It's a bit like the difference between
  eight pens and a box of pens. If someone knows how to properly
  formalise n = 1, please speak up.
 
 Sorry if I still don't follow at all.  Here is how I understand (i. e.
 have learnt) lim notation, with n ∈ N, a_n ∈ R.  (Excuse my poor
 terminology, I have to translate this in my mind from German maths
 language ;-).  My point of posting this is that I don't see how to
 accommodate the lim notation as I know it with your term. The limit of
 infinity?  What is the limit of infinity, and why should I
 multiplicate it with 0?  Why should I get 1?
 

n * n = 1 where

  lim   lim
 n - 0   n - oo  


You don't get 1, you start off with it. If you want to find the area
of a function, you slice 1^2 into infinitely many parts and then look
how much every single slice differs from lim( 0 ) * 1, all that
lim( inf ) many times. When you've finished counting pebble, you know
how to scale this 1^2 to match it with your normal value of 1.

n = 12
n = 1 * n

now, 1 is twelve. QED: The wrath of algebra. One as a pure concept is
a very strange beast, as it can mean anything.

Like, if you take something and try to understand it by dividing it
successively into infinitely many parts, the meaning of each part will
approach zero, as you don't change the thing you're analysing but the
nature of your lenses.

If you ever want to watch a zen master frowning or despair, tell him
exactly that.

-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Pierre-Evariste Dagand
2008/1/12, Cristian Baboi [EMAIL PROTECTED]:
 Suppose lim a_n = a , lim b_n = b, c_2n = a_n, c_2n+1 = b_n.

 What is lim c_n ?

This reminds me of these good old days in Classe prépa (something
typically french) doing these silly things with sequences and
Epsilons...

So let's try to do it :

First, if we assume that a = b, that's ok : lim c_n = a = b

Second, we consider that a \neq b. We will show that c_n do not have a limit.
By contraction, we assume that  c_n has a limit c.

Then, by definition of limit, we have :

\exists N, \forall n \geq N, | c_n - c | \leq \epsilon

Therefore, this result holds for the suits (c_2n) and (c_{2n+1}), ie. :

\exists N, \forall n \geq N, | c_2n - c | \leq \epsilon and
\exists N, \forall n \geq N, | c_{2n+1} - c | \leq \epsilon

By definition of c_2n and c_{2n+1}, we can replace them by a_n and b_n :

\exists N, \forall n \geq N, | a_n - c | \leq \epsilon  and
\exists N, \forall n \geq N, | b_n -c | \leq \epsilon

By definition of limit, this means that :

lim a_n = c  andlim b_n = c

By unicity of the limit, this means that :
a = c   and b = c

Leading to a contradiction as we have assumed that a \neq b.

Q.E.D.

But I'm still wondering about the relation between this and Haskell...

-- 
Pierre-Evariste DAGAND
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Jonathan Cast

On 12 Jan 2008, at 1:45 AM, Achim Schneider wrote:


Kalman Noel [EMAIL PROTECTED] wrote:


Achim Schneider wrote:

whereas lim( 0 ) * lim( inf ) is anything you want


Indeed I suppose that »lim inf«, which is a notation I'm not familiar
with, is not actually defined to mean anything?


It's an ad-hoc expression of as the slices approach zero size, their
number approaches infinity. It's more an observation than anything
else. I have no idea how a professional mathematician would formalise
it.


I suspected as much.

You mean that, for any extended real number z, two sequences of real  
numbers xn and yn may be chosen so that lim(xn) = 0, lim(yn) = inf,  
and lim(xn * yn) = z.


jcc





--
(c) this sig last receiving data processing entity. Inspect headers  
for

past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited.

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Cristian Baboi
On Sat, 12 Jan 2008 13:55:19 +0200, Kalman Noel  
[EMAIL PROTECTED] wrote:



Cristian Baboi:

Suppose lim a_n = a , lim b_n = b, c_2n = a_n, c_2n+1 = b_n.

What is lim c_n ?


If my intuition was of any importance here, it would claim that c_n
diverges, because if I roughly approximate c_n by the sequence c' =
⟨a,b,a,b,...⟩, then I note that c' oscillates, so c_n »roughly
oscillates«.

Kalman


You mean something like this x=a:b:x  ?


___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-12 Thread Kalman Noel
Cristian Baboi wrote:
Cristian Baboi:
 Suppose lim a_n = a , lim b_n = b, c_2n = a_n, c_2n+1 = b_n.
 What is lim c_n ?

 If my intuition was of any importance here, it would claim that c_n
 diverges, because if I roughly approximate c_n by the sequence c' =
 ⟨a,b,a,b,...⟩, then I note that c' oscillates, so c_n »roughly
 oscillates«.
 
 You mean something like this x=a:b:x  ?

Ah, you try to be on-topic by using Haskell syntax :)

Obviously though, I really forgot to consider the case a = b... But that's
enough OT for today, I guess.

Kalman

--
Get a free email account with anti spam protection.
http://www.bluebottle.com/tag/2

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-11 Thread Ketil Malde
Achim Schneider [EMAIL PROTECTED] writes:

 You need to use the / operator, if you want to do floating-point
 division.

 Yes, exactly, integers don't have +-0 and +-infinity... only
 (obviously) a kind of nan.

No, failure (exception, bottom) is different from NaN, which is just
another value in the domain - admittedly one which behaves rather
strangely.

 Said differently: I don't know a thing about floats or numerics.

Perhaps it helps to think of floating point values as intervals? If +0
means some number between 0 and the next possible representable
number (and similar for -0), it may make more sense to have 1/+0 and
1/-0 behave differently.  

-k
-- 
If I haven't seen further, it is by standing in the footprints of giants
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-11 Thread David Roundy
On Fri, Jan 11, 2008 at 02:54:20PM +0100, Achim Schneider wrote:
 +-0 / +-0 is always NaN 'cos you can't tell which one is bigger and
 thus can't decide between positive and negative Infinity, and it
 isn't both, either.
 
 But then there's +0/0 and -0/0, which would be +Infinity and
 -Infinity, and +0  0  -0. AFAIK there are no floats with three zero
 values, though. 

No, +0/0 might be 0 or finite instead of +Infinity, so it's a NaN.

e.g. consider

Prelude let x=1e-300/1e300
Prelude x
0.0
Prelude x/x
NaN

The true answer here is that x/x == 1.0 (not 0 or +Infinity), but there's
no way for the computer to know this, so it's NaN.
-- 
David Roundy
Department of Physics
Oregon State University
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-11 Thread Achim Schneider
Ketil Malde [EMAIL PROTECTED] wrote:

 Achim Schneider [EMAIL PROTECTED] writes:
 
  You need to use the / operator, if you want to do floating-point
  division.
 
  Yes, exactly, integers don't have +-0 and +-infinity... only
  (obviously) a kind of nan.
 
 No, failure (exception, bottom) is different from NaN, which is just
 another value in the domain - admittedly one which behaves rather
 strangely.
 
s/a kind of/not entirely unlike a/

  Said differently: I don't know a thing about floats or numerics.
 
 Perhaps it helps to think of floating point values as intervals? If +0
 means some number between 0 and the next possible representable
 number (and similar for -0), it may make more sense to have 1/+0 and
 1/-0 behave differently.  
 
Hmmm... ah.

+-0 / +-0 is always NaN 'cos you can't tell which one is bigger and
thus can't decide between positive and negative Infinity, and it
isn't both, either.

But then there's +0/0 and -0/0, which would be +Infinity and
-Infinity, and +0  0  -0. AFAIK there are no floats with three zero
values, though. 


-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-11 Thread Achim Schneider
David Roundy [EMAIL PROTECTED] wrote:

 Prelude let x=1e-300/1e300
 Prelude x
 0.0
 Prelude x/x
 NaN
 
 The true answer here is that x/x == 1.0 (not 0 or +Infinity), but
 there's no way for the computer to know this, so it's NaN.

Wl.. math philosophy, Ok.

You can't divide something in a way that uses no slices. You just don't
cut, if you cut zero times. Which is what you do when you divide by
one, mind you, not when you divide by zero. Division by [1..0] equals
multiplication by [1..]. You can't get to the end of either spectrum,
just axiomatically dodge around the singularities to axiomatically
connect the loose ends.

There is no true answer here, the question is wrong.

And you're using floats where only rationals can tackle the problem.



I was wrong in claiming that 
  But then there's +0/0 and -0/0, which would be +Infinity and
  -Infinity, and +0  0  -0. AFAIK there are no floats with three
  zero values, though. 
, both are NaN. 


-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-11 Thread Lennart Augustsson
Also, there are only two zeros, +0 and -0 and they compare equal.

On Jan 11, 2008 10:12 AM, Achim Schneider [EMAIL PROTECTED] wrote:



 I was wrong in claiming that
   But then there's +0/0 and -0/0, which would be +Infinity and
   -Infinity, and +0  0  -0. AFAIK there are no floats with three
   zero values, though.
 , both are NaN.


 --
 (c) this sig last receiving data processing entity. Inspect headers for
 past copyright information. All rights reserved. Unauthorised copying,
 hiring, renting, public performance and/or broadcasting of this
 signature prohibited.

 ___
 Haskell-Cafe mailing list
 Haskell-Cafe@haskell.org
 http://www.haskell.org/mailman/listinfo/haskell-cafe

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-11 Thread Jonathan Cast

On 11 Jan 2008, at 10:12 AM, Achim Schneider wrote:


David Roundy [EMAIL PROTECTED] wrote:


Prelude let x=1e-300/1e300
Prelude x
0.0
Prelude x/x
NaN

The true answer here is that x/x == 1.0 (not 0 or +Infinity), but
there's no way for the computer to know this, so it's NaN.


Didn't catch this the first time around, but: only to a physicist.   
(I mean no disrespect to the author of darcs, but nevertheless the  
point stands).  Back in the real world, 0 / 0 may be defined  
arbitrarily, or left undefined.  (Defining it breaks the wonderful  
property that, if lim (xn) = x, lim (yn) = y, and x/y = z, then lim  
(xn / yn) = z.  This is considered a Bad Thing by real  
mathematicians).  In fact, in integration theory 0 * inf = 0 for  
certain 'multiplications', which gives the lie to 0 / 0.





Wl.. math philosophy, Ok.

You can't divide something in a way that uses no slices. You just  
don't

cut, if you cut zero times. Which is what you do when you divide by
one, mind you, not when you divide by zero. Division by [1..0] equals
multiplication by [1..].


Right.  (Although 0 * inf is defined by fiat, as noted above).


You can't get to the end of either spectrum,
just axiomatically dodge around the singularities to axiomatically
connect the loose ends.


`Axiomatically' --- you mean by re-defining standard notation like *  
and / to mean what you need in this case.  I think this is a  
different thing than setting up ZFC so everyone agrees on what a  
`set' is from henceforth.



There is no true answer here, the question is wrong.


Exactly.

jcc

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-11 Thread Achim Schneider
Jonathan Cast [EMAIL PROTECTED] wrote:

 On 11 Jan 2008, at 10:12 AM, Achim Schneider wrote:
 
  David Roundy [EMAIL PROTECTED] wrote:
 
  Prelude let x=1e-300/1e300
  Prelude x
  0.0
  Prelude x/x
  NaN
 
  The true answer here is that x/x == 1.0 (not 0 or +Infinity), but
  there's no way for the computer to know this, so it's NaN.
 
 Didn't catch this the first time around, but: only to a physicist.   
 (I mean no disrespect to the author of darcs, but nevertheless the  
 point stands).  Back in the real world, 0 / 0 may be defined  
 arbitrarily, or left undefined.  (Defining it breaks the wonderful  
 property that, if lim (xn) = x, lim (yn) = y, and x/y = z, then lim  
 (xn / yn) = z.  This is considered a Bad Thing by real  
 mathematicians).  In fact, in integration theory 0 * inf = 0 for  
 certain 'multiplications', which gives the lie to 0 / 0.

whereas lim( 0 ) * lim( inf ) is anything you want, or, more precisely,
the area of the thing you started with. It's like taking seven balls,
assembling them into a hexagon and claiming it's a circle.

Such things just happen if you are working with pure abstractions.

-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-10 Thread Achim Schneider
John Meacham [EMAIL PROTECTED] wrote:

 On Thu, Jan 10, 2008 at 11:17:18AM +0200, Yitzchak Gale wrote:
  The special case of 1/0 is less clear, though. One might
  decide that it should be an error rather than NaN, as some
  languages have.
 
 It is neither, 
 
 1/0 = Infinity
 -1/0 = -Infinity
 
Just out of curiosity:

1/-0 = -Infinity?
-1/-0 = Infinity?

If you don't have two separate values for nothing, one approaching from
negativeness and one from positiveness, defining the result to be
infinite instead of NaN makes no sense IMHO.

-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-10 Thread David Roundy
On Thu, Jan 10, 2008 at 09:24:34PM +0100, Achim Schneider wrote:
 John Meacham [EMAIL PROTECTED] wrote:
  On Thu, Jan 10, 2008 at 11:17:18AM +0200, Yitzchak Gale wrote:
   The special case of 1/0 is less clear, though. One might
   decide that it should be an error rather than NaN, as some
   languages have.
  
  It is neither, 
  
  1/0 = Infinity
  -1/0 = -Infinity

 Just out of curiosity:
 
 1/-0 = -Infinity?
 -1/-0 = Infinity?

Yes.  (You could have tried this for yourself, you know... but I suppose
haskell-cafe isn't a bad interactive Haskell interpreter, perhaps more user
friendly than ghci.)
-- 
David Roundy
Department of Physics
Oregon State University
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-10 Thread Achim Schneider
David Roundy [EMAIL PROTECTED] wrote:

 On Thu, Jan 10, 2008 at 09:24:34PM +0100, Achim Schneider wrote:
  John Meacham [EMAIL PROTECTED] wrote:
   On Thu, Jan 10, 2008 at 11:17:18AM +0200, Yitzchak Gale wrote:
The special case of 1/0 is less clear, though. One might
decide that it should be an error rather than NaN, as some
languages have.
   
   It is neither, 
   
   1/0 = Infinity
   -1/0 = -Infinity
 
  Just out of curiosity:
  
  1/-0 = -Infinity?
  -1/-0 = Infinity?
 
 Yes.  (You could have tried this for yourself, you know... but I
 suppose haskell-cafe isn't a bad interactive Haskell interpreter,
 perhaps more user friendly than ghci.)

Prelude 1 `div` 0
*** Exception: divide by zero

That's it. One just shouldn't just extrapolate and think you didn't mean
GHC but IEEE...

-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: 0/0 1 == False

2008-01-10 Thread David Roundy
On Thu, Jan 10, 2008 at 09:41:53PM +0100, Achim Schneider wrote:
 David Roundy [EMAIL PROTECTED] wrote:
  On Thu, Jan 10, 2008 at 09:24:34PM +0100, Achim Schneider wrote:
   John Meacham [EMAIL PROTECTED] wrote:
1/0 = Infinity
-1/0 = -Infinity
  
   Just out of curiosity:
   
   1/-0 = -Infinity?
   -1/-0 = Infinity?
  
  Yes.  (You could have tried this for yourself, you know... but I
  suppose haskell-cafe isn't a bad interactive Haskell interpreter,
  perhaps more user friendly than ghci.)

 Prelude 1 `div` 0
 *** Exception: divide by zero
 
 That's it. One just shouldn't just extrapolate and think you didn't mean
 GHC but IEEE...

Prelude 1/(-0)
-Infinity

You need to use the / operator, if you want to do floating-point division.
-- 
David Roundy
Department of Physics
Oregon State University
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


[Haskell-cafe] Re: 0/0 1 == False

2008-01-10 Thread Achim Schneider
David Roundy [EMAIL PROTECTED] wrote:

 On Thu, Jan 10, 2008 at 09:41:53PM +0100, Achim Schneider wrote:
  David Roundy [EMAIL PROTECTED] wrote:
   On Thu, Jan 10, 2008 at 09:24:34PM +0100, Achim Schneider wrote:
John Meacham [EMAIL PROTECTED] wrote:
 1/0 = Infinity
 -1/0 = -Infinity
   
Just out of curiosity:

1/-0 = -Infinity?
-1/-0 = Infinity?
   
   Yes.  (You could have tried this for yourself, you know... but I
   suppose haskell-cafe isn't a bad interactive Haskell interpreter,
   perhaps more user friendly than ghci.)
 
  Prelude 1 `div` 0
  *** Exception: divide by zero
  
  That's it. One just shouldn't just extrapolate and think you didn't
  mean GHC but IEEE...
 
 Prelude 1/(-0)
 -Infinity
 
 You need to use the / operator, if you want to do floating-point
 division.

Yes, exactly, integers don't have +-0 and +-infinity... only
(obviously) a kind of nan.

It's just that with the stuff I do I know I have some logical problem
in my formulas when I get any special floating point value anywhere,
and using --excess-precision can only make the numbers more precise.

Said differently: I don't know a thing about floats or numerics.

-- 
(c) this sig last receiving data processing entity. Inspect headers for
past copyright information. All rights reserved. Unauthorised copying,
hiring, renting, public performance and/or broadcasting of this
signature prohibited. 

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe