History of Computing

Chris Wells, September 26, 2022

Chris Wells, September 26, 2022

The slide rule is an analogue calculating device that first appeared during the first half of the seventeenth century CE. Its invention is usually attributed to the English mathematician and Anglican clergyman *William Oughtred* (1574-1660). Like many inventions, his device was based on the work of a number of other individuals, predominant among whom were the Scottish mathematician *John Napier* (1550-1617) and the English mathematician *Edmund Gunter* (1581-1626).

Napier's contribution was the discovery of *logarithms*. Napier spent over two decades working on the theory of logarithms, and eventually published his findings in his 1614 work *Mirifici Logarithmorum Canonis Descriptio* (*A Description of the Wonderful Law of Logarithms*), just three years before his death at the age of sixty-seven.

The *logarithm* of a number *x* is the *exponent* (i.e. power) *y* by which another number (known as the *base*, *b*) must be raised in order to produce *x*. The base used can vary, depending on the area of application. In computer science, a base of *two* is often used, while in pure mathematics and many scientific applications a base known as *e* is used. In engineering and electronics, base *ten* is frequently used, and is obviously well suited for use with a decimal number system.

Napier found that the logarithm of the *product* of two numbers is equal to the sum of the logarithms of the individual numbers. The process of multiplying two large numbers together can thus be greatly simplified by *adding together* the logarithms of the two numbers and taking the *antilogarithm* of the result. The antilogarithm is the inverse function of the logarithm – it returns the number for which another number is the logarithm to a given base. In other words, if *x* is the *logarithm* of *y*, then *y* is the *antilogarithm* of *x*.

The same principle can be applied to finding the *quotient* of two numbers (i.e. dividing one number by another). The difference is that in order to divide one number by another, we must find the *difference* of the logarithms of the two numbers and take the antilogarithm of the result. The principle is embodied in the first and second laws of logarithms, which can be stated as follows:

log_{b} (*m* × *n*) = log_{b} (*m*) + log_{b}(*n*)

log_{b} (*m* ÷ *n*) = log_{b} (*m*) – log_{b} (*n*)

Although the use of logarithms to find the product of two numbers *does* reduce a multiplication problem to one of simple addition, it also relies on the availability (and accuracy) of a set of logarithmic tables. In order to calculate the product of two numbers, we must first extract the logarithm of each number from the tables. Once we have added the two logarithms together, we then have to use the tables once more to look up the antilogarithm of the result.

Napier's logarithms were *natural logarithms*, i.e. logarithms to base *e* (c. 2.7183). Natural logarithms are of great interest to mathematicians, especially those involved in the pursuit of pure mathematics, but they are not so useful for engineers and scientists, who tend to work with decimal values (i.e. numbers to base *ten*).

In 1617, the English mathematician *Henry Briggs* (1561-1630), who had been influential in encouraging the adoption of Napier's ideas, suggested the use of a decimal base instead of *e*. With Napier's agreement, he undertook the creation of a set of logarithmic tables to base ten, and in 1624 published his work *Arithmetica Logarithmica*, which contained the logarithms to base ten of thirty thousand natural numbers (1 – 20,000 and 90,001 – 100,000) to fourteen decimal places.

The scientific community were quick to adopt the use of logarithms in order to reduce the time and effort required for computation, especially in the field of astronomy, where it was often necessary to carry out long and tedious calculations involving very large numbers. The contributions of Napier and Briggs led to the development in 1620 of a precursor to the slide rule – the *Gunter scale*.

The Gunter scale was a *logarithmic scale* invented by Edmund Gunter as a navigational aid for mariners. The original scale consisted of a single length of metal or wood with markings etched into it at intervals, numbered from 1 to 10. The intervals were spaced in proportion to the logarithm of the number each represented. The distance between 1 and 2 is equal to 0.3 units; the distance between 1 and 4 is 0.6 units; that between 8 and 1 is 0.9 units; and so on. Navigators could make calculations involving multiplication and division using a "Gunter" (as it became known) and a set of dividers, or calipers.

In (circa) 1622 William Oughtred invented the earliest form of the slide rule, which was circular. The device utilises an inner ring, and an outer ring that can slide around each other. Each ring has an identical logarithmic scale engraved on it. The illustration below shows an instrument made by the Scottish instrument maker *Robert Davenport* based on a description in Oughtred's original Latin manuscript *Circles of Proportion and the Horizontal Instrument*, which he wrote in (circa) 1632, and which was later translated into English and eventually published by Oughtred's student William Forster in 1660.

