# 4.5: Uniform Distribution

- Page ID
- 3269

Definition\(\PageIndex{1}\)

A random variable \(X\) has a **uniform distribution** on interval \([a, b]\), write \(X\sim\text{uniform}[a,b]\), if has pdf given by

$$f(x) =\left\{\begin{array}{l l}

\frac{1}{b-a}, & \text{for}\ a\leq x\leq b \\

0, & \text{otherwise}

\end{array}\right.\notag$$

A typical application of the uniform distribution is to model randomly generated numbers. In other words, it provides the probability distribution for a random variable representing a randomly chosen number between numbers \(a\) and \(b\).

The uniform distribution assigns equal probabilities to intervals of equal lengths, since it is a constant function, on the interval it is non-zero \([a, b]\). This is the continuous analog to equally likely outcomes in the discrete setting.