Ancient
Babylonian
                                                                       Algorithms
                                                                       Donald E. Knuth
                                                                       Stanford University
    The early origins of mathematics are discussed,                        One of the ways to help make computer science re-
emphasizing those aspects which seem to be of greatest                 spectable is to show that it is deeply rooted in history,
interest from the standpoint of computer science. A                    not just a short-lived phenomenon. Therefore it is natu-
number of old Babylonian tablets, many of which have                   ral to turn to the earliest surviving documents which
never before been translated into English, are quoted.                 deal with computation, and to study how people ap-
    Key Words and Phrases: history of computation,                     proached the subject nearly 4000 years ago. Archeo-
Babylonian tablets, sexagesimal number system, sorting                 logical expeditions in the Middle East have unearthed a
    CR Categories: 1.2                                                 large number of clay tablets which contain mathematical
                                                                       calculations, and we shall see that these tablets give
                                                                       many interesting clues about the life of early "computer
                                                                       scientists."
                                                                       Introduction to Babylonian Mathematics
                                                                           The tablets in question come from the general area of
                                                                       Mesopotamia (present day Iraq), between the Tigris and
                                                                       Euphrates rivers, centered more or less about the ancient
                                                                       city of Babylon (near present-day Baghdad). They are
                                                                       covered with cuneiform (i.e. "wedge-shaped") script, a
                                                                       form of writing which goes back to about 3000 B.C. The
                                                                       tablets of greatest mathematical interest were written
                                                                       about the time of the Hammurabi dynasty, about 1800-
                                                                       1600 B.c., and we shall be primarily concerned with
                                                                       texts that date from this so-called Old-Babylonian pe-
                                                                       riod.
                                                                           It is well known that Babylonians worked in a
                                                                       sexagesirnal, i.e. radix 60, number system, and that our
                                                                       present sexagesimal units of hours, minutes, and seconds
    Copyright @ 1972, Association for Computing Machinery, Inc.        are vestiges of their system. But it is less widely known
    General permission to republish, but not for profit, all or part   that the Babylonians actually worked withfloating-point
of this material is granted, provided that reference is made to this   sexagesimal numbers, using a rather peculiar notation
publication, to its date of issue, and to the fact that reprinting
privileges were granted by permission of the Association for Com-      that did not include any exponent part. Thus, the two-
puting Machinery.                                                      digit number
    Author's address: Stanford University, Computer Science De-
partment, Stanford, CA 94305. The preparation of this paper was        2,20
supported in part by the National ScienceFoundation, under grant
GJ-992.                                                                stood for 2 × 60 + 20 = 140, and for 2 + 20/60 = 2~,
671                                                                    Communications               July 1972
                                                                       of                           Volume 15
                                                                       the ACM                      Number 7
and for 2/60 + 20/3600, and in general for 140 X 60 ",         been added in parentheses, to explain some of the things
where n is any integer.                                        that were originally unstated on the tablets. All numbers
    At first sight this manner of representing numbers         are presented Babylonian-style, i.e. without exponents,
may look very awkward, but in fact it has significant          so the reader is warned that he will have to supply an
advantages when multiplication and division are in-            appropriate scale factor in his head; thus, it is necessary
volved. We use the same principle when we do calcula-          to remember that 1 might mean 60 and 15 might mean ¼.
tions by slide rule, performing the multiplications and            The first example we shall discuss is excerpted f r o m
divisions without regard to the decimal point location         an Old-Babylonian tablet which was originally about
and then supplying the appropriate power of 10 later.          5 X 8 × 1 inches in size. H a l f of it now appears in the
A Babylonian mathematician computing with numbers              British Museum, about one-fourth appears in the
that were meaningful to him could easily keep the ap-          Staatliche Museen, Berlin, and the other fourth has ap-
propriate power of 60 in mind, since it is not difficult to    parently been lost or destroyed over the years. The
estimate the range of a value within a factor of 60. A         original text appears in [3, pp. 193-199; 4, Tables 7, 8,
few instances have been found where addition was per-          39, 40; and 8, pp. 11-21].
formed incorrectly because the radix points were im-           A (rectangular) cistern.
properly aligned [7, p. 28], but such examples are sur-        The height is 3,20, and a volume of 27,46,40 has been
prisingly rare.                                                    excavated.
    As an indication of the utility of this floating-point     The length exceeds the width by 50. (The object is to find the
notation, consider the following table of reciprocals:             length and the width.)
                                                               You should take the reciprocal of the height, 3,20, obtaining 18.
                                                               Multiply this by the volume, 27,46,40, obtaining 8,20. (This
 2    30       16   3,45           45    1,20                      is the length times the width; the problem has been reduced
 3    20       18   3,20           48    1,15                      to finding x and y, given that x -- y = 50 and xy = 8,20.
 4    15       20   3              50    1,12                      A standard procedure for solving such equations, which
 5    12       24   2,30           54    1,6,40                    occurs repeatedly in Babylonian manuscripts, is now used.)
 6    10       25   2,24            1    1                     Take half of 50 and square it, obtaining 10, 25.
 8    7,30     27   2,13,20       1,4    56,15                 Add 8,20, and you get 8,30, 25. (Remember that the radix point
 9    6,40     30   2             1,12   50                        position always needs to be supplied. In this case, 50 stands
10    6        32   1,52,30       1,15   48                        for 5/6 and 8,20 stands for 8], taking into account the
12    5        36   1,40          1,20   45                        sizes of typical cisterns!)
15    4        40   1,30          1,21   44,26,40              The square root is 2,55.
                                                               Make two copies of this, adding (25) to the one and subtracting
