Wednesday, November 6, 2013

how to weigh 12 coins: a solution

With regards to the previous puzzle, I'd better write this down before I forget... Took quite of bit of thinking...

So here goes my three steps:

1) Cluster the 12 coins into 3 groups of 4, and weigh 2 groups. Say the groups are G1, G2 and G3, and weigh G1 against G2.

Two scenarios
1.1 G1 = G2
Then both G1 and G2 contain authentic coins. The fake coin must be in G3, and finding it in a group of 4 in two steps is quite straightforward.
1.2 G1 and G2 weigh differently. Say G1>G2.

2) Let G1 = {x1,x2,x3,x4}, G2 = {y1,y2,y3,y4}. Make 2 new groups K1 = {x1,x2,y1} and K2 = {x3,x4,y2}, and weigh these 2 groups.

2.1 K1 = K2
Then the fake coin is either y3 or y4, and can be identified in one step by comparing one coin to a known real coin.
2.2 K1 and K2 weigh differently. Say K1>K2 (K2>K1 is symmetric).
Then y1, x3 and x4 must be real. If the fake coin is heavier, then either x1 or x2. If it is lighter then y2. And we'll just need the next step to find out.

3) Weigh x1 and y2 against 2 known real coins.

3.1 {x1,y2} = 2 real coins
Yay, x2 is the fake coin :)
3.2 {x1,y2} weigh differently from the 2 real coins.
If {x1,y2} is heavier, then the fake coin is heavier, so there, x1 is fake :)
If otherwise, then y2 is fake :)

No comments:

Post a Comment