Inhomogeneous Poisson Processes
- In contrast to homogenous, the rate changes over time.
- Note that ISIs are not independent
Proof:
Are the ISIs independent? Calculate: $\mathrm{Pr}\{t_2 > s | t_1 = t\} = \mathrm{Pr}\{N(t+s) - N(t) = 0\}$
Let $\mu(t) = \int^t_0 \lambda (r) \mathrm{d}r$
$\mu(t+s) - \mu(t) = \int_t^{t+s} \lambda(r) \mathrm{d}r$
$\mathrm{Pr}\{t_2 > s | t_1 = t\} = \mathrm{Pr}\{N(t+s) - N(t) = 0\}$
$= \dfrac{(\mu(t+s) - \mu(t))^0 e^{-(\mu(t+s) - \mu(t))}}{0!}$
$=e^{-(\mu(t+s) - \mu(t))}$
Since $\mathrm{Pr}\{t_2 > s| t_1 = t\}$ is a function of $t$, then the distribution of $t_2$ depends on $t$ (the value $t_1$ takes on), so $t_1 \not\!\perp\!\!\!\perp t_2$.
Generating Poisson Processes
- Generate $t_1, t_2,\,…\,$using
np.random.exponential
- Note that it accepts ($\beta = \frac{1}{\lambda}$)
- Add the ISIs until the sum is greater than $\tau$.
- $N\sim\mathrm{Poi}(\lambda\tau)$ using
np.random.poisson
- If there are $N$ spikes in an interval $\tau$. Are the $t_i$s independent? No. If $t_1$ is 850 ms, $t_2$ must be less than $\tau$ - 850 ms.
- To get the times of the spikes, generate from a uniform distribution
Generating Inhomogenous Poisson Processes
- For $\lambda(r)$, determine $\lambda_{max}$.
- Generate an homogenous Poisson process with rate $\lambda_{max}$.