Re: demonic numbers !
From: Cameron MacKinnon (cmackin+nn_at_clearspot.net)
Date: 02/07/05
- Next message: David Sletten: "Re: Evaulate an arithmetic expression"
- Previous message: Kent M Pitman: "Re: demonic problem descriptions"
- In reply to: Wade Humeniuk: "Re: demonic numbers !"
- Next in thread: David Steuber: "Re: demonic numbers !"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Mon, 07 Feb 2005 12:27:57 -0500
Wade Humeniuk wrote:
> Coby Beck wrote:
>
>>
>> This i would like to see!
>> But an interesting experiment might be a multiple choice question you
>> could give to different sets of people:
>>
>> What does .1111 mean?
>>
>> a) .1111d0
This is nonsensical except to some computer programmers. Among the
broader numerate population, the letter d never appears in the middle of
a number.
>> b) 1111/10000
Everyone is taught in primary school that 1111/10000 and 0.1111 are the
same number. Lispers associate fractions with exactitude, but this is
certainly not the case among the broader public.
>> c) 1.111x10e-4
...and they learn that scientific notation is used as a terse notation
for numbers whose significant digits lie far from the decimal point. The
notation implies a physical constant or measurement, which further
implies limited accuracy and finite error.
>> d) all of the above
Programmers tend to make artificial distinctions between the above
number formats, because our languages overload the notation to choose
between various internal representations, something non programmers
don't know about.
> Actually I see that it is meant as .1111... (repeating
> decimal)
>
> which is 1/9
This is reasonable, but I would have lost marks in elementary school if
I'd said that 0.1111 and 0.1111... were equivalent. Further, and this is
key, I don't think casual users and the nearly innumerate would be
surprised if they punched in 0.1111 and the computer used that number
exactly (instead of guessing that 1/9 was desired) for their
calculation. Even if they WERE surprised, there's a logical and
intuitive way to hint to the machine that more digits are required --
just add more digits.
Of course, I don't think there's anything stopping a conforming Lisp
from storing 0.1111 as 3^-2 so people writing portable code shouldn't
depend on it being otherwise.
The quiz writer didn't offer the choice of 7455795/67108864. I wonder
why not?
The whole quiz is bogus. It is attempting to enlighten us on the
question "what should a computer assume about a number, absent context?"
A better question to investigate might be "what can a computer discover
about a number, given context?" Might we not use hints such as whether
the number is involved in indexing, whether it is converted to base 10
(i.e. printed) and with what precision?
- Next message: David Sletten: "Re: Evaulate an arithmetic expression"
- Previous message: Kent M Pitman: "Re: demonic problem descriptions"
- In reply to: Wade Humeniuk: "Re: demonic numbers !"
- Next in thread: David Steuber: "Re: demonic numbers !"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|