by Ben Bova
“There are many ways. For example, by treating the numbers as coordinates, it’s possible to turn the numbers into new shapes and pictures.”
“What will the pictures show?”
“I don’t know. Maybe it will be an illustration of the enigma of the universe. Or maybe it will be an essay, or perhaps even a whole book. But the key is that we must obtain enough digits of the circular ratio first. I estimate that we must compute tens of thousands, perhaps even hundreds of thousands of digits before the meaning can be discerned. Right now, I’ve only computed about a hundred digits, inadequate to detect any hidden meaning.”
“A hundred? That’s all?”
“Sire, even so few digits have taken me more than ten years of effort. To compute the circular ratio, one must approach it by inscribing and circumscribing a circle with polygons. The mores sides in the polygons, the more precise the calculations and the more digits that can be obtained. But the complexity of the calculations increases rapidly, and progress is slow.”
King Zheng continued to stare at the circle crossed by a straight line. “Do you think you’ll find the secret of eternal life in it?”
“Yes, of course.” Jing Ke grew excited. “Life and death are the basic rules given to the world by the Heavens. Thus, the mystery of life and death must be contained in this message as well, including the secret of eternal life.”
“Then you must compute the circular ratio. I will give you two years to compute ten thousand digits. In five more years, I need you to get to a hundred thousand digits.”
“That … that’s impossible!”
King Zheng whipped his long sleeves across the table, scattering the silk cloth and ink and brush onto the floor. “You have but to name whatever resources you need.” He stared at Jing Ke coldly. “But you must complete the calculations in time.”
* * *
Five days later, King Zheng called for Jing Ke again. This time, Jing Ke didn’t come to the palace in Xianyang; instead, he met the royal entourage on the road as the king was touring around his domain. Right away, King Zheng asked Jing Ke for updates on the progress of the calculations.
Jing Ke bowed and spoke. “Sire, I gathered all the mathematicians who are capable of such calculations in the entire realm: they number only eight. Based on the amount of calculations necessary, even if all nine of us devote the rest of our lives to this task, we will only be able to obtain about three thousand digits of the circular ratio. In two years, the best that we can do is three hundred digits.”
King Zheng nodded and indicated that Jing Ke should walk with him. They came to a granite monument about twenty feet high. A hole was drilled through the top of the monument, and a thick rope made of twisted ox hide passed through the hole to suspend the monument from a wooden platform like the weight of a giant pendulum. The smooth bottom of the monument hovered about a man’s height above the ground. There were no inscriptions on the monument.
King Zheng pointed to the hanging monument and said, “Look, if you can finish the calculations in time, this will become a monument of your triumph. We will erect it on the ground and fill it with inscriptions of your many accomplishments. But if you can’t finish the calculations, this will become a memento of your shame. In that case, it will also be erected on the ground, but before cutting the rope to drop it, you will have to sit below it so that it can be your tombstone.”
Jing Ke lifted his eyes to gaze at the gigantic suspended stone that filled his field of vision. Against the moving clouds in the sky, the dark mass appeared oppressive.
Jing Ke turned to the king and said, “Your Majesty had spared my life once, and even if I could finish the calculations in time, it wouldn’t be enough to erase the crime of my attempt on your life. I’m not afraid to die. Please give me five more days to think about this. If I still can’t come up with a plan, I’ll sit under the monument willingly.”
* * *
Four days later, Jing Ke requested an audience with the king, which was immediately granted. Calculating the circular ratio was the most important task on the king’s mind.
“From your expression, I gather that you have indeed come up with a plan.” The king smiled.
Jing Ke did not answer directly. “Your Majesty, you once said that you would give me all the resources that I require. Is that still the case?”
“Of course.”
“I need three million men from your army.”
The number did not astonish the king. His eyebrows only lifted briefly. “What kind of soldiers?”
“The common soldiers under your command now are sufficient.”
“I think you should be aware that most of the soldiers in my army are illiterate. In two years, you cannot possibly teach them complex mathematics, let alone finish the calculations.”
“Sire, the skills they would need can be taught to the least intelligent solider in an hour. Please give me three soldiers so that I can demonstrate.”
“Three? Only three? I can easily give you three thousand.”
“I only need three.”
King Zheng waved his hand and summoned three soldiers. They were all very young. Like other Qin soldiers, they moved like order-obeying machines.
“I don’t know your names,” Jing Ke said, tapping the shoulders of two of the soldiers. “The two of you will be responsible for number input, so I’ll call you ‘Input One’ and ‘Input Two.’” He pointed to the last soldier. “You will be responsible for number output, so I’ll call you ‘Output.’” He shoved the soldiers to where he wanted them to stand. “Like this. Form a triangle. Output is the apex. Input One and Input Two form the base.”
“You could have just told them to stand in the Wedge Attack Formation,” King Zheng said, glancing at Jing Ke with a smile.
Jing Ke took out six small flags—three white, three black—and handed them out to the three soldiers so that each held a black flag and a white flag. “White represents zero; black represents one. Good. Now, listen to me. Output, you turn around and look at Input One and Input Two. If they both raise the black flags, you raise the black flag as well. Under all other circumstances, you raise the white flag. Specifically, there are three such conditions: Input One is white and Input Two is black; Input One is black and Input Two is white; Input One and Input Two are both white.”
Jing Ke repeated the instructions one more time to be sure that the three soldiers understood. Then he began to shout orders. “Let’s begin! Input One and Input Two, you can raise whichever flag you want. Good. Raise! Good. Raise again! Raise!”
Input One and Input Two raised their flags three times. The first time they were black-black, the second time white-black, and the third time black-white. Output reacted correctly each time, raising the black flag once and the white one twice.
“Very good. Sire, your soldiers are very smart.”
“Even an idiot would be capable of this. Tell me, what are they really doing?” King Zheng looked baffled.
“The three soldiers form a component for a calculation system, which I call an AND gate. If both numbers input into the gate are one, the result output is also one; otherwise, if one of the numbers input is zero, such as zero-one, one-zero, or zero-zero, the result output is zero.” Jing Ke paused to let King Zheng digest the information.
The king said impassively, “All right. Continue.”
Jing Ke turned to the three soldiers again. “Let’s form another component. You, Output, if you see either Input One or Input Two raise a black flag, you raise the black flag. There are three situations where that will be true: black-black, white-black, black-white. When it’s white-white, you raise the white flag. Understand? Good lad, you’re really clever. You’re the key to the correct functioning of the gate. Work hard, and you will be rewarded! Let’s begin operation. Raise! Good, raise again! Raise again! Perfect. Your Majesty, this component is called an OR gate. Whenever one of the two inputs is one, the output is also one.”
Then, Jing Ke used the three soldier
s to form what he called a NAND gate, a NOR gate, an XOR-gate, an XNOR-gate, and a tristate gate. Finally, using only two soldiers, he made the simplest gate, a NOT gate: Output always raised the flag that was opposite in color from the one raised by Input.
Jing Ke bowed to the Emperor. “All calculating components have been demonstrated. This is the scope of the skills that the three million soldiers must learn.”
“How can you perform complex calculations using such simple, childish tricks?” King Zheng’s face was full of distrust.
“Great King, the complexity in everything in the universe is built up from the simplest components. Similarly, an immense number of simple components, when structured together appropriately, can generate extremely complex capabilities. Three million soldiers can form a million of these gates I’ve just demonstrated, and these gates can be put together into a whole formation capable of any complex calculation. I call my invention a calculating formation.”
“I still don’t understand how the calculations will be carried out.”
“The precise process is complicated. If Your Majesty continues to be interested, I can explain in detail later. For now, it’s enough to know that the operation of the calculating formation is based on a novel method of thinking about and writing down numbers. In this method, only two numerals, zero and one, corresponding to the white and black flags, are needed. But this new method can use zero and one to represent any number, and this allows the calculating formation to use a large number of simple components to collectively carry out high-speed calculations.”
“Three million is almost the entirety of my army, but I will give them to you.” King Zheng sighed meaningfully. “Hurry. I’m feeling old.”
* * *
A year passed.
It was another beautiful day with the sun and the moon both out. King Zheng and Jing Ke stood together on a high stone dais, with the king’s numerous ministers in rows behind them. Below them, a magnificent phalanx of three million Qin soldiers stood arrayed on the ground, the entire formation a square three miles* on each side. Lit by the freshly risen sun, the phalanx remained still like a giant carpet made of three million terra-cotta warriors. But when a flock of birds wandered above the phalanx, the birds immediately felt the potential for death from below and scattered anxiously.
Jing Ke said, “Your Majesty, your army is truly matchless. In an extremely short time, we have completed such complex training.”
King Zheng held on to the hilt of his long sword. “Even though the whole is complex, what each soldier must do is very simple. Compared to the military training they went through, this is nothing.”
“Then, Your Majesty, please give the great order!” Jing Ke’s voice trembled with excitement.
King Zheng nodded. A guard ran over, grabbed the hilt of the king’s sword, and stepped backward. The bronze sword was so long that it was impossible for the king to pull it out of the scabbard without help. The guard knelt and presented the sword to the king, who lifted the sword to the sky and shouted: “Calculating Formation!”
Battle drums began to beat, and four giant bronze cauldrons at the corners of the stone dais came to life simultaneously with roaring flames. A group of soldiers standing at the edge of the dais facing the phalanx chanted in unison: “Calculating Formation…”
On the ground below, colors in the phalanx began to shift and move. Complicated and detailed circuit patterns appeared and gradually filled the entire formation. Ten minutes later, the army had rearranged itself into a nine-square-mile calculating formation.
Jing Ke pointed to the formation and began to explain. “Your Majesty, we have named this formation Qin I. Look, there in the center is the central processing formation, the core component of the calculating formation, made up of the best divisions of your army. By referencing this diagram, you can see within it the adding formation, quick storage formation, and stack memory formation. Around it, the part that looks highly regular is the memory formation. When we built this part, we found that we didn’t have enough soldiers. But luckily, the work done by the elements in this component is the simplest, so we trained each soldier to hold more colored flags. Each man can now complete the work that initially required twenty men. This allowed us to increase the memory capacity to meet the minimum requirements for running the calculating procedure for the circular ratio. Observe also the open passage that runs through the entire formation and the light cavalry waiting for orders in the passage: that’s the system’s main communication line, responsible for transmitting information between the components of the whole system.”
Two soldiers brought over a large scroll, tall as a man, and spread it open before King Zheng. As the scroll reached the end, everyone present remembered the scene in the palace a few years ago, and they all held their breath. But the imaginary dagger did not appear. Before them was only a large sheet of thin silk filled with symbols, each the size of a fly’s head. Packed so densely, the symbols were as dazzling to behold as the calculating formation on the ground below.
“Your Majesty, these are the orders in the procedure I developed for calculating the circular ratio. Please look here”—Jing Ke pointed to the calculating formation below—“the soldiers standing ready form what I call the ‘hardware.’ What’s on this cloth is what I call the ‘software,’ the soul of the calculating formation. The relationship between hardware and software is like that between the guqin zither and sheet music.”
King Zheng nodded. “Good. Begin.”
Jing Ke lifted both hands above his head and solemnly chanted: “As ordered by the Great King, initiate the calculating formation! System self-test!”
A row of soldiers standing halfway down the face of the stone dais repeated the order using flag signals. In a moment, the phalanx of three million men seemed to turn into a lake filled with sparkling lights as millions of tiny flags waved.
“Self-test complete! Begin initialization sequence! Load calculation procedure!”
Below, the light cavalry on the main communication line that passed through the entire calculating formation began to ride back and forth swiftly. The main passage soon turned into a turbulent river. Along the way, the river fed into numerous thin tributaries, infiltrating all the modular subformations. Soon, the ripples of black and white flags coalesced into surging waves that filled the entire phalanx. The central processing formation area was the most tumultuous, like tinder set on fire.
Suddenly, as though the fuel had been exhausted, the movements in the central processing formation slackened and eventually stopped. Starting with the central processing formation in the center, the stillness spread in every direction like a lake being frozen over. Finally, the entire calculating formation came to a stop, with only a few scattered components flashing lifelessly in infinite loops.
“System lockup!” a signal officer called out. Shortly after, the reason for the malfunction was determined: there was an error with the operation of one of the gates in the central processing formation’s status storage unit.
“Restart system!” Jing Ke ordered confidently.
“Not yet,” King Zheng said, still holding on to his sword. “Replace the malfunctioning gate and behead all the soldiers who made up that gate. In the future, any other malfunctions will be dealt with the same way.”
A few riders dashed into the phalanx with their swords drawn. They killed the three unfortunate soldiers and replaced them with new men. From the vantage point of the dais, three eye-catching pools of blood appeared in the middle of the central processing formation.
Jing Ke gave the order to restart the system. This time, it went very smoothly. Ten minutes later, the soldiers were carrying out the circular ratio calculating procedure. As the phalanx rippled with flag signals, the calculating formation settled into the long computation.
“This is really interesting,” King Zheng said, pointing to the spectacular mass calculating phalanx. “Each individual’s behavior is so simple, yet together, they can produce s
uch complex intelligence.”
“Great King, this is just the mechanical operation of a machine, not intelligence. Each of these lowly individuals is just a zero. Only when someone like you is added to the front as a one is the whole endowed with meaning.” Jing Ke’s smile was ingratiating.
“How long would it take to calculate ten thousand digits of the circular ratio?” King Zheng asked.
“About ten months. Maybe even sooner if things go right.”
General Wang Jian* stepped forward. “Your Majesty, I must urge caution. Even in regular military operations, it’s extremely dangerous to concentrate so much of our forces in an open area like this. Moreover, the three million soldiers in this phalanx are unarmed, carrying only signal flags. The calculating formation is not intended for battle and will be extremely vulnerable if attacked. Even under normal conditions, to effectuate an orderly retreat of this many men packed so tightly would take most of a day. If they were attacked, retreat would be impossible. Sire, this calculating formation will appear in the eyes of our enemies as meat placed on a cutting board.”
King Zheng did not reply, but turned his gaze to Jing Ke. The latter bowed and said, “General Wang is absolutely right. You must be cautious when deciding whether to pursue this calculation.”
Then Jing Ke did something bold and unprecedented: he lifted his eyes and locked gazes with King Zheng. The king immediately understood the meaning in that gaze: All your accomplishments so far are like zeroes; only with the addition of eternal life for yourself, a one, can all of those become meaningful.
“General Wang, you’re overly concerned.” King Zheng whipped his sleeves contemptuously. “The states of Han, Wei, Zhao, and Chu have all been conquered. The only two remaining states, Yan and Qi, are led by foolish kings who have exhausted their people. They’re on the verge of total collapse and pose no threat. Given the way things are going, by the time the circular ratio calculation is complete, those two states may already have fallen apart on their own and surrendered to the Great State of Qin. Of course, I appreciate the general’s caution. I suggest that we form a line of scouts at some distance from the calculating formation and step up our surveillance of the movements of the Yan and Qi armies. This way, we will be secure.” He lifted his long sword toward the sky and solemnly declared, “The calculations must be finished. I have decided that it must be so.”