# Poisson Conditional Probability with varying $\lambda$

The number of accidents that a given person has in a given year is a Poisson random variable with mean $\lambda$, independently each year. However, suppose that $\lambda$ changes from person to person: $\lambda = 2$ for $60\%$ of the population and $\lambda = 3$ for the remainder.

If a person is chosen randomly, what is the conditional probability that he will have 3 accidents in a year, given that he has no accidents the previous year?

# Attempts

I denote the time beginning of the time at the first year, $t_0=0$, I call the number of accidents $a_t$ for a given period of time $t$. I also denote the average $\lambda$ as, $$\left< \lambda \right> = \sum^2_1w_i\lambda_i = 0.4*3+0.6*2$$ The Poisson distribution is, $$P(X=n) = e^{-\lambda}\lambda^n/n!$$ I think I have correctly calculated, $$P(a_1=0) = \sum_{i=1}^2 w_ie^{-\lambda_i}\lambda_i^0/0! = 0.4e^{-3}+0.6e^{-2}$$

I believe calculation requires me to calculate,

$$P(a_{2-1} = 3 | a_{1}=0) = \frac{P(a_{2-1} = 3 , a_{1}=0)}{P(a_{1}=0)}$$

Is this equal then to, $$\require{cancel} P(a_{2-1} = 3 | a_{1}=0) = \frac{P(a_{2} = 3)}{P(a_{1}=0)} = \sum_{i=1}^2 \frac{\cancel{w_i}e^{-2\lambda_i}(2\lambda_i)^3/3!}{\cancel{w_i}e^{-\lambda_i}\lambda_i^0/0!}$$

Looking for some hints in the right direction as I'm trying to pick up the basics of probability for a more advanced postgrad course

The solution to the original question "If a person is chosen randomly, what is the conditional probability that he will have $3$ accidents in a year, given that he has no accidents the previous year?" depends on the prior distribution of the population, so if that cancels out then you may have made an error.
The posterior proportion of those who had no accidents the previous year who have $\lambda=3$ is $\dfrac{0.4e^{-3}}{0.4e^{-3}+0.6e^{-2}}$ and who have $\lambda=2$ is $\dfrac{0.6e^{-2}}{0.4e^{-3}+0.6e^{-2}}$.
So the probability that somebody who had no accidents the previous year has $3$ accidents this year is $$\dfrac{0.4e^{-3}}{0.4e^{-3}+0.6e^{-2}} \dfrac{e^{-3} 3^3}{3!} + \dfrac{0.6e^{-2}}{0.4e^{-3}+0.6e^{-2}}\dfrac{e^{-2} 2^3}{3!}$$ which in your style of formulation might be written $$\frac{\displaystyle \sum_{i=1}^2 w_i \,e^{-2\lambda_i }\lambda_i^{0+3} /(0!3!)}{\displaystyle \sum_{i=1}^2 w_i \,e^{\lambda_i } \lambda_i^{0} /0!}$$ but you cannot cancel the $w_i$s
• @AlexanderMcFarlane: The differences are separate summations in the numerator and denominator, and a stray $2$ you introduced in the numerator. So you were close – Henry Jan 14 '16 at 23:59
• @user10796158 - $0.4e^{-3}$ is the joint probability that somebody has $\lambda=3$ and no accidents in a year, while $0.6e^{-2}$ is the joint probability that somebody has $\lambda=2$ and no accidents in a year. So $\frac{0.4e^{-3}}{0.4e^{-3}+0.6e^{-2}}$ is the posterior probability that somebody has $\lambda=3$ given that they had no accidents in a year – Henry yesterday