Ada Lovelace: What did the first computer program do?

Celebrated on what would be her 197th birthday, Ada Lovelace is widely credited as having written the first computer program. What did Lovelace's program do? 

Courtesy of Marcin Wichary/Computer History Museum
This full-scale model of Charles Babbage's Difference Engine No. 2, designed, but never actually built, in the late 1840s, weighs 5 tons, is 11 feet long and seven feet high, and has 8,000 parts.

The British Romantic poet Lord Byron is a hero among Greeks, having volunteered in the country's war of independence against the Ottoman Empire in the 1820s. Two decades later, Byron's daughter would become a hero among geeks, having drafted what is today considered the very first computer program. 

Her feat is all the more impressive considering that, in the 1840s, there weren't actually any computers. Back then, the word 'computer,' which first appears in English in the early 1600s, meant a person whose job it was to perform calculations. 

Instead, Lovelace, who is celebrated on Google's homepage today on what would be her 197th birthday, wrote her program on a hypothetical computer, one that had been developed by the British mathematician and engineer Charles Babbage

Babbage first came up with his idea in 1812, when looking at tables of logarithms that had been tabulated by human computers. The tables were, Babbage observed, riddled with errors. Taking a cue from methods developed by the French government, in which logarithmic tables were created by roomfuls of workers performing simple addition and subtraction, overseen by mathematicians who had broken down the process into simple steps, Babbage envisioned the work being performed by a fast, reliable machine.

He convinced his own government to bankroll his 'Difference Engine,' as he called it. But after ten years and some £17,000 of public money, Babbage's machine, which was designed to tabulate logarithms and trigonometric functions, remained only half built. So he did what any good visionary would do: He scrapped the plans in favor of something more ambitious. 

The Analytical Engine, which, like the Difference Engine, existed mostly on paper during Babbage's lifetime, was envisioned as a general calculating device. The user would input punched cards into the machine, which would be processed by rotating barrels. The machine would output to a printer, a plotter, or a ringing bell. (Babbage was inspired by the Jacquard loom, which used punched cards to "program" certain weaves, such as a brocade or a damask.)

The design of the Analytical Engine is nothing like that of today's MacBook, but it has all the basic architecture. It distinguished between program memory and data memory. It had a separate input/output unit. It accepted conditional "if/then" expressions.

Of course, the average laptop is millions of times more powerful. According to John Graham-Cumming, a British programmer and writer who is seeking to build a real-life Analytical Engine, the machine would have 675 bytes of memory and a clock speed of 7 Hz.  Graham-Cumming told the BBC that if completed, Babbage's machine would be "about the size of a small steam train."  

The Analytical Engine was a lifelong passion for Babbage; he tinkered with designs until the end of his life, in 1871. But it took a young mathematician with a storied family history to grasp the full potential of Babbage's machine.

Lord Byron never knew Ada. He abandoned her and her mother, Annabella Milbanke, when his daughter was only a few months old, and he died when she was eight. Annabella, intent on discovering traces of Byron's volatile personality in his offspring, subjected Ada to intensive schooling in science and mathematics from a young age.

Ada showed remarkable talent in math, and by the time she was seventeen she was introduced to Charles Babbage, who called her "The Enchantress of Numbers."

Ada, who in 1838 became the Countess of Lovelace corresponded with Babbage about his Difference and Analytical engines, and, in 1842 and 1843, she translated an essay about the Analytical Engine by the Italian statesman and mathematician Luigi Menabrea.

Lovelace's notes on Menabrea's essay, which attempt to explain what the Analytical Engine is and why it is important, are longer than the actual essay itself. Note G describes, in very detailed steps, how one could use punch cards to make Babbage's engine calculate a sequence of Bernoulli numbers. Historians of science regard Note G as containing the very first computer program, making Lovelace the first programmer. 

But equally important was Lovelace's recognition of what the Analytical Engine really was: not a mere steampunk abacus, but a device that can process data of any kind, and perhaps even reason. She wrote:

You've read  of  free articles. Subscribe to continue.
Real news can be honest, hopeful, credible, constructive.
What is the Monitor difference? Tackling the tough headlines – with humanity. Listening to sources – with respect. Seeing the story that others are missing by reporting what so often gets overlooked: the values that connect us. That’s Monitor reporting – news that changes how you see the world.

Dear Reader,

About a year ago, I happened upon this statement about the Monitor in the Harvard Business Review – under the charming heading of “do things that don’t interest you”:

“Many things that end up” being meaningful, writes social scientist Joseph Grenny, “have come from conference workshops, articles, or online videos that began as a chore and ended with an insight. My work in Kenya, for example, was heavily influenced by a Christian Science Monitor article I had forced myself to read 10 years earlier. Sometimes, we call things ‘boring’ simply because they lie outside the box we are currently in.”

If you were to come up with a punchline to a joke about the Monitor, that would probably be it. We’re seen as being global, fair, insightful, and perhaps a bit too earnest. We’re the bran muffin of journalism.

But you know what? We change lives. And I’m going to argue that we change lives precisely because we force open that too-small box that most human beings think they live in.

The Monitor is a peculiar little publication that’s hard for the world to figure out. We’re run by a church, but we’re not only for church members and we’re not about converting people. We’re known as being fair even as the world becomes as polarized as at any time since the newspaper’s founding in 1908.

We have a mission beyond circulation, we want to bridge divides. We’re about kicking down the door of thought everywhere and saying, “You are bigger and more capable than you realize. And we can prove it.”

If you’re looking for bran muffin journalism, you can subscribe to the Monitor for $15. You’ll get the Monitor Weekly magazine, the Monitor Daily email, and unlimited access to

QR Code to Ada Lovelace: What did the first computer program do?
Read this article in
QR Code to Subscription page
Start your subscription today