Even though Oughtred's design was for a circular instrument, it was based on the principle of using two identical Gunter scales in tandem, by sliding one past the other in order to carry out calculations. The illustration below shows how we might use such a pairing to calculate the product of *two* and *four* (2 × 4). We start by sliding the upper scale to the right until the interval marked "1" on the upper scale lines up with the interval marked "2" on the lower scale. We then read off the value on the lower scale that is aligned with the interval marked "4" on the upper scale, which gives us the answer *eight* (8).

In fact, as you can see from the illustration, once we have aligned the "1" on the upper scale upper scale with the "2" on the lower scale, we can read off the value of two multiplied by *any* value up to and including five (5) by finding that value on the upper scale and reading off the corresponding value on the lower scale. Which raises another question: how do we multiply two by a value that is *greater* than five? Suppose, for example, we want to multiply two by seven (2 × 7)?

When the "1" on the upper scale is aligned with the "2" on the lower scale, the "7" on the upper scale is not aligned with anything at all. We get around the problem by aligning the "10" on the upper scale (i.e. the right-hand index of the upper scale) with the "2" on the lower scale instead. This means that any value we read off on the lower scale will be *one tenth* of the value we are looking for. As you can see, the "7" on the upper scale corresponds to a value of 1.4 on the lower scale. All we need to do to get the correct result is move the decimal point one place to the right.

Finding the quotient of two numbers (i.e. dividing one number by another) is also relatively straightforward. Suppose, for example, we want to divide *five* by *two* (5 ÷ 2). We move the "2" on the upper scale so that it lines up with the "5" on the lower scale. We then read off the result on the lower scale by finding the value that corresponds to the "1" on the upper scale, which in this case is 2.5.

We can manipulate the scales in various ways to find the sum and quotient of any two numbers, regardless of how big or how small they are. Once we have a result, we just need to determine where the decimal point goes. This is often a matter of mentally calculating an *approximate* result so that we know how far to the left or the right we need to shift the decimal point in the value read from the slide rule in order to get the correct answer.

The slide rule gradually evolved from a simple pairing of Gunter scales into a somewhat more sophisticated instrument. In 1654, it began to look more like the slide rule we are familiar with today, when the English instrument maker and inventor *Robert Bissaker* (1620-1685) made a slide rule consisting of three parallel rules. The two outer rules were fixed with respect to one another. Between them was an inner sliding rule.

In 1775, the English mathematician *John Robertson* (1712-1776) produced the first slide rule to have a *runner* (or *cursor*). Robertson's cursor took the form of a simple sliding brass rectangle mounted on top of the scales. The cursor later evolved into a sliding window made of glass or plastic, with a line etched into it that ran perpendicular to the scales. The cursor serves as both a placeholder and as a method of transferring settings from one scale to another.

n 1851, French army officer *Amédée Mannheim* (1831-1906) created what was essentially to become the standard version of the slide rule, and one that has endured with only minor modifications up until the present day. Mannheim's instrument was designed as a general-purpose slide rule for making all kinds of scientific and engineering calculations. It had all of the characteristics so far described, including two fixed parallel rules, one sliding rule, and a cursor (Mannheim's slide rule had a much thinner cursor than Robertson's, allowing more of the scales to be seen).

The illustration above shows a French-made Mannheim slide rule dating from some time in the late nineteenth century CE. The main innovation introduced by Mannheim was the arrangement of the scales (see below). Each of the fixed parallel rules had a scale on its inside edge. The sliding rule, which lay between them, had a scale on each of its outer edges, with each scale corresponding to the scale on the fixed rule to which it was adjacent.

The two outermost scales are designated as **A** and **D**, while the scales on the sliding rule are designated **B** and **C**. Scales **A** and **B** are *double decade* scales, and are used for finding squares and square roots. Scales **C** and **D** are *single decade* scales, and are used for multiplication and division (*single decade* scales range from 1 to 10 over the length of the slide rule, whereas *double decade* scales range from 1 to 100).

From 1851 until the latter half of the twentieth century, many variants of Mannheim's slide rule emerged, but the underlying format remained the same. Additional scales were added to allow the calculation of cubes and cube roots, logarithms and exponentials, trigonometric functions, reciprocals, and various other functions. Slide rules became available that had additional scales on their reverse side. These instruments became known as *duplex* slide rules (slide rules with scales on one side only are referred to as *simplex* slide rules).

Towards the end of the eighteenth century, the slide rule became an essential tool for engineers and scientists, and would remain so until the late 1970s. It enabled calculations to be made quickly, and with a precision of between two and three significant digits, depending on the skill of the user and the ease with which the scales could be read (this could vary somewhat, depending on the quality of the instrument – good quality slide rules were quite expensive).

