How Complex Math and Human Innovation Created the Calculator
Keith Houston on the People, Technology, and Equations Behind a Modern Mathematical Convenience
It would not fit. Late in 1957, as Tadao and Toshio Kashio waited to load their desk-sized calculator onto a plane at Tokyo’s Haneda Airport, they were told they would have to dismantle it first. If you can just remove this top part here, an attendant told them, gesturing to the keyboard and display, it will fit on the airplane. If we do that, the Kashios pleaded, it may break. And so it did. When they arrived at Taiyo Sales in Sapporo to demonstrate their reassembled machine, it refused to work, and the brothers had to fall back on a slideshow. The future of their calculator, and that of the Kashio family business, seemed to hang in the balance.
The Kashio brothers—Tadao, Toshio, Kazuo, and Yukio—were quite different from the inventors and engineers who had gone before them. They did not have Blaise Pascal’s mathematical prowess, or Samuel Morland’s royal connections. They did not have Charles Xavier Thomas’s considerable income, or Curt Herzstark’s family tradition of engineering. What they did have was a finger-mounted cigarette holder that let Japan’s workers get their nicotine fix both on and off the job.
The Kashios hailed from a village on Japan’s southern island of Shikoku, where their parents farmed rice paddies. In 1923, however, in the aftermath of an earthquake that flattened Tokyo and Yokohama and left an estimated 140,000 dead, Shigeru Kashio moved his young family to the country’s capital to help rebuild it. To save money on the commute to his construction job, Shigeru walked for up to five hours each day rather than take public transport.Manufacturing would build an electric calculator, economy be damned, and that it would do so in a completely new way.
Tadao, Shigeru’s eldest son, grew up to become a metalworker and machinist. Although he was too sickly to join the military when the Second World War intruded, Tadao joined the war effort by making airplane parts on a lathe in the family’s garden shed. That enterprise came to a crashing halt when the Kashio house was destroyed by American bombers. Japan’s surrender, after the destruction of Hiroshima and Nagasaki, seemingly dampened any hopes of a revival. And yet, shortly after the war, Tadao was offered a milling machine located some three hundred kilometers from Tokyo, and he grabbed the chance to resuscitate the family firm. His father hitched a handcart to his bicycle and spent several weeks dragging the machine back home. Kashio Manufacturing was born.
At first, Kashio’s product line was decidedly eclectic: now joined by his younger brother Toshio, Tadao made gears, parts for microscopes, and hot plates for cooking. Toshio, on the other hand, who idolized Thomas Edison and who had learned his way around electrical circuitry at Japan’s Ministry of Communication, had bigger ideas. Even so, Toshio’s first hit product was far removed from electrical wizardry: the so-called yubiwa, or “ring pipe” was nothing more than a chromed finger ring with a cigarette holder soldered to it. And yet it was a runaway success. Japan’s workers could smoke their unfiltered cigarettes all the way to the end while working, then enjoy a relaxing puff afterward in the sentō, or bathhouse, without getting their tobacco wet.
The profits from the yubiwa pipe gave the Kashios room to breathe, and Toshio room to think. Back in 1946, he had read a newspaper article that chronicled the battle of wits between Kiyoshi Matsuzaki on his abacus and Tom Wood of the U.S. Army on his electric calculator. The West had been captivated by Matsuzaki’s victory, but Toshio was more intrigued by the losing machine. His interest was piqued again three years later at a business expo in Ginza, Tokyo, where Tadao and Toshio saw a clutch of similar machines in person. All had been imported, since impoverished postwar Japan lacked the industrial base to manufacture motor-driven calculators. (That would not change for another decade.) Toshio decided then that Kashio Manufacturing would build an electric calculator, economy be damned, and that it would do so in a completely new way.
Four years and ten prototypes later, Toshio and Tadao finished their calculator. Figuratively speaking, it was revolutionary; in literal terms, it was the opposite, since this was the first automatic calculator anywhere in the world that was not driven by rotating gears or motors but rather a kind of electromagnet called a solenoid. Familiar to Toshio from his days at the Ministry of Communication, a solenoid is a cylindrical coil of wire that, when energized by an electrical current, propels a metal “plunger” along its length. The plunger, in turn, can be used to trigger an external system: to open a valve controlling the flow of a fluid, for example, or to lock a door, or to start a car. Or indeed, in Toshio’s case, to trip another electrical switch. The Kashios’ calculator was a symphony of solenoids and switches, wired together in series and in parallel to create circuits of ever-increasing complexity. There was not a gear or a motor to be seen.
In 1955, the Kashio brothers demonstrated their calculator at Bunshodo Corporation, a Tokyo office supply company. It worked perfectly, and quietly, too, lacking the obtrusive racket generated by most electric calculators. But their potential customer had a question: why, having completed a multiplication, could one not simply multiply the result a second time, and a third, and so on? This had been a feature of mechanical calculators since Pascal’s time and yet the Kashios’ machine had to be reset after each arithmetical operation. Reworking the calculator to satisfy Bunshodo’s request cost the Kashios another year of development—and then, with the machine almost ready to go, Toshio declared that he wanted to throw it out and start over. Solenoids and switches, he declared, were too fiddly for mass production. Relays were the future.
In tearing down his solenoid calculator, Toshio Kashio was unwittingly joining a much larger movement in the design and development of computers. The roots of that movement, in turn, lay all the way back in the age of the telegraph—the first communication system that relied not on line of sight or a horse and rider to convey information but rather on the new wonder of electricity.
First, a point of etymology. The word “telegraph” means to write at a distance, and, although the term is synonymous with the dits and dahs of the electrical telegraph, humanity had been telegraphing since long before that device was ever conceived. Humans have been using smoke signals since prehistoric times, for example, and flags, it turns out, are even better. The use of flags to exchange messages between ships is well known, but land-based flag networks were also found in the Americas, Europe, Africa, and Asia. At one point during the early nineteenth century, France, the erstwhile leader in such things, hosted more than five hundred “optical telegraph” stations within its borders.
Then came electricity. The first suggestion that a wire could carry not just a current but a message was published in the pages of Scot Magazine as early as 1753, but the lack of reliable power sources stymied that and many later proposals. It was only in the early years of the nineteenth century, when one Samuel Morse combined a simple electrical circuit with an ingenious coding scheme, that the electrical telegraph came of age. With a switch at one end of the line and an electromagnet at the other, Morse’s telegraph turned a series of on-off pulses into a dot-dashed line drawn by a pencil, which could then be decrypted by a reader familiar with Morse’s eponymous code. Later, the pencil and paper tape would be replaced by a “sounder” that emitted a tapping noise.
The problem that Morse and others faced was that of range. All wires dissipate current to a greater or lesser degree, so that after a certain distance the receiving mechanism will stop working. Lightbulbs will flicker and dim; telegraph sounders will stop tapping. What was needed was a way to transform a weak incoming signal into a strong outgoing one so that a series of telegraph lines could be daisy-chained together over long distances. What was needed was the relay.
Both Edward Davy, an English inventor, and an American named Joseph Henry, later to be the Smithsonian’s first secretary, have convincing claims to the earliest working relays. Their respective devices were conceptually identical too. Like Morse’s telegraph, a switch at one end of a telegraph circuit controlled an electromagnet at the other. But rather than pushing a pencil onto a moving tape, or tapping out an audible rhythm, that electromagnet was in turn connected to another switch—a switch that operated a second telegraph circuit with its own dedicated power source. As the telegraphist tapped out a message on the first switch, the electromagnet opened and closed in sympathy, actuating the switch at the start of the second circuit, so that the dots and dashes of their message were transmitted onward, at full power, on the new circuit. Nor was there any reason to stop there. Additional circuits, or relays, could be added as often as necessary for a telegraph line to cross a county, a state, or a country. It was the final part of the telegraph puzzle.
But the relay had another use, too, one that neither Henry, Davy, nor Morse had anticipated. Consider this: sending any sufficiently strong input signal to a relay results in a closed-output circuit, while any sufficiently weak input signal results in an open circuit. If we label the closed case as “0” and the open case as “1,” it becomes apparent that the humble relay can bend messy, entropic reality to the service of pristine binary logic.
“Ma Bell,” the hulking American Telephone and Telegraph Company, was the product of Alexander Graham Bell’s quest to build an improved telegraph. The Scotsman, who, in the 1870s, had immigrated to Canada and then to the United States, had the idea that it might be possible to connect multiple telegraph senders and receivers over a single line. Instead of simply making and breaking the circuit, Bell proposed instead to send audible tones, converted into oscillating electric currents, along the wire. Each telegraph key would emit a particular musical note, and a receiver tuned to that same frequency would pick up only the dots and dashes sent by the associated key.
Bell’s “harmonic telegraph” has been largely lost to history, but the lessons he learned while working on it led him to patent the first practical telephone system. Now, Bell’s instrument was neither the first working telephone nor even, possibly, the first to be patented, but he was the first to build a viable enterprise from his invention. And it was in the bowels of AT&T, the resulting corporate behemoth, that the life of the relay would enter its second act.
In 1925, AT&T centralized its research staff under the banner of Bell Telephone Laboratories. It was there, twelve years later, that an engineer named George Stibitz rescued a pair of relays, still used widely in telephone exchanges, from the Bell Labs scrap heap and took them home to his kitchen. There, for reasons that even Stibitz, interviewed many times about his work, seemed to have forgotten, he wired the relays together with a pair of flashlight bulbs and some batteries to make a circuit that could add one and one to make two. His wife, Dorothea, later dubbed it the “Model K,” for “kitchen.”Shannon’s insight was that relays were the perfect building blocks to bring Boolean logic into the real world.
Soon after, Stibitz’s boss, Thornton Fry, asked him if the Model K could be made to work with complex numbers. Fry did not mean numbers bigger than two, the limit of the Model K’s circuitry, but rather a very specific and lushly exotic species of number made up of separate “real” and “imaginary” components. Written as x + iy, where x is the real component and y is the imaginary one, the complexity of the complex number lies in the fact that i is equal to the square root of negative one—which, in standard arithmetic, has no real value. Complex numbers do have applications in physics and engineering, but even simple operations such as multiplication are more time-consuming than for regular, “real” numbers. Fry needed between five and ten human computers to keep up with his engineers’ demands for complex-number arithmetic.
Stibitz obliged, building a relay-based calculator that could add, subtract, multiply, and divide complex numbers. Completed late in 1939, the machine contained more than four hundred relays and took around a minute to multiply a pair of complex numbers—which was slow, but still many times faster than a human. And as Stibitz and Fry demonstrated in September 1940 at the American Mathematical Society in New York, the “Complex Number Calculator” could also be hooked up to a telephone line and driven using a kind of electric typewriter called a teletype. It was the first ever public demonstration of remote computing.
In designing the Complex Number Calculator, Stibitz may have been inspired by the work of Claude Shannon, a math student at the time, who would later marry a Bell Labs computer named Mary Elizabeth Moore. Shannon’s master’s thesis, published in 1938, described how relays could be used to solve any problem described in terms of Boolean algebra. In that statement lies a rabbit hole of considerable depth: Boolean algebra was the invention of a nineteenth-century English mathematician named George Boole, and it provided a formal way to write down and manipulate if-then statements such as “if x and y are true, then z is true” or “if a or b is true, then c is false.” It is, essentially, a kind of math dedicated to only two values—0, meaning false, and 1, meaning true—but, as Gottfried Leibniz had realized two centuries earlier, those two values can be combined to represent any other kind of number one might need. Here, for example, are binary counterparts of the decimal numbers from 0 to 8:
By combining Leibniz’s binary numbers and Boole’s binary algebra, it becomes possible to construct expressions that will add, subtract, multiply, or divide any kind of number at all: whole numbers; fractions; complex numbers. And if we consider that we can map numbers onto letters—imagine that 0 corresponds to “A,” 1 corresponds to “B,” 2 corresponds to “C,” and so on—then we can break out from the mathematical realm and start to manipulate letters, words, and language. Shannon’s insight was that relays were the perfect building blocks to bring Boolean logic into the real world. His thesis, which has been called “possibly the most important, and also the most famous, master’s thesis of the century,” was nothing less than a road map for building computers. Or, indeed, for building calculators.
Excerpted from Empire of the Sum: The Rise and Reign of the Pocket Calculator by Keith Houston. Copyright © 2023. Available from W.W. Norton & Company.