Turing Trains | Isometric | Wang Tiles | Maze Arrays | i Logo


Turing Trains


computational train track layouts


Mechanical Logic and Computation

A general review of mechanical calculation, its common drawbacks and the advantages of train track designs.

Today, we are surrounded by electronic digital devices. From the computer on your desk, your mobile phone and 'throw away' pocket calculator. They are an integral part of our modern day life.

Essentially, they all do a similar job. Each device 'reads in' input data, manipulates it in some logical manner, and outputs (displays) the result.

The input data is generated by the user (that's you!!) pressing buttons or keys on a keyboard. Complex devices may use screen swipes, motion detection or voice recognition. After logical processing, the resulting output is displayed on an LCD screen for viewing.

Modern devices use electricity. Or more precisely, they control the flow of electrons through electronic circuits. Electrons flow easily in conducting materials and cannot flow through insulators. They are very small so circuits can be tiny. Indeed the history of modern day computers is one of continuous miniaturization. From the valve, to the transistor to the micro chip.

Before the advent of electrical devices however, calculating machines were mechanical. They were used for repeated, reliable calculation of mathematical tables, financial transactions and yearly high tide times.

Continuous Analogue Movement

A common method of mechanical calculation is to use a rotating gear wheels, which can be easily set or read by an operator. However, they cannot easily perform logic or be programmed in any way. They create a dedicated machine for numerical calculations.

Mechanical calculating machines suffer from 2 main drawbacks:

  1. Power (torque). Each component needs power to operate. This can be large, as one component can drive many others. It can also be very variable, when many gears wheels rollover for example. This generates high torques, requiring strong construction of all moving parts.
  2. Play. There is always some mechanical 'looseness' between stages, which means not all wheels are synchronised ('in synch'). The operator sometimes has to overturn to read 'later' output wheels.

This limits their expansion and complexity. A machine capable of computation would have to be very precisely engineered.

Electronic computers have a similar problem. But they have a solution.

  1. The amplifier. This boosts the signal preventing it from dying away. Mechanical systems can use servo motors to maintain power. An example is power assisted steering in your car. A gentle movement of the steering wheel translates to a more powerful movement of the wheels. But this is complex mechanics and would need to be repeated many times in a computer.
  2. The clock. All wheels are clocked so they are always in synch with each other. Not easy to achieve mechanically.

A better solution is to employ discreet logic elements. By using individual mechanical modules we can build up a complex machine that can add and hopefully do many more things besides. The way forward is...

Binary Discreet Movement

Digital devices represent data in binary form, as either 1 or 0. This is a fundamental concept and is the simplest way of representing numbers. Electronic circuits use two different voltages to represent high (1) and low (0).

A useful binary element is the flip-flop. This component allows binary counting to take place. Once we can count then maybe we can add. The electronic version is called a 'D type flip-flop'. To create a binary counter, they are linked in series. Each flip-flop transfers every second pulse from right to left. The whole counter 'rolls over' from 7 (binary 111) back to 0.

Marble (or ball-bearing) Computers

These are powered by gravity. They use a 'see-saw' type lever to create a flip-flop directly.

They appear promising. However they are difficult to expand into more complex machines because for gravity to work, the vertical height between components must be correct. This makes it difficult to move things around, or use components more than once.

Another problem is representing spaces. Just leaving a gap between marbles doesn't always work, as numbers can have a long string of zeros, and you don't know exactly how many zeros in a long gap. So two different types of marble are needed, black and white or light and heavy to represent 0 and 1, which complicates things.

Domino Computers

Individual gates can be built. More complex calculations are diificult to design, as the domino computer cannot store and read back data bits. This is because dominos can only fall once. They need to be reset for each travelling signal.

In both marble and domino computers, the power is supplied by gravity and is evenly distributed throughout the system. This removes sudden torque requirements, but means the computers are not easy to reset.

A possible solution is to construct individual logic gates.

Logic Gates

Logic gates are the basic components of a computer. There are several types of gate: And, Or and Not. All other gates can be built from these 3 basic types. Even the D type flip-flop above can be constructed from individual logic gates.

Shoebox Computer

Each gate is constructed as a separate module in a shoebox. Boxes can contain pivoted levers, pulleys, string and springs or weights to simulate each type of gate. Mechanical inputs and output links between boxes can be:

  1. Movement: push / pull
  2. Twist: right / left
  3. Continuous rotation: clockwise / counter clockwise

Linking the boxes together produces complex logical functions. A common circuit is a 'one bit full adder' which inputs two single-digit binary numbers and outputs their sum, along with any carry into the next column.

However, quite quickly, the usual problems with mechanical systems arise. They are the same as before:

  1. Power (torque). The more elements we use the more power we need. Things can get quite difficult to rotate, push or pull. Eventually everything comes to a halt. So some boxes will need to contain amplifiers. This is like power assisted steering in your car. A low power input can be converted to a high power output. This is why an important component of modern day computers is the transistor. It boosts the signal and prevents it simply dying away.
  2. Play. The mechanical 'looseness' between stages, means not all inputs and outputs are synchronised ('in synch'). This is a big problem if some output signals are fed back as inputs to 'earlier' stages. A solution is to use a clock pulse.


A clock signal is fed into each shoe box. Inputs and outputs can only be read or changed on alternate high / low clock pulses or rising / falling pulse edges. This complicates the design.

Train Track Computer

This seems to avoid Power and Play problems. The power is provided by the train engine. It is delivered to each lazy point as required to switch the point (and any linked points). All other points remain at rest and consume no power. The train can use solar cells, or run on electrified rails for long calculations.

Train track computers are asynchronous. Only one point can be switched at any one time. So all points are 'in synch'. The drawback of this system is that signals cannot be split. The train is only in one place at any one time and points need to be visited in order. However, by using sublayouts, the train can visit and return from different sections of layout.

This illustrates the unique design of train track computers. They cannot be built from many logic gates as modern computers are built from many NAND gates. And tracks are naturally two-way.

Their main advantage is that layouts are very flat. It is easy to view their operation, and to extend registers by adding on further stages. Indeed, by using calls to subroutines, the whole computer can be extended indefinitely.



zoom in to enlarge layouts