PDA

View Full Version : Probability Problem (non-poker)

RocketManJames
09-12-2003, 01:52 PM
For those who like puzzles/problems...

A friend gave me a probability puzzle to solve. I was able to come up with a 'simplified' formula that must hold true at the right answer, but I had to iterate using a computer to solve it. Is there a way to solve the following problem simply and without having to iterate?

Z placed a box on the table and told X to take out five balls from it (X didn't know anything about their colour/number). He removed five blue balls. Surprised, Z exclaimed: That that would happen was an exact 50-50 chance. What is the smallest number of balls and how many of them blue should he have placed in the box to get that result?

I will post my 'iterated answer' with my reasoning in a separate post.

-RMJ

RocketManJames
09-12-2003, 01:58 PM
I reasoned that there need only be two types of balls, Blue and Non-Blue (let's call it W), and that (B c 5) / [(W+B) c 5] = 1/2.

This reduced to
[B*(B-1)*...*(B-4)] / [(B+W)*(B+W-1)*...*(B+W-4)] = 1/2.

I did not see a straightforward way to get a B and W that satisfies the above, so I had to iterate using a computer.

The result I got was B=9, W=1.

Bozeman
09-12-2003, 02:19 PM
For this to be true, there must be at least one (call it red) other ball in the box. The one red ball will drawn half the time if there are 10 total balls. Any solution with more red balls will have more total balls. Thus, 9 blue, one "red".

Craig

thylacine
09-16-2003, 11:02 AM
How about 2 red and (17-sqrt(201))/2 blue? /images/graemlins/smirk.gif

Copernicus
09-16-2003, 11:05 AM
Another way to reason it from where you got is:

Invert both sides of your equation and call B+W=T(otal) (just to make thinking about it easier) .

Then T*(T-1)*(T-2)*(T-3)*(T-4)/(B)*(B-1)*(B-2)*(B-3)(B-4)=2

For the ratio to be 2, if you factor all of the numbers in the N(umerator) and (Denominator) into their prime factors, everything has to cancel in the N and the D except 2*P in the N and P in the D.

Since all but one of the prime factors exist in both the N and D, the product of the non-unique prime factors in each the N and D must be the same. The constraints that the original numbers are consecutive in both N and D, and their products are the same means they must be the same numbers. (This is provable, but beyond this little post).

The problem therefore reduces to, "what is the smallest set of 5 consecutive numbers in the numerator that has 4 identical consecutive numbers in the denominator, except that the remaining number in the N is 2*the remaining number in the D?" Since the N is larger, you also know that its non-cancelling number is larger than the non-cancelling number in the D. Further, since the cancelling numbers were shown to be consecutive, the non-cancelling number in the N must be T, and the non-cancelling number in the D must be T-5 (because T-1, T-2, T-3, and T-4 are the only possible cancelling numbers in both the N and D). The problem therefore becomes
T/(T-5)=2, or T=10. Since there is only root to the equation, not only is T=10 the minimum but also the only solution.

Iteration is easier, and from the iteration you can probably prove by induction that there is no larger set of numbers that can meet the criteria. The above, however, is more rigorous and independent of having a "starting point" for an induction proof.

BruceZ
09-16-2003, 01:10 PM
Here's a similar problem. It's a little more interesting.

sock drawer problem (http://forumserver.twoplustwo.com/showthreaded.php?Cat=&amp;Number=161524&amp;page=&amp;view=&amp;sb =5&amp;o=)

elwoodblues
09-16-2003, 03:10 PM
I came up with the same solution - 9 Blue, 1 Red. If I'm wrong, could someone point out my error:

I started with the assumption that it would be 1 Red. From there, I came up with the following equation:

Number of Blue Balls = B
Total = T
B/T * (B-1)/(T-1) * (B-2)/(T-2) * (B-3)/(T-3) * (B-4)/(T-4) = 1/2

We assume Red Balls = 1, therefore T = B + 1

Substituting (B + 1) for T in the equation gets

B/(B+1) * (B-1)/B * (B-2)/(B-1) * (B-3)/(B-2) * (B-4)/(B-3) = 1/2

Now, it's just a matter of simplifying the equation...to get to:
(B-4)/(B+1) = 1/2
Solving for B we get B=9

~elwood

slider77
09-16-2003, 03:34 PM
You guys are oversimplifying the problem I think. The key word in the problem is "exact". If 9/10 are blue, the .9^5 = .5905 = about 59%. That's not "exactly 50/50".

This is more like a linear/integer programming problem - iterations are the only way to get at it. I used Excel and got

5129 = Blue
5892 = Non-Blue

thylacine
09-16-2003, 03:54 PM
Suppose b red balls, t total balls.

Balls are drawn " without replacement".

So Prob(all 5 red|5 drawn) is

C(b,5)/C(t,5) or equivalently P(b,5)/P(t,5)

and NOT b^5/t^5.

It seems you have simply found that 5129/5892 is a rational approximation for (1/2)^(1/5) which in any case is irrational.

slider77
09-16-2003, 05:26 PM
If it's balls are kept out after each draw, it would just be solving algebra.

B = Number Blue Balls
N = Total Balls

First draw: P(Blue ball) = B/N
2nd draw: P(Blue ball) = B-1/N-1

Multiply all draws and set equal to .5

1 Equation, 2 variables - start with N=6 and "trial and error" until the equation balances. Or use Solver in Excel.

DrSavage
09-16-2003, 05:34 PM
You are wrong.
The probability of drawing 5 blue balls from 9 blue and 1 red ball is (9/10)*(8/9)*(7/8)*(6/7)*(5/6) = 5/10=0.5 exactly.
your (0.9)^5 applies to the case when balls would be put back into the box after each removal, which was not the case here.

thylacine
09-16-2003, 06:28 PM
Don't ask

What is the smallest number of balls and how many of them blue should he have placed in the box to get that result?

I've just been talking to a number theorist friend and the interesting question is this:

What is the LARGEST number of balls and how many of them blue should he have placed in the box to get that result?

Is there a largest? Is there any solution other than the obvious one? Same question with any number 3 or more balls. (With the 2 ball version there are infinitely many solutions.)

slider77
09-16-2003, 09:35 PM
Here's a simple way without a computer.

Since it asks for the minimum number of balls, the number of blue balls (B) would have to be just 1 less than the number of total balls (N). It can't be like 5000 total and 4852 are blue - even though something like that could work.

Prob(5 blue balls in a row) =
B/N * B-1/N-1 * B-2/N-2 * B-3/N-3 * B-4/N-4 = .50

Substitute B=N-1...do the cancelling....and you get:

(N-5)/N = .5

N=10
B=9

Copernicus
09-18-2003, 11:41 AM
The original post asked for a solution without iteration. Guessing (or "assuming") IS iteration when you dont guess right the first time!

thylacine
09-18-2003, 01:16 PM
They are using a method referred to by mathematicians by the technical term "cracking a walnut with a sledgehammer".

Copernicus
09-18-2003, 11:33 PM
those are the applied mathematicians of course.