Sunday, September 23, 2007

A Lesson From Steam Engines

Let’s get back to exploring the benefits of applying science to computer science. Since the rebirth of science about 400 years ago, we have had two major economic revolutions; the Industrial Revolution and the Information Revolution. During the Industrial Revolution, mankind began to manipulate large quantities of energy; while during the Information Revolution, mankind began to manipulate large quantities of information. Both have had huge economic impacts. We can date the dawn of the Information Revolution to the spring of 1941 when Konrad Zuse built the Z3 with 2400 telephone relays. Similarly, we can date the dawn of the Industrial Revolution to 1712 when Thomas Newcomen invented the first commercially successful steam engine.

As an IT professional you are a warrior in the Information Revolution. You work with information all day long. You create, maintain, and operate software which processes information in huge quantities. Software is also a form of information, so essentially you get paid to process information with information. Have you ever stopped to wonder what information is? Is information “real” or just something we made up? Is information a tangible part of the physical Universe, or is it just a useful human contrivance like the names we use for the days of the week? Over the past 400 years, the role of information in physics has taken on more and more significance, to the point that many eminent physicists, such as John Wheeler, have proposed that the physical Universe is simply made out of information - “It from Bit”. Over the years, the concept of information has arisen in physics in several effective theories, most notably in thermodynamics and Einstein’s special theory of relativity. Today we will lay the foundations for the concept of information in thermodynamics, and leave Einstein for another time. Now let’s see if we can learn a lesson from the past warriors of the Industrial Revolution.

The early factories of the 18th century were forced to run on water power. This required them to be located in the highlands near fast-moving water, far from the lowland cities where workers and consumers resided and distant from many natural resources required for production. What was needed was a portable source of power. The Newcomen steam engine was the first commercially successful steam engine and consisted of an iron cylinder with a movable piston. Low-pressure steam was sucked into a cylinder by a rising piston. When the piston reached its maximum extent, a cold water spray was shot into the cylinder causing the steam to condense and form a partial vacuum in the cylinder. External atmospheric air pressure forced the piston down during the power stroke. In the 18th-century, steam engines used low-pressure steam and were thus called atmospheric steam engines because the power stroke came from atmospheric air pressure. High-pressure steam boilers in the 18th century were simply too dangerous to use for steam engines. The Newcomen steam engine was used primarily to pump water out of coal mines. It had an efficiency of about 1%, meaning that about 1% of the energy in the coal used to fuel the engine ended up as useful mechanical work, while the remaining 99% ended up as useless waste heat. This did not bother owners of steam engines in the 18th century because they had never even heard of the term energy. The concept of energy did not come into existence until 1850 when Rudolph Clausius published the first law of thermodynamics. However, they did know that the Newcomen steam engine used a lot of coal. This was not a problem if you happened to own a coal mine, but for 18th-century factory owners, the Newcomen steam engine was far too expensive for their needs.

You can see the oldest surviving Newcomen steam engine at the Henry Ford Museum in Dearborn Michigan just outside of Detroit, as well as Thomas Edison’s original Menlo Park Laboratory, which has also been relocated to the adjoining Greenfield Village museum. This engine was built in 1760 and pumped water from an English coal pit until 1834. I had the chance to see this steam engine a few years ago. It was as big as a house and weighed in at a whopping 15 horsepower, about the horsepower of a modern riding lawnmower. You might wonder why anybody would go to the trouble of building such an engine, but you have to compare it to the effort involved in the care and feeding of 15 horses!

Figure 1 – The first commercially successful steam engine was invented by Thomas Newcomen in 1712. The Newcomen steam engine had an efficiency of 1%.

In 1763, James Watt was a handyman at the University of Glasgow building and repairing equipment for the University. One day the Newcomen steam engine at the University broke, and Watt was called upon to fix it. During the course of his repairs, Watt realized that the main cylinder lost a lot of heat through conduction and that the water spray which cooled the entire cylinder below 212 0F required a lot of steam to reheat the cylinder above 212 0F on the next cycle. In 1765, Watt had one of those scientific revelations in which he realized that he could reduce the amount of coal required by a steam engine if he could just keep the main cylinder above 212 0F for the entire cycle. He came up with the idea of using a secondary condensing cylinder cooled by a water jacket to condense the steam instead of using the main cylinder. He also added a steam jacket to the main cylinder to guarantee that it always stayed above 212 0F for the entire cycle. In 1765, Watt conducted a series of experiments on scale model steam engines that proved out his ideas.

Figure 2 – In 1765, James Watt improved the Newcomen steam engine by introducing a condensing cylinder to condense steam during the power stroke and by using a steam jacket to always keep the main cylinder at a temperature higher than the boiling point of water. Watt's improved steam engine had an efficiency of 3%, and on that basis, launched the Industrial Revolution

To learn moree about the Newcomen and Watt steam engines go to:

http://technology.niagarac.on.ca/staff/mcsele/newcomen.htm

Watt’s steam engine had an efficiency of 3% which may still sound pretty bad, but that meant it only used 1/3 the coal of a Newcomen steam engine with the same horsepower. So the Watt steam engine became an economically viable option for 18th-century factory owners. We will discuss the second law of thermodynamics at a later time. But just for the sake of comparison, the second law allows us to calculate that the maximum efficiency of a steam engine running at a room temperature of 72 0F using 212 0F steam is 21%.

The Industrial Revolution was delayed by more than 50 years because nobody bothered to try to understand what was going on in a Newcomen steam engine. This was overcome by James Watt when he unknowingly applied the scientific method to steam engines. Based upon some empirical evidence gathered while repairing a Newcomen steam engine, he had a moment of inspiration. He then proceeded to deduce the implications of his revelation and came up with the design for a new kind of steam engine. He then tested his design with a series of controlled experiments.

We are now some 60+ years into the Information Revolution, and like our counterparts in the Industrial Revolution, we are still struggling with the inefficiency of creating and operating software. And like our counterparts, we know that we are very inefficient at software, but we really do not have a clue as to how inefficient we may truly be. Softwarephysics proposes that we stop and take a look into our engine compartment.

The Problem with Common Sense
Like the 18th-century engineers struggling with steam engines, IT professionals have developed a common sense approach to software based upon a set of heuristics. In IT, you quickly learn that when coding software it never works the first time. If you are lucky it will work on the 10th try. If it does not work by the 100th try, you need to look for another profession. But common sense is just another effective theory. Recall that an effective theory is an approximation of reality that only holds true over a certain restricted range of conditions and only provides a certain depth of understanding of the problem at hand. Take a ballpoint pen from your desk and one of your shoes. Drop them both from shoulder height and see which one hits the ground first. For nearly 2,000 years, common sense and the teachings of Aristotle held that the shoe will hit the ground first. It was not until the late 16th century that Galileo demonstrated that they hit the ground at the same time. He also discovered that if you doubled the time of a fall, the distance traveled increased by a factor of four (the square of the time). This was one of the first uses of a mathematical model in physics. The purpose of softwarephysics is to go beyond IT common sense and come up with an effective theory of software behavior at a deeper level.

Next time we will continue on with thermodynamics and see how it led to an effective theory of information and how softwarephysics incorporates that theory into a model for software behavior.

Comments are welcome at scj333@sbcglobal.net

To see all posts on softwarephysics in reverse order go to:
https://softwarephysics.blogspot.com/

Regards,
Steve Johnston

1 comment:

Unknown said...

Nice! I am looking to get a good overview of the topic and your article provided help on the way. Thanks. Steam Boiler Repair Edison