Physical Counter Computing....Or How I Lost My Marbles.

I became interested with the idea of using marbles or ball bearings in an automatic abacus back in '99 when I was considering alternate history Babbage Engines.

While all mechnical calculators that I've been able to find have used gearteeth to count digits, it seemed quite plausible that a calculator could be built using weights. Something along the lines of the a ball clock. I thought about it long enough to decide it was plausible, used it in a story, and did not take the idea up again until recently. While reading Stephen Wolfram's A New Kind of Science  last year, I came across the assertation that a fully functional computer processor could be built using only two instructions:  

increment register

decrement register , jump if zero 

Hmmm. said I. So I spent a week walking around muttering "...inc a, inc a, dec b jmp 4 , inc a..."

There's nothing like assembly to calm the mind. Its better than mantras and morphine together, and almost as good as sex. I figured that if I could make it multiply and divide, than it could do anything else. That may be an erroneous statement, but it continues to seem reasonable as a quick test of universality. 

So far, I've managed division, long division and multiplication. Looking at the opcodes tends to make me dizzy, so I'm writing a quick simulator in Forth to test the "programs".

One of the interesting things about the Counter Machine is that I am not working in binary. I know that decimal computation went out with the vacuum tube (Alright, it went out some time before the tube *grin*), but it has certain advantages. 

For example:

Each 'digit' in a Counter Machine is handled in parallel fashion. With twelve digits per register, one can count to a maximum value of 4,095. This takes a maximum of 12 counters. With decimal, there is 9 counters per digit, and a maximum value of 999,999,999,999, and this takes a maximum of 108 counters. The easiest way to implement numbers such as 4.7 would be to have one register for each side of the decimal point. This would give a maximum of 12 places of precision, which is enough for many - if not most - computations. 

(For example, the difference in the Earth's Circumference at 12 places of pi, and 13 places:

3.141592653589       40037.477794950632425 km                     

3.1415926535897     40037.4777949595534525 km

Difference = 0.0000000089210275 km. That is 8.921 microns. This is assuming  12744.325  km as a reasonable generalization of the Earth's Diameter.

 

 

'...Cervanno turned to the silent machine. "For example, we can arrange a problem like this." he said, his hands moving between a number of setting toggles. "There is already a recipe in the reader. We enter the data like so --" Here he took the tally and drove the long lathe into a slot. There was a complicated clicking sound, and then a rattle of counters.

"It takes a finite amount of time to and a tally stick. Perhaps ten beats a stick. Now that its read, we begin the orders." He moved a handwheel, and counters rolled and hummed through the machine, cascading out into a basket with a rattling roar. Tyrannis watched other counters fill the output tubes.

"About another ten seconds for the orders." Cervanno said, "but some orders can get quite complex, and calculation can exceed an hour."

Tyrannis ran his finger along the output lines. "And you can crack a code this quickly?"

Cervannos shook his head. "Its a cipher we already know. If it were not ..." '

 

 

1