Example 1 — The Uniform Distribution
A continuous random variable \( X \) has density:
\[ f_X(x) = \begin{cases} \dfrac{c}{b-a}, & a \le x \le b \\[1em] 0, & \text{otherwise} \end{cases} \]where \( c \) is a positive constant to be determined.
- Sketch \( f_X(x) \).
- Find the value of \( c \) that makes \( f_X \) a valid PDF.
- Verify the total area equals 1 by integration.
- With \( a = 3 \) and \( b = 8 \), compute \( P(4 \le X \le 7) \).
View solution
(a) Sketch. The function is constant \( \dfrac{c}{b-a} \) on \( [a, b] \) and 0 elsewhere — a rectangle of height \( \dfrac{c}{b-a} \) and width \( b - a \).
(b) Determine \( c \). Total area = width × height:
\[ \text{Area} = (b-a) \cdot \frac{c}{b-a} = c \]Setting the total area to 1 gives \( c = 1 \). So the valid PDF is:
\[ f_X(x) = \begin{cases} \dfrac{1}{b-a}, & a \le x \le b \\ 0, & \text{otherwise} \end{cases} \](c) Verify by integration.
\[ \int_{-\infty}^{\infty} f_X(x)\,dx = \int_a^b \frac{1}{b-a}\,dx = \left[\frac{x}{b-a}\right]_a^b = \frac{b-a}{b-a} = 1 \](d) Probability on [4, 7] with \( a = 3, b = 8 \). The height is \( \dfrac{1}{5} \):
\[ P(4 \le X \le 7) = \int_4^7 \frac{1}{5}\,dx = \left[\frac{x}{5}\right]_4^7 = \frac{7-4}{5} = \frac{3}{5} = 0.6 \]