Thursday, July 14, 2011

Finding the heavier ball from eight identical balls

You have eight billiard balls. One of them is "defective", meaning that it weighs more than the others. How do you tell, using a physical balance, which ball is defective in two weighing?
A physical balance is a simple two-pan setup, like the one the blindfolded figure of Justice holds. It tells you which of the two pans is heavier, though not by how much. It can also tell you when the two pans are of equal weight.
You can't just add one ball at a time thinking its one weighing, however, you may put any number of balls in each bowl.

Solution:
The obvious approach will not work. That would be to weigh four balls against four balls. The heavier pan would have to contain the defective ball. Split that group's balls into two pairs and weigh the pairs against each other. Again, the heavier pan has to contain the defective ball. You’re then out of your two allotted weighing. There is no way to decide which of the two suspect balls is heavier.
The solution is to make full use of the fact that the balance can tell you if two pans are equal. Whenever the two pans are of equal weight, you can conclude the defective ball is not in either pan.

For the first weighing, pick any three balls and weigh them against any other three balls. This has two basic outcomes.

One is that the balance finds the two pans equal. In that case, the defective ball must be one of the two you didn’t weigh. For the next and last weighing, just compare the two so-far-untested balls. The heavier one has to be the defective ball.

The other possible outcome of the first weighing is that the balance finds one of the two pans heavier. The defective ball must be in the heavier pan. For the final weighing, pick any two of the balls in the heavier pan and compare them. If one is heavier, it’s the defective ball. If both are equal, the defective ball has to the third ball that you didn’t weigh this time.

This puzzle is known throughout the world. It appeared, for instance, in Boris Kordemsky’s Mathematical Know-How (1956), the best-selling puzzle book of the Cold War Soviet Union.
 
Source:
"How Would You Move Mount Fuji?"
Microsoft's Cult Of The Puzzle
By William Poundstone

No comments:

Post a Comment