On Mon, Dec 30, 2019 at 1:40 PM Andrew Barnert <abarn...@yahoo.com> wrote:
>
> On Dec 29, 2019, at 18:20, Chris Angelico <ros...@gmail.com> wrote:
> >
> > On Mon, Dec 30, 2019 at 11:47 AM Steven D'Aprano <st...@pearwood.info> 
> > wrote:
> >>
> >> On Mon, Dec 30, 2019 at 08:30:41AM +1100, Chris Angelico wrote:
> >>
> >>>> Especially since it fails quite a few commonsense tests for whether or
> >>>> not something is a number:
> >> [...]
> >>>> The answer in all four cases is No. If something doesn't quack like a
> >>>> duck, doesn't swim like a duck, and doesn't walk like a duck, and is
> >>>> explicitly called Not A Duck, would we insist that it's actually a duck?
> >>>
> >>> Be careful: This kind of logic and intuition doesn't always hold true
> >>> even for things that we actually DO call numbers. The counting numbers
> >>> follow logical intuition, but you can't count the number of spoons on
> >>> a table and get a result of "negative five" or "the square root of
> >>> two" or "3 + 2i".
> >>
> >> That's because none of those examples are counting numbers :-)
> >>
> >> My set of "commonsense tests" weren't intended to be an exhaustive or
> >> bulletproof set of tests for numberness. They were intended to be
> >> simple, obvious and useful tests: if it quacks, swims and walks like a
> >> duck, it's probably a duck. The silent Legless Burrowing Duck being a
> >> rare exception.[1]
> >
> > Exactly my point! Counting numbers follow logical intuition; but you
> > attested that you could use logical intuition to figure out if
> > something is a "number". Not a "counting number". Logical intuition
> > does NOT explain all the behaviours of non-counting numbers, and you
> > can't say "oh this is illogical ergo it's not a number". The logic of
> > logical intuition is illogical. :)
>
> Counting numbers are intuitively numbers. So are measures. And yet, they’re 
> different. Which one is the “one true numbers”? Who cares? Medieval 
> mathematicians did spend thousands of pages trying to resolve that question, 
> but it’s a lot more productive to just accept that the intuitive notion of 
> “number” is vague and instead come up with systematic ways to define and 
> compare and contrast and relate different algebras (not just those two).
>

That's what I said. You cannot use intuition to define numbers unless
you're willing to restrict it to counting numbers. Therefore, if
intuition cannot define numbers, intuition cannot be used to exclude
non-numbers.

> Are complex numbers numbers? Sure, if you want. Or no, if you prefer. But 
> they’re still not real numbers, much less natural numbers. That’s obvious, 
> and nearly useless. What you really want to know is which properties of the 
> reals also hold of the complex numbers, and that’s a lot less obvious and a 
> lot more useful.
>
> And the same is true for IEEE binary64. You can say they’re not numbers, or 
> that they are, or that some of them are and some of them aren’t, but they’re 
> not the rationals (or the reals or the affinely extended reals or a 
> subalgebra of any of the above); what you really want to know is which 
> properties of the rationals hold under what approximation regime for the IEEE 
> binary64s.
>

And the same is true of the debate about float("nan"). You cannot use
intuition to figure out whether this is a number or not, because
intuition has ALREADY failed us. "Commonsense tests" such as Steven
put forward are not a valid way to debate the edge cases, because they
fail on what we would consider clear cases.

ChrisA
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/H42CEYXNVBWKNKDYVQGVGNLUOPLG4KAT/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to