Dozens of tablets containing this information have been            from the other.
found, some of which go back as far as the " U r I I I         You find that 3,20 (namely 3-~)is the length and 2,30 (namely
dynasty" o f a b o u t 2250 B.c. There are also m a n y mul-       2½) is the width.
                                                               This is the procedure.
tiplication tables which list the multiples of these num-
bers; for example, division by 81 = 1,21 is equivalent to      The first step here is to divide 27,46,40 by 3,20; this is
multiplying by 44,26,40, and tables of 44,26,40 × k for        reduced to multiplication by the reciprocal. The mul-
1 < k < 20 and k = 30,40,50 were commonplace. Over             tiplication was done by referring to tables, probably by
two hundred examples of multiplication tables have             manipulating stones or sand in some manner and then
been catalogued.                                               writing down the answer. The square root was also
                                                               computed by referring to tables, since we k n o w that
                                                               m a n y tables of n vs. n ~ existed. N o t e that the rule for
Babylonian "Programming"                                       computing the values of x and y such that x -- y = d
                                                               and x y = p was to f o r m
    The Babylonian mathematicians were not limited             sqrt((d/2) ~ + p) 4- (d/2).
simply to the processes of addition, subtraction, mul-
tiplication, and division; they were adept at solving              The calculations described in Babylonian tablets are
m a n y types of algebraic equations. But they did not         not merely the solutions to specific individual problems:
have an algebraic notation that is quite as transparent as     they actually are general procedures for solving a whole
ours; they represented each formula by a step-by-step          class of problems. The numbers shown are merely in-
list of rules for its evaluation, i.e. by an algorithm for     cluded as an aid to exposition, in order to clarify the
computing that formula. In effect, they worked with a          general method. This tact is clear because there are
"machine language" representation of formulas instead          numerous instances where a particular case of the gen-
of a symbolic language.                                        eral method reduces to multiplying by 1 ; such a multi-
     The flavor of Babylonian mathematics can best be          plication is explicitly carried out, in order to abide by
appreciated by studying several examples. The transla-         the general rules. Note also the stereotyped ending,
tions below attempt to render the words of the original        "This is the procedure," which is c o m m o n l y found at
texts as faithfully as possible into good English, without     the end of each section on a tablet. Thus the Babylonian
extensive editorial interpretation. Several remarks have       procedures are genuine algorithms, and we can com-
                                                               mend the Babylonians for developing a nice way to ex-
672                                                            Communications                    July 1972
                                                               of                                Volume 15
                                                               the ACM                           Number 7
plain an algorithm by example as the algorithm itself                 instances such as the following text (again from the
was being defined.                                                    British Museum), the style is somewhat different [5, p.
    Here is another excerpt from the same tablet, this                19]:
time involving only a linear equation:                                The sum of length, width, and diagonal is 1,1 and 7 is the area.
A cistern.                                                            What are the corresponding length, width, and diagonal?
The length (in cubits) equals the height (in gars, where 1 gar =      The quantities are unknown.
    12 cubits).                                                       1,10 times 1,10is 1,21,40.
