December 05, 2004

The metric system: a case study in technical standard setting

I have just finished reading The Measure of All Things : The Seven-Year Odyssey and Hidden Error That Transformed the World. It is a fascinating case study in how international standards are set.

As of 2004, the only countries in the world whose official system of measures is not the metric system are Myanmar (formerly Burma), Liberia and the USA. It is a fantastically successful international standard. In the US, Congress passed the Metric Conversion Act of 1975, calling for voluntary conversion. Amendments to the Act in 1988 designated the metric system as the "preferred system of weights and measures for United States trade and commerce." In the US it is legal to use but not mandatory.

Before France's revolution, its' academy, very much an analogue of England's Royal Society gained prominence. It was the age of rationalism and the scientists were pushing for measures which simplified scientific calculation. Think of them as the geeks. At the same time the King was worried about unrest due to lack of grain. Think of him as the suit. France had a babylon of local measures. Each city had measures morticed into the town hall walls. There would be one for a barrel, one for measuring grain, one for measuring cloth and so on. There were hundreds of measures for each item, totalling thousands of measures across France. It was very difficult to create contracts or conduct trade. As each market had its own measures, it made it difficult to compare prices between markets. The local aristocracy charged a fee to use the local measures. As a result each market was a monopoly.

The King was interested in a uniform standard. Nothing more. The idea of a completely arbitrary standard was anathema to the Academy, who thought that it should be based on an invariant, like 1/10000000 the length of the meridian from the North Pole to the Equator. Why this? They already knew this would give a measure very close to a length measure already used in Paris. The King reluctantly agreed and a surveying mission to measure the meridian from Dunkerque to Barcelona. The idea was to measure part of the meridian and then extrapolate the result, based on the idea of the Earth as a regular ovoid.

The two chief surveyors were Delambre and Mechain. In the seven years it took to complete the survey, revolution and counter revolution took place. At the end Napoleon was in charge. Though there were changes of government, each government wanted to advance trade. The new idea of nation engendered by the French Revolution needed means of defining the nation. Indeed the metric system has often been adopted when countries have become independent (e.g. India and Chine).

Ultimately it was found that:

  1. The Earth is not a regular ovoid, so the extrapolation was impossible
  2. That plus Mechain's fudging of his data, caused the metre to not be 1/10000000 of the quarter meridian.
  3. The metre turns out to be an arbitrary standard afterall.

Nevertheless the initial geekiness around the metre, and Napoleon's successful conquest of much of Europe was enough to get the metre rolling. The rest of the metric system rolled along with it.

Though scientists quibbled over the measurement of the metre, economics was driving its adoption. With standards in place it was possible to trade between markets in a country and then markets between countries.

Once there was a critical mass the network effect took over. Countries started adopting the metric system because other countries had, and the standard would enable trade.

The scientists of Britain, USA and the colonies were not invited to the first metric convention. The hostility to the metric system caused by that fateful act ensured the metric system would not be used in Britain, the Commonwealth or the United States for almost 200 years. Finally with the creation of the European Common Market in 1970, Britain was concerned enough to act. It adopted the metric system and the remaining non metric countries such as Canada and Australia followed suit. The latter happened in my memory. I remember having inch rulers in Grade 1 and centimetre rulers in Grade 2.

The United States had standardised on imperial measures early in its history. Because it already had a standard it also had all the benefits that come from one. It is only now, in the age of globalisation, which is really a word for pervasive international trade, does the United States suffer. Trading partners insist on metric measures. Industries such as Car manufacturing, which rely on parts made all over the world, are already completely metric. Now almost 80% of Americans know of metric units. It is expected that the metric system will continue its creeping takeover of the USA.

A repeating theme in adoption of the metric system is its rejection by adults. In the Benelux countries who were the first to permanently adopt the metric system , it was found the only way to achieve adoption was to teach it in schools and wait two generations until the majority of the population understood it. The old measures were anthropomorphic. The foot was originally the King's foot. Some human measures, like your weight and height feel more natural in the old measures. Everyone knows that a male over 6 feet is considered tall. I am 5'11".

So, what are the lessons learned for introducing a new technical standard?

  1. The standard should appear to have technical merit and appeal to geeks, even if it secretly doesn't
  2. The standard will need an economic rationale for adoption
  3. The standard should appear to be neutral and not favour any one party
  4. A meeting representing all should be held to agree on. Those not represented will inevitably resist it.
  5. The standard needs an exact specification. The metre has been revised three times and its specification tightened.
  6. The standard needs a standards body.
  7. The standard needs easy availability of implementations. (The French produced millions of metre rulers each year)
  8. Compliance needs to be audited and enforced.
  9. Once the network effect kicks in the standard becomes viral and achieves dominance
  10. The old standards, though rarer, will persist for a long time
  11. A standard that works well enough is very hard to replace. E.g. the US imperial system