The slide rule was essentially a versatile and highly portable analogue computing device that did not require batteries or a power source. On the down side, its accuracy was limited in comparison with the digital electronic calculators that would eventually replace it. Learning to use a slide rule could also be a daunting proposition, because it required at least a basic understanding of the mathematical principles involved.

The first hand-held pocket calculator was Hewlett Packard's HP-35, which first appeared on the market in 1972 and retailed for just under four hundred dollars. Although still beyond the reach of most students at that time, the HP-35 signalled the imminent demise of the slide rule. It was far more accurate, much easier to use, and just as portable. Prices fell rapidly as more and more manufacturers brought their products onto the market, and within a few short years the slide rule had become virtually obsolete.

_{This article was first published on TechnologyUK.net in October, 2019.}

History of Computing

Chris Wells, September 26, 2022

Chris Wells, September 26, 2022

The Scottish mathematician John Napier (1550-1617) is primarily known for his discovery of logarithms, which led to the development of, among other things, the slide rule. He is however also frequently remembered for his invention, in 1617, of a calculating device that could be used to simplify the multiplication and division of large numbers. Napier's device, which came to be known as "Napier's Bones", consists of a set of bone-like rods, usually made of wood or ivory, that have a series of numbers engraved on all four sides as shown below.

The rods are usually mounted on a baseboard consisting of a wooden frame with a raised edge that serves to hold the rods in place while a calculation is being made. The illustration below shows a complete set of rods in their frame. The left-most column holds the rod that displays the numbers 1 to 9, in ascending order, from top to bottom (this rod is sometimes referred to as the *ruler*, and is often incorporated into the baseboard itself as a fixed column).

The remaining rods can be arranged in any order, depending on the calculation being carried out. Each side of each rod is divided into nine squares, the top-most of which holds a single digit number. Each of the squares below it holds a *multiple* of that number, starting with double, then triple, then quadruple, and so on. The number shown in the bottom square has nine times the value of the number in the top-most square.

Note that all of the multiples are shown as two-digit numbers. Leading zeros are used where necessary to facilitate this. The first digit of each number appears in the top left-hand corner of its square, and the second digit appears in the bottom right-hand corner. The two digits are separated by a diagonal line that divides the square into two triangles, forming diagonal number pairings between adjacent squares.