A certain volume of dirt has been excavated.                          7 times 2 is 14.
The cross-sectional area (in square cubits) plus this volume (in      Take 14 from 1,21,40 and 1,7,40 remains.
    cubic cubits) comes to 1,10 (namely 1-~).                         1,7,40 times 30 is 33,50.
The length is 30 (namely ½cubit). What is the width?                  By what should 1,10 be multiplied to obtain 33,50?
You should multiply the length, 30, by 12, obtaining 6; this is the   1,10 times 29 is 33,50.
    height (in cubits instead of gars).                               29 is the diagonal.
Add 1 to 6, and you get 7.                                            The sum of length, width, and diagonal is 12 and 12 is the area.
The reciprocal of 7 does not exist; what will give 1,10 when          What are the corresponding length, width, and diagonal?
    multiplied by 7? 10 will.                                         The quantities are unknown.
(Hence 10, namely ~, is the cross-sectional area in square cubits.)   12 times 12 is 2,24.
Take the reciprocal of 30, obtaining 2.                               12 times 2 is 24.
Multiply 10 by 2, obtaining the width, 20 (namely xa cubit).          Take 24 from 2,24 and 2 remains.
This is the procedure.                                                2 times 30 is 1.
Note the interesting way in which the Babylonians dis-                By what should 12 by multiplied to obtain 17
                                                                      12 times 5 is 1.
regarded units, blithely adding area to volume; similar               5 is the diagonal.
examples abound, showing that the n u m e r i c a l algebra
was of primary importance to them, not the physical or                The sum of length, width, and diagonal is 1 and 5 is the area.
                                                                      Multiply length, width, and diagonal times length, width, and
geometrical significance of the problems. At the same                    diagonal.
time they used conventional units of measure (cubits,                 Multiply the area by 2.
even " g a r s " and the understood relation between gars             Subtract the products and multiply what is left by one-half.
and cubits), in order to set the scale factors for the                By what should the sum of length, width, and diagonal be
parameters. And they " a p p l i e d " their results to practical         multiplied to obtain this product?
                                                                      The diagonal is the factor.
things like cisterns, perhaps because this would m a k e
their work appear to be socially relevant.                            This text comes from the considerably later "Seleucid"
    In this p r o b l e m it was necessary to divide by 7, but        period of Babylonian history (see below), which may
the reciprocal of 7 didn't appear on the tables because               account for the difference in style. It treats a problem
it has no finite reciprocal. (There is an infinite repeating          based on the rather remarkable formula
expansion 1/7 - 8,34,17,8,34,17,..., but we have no
                                                                      d -- ½((1 q- w q- d) ~ -     2 A ) / ( l q- w W d),
evidence that the Babylonians knew this.) In such cases
where the reciprocal table was of no avail, the text                  where
always says, in effect, " W h a t shall I multiply by a in            A = lw is the area of a rectangle,
order to obtain b?" and then the answer is given. This                d -- x / ( l 2 -b w2) is the length of its diagonals.
wording indicates that a multiplication table is to
be used backwards; for example, the calculation of                    (There is ample evidence from other texts that the Old-
 11,40 - 35 = 20 [3, p. 329] could be read off from a                 Babylonian mathematicians knew the so-called Pythago-
multiplication table. F o r more difficult divisions, e.g.            rean theorem, over I000 years before the time of
 1,26,40 - 43,20 = 15 [3, p. 246; 5, p. 8], a slightly                Pythagoras.) The first two sections quoted above work
different wording was used, indicating perhaps that a                 out the problem for the cases (1, w, d) = (20, 21, 29) and
 special division procedure was employed in such cases.               (3, 4, 5) respectively, but without calculating l and w;
At any rate we k n o w that the Babylonians were able to              we know from other texts that the solution t o x -b y = a,
                                                                      x ~ q_ y2 = b was well known in ancient times. The de-
compute
                                                                      scription of the calculation in these two sections is un-
7 + 2,6;     2 8 , 2 0 - - 17;   10,12,45 + 40,51;                    usually terse, not naming the quantities it is dealing
and so on. One Old-Babylonian table of reciprocals is                 with. On the other hand, the third section gives the s a m e
known that gives reciprocals of irregular numbers to                  procedure entirely w i t h o u t numbers. The reason for this
three sexagesimal places, but it is not extremely accurate            may be the fact that the stated parameters 1 and 5 can-
[3, p. 16].                                                           not possibly correspond to the length-F width-Fdiagonal
                                                                      and the area, respectively, of any rectangle, no matter
                                                                      what powers of 60 are attached! Viewed in this light,
