Babbage's Letter to Sir Humphry Davy

Babbage's Letter to Sir Humphry Davy, July 3rd, 1822

Letter to Sir Humphry Davy, Bart, President of the Royal Society, &c.&c. On the Application of Machinery to the Purpose of Calculating and Printing Mathematical Tables, from Charles Babbage, Esq. M.A. F.R.S. Lond. and Edin., Member of the Cambridge Philosophical Society, Secretary of the Astronomical Society of London, and Correspondent of the Philomathic Society of Paris. 4to 12pp Baldwin & Co. 1822.

July 3, 1822

My Dear Sir,

The great interest you have expressed in the success of that system of contrivances which has lately occupied a considerable portion of my attention, induces me to adopt this channel for stating more generally the principles on which they proceed, and for pointing out the probable extent and important consequences to which they appear to lead. Acquainted as you were with this inquiry almost from its commencement, much of what I have now to say cannot fail to have occurred to your own mind: you will, however, permit me to restate it for the consideration of those with who the principles and the machinery are less familiar.

The intolerable labour and fatiguing monotony of a continued repetition of similar arithmetical calculation, first excited the desire and afterwards suggested the idea, of a machine, which, by the aid of gravity or any other moving power, should become a substitute for one of the lower operations of human intellect. It is not my intention in the present Letter to trace the progress if this idea, or the means which I have adopted for its execution; but I propose stating some of their general applications, and shall commence with describing the powers of several engine which I have contrived: of that part which is already executed I shall speak more in the sequel.

The first engine of which drawings were made was one which is capable of computing any table by the aid of differences, whether they are positive or negative, or of both kinds. With respect to the number of the order of differences, the nature of the machinery did not in my opinion, nor in that of a skilful mechanic, whom I consulted, appear to be restricted to any very limited number; and I should venture to construct one with ten or a dozen orders with perfect confidence. One remarkable property of this machine is, that the greater the number of differences the more the engine will outstrip the most rapid calculator.

By the application of certain parts of no great degree of complexity, this may be converted into a machine for extracting the roots of equations, and consequently the roots of numbers: and the extent of the approximation depends on the magnitude of the machine.

Of a machine for multiplying any number of figures (m) by any other number (n), I have several sketches; but it is not yet brought to that degree of perfection which I should wish to give it before it is to be executed.

I have also certain principles by which, if it should be desirable, a table of prime numbers might be made, extending from 0 to ten millions.

Another machine, whose plans are much more advanced than several of those just named, is one for constructing tables which have no order of difference constant.

A vast variety of equations of finite differences may by its means be solved, and a variety of tables, which could be produced in successive parts by the first machine I have mentioned, could be calculated by the latter one with a still less exertion of human thought. Another and very remarkable point in the structure of this machine is, that it will calculate tables governed by laws which have not been hitherto shown to be explicitly determinable, or that it will solve equations for which analytical methods of solution have not yet been contrived.

Supposing these engines executed, there would be wanting other means to ensure the accuracy of the printed tables to be produced by them.

The errors of the persons employed to copy the figures presented by the engines would first interfere with their correctness. To remedy this evil, I have contrived means by which the machines themselves shall take from several boxes containing type, the numbers which they calculate, and place them side by side, thus becoming at the same time a substitute for the compositor and the computer: by which means all errors in copying as well as in printing is removed.

There are, however, two sources of error which have not yet been guarded against. the ten boxes with which the engine is provided contain each about three thousand types; any box having of course, only those of one number in it. It may happen that the person employed in filling these boxes shall accidentally place a wrong type in some of them; as for instance, the number 2 in the box which ought to contain 7's. When these boxes are delivered to the superintendent of the engine, I have provided a simple and effectual means by which he shall, in less than half an hour, ascertain whether, amongst these 30,000 types, there be any individual misplaced, or even inverted. The other cause of error to which I have alluded, arises from the type falling out when the page has been set up: this I have rendered impossible by means of a similar kind.

The quantity of errors from carelessness in correcting the press, even in tables of the greatest credit, will scarcely be believed, except by those who have had constant occasion for their use. A friend of mine whose skill in practical as well as theoretical astronomy is well known, produced to me a copy of the tables published by order of the French Board of Longitude, containing those of the Sun by Delambre, and of the Moon by Burg, in which he had corrected above five hundred errors: most of these appear to be errors of the press; and it is somewhat remarkable, that in turning over the leaves in the fourth page I opened we observed a new error before unnoticed. These errors are so much more dangerous, because independent computers using the same tables will agree in the same errors.

