# Thread: Challenging problem!!!!!!! Really difficult

1. ## Challenging problem!!!!!!! Really difficult

A person is trapped in a dark cave with three ways out. One of them leads to safety after 2 hours of travel while the other two would return him to the cave after 3 and 5 hours of travel respectively. Assuming that the person is equally likely to opt for any of the openings at all times, what is the expected length of time he spends travelling until reaching safety?

Thank you.

2. ## Re: Challenging problem!!!!!!! Really difficult

I'm going to do it as slowly as I please.
I tried by brute force to at least find a pattern.

Label the paths A, B, C
where A = 2, B = 3, C = 5 hours

and P be the probability of choosing a certain path, and the path ends after traveling path A.

P(A) = 1/3
P(A|B) = P(A|C) = 1/9
P(A|B|B) = P(A|B|C) = P(A|C|B) = P(A|C|C) = 1/27
P(A|B|B|B) = P(A|B|B|C) = P(A|B|C|B) = P(A|C|B|B) = P(A|B|C|C) = P(A|C|B|C) = P(A|C|C|B) = P(A|C|C|C) = 1/81

then the expected value is 2(1/3) + (5+7)(1/9) + (8+10+10+12)(1/27) + (11+13+13+13+15+15+15+17)(1/81) + ... = 2(1/3) + 12(1/9) + 30(1/27) + 112(1/81) + ...

the sum appears to diverge to infinity, but I would have to prove it.

3. ## Re: Challenging problem!!!!!!! Really difficult

Are we to believe that third sentence ?
'Assuming that the person is equally likely to opt for any of the openings at all times ....'
Either the exits are disguised in some way or the person is a total idiot, potentially trying the same no exit over and over again.
If this is not the case, there seem to be five possible routes to freedom.
Using the notation of the previous post,
(1) A probability 1/3,
(2) BA probability 1/6
(3) CA probability 1/6
(4) BCA probability 1/6
(5) CBA probability 1/6.
That gives an expectation of six hours, which in a way is strange since none of the routes to freedom take precisely six hours.

4. ## Re: Challenging problem!!!!!!! Really difficult

Why would that be strange? An "expectation" is basically an average and we seldom expect averages to be exact numbers.

5. ## Re: Challenging problem!!!!!!! Really difficult

I did say 'in a way'. I was looking at it from a naive jokingly point of view.
Someone saying ' how long would you expect to take to find your way out' ? and on receiving the reply 6 hours saying that none of the possible exit scenarios would take 6 hours.

6. ## Re: Challenging problem!!!!!!! Really difficult

What's wrong with this?

Let T be the amount of time spent in the cave.

Then E(T) = 1/3(2 + (3 + E(T)) + (5 + E(T)))

=> E(T)(1 -(2/3) = 10/3
=> E(T) = 10

8. ## Re: Challenging problem!!!!!!! Really difficult

Originally Posted by StaryNight
What's wrong with this?

Let T be the amount of time spent in the cave.

Then E(T) = 1/3(2 + (3 + E(T)) + (5 + E(T)))

=> E(T)(1 -(2/3) = 10/3
=> E(T) = 10
That is exactly what I did. The idea is that it is recursive, the expected additional time after returning to the cave is the same as the original expected time.