Further Examples                                                      teachers of computer science will recognize that the
                                                                      above text reads very much like the solution to an ex-
    We have noted that general algorithms were usually                amination in which an impossible problem has been
given, accompanied by a sample calculation. In rare                   posed. (Note also that the second section follows the
673                                                                   Communications                     July 1972
                                                                      of                                 Volume 15
                                                                      the ACM                            Number 7
general procedure, as stated in the third section, very                          and these operations were clearly u n d e r s t o o d by the
faithfully when it c o m e s to dividing 1 by 12, instead o f                    B a b y l o n i a n mathematicians; but the rules were ap-
using the reciprocal o f 12.)                                                    parently never written down. N o examples showing in-
     Instances o f algorithms without a c c o m p a n y i n g num-               termediate steps in multiplication have been found.
bers are very rare; here is a n o t h e r one, this time an                           The following interesting example dealing with c o m -
O l d - B a b y l o n i a n text f r o m the L o u v r e [4, p. 39; 8, p. 71]:   p o u n d interest, taken f r o m the Berlin M u s e u m collec-
Length and width is to be equal to the area.                                     tion, is one o f the few examples o f a "DO I = 1 TO N" in
You should proceed as follows•                                                   the B a b y l o n i a n tablets that have been excavated so far
Make two copies of one parameter•                                                [3, pp. 353-365; 4, Tables 32, 56, 57; 5, p. 59; 8, pp.
Subtract 1.                                                                      118-120]:
Form the reciprocal.
Multiply by the parameter you copied.                                            I invested 1 maneh of silver, at a rate of 12 shekels per maneh (per
This gives the width,                                                                  year, with interest apparently compounded every five years).
                                                                                 I received, as capital plus interest, 1 talent and 4 manehs.
I n other words, if x + y = xy, it is possible to c o m p u t e                  (Here 1 maneh = 60 shekels, and 1 talent = 60 manehs.)
y by the p r o c e d u r e y = (x - 1) -1 x. The fact that no                    How many years did this take?
n u m b e r s are given m a d e this passage particularly h a r d                Let 1 be the initial capital.
                                                                                 Let 1 maneh earn 12 (shekels) interest in a 6 (= 360) day year.
to decipher, and it was not properly u n d e r s t o o d for
                                                                                 And let 1,4 be the capital plus interest.
m a n y years (see [9, pp. 73-74]); hence we can see the                         Compute 12, the interest, per 1 unit of initial capital, giving 12
advantages o f numerical examples.                                                     as the interest rate.
       The above p r o c e d u r e reads surprisingly like a pro-                Multiply 12 by 5 years, giving 1.
g r a m for a " s t a c k m a c h i n e " like the B u r r o u g h s B5500l      Thus in five years the interest will equal the initial capital.
                                                                                 Add 1, the five-year interest, to 1, the initial capital, obtaining 2.
N o t e that b o t h in this example and in the very first one
                                                                                 Form the reciprocal of 2, obtaining 30.
we discussed we are told to m a k e two copies o f some                          Multiply 30 by 1,4, the sum of capital plus interest, obtaining 32.
n u m b e r ; this indicates that actual numerical calcula-                      Find the inverse of 2, obtaining 1. (The" inverse" here means the
tions generally destroyed the o p e r a n d s in the process o f                       logarithm to base 2; in other problems it stands for the value
finding a result. Similarly we find in other texts the in-                             of n such that a given valuef(n) appears in some table.)
                                                                                 Form the reciprocal of 2, obtaining 30.
