home | index | units | counting | geometry | algebra | trigonometry & functions | calculus
analysis | sets & logic | number theory | recreational | misc | nomenclature & history | physics

Final Answers
© 2000-2008 Gérard P. Michon, Ph.D.

Mathematical Magic

The universe is full of magical things, patiently
waiting for our wits to grow sharper
.
 Top Hat Eden Phillpotts   (1862-1960)
 
That must be wonderful !
I don't understand it at all
.
 (Anonymous)
 
Any sufficiently advanced technology is indistinguishable from magic.
Third Law  of   Arthur C. Clarke  (1917-)

  • 1089:  Subtract a 3-digit number and its reverse, then...
  • Grey Elephants in Denmark: Mental magic  in a classroom.
  • The 5-card trick of Fitch Cheney:  4 cards tell the fifth one.
  • Generalizing the 5-card trick and  Devil's Poker...
  • Kruskal's Count.
     border
     border
     border
  • Paths to God.

 border
 border  border
 border
 border
 border
 border

Related articles on this site:

Related Links (Outside this Site)

Math Magic, by Larry Moss.
1089 and all that, by David Acheson   (Plus magazine, Sept. 2004)
Magic Tricks with NumbersMartin Gardner  (Games Magazine, May 1999).
 
border
border

Mathematical "Magic" Tricks


(2004-12-02)   1089
Pick a 3-digit number where the first and last digits differ by 2 or more...
  • Consider the "reverse" number, obtained by reading it backwards.
  • Subtract the smaller of these two numbers from the larger one.
  • Add the result to its own reverse. 
Why is this always equal to 1089?

This is one of the better tricks of its kind, because the effect of reversing the digits is not obvious to most people at first...  If the 3-digit number reads abc, it's equal to 100a+10b+c, and we have the following result after the second step:

| (100a+10b+c) - (100c+10b+a) |     =     99 | a-c |

The quantity  | a-c |  is between 2 and 9, so the above is a 3-digit multiple of 99, namely: 198, 297, 396, 495, 594, 693, 792 or 891.  The middle digit is always 9, while the first and last digits of any such multiple add up to 9.  Thus, adding the thing and its reverse gives 909 plus twice 90, which is 1089, as advertised.


(2004-04-03)   Grey Elephants in Denmark
Mental magic  for classroom use...   [Single-use collective mentalism]

The teacher tells the class that a crowd can be driven to think about the same thing; very few people will escape the mental picture shared by all others...

Each student in the class is asked to think about a small number and is then instructed to perform the following operations silently.

  • Double the number.
  • Add 8 to the result.
  • Divide the result by 2.
  • Subtract the original number...
  • Convert this into a letter of the alphabet. (1=A, 2=B, 3=C, 4=D, etc.)
  • Think of the name of a country which starts with this letter.
  • Think of an animal whose name starts with the country's second letter.
  • Think of the color of that animal...

The teacher then announces to a puzzled classroom that their collective thinking must have gone wrong, since "there are no grey elephants in Denmark"...

Well, there  are  elephants in Denmark:  At this writing, the home of Kungrao (M), Surin (F) and Tonsak (F) is the Copenhagen Zoo...

The trick works in most parts of the World, but I wonder how many students from the Caribbeans would think of an "ostrich in Dominica" instead.    Just a joke!


Michael Jørgensen (2004-03-24)   The 5-Card Trick of Fitch Cheney
How to reveal one of 5 random cards by showing the other 4 in order.

The 4! = 24 ways of showing 4 given cards in order would not be enough to differentiate among the remaining 48 cards of the pack.  However, since we may choose what card is offered for guessing, we have an additional choice among 5.  This translates into 120 possible courses of action, which is more than enough to convey the relevant information.  Here's one practical way to do so:

Consider two cards of the same suit  (among 5 cards we always have  at least  one such pair available).  Let's call them the   base card  and the  hidden card, in whichever way makes it possible to go from the base card to the hidden card card by counting at most 6 steps clockwise on a circle of the 13 possible values.  (King is followed by Ace, Ace is followed by 2, 3, 4, etc.)

We offer the hidden card up for "guessing".  By revealing the base card first, we reveal immediately the suit of the hidden card and we also set the point where a count of up to 6 "clockwise" steps is to begin to determine the hidden card.

The order in which the remaining 3 cards are presented can be used to reveal this count, as there are 6 possible permutations of 3 given cards.  Using some agreed-upon ordering of the cards in a deck, we have a high card (H), a medium card (M) and a low card (L) in hand.  Some arbitrary code may be used, like:

LMH = 1 ;   LHM = 2 ;   MLH = 3 ;   MHL = 4 ;   HLM = 5 ;   HML = 6


This trick is credited to Dr. William Fitch Cheney, Jr. (Fitch the Magician, 1894-1974)  who earned the first math Ph.D. ever awarded by MIT (1927).

