[Haskell-cafe] Why 'round' does not just round numbers ?
Henning Thielemann
lemming at henning-thielemann.de
Mon Oct 27 06:46:01 EDT 2008
On Mon, 27 Oct 2008, Janis Voigtlaender wrote:
> Henning Thielemann wrote:
>> I think one reason is that repeated rounding should not be worse than
>> rounding in one go. Consider the rule 'use ceiling when the first removed
>> digit is 5'. Then
>>
>> 0.45 - (round to one place) -> 0.5 - (round to integer) -> 1
>
> But repeated rounding *is* worse than rounding in one go, under any
> reasonable scheme:
>
> 3.46 -> 3.5 -> 4
With the rounding-to-even route this would be
3.46 -> 3.4 -> 3
so rounding in passes is no worse than rounding in one go for this
example.
> vs.
>
> 3.46 -> 3
>
> That was actually the debate with that teacher. Unbelievable as that
> still is to me today, she advocated the 3.46 -> 3.5 -> 4 route ...
I also know a didact which tells teachers that 1 has no prime
decomposition. Oh, I see, she may have copied that from Wikipedia:
http://en.wikipedia.org/wiki/Prime_factorisation
More information about the Haskell-Cafe
mailing list