# Probability of one Poisson variable exceeding another with equal means

Let $X$ and $Y$ be independent random Poisson variables, both with parameter $\lambda$. Is there a simple closed form expression for $P(X \leq Y)$?

I know from this question that we have to evaluate something like the sum $$\sum_{\substack{0 \leq x, y \\ x \leq y}} \frac{\lambda^{x + y}}{x!y!},$$ but how is that done?

## 2 Answers

You assume equal means. We have

• $1= P(X < Y) + P(Y<X) + P(Y=X)$
• $P(Y<X) = P(X<Y) =q$
• With $p=P(Y=X) \Rightarrow q =\frac{1-p}{2} \Rightarrow P(X\leq Y)=\frac{1-p}{2} + p =\frac{1}{2}(1+p)$
• $p = P(X=Y) =e^{-2\lambda} \sum_{n=0}^{\infty} \frac{\lambda^{2n}}{(n!)^2} = e^{-2\lambda}I_0(2\lambda)$ $$\Rightarrow P(X\leq Y) = \frac{1}{2}(1+p) = \frac{1}{2}(1+e^{-2\lambda}I_0(2\lambda))$$
• This is much simpler! I was hoping that someone had a better way to derive it. – rwbogl May 17 '18 at 15:48

If you accept special functions as closed forms, then the answer is $$P(X \leq Y) = \frac{1}{2} (1 + e^{-2\lambda} I_0(2\lambda)),$$ where $I_0$ is a modified Bessel function of the first kind. To derive this directly, read on.

The probability can be evaluated as the following sum: \begin{equation*} P(X \leq Y) = \sum_{\substack{0 \leq x, y \\ x \leq y}} \frac{\lambda^x}{x!} e^{-\lambda} \frac{\lambda^y}{y!} e^{-\lambda} = e^{-2\lambda} \sum_{\substack{0 \leq x, y \\ x \leq y}} \frac{\lambda^{x + y}}{x! y!}. \end{equation*} Ignore the $e^{-2\lambda}$ factor for a moment. This sum is symmetric in the sense that swapping summation variables does not change the terms. That is, $\lambda^{x + y}/ x!y! = \lambda^{y + x} / y!x!$. This lets us exploit the Iverson bracket identity $$[0 \leq x \leq y] + [0 \leq y \leq x] = [0 \leq x, y] + [0 \leq x = y].$$ Multiplying by our term and summing over all integers $x$ and $y$ yields \begin{equation*} \sum_{\substack{x, y \\ 0 \leq x \leq y}} \frac{\lambda^{x + y}}{x!y!} + \sum_{\substack{x, y \\ 0 \leq y \leq x}} \frac{\lambda^{x + y}}{x!y!} = \sum_{0 \leq x, y} \frac{\lambda^{x + y}}{x!y!} + \sum_{0 \leq x} \frac{\lambda^{2x}}{(x!)^2}. \end{equation*} Since our sum is symmetric, the two sums on the left are equal. On the right side, the first sum immediately factors as $(\sum_{x \geq 0} \lambda^x / x!)(\sum_{y \geq 0} \lambda^y / y!) = e^{2\lambda}$. The second sum can be seen to be $I_0(2\lambda)$, where $I_0(t)$ is defined as $$I_0(t) = \sum_{k = 0}^\infty \frac{\left(\frac{1}{4} t^2\right)^k}{(k!)^2}.$$ All together, this implies \begin{equation*} 2\sum_{\substack{x, y \\ 0 \leq x \leq y}} \frac{\lambda^{x + y}}{x!y!} = e^{2\lambda} + I_0(2\lambda). \end{equation*} Trivial manipulation then gives $$P(X \leq Y) = \frac{1}{2}(1 + e^{-2\lambda} I_0(2\lambda)),$$ as we claimed.

This can be "checked" by simulating the event. For $\lambda = 10$, our predicted probability is $(1 + e^{-20} I_0(20))/2 \approx 0.54489$. Using this code, one simulation generated $10^5$ $(X, Y)$ pairs of Poisson random variables of mean $10$. The actual proportion of pairs with $X \leq Y$ was $0.54598$, not too far from what we expected.