To bring to perfection the various machinery which I have contrived would require an expense of both time and money, which can be known only to those who have themselves attempted to execute mechanical inventions. Of the greater part of that which has been mentioned, I have at present contented myself with sketches on paper, accompanied by short memorandums, by which I might at any time more fully develop the contrivances; and where any new principles are introduced, I have had models executed, in order to examine their actions. For the purpose of demonstrating the practicability of these views, I have chosen the engine for differences, and have constructed one of them, which will produce any tables whose second differences are constant. Its size is the same as that which I should propose fora any more extensive one of the same kind: the chief difference would be, that in one intended for use there would be greater repetition of the same parts in order to adapt it to the calculation of a larger number of figures. Of the action of this engine, you have yourself had opportunities of judging, and I will only at present mention a few trials which have since been made by some scientific gentlemen to whom it has been shown, in order to determine the rapidity with which it calculates. The computed table is presented to the eye at two opposite sides of the machine; and a friend having undertaken to write down the numbers as they appeared, it proceeded to make a table from the formula x2+x+41. In the earlier numbers my friend, in writing quickly, rather more than kept pace with the engine; but as soon as four figures were required, the machine was at least equal in speed to the writer.

In another trial it was found that thirty numbers of the same table were calculated in two minutes and thirty seconds: as these contained eighty-two figures, the engine produced thirty-three every minute.

In another trial it produced figures at the rate of forty-four in a minute. As the machine may be made to move uniformly by a weight, this rate might be maintained for any length of time, and I believe few writers would be found to copy with equal speed for many hours together. Imperfect as the first machine generally is and suffering as this particular one does from great defect in the workmanship, I have every reason to be satisfied with the accuracy of its computations; and by the few skilful mechanics to whom I have in confidence shown it, I am assured that its principles are such that it may be carried to any extent. In fact, the parts of which it consists are few but frequently repeated, resembling in this respect the arithmetic to which it is applied, which, by the aid of a few digits often repeated, produces all the wide variety of number. The wheels of which it consists are numerous, but few move at the same time; and I have employed a principle by which any small error that may arise from accident or bad workmanship is corrected as soon as it is produced, in such a manner as effectually to prevent any accumulation of small errors from producing a wrong figure in the calculation.

Of those contrivances by which the composition is to be effected, I have made many experiments and several models; the results of these leave me no reason to doubt of success, which is still further confirmed by a working model that is just finished.

As the engine for calculating tables by the method of differences is the only one yet completed, I shall, in my remarks on the utility of such instruments, confine myself to a statement of the powers which that method possesses.

I would however premise, that if any one shall be of opinion, notwithstanding all the precaution I have taken and means I have employed to guard against the occurrence of error, that it may still be possible for it to arise, the method of differences enables me to determine its existence. Thus if proper numbers are placed at the outset in the engine, and if it has composed a page of any kind of table, then by comparing the last number it has set up with that number previously calculated, if they are found to agree, the whole page must be correct: should any disagreement occur it would scarcely be worth looking for its origin, as the shortest plan would be to make the engine recalculate the whole page, and nothing would be lost but a few hours' labour of the moving power.

Of the variety of tables which such an engine could calculate, I shall mention but a few. The tables of powers and products published at the expense of the Board of Longitude, and calculated by Dr. Hutton, were solely executed by the method of differences; and other tables of the roots of numbers have been calculated by the same gentleman on similar principles.

As it is not my intention to enter into the theory of differences, a field far too wide for the limits of this letter, and which will probably be yet further extended in consequence of the machinery I have contrived, I shall content myself with describing the course pursued in one of the most stupendous monuments of arithmetic calculation which the world has yet produced, and shall point out the mode in which it was conducted, and what share of mental labour would have been saved by the employment of such an engine as I have contrived.

The tables to which I allude are those calculated under the direction of M. Prony, by order if the French Government, -a work which will ever reflect the highest credit on the nation which patronized and on the scientific men who executed it. The tables computed were the following.

1. The natural sines of each 10,000 of the quadrant calculated to twenty-five figures with seven or eight orders of differences.

2. Thew logarithmic sines of each 100,000 of the quadrant calculated to fourteen decimals with five orders of differences.

3. The logarithm of the ration of the sines to their arcs of the first 5,000 of the 100,000ths of the quadrant calculated to fourteen decimals with three orders of differences.

4. The logarithmic tangents corresponding to the logarithmic sines calculated to the same extent.

5. The logarithms of the ratios of the tangents to their arcs calculated in the same manner as the logarithms of the ratios of the sines to their arcs.

6. The logarithms of numbers from 1 to 10,000 calculated to nineteen decimals.

7. The logarithms of all numbers from 10,000 to 200,000 calculated to fourteen figures with five orders of differences.

Such are the tables which have been calculated, occupying in their present state seventeen large folio volumes. It will be observed that the trigonometrical tables are adapted to the decimal system, which has not been generally adopted even by the French, and which has not been at all employed in this country. But, notwithstanding this objection, such was the opinion entertained of their value, that a distinguished member of the English Board of Longitude was not long since commissioned by our Government to make a proposal to the Board of Longitude of France to print an abridgement of these tables at the joint expense of the two countries; and five thousand pounds were named as the sum our Government was willing to advance for this purpose. It is gratifying to record this disinterested offer, so far above those little jealousies which interfere between nations long rivals, and manifesting so sincere a desire to render useful to mankind the best materials of science in whatever country they might be produced. Of the reasons why this proposal was declined by our neighbours, I am at present uniformed: but, from a personal acquaintance with many of the distinguished foreigners to whom it was referred, I am convinced that it was received with the same good feelings as those which dictated it.