The puzzle is presented in the 1960 book of Wallace Lee  entitled  Math Miracles  (chapter 14, as quoted by Martin Gardner)  and was popularized by the magician Art Benjamin in 1986.  It was used in a 1994 job interview and subsequently appeared on the rec.puzzles newsgroup, where Bob Vesterman posted the particular solution presented above  (1994-04-25).

In 1995, Robert Orenstein implemented Vesterman's encoding for online play at  http://www.anamorph.com/docs/ct/cards.html, but the interactive part has "temporarily" been shut down, since 2002-08-15.

The Best Card Trick  (PDF)  by Michael Kleber.  Mathematical Intelligencer 24 #1 (Winter 2002).


Eric Farmer (2004-03-25)   [Generalization of the above]
Reveal n random cards (from a deck of d) by showing only k of them...

The previous article deals with k=4, n=5, d=52.  The case k=3, n=8, d=13 has been dubbed  Devil's Poker :  The Devil chooses 5 cards of a single suit and you present 3 of the remaining 8 cards one by one to an Angel who must guess the Devil's hand, using a  prior  convention between you and the Angel.

We have   k! C(n,k) = n!/(n-k)!   possible actions to reveal one of  C(d-k,n-k) compatible possibilities.  This task is only possible if the former number exceeds the latter, which means that  n!(d-n)!  must be greater than or equal to  (d-k)! .

In the case considered by Michael Kleber in the Mathematical Intelligencer article (PDF) mentioned at the end of the previous article, we have  k = n-1, so the above inequality boils down to  d < n!+n, as stated by Kleber who goes on to prove that this necessary condition is sufficient to establish a working strategy...


(2006-05-01)   The Kruskal Count
Kruskal's card trick.

This trick is attributed to the physicist Martin J. Kruskal.  It illustrates a statistical feature which is amazing enough when one first encounters it.  Here's one way to present the trick:

If we use a regular deck of cards, we either remove the face cards or attribute to them the same value (1) as aces.  Beforehand, a player choses  secretly  a special number N from 1 to 10.  As the cards from the deck are revealed one by one, the player counts cards and considers the N-th card revealed to be his  new  special number and keeps counting N cards from that one, and so forth...  All told, only a few cards are thus singled out as special.  The majority are not...

Yet, toward the end of the deck the dealer  (the magician)  can confidently point out that one particular card is "special"...

The same trick can demonstrated by a clever dealer which just looks at the cards before dealing them and announce that a specific card (which may be flipped in the deck)  will  turn out to be special.  You may play this version online with a computer which (honestly) shuffles the deck.  Allow yourself to be baffled a few times before reading on...


Well, the explanation is simply statistical.  Consider, for simplicity, the related case of

 Come back later, we're
 still working on this one...

Two subsequences extracted with the above rules from an infinite sequence of digits (0 to 9) will enventually coincide, because if they coincide once they coincide forever  (think about it). 

 Come back later, we're
 still working on this one...


(2008-01-25)   Kruskal Paths to  God.   (Martin Gardner, 1999)
In the  U.S. Declaration of Independence,  all paths lead to  God.

In the  May 1999 issue of  Games MagazineMartin Gardner published the following puzzle, among a small collection of  some magic tricks with numbers.  It involves the first sentences of the  US Declaration of Independence :

When in the Course of human Events, it becomes necessary for
one People to dissolve the Political Bands which have connected
them with another, and to assume, among the Powers of the Earth,
the separate and equal Station to which the Laws of Nature and of
Nature's God entitle them, a descent Respect to the Opinions of Mankind
requires that they should declare the causes which impel them to the Separation.

You are instructed to pick any word in the first (red) section of the text.  Then, skip as many words as there are letters in your chosen word.  For example, if you picked the fourth word ("Course") you have to skip 6 words ("of human Events, it becomes necessary") to end up on the word "for"...  Iterate the same process, by skipping as many words as there are letters in the successive words you land on.

What's the first word you encounter in the last (green) section?  Answer:  God.  Always.  (The sequence would continue with the words: descent, that, causes.)

The "magic" is based on the Kruskal principle discussed above...  You will ultimately land on  God  by starting with most words in the middlle (yellow) section.  The words that do work have been underlined for you.  You may check that this underlining is correct by working it out (backwards) for yourself, starting with the last yellow words  ("and", "of") which do land on  God  in one step.  As any word which leads to an underlined word gets underlined itself, almost all words in the yellow section end up being underlined.  This includes the first 17 words of that yellow section.  Since all words of the red section have less than 17 letters, that solid chunck of underlined words can't be jumped over and, therefore, all paths starting in the red section will ultimately lead to the word "God" in the green section.  (Actually, any word up to the word "Station" is a valid beginning of a sequence which ends up on the word "God".)

Kruskal Count  by  Doctor Douglas  (2007-04-01)

border
border
visits since March 27, 2004
 (c) Copyright 2000-2008, Gerard P. Michon, Ph.D.