A great example of a well executed standards process is J2EE. A great example of a bad one is Web Services, where almost every one of the above rules was broken.

A final characteristic of successful standards is there permanence. It was discovered only a few years after the introduction of the metric system that the metre was flawed in terms of what it was supposed to be. A platinum bar was created which became the first metre. Then when the Germans complained that the ends were scratched, another one, created by International committe over years was fashioned. The current definition is 1/299,792,458 of the distance travelled by light in a vacuum in one second. Each refinement has simply been a better specification of that original flawed platinum bar. The length of that bar will likely live on for Millennia.

Doubtful? The 60 based time and angle system (60 seconds in a minute, 60 minutes in an hour, 60*6 = 360 degrees in a circle) originated in Babylon 4000 years ago. When the French tried to reform time into a decimal day they failed. I wonder how long TCP/IP will be around?

Posted by gluck at 06:45 PM | Comments (4)

November 16, 2004

Brave New World - The jump represented by Fedora Core 3 64 bit, AMD64 and JDK1.5.0

In the world of open source, it seems there are periods of inching forward punctuated by large jumps. I believe we are in the middle of one of those jumps now. In this post I argue that the combination of Fedora Core 3, AMD64, the emergence of Firefox, Java 5 64 bit makes for one of those jumps.

Fedora Core 3 x86_64

I have been a RedHat devotee for the last 5 years. Their decision to split the open source and commercial distros did not overly concern me. This technique was pioneered by the Mozilla project and has been used by many successful projects including Apple's Darwin.

When Fedora Core 2 came out I was quite disappointed. While it added the 2.6 kernel it's quality was much lower than FC1. There were freezing problems caused by power management that required boot-time options to workaround. It seems to me that the distribution's job is to shield users from these sorts of issues. If a user wants to use the vanilla kernel, they can download and compile it themselves.

With Fedora Core 3, the Fedora project has regained my confidence. It is fast, stable, slick, smooth and mature. I have been using it for the past week as both a user and as a developer, writing Java and C code. With Gnome 2.8 the user interface has many subtle user interface improvements. Desktop integration between the standard apps is improved. For example clicking on a mailto: link in Firefox smoothly opens a send new message dialog in Evolution 2.

I am running the x86_64 version of Fedora Core 3. It comes with 32 and 64 bit versions of libraries, and from what I can tell works well with both. I am using IntelliJ running a 32 bit version of JDK1.4.2. Our code is running JDK1.5.0 64 bit. I can step through my running app in 64 bit Java with my 32 bit Java IDE.

For many people Fedora Core 3 brings them up to date with a year of progress in Linux. There has never been a better time to take the plunge.

AMD64

AMD64 has been around for a while. The extreme server performance of the Opteron range has been leaking out slowly. In my own tests, we got a three times improvement in performance with no tuning.

On the desktop, AMD64 ushers in low-cost 64 bit computing. We just bought all the developers (myself included) new AMD64-based machines. They were AUD1600. We are now in the age of commodity 64 bit.

JDK1.5.0 for AMD64

Sun have partnered with AMD and one of the fruits of that partnership is JDK1.5.0's AMD64 support. The 2GB memory limit is now gone for Java.

The Reemergence of Web Standards

Two things are having an impact here. Firstly, the Mozilla project has finally triumphed with Firefox. This browser has captured the public imagination. Far from an overnight success it derives from years of work. As someone who has used it since Mozilla .9, and reported bugs against it, it is great for us that kept the candle alive to see it now. According to w3schools the Mozilla family is now at 18.6% browser share worldwide.

