Thursday, December 28, 2006

Mathematics Of Sudoku

•9 rows, 9 columns, 9 3x3 boxes and 81 cells
•I will refer to rows, columns or boxes as areas
•(p,q) refers to row p and column q
•I number the boxes left to right, top to bottom


How many givens do we need to guarantee a unique solution?

•This is an unknown mathematical problem
•There are examples of uniquely solvable grids with 17 givens


How many givens can we have without guaranteeing a unique solution?

•It is possible to have a puzzle with only four cells blank that is still not uniquely determined



The Number of Sudoku grids

The number of ways of filling in a blank Sudoku grid was shown in May 2005 by Felgenhauer and Jarvis to be 6,670,903,752,021,072,936,960

Saturday, December 23, 2006

History Of Sudoku

The history of Sudoku can be traced back to an 18th century Swiss mathematician by the name of Euler. In 1783, he devised a square 9x9 grid in which all the digits from 1 to 9 appear in every row and column. In other words, in every row and column the digits are never repeated. This is known as a Latin Square. The Latin Square can be described as the forerunner of Sudoku.

Almost 200 years later, a retired American architect named Howard Garns used the concept of the Latin Square and created a puzzle which at that time was given the term Number Place. In 1979, his Number Place puzzles were featured in an American puzzle magazine.
What Howard Garns did was to add another condition to the Latin Square. Not only are the digits from 1 to 9 not repeated in every row and column, they are also not repeated in each of the 9 blocks of 9 cells. But unfortunately Garn's puzzles were only known to the readers of the magazine, and for many years they went unnoticed by the general public.

But everything changed in 1984, when a Japanese puzzle magazine became aware of Number Place, and they took the puzzle to Japan for their readers to enjoy. At first, they gave the puzzle the long name mentioned above. Two years later, Sudoku became a hit in Japan after the Japanese magazine reduced the number of clues, and also arranged the clues symmetrically. These innovations made the puzzle even more challenging and appealing. But although Sudoku became very popular among the people in Japan, for many years it remained relatively unknown outside of that country.

Once again, Sudoku made another journey, this time from Japan to England. That was in 2004. What happened was that a New Zealander by the name of Wayne Gould came across Sudoku puzzles while he was on a trip to Japan. He liked them so much that he spent some time to develop a computer program that could generate Sudoku puzzles automatically. Then armed with an endless supply of Sudoku puzzles from his program, he persuaded The Times of London to carry the puzzles. In November 2004 Sudoku first appeared in an English newspaper, and from then on and within a few months its popularity spread very quickly.

In April last year, Sudoku became a regular feature in a newspaper in New York. This completes Sudoku's westward travel around the world, from 1979 to 2005, starting from America to Japan, and then from Japan to England and back to America. By the end of last year, Sudoku had become a popular pastime all over the world, including Malaysia. Although it took a total of 26 years, Sudoku is a wonderful example of how a good idea will spread in today's world that is so well-connected. But the unfortunate fact behind this story of the global rise of a puzzle is that the creator, Howard Garns, did not live long enough to see his puzzle became a worldwide success. He died in 1989.

Construction of Sudoku Puzzles

Building a Sudoku puzzle can be performed by pre-determining the locations of the givens and assigning them values only as needed to make deductive progress. This technique gives the constructor greater control over the flow of puzzle solving, leading the solver along the same path the compiler used in building the puzzle. Great caution is required, however, as failing to recognize where a number can be logically deduced at any point in construction—regardless of how tortuous that logic may be—can result in an unsolvable puzzle when defining a future given contradicts what has already been built. Building a Sudoku with symmetrical givens is a simple matter of placing the undefined givens in a symmetrical pattern to begin with.