STEAM Cafe - Ada Lovelace: First Computer Programmer
Good evening, everybody.
Hello.
Can everyone hear me OK?
Is the volume good?
Up, down?
Hello, you think?
OK.
Is that any better?
I think Dane turned it up a little bit.
OK.
I'm Angela Mettler.
I'm an administrative assistant in the president's office,
but also mine.
And I'd like to welcome you all to this month's STEAM Cafe.
STEAM Cafe is a collaboration between Salt-N-Soda Mines,
Cape Camp Brewing, and Salt-N-Soda Public Broadcasting.
So we thank them for their support as well.
And of course, all of you and anyone joining us online.
Couldn't do it without you.
We've been doing this since April of 2018.
It's the 3rd Tuesday.
So I'm not going to take too much time,
but I will introduce Dr. Erica Hausbeck.
She is an assistant professor in our humanities department.
OK.
So today I'm going to talk about research
that Duane Abada and I undertook for a couple years.
And then we presented it at the American Society
for Engineering Education.
And it's on Ada Lovelace's Victorian Computer Program.
So Ada Lovelace was previously a little-known historical figure.
But in the past 15 years or so, her reputation has been rising.
In part because of the establishment of Ada Lovelace Day.
And this year, that was last week on October 12th.
It's something like the first or second day in October.
Second Tuesday.
Ada Lovelace Day was founded by Sue Herman Anderson in the United Kingdom
to raise the profile of women in science, technology, engineering, and math
by encouraging people around the world to talk about women in STEM.
Women whose work they admire.
So this is now an international day of celebration
that helps people learn about the achievements of women in STEM.
And it's meant to inspire others and create role models for women.
So, and this was...
The establishment of this day was inspired by Penelope Lockwood,
psychologist Penelope Lockwood's research.
She carried out a study that found that women need to see female role models
more than men need to see male role models.
So Ada Lovelace was chosen as, like, the woman.
One of the earliest women in STEM to be this sort of role model for women.
So since 2009, more people have been learning about Ada Lovelace.
There's a number of children's books about Ada Lovelace now.
So who was Ada Lovelace?
She was born Augusta Ada Byron,
and she later married Baron William King,
who became the Countess Lovelace through actually Ada's hereditary claim
to that aristocratic role.
She was born to Lord Byron, her father, and his wife.
She's the only legitimate child of Lord Byron.
Legitimate child is important because Byron had a number of illegitimate children.
So Augusta Ada King was the Countess of Lovelace,
and subsequently she's now become famous for perhaps being
the first Victorian computer programmer.
So her parents were actually really important to who she ended up being.
George Gordon Lord Byron, if you're not familiar with your British literature,
was a very famous romantic poet who was in fact infamous.
And he's widely considered to be the first celebrity of the 19th century.
So like tabloid-level celebrity.
He was a playboy with many sexual exploits with both men and women.
Many people knew about him.
He was also a lord, which meant that he was in the House of Parliament.
And Lord Byron did a number of things.
He was a great poet.
I recommend reading his poetry.
But he's also, as a lord in Parliament,
he was the only politician to speak in favor and support of the Luddites.
So has anyone heard the term Luddite before?
Okay, so what does Luddite mean?
Yes, someone who hates technology.
Someone who's vociferously anti-technology.
So Luddite actually comes from in the early 19th century, about 1812.
There were a bunch of weavers who violently protested the introduction of automatic looms.
So these were looms that were automating a lot of the process of weaving.
And the weavers got mad because it was their job.
Sound familiar?
So they broke the machines.
They smashed them.
They were called the frame breakers.
And the factory owners violently responded to this.
They shut down the strike.
And there were bloody riots.
And a number of these Luddites were hanged for protesting.
Byron was the only politician who said,
you know, they might have a point.
They might have a point that these machines are replacing their livelihood.
Maybe they have a right to be mad.
Most people in Parliament were like,
no, we should be on the side of the factory owners and shut this down.
It's terrible for half the world.
Now, Byron, who was known to be a very sexy dude,
it took him a while to settle down, but eventually he settled down with Annabella Milbank,
whom he married.
She was his polar opposite in all ways.
This marriage was not meant to succeed.
She was an extremely religiously devout and strict woman.
So, you know, Byron was known to be wild.
He was also often known for his manic moods.
It's widely believed that he probably had some kind of bipolar disorder.
His wife, on the other hand, was very strict, very beautiful.
And she and Byron did not ultimately get along.
They separated soon after Ada was born.
And so Ada never actually knew her father in person.
He left when she was about a month old,
and he died in three when she was eight years old.
So Lady Byron was violently estranged from her husband,
who she was very bitter about.
And she raised Ada.
Oh, I forgot to say.
Lady Byron was herself a mathematical prodigy.
So Byron called her his princess of the parallelogram,
you know, would write lovingly to her.
She was very good at math.
So when Byron, you know, left,
Lady Byron decided to raise their daughter with a strict and rigorous curriculum of math and science
to counteract any poetical tendencies that she may have inherited from her father.
Now, poetical tendencies doesn't just mean the great poetry that Byron wrote.
I think it's really a euphemism for his mental illness.
And it seems pretty clear that there was something running along the Byron line.
And Ada seems to have, I think she did actually inherit his bipolar disorder.
So, you know, this whole, this regime worked to create a brilliant, you know, proto-computer scientist.
It didn't actually work to alienate Ada from Byron.
She actually was very fond of Byron.
Byron sort of overshadowed her entire life.
She named her children after Byron and then chose to be buried next to Byron.
So, it, you know, a lesson in parenting, I guess.
So, our other person in this historical tale is Charles Babbage.
So, Babbage was, he was very rich.
And he was a socialite.
But he's not an aristocrat.
So, the Byrons are aristocrats.
In this time, this is important because this means they have political power.
Their nobility, this mattered in Britain at the time.
Babbage inherited a lot of manufacturing money.
And banking money.
He was a professor of mathematics at Cambridge.
And he was famous for being an inventor and an engineer.
A very good mathematician.
He often drew these huge forays with the intellectual elite of the day.
So, he knew everyone.
Charles Dickens, the Byrons.
You know, if you were anyone, you might be at one of Babbage's parties.
And at one of Babbage's parties, oops, sorry, I skipped that.
At one of Babbage's parties, this is where Ada Lovelace met Charles Babbage.
When she was 17 years old and he was 24 years older.
So, Babbage invented computers.
He came up with the idea for inventing a mechanical steam-powered computer.
When he was frustrated after finding multiple errors in manually calculated astronomical data.
At this time, when you had complicated calculations, you had to have them done by hand, ultimately.
They were done by hand and then they were transposed into the printing process.
And then, you know, printed out into tables.
That were then used to kind of speed that mathematical process.
Babbage found, you know, Babbage was super frustrated with this.
Because there could be a number of errors that could be introduced.
In either doing the calculations by hand or in printing them, etc., etc.
They were riddled with all kinds of new errors.
Which made using these tables extremely frustrating.
So, Babbage, and this is probably apocryphal because it's a little bit too imperfect.
Babbage said, I wish to God these calculations had been executed by machine.
And when he said that, to say executed by steam at this time meant, you know, the cutting edge of technology, right?
This is in the time when steam engines were just coming about and like really taking over, right?
And so, this meant he really wanted this to be done in a technological manner.
He came up with two prototypes.
He had designed for different tensions, one and two.
He was working on these from 1822 until really the early 1830s.
But he came back to it a little bit later after the annulus lenti.
Babbage received 17,000 pounds from the British government to create these tensions.
So, they bought into his idea.
17,000 pounds was the equivalent of building two steam naval ships.
Which you could imagine was a really serious investment.
It was something that Britain, a naval superpower at the time, was really interested in.
So, they felt that these engines were going to be sophisticated enough.
You know, if they could really make these astronomical tables which were used for navigation
and all kinds of like economic, you know, economic endeavors,
if they could make those more reliable, it would be worth it.
So, it sounded great.
Babbage failed to actually do that.
None of these computers actually existed in the Victorian period.
Now, there's a number of reasons for his failure and they're fairly complicated.
But it comes down to poor project management.
He was bad at communicating.
And, I think the tolerances, the precision that was necessary to really make things work
was technically possible in the time but was just technically possible.
So, it was very hard to maintain that level of precision in the 1830s.
So, he kept running into problems with his engineer for like the sheer number of detailed parts.
Now, eventually, these actually were made.
These were made.
The Difference Engine was made at the London Science Museum
and at the Computer History Museum in Mountain View, California.
It was made from 1991 to approximately 2000.
It took them a long time to set up a little bit, actually.
And they built it from Babbage's design.
So, his designs actually did work.
There was proof ultimately that they worked.
They never worked in his lifetime.
But, they were able to make it work.
So, it's still being shown at the London Science Museum.
At the Computer History Museum in Mountain View, California.
It was on display until 2016 but was removed recently
because it was actually built by Nathan Niervold
and he put it back into a private collection.
So, it's at his house, I guess.
And he's the Chief Operating Officer, former Chief Operating Officer of Microsoft.
So, the Difference Engines.
These were technically, these could be considered computers, not calculators
because they have a capacity for memory.
That was the thing that differentiated the Difference Engine from calculators.
And these things were huge, as you can see.
So, the thing that made Babbage abandon the Difference Engine
was really having a better idea.
And he got a better idea in the early 1830s
when he realized, he kept looking through a number of different ways to do this,
but he realized punch cards were the way that he wanted to program
the next version of his computer.
And he was inspired by the punch cards for the jacquard loom.
The jacquard loom is an automatic loom.
So, those same types of automatic looms that were, you know,
the Luddites were protesting in 1812 and 1815,
that's what Babbage was ultimately inspired by
and what caused him to make the leap to the analytical engine,
which most people consider to be more clearly a computer
because it not only has the capacity for memory,
it also has the capacity for loops and branching and programming.
Actually, Ada Lovelace made this connection a few years before Babbage backfired.
So, she was touring the Midlands where there's a lot of weaving factories.
She saw looms like the jacquard loom, and she said,
they remind me of Babbage's gem of all backfiring,
of which he only had one-seventh of a part.
And he would often show that at his parties,
and that's where they met initially.
And so, she wrote that in a letter.
I don't know if she ever brought that up to Babbage,
but Babbage eventually came up with it on his own.
And jacquard looms are these automatic looms.
And the punch cards are really made to control the way the threads are going.
They're made to create very intricate, self-rotated fabrics.
You know, those fabrics that have very intricate patterns in them?
That's what they're doing.
And some people have argued that jacquard looms are the first thing
that you can program to make this effect.
So, the analytical engine.
The analytical engine was really the first computer
that's able to be programmed in various ways,
has the capacity for loops, branching, programming, and memory.
And this was the computer that Ada Lovelace programmed.
And she programmed without ever having access to the computer.
It was never accessed.
So, she did this in a translation of an article
that was written about Charles Babbage's lecture about new machines.
So, notice how there's, like, all the, you know, it's all the way down, right?
The sketch of the analytical engine invented by Charles Babbage,
Babbage went to Italy, and he delivered a lecture about his analytical engine.
And that lecture was listened to by an audience which included L.F. Manabria.
And L.F. Manabria wrote up the lecture in an article and published it in French.
Now, a couple years later, like in 1842 to 1843,
Ada Lovelace was asked to translate the article in English by a mutual friend.
She did that, and Babbage encouraged her to add a little bit of something of her own in notes.
The footnotes that Lovelace wrote far exceed the original article itself.
These are really long footnotes.
So, Babbage, Babbage kind of, he kind of worked with her on the notes too,
but the notes are really where Lovelace makes her contributions to computing history.
So, among those notes, and remember, these are footnotes to a translation,
in those notes she wrote her computer program.
Now, this program was made to calculate the eight Bernoulli numbers.
The Bernoulli numbers were important in this time because, like I said, everything was done by hand.
Bernoulli numbers could dramatically simplify very complex calculations.
So, being able to calculate these numbers was really important.
Her program has since been translated into a number of modern programming languages.
It worked, but there was one problem with it.
In the fourth operation, she transposed two variables.
Now, this could have been her mistake, or it could have been a mistake that was improved in printing.
Sinclair Target noticed it when he translated it into C++.
Duane translated the program into C++.
Yeah, into C.
And it's been translated into other languages as well.
So, what's remarkable about this is before there was the idea of a programming language,
Ada Lovelace set out to make the computer do something, right?
And these were the set of instructions that she made to make the computer that did not yet exist produce the eight Bernoulli numbers.
So, there's a number of arguments about Lovelace.
There's a number of arguments about this program.
First is whether it's really first, right?
And historians love that.
If you're going to be first, that's really important.
It's not clear that Lovelace was actually first.
Babbage and Monabria may have written programs well before her.
The difference is that Lovelace wrote her program in a more public forum, and her program was more complex.
Her program contained loose programming.
Now, other historians argue maybe Lovelace didn't do it all by herself.
Maybe Babbage did it with her.
Now, maybe Babbage did it with her.
The program is all in her handwriting that we've been able to find.
And it does seem like she was entirely mathematical capable of it, so I'm not entirely sure why we think Babbage did it.
So, Lovelace was capable of it.
Maybe it wasn't first.
Maybe it's the most complex one.
It's really important nonetheless.
Now, Doran Swayze, who is an important computer historian, he says it doesn't really matter if her program was technically first.
What matters is her bigger point of note, which is that the analytical engine, as a computer,
she didn't call it a computer, but the analytical engine will be able to have symbolic results rather than merely numerical.
This was really important.
She understood that this was not just going to be a calculator, but that computers would eventually be able to do all sorts of things,
create art, create music, do all sorts of things.
So, she said the analytical engine leaves algebraical patterns just as cardboard leaves flowers and leaves.
The symbolical results will be attached to these numerical results.
So, she knew that programming would be able to produce all kinds of things in the world.
She also asked a number of questions that have become important to artificial intelligence.
She asked whether the analytical engine could be said to be a thinking or reasoning machine.
Her answer was no, it was not a thinking or reasoning machine.
This is a question that came up immediately as soon as people saw computers at Babbage's party.
They would see the difference engine and they would be like, it thinks!
Ada thought that was the stupidest thing ever.
She was like, it does not think.
Other people have explored this in different ways.
She also wrote this note on translation when she had three children under eight years old.
So, I think that's really incredible too.
She was able to do this in large part because she was an aristocrat who had a whole household of servants running the household
and taking care of her children while she was able to study advanced mathematics because her husband let her.
And he very much let her do that.
So, she was very much in a time where even as Countess Lovelace, she had strict gender expectations for her behavior.
So, Babbage and Lovelace both had in common a kind of mystical belief in Christianity.
They pursued mathematical science because they thought that it was a language through which they could express the great facts of the natural world.
That basically their pursuit of math and science would bring them closer to God's creation
and that God's creation was a kind of clockwork universe that needed to reveal itself.
Now, I say this because I think this was an important part of her thinking all the way through.
Programming will do these things in the world.
This is what will happen.
And so, this is very much a very Victorian sentence.
This is all one sentence.
Yeah.
So, this ended up being a dead grant of computing technology.
The modern digital computers we have today have no direct relationship to Babbage and Lovelace's work.
It has no direct relationship.
In part, that's because they were never actually built.
Now, in the 1940s, Alan Turing, who you may have heard of, he rediscovered Lady Lovelace's work, Countess Lovelace's work,
and took it up and cited it in his own work.
And his question, do computers think, he called Lady Lovelace's question.
So, you know, Turing is a big part of why we still remember Lovelace.
He recovered her.
Yeah, Babbage lived until he was almost 80 years old, and he worked his whole life on these computers.
He never brought them to do anything.
So, they never actually existed.
Lovelace had an even more tragic end.
After her collaboration with Babbage, they had a falling out in terms of their friendship, in part over the sketch of the analytical engine.
And she ended up becoming a gambling addict.
She lost thousands of pounds of money.
Her family tried to cover that up, and then she got uterine cancer and died a few years later.
So, pretty tragic.
Yeah, and none of this was really known, widely known about until, you know, historians knew about it,
but it wasn't really brought about until about 2000.
So, we weren't widely aware of Lady Lovelace.
So, if you're interested in the subject, I highly recommend BBC's documentary, Calculating Ada,
the Countess of Tutankhamen, which is a great documentary.
Do you have any questions?
I'm happy to try to fill them.
Oh, well, so, we had one paper that was on integrating Lovelace into, you know, women in science and engineering,
like, why did that, and, like, how you could do this.
That's a good question.
It's a really, it's a really evocative parallel, but I don't think that they were active in the same exact way.
Now, around the same time, you have Dickens writing about the Spittlefields.
So, Spittlefields was a place in, I think it was in London, a neighborhood that was for weavers, and it was very poor.
So, he, I think it was a household word, it's a detailed article about the existence of women there.
So, there's still concern about, like, the factory conditions, what kinds of, like, lights are available to these people,
but not in exactly the same way as Lovelace.
I don't know if Ada ever made that connection, you know, that her father had, that the Lovelace was on the opposite side.
I don't know.
I guess it was just to demonstrate that, like, okay, you want it to do this, here's how you would make it do that.
And the whole, the goal of the program doesn't really matter as much as just, like, you know, this is how you would do it.
Yeah, I don't know.
There's probably other people here who could talk about that more.
How does a punch card make it do things?
Yeah.
And the analytical engine has never actually been built.
To my knowledge, I have heard of people wanting to build it, and I think they're working on it.
Like, there's interest in building it, but I don't think that it would be a huge success.
But, and these things are, you know.
Yeah.
How do punch cards work?
And Babbage was really interested in things like player pianos.
They had automatons that were basically early robots that would do things like a player piano or, like, they would dance.
And he loved those kinds of objects.
So, and he had one of those.
I forget exactly what it was.
But he had an automaton that he had.
It was early on in Amplify.
That was his project.
Any other questions?
So, Lovelace has been memorialized in computer programming language as well.
In 1980, or through the 80s, there was Ada, the language that was developed by the Department of Defense, 1977 to 1983.
And Ada code is still used by U.K. aircraft.
It's not a very, like, user-friendly programming language, but it is still Lovelace.
All right.
Thank you.
I just want to say thanks again to everybody who attended today, both online and in person.
Again, we do this every third Tuesday.
So, next, I'm trying to think, I think it's the 21st of November.
So, same place, same time.
So, hope to see you next time.