I will now endeavour shortly to state the manner in which this enormous mass of computation was executed; One table of which (that of the logarithms of numbers) must contain about eight millions of figures.

The calculators were divided into three sections. The first section comprised five or six mathematicians of the highest merit, amongst whom were M. Prony and M. Legendre. These were occupied entirely with the analytical part of the work; they investigated and determined on the formulae to be employed.

The second section consisted of seven or eight skilful calculators habituated both to analytical and arithmetical computations. These received the formulae from the first section, converted them into numbers and furnished to the third section the proper differences at the stated intervals.

They also received from that section the calculated results, and compared the two sets, which were computed independently for the purpose of verification.

The third section on whom the most laborious part of the operations devolved, consisted of from sixty to eighty persons, few of them possessing a knowledge of more than the first rules of arithmetic: these received from the second class certain numbers and differences, with which, by additions and subtractions in a prescribed order, they completed the whole of the tables above mentioned.

I will now examine what portion of this labour might be dispensed with, in case it should be deemed advisable to compute these or any similar tables of equal extent by the aid of the engine I have referred to.

In the first place, the labour of the first section would be considerably reduced, because the formulae used in the great work I have been describing have already been investigated and published. One person, or at the utmost two, might therefore conduct it.

If the persons composing the second section, instead of delivering the numbers they calculate to the computers of the third section, were to deliver them to the engine, the whole of the remaining operations would be executed by machinery, and it would only be necessary to employ people to copy down as fast as they were able the figures presented to them by the engine. If, however, the contrivances for printing were brought to perfection and employed, even this labour would be unnecessary, and a few superintendents would manage the machine and receive the calculated pages set up in type. Thus the number of calculators employed, instead of amounting to ninety-six, would be reduced to twelve. This number might, however, be considerably diminished, because when an engine is used the intervals between the differences calculated by the second section may be greatly enlarged. In the tables of logarithms M. Prony caused the differences to be calculated at intervals of two hundred, in order to save the labour of the third section: but as that would not devolve on machinery, which would scarcely move the slower for its additional burden, the intervals might properly be enlarged to three or four times that quantity. This would cause a considerable diminution in the labour of the second section. If to this diminution of mental labour we add that which arises from the whole work of the compositor being executed by the machine, and the total suppression of that most annoying of all literary labour, the correction of the errors of the press,1 I think I am justified in presuming that if engines were made purposely for this object, and were afterwards useless, the tables could be produced at a much cheaper rate; and of their superior accuracy there could be no doubt. Such engines would, however, be far from useless: containing within themselves the power of generating, to an almost unlimited extent, tables whose accuracy would be unrivalled, at an expense comparatively moderate, they would become active agents in reducing the abstract inquiries of geometry to a form and an arrangement adapted to the ordinary purposes of human society.

I should be unwilling to terminate this Letter without noticing another class of tables of the greatest importance, almost the whole of which are capable of being calculated by the methods of differences. I refer to all astronomical tables for determining the positions of the sun or planets: it is scarcely necessary to observe that the constituent parts of these are of the form a sin Q, where a is a constant quantity, and Q is what is usually called the argument. Viewed in this light they differ but little from a table of sines, and like it may be computed by the method of differences.

I am aware that the statements contained in this Letter may perhaps be viewed as something more than Utopian, and that the philosophers of Laputa may be called up to dispute my claim to originality. Should such be the case, I hope the resemblance will be found to adhere to the nature of the subject rather than to the manner in which it has been treated. Conscious, form my own experience, of the difficulty of convincing those who are but little skilled in mathematical knowledge, of the possibility of making a machine which shall perform calculations, I was naturally anxious, in introducing it to the public, to appeal to the testimony of one so distinguished in the records of British science. Of the extent to which machinery whose nature I have described may be carried, opinions will necessarily fluctuate, until experiment shall have finally decided their relative value: but of that engine which already exists I think I shall be supported, both by yourself and by several scientific friends who have examined it, in stating that it performs with rapidity and precision all those calculations for which it was designed.

Whether I shall construct a larger engine of this kind, and bring to perfection the others I have described, will in a great measure depend on the nature of the encouragement I may receive.

Induced, by a conviction of the great utility of such engines, to withdraw for some time my attention from a subject on which it has been engaged during several years, and which possess charms of a higher order, I have now arrived at a point where success is no longer doubtful. It must, however, be attained at a very considerable expense, which would not probably be replaced, by the works it might produce, for a long period of time, and which is an undertaking I should feel unwilling to commence, as altogether foreign to my habits and pursuits.

I remain, my dear Sir,

Faithfully yours,


Devonshire Street, Portland Place

July 3rd, 1822