# Conditional probability in Poisson distribution

conditional probabilitypoisson distributionpoisson processstatistics

The number of accidents that a person has in a given year is a Poisson random variable with mean $$\lambda$$. However we may suppose that the rate $$\lambda$$ depends on the person or proportion of the population. Suppose that $$\lambda = 4$$ for 65% of the population and $$\lambda = 5$$ for other 35% of the population. What is the conditional probability that a person will have 3 accidents in a given year, given that he/she had no accidents in the preceding year?

$$\textbf{Answer:}$$

Let's define two events for a person A = 3 accidents in a given year and B = No accident in the last year.

So, we want to calculate $$P(A|B)$$. Now, $$P(\text{k accidents in 1 year}) = \frac{(rt)^ke^{-rt}}{k!}$$ with $$\lambda =rt$$. Since, time is 1 year here, $$\lambda = r$$.

Now, the events in poisson distribution happen independently, i.e the number of accidents happening this year will not be affected by the number of accidents in last year, and hence $$P(A|B) = P(A)$$

$$P(A) = 0.65 \times \frac{4^3e^{-4}}{3!} + 0.35 \times \frac{5^3e^{-5}}{3!} = 0.17612$$

But, this answer is being marked incorrect, Is the solution incorrect? why? If so, then to solve this conditional probability, we will have to take the usual approach, i.e
$$P(A|B) = \frac{P(A\cap B)}{P(B)}$$

How to calculate the $$P(A\cap B)$$ then?

Thanks for the help.

Think of the situation as a coupled experiment. First, you choose $$\lambda$$ randomly according to the mentioned probabilities. Then, the number of accidents in year $$j$$ is a $$\text{Poisson}(\lambda)$$-distributed random variable $$X_j$$.
Intuitively, if the accidents in year $$1$$ were $$0$$, then it is more likey, that $$\lambda$$ is $$4$$ not $$5$$. So $$A = \{X_2 = 3\}$$ and $$B = \{X_1 = 0\}$$ are not independent, they're only independent given that $$\lambda = 4$$ or $$\lambda = 5$$.
More formally: $$\mathbb{P}(A \cap B) = \mathbb{P}(A \cap B \, \vert \, \lambda = 4)\mathbb{P}(\lambda = 4) + \mathbb{P}(A \cap B \, \vert \, \lambda = 5)\mathbb{P}(\lambda = 5) \\ = \mathbb{P}(A \, \vert \, \lambda = 4)\mathbb{P}(B \, \vert \, \lambda = 4)\mathbb{P}(\lambda = 4) + \mathbb{P}(A \, \vert \, \lambda = 5)\mathbb{P}(B \, \vert \, \lambda = 5)\mathbb{P}(\lambda = 5)$$ and $$\mathbb{P}(B) = \mathbb{P}(B \, \vert \, \lambda = 4)\mathbb{P}(\lambda = 4) + \mathbb{P}(B \, \vert \, \lambda = 5)\mathbb{P}(\lambda = 5).$$.