If the time between successive events is independent each with an
exponential distribution with \(\lambda\), then the total time
\(X\) that elapses before all of the next \(n\) events occur is
given by the *Erlang distribution*.

## Probability Density Function

Let \(\alpha=n,\beta=\frac{1}{\lambda}\) in the Gamma distribution. \(n\) is a positive integer.

\begin{equation*}
f(x;\lambda,n)=\frac{\lambda\left(x\lambda\right)^{n-1}e^{-\lambda x}}{(n-1)!}
\end{equation*}

for \(x\ge0\)

## Mean and Variance

Mean: \(\frac{n}{\lambda}\)

Variance: \(\frac{n}{\lambda^{2}}\)