Download Mathemagic 4

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts
Transcript
Oulun Lyseo / Galois-club
Mathemagic 4
Guessing the circled digit
HOW TO DO IT?
Ask the spectator to
a) choose any positive integer n, preferably less than million to avoid tedious calculations,
but in principle any number would do.
b) rearrange (scramble) the digits of this number in some random order to get a new
number nā€™.
c) subtract the smaller of these two numbers from the larger
d) circle one of the nonzero digits in the resulting number āŒˆš‘› āˆ’ š‘›ā€²āŒ‰
e) announce you the remaining digits
(The steps a-d are done hidden from you.)
Then after a few seconds thinking you can announce the circled digit. You obtain it by
calculating mentally the sum of digits announced to you, taking its digital root, and
subtracting this root from 9.
WHY IT WORKS?
Digital root of the integer n is calculated by adding up all its digits to obtain the first digital
sum. If this sum is 10 or greater then repeat the same process for it to obtain the second
digital sum. Continue until the sum is less than 10. This final sum is the digital root of the
original number n.
For example, if n = 29170665, then the first digital sum is 34 and the second 7 which then is
the digital root of n.
The trick works because the subtraction in step c) necessarily (see the proof below) produces
a number whose digital root is 9. Then the circled digit must be equal to 9 ā€“ (the digital sum of
the remaining digits) which is easy to calculate mentally.
Proof that the digital root of |š’ āˆ’ š’ā€²| is always equal to 9:
CLAIM 1: The difference |š‘› āˆ’ š‘›ā€²| is divisible by 9.
Proof of this: Assume that n > nā€™ and that
(*)
š‘› = š‘‘0 āˆ™ 100 + š‘‘1 āˆ™ 101 + ā‹Æ + š‘‘š‘˜ āˆ™ 10š‘˜
where š‘‘š‘– ā€™s are the digits in the decimal representation of n.
Each digit š‘‘š‘– appears also in the decimal representation of the scrambled number nā€™ which
can be written analogously to (*) as the sum of powers of 10 and where one of the terms is
š‘‘š‘– āˆ™ 10š‘— . The difference š‘› āˆ’ š‘›ā€² can then be written as a sum of terms
š‘–
š‘—
š‘‘š‘– āˆ™ 10 āˆ’ š‘‘š‘– āˆ™ 10 = {
š‘‘š‘– āˆ™ 10š‘— (10š‘–āˆ’š‘— āˆ’ 1), if š‘– ā‰„ š‘—
š‘‘š‘– āˆ™ 10š‘– (10š‘—āˆ’š‘– āˆ’ 1), if š‘— > š‘–
In both cases the term in brackets is divisible by 9 and so is š‘‘š‘– āˆ™ 10š‘– āˆ’ š‘‘š‘– āˆ™ 10š‘— and also š‘› āˆ’ š‘›ā€².
QED 1
CLAIM 2: A given number š‘š is divisible by 9 if and only if its digital root equals 9.
Proof of this: Since the digital root is obtained by successively adding up the digits it clearly
suffices to prove that š‘š is divisible by 9 if and only if the sum of its digits is divisible by 9.
So assume that š‘‘š‘˜ š‘‘š‘˜āˆ’1 ā€¦ š‘‘1 š‘‘0 is the decimal representation of m where š‘‘š‘– ā€™s are the digits.
Then
(*)
š‘š = š‘‘0 āˆ™ 100 + š‘‘1 āˆ™ 101 + ā‹Æ + š‘‘š‘˜āˆ’1 āˆ™ 10š‘˜āˆ’1 + š‘‘š‘˜ āˆ™ 10š‘˜
Let š‘ (š‘š) be the sum of digits in m, that is
š‘ (š‘š) = š‘‘0 + š‘‘1 + ā‹Æ + š‘‘š‘˜āˆ’1 + š‘‘š‘˜
Consider the difference
š‘š āˆ’ š‘ (š‘š) = (š‘‘0 āˆ™ 100 + š‘‘1 āˆ™ 101 + ā‹Æ + š‘‘š‘˜āˆ’1 āˆ™ 10š‘˜āˆ’1 + š‘‘š‘˜ āˆ™ 10š‘˜ ) āˆ’(š‘‘0 + š‘‘1 + ā‹Æ + š‘‘š‘˜āˆ’1 + š‘‘š‘˜ )
= š‘‘0 (100 āˆ’ 1) + š‘‘1 (101 āˆ’ 1) + ā‹Æ + š‘‘š‘˜āˆ’1 (10š‘˜āˆ’1 āˆ’ 1) + š‘‘š‘˜ (10š‘˜ āˆ’ 1),
which is clearly divisible by 9 since each of the differences (10š‘– āˆ’ 1) is divisible by 9.
Hence we have for some positive integer p that
š‘š āˆ’ š‘ (š‘š) = 9š‘
If m is divisible by 9 then š‘ (š‘š) = š‘š āˆ’ 9š‘ is too, and conversely if š‘ (š‘š) is divisible by 9 then
š‘š = š‘ (š‘š) + 9š‘ is too. This completes the proof of Claim 2.
QED 2
Claims 1 and 2 together prove that the digital root of |š‘› āˆ’ š‘›ā€²| is always equal to 9.