final message

new topic     » topic index » view thread      » older message » newer message

I don't believe you guys will ever take any notice of what an outsider has to say, but..

These are thingns of some consequence:

Primary facts:

1 There is no multiplicative inverse of zero.
2 A Greatest Common Divisor has to:
. 1 be a divisor. ie it cannot be equal to zero.
. 2 be greater than any other divisor.

. Defining GCD(0,0) = 0 doesn't satisfy either
. condition 2.1 or 2.2.

No mathematical theory defines GCD(0,0) = 0.

The lattice theory article referenced defines
GCD(0,0) = 1 on the grounds that every integer is
divisible by 1. It doesn't satidfy 2.2.

Practical:

GCD(0,0) is given as 0 by a number of programming
languages because the Knuth algorithm would give
that result. Haskell gives it as undefined.

If used as a divisor it will likely produce an
exception or error. This would not necessarily occur
near where the exceptional result was produced.

There is, of course, the other difficulty that the
language may not have a value to return for
'not an integer'.

0/0:

Not indeterminate. See 1.
Can be defined to be any number with the consequence
of talking nonsense.

intdiv(-8,-3):

Dividing -8 envelopes into sets of maximum -3 is easy
1 set holds -8 envelopes. Not what you wanted?
-1 set holds 8 envelopes? - No you can't do that!
Perhaps I am wrong and you can do this. Show me!

Divide -8 envelopes into -3 sets, not so easy
-2 sets hold 3 envelopes, -1 set holds 2 envelopes or
-4 sets hold 2 envelopes, 1 set holds 0 envelopes.

At some time you guys are going to have to admit that
you are seriously talking shit.

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu