A custard computer

by Paul Curzon, Queen Mary University of London

This simplistic custard contraption is inspired by a more sophisticated custard computer invented by Adrian Johnstone, Royal Holloway, University of London.

Custard dripping downwards
Image by Bruno / Germany from Pixabay

Imagine a room-sized vat of custard suspended from the ceiling. Below are pipes, valves and reservoirs of custard. At the bottom is a vast lake where the custard collects as it splurges out of the pipes. A pump sucks custard back up to the vat on the ceiling once more. Custard flows, sits, splurges…all the while doing computation.

Babbage worked out how to make a computer using wheels. How might you make a general purpose digital computer out of custard? (It sounds more fun!) Adrian Johnstone at Royal Holloway has designed one and if built it would look something like our above description, like something from Willie Wonka’s chocolate factory.

Here we give a slightly simplistic version. The first step is to have something to represent 0 and 1. That’s easy with custard: no custard in a storage tank is a 0 and custard is a 1. Out of that you can represent numbers using collections of such tanks: lots of tanks containing custard or no custard, with a code (binary) giving them meaning as numbers.

Once you have a way to represent numbers, the next step to making a computer is to make the equivalent of transistors. Transistors are just switches, but ones that revolutionised electronics to the point that they have been hailed as one of the greatest inventions ever. Starting with humble transistors, computers (and lots more) can be built.

Transistors have three inputs. One acts as the data input, or source, connected ultimately to the source of the current (in our case the vat of custard). Another, the drain, connects ultimately to the place the current drains to (in our case the lake of custard). A third input is the gate. It switches the transistor on and off, either allowing current (custard) to flow towards the drain or not. The gate thus acts as the switch to allow custard to flow.

One way to make a custard transistor would be to use a contraption based on your toilet but full of custard (don’t think about that too much). Look in your toilet cistern and see how it switches water on and off when you flush the toilet to get the idea. For a (custard) transistor, have a small tank of custard with a ball floating on the surface. It acts as the gate. Fastened to the end of the ball is a lever The lever’s other end can push up against the end of the pipe that runs from source to drain, blocking the flow. When the tank is full of custard it pushes the other end of the lever down, letting custard flow. If the tank empties then the ball drops, so the other end of the lever rises and blocks the flow.

Transistors have been hailed as one of the greatest inventions ever.

There are two kinds of transistors. They differ in that the gate just operates in opposite fashions. With one kind, custard can flow from source to drain only when there is current (custard) at the gate (as above). In the other, custard flows only when there is no custard at the gate.

Transistor circuit symbol

Once you have (custard) transistors, you can make (custard) logic gates (NOT, AND, OR,…). A (custard) NOT, for example, would need to let custard into its out pipe only if there were no custard on its input pipe (and vice versa). We can do this using a transistor with the NOT circuit’s input connected to the gate, and where custard flows only when the gate has no custard. The drain of the transistor becomes the output of the NOT circuit. The source of the transistor connects to the vat of custard to provide the custard that will flow when the transistor switches on. When custard arrives at the gate which is acting as a switch, it stops custard flowing to the drain, and vice versa, as required.

AND logic needs to let custard out only when there is custard at both its input pipes. OR logic allows custard through when there is custard at either of its input pipes. This can be done with appropriate plumbing together of the transistors as follows.

Diagram of a custard transistor
A custard transistor: when there is
custard at the gate, custard flows
from source to drain. When no
custard is at the gate, the floating ball
drops and closes the link.

A (custard) AND uses two transistors It allows custard to flow when there is custard at both gates which are the input pipes of the AND circuit. Connect one input of the AND circuit to the gate of the first transistor with the source connected to the vat of custard. Connect its output to the source of the second transistor. The gate of this second transistor is linked to the second input of the AND. Custard will flow from the vat down towards the drain only when there is custard at both gates. If either gate has no custard, then the custard will not flow, just as required for custard AND logic. We will leave you to work out how to make (custard) OR logic.

Once you can create gadgets that do (custard) NOT, AND and OR, you can then start to build more interesting circuits by combining them: building up the components of a computer like (custard) adders and (custard) multipliers, circuits that compare numbers and ones that trigger custard to be moved about… put it together in the right way and you can build a computer with control unit, arithmetic logic unit, memory unit and so on… (as long as you have enough custard).

Out of the glooping vat of custard, computation emerges….Would it really work? You would have to build it to find out!


More on …

Related Magazines …


This article was funded by UKRI, through Professor Ursula Martin’s grant EP/K040251/2 and grant EP/W033615/1.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s