Part I · Chapter 2
One Machine for Every Rulebook
A machine that only adds one would need a new rulebook, and so a new machine, for every task. This chapter offers a way out: rules are just symbols, so they can be written on the tape. One machine can then read any rulebook and follow it. That machine is the universal machine, and it is why the device in your pocket can be anything.
Rules are just more symbols. Put them on the tape, and one machine can become any machine.
A machine for every job?
Chapter 1’s machine added one, and that was all it could do. To sort a list you would need a different rulebook. To check a dose against a child’s weight you would need another. If every rulebook meant a new machine, a hospital would need a warehouse of them: one for lab results, one for appointments, one for drug interactions.
This is not a silly worry. It is roughly how the first electronic computers worked. ENIAC, finished in 1945, was programmed by hand: to change what it computed, people rearranged cables and switches on its panels, much like an old telephone exchange. Changing the job meant physically rewiring the machine, and that could take days.
The rulebook goes on the tape
Turing saw the way out in 1936, before any electronic computer existed.
Look again at the rulebook in Chapter 1. It is a small table: if state is CARRY and the symbol is 1, write 0, move left, stay in CARRY. Every line of it can be written with ordinary symbols. So the rulebook can be written on the tape, just like the data.
Now imagine a special machine whose own fixed rules say:
- Look at the rulebook written on one part of the tape.
- Look at the current state and the symbol under the finger on another part of the tape.
- Find the matching line of the rulebook, and do what it says.
- Repeat.
This machine does nothing useful on its own. Hand it the adding-one rulebook and it adds one. Hand it a sorting rulebook and it sorts. Hand it a rulebook for checking doses and it checks doses. Turing proved that one such machine, with one fixed table of its own, can imitate every other Turing machine. He called it the universal machine.
Two words now separate:
- Hardware is the fixed machine that follows rules: the part that never changes.
- Software is the rulebook on the tape, which you can swap. Today we call it a program.
Figure 2.1. The universal machine: the rulebook sits on the tape beside the data, and fixed hardware reads and applies it.
In 1945 John von Neumann turned this into an engineering design. A single memory holds both instructions and data. A fixed circuit fetches the next instruction, carries it out, and fetches the next. Nearly every computer since has followed that plan. Your phone does not become a camera by being rewired. It loads a different program.
At this step, the machine is EDSAC, the 1949 Cambridge computer that kept its program in memory: it could run any rulebook, but nobody had written the nurse’s.