PDA

View Full Version : Charles Babbage's "Difference Engine"



Magee
12-10-2009, 09:37 AM
Not exactly new news to many here, I'm sure, but there was a story about this on NPR this AM (I hadn't heard of it before). Apparently two were built... one for the Science Museum in London and one for Nathan Myhrvold (of Microsoft) who funded the project. Myhrvold's is the one currently on loan to The Computer Museum in CA. Not really ANY talk of the machining involved, unfortunately, but it's a fascinating story and machine nonetheless:

LINK to NPR (http://www.npr.org/templates/story/story.php?storyId=121206408)

Link to the Computer History Museum (http://www.computerhistory.org/babbage/)

http://www.computerhistory.org/babbage/common/img/welcome-babbageengine.jpg

http://media.npr.org/assets/artslife/arts/2009/12/babbagedesign.jpg?t=1260398716&s=51

http://www.computerhistory.org/babbage/howitworks/img/4-3.jpg

http://www.computerhistory.org/babbage/modernsequel/img/6-2.jpg

lazlo
12-10-2009, 09:49 AM
Oh wow, I've been wanting to see the London Difference Engine -- I didn't know they made two!

Time to visit the home office (in Santa Clara, about 4 miles from the Computer History Museum in Mountain View)! :D

Edit: they didn't make two. The London Science Museum constructed Babbage's Difference Engine in 2002, and the guy from Microsoft commissioned a copy of it, that was just completed last year.

The Difference Engine in London isn't a replica -- Charles Babbage never built it, so the version the Brits made 150 years later was the first one :)

Evan
12-10-2009, 10:13 AM
It is a lot more complex than that Robert.


Physical Legacy
Aside from a few partially complete mechanical assemblies and test models of small working sections, none of Babbage's designs was physically realized in its entirety in his lifetime. The major assembly he did complete was one-seventh of Difference Engine No. 1, a demonstration piece consisting of about 2,000 parts assembled in 1832. This works impeccably to this day and is the first successful automatic calculating device to embody mathematical rule in mechanism. A small experimental piece of the Analytical Engine was under construction at the time of Babbage's death in 1871. Many of the small experimental assemblies survived, as does a comprehensive archive of his drawings and notebooks.


http://www.computerhistory.org/babbage/engines/


There were three engines. Two difference engines which are mechanical calculators, not computers, and the Analytical engine, which is a computer.

lazlo
12-10-2009, 10:23 AM
I'm very familiar with Babbage's machines Evan. The Difference Engine calculated tables of polynomial functions. That was the reason for the printer.

He designed his Analytical Engine (a more general purpose computer) after he designed Difference Engine No. 1. This machine, Difference Engine No. 2, was the last machine he designed, although he tweaked the design for the Analytic Engine up to his death.

The London Science Museum made models of both the Difference Engine No. 2 and the Analytical Engine. The Microsoft copy is the Difference Engine No. 2.

Still, machine art (and compute science brilliance) at it's finest.

I can't link to the video in Magee's second link, but it's highly recommended. Watching the gears in motion, and the carry chains spiraling upward is mesmerizing.

Evan
12-10-2009, 10:33 AM
I'm very familiar with Babbage's machines Evan.

Then you should know that he actually built a working portion of the first difference engine.

http://ixian.ca/pics7/babbage.jpg

lazlo
12-10-2009, 10:40 AM
Yep, it was a prototype module (essentially a single carry chain) built by Joseph Clement, Babbage's machinist for the Difference Engine No.1 under contract to the British Government.

Babbage shared a lot of traits with Edison, and was a prick to work with. Clement left to run his own machine shop, and no further work on the Difference Engine No. 1 was ever completed.

Clement was a pioneer of standardizing screw threads, and had a young journeyman who worked for him, by the name of Joseph Whitworth :)

rockrat
12-10-2009, 10:45 AM
Anyone interested should check out a book - The Cogwheel Brain by Doron Swade (isbn 0-316-64847-7)

I think that I had blabbed about Babbage before but...

I read the book and found the history of this interesting. Babbage can be given credit for pushing machines and machinists for more accurate and precise parts for his time. He needed gears that matched each other very closely and he struggled to find shops and people that could do this.

I was lucky enough to have seen the machine that was built in the museum in London and also the starts for the second machine. The info at the museum noted that the second machine was to be sent to the US. They gave the impression that the machine would tour US museums before being on permanent display on the west coast somewhere.

Here is a photo that I took (I could have done a bit better) Difference Engine #2 (http://img.photobucket.com/albums/v12/rockrat/machines/babbage.jpg?)

rock~

lazlo
12-10-2009, 10:50 AM
Babbage can be given credit for pushing machines and machinists for more accurate and precise parts for his time. He needed gears that matched each other very closely and he struggled to find shops and people that could do this.

There was an excellent Scientific American article about the London Science Museum's construction of the Analytical Engine back in early 2000. They noted that the British government pulled funding for the Difference Engine No. 1, partly because it was very prone to jamming. Gears were hand-cut back then, so getting long chains to inter-mesh was hopeless.

IIRC, the London Museum's gears are CNC cut?

Thanks for the book citation Rock -- I remember that from the last time we discussed Babbage's machines. I'll have to get a copy.

rockrat
12-10-2009, 11:02 AM
IIRC, the London Museum's gears are CNC cut?

I dont believe so, the book states otherwise. But I didnt see them being cut either. :)

