Find the probability that $B$ obtains a new kidney. Look at this problem:

Two individuals, $A$ and $B$, both require kidney transplants. If she
  does not receive a new kidney, then $A$ will die after an exponential
  time with rate $\mu_A$, and $B$ after an exponential time with rate
  $\mu_B$. New kidneys arrive in accordance with a Poisson process
  having rate $\lambda$. It has been decided that the first kidney will
  go to $A$ (or to $B$ if $B$ is alive and $A$ is not at that time) and
  the next one to $B$ (if still living). What is the probability that $B$ obtains a new kidney?

The solution that the author has offered for this problem is $$\frac{\lambda}{\lambda+\mu_B}\frac{\lambda+\mu_A}{\lambda+\mu_A+\mu_B}$$ but I have another answer to this problem as below:
$$\begin{align*}Pr(B\text{ obtains kidney})&=Pr(B\text{ obtains kidney}\mid\space A\space is \space alive)\cdot Pr(A\space is \space alive)\\[0.2cm]&+Pr(B\text{ obtains kidney}\mid\space A\space is\space not \space alive)\cdot Pr(A\space is\space not \space alive)\\[0.2cm]&=\frac{\lambda}{\lambda+\mu_B}\frac{\mu_A}{\lambda+\mu_A}+\frac{\lambda}{\lambda+\mu_A}Pr(B\text{ obtains kidney}\mid \space A\space is \space alive)\end{align*}$$
Now as when $A$ is alive while the first kidney arrives, $B$ must wait for the second kidney and the distribution of the second kidney arrival time is a Gamma distribution with parameters $n=2,\lambda$ and hence 
$$Pr(B\text{ obtains kidney}\mid \space A\space is \space alive)=Pr(X_1+X_2<X_B)$$
in which $X_1+X_2$ is the time of arrival of the second kidney, and $X_B$ is the death time of $B$, so we have 
$$Pr(B\text{ obtains kidney}\mid \space A\space is \space alive)=Pr(X_1+X_2<X_B)=\left(\frac{\lambda}{\lambda+\mu_B}\right)^2$$
So we have 
$$\begin{align*}Pr(B\text{ obtains kidney})&=\frac{\lambda}{\lambda+\mu_B}\frac{\mu_A}{\lambda+\mu_A}+\frac{\lambda}{\lambda+\mu_A}Pr(B\text{ obtains kidney}\mid \space A\space is \space alive)\\&=\frac{\lambda}{\lambda+\mu_B}\frac{\mu_A}{\lambda+\mu_A}+\frac{\lambda}{\lambda+\mu_A}\left(\frac{\lambda}{\lambda+\mu_B}\right)^2\end{align*}$$
and obviously is different with the answer of the book. Can any one help me to find my mistake?
 A: You have $3$ exponential times ("clocks") running. These are 


*

*$A$'s lifetime, with rate $μ_Α$,

*$Β$'s lifetime, with rate $μ_Β$ and

*the time until the next kidney arrival, with rate $λ$.


The author's solution is justified as follows (although there are also faster ways to explain it). $B$ will obtain a kidney if following cases obtain:


*

*$A$'s "clock" expires first, which occurs with probability $$\frac{μ_Α}{λ+μ_Α+μ_Β}$$ (minimum of independent exponential random variables) and then from the two remaining "times" ($B$'s lifetime and time for next kidney arrival), the time for the next kidney arrival expires first, which occurs with probability $$\frac{λ}{λ+μ_Β}$$ (here we used the memoryless property of the exponential distribution, to obtain that the remaining times are again exponentially distributed).

*the time until the first kidney arrival expires first, which occurs with probability $$\frac{λ}{λ+μ_Α+μ_Β}$$ and then from the two remaining times ($B$'s lifetime and time for next kidney arrival, remember that $A$ took the first kidney), the time for the next kidney arrival expires first, which occurs with probability $$\frac{λ}{λ+μ_Β}$$


Bring these together you obtain the solution $$\frac{μ_Α}{λ+μ_Α+μ_Β}\frac{λ}{λ+μ_Β}+\frac{λ}{λ+μ_Α+μ_Β}\frac{λ}{λ+μ_Β}=\frac{λ}{λ+μ_Β}\frac{λ+μ_Α}{λ+μ_Α+μ_Β}$$ 

The mistake in your approach is that you ignore one "clock". Therefore you never get three terms in the denominators, despite the fact that there are three times (clocks) running. For example when you calculate the probability $Pr(B \text{ obtains a kidney} \mid A\space is\space not \space alive)$ ( where $A$ is not alive when the first kidney arrives) you have apparently ignored the fact that $B$ could have died before $A$. 
A: I stumbled on this same problem in Sheldon M. Ross, "Introduction to Probability Models" (10th ed., p. 359).
My first attempt was the same, conditioning on whether A does receive a kidney or not. That didn't agree with Monte Carlo simulation I did (see below), so my second attempt was conditioning on the time when the first kidney arrives:
$$ \mathbb{P} \{ \mathcal{B}: \text{B gets a kidney} \} = \int_0^\infty \mathbb{P} \{ \mathcal{B} \, | \, T = t \} \, \text{pdf}_T (t) \, dt $$
Writing out the integral, which is just a normalization of three exponential functions:
$$ \int_{0}^{\infty} (e^{-\alpha t} \, e^{-\beta t} \, \frac{\lambda}{\lambda + \beta} + (1-e^{-\alpha t}) \, e^{-\beta t}) \, \lambda \, e^{-\lambda t} dt $$
Argument behind it: if A is alive by $T = t$, B should be too, and B should live to see the second kidney (using memorylessness). If A isn't alive by $t$, B should be.
Comparing results of the two attempts with a Monte Carlo simulation, with $\lambda = 0.5$, $\alpha = 1$, $\beta$ in the range 0.15 to 3 with step 0.15, and with 1000 simulations per value of $\beta$, shows that not only does the first attempt seem reasonable to an untrained mind, it produces relatively good results too. It deviates more at higher $\beta$ where the chance of B dying sooner increases.

