Variance of total number of customers arriving

363 Views Asked by At

Suppose a customer arrival to a gas station follows a non-stationary Poisson process with the following arrival rate per hour:

  • [6am - 9am] has $\lambda = 20$.

  • [9am - 3pm] has $\lambda = 8$.

  • [3pm - 7pm] has $\lambda = 12$.

  • [7pm - 10pm] has $\lambda = 6$.

Compute the variance of total number of customers that arrive in a single day.

My attempt Let $X = $ total number of customers that arrive in a single day. Then $Var(X) = E(X^2)- [E(X)]^2 = (20^2\times 3+8^2\times 6+12^2\times 4 + 6^2\times 3) - (20\times 3+8\times 6+12\times 4 + 6\times 3)^2 = 2268-174^2 = -28008$

However, this number is negative, so it does not make sense in the context of this problem. But I could not see why it's wrong though, considering the way to compute $E(X)$ is actually correct. Could someone please point out the mistake for $E(X^2)$?

2

There are 2 best solutions below

1
On BEST ANSWER

Two key points:

  1. A Poisson distribution with parameter $\lambda$ (i.e. its mean and variance) has $E(X^2)=\lambda+\lambda^2$: this is the error in your calculation as you were using $E(X^2)=\lambda^2$

  2. The sum of two independent Poisson distributions with parameters $\lambda$ and $\mu$ is another Poisson distribution with parameter $\lambda+\mu$

So you have $16$ independent Poisson distributions and their sum is another Poisson distribution with parameter $20\times 3+8\times 6+12\times 4 + 6\times 3 =174$. This is therefore the variance of the sum as well as being its mean.

3
On

You have a Poisson process $N(t)$ on the probability space $(\Omega, \mathcal{F}, P)$. Let X=N(16), i.e. the total number of customers in a single 16-hour day.

You want to use that $Y_1=N(3)-N(0)$, $Y_2=N(9)-N(3)$, $Y_3=N(13)-N(9)$ and $Y_4=N(16)-N(13)$ are independent and each $\text{Poisson}(\lambda_i)$-distributed, where

$\lambda_1 = 3\cdot 20=60, \lambda_2 = 6 \cdot 8 = 48, \lambda_3 = 4 \cdot 12 = 48, \lambda_4 = 3 \cdot 6 = 18$.

For a Poisson-distributed random variable $M$ with parameter $\lambda_M$, $\text{Var}(M)=\mathbb{E}[M]=\lambda_M$.

Now $\mathbb{E}[X]=\mathbb{E}[Y_1+Y_2+Y_3+Y_4]=\sum_{i=1}^4 \mathbb{E}[Y_i]=\sum_{i=1}^4 \lambda_i$, and due to independence,

$\text{Var}(X)=\text{Var}(Y_1+Y_2+Y_3+Y_4)=\sum_{i=1}^4 \text{Var}(Y_i) = \sum_{i=1}^4 \mathbb{E}[Y_i] = \mathbb{E}[X]$.