At this level Firefox must be supported. And as the most standards-compliant browser (74 out of a 100 cw IE's 39.5) ever, it means standards must be supported.

Tellingly, the web designers I work with love working with Firefox. The result is they develop on Firefox first and then "port" to IE.

Goooooooooooooooooooooooooooooooooooooogle

While Google's long term effect on computing is hard to gauge, the results up to now are:

  • Microsoft has been prevented from extending its monopoly into searching
  • Gmail is an attack on Microsoft Hotmail and frustrates its attempt to use the combination of Exchange and Hotmail to push its patented senderid scheme into SMTP.
  • Desktop searching is an attack on the Microsoft heartland.
  • Google are now hosting the Firefox homepage. There have been rumours flying about a Google branded distribution of Firefox with some funky extra features.

The whole effect is to curtail Microsoft. Google is an effective monopoly which advocates ethics compared with Microsoft, who were found guilty of abusing their market position in desktop operating systems.

By curtailing Microsoft, the secondary effect is to promote standards through computing. The Windows OS gets less important.

The Total Effect

The whole effect is a big leap forward. Linux is better than ever. It is now usable for a large percentage of the population. The decline of Microsoft and the reemergence of standards gives this most standards-compliant operating systems a fertile world in which to take root.

Thanks to AMD64, 64 bit Linux and 64 bit Java 5, commodity 64 bit computing is now here. With the exception of the Microsoft's monopoly extension play, the struggling .NET, you can do everything on it.

My hope is that all of this will trigger a mass migration of the fence sitters to the Linux way. If you are one, why not wade in, the water's warm.

Posted by gluck at 04:37 PM | Comments (0)

October 09, 2004

Fatland

When I went to the US in June for the Agile Development Conference, I was paranoid about putting on weight. I avoided all fast food, ate only at restaurants and was careful to eat small. It seemed to work. On previous trips to the US I have always put on weight. Two years ago I put on a whopping 5 kilograms in one week! (Perhaps I was in denial about my pre-trip weight).

What is it about the US that has this effect. Well a great book to read to find out is fatland

The book argues that the late 70s ushered in two very low cost sources of empty kilojoules: Palm Oil and High Fructose Corn Syrup ("HFCS"). Palm Oil was a new import from South East Asia. Palm Oil is a saturated fat similar chemically to beef lard. HFCS is made from corn and is 10 times sweeter than sugar. Fructose also follows a different chemical pathway to sucrose. Long term use causes increased fat formation, high blood triglycerides, decreased glucose tolerance and too much insulin the blood.

It then argues that the food companies sought a way to take advantage of these changes. Coke and Pepsi changed from 100% sugar to 50% sugar and then 100% HFCS in their cola drinks. Research showed that over 4, humans lose the ability to take into account calories taken in in liquid form, not compensating for them when they ate solids. Other research showed that human satiety was flexible: they would eat more when confronted with wide variety and also when given more. Because of the high cost of labour but the low cost of these new sugars and fats, it was found that more margin per customer could be made by selling them more at an incrementally lower price. Along came value meals and supersize options. The growth in supersizing can be illustrated by the serving size of McDonalds fries. In 1960 200 calories, 1970s 320, 1990s 450, late 1990s 540 to the present 610 calories.

Accompanying this was a change to eat more meals out and do less exercise. Physical education had become curtailed in many schools. School districts were entering into lucrative 'pouring contracts' with softdrink manufacturers. Conditions often included unrestricted sales through the day and in-school advertising.

The health result of all this is still unfolding. About 25% of Americans are now obese, meaning they have a Body Mass Index ("BMI") of 30 or more. 60% are overweight, meaning a BMI of 26 or more. This in turn is associated with rapidly growing rates of diabetes, coronary artery disease, hypertension and stroke. This is leading to something of a windfall for drug companies who are seeing extra demand for drugs to treat these conditions. In time these diseases will drive up health costs and make insurance dearer. The US Surgeon General has warned that obesity is now a major threat to life in the US and may overtake smoking as a leading cause of preventative death. Australians and Britons tend to follow US trends. Lets hope we don't follow them on this one.

And what am I doing about this? Well I lost my appetite after reading Fatland. I am personally someone at risk of going this way. I have lost a few kilos in the last four weeks and now have a BMI of 27. Not obese but overweight. I also have two boys: one three and one almost two. A high correlation exists between children who are overweight in kindergarten and those overweight or obese in adults. So it is a family wide effort to all stay healthy. It makes it easier too to all me consistent.

And what is McDonalds doing now? In Australia this month they have started using Canola oil rather than beef tallow and Palm oil. And "low sugar" bread. I remember asking the manager of the Gladesville store what they cooked their fries in four years ago after reading in The Australian Newspaper that it was beef tallow, and being told it was vegetable oil. I think these changes are good. I was in the Milton store today to buy a coffee and saw that the supersize portioning is still in place. Fatland takes a rather cynical view that some of the pro health choices were only introduced to disarm the veto person.

Anyway I highly recommend this book.

Posted by gluck at 05:00 AM | Comments (0)