Archive | October 2010

The Day The Earth Stood Still




Read More…

Data Compression and Crowded Pigeons

WinZip Icon

The Infamous WinZip

Have you ever used a data compression program?  WinZip, WinRAR, bzip2 and gzip are all common data compression software.  If you have ever emailed large pictures, sent or received text files or pdfs, you may have run across these pieces of software.  In general, they take a set of input files, and output a compressed file, which when uncompressed, produce the original files again.  The quite amazing thing that these software applications do is to produce a compressed file whose size is less than the sum of the sizes of the input files.  This is great!  But have you wondered, what would happen if you tried to compress a compressed file?  Would it get smaller?  Could you not, therefore, repeatedly compress the same file over and over till it became insignificantly small?  What is to stop this?  Another question you may ask is, given a compressor, can you compress all files to yield a smaller file?  Why do some files compress more than others?

Read More…

2 Goats 1 Prize

Image via Wikipedia

Consider this scenario:

You have almost won at a game show!  Your host, Monty, gives you one final task.  He lifts the curtains to reveal three closed doors, labeled A, B, and C.  He informs you that behind the doors, in some order, there are two goats and a grand prize.  The doors are identical and there is no way to tell what is behind them.  He asks you to pick a door, which you do, picking one at random (let’s say A).  Monty turns around and, in a fit of generosity, tells you that he will help you out by opening one of the unselected doors that contains a goat (let’s say B).  Having taken one of the doors out of the running, he now gives you a choice.  “Would you like to switch your selection to C or stay with A?”, he asks.

As you stand there, what should you do to have the best chance of winning the grand prize? Is there a systematic way to find out?

Read More…

Aircraft and Treadmills

In this post, I want to address an interesting thought experiment that I “found on the internet”™.  The problem is usually phrased in a few different ways but here is the version I have chosen to attack.

The Problem

It was a calm, sunny day at Horsehead Airport.  An aircraft, ready to fly to a foreign country lines up on the airport runway, carrying out final preparations for takeoff.  On this calmest of days, the evil Dr. Horrible has decided to discombobulate the pilot of our aircraft by swapping out the runway for a long conveyor belt.  This belt is powered by a very powerful motor that can drive the conveyor belt and anything on it at  enormous speeds.  As the pilot throttles up for takeoff, he powers up his conveyor belt to move backwards.  His aim is to move the conveyor belt backwards just fast enough to cancel the aircraft’s forward motion, hence preventing the aircraft from achieving takeoff velocity.  Does he succeed in doing so?  Can the pilot still takeoff his aircraft or is he at the mercy of the evil Dr. Horrible?

What do you think would happen?  Take an intuitive guess.  Part of being a good scientist is getting good at making defensible guesses.  Also part of being a good scientist is realizing when your common sense and gut feeling are going to fail and training to guess more systematically.  When I first ran into this problem many years ago, my gut feeling was “Hmm..  if the conveyor belt moves as fast as the aircraft but in the other direction, then the two would cancel each other out and the aircraft would be at rest, unable to take off!”.  My second thought was “Wait a minute.. maybe the engines can produce enough airflow over the wings that the plane can lift off even if stationary!”.  The Mythbusters investigated a similar question a while back (here is a sneak peek).

Read More…

Confirmatory Tests and False Positives

Consider this.  You feel ill, are running a fever, and feel dizzy.  You go to a nearby hospital and the attending physician suspects that you are suffering from a rare illness called Beetleguese fever.   He orders a test to check his hypothesis which comes back positive for Beetleguese fever[1].  Having seen this test result, you would expect the physician to start treating you immediately.  Instead, he orders another test to confirm the diagnosis.  Why?  Isn’t that just a waste of time and money?  Maybe the test was not accurate enough.  You ask the physician how accurate the test is.  He tells you that it is 99.999% accurate.  “That’s great!”, you exclaim.  The physician retorts, “It’s not good enough.  We need to confirm it independently”.  Why would he say that?  How much more accurate can you get?

If Beetleguese fever is a very rare disease, then the physician is right.  Let us assume that you live in a country with a population of 10 million people.  At any given time, let us assume that 100 individuals  in the population have Beetleguese fever (the physician mentioned that it was very rare).  If a random person from this population was chosen and tested for Beetleguese fever using our 99.999% accurate test, and the test result came back as positive for the disease, the probability that the subject actually has Beetleguese fever is only around 50%!  If you find this fact hard to believe, read on and I will show you exactly how we arrive at this number and why this is the case.

Read More…