Napier described various devices to be used for simplifying arithmetic calculations, including the rods already dubbed "Napier's Bones", in a publication entitled *Rabdologiæ*, written in Latin and published in Edinburgh in 1617 (the year of Napier's death). In order to demonstrate how Napier's device is used, let's work through an example by finding the product of two relatively large numbers. Suppose we wish to find the value of the following expression:

689,345 x 7,394

Now, I know that there are people who can do this kind of multiplication in their heads, but they are far and few between (and I'm certainly not one of them). Most of us, when faced with a problem of this nature, would reach for a calculator or, in the absence of a calculator, grab a pencil and a piece of paper and work out the answer by hand (assuming we remember how to do long multiplication!).

So how do we perform a calculation like this using Napier's Bones? The first thing we do is to select a set of rods whose topmost squares contain all of the digits in our first multiplicand (6, 8, 9, 3, 4 and 5), and place them into the frame adjacent to the ruler. They should appear in the correct order so that they represent the number 689,345, as shown in the following illustration:

Now we read off four values – one for each of the digits in our second multiplicand (7, 3, 9 and 4). We'll start with the least significant digit, which is 4. The order in which you proceed is not really important, as long as you keep track of how many zeros you need to add to the result for each row (see below).

Proceed by writing down the sum of each *diagonal pair* of digits in row four, from left to right (the first and last digits in each row are not diagonally paired with any other digits, so just write them down as they are). You should get the following result:

2,757,380

This result is constructed as follows:

2, 4+3, 2+3, 6+1, 2+1, 6+2, 0

Now repeat the procedure for the next least significant digit (9), and *add a zero* to the end of the resulting number. This time, you will encounter several instances where the sum of a diagonal pairing is greater than ten. Wherever this occurs, subtract ten from the result and carry one to the left. You should get the following result:

62,041,050

Repeat the procedure for the remaining two digits (3 and 7), adding *two* and *three* additional zeros, respectively, to the results. You should get the following:

206,803,500

and

4,825,415,000

As you may have guessed, we get the answer we are seeking by adding the four intermediate results together:

+ 0,002,757,380

+ 0,062,041,050

+ 0,206,803,500

+ 4,825,415,000

= **5,097,016,930**

= 1,012,110,100

If you check the result with a calculator, you will see that the answer (5,097,016,930) is correct. When you think about it, what we have done here is not all that different from the long multiplication we all learned in school. The main difference is that the task of finding the intermediate results to be added together should be significantly easier, once you get comfortable with using Napier's Bones.

An experienced user can also find the quotient of two numbers using Napier's Bones, although the procedure is somewhat different to the procedure we used for multiplication. It does, nevertheless, eliminate much of the hard work involved in manually carrying out long division. A later refinement of Napier's Bones made it possible to extract the square root of a number by utilising a special three-column rod specifically designed for that purpose in place of the standard ruler.

In the context of computing, the real significance of Napier's Bones lies in the fact that they demonstrate the potential for mechanical devices to exploit the deeper relationships that exist between numbers in order to simplify, and to some extent automate, the process of carrying out complex calculations. We're not finished with Napier yet, however. The next article in this series looks at the *slide rule*, another mechanical computing device that was based on Napier's discovery of *logarithms*.

_{This article was first published on TechnologyUK.net in October, 2019.}

History of Computing

Chris Wells, September 25, 2022

Chris Wells, September 25, 2022

The idea of "computing" – in the broadest sense of the word – is not new. Even in prehistoric times, human beings would have used various methods, including the use of fingers and toes, to count things like the number of sheep or cattle they owned. When the numbers involved were greater than the number of fingers and toes available, or when a more permanent record of some kind was needed, other methods had to be found. Such methods included the use of small stones or pebbles for counting, and the use of notched sticks or knotted chords for recording a quantity.

The Incas used accounting systems that employed ropes and pulleys. These systems were probably the earliest form of binary computer, and used knots in the ropes to represent the binary digits. They were used for tax and government records, and stored information about all of the resources of the Inca Empire, allowing efficient allocation of resources in response to disasters such as storms, drought, and earthquakes. All but one of these systems was destroyed by Spanish soldiers acting on the instructions of Catholic priests, who believed that they were the work of the Devil.

Probably the first serious effort to build computing machines was made by the Greeks, who built analogue and digital computing devices that used intricate gear systems, although they were subsequently abandoned as being impractical. One computing device that *has* survived, despite having its origins in the ancient world, is the *counting frame*, more commonly known as the *Abacus*. Not only have numerous examples of this device survived, it is still in use today in one form or another in many parts of the world.

Opinions seem to differ as to when and where the abacus first came into being. There is certainly evidence to suggest that various forms of *counting board* were in use in some parts of the world thousands of years ago. The counting board was a simple counting device, usually made from stone or wood. These boards usually had shallow grooves to accommodate small pebbles or beads. The grooves were usually accompanied by markings that indicated the magnitude of the values they represented.

The oldest surviving example of a counting board, the *Salamis Tablet*, was discovered on the Greek island of Salamis in 1899 and is thought to date from around 300 BCE. It currently resides in the Epigraphical Museum in Athens. Constructed from marble and with approximate dimensions of 150 x 75 x 4.5 centimeters, it can hardly be considered a portable computing device. Indeed, it is not entirely clear whether or not it would have been used for carrying out calculations or, as some sources suggest, as some kind of gaming board.

There is evidence to suggest that counting boards were used by the Persians from around 600 BCE, and by the Greeks from approximately 500 BC. These devices were undoubtedly the precursor to the abacus. According to the Greek historian Herodotus (circa 484 – 425 BCE), counting boards were also in use in ancient Egypt.

The earliest use of a counting *frame* (as opposed to a counting *board*) probably occurred in China, where its use is recorded in documentation dating from the 2nd century BCE. The Chinese abacus (or *suanpan*) has a rectangular wooden frame, with a number of bamboo rods (usually seven or more) mounted vertically within the frame.

As you can see from the illustration, a horizontal bar divides the frame into an upper deck and a lower deck. Each rod typically carries seven beads or discs – two on the upper deck and five on the lower deck. The beads in the upper deck are sometimes referred to as "heaven beads" and each bead has a value of *five* (5). Those in the lower deck may be referred to as "earth beads" or "water beads", and each has a value of *one* (1).

Each column, usually starting from the right-most column, represents successive powers of ten, starting with 10^{0} (i.e. 1). Calculations are carried out by moving beads towards or away from the horizontal bar. The result of a calculation is represented by the beads closest to the horizontal bar, on both decks, once the calculation has been completed. The number represented by the suanpan in the illustration is 70,710,678.

Those trained in the use of the suanpan can often carry out calculations involving large numbers just as quickly (and sometimes even faster!) than someone using a calculator. We’re not going to go into a lengthy session on how to use the device in this article, but we’ll look at a very simple example. Let’s suppose we want to add the numbers *seven* (7) and *two* (2).

We start by clearing the frame, which we do by placing it flat on an even surface and moving all of the beads *away* from the horizontal divider bar, so that all of the beads in the upper deck are moved as far as they will go towards the top of the frame, and all of the beads in the lower deck are moved as far as they will go towards the bottom of the frame. This is the equivalent of pressing the "clear" button on a calculator!

To perform the addition, we simply need to count the beads for the first number, then count the beads for the second number. To count the first number (7), we move one bead from the upper deck of the right-most column (the upper deck beads are worth five, remember) and two beads from the lower deck of the right-most column (each worth one) towards the bar.

To count the second number (2), we move a further two beads from the lower deck of the right-most column towards the bar.

We find the answer to a calculation by adding up the values of the beads adjacent to the bar in each column. In this case, only the first column is involved in the calculation. We have one bead in the upper deck worth *five* (5), and four beads in the lower deck worth *one* (1) each, giving a total of *nine* (9). This example is admittedly quite trivial, and one that you could undoubtedly do in your head, but it demonstrates the principle.

Subtraction can be carried out just as easily. If, for example, we want to subtract *three* (3) from the result of our previous calculation, we simply move three of the beads in the lower deck of the right-most column *away* from the bar. This leaves us with one bead in the upper deck worth *five* (5), and one bead in the lower deck worth *one* (1), giving a total of *six* (6) – which is the correct answer to *nine minus three* (9 – 3).

If a counting operation carried out during an addition results in a value of greater than *ten* (10) on any wire, a "carry" is accomplished by clearing beads from the upper and lower decks of the wire (the beads cleared should have a combined value of ten), and moving one bead from the lower deck of the wire immediately to the left of the affected wire towards the bar.

Many operations require an understanding of what are known as *complementary numbers*. In this instance, we are referring to any two numbers *less than ten* that, when added together, *add up to ten* (i.e. 9 + 1, 8 + 2, 7 + 3, 6 + 4 and 5 + 5). Suppose, for example, we want to add *three* and *eight* (3 + 8). First, we "reset" the abacus, then we set it to *three* by moving three beads in the lower deck from the 1’s column (the right-most wire) towards the bar.

We want to add *eight* to this number, so we start by *subtracting two* (two is the *complement* of eight) by moving two of the beads we originally moved *away* from the bar.

We complete the operation by moving one bead in the lower deck from the 10’s column (the second right-most wire) towards the bar. This leaves us with one bead from the 10’s column and one bead from the 1’s column on the bar, which represents a value of *eleven* (11) – the correct answer.

Archaeological evidence dating from the first century CE indicates that the Romans developed their own version of the abacus, although in the Roman version the beads ran in grooves rather than on wires. There are also historical sources from the same period indicating that counting frames were in use in India at around the same time.

The suanpan appears to have migrated from China to both Korea (where it is variously called a *jupan*, *jusan* or *supan*) and Japan (where it is known as a *soroban*) during the fifteenth and sixteenth centuries CE. A Russian version of the abacus (the *Schoty*) appeared around the end of the sixteenth century CE.

Counting frames of one kind or another were in widespread use in various parts of Western Europe up until around 1500. Use of the abacus in Europe and elsewhere declined rapidly with the adoption of the Hindu-Arabic numeral system, first developed in India some time between the first and fourth centuries CE and later adopted by Arab mathematicians.

The Hindu-Arabic system was a positional decimal numeral system that eventually became the most commonly used system for the symbolic representation of numbers worldwide, and the one we use today. It made record-keeping easier, and facilitated the use of algorithmic methods for performing calculations on paper that were simply more convenient than the use of a counting frame.

Nevertheless, use of the abacus for counting and making calculations continued in some parts of the world and, as we mentioned earlier, persists to this day. The abacus allows a wide range of numbers to be represented, and can be used to perform a range of mathematical operations – addition, subtraction, multiplication and division, and even the calculation of square roots. A skilled operator can often make such calculations faster than someone using a calculator or a slide rule.

One benefit of using an abacus is that, unlike performing calculations using a calculator or pen and paper, it is highly tactile and provides significant visual feedback to the user. For this reason, it is often used in pre-school and elementary education to introduce children to number systems and basic mathematical concepts. Indeed, if you visit your local toy shop, you will probably find an abacus being sold as an educational children’s toy.

_{This article was first published on TechnologyUK.net in October, 2019.}