An Exercise for the Mind: A 10 by 10 Math Puzzle: A Pattern Recognition Game: Meditation on an Open Maze

A few weeks ago I was introduced to a simple and intriguing game. It is probably best categorised as a mathematical puzzle, yet it requires no calculations at all, just placement of numbers based on two rules. Hence, I prefer to refer to this puzzle as a pattern recognition game, an exercise for the mind using an open maze – a meditation of sorts.

The Purpose of the Game

    To take a 10 by 10 grid, representing 100 squares, and completely fill every square based on two types of movements.

The Rules are Simple

    1) Create a 10 by 10 grid (graph paper or a spread sheet will come in very handy).

    2) Fill one of the squares with the number 1, then, based on the following two movement types, use consecutive numbers to fill in the rest of the grid:

      Movement Type I) If the next number in the sequence is going to be placed vertically or horizontally, then it must be placed exactly three squares away from the previous number (there must be a two square gap between the numbers).

      Movement Type II) If the next number in the sequence is going to be placed diagonally, then it must be placed exactly two squares away from the previous number (there must be a one square gap between the numbers).

    3) Numbers must be placed using the above two movement types. Numbers can only be placed in empty squares - once a square has been used it can not be used again. All placements must occur within the grid.
    4) Game is complete when the number 100 is reached - when all empty squares in the grid are filled. If you can not continue placing numbers based on the two movement types above, and empty squares remain in the grid, then the puzzle is not complete and the game lost.

Two Incomplete Examples and a Solution

    Example 1) The first example is one where I tried to get the worst possible result. I was able to end the game in 30 moves – reaching the number 30.

    Example 2) The second example is my best result so far. In this example I was able to reach 99 – one move short of finishing the game.

    A Solution: The final example is a solution completed by someone who has been playing this game for approximately three years. This is the only solution that he has ever been able to obtain for this game during this period - so we know that there is at least one solution. It would be interesting to find out how many solutions actually do exist – any hardcore mathematicians or programmers out there interested in tackling this problem?

Variations

    Other than creating a scoring system or using symbols instead of numbers to fill in the squares, two of the best variants would be: 1) to give a starting point and an end point for the game – this should increase the difficulty of the puzzle; 2) creating different types of grids, but maintaining the same placement rules – an example is presented below (click image to enlarge).

For anyone who wants to try this out, below you will find a sheet with 12 grids (click to enlarge). Ideally, a simple program based on the parameters above loaded on a device with a touchscreen would be the best way to enjoy this game.

If you are into such things, I hope the game entertains you, and if you find anymore solutions, then please send them my way. Thank you in advance.





Posted in Submitted by chycho on Fri, 2009-05-15 15:13.
chycho's blog | login or register to post comments

i just checked out some of the info on your company D-Wave Systems ... what a great project. This is what will most likely kick in the next stage in our evolution, both as a society and personally.

Once Moore's law tapers off, quantum computing should kick start things again... i hope so anyway.

For sure, if you can, please email me what you couldn't post in the comment and i'll see what i can do to put together a piece to share the info (if that's okay that is). I'm not a programmer but i know there are regular chycho readers that would appreciate it.

please include any info about your company and the project that you would like shared. I'll do my best to put the info together coherently (as best as i can understand it anyway).

you can email me at chycho@chycho.com

and thanks again for taking the time to share the knowledge :)

chycho | Wed, 2009-05-20 17:49

Apparently, my last comment was too long and was truncated. I'm also having trouble getting the entire problem description of the puzzle to show up in the comment. Anyway, if you're interested in the problem description, I can email it to you in its entirety.

Given the problem description, our software can find one solution to the puzzle. It's possible to find multiple solutions, but more work is needed. You'd find one solution first and store it in your database. Then you'd extend the problem description to force the next solution to be different from the current one. It should be easy to automate the process of finding multiple solutions to the puzzle. I could give a try.

Thanks ahead for mentioning us and our software in your blog post.

kaifan0112 | Wed, 2009-05-20 17:07

Hi. Thanks for your interest in our company and software.

The name of our company is D-Wave Systems (http://www.dwavesys.com/). We're primarily a quantum hardware company, but we develop software too. One of our goals is to produce hardware and software capable of solving difficult combinatorial search and optimization problems in ways that cannot be done today.

At this point, we don't have a nice name for the software package I used to solve your puzzle. I can tell you more about it though. It's based on the idea of specifying a problem in a declarative programming language and finding a solution to the problem. Because the language is declarative, the user won't need to know anything on how the problem is solved.

The declarative programming language we use is an extension to the database language SQL. We've chosen SQL for two reasons. The first reason is the popularity of SQL, and the second is the fact that the data for most practical problems resides in a database. SQL is not for specifying combinatorial search and optimization problems, but with a conservative extension to the language, we've made it capable of specifying those problems.

As an example, here is a problem description of the puzzle in our extended SQL language:

FIND Grid (
i1.intvalue AS num COMPLETE,
i2.intvalue AS grow,
i3.intvalue AS gcol,
UNIQUE (grow,gcol))
FROM INTRANGE(1,100) i1,
INTRANGE(1,10) i2,
INTRANGE(1,10) i3
WHERE
FORALL (SELECT * FROM Grid
WHERE num

kaifan0112 | Wed, 2009-05-20 16:58

cool, that works :)

what's the name of your company/program? I would like to do a follow-up post to this puzzle and i think it would be good to point people to you since you guys have a program to solve these types of problems.

as well, does your program reveal how many solutions a problem has? If it does, can you tell us how many solutions this puzzle will have?

and thanks for taking the time to post the solutions and the information.

it's much appreciated :)

chycho | Wed, 2009-05-20 00:12

Hi,

Here is the solution I got:

16,61,98,15,93,9,44,92,8,43
96,39,82,79,40,83,80,41,86,21
99,14,94,62,11,91,88,10,45,89
17,60,97,84,81,32,85,20,7,42
95,38,100,78,37,24,77,90,87,22
64,13,18,63,12,19,71,31,46,70
50,59,36,25,67,33,28,23,6,29
56,53,65,57,54,73,76,3,72,75
35,26,49,34,27,48,68,30,47,69
51,58,55,52,66,4,1,74,5,2

As for our software, it's something we've developed for solving combinatorial search and optimization problems in a generic way. The math puzzle you described is just one example of such problems. There are tons of other examples, such as graph colouring, hamiltonian cycle, and knapsack. Practical examples include scheduling, resource allocation, vehicle routing, financial portfolio selection, and many others. To solve those problems in a generic way, we let the users of our software specify their problems (such as your puzzle) in an easy-to-learn high-level programming language. They don't need to know anything on how their problems are solved. They just need to be able to describe them in the programming language. Our software will take the problem description and solve the problem.

kaifan0112 | Tue, 2009-05-19 17:54

it would be cool to see the solution ... and the software.

chycho | Tue, 2009-05-19 05:39

Hi. The puzzle you described is very interesting. I'm a software developer working on software that can actually be used to solve your puzzle. Using our software, I managed to solve the puzzle in a little over 2 minutes (I got a solution that is different from the one you posted, so definitely more than one solution exists).

Cheers,
C

kaifan0112 | Tue, 2009-05-19 05:11

Solutions

Politics for 2009

Economics for 2009

Health and Environment

Politics General

Search

 

Chycho TV

The Art of ...

Canada

United States

Politics Pre-2009