Welcome to the Uniform Distribution!
Hello future Further Mathematician! The chapter on the Uniform Distribution is your first deep dive into continuous random variables within the FS1 statistics module. Don't worry, it's one of the friendliest distributions out there!
We call it "uniform" because it's completely fair—every value within a specific range has the exact same probability density. Understanding this concept is crucial, not just for passing the exam, but also as a foundation for understanding more complex distributions like the Normal or Exponential distributions later on.
Ready to master the formulas, understand the conditions, and tackle the derivations? Let's go!
Key Takeaway from the Introduction
The Uniform Distribution models a situation where all outcomes within a defined interval are equally likely.
1. Understanding Continuous Uniform Distribution (FS1.2: Conditions for application)
The Uniform Distribution is also often called the Rectangular Distribution because of the shape its probability graph takes.
What are the conditions for using it?
A random variable \(X\) follows a Uniform Distribution over a specific interval, say from \(a\) to \(b\), if:
- \(X\) is a continuous random variable. This means \(X\) can take any value within the range (e.g., time, distance, temperature), not just discrete integers.
- The probability density is constant for all values \(x\) within the range \(a \le x \le b\).
- The probability density is zero outside this range.
Notation: We write \(X \sim U(a, b)\), where \(a\) and \(b\) are the minimum and maximum possible values, respectively, and \(a < b\).
Analogy: The Bus Arrival Time
Imagine a bus arrives at a stop randomly between 8:00 AM (\(a=0\)) and 8:10 AM (\(b=10\)). If the time it arrives is truly random and not influenced by traffic or a schedule, then the time of arrival (in minutes past 8:00 AM) is uniformly distributed, \(X \sim U(0, 10)\). Whether you arrive at 8:01:05 or 8:07:32, the density of that specific time is the same.
In the real world, "truly uniform" distributions are rare, but they are often used to model random errors, rounding discrepancies, or processes where there is no physical reason for one outcome to be preferred over another (like the random generation of numbers in a computer).
Key Takeaway from Section 1
A variable \(X\) is uniformly distributed if its density is flat (constant) between two limits, \(a\) and \(b\).
2. The Probability Density Function (PDF)
For any continuous distribution, the total area under its curve (or graph) must always equal 1 (representing 100% probability).
Since the Uniform Distribution creates a rectangle when graphed, the area calculation is simple:
$$\text{Area} = \text{Height} \times \text{Width}$$
We know Area must equal 1. The width of the rectangle is the length of the interval, which is \((b - a)\).
$$\text{Height} \times (b - a) = 1$$
Therefore, the height (which is the probability density function, \(f(x)\)) must be:
$$f(x) = \frac{1}{b-a}$$
The Formula for the PDF
The full definition of the Probability Density Function (PDF) for \(X \sim U(a, b)\) is:
$$f(x) = \begin{cases} \frac{1}{b-a} & \text{for } a \le x \le b \\ 0 & \text{otherwise} \end{cases}$$
Memory Aid: Think of a cake! If you cut a cake of length \((b-a)\) so that the total area (volume) is 1, the height of the slice must be the reciprocal of the length: \(1/(b-a)\).
Key Takeaway from Section 2
The PDF, \(f(x)\), is simply the height of the probability rectangle, equal to \(1\) divided by the length of the interval \((b-a)\).
3. Calculating Probabilities (FS1.2: Calculation of probabilities)
To find the probability that \(X\) falls within a sub-interval \([c, d]\), where \(a \le c \le d \le b\), we just find the area of the rectangle defined by that sub-interval.
$$P(c \le X \le d) = \text{Area of sub-rectangle}$$
$$\text{Area} = \text{Height} \times \text{Width of sub-interval}$$
$$P(c \le X \le d) = f(x) \times (d - c)$$
Substituting the PDF formula:
$$P(c \le X \le d) = \left(\frac{1}{b-a}\right) \times (d-c) = \frac{d-c}{b-a}$$
A Note on Continuous Variables
Don't worry about whether the inequalities are strict (\(<\)) or non-strict (\(\le\)). Because \(X\) is continuous, the probability of any single exact value is zero.
$$P(X=c) = 0$$
Therefore:
$$P(c < X < d) = P(c \le X < d) = P(c \le X \le d)$$
Step-by-Step Example
A machine generates a random number \(X\) between 2 and 8. Find the probability that the number is between 3 and 5. (\(X \sim U(2, 8)\). So \(a=2\), \(b=8\)).
- Find the interval length: \(b - a = 8 - 2 = 6\).
- Find the PDF (Height): \(f(x) = 1/6\).
- Find the width of the required sub-interval: \(d - c = 5 - 3 = 2\).
- Calculate the probability (Area):
$$P(3 < X < 5) = \text{Height} \times \text{Width} = \frac{1}{6} \times 2 = \frac{2}{6} = \frac{1}{3}$$
Common Mistake to Avoid!
Students sometimes confuse the discrete and continuous uniform distributions. In the Continuous uniform distribution, you do not sum probabilities; you calculate area. Always use the formula derived from geometry (Area = width * height).
Key Takeaway from Section 3
Probability is found by calculating the fraction of the total interval length that the required sub-interval covers: \(\frac{\text{Length of desired interval}}{\text{Total interval length}}\).
4. Mean and Variance (FS1.2: Mean and variance - Knowledge and derivations expected)
For the Uniform Distribution, the formulas for the mean and variance are included in your formulae booklet, but the syllabus explicitly states that derivations will be expected. This means you must know how to use integration to prove these results.
Remember, for any continuous distribution:
- Mean \(E(X) = \mu = \int_{-\infty}^{\infty} x f(x) dx\)
- Variance \(Var(X) = \sigma^2 = E(X^2) - [E(X)]^2\)
Since \(f(x) = \frac{1}{b-a}\) only exists between \(a\) and \(b\), our integration limits simplify.
4.1 The Mean \(E(X)\)
Intuitively, since the distribution is perfectly symmetrical, the mean must be the midpoint of the interval \([a, b]\).
Required Result: $$\mu = E(X) = \frac{a+b}{2}$$
The Derivation (Proof):
$$E(X) = \int_a^b x f(x) dx = \int_a^b x \left(\frac{1}{b-a}\right) dx$$
Since \(\frac{1}{b-a}\) is a constant, we can pull it out:
$$E(X) = \frac{1}{b-a} \int_a^b x dx$$
Integrate \(x\):
$$E(X) = \frac{1}{b-a} \left[ \frac{x^2}{2} \right]_a^b$$
Substitute the limits:
$$E(X) = \frac{1}{b-a} \left( \frac{b^2}{2} - \frac{a^2}{2} \right)$$
Factor out \(\frac{1}{2}\):
$$E(X) = \frac{1}{2(b-a)} (b^2 - a^2)$$
Use the difference of squares identity: \(b^2 - a^2 = (b-a)(b+a)\):
$$E(X) = \frac{1}{2(b-a)} (b-a)(b+a)$$
Cancel the \((b-a)\) terms:
$$E(X) = \frac{a+b}{2}$$
That’s the first derivation done! Well done!
4.2 The Variance \(Var(X)\)
To find the variance, we first need to calculate \(E(X^2)\).
$$E(X^2) = \int_a^b x^2 f(x) dx = \int_a^b x^2 \left(\frac{1}{b-a}\right) dx$$
$$E(X^2) = \frac{1}{b-a} \int_a^b x^2 dx$$
Integrate \(x^2\):
$$E(X^2) = \frac{1}{b-a} \left[ \frac{x^3}{3} \right]_a^b$$
Substitute the limits:
$$E(X^2) = \frac{1}{b-a} \left( \frac{b^3}{3} - \frac{a^3}{3} \right) = \frac{1}{3(b-a)} (b^3 - a^3)$$
Now we use the difference of cubes identity: \(b^3 - a^3 = (b-a)(a^2 + ab + b^2)\):
$$E(X^2) = \frac{1}{3(b-a)} (b-a)(a^2 + ab + b^2)$$
Cancel the \((b-a)\) terms:
$$E(X^2) = \frac{a^2 + ab + b^2}{3}$$
Now apply the variance formula: \(Var(X) = E(X^2) - [E(X)]^2\):
$$Var(X) = \frac{a^2 + ab + b^2}{3} - \left(\frac{a+b}{2}\right)^2$$
Square the mean term:
$$Var(X) = \frac{a^2 + ab + b^2}{3} - \frac{a^2 + 2ab + b^2}{4}$$
Find a common denominator (12):
$$Var(X) = \frac{4(a^2 + ab + b^2) - 3(a^2 + 2ab + b^2)}{12}$$
Expand the brackets:
$$Var(X) = \frac{(4a^2 + 4ab + 4b^2) - (3a^2 + 6ab + 3b^2)}{12}$$
Combine like terms:
$$Var(X) = \frac{(4a^2 - 3a^2) + (4ab - 6ab) + (4b^2 - 3b^2)}{12}$$
$$Var(X) = \frac{a^2 - 2ab + b^2}{12}$$
Recognise the numerator as a perfect square: \(a^2 - 2ab + b^2 = (b-a)^2\):
Required Result: $$Var(X) = \frac{(b-a)^2}{12}$$
The algebra for the variance derivation is a bit heavy, but focus on the key steps: finding \(E(X^2)\), using the difference of cubes identity, and then using the variance formula with a common denominator. Practice this derivation until it's second nature!
Quick Review: Uniform Distribution Formulas
PDF: \(f(x) = \frac{1}{b-a}\)
Mean (\(\mu\)): \(E(X) = \frac{a+b}{2}\)
Variance (\(\sigma^2\)): \(Var(X) = \frac{(b-a)^2}{12}\)
Standard Deviation (\(\sigma\)): \(\sigma = \sqrt{\frac{(b-a)^2}{12}} = \frac{b-a}{\sqrt{12}}\)
5. Working with Standard Deviation and Applications
Once you have the mean and variance, calculating the Standard Deviation (SD) is straightforward: it is just the square root of the variance.
Example Application
A machine is programmed to cut metal rods to a length \(L\) (in cm). Due to slight inaccuracies, the actual length \(X\) is uniformly distributed between 19.8 cm and 20.2 cm. (\(X \sim U(19.8, 20.2)\)).
- Find the mean length of the rods.
- Find the variance and standard deviation of the length.
Using the mean formula: \(a=19.8\), \(b=20.2\).
$$E(X) = \frac{19.8 + 20.2}{2} = \frac{40}{2} = 20 \text{ cm}$$This makes perfect sense—the average is exactly the intended length.
First calculate \((b-a)\): \(20.2 - 19.8 = 0.4\)
Variance:
$$Var(X) = \frac{(b-a)^2}{12} = \frac{(0.4)^2}{12} = \frac{0.16}{12} = \frac{1}{75}$$Standard Deviation:
$$\sigma = \sqrt{\frac{1}{75}} \approx 0.115 \text{ cm (3 s.f.)}$$Prerequisite Check: Continuous vs. Discrete
If you're finding this topic challenging, briefly recall the fundamental difference between continuous and discrete random variables:
- Discrete (e.g., Binomial, Poisson): Uses summations (\(\sum\)), probability mass functions, and calculations of \(P(X=x)\).
- Continuous (e.g., Uniform): Uses integrals (\(\int\)) or geometry (area), probability density functions \(f(x)\), and \(P(X=x)=0\).
The Uniform Distribution is essentially the simplest application of continuous probability rules, making it a great place to solidify your understanding of integrating a PDF to find expectations!
You’ve covered all the core content for the Uniform Distribution now—from the basic constant PDF to the required integral derivations for the mean and variance. Keep practicing those derivations!