Ayobonike O. answered 9d
MBA & Data Scientist: Expert Python, R & SAS for Business Analytics
Poisson Process Simulation & Analysis
This simulation uses the Uniform Product Method. This relies on the fact that if $U_1, U_2, \dots$ are i.i.d. $Uniform(0,1)$, then $X = I - 1$ follows a Poisson distribution with parameter $\lambda$, where $I$ is the smallest index such that:
$$\prod_{i=1}^{I} U_i < e^{-\lambda}$$
1. Restaurant Arrival Simulation
For an arrival rate of $\lambda = 25/\text{hour}$:
- 5-min interval: $\lambda_5 = 25/12 \approx 2.0833$
- 10-min interval: $\lambda_{10} = 25/6 \approx 4.1667$
- 30-min interval: $\lambda_{30} = 25/2 = 12.5$
Key Findings:
- Mean vs. Variance: In a Poisson distribution, $E[X] = Var(X) = \lambda$. Our simulation (10,000 trials) confirms this, with both values hovering around $4.17$ for the 10-minute intervals.
- Probability Analysis: The probability of seeing $>10$ cars in 30 minutes is calculated as $1 - P(X \le 10, \lambda=12.5)$, resulting in $\approx 0.7029$.
2. Convergence to Normal Distribution (CLT)
As $\lambda$ increases, the Poisson distribution loses its skewness and begins to resemble a Normal distribution. By transforming the variable to $Y = \frac{X - \lambda}{\sqrt{\lambda}}$, we observe that $Y$ converges to a Standard Normal Distribution $N(0,1)$.
Python Implementation
Python