# Expected time between two events

I'm having trouble with the following problem:

Consider a game between two players A and B. Player A must complete three tasks each of which take an exponentially distributed amount of time with rates 10, 5, and 15 minutes each. Player B must only complete one task that takes an exponentially distributed amount of time with rate 30 minutes.

1. What is the expected amount of time that Player A finishes before Player B
2. For what rate should Player B aim so that the probability that he wins against player A with probability 0.99. That is $P(t_B > t_A) \le 0.01$

Here's what I have so far:

Player A's time to completion follows a hypoexponential distribution of the form $f_{X_1+X_2+X_3}(t) = \frac{\lambda_2}{\lambda_2-\lambda_1}\cdot\frac{\lambda_3}{\lambda_3-\lambda_1}\cdot\lambda_1e^{-\lambda_1t} + \frac{\lambda_1}{\lambda_1-\lambda_2}\cdot\frac{\lambda_3}{\lambda_3-\lambda_2}\cdot\lambda_2e^{-\lambda_2t} + \frac{\lambda_1}{\lambda_1-\lambda_3}\cdot\frac{\lambda_2}{\lambda_2-\lambda_3}\cdot\lambda_3e^{-\lambda_3t}$

which has mean $\lambda_1^{-1}+\lambda_2^{-1}+\lambda_3^{-1}$ with $\lambda_1=1/10, \lambda_2=1/5, \lambda_3=1/15$. Then Player A's expected time to completion is $E[f_A(t)] = 30$

I also know that Player B's expected time to completion is $E[f_B(t)] = E[\frac{1}{30}e^{-t/30}] = 30$

But how do I determine $E[f_A(t) - f_B(t)]$. Since expectation is linear, this would imply that $E[f_A(t) - f_B(t)] = E[f_A(t)] - E[f_B(t)] = 30 - 30 = 0$. My intuition tells me that I would expect player A to win more frequently than player B because there is more potential for variation for A to finish his three tasks than player B, but this intuition is not present in the above math. I guess the issue I have is I don't think this would be a fair game because the variations are too different.

Additionally, the distribution $f_A(t) - f_B(t) = \int_{0}^{\infty}f_A(x)f_B(x-y)dx$ because $f_A(t)$ and $f_B(t)$ are independent. But I'm not sure what to do with this distribution once I have it.

Concerning the 'self-study' tag: I'm independently going through Ross' "Introduction to Probability Models" (2014, 11th edition) and I came up with this question myself to make sure I understand the material correctly. I looked in the Exercises section to see if any similar questions were asked, but I did not find any. I might be using this type of question analysis in a larger project, but I have not taken any formal classes in this area. I'm posting here to make sure my understanding of the material is correct since I don't have a professor with whom to check my work.

• Please add the [self-study] tag & read its wiki. – gung May 11 '16 at 20:54
• (1) Don't use your intuition: calculate the variances of the times. The result might surprise you. (2) The expression "$E[f_A(t) - f_B(t)]$" makes little sense and is useless: it asks to take the expectation of a constant. – whuber May 12 '16 at 14:08