Babbage, Lovelace and the Engine

In the 1830s Charles Babbage designed a general-purpose computer made of brass and steam. Ada Lovelace saw further than anyone what such a machine could do — and set out the first famous objection to machine intelligence. Meanwhile George Boole turned logic into algebra.

In 1843 a 27-year-old Englishwoman published a translation of an Italian engineer’s article about a machine that did not exist. Her own notes ran to roughly three times the length of the original. In them she described how the machine could be instructed, step by step, to calculate a difficult sequence of numbers; imagined it composing music; and warned that it could never “originate” anything. More than a century later, Alan Turing devoted a section of his most famous paper to answering her. The woman was Ada Lovelace, and the machine was Charles Babbage’s Analytical Engine.

Babbage’s engines

Charles Babbage (1791–1871) was a Cambridge mathematician with a grievance: the printed tables of logarithms and astronomical values that navigators, engineers and bankers relied on were full of errors, because they were calculated and copied by hand. In 1822 he proposed a machine to compute and print such tables automatically. Over the next decades he designed two very different engines.

A special-purpose calculator (from 1822). The Difference Engine used the “method of finite differences”, a trick that lets you produce a table of polynomial values using nothing but repeated addition. Addition is easy to do with gear wheels, so the whole machine could be built from columns of geared digits.

The British government put about £17,000 into the project — a huge sum at the time — but after disputes with his chief engineer, Joseph Clement, work stopped in 1833, and the government formally abandoned it in 1842. Only a demonstration section was assembled. Babbage later designed an improved Difference Engine No. 2; London’s Science Museum built its calculating section from his drawings in 1991, and it worked.

Lovelace’s Notes (1843)

Augusta Ada King, Countess of Lovelace (1815–1852), was the only legitimate child of the poet Lord Byron, whose marriage to her mother broke up when she was a baby. Her mother, determined to steer her away from her father’s temperament, had her schooled in mathematics; later she studied with the logician Augustus De Morgan. She met Babbage in 1833, at seventeen, saw a demonstration piece of the Difference Engine, and began a long friendship and correspondence with him.

In 1840 Babbage described the Analytical Engine to scientists in Turin. A young Italian engineer, Luigi Menabrea (later prime minister of Italy), wrote up the lectures in French in 1842. Lovelace translated his article into English and, encouraged by Babbage, added seven notes labelled A to G. They were published in 1843 in Richard Taylor’s Scientific Memoirs, signed only with her initials, “A.A.L.”

The final note, Note G, set out in detail how the Engine could calculate the Bernoulli numbers, a sequence important in mathematics, as a table of operations: which variables to use, which operation to perform, and where to store each result, including a repeated loop. Consensus It is widely described as the first computer program published in print — though, as we shall see, whether it was the first program written, and whose program it was, is another matter.

What made the Notes remarkable was not only the program but the vision. Lovelace grasped that the Engine manipulated symbols, not just numbers. If the relationships between musical notes could be expressed in its notation, she wrote, the Engine “might compose elaborate and scientific pieces of music of any degree of complexity or extent.” She put the comparison with the loom memorably:

“The Analytical Engine weaves algebraical patterns just as the Jacquard-loom weaves flowers and leaves.”Ada Lovelace, Note A (1843)

That leap — from a calculating machine to a general symbol-manipulating machine — is exactly the leap that would later make AI possible.

“Lady Lovelace’s objection”

Lovelace was equally careful to say what the Engine could not do. In Note G she warned against overrating it:

“The Analytical Engine has no pretensions whatever to originate anything. It can do whatever we know how to order it to perform.”Ada Lovelace, Note G (1843)

In his 1950 paper “Computing Machinery and Intelligence”, Alan Turing listed this as one of the main objections to the idea of thinking machines and called it “Lady Lovelace’s Objection”. He answered it in two ways. First, he said, machines surprise him constantly, because he cannot foresee every consequence of the instructions he gives. Second — and more importantly — a machine that learns from experience could end up doing things its programmer never directly ordered. Turing also noted, fairly, that Lovelace was writing about the Engine she knew, and that her statement was not a claim about all possible machines.

The objection is still alive. When a large language model writes a poem, is it originating anything, or recombining patterns from its training data in ways its makers set up? The modern form of Lovelace’s question is one of the most interesting debates in AI.

How much credit does she deserve?

Debated Lovelace has become an icon: “the first computer programmer”, with a programming language (Ada, 1980) and an international day named after her. Historians disagree sharply about how far the title is earned. Explore both cases.

The question

Was Ada Lovelace the first computer programmer?

Choose one to hear its case.

Other views
  • Pioneer of programming: Lovelace wrote the first published program and saw the general nature of computing; the title fits.
  • Interpreter, not originator: Babbage invented both the machine and its earliest programs; Lovelace was a gifted explainer whose role has been inflated by later mythmaking.
  • Visionary rather than “programmer”: a middle view held by many historians — the program matters less than her conceptual leap to a general symbol-processing machine, and it is that, not a title, for which she deserves credit.

Boole’s laws of thought

While Babbage worked on engines, a self-taught schoolmaster from Lincoln was mechanising logic on paper. George Boole (1815–1864), later professor of mathematics at Queen’s College, Cork, in Ireland, argued that the laws of reasoning could be written as algebra. In The Mathematical Analysis of Logic (1847) and then An Investigation of the Laws of Thought (1854), he treated statements as quantities that could only be 1 (true) or 0 (false), and combined them with operations we now call AND, OR and NOT.

Boole did not build a machine, but his algebra became the language of every digital circuit. In 1937 a young student named Claude Shannon showed in his master’s thesis that Boolean algebra could describe — and design — networks of electrical switches. Every chip in your phone performs Boolean logic billions of times a second. And Boole’s ambition, to capture the “laws of thought” in symbols, became the founding ambition of symbolic AI.

Quick check

What made the Analytical Engine general-purpose, unlike the Difference Engine?

The Difference Engine did one fixed job. The Analytical Engine could follow any program written in its card language.

In Note G, what did Lovelace say the Engine could not do?

She wrote that it could only do what “we know how to order it to perform”. Turing called this Lady Lovelace’s Objection.

Whose work turned logic into algebra with values 1 and 0?

Boole’s Laws of Thought (1854) built on his 1847 work; De Morgan was a fellow logician and Lovelace’s tutor.

// Pause and reflect

  1. Lovelace said the Engine can do only what we know how to order it to do. Does a system that learns from data escape her objection, or just move it one step back?
  2. Why do you think the story of “the first programmer” became so popular? What does the debate tell you about how history chooses its heroes?
  3. Babbage’s machines were never finished. What, if anything, does an unbuilt design contribute to the history of technology?

Your notes are saved privately in this browser.

What happened next

Babbage’s engines faded from view, and the idea of a general-purpose machine had to be rediscovered from scratch. In 1936 a young Cambridge mathematician defined, on paper, a machine so simple and so general that it captured the very idea of computation. Continue with Alan Turing.

Key terms on this page

Sources & further reading