The book does parallel the building of the machine in London with Babbages challenges. So looking at a time line the reader jumps back and forth as the chapters change. The writing is god enough that you know where you are on the time line. But, they do note that the funding required that the machine be built by a specific date and it must be built using processes of the time. They did allow current manual lathes and manual mills to be used. But there was so much hand fitting.

It was finished only hours (or a day or so) before the unveiling and when Doron tried to turn the handle the first time it froze up a bit. After a little checking they realized that it took just a bit more force than he was applying. After the first turn or so things set in and it was reported to turn fairly easily.

I really become enthralled with the book, I just couldnt put it down. This is rare for me. Normally the only books that will content me are old machine manuals or books on casting, induction heating or something.

I found the book for a few dollars at a local computer store that was selling all of its books off. It was well worth the price.

rock~

edit - a few more photos

Difference engine #2 second shot (http://img.photobucket.com/albums/v12/rockrat/machines/DSCN2276.jpg)

The machine being made for the US (http://img.photobucket.com/albums/v12/rockrat/machines/DSCN2275.jpg)

And I talked to Charles Babbage! Well I talked to his brain at least Brain (http://img.photobucket.com/albums/v12/rockrat/machines/DSCN2277.jpg)

Sorry for the focus, I must have been too excited and just didnt get my camera set correctly for the lighting. Gawd I'm a geek. :)

Tony Ennis
12-10-2009, 11:15 AM
There was an excellent Scientific American article about the London Science Museum's construction of the Analytical Engine back in early 2000.

I kept that copy :-) I'm a Babbage fan!

Tony Ennis
12-10-2009, 11:19 AM
How things change. There are working Difference engines made with Lego blocks and an Analytical engines made with Mechano.

Check out this over-achiever (http://www.meccano.us/).

Sleazey
12-10-2009, 01:12 PM
Seeing these hobbyist versions of famous machines of the past, one wonders what will future hobbyists be able to do? Using Meccano, hobbyists have recreated Vannevar Bush's Differential Analyzer, and others have recreated parts of Babbage's various Engines. The original projects taxed the resources of major universities and even sovereign governments.

Now, using commercially available toys(!), an individual can build working replicas. What will hobbyists be building in 100 years?

The Artful Bodger
12-10-2009, 02:00 PM
How things change. There are working Difference engines made with Lego blocks and an Analytical engines made with Mechano.

Check out this over-achiever (http://www.meccano.us/).

Meccano computers are hardly a recent development!

http://computerworld.co.nz/news.nsf/tech/7627BB58BAFE998DCC257317001AA6D1
Used to design hydro dams, and to knock them down, also to track rabbit populations!

psomero
12-10-2009, 02:00 PM
so the second one is at the computer museum in mountain view right now?

i'll have to go check that out. it's just a 15-20 minute drive up the road from here...

John Stevenson
12-10-2009, 07:00 PM
Yep, it was a prototype module (essentially a single carry chain) built by Joseph Clement, Babbage's machinist for the Difference Engine No.1 under contract to the British Government.

Babbage shared a lot of traits with Edison, and was a prick to work with. Clement left to run his own machine shop, and no further work on the Difference Engine No. 1 was ever completed.

Clement was a pioneer of standardizing screw threads, and had a young journeyman who worked for him, by the name of Joseph Whitworth :)

There was a falling out between Babbage and Clement, Babbage complained that Clement was spending more time and money perfecting his machine tools instead of working on the engine.
Clement's reply was that there were no machine tools accurate enough to do this work so the tools had to be done first.

A bit of a chicken and egg situation but the bugbear was that these were Clements tools and any work done on them benefited Clements more than Babbage.

bob ward
12-10-2009, 07:42 PM
Anyone interested should check out a book - The Cogwheel Brain by Doron Swade (isbn 0-316-64847-7)


Thanks for the heads up on the book. Only $12 or so on Amazon, or plenty of second hand ones on ebay for $3 or $4. I've ordered my copy, sounds like a good read for very few $$.

Peter S
12-11-2009, 06:24 AM
Meccano computers are hardly a recent development!

http://computerworld.co.nz/news.nsf/tech/7627BB58BAFE998DCC257317001AA6D1
Used to design hydro dams, and to knock them down, also to track rabbit populations!

Thanks for that! I remember when this machine was a prominent display at MOTAT back in the 1980's, it then dissappeared and I heard a story that it was "lost". But according to that article it still exists - I will check that out.

--------------------

For those who want more books... Doron Swade also wrote a 48 page booklet for the Science Museum in 1991 titled Charles Babbage and his Calculating Engines, it is worth getting just for the photos - colour, and larger format than those in The Cogwheel Brain.

Evan
12-11-2009, 09:32 AM
There are a range of problems that fall into the "intractable" class in mathematics that are trivial to solve with a mechanical system.

One example that I have given here before is to compute the centroid of a non trivial number of points. The reason it is intractable is that the number of calculations required is proportional to N! where N is the number of points. It can be solved to a very close approximation of truth using identical rubber bands and nails on a board.

The nails are driven into the board at coordinates representing the bodies and each nail has a rubber band looped over it with the other end tied to a small ring that all the bands are attached to. The centre of the ring automatically assumes the position of the centroid and will continue to do so as the points (nails) are moved around.

John Stevenson
12-11-2009, 05:43 PM
Thanks for the heads up on the book. Only $12 or so on Amazon, or plenty of second hand ones on ebay for $3 or $4. I've ordered my copy, sounds like a good read for very few $$.

Found one on Abebooks for $1.00, postage was $4.00 though :(

.

boslab
12-11-2009, 06:34 PM
There are a range of problems that fall into the "intractable" class in mathematics that are trivial to solve with a mechanical system.

One example that I have given here before is to compute the centroid of a non trivial number of points. The reason it is intractable is that the number of calculations required is proportional to N! where N is the number of points. It can be solved to a very close approximation of truth using identical rubber bands and nails on a board.

The nails are driven into the board at coordinates representing the bodies and each nail has a rubber band looped over it with the other end tied to a small ring that all the bands are attached to. The centre of the ring automatically assumes the position of the centroid and will continue to do so as the points (nails) are moved around.
whats that got to do with the difference engine?
mark

lazlo
12-11-2009, 06:36 PM
Check out this over-achiever (http://www.meccano.us/).

Wow, very impressive!

http://www.meccano.us/difference_engines/rde_1/DEFront_small.jpg

John Stevenson
12-11-2009, 06:42 PM
whats that got to do with the difference engine?
mark

Well the reply was different :rolleyes:

Ok I'll get me coat..................

Ries
12-11-2009, 06:48 PM
2 very entertaining FICTIONAL takes on the difference engine-

http://en.wikipedia.org/wiki/The_Difference_Engine

is a novel by Bruce Sterling and William Gibson about an alternate timeline where the difference engine was built, and became the basis of technology.

and then, this great little story about a guy who finds a difference engine in a burlap sack under a house in Tasmania, and the adventure that follows-

http://www.amazon.com/Georgia-My-Mind-Other-Places/dp/0312862253

all three authors are smart, and write plausible science fiction.

lazlo
12-11-2009, 07:01 PM
2 very entertaining FICTIONAL takes on the difference engine-

http://en.wikipedia.org/wiki/The_Difference_Engine

is a novel by Bruce Sterling and William Gibson about an alternate timeline where the difference engine was built, and became the basis of technology

Fabulous -- modern society, 100 years early, based on SteamPunk technology! :) I'm going to have to order that book too!

Weston Bye
12-11-2009, 07:05 PM
2 very entertaining FICTIONAL takes on the difference engine-

http://en.wikipedia.org/wiki/The_Difference_Engine

is a novel by Bruce Sterling and William Gibson about an alternate timeline where the difference engine was built, and became the basis of technology.

and then, this great little story about a guy who finds a difference engine in a burlap sack under a house in Tasmania, and the adventure that follows-

http://www.amazon.com/Georgia-My-Mind-Other-Places/dp/0312862253

all three authors are smart, and write plausible science fiction.

The Difference Engine struck me as all trip and no destination - fun while it lasted, but left me dissapointed with the ending.

boslab
12-11-2009, 07:07 PM
Well the reply was different :rolleyes:

Ok I'll get me coat..................i'm on about elastic bands, i just want somone to explain the Evan post, pardon me, perhaps you would like to explain because i cant see where that came from, why dont we throw in the madelbrot set or the exponential series [e] or plot the graph of Tangents,
still i dont get what Evan [with all due respect] was on about, do you, i dont think i have a mathematical liability i just dont understand, is it wrong to ask?
perhaps i'll get me coat............:rolleyes:

boslab
12-11-2009, 07:09 PM
Fabulous -- modern society, 100 years early, based on SteamPunk technology! :) I'm going to have to order that book too!
HG Wells explores a whole future based on mechanical calculation, driven by steam i beleive
mark

lazlo
12-11-2009, 07:15 PM
HG Wells explores a whole future based on mechanical calculation, driven by steam i beleive

HG Wells wrote some weird Uptopian society books that I couldn't struggle through, but I've read all of his most famous books: The Time Machine, The Island of Doctor Moreau, The Invisible Man, The War of the Worlds, and they're all superb. No steam punk per se, but a lot of brilliant fore-thought. Likewise with Jules Vern.

More recently, Fred Saberhagen, who wrote the Beserker series (of which the Borg from STTNG was a blatant rip off), was equally (IMHO) adept at predicting the future. In "LifeHater", circa 1964, he very accurately describes a laptop computer.

boslab
12-11-2009, 07:21 PM
i'll make a point to read, thanks
mark

macona
12-12-2009, 12:10 AM
Heres a couple pics of the one in the Computer Museum in Cali. Got to see it before it was officially unveiled after Maker Faire last year.

http://i65.photobucket.com/albums/h228/macona/DSC03449-1.jpg

http://i65.photobucket.com/albums/h228/macona/DSC03444-1.jpg

whitis
12-12-2009, 03:21 AM
One example that I have given here before is to compute the centroid of a non trivial number of points. The reason it is intractable is that the number of calculations required is proportional to N! where N is the number of points. It can be solved to a very close approximation of truth using identical rubber bands and nails on a board.


Well, good thing I didn't know that 20 years ago when I needed to compute the centroid of 576 points. That should qualify as non-trivial since the number of operations required (576!*N) using the characteristics of your algorithm would have well over 1000 digits. Since the fastest 286 CPU could only do about 3.6MIPS, the computer wouldn't have come anywhere close to finishing the calculation by the time the sun exploded in 4-5 billion years. Actually, the 286 did the entire centroid calculation 30 times each second, in addition to its other work. I used a simple algorithm that executed in order N time rather than some boneheaded algorithm that executes in order N! time. Since I used hand optimized assembly language, it could actually do more than 576 points. In this case, the coordinates were fixed and the value at each point varied and I exploited that in the optimization by precomputing some values but if the coordinates were random it would have still run in linear time. This was not an approximate solution, it was exact within the precision of computation.

The application was real time telescope autoguiding using video from a $9000 image intensified video camera and was used successfully on the NASA 1.5m telescope on Mt Lemmon.

For those unfamiliar with astronomy, an autoguider holds the image in a telescope steady for long exposures despite atmospheric fluctuations, mechanical flexure, and tracking errors. An image intensifier is a device for amplifying light levels.

In computational complexity theory, intractable problems are those which, while theoretically solvable, can't be solved in a reasonable amount of time. A centroid is basically the geometric center or center of mass (center of gravity), etc. of one or more objects. Things get a little more confusing because there are often pragmatic approximate solutions to intractable problems and problems that are very simple may take nearly a very long time to solve if you throw very large numbers of data points at them. A centroid calculation isn't much harder than even the simplest mathematical problems. If you tried to compute the centroid of the earth by feeding in the mass and location of every single atom at some instant in time, it would take one desktop computer roughly a billion years to do the calculation (never mind the problem of acquiring or storing the data or feeding it into the computer at the speed it could calculate). However, it would take the computer about 100million years just to count the data points.

If you have randomly placed holes to drill in a plate on a CNC machine, computing the optimum path to minimize traverse time between holes is a computationally intractable problem (known as the traveling salesman problem). As the number of holes goes up, the number of computations explodes. For just 20 holes, there are 2432902008176640000 possible paths.
If your computer can do a brute force evaluation of 100million paths per second, it takes 137 years to find the solution. In 136 CPU years, the same problem has been solved, exactly, for 85,900 points on a circuit board using more sophisticated algorithms (possibly the current world record for maximum number of destinations solved exactly). However, one can compute a reasonably optimal path. Simply visiting the nearest undrilled hole from the one you just drilled gives you a solution that is, on average, only 25% worse than optimal. This can be computed in a fraction of a second for thousands of holes. Babbage's Analytical engine could have come up with a halfway decent solution for several hundred holes; it might have taken a day. The traveling salesman problem (as the crow flies, not by road) has been solved (http://www.tsp.gatech.edu/world/) to within 0.05% of optimal for a list of 1.9million geographic locations on earth. Maybe better, since we don't know what the optimum solution is, we just have a lower bound on the solution.

If the points are in motion, the rubber band method solves the centroid problem continuously. Except that the rubber bands have time lags and oscillate, adding to the other sources of inaccuracy.

rockrat
12-12-2009, 09:20 AM
Heres a couple pics of the one in the Computer Museum in Cali. Got to see it before it was officially unveiled after Maker Faire last year.

Sweet! The one in the London museum was inside a glass case that could be pulled back. I like this display a bit more. You can see things better. Anything with glass around it in the London museum was difficult to see due to the lighting; which also caused issues with photographs.

Now I am surprised that the display in California has left the crank handle out in the open with no visible retaining mechanism and behind nothing more than a rope.

Its cool to think that I saw parts of that being made back in 2007 in London. Next time I'm out west I'll have to drop by and see it in its entirety.

rock~

boslab
12-12-2009, 04:58 PM
Evan and Whitis, i think your medication is WAY too strong, thought mine was bad!
No just teasing but still none the wiser
mark