Calculating Probability in a Uniform Distribution from -1 to 1
A random number generator outputs values uniformly between -1 and 1. In such a uniform distribution, the probability of selecting a number within a specific interval is directly proportional to the length of that interval.
The Problem:
We are asked to find the probability that a randomly generated number lies between 0.9 and 1.
Understanding Uniform Distribution:
A uniform distribution over an interval [a,b][a, b][a,b] means:
-
Every number between aaa and bbb has equal probability of being selected.
-
The total probability across the interval is 1.
-
The probability density is:
f(x)=1b−af(x) = \frac{1}{b – a}f(x)=b−a1
For the interval [−1,1][-1, 1][−1,1]:
-
a=−1a = -1a=−1, b=1b = 1b=1
-
Width of the interval = 1−(−1)=21 – (-1) = 21−(−1)=2
-
So, the probability density is:
f(x)=12f(x) = \frac{1}{2}f(x)=21
Calculating the Desired Probability:
We want the probability that the number lies between 0.9 and 1:
P(0.9≤x≤1)=(1−0.9)×12=0.1×12=0.05P(0.9 \leq x \leq 1) = (1 – 0.9) \times \frac{1}{2} = 0.1 \times \frac{1}{2} = 0.05P(0.9≤x≤1)=(1−0.9)×21=0.1×21=0.05
✅ Correct Answer:
(2) 0.05