May 25th, 2004

When you change the insides, nobody notices

I find it ironic when people complain that Calc and Notepad haven’t changed. In fact, both programs have changed. (Notepad gained some additional menu and status bar options. Calc got a severe workover.)

I wouldn’t be surprised if these are the same people who complain, “Why does Microsoft spend all its effort on making Windows ‘look cool’? They should spend all their efforts on making technical improvements and just stop making visual improvements.”

And with Calc, that’s exactly what happened: Massive technical improvements. No visual improvement. And nobody noticed. In fact, the complaints just keep coming. “Look at Calc, same as it always was.”

The innards of Calc—the arithmetic engine—was completely thrown away and rewritten from scratch. The standard IEEE floating point library was replaced with an arbitrary-precision arithmetic library. This was done after people kept writing ha-ha articles about how Calc couldn’t do decimal arithmetic correctly, that for example computing 10.21 − 10.2 resulted in 0.0100000000000016.

(These all came from people who didn’t understand how computers handle floating point. I have a future entry planned to go into floating point representations in more detail.)

Today, Calc’s internal computations are done with infinite precision for basic operations (addition, subtraction, multiplication, division) and 32 digits of precision for advanced operations (square root, transcendental operators).

Try it: 1 / 3 × 10000000000 − 3333333333 =. The result is one third exactly. Type 1/x − 3 = and you get zero back. (Of course, if you don’t believe that, then repeat the sequence “× 10000000000 − 3333333333 =” until you’re bored and notice that the answer always comes back as 0.33333333333333333333333333333333. If it were fixed-precision, then the 3’s would eventually stop coming.)

Thirty-two positions of precision for inexact results not good enough? The Power Calculator PowerToy uses the same arithmetic engine as Calc and lets you crank the precision to an unimaginable 512 digits.

Anyway, my point is that—whether you like it or not—if you don’t change the UI, nobody notices. That’s why so much effort is spent on new UI.

Topics
History

Author

Raymond has been involved in the evolution of Windows for more than 30 years. In 2003, he began a Web site known as The Old New Thing which has grown in popularity far beyond his wildest imagination, a development which still gives him the heebie-jeebies. The Web site spawned a book, coincidentally also titled The Old New Thing (Addison Wesley 2007). He occasionally appears on the Windows Dev Docs Twitter account to tell stories which convey no useful information.

0 comments

Discussion are closed.