Turing Machine

This program demonstrates a Turing machine, an abstract model of a computer created by mathematician Alan Turing in the 1930's, before real computers existed. This Turing machine is programmed to compare numbers of colored blocks in the second row of the display.

When you click the "run" button the Turing machine will go to work, scanning the colored blocks. The block moving along the top row of yellow blocks is called the "read/write" head, and as it moves it can detect the colored blocks below, and change them. It will compare the number of red blocks to the left and to the right of the blue block by erasing a block on the left, and then trying to erase a block on the right. If there are no more blocks on the right, it can tell that there must have been more blocks on the left. It signals this by turning red when it stops. If it is dark blue when it stops, this means there were more blocks on the right. If the numbers were equal, it is light blue when it stops.

You can press the "reset" button to reset the colored blocks. To make a new arrangement, click on the blocks in the lower row. If you click on a red block it will turn blue; a light blue block will turn red, and a blue block will turn light blue. This Turing machine can only process rows of blocks on the left end of the row, with no gaps. See if it can correctly compare two groups of 4 blocks by setting up 4 red blocks, a blue block, and another 4 red.

Reference: Minsky, M. (1967) Computation: Finite and Infinite Machines. Englewood Cliffs, NJ: Prentice-Hall, Ch. 6.