struction to " K e e p this n u m b e r in y o u r h e a d " [6, pp.
                                                                                 Multiply 30 by 30 (the latter 30 apparently stands for 32 -- 2, for
50-51], a remarkable parallelism with t o d a y ' s notion                             otherwise the 32 would never be used and the rest of the
t h a t a c o m p u t e r stores n u m b e r s in its " m e m o r y . " In             calculation would make no sense), obtaining 15 ( = total
a n o t h e r place we read, in essence, " R e p l a c e the s u m o f                 interest without initial capital if the investment had been
length and width by 30 times itself" [3, p. 114], an                                   cashed in five years earlier).
                                                                                 Add 1 to 15, obtaining 16.
ancient version of the assignment statement " x : = x/2".
                                                                                 Find the inverse of 16, obtaining 4.
                                                                                 Add the two inverses 4 and 1, obtaining 5.
                                                                                 Multiply 5 by 5 years, obtaining 25.
Conditionals and Iterations                                                      Add another 5 years, making 30.
                                                                                 Thus, after the 30th year the initial capital and its interest will
                                                                                       be 1,4.
      So far we have seen only "straight-line" calculations,
                                                                                 . . . (Here about 4 lines of the text have broken off. Apparently
without any branching or decision-making involved. In                                  there is now a question of checking the previous answer.)
order to construct algorithms that are really nontrivial                               • . . giving 12 as the interest rate.
f r o m a c o m p u t e r scientist's point o f view, we need to                 Multiply 12 by 5 years, giving 1.
have some operations that affect the flow o f control.                           Thus in five years the interest will equal the initial capital•
                                                                                 Add 1, the five-year interest, to 1, the initial capital, obtaining 2,
      But alas, there is very little evidence o f this in the                          the capital and its interest after the fifth year.
B a b y l o n i a n texts. The only thing resembling a condi-                    Add 5 years to the 5 years, obtaining 10 years.
tional b r a n c h is implicit in the operation of division,                     Double 2, the capital and its interest, obtaining 4, the capital
where the calculation proceeds a little differently if the                             and its interest after the tenth year.
reciprocal o f the divisor does not appear in the table.                         Add 5 years to the 10 years, obtaining 15 years.
                                                                                 Double 4, the capital and its interest, obtaining 8, the capital
      W e d o n ' t find tests like " G o to step 4 if x < 0",
                                                                                       and its interest after the fifteenth year.
because the Babylonians d i d n ' t have negative numbers;                       Add 5 years to the 15 years, obtaining 20 years.
we d o n ' t even find conditional tests like " G o to step 5                    Double 8, obtaining 16, the capital and its interest after the
if x = 0", because they d i d n ' t treat zero as a n u m b e r                        twentieth year.
either! Instead of ha,~ing such tests, there would effec-                        Add 5 years to the 20 years, obtaining 25 years.
                                                                                 Double 16, the capital and its interest, obtaining 32, the capital
tively be separate algorithms for the different cases. ( F o r                         and its interest after the twenty-fifth year.
example, see [3, pp. 312-314] for a case in which one                            Add 5 years to the 25 years, obtaining 30 years.
algorithm is step-by-step the same as another, but sim-                          Double 32, the capital and its interest, obtaining I, 4, the capital
plified since one o f the parameters is zero.)                                         and its interest after the thirtieth year.
      N o r are there m a n y instances o f iteration. The basic                 This long-winded and rather clumsy p r o c e d u r e reads
operations underlying the multiplication o f high-preci-                         almost like a m a c r o expansion !
sion sexagesimal n u m b e r s obviously involve iteration,
674                                                                              Communications                     July 1972
                                                                                 of                                 Volume 15
                                                                                 the ACM                            Number 7
    A more sophisticated example involving c o m p o u n d            ample, a symbol for zero was now used within numbers,
interest appears in another section of the Louvre tablet              instead of the blank space that formerly appeared. The
quoted earlier. The same usurious rate of interest (20                following excerpts from a text in the Louvre Museum [3,
percent per annum) occurs, but now c o m p o u n d e d an-            pp. 96-103; 8, p. 76] indicate some of the other ad-
nually:                                                               vances:
One kur (of grain) has been invested; after how many years will       From 1 to 10, sum the powers (literally the "ladder") of 2.
    the interest be equal to the initial capital?                     The last term you add is 8,32.
You should proceed as follows.                                        Subtract 1 from 8,32, obtaining 8,31.
Compound the interest for four years.                                 Add 8,31 to 8,32, obtaining the answer 17,3.
The combined total (capital + interest) exceeds 2 kur.
What can the excess of this total over the capital plus interest
                                                                      The squares from 1 X 1 = 1 to 10 X 10 = 1,40; what is their
    for three years be multiplied by in order to give the four-year
                                                                          sum?
    total minus 2?
                                                                      Multiply 1 by 20, namely by one-third, giving20.
2,33,20 (months).
                                                                      Multiply 10 by 40, namely by two thirds, giving 6,40.
From four years, subtract 2,33,20 (months), to obtain the desired
                                                                      6,40 plus 20 is 7.
    number of full years and days.                                    Multiply 7 by 55 (which is the sum of 1 through 10), obtaining
Translated into decimal notation, the problem is to de-                   6,25.
                                                                      6,25 is the desired sum.
termine how long it would take to double an investment.
Since                                                                 Here we have correct formulas for the sum of a geo-
                                                                      metric series
1.728 = 1.23 < 2 < 1.24 = 2.0736,
the answer lies somewhere between three and four years.               ~-~2 k = 2 n q - ( 2 " - - 1)
                                                                      k=l
The growth is linear in any one year, so the answer is
                                                                      and for the sum of a quadratic series
 1.24 -- 2              33    20
1.24 _ 1.23 X 12 = 2 q- ~ q- 36---~
                                                                      kffil              ~n           k.
months less than four years. This is exactly what was
computed [5, p. 63].                                                  These formulas have not been found in Old-Babylonian
    Note that here we have a problem with a nontrivial                texts.
iteration, like a "WHILE" clause: The procedure is to                     Moreover, this same Seleucid tablet shows an in-
form powers of I q- r, where r is the interest rate, until            creased virtuosity in calculation; for example, the roots
finding the first value of n such that (1 + r)" >_ 2; then            to complicated equations like
calculate
                                                                      xy=     1,   xq-y=      2,0,0,33,20
12((1 -F r)" -- 2)/((1 q- r)" -- (1 -Jr- r)"-1),
                                                                      (solution: x = 1,0,45 and y = 59,15,33,20) are com-
and the answer is that the original investment will                   puted. Perhaps this problem was designed to demon-
double in n years minus this many months.                             strate the use of the new zero symbol.
    This procedure suggests that the Babylonians were                     An extremely impressive example of the Seleucid era
familiar with the idea of linear interpolation. Therefore             calculating ability appears in another Louvre Museum
the trigonometric tables in the famous "Plimpton tab-                 tablet [3, pp. 14-22]. It is a 6-place table of reciprocals,
let" [6, p. 38-41] were possibly used to obtain sines and             which begins thus:
cosines in a similar way.
                                                                      By the power of Anu and Antum, whatever I have made with my
                                                                          hands, let it remain intact.
The Seleueids                                                         Reciprocal   1                       is 1
                                                                      Reciprocal   1,0,16,53,53,20            59,43,10,50,52,48
    Old-Babylonian mathematics has several other in-                  Reciprocal   1,0,40, 53,20              59,19,34,13,7,30
teresting aspects, but a more elaborate discussion is be-             Reciprocal   1,0,45                     59,15,33,20
yond the scope of this paper. Very few tablets have been              and so on, ending with
found that were written after 1,600 B.c., until approxi-
mately 300 B.c. when Mesopotamia became part of the                              2,57,8,49,12                20,19,19,34,45,35,48,8,53,20
                                                                      Reciprocal 2,57,46,40                  20,15
empire of Alexander the Great's successors, the "Seleu-                          2,59,21,40,48,54            20,4,16,22,28,44,14,57,40,4,
cids." A great number of tablets from the Seleucid era                                                           56,17,46,40
have been found, mostly dealing with astronomy which
was highly developed. A very few pure mathematical                    Reciprocal 3                         is 20
texts of this era have also been found; these tablets                 First part; results for 1 and 2, incomplete.
indicate that the Old-Babylonian mathematical tradition               Table of Nidintum-Anu, son of Inakibit-Anu, son of Kuzu,
did not die out during the intervening centuries.                         priests of Anu and Antum in Uruk. Author Inakibit-Anu.
    Indeed, some noticeable progress was made; for ex-
675                                                                   Communications                        July 1972
                                                                      of                                    Volume 15
                                                                      the ACM                               Number 7
     Apparently Inakibit-Anu (whom we shall call Inaki-       matics by A.A. Aaboe [1] can be recommended, as can
bit for short) was the author of this remarkable table;       B.L. van der Waerden's well-known treatise Science
and his son made a copy. Another tablet or tablets, now       Awakening [9]. Much of the deciphering of Babylonian
lost, continued the table to numbers beginning with           mathematical texts was originally due to Otto Neuge-
3, 4, ....                                                    bauer, who has written an authoritative popular ac-
     There are exactly 231 sexagesimal numbers of six         count The Exact Sciences in Antiquity [7]; see especially
digits (i.e. six sexagesimal places) or less which have a     his fascinating discussion, pp. 59-63; 103-105, of the
finite reciprocal and which begin with 1 or 2. This table     problems that plague historical researchers in this field.
contains every one of them, without exception. And 20              For more detailed study, it is fun to read the original
further entries, giving reciprocals of numbers that have      source material. Neugebauer published the texts of all
more than six digits, are also included. It is not clear      known mathematical tablets,, together with German
how these 20 extra numbers were selected. (See the Ap-        translations, in a comprehensive series of three volumes,
pendix to this paper for further discussion.)                 during the period 1935-1937 [3, 4, 5]. A French edition
     How did Inakibit prepare this table? The simplest        of the texts [8] was published in 1938 by F. Thureau-
procedure would be to start with the pair of numbers          Dangin, an eminent Assyriologist. Then in 1945, Neuge-
(1, 1) and then to go repeatedly from (x, y) to (2x, 30y),    bauer and A. Sachs published a supplementary volume
(3x, 20y), and (5x, 12y) until no more numbers x of six       [6], which includes all mathematical tablets discovered
or less digits are possible. (In fact this procedure can be   in the meantime (mostly in American museums). The
simplified further if we note that only those values x of     Neugebauer-Sachs volume is written in English, but un-
the form 2~3~'5k need to be considered where either i _< 1    fortunately these tablets are not quite as interesting as
o r j --- 0 or k = 0; other numbers are multiples of 60.)     the ones in Neugebauer's original German series. A list
There is some evidence that this is exactly what he did;      of developments since 1945 appears in [7, p. 49].
for example, several tables are known that start with              Most of the Babylonian mathematical tablets have
some pair of reciprocals and then repeatedly apply one        never been translated into English. The translations
of these three operations [6, p. 13-16]. An even more         above have been made by comparing the German of
convincing argument for this hypothesis is that Inaki-        [3, 4, 5] with the French [8]; but these two versions ac-
bit's values for 3-22 and 3-23 are both wrong; and most of    tually differ in many details, so the Akkadian and
the errors in 3-2a are accounted for if we assume that he     Sumerian vocabularies published in [4, 8, 6] have been
calculated 3-~8 from the incorrect value of 3-~2.             consulted in an attempt to give an accurate rendition.
     The complete table requires that 721 pairs (x, y)             Since only a tiny fraction of the total number of clay
must be generated, and of course it is very laborious to      tablets has survived the centuries, it is obvious that we
work with such high-precision numbers. Moreover, even         cannot pretend to understand the full extent of Babylo-
after all these pairs (x, y) have been computed, the work     nian mathematics. Neugebauer points out that the job
is far from done; it is still necessary to sort them into     of discovering what they knew is something like trying
order ! Inakibit's table is the earliest known example of a   to reconstruct all of modern mathematics from a few
large file that has been sorted; and this is one of the       pages that have been randomly torn out of the books in
reasons his work is so impressive, as anyone who has          a modern library. We can only place "lower bounds" on
tried to sort over 700 cards by hand will attest. To get      the scope of Babylonian achievements, and speculate
some idea of the immensity of this task, consider that it     about what they did not know.
takes many hours to sort 700 large numbers by hand                 What about other ancient developments? The Egyp-
nowadays; imagine how difficult it must have been to do       tians were not bad at mathematics, and archeologists
this job in ancient times! Yet Inakibit must have done it,    have dug up some old papyri that are almost as old as
since there is no simple way to generate such a table in      the Babylonian tablets we have discussed. The Egyptian
order. (As we might expect, he made a few mistakes;           method of multiplication, based essentially in the binary
there are three pairs of lines which should be inter-         number system (although their calculations were deci-
changed to bring the table into perfect order.)               mal, using something like Roman numerals)~ is espe-
     Thus, Inakibit seems to have the distinction of being    cially interesting; but in other respects, their use of
the first man in history to solve a computational prob-       awkward "unit fractions" left them far behind the
lem that takes longer than one second of time on a            Babylonians. Then came the Greeks, with an emphasis
modern electronic computer !                                  on geometry but also on such things as Euclid's al-
                                                              gorithm; the latter is the oldest nontrivial algorithm
                                                              which still is important to computer programmers. (See
Suggestions for Further Reading                                [7, 9] for the history of Egyptian mathematics, and [1, 7,
                                                              9] for Greek mathematics. A free translation of Euclid's
   If you have been captivated by Babylonian mathe-           algorithm in his own words, together with his incom-
matics, there are several good books on the subject           plete proof of its correctness, appears in [2, p. 294-296].)
which give further interesting details. The short intro-      And then there are the Indians, and the Chinese; it is
ductory text Episodes from the Early History of Mathe-        clear that much more can be told.
676                                                           Communications               July 1972
                                                              of                           Volume 15
                                                              the ACM                      Number 7
   Acknowledgment. I wish to thank Professor Abra-
ham Seidenberg for his courtesy in helping me obtain
copies of [3] and [8] when I needed them.
Appendix
     The 20 additional entries included in Inakibit's table are some-
what mysterious. In 19 of the cases, the number has a reciprocal
with six digits or less; the exception is 3z3 = 2,1,4,8,3,0, 7, whose
reciprocal has 17 sexagesimal digits.
     Let's say that a sexagesimal number is a Q-number if it has
six or less digits, while its reciprocal is finite and has more than
six digits and begins with 1 or 2. There are 132 Q-numbers in
all, only 19 of which appear in Inakibit's table. Five of these are
217, 223, 311, 3TM, and 32z; they constitute all Q-numbers of the forms
2~, 3., or 5~, and it is likely that such numbers appeared in special
tables. However, the Q-number 611 is not included, so it is not
simply a matter of perfect powers being included. The three-
digit Q-numbers 2131° and 2239 are excluded, so it not a matter of
including the smallest cases. The Q-numbers which do appear,
besides the five listed above, are 3951, 3105a, 31155; 213951, 2131'52,
213135a (but not 2131554); 31851, 2339, 2731°, 212311, 2183TM, 2203~, 29259,
2'2452. It is perhaps noteworthy that 31153 does not appear, but its
multiple 3u5 ~ does.
     Since so many Q-numbers are missing, we may conclude that
Inakibit continued his table by giving the reciprocals of all six-
digit numbers up to 59,43,10, 50, 52,48, not taking advantage of
symmetry. Hence the complete table contained the reciprocals of
at least 721 six-digit numbers, and it probably filled three clay
tablets in all.
References
      1°
Aaboe, Asger A. Episodesfrom the Early History of Mathematics.
    Random House, New York, 1964, 133 pp.
    2.
Knuth, Donald E. Seminumerical Algorithms. Addison-Wesley,
    Reading, Mass., 1971 (second printing), 624 pp.
    3.
Neugebauer, O. Mathematische keilschrift-texte. In Quellen und
    Studien zur Geschichte der Mathematik, Astronomie, und
    Physik, Vol. A3, Pt. 1, 1935, 516 pp.
    4.
Neugebauer, O. Mathematische keilschrift-texte. In Quellen und
    Studien zur Geschichte der Mathematik, Astronomie, und
    Physik, Vol. A3, Pt. 2, 1935, 64 pp. plus 69 reproductions of
    tablets.
    5.
Neugebauer, O. Mathematische keilschrift-texte. In Quellen und
    Studien zur Geschiehte der Mathematik, Astronomie, und
    Physik, Vol. A3, Pt. 3, 1937, 83 pp. plus 6 reproductions of
    tablets.
    6.
Neugebauer, O., and Sachs, A. Mathematical Cuneiform Texts.
    American Oriental Society, New Haven, Conn., 1945, 177 pp.
    plus 49 reproductions of tablets.
    7.
Neugebauer, O. The Exact Sciences in Antiquity. Brown U. Press,
    Providence, R.I., 1957 (second ed.), 240 pp. plus 14
    photographic plates.
    8.
Thureau-Dangin, F. Textes Math~matiques Babyloniens. E.J.
    Brill, Leiden, The Netherlands, 1938, 243 pp.
    9.
van der Waerden, B.L. Science Awakening. Tr. by Arnold Dresden.
    P. Noordhoff, Groningen, The Netherlands, 1954, 306 pp.
677                                                                            Communications   July 1972
                                                                               of               Volume 15
                                                                               the ACM          Number 7