Intro to Rod Logic

So let's talk about rod logic. You can read all about Eric Drexler's nanomechanical version in chapter 11 of his 1991 doctoral thesis, Molecular Machinery and Manufacturing with Applications to Computation [PDF]. What I'll show here is my own interpretation of his ideas, stripped of their nanomechanical aspect. Here is a schematic of an identity gate.

Identity gate
Identity gate profile

On the left we see two rods, a green input rod and a blue output rod, with each rod having a nub attached. In the profile on the right, we see that the nubs attached to the rods can slide into each other. Each rod is in one of two states, 0 or 1, not pushed in or pushed in.

If we keep the green input rod at the 0 position and attempt to push the blue output rod, the nubs prevent the output from moving, and so the output is 0. If we move the input rod to the 1 position, then the output rod will move to the 1 position when pushed. That's the identity gate.

By changing the position of the nub on the input rod, we can create a NOT gate:

NOT gate

This time, pushing the input rod will prevent the output rod from being pushed, so the output is the inverse of the input.

Note that with these gates, after the output is registered, all the rods need to be reset back to the zero position, and they generally have to be reset in the reverse order that they were pushed in. This is a characteristic of reversible logic.

By adding a second input rod and another nub on the output rod, we can create an AND gate:

AND gate

Here, only if the two input rods are pushed to 1 will the output rod be able to be pushed. Note that the interaction of each individual input rod with the output rod is an identity function (A=X, A=Y), and because of the two nubs on the output rod, the functions represented by the input rods are logical-anded together (A=XY). And, as with the NOT gate, if we move the nubs on the input rods, we can create an AND of two inverse functions (A=not(X) not(Y)), more commonly known as the NOR gate (A=not(X+Y)):

NOR gate

By adding any number of input rods and setting their nubs at appropriate positions, we can create any AND function. Here's one representing the function A=not(X) not(Y) Z:

001 gate

Functions of AND are the only functions that can be built with a single output rod, or indeed a single output layer. We could imagine a way of pushing an output rod if either input rod is pushed, which is the OR function:

OR gate (first idea)

I don't like this geometry. If I push one of the rods, then the corresponding output rod is the one which will move the T-shaped block at the end. If I have a 16-input OR gate, then sometimes I might push only the first rod, and not the other fifteen. This means firstly that one rod would have to push a very large T-shape, and secondly that the friction of the T-shape against its guide walls which prevent it from rotating instead of moving forwards would be very high — torque is force times length, and the width of the T is the length in that equation resulting in high friction.

My alternative requires two levels of rods, and thus an additional delay, but there is no friction problem:

OR gate

The green input rods together with the blue intermediate rod together form the familiar NOR gate. The red output rod is then pushed to form the inverse of the NOR result, which is the OR function: A = not(not(X) not(Y)) = not(not(X+Y)) = X+Y.

In this same way, we can form a NAND gate, which is simply the NOT of the AND gate:

NAND gate

And finally, to complete the set, let's have a look at the implementation of an XOR gate:

XOR gate

We can see that the red output rod and the blue intermediate rods form the familiar NOR gate, and the top blue rod forms another NOR gate, with the bottom blue rod forming an AND gate. A little mental manipulation shows that the output rod can only be pushed to the 1 position if and only if one and only one of the green rods is pushed to the 1 position. A 00 input allows the top blue rod to move, which inhibits the output rod from moving, while a 11 input allows the bottom blue rod to move, which also inhibits the output rod from moving.

These are all the basic rod logic gates we should need.