Cut the knot: learn to enjoy mathematics
A math books store at a unique math study site. Learn to enjoy mathematics.
Google
Web CTK
Best sites for teachers
Sites for teachers
Sites for parents
Terms of use
Awards

Interactive Activities
CTK Exchange
CTK Insights - a blog

Games & Puzzles
What Is What
Arithmetic/Algebra
Geometry
Probability
Outline Mathematics
Make an Identity
Book Reviews
Eye Opener
Analog Gadgets
Inventor's Paradox
Did you know?...
Proofs
Math as Language
Things Impossible
Visual Illusions
My Logo
Math Poll
Cut The Knot!
MSET99 Talk
Other Math sites
Front Page
Movie shortcuts
Personal info
Reciprocal links
Privacy Policy

Guest book
News sites

Recommend this site

Best sites for teachers
Sites for teachers
Sites for parents

Education & Parenting

Manifesto: what CTK is about Search CTK Buying a book is a commitment to learning Table of content Things you can find on CTK Chronology of updates Email to Cut The Knot Recommend this page

Bachet's Magic Trick

Let N be an integer. This is the lone number at the bottom of the applet below. It can be modified by clicking on it. Currently it is 4. For practical reasons, it can change between 3 and 6, inclusive.

The integers from 1 through N·(N+1) are split into pairs. Select one pair and click the Proceed button. The same numbers will now be arranged in a N×(N+1) array. By just pointing to the two rows in which your selected numbers are located (if the numbers are in the same row, select it twice) you give your computer enough information to guess your numbers. Try it!


This applet requires Sun's Java VM 2 which your browser may perceive as a popup. Which it is not. If you want to see the applet work, visit Sun's website at http://www.java.com/en/download/index.jsp, download and install Java VM and enjoy the applet.


Buy this applet

Explanation

Copyright © 1996-2008 Alexander Bogomolny

 

 

 

 

 

 

 

 

 

 

Bachet's Magic Trick

The number of distinct pairs in which N objects may be combined is N·(N+1)/2. For example, if N = 4, there are 10 pairs: {1, 1}, {1, 2}, {1, 3}, {1, 4}, {2, 2}, {2, 3}, {2, 4}, {3, 3}, {3, 4}, and {4, 4}, with each object appearing 5 (in general, N + 1) times.

Two sets of such pairs could be arranged in an N×(N+1) array in a peculiar manner. For example, for N = 4, we have

{1, 1} {1, 1} {1, 2} {1, 3} {1, 4}
{2, 1} {2, 2} {2, 2} {2, 3} {2, 4}
{3, 1} {3, 2} {3, 3} {3, 3} {3, 4}
{4, 1} {4, 2} {4, 3} {4, 4} {4, 4}
or 
{1, 1}   {1, 1} {1, 2} {1, 3} {1, 4}
{2, 1} {2, 2}   {2, 2} {2, 3} {2, 4}
{3, 1} {3, 2} {3, 3}   {3, 3} {3, 4}
{4, 1} {4, 2} {4, 3} {4, 4}   {4, 4}

where in the left half of the table I reversed the order of numbers in a pair. It is now clear that for a pair on the left, the first number points to the row, while the second to the column, in which the pair is located. Additionally, the second number points to the row in which the companion pair (i.e., the one with the original order of numbers) could be found. (Incidentally, its column number is one more than the row number of the left pair.) This means that the location of the latter is uniquely determined by the row numbers of the two pairs as is the location of the original pair.

Let's now label the 20 pairs with 20 numbers. If the left pair {row, col} is associated with n and the right pair {col, row} with m, we can say that both, or the defining one {row, col} is associated with the pair (n, m). Naturally then, given the two rows in which the numbers n and m are located, it is very easy to determine both of them.

To see how the association works, check the "Straight list" and uncheck the "Randomize" button in the applet below.


This applet requires Sun's Java VM 2 which your browser may perceive as a popup. Which it is not. If you want to see the applet work, visit Sun's website at http://www.java.com/en/download/index.jsp, download and install Java VM and enjoy the applet.


Buy this applet

"Straight list" assigns the labels in a straightforward manner, such that the ordering of the pairs in the array becomes obvious. Otherwise, they are labeled in a random manner.

The "Randomize" button confounds the simplicity of the situation. Since all that is important is the rows of the two numbers, they may be located anywhere in the rows. When the randomize button is checked, the number are randomly permuted in every row just before being displayed in the array and, in addition, the numbers in a pair may occasionally swap rows.

[Rouse Ball, p. 326-328] refers the problem and the particular arrangement of pairs of objects to the classical Problèmes plaisans et délectables by a pioneer of recreational mathematics Claude Gaspar Bachet, sieur de Méziriac (the 1st edition published in 1612, the 2nd in 1624.)

References

  1. W. W. Rouse Ball, H. S. M. Coxeter, Mathematical Recreations and Essays, Dover, 1987

Copyright © 1996-2008 Alexander Bogomolny

28676804Page copy protected against web site content infringement by Copyscape


Search:
Keywords:


Latest on CTK Exchange
Math
Posted by Laura
2 messages
06:56 AM, Apr-15-08

Divisibility rules - Jargon buste ...
Posted by Carolyn
2 messages
08:35 AM, Apr-04-08

product of fractions
Posted by ke_45
3 messages
08:37 AM, May-06-08

Distance to the horizon
Posted by Monty
3 messages
04:38 PM, May-08-08

Mistake on the page (an aside, Be ...
Posted by Max
4 messages
10:28 AM, Feb-28-08

Nim Games - a query
Posted by Akash Kumar
1 messages
08:53 AM, Apr-15-08

A typo in
Posted by alexwajn
1 messages
11:36 PM, Apr-19-08