Sum of independent exponential variables
If the time until the first event in a homogeneous Poisson process with rate \(\lambda\) is \(Y_1\), the time from the first event until the second one is \(Y_2\), ..., and the time from the \((k-1)\)'th until the \(k\)'th event is \(Y_k\), then the total time until the \(k\)'th event can be written as
\[ X \;\; = \; \; \sum_{i=1}^k {Y_i} \]From the memoryless property of a homogeneous Poisson process, the \(\{Y_i\}\) are independent and they all have \(\ExponDistn(\lambda)\) distributions. The time until the \(k\)'th event \(X\) can therefore be treated as the sum of a random sample of size \(k\) from this exponential distribution.
Since a random variable with an \(\ErlangDistn(k, \lambda)\) distribution has the same distribution as the sum of \(k\) independent \(\ExponDistn(\lambda)\) random variables, we can use the properties of the sum of a random sample to find its mean and variance.
Mean and variance of Erlang distribution
If a random variable, \(X\), has an Erlang distribution with probability density function
\[ f(x) \;\;=\;\; \begin{cases} \dfrac{\lambda^k}{(k-1)!} x^{k-1} e^{-\lambda x} & x \gt 0 \\[0.3em] 0 & \text{otherwise} \end{cases} \]its mean and variance are
\[ E[X] \;=\; \frac k{\lambda}\spaced{and} \Var(X) \;=\; \frac k{\lambda^2} \]Since \(X = \sum_{i=1}^k {Y_i}\),
\[ E[X] \;=\; k \times E[Y_i] \;=\; \frac k{\lambda} \]and
\[ \Var(X) \;=\; k \times \Var(Y_i) \;=\; \frac k{\lambda^2} \]A final useful property of Erlang distributions that adding together two independent Erlang variables (with the same \(\lambda\)) results in a variable that also has an Erlang distribution.
Additive property of Erlang distributions
If \(X_1 \sim \ErlangDistn(k_1,\; \lambda)\) and \(X_2 \sim \ErlangDistn(k_2,\; \lambda)\) are independent, then
\[ X_1 + X_2 \;\;\sim\;\; \ErlangDistn(k_1 + k_2,\; \lambda) \]Since we can write \(X_1 = \sum_{i=1}^{k_1} {Y_i}\) and \(X_2 = \sum_{i=k_1 + 1}^{k_1 + k_2} {Y_i}\) where the \(\{Y_i\}\) are independent exponential variables,
\[ X_1 + X_2 \;=\; \sum_{i=1}^{k_1 + k_2} {Y_i} \]which therefore has an \(\ErlangDistn(k_1 + k_2,\; \lambda)\) distribution.