The expected value E ( X ) E(X) E ( X ) tells you the long-run average of a random variable, but not how much the results vary. Two games can both have an expected payout of $2, one paying exactly $2 every time and the other paying $0 or $20. The variance and standard deviation measure that spread. You’ll also see how they change when every value is scaled or shifted, for example when a prize is doubled or an entry fee is subtracted.
For a discrete random variable X X X with mean μ = E ( X ) \mu = E(X) μ = E ( X ) , the variance is the expected squared distance from the mean:
Var ( X ) = E ( ( X − μ ) 2 ) = ∑ ( x − μ ) 2 P ( X = x ) \text{Var}(X) = E\big((X - \mu)^2\big) = \sum (x - \mu)^2 \, P(X = x) Var ( X ) = E ( ( X − μ ) 2 ) = ∑ ( x − μ ) 2 P ( X = x )
The standard deviation is its square root, σ = Var ( X ) \sigma = \sqrt{\text{Var}(X)} σ = Var ( X ) . It’s in the same units as X X X , which makes it easier to interpret.
Expanding the square gives a formula that’s usually quicker:
Var ( X ) = E ( X 2 ) − [ E ( X ) ] 2 where E ( X 2 ) = ∑ x 2 P ( X = x ) \text{Var}(X) = E(X^2) - [E(X)]^2 \qquad \text{where} \qquad E(X^2) = \sum x^2 \, P(X = x) Var ( X ) = E ( X 2 ) − [ E ( X ) ] 2 where E ( X 2 ) = ∑ x 2 P ( X = x )
In words: “the mean of the squares minus the square of the mean.” To use it, add two rows to the probability table, x P ( X = x ) xP(X = x) x P ( X = x ) and x 2 P ( X = x ) x^2P(X = x) x 2 P ( X = x ) , and add each row.
Since a variance can’t be negative, E ( X 2 ) E(X^2) E ( X 2 ) is always at least [ E ( X ) ] 2 [E(X)]^2 [ E ( X ) ] 2 . If you get a negative variance, you’ve made an error.
Put the values of x x x in one list and the probabilities in another, then run one-variable statistics with the probabilities as the frequency list. The mean x ˉ \bar{x} x ˉ is E ( X ) E(X) E ( X ) , and the population standard deviation σ x \sigma_x σ x is the standard deviation of X X X (don’t use s x s_x s x ). Square σ x \sigma_x σ x for the variance.
If every value of X X X is multiplied by a a a and then b b b is added, the new random variable is a X + b aX + b a X + b . Then
E ( a X + b ) = a E ( X ) + b Var ( a X + b ) = a 2 Var ( X ) E(aX + b) = aE(X) + b \qquad\qquad \text{Var}(aX + b) = a^2\,\text{Var}(X) E ( a X + b ) = a E ( X ) + b Var ( a X + b ) = a 2 Var ( X )
so the standard deviation of a X + b aX + b a X + b is ∣ a ∣ σ |a|\sigma ∣ a ∣ σ .
Why? Adding b b b slides every value along by the same amount: the centre moves, but the spread doesn’t change. Multiplying by a a a stretches every distance from the mean by a factor of ∣ a ∣ |a| ∣ a ∣ , so squared distances are multiplied by a 2 a^2 a 2 .
Change to X X X Effect on E E E Effect on Var Effect on SD add b b b add b b b none none multiply by a a a multiply by a a a multiply by a 2 a^2 a 2 multiply by ∣ a ∣ \lvert a \rvert ∣ a ∣
For any function g g g , E ( g ( X ) ) = ∑ g ( x ) P ( X = x ) E\big(g(X)\big) = \sum g(x)P(X = x) E ( g ( X ) ) = ∑ g ( x ) P ( X = x ) . That’s how E ( X 2 ) E(X^2) E ( X 2 ) is defined. Be careful: in general E ( X 2 ) ≠ [ E ( X ) ] 2 E(X^2) \ne [E(X)]^2 E ( X 2 ) = [ E ( X ) ] 2 , and their difference is exactly the variance.
Let X X X be the score on a fair six-sided die. Find E ( X ) E(X) E ( X ) , Var ( X ) \text{Var}(X) Var ( X ) and the standard deviation.
Solution. Each value has probability 1 6 \tfrac{1}{6} 6 1 .
E ( X ) = 1 + 2 + 3 + 4 + 5 + 6 6 = 21 6 = 3.5 E(X) = \frac{1 + 2 + 3 + 4 + 5 + 6}{6} = \frac{21}{6} = 3.5 E ( X ) = 6 1 + 2 + 3 + 4 + 5 + 6 = 6 21 = 3.5
E ( X 2 ) = 1 + 4 + 9 + 16 + 25 + 36 6 = 91 6 E(X^2) = \frac{1 + 4 + 9 + 16 + 25 + 36}{6} = \frac{91}{6} E ( X 2 ) = 6 1 + 4 + 9 + 16 + 25 + 36 = 6 91
Var ( X ) = 91 6 − 3.5 2 = 91 6 − 49 4 = 182 − 147 12 = 35 12 \text{Var}(X) = \frac{91}{6} - 3.5^2 = \frac{91}{6} - \frac{49}{4} = \frac{182 - 147}{12} = \frac{35}{12} Var ( X ) = 6 91 − 3. 5 2 = 6 91 − 4 49 = 12 182 − 147 = 12 35
The variance is 35 12 ≈ 2.92 \dfrac{35}{12} \approx 2.92 12 35 ≈ 2.92 and the standard deviation is 35 / 12 ≈ 1.71 \sqrt{35/12} \approx 1.71 35/12 ≈ 1.71 (3 s.f.).
The random variable X X X has this distribution, and E ( X ) = 1.7 E(X) = 1.7 E ( X ) = 1.7 .
x x x 0 0 0 1 1 1 2 2 2 3 3 3 P ( X = x ) P(X = x) P ( X = x ) 0.1 0.1 0.1 p p p q q q 0.2 0.2 0.2
Find p p p and q q q , then find Var ( X ) \text{Var}(X) Var ( X ) and the standard deviation of X X X .
Solution. The probabilities add to 1 1 1 : 0.1 + p + q + 0.2 = 1 0.1 + p + q + 0.2 = 1 0.1 + p + q + 0.2 = 1 , so p + q = 0.7 p + q = 0.7 p + q = 0.7 .
The mean is 1.7 1.7 1.7 : 0 ( 0.1 ) + 1 p + 2 q + 3 ( 0.2 ) = 1.7 0(0.1) + 1p + 2q + 3(0.2) = 1.7 0 ( 0.1 ) + 1 p + 2 q + 3 ( 0.2 ) = 1.7 , so p + 2 q = 1.1 p + 2q = 1.1 p + 2 q = 1.1 .
Subtracting the equations: q = 0.4 q = 0.4 q = 0.4 , and then p = 0.3 p = 0.3 p = 0.3 .
E ( X 2 ) = 0 2 ( 0.1 ) + 1 2 ( 0.3 ) + 2 2 ( 0.4 ) + 3 2 ( 0.2 ) = 0 + 0.3 + 1.6 + 1.8 = 3.7 E(X^2) = 0^2(0.1) + 1^2(0.3) + 2^2(0.4) + 3^2(0.2) = 0 + 0.3 + 1.6 + 1.8 = 3.7 E ( X 2 ) = 0 2 ( 0.1 ) + 1 2 ( 0.3 ) + 2 2 ( 0.4 ) + 3 2 ( 0.2 ) = 0 + 0.3 + 1.6 + 1.8 = 3.7
Var ( X ) = 3.7 − 1.7 2 = 3.7 − 2.89 = 0.81 \text{Var}(X) = 3.7 - 1.7^2 = 3.7 - 2.89 = 0.81 Var ( X ) = 3.7 − 1. 7 2 = 3.7 − 2.89 = 0.81
The standard deviation is 0.81 = 0.9 \sqrt{0.81} = 0.9 0.81 = 0.9 .
In a fairground game, X X X is the number of targets a player hits, with the distribution from Example 2. The player pays $8 to play and wins $5 per target. Let Y Y Y be the player’s profit in dollars.
(a) Write Y Y Y in terms of X X X .
(b) Find E ( Y ) E(Y) E ( Y ) and the standard deviation of Y Y Y .
(c) Is the game fair?
Solution.
(a) Y = 5 X − 8 Y = 5X - 8 Y = 5 X − 8 .
(b) Using E ( X ) = 1.7 E(X) = 1.7 E ( X ) = 1.7 and Var ( X ) = 0.81 \text{Var}(X) = 0.81 Var ( X ) = 0.81 :
E ( Y ) = 5 ( 1.7 ) − 8 = 0.5 Var ( Y ) = 5 2 ( 0.81 ) = 20.25 E(Y) = 5(1.7) - 8 = 0.5 \qquad \text{Var}(Y) = 5^2(0.81) = 20.25 E ( Y ) = 5 ( 1.7 ) − 8 = 0.5 Var ( Y ) = 5 2 ( 0.81 ) = 20.25
The standard deviation of Y Y Y is 20.25 = 4.5 \sqrt{20.25} = 4.5 20.25 = 4.5 . (Or directly: 5 × 0.9 = 4.5 5 \times 0.9 = 4.5 5 × 0.9 = 4.5 .)
The expected profit is 50 cents per game, with a standard deviation of $4.50.
(c) A game is fair when E ( Y ) = 0 E(Y) = 0 E ( Y ) = 0 . Here E ( Y ) = 0.5 > 0 E(Y) = 0.5 \gt 0 E ( Y ) = 0.5 > 0 , so the game is not fair: it favours the player.
The probability distribution of X X X is P ( X = x ) = k x P(X = x) = \dfrac{k}{x} P ( X = x ) = x k for x = 1 , 2 , 3 x = 1, 2, 3 x = 1 , 2 , 3 . Find the exact values of k k k , E ( X ) E(X) E ( X ) and Var ( X ) \text{Var}(X) Var ( X ) .
Solution. The probabilities add to 1 1 1 :
k ( 1 + 1 2 + 1 3 ) = 11 k 6 = 1 ⇒ k = 6 11 k\left(1 + \frac{1}{2} + \frac{1}{3}\right) = \frac{11k}{6} = 1 \quad\Rightarrow\quad k = \frac{6}{11} k ( 1 + 2 1 + 3 1 ) = 6 11 k = 1 ⇒ k = 11 6
Notice that x ⋅ k x = k x \cdot \dfrac{k}{x} = k x ⋅ x k = k , so each term of E ( X ) E(X) E ( X ) is just k k k :
E ( X ) = k + k + k = 3 k = 18 11 E(X) = k + k + k = 3k = \frac{18}{11} E ( X ) = k + k + k = 3 k = 11 18
E ( X 2 ) = ∑ x 2 ⋅ k x = k ( 1 + 2 + 3 ) = 6 k = 36 11 E(X^2) = \sum x^2 \cdot \frac{k}{x} = k(1 + 2 + 3) = 6k = \frac{36}{11} E ( X 2 ) = ∑ x 2 ⋅ x k = k ( 1 + 2 + 3 ) = 6 k = 11 36
Var ( X ) = 36 11 − ( 18 11 ) 2 = 396 121 − 324 121 = 72 121 \text{Var}(X) = \frac{36}{11} - \left(\frac{18}{11}\right)^2 = \frac{396}{121} - \frac{324}{121} = \frac{72}{121} Var ( X ) = 11 36 − ( 11 18 ) 2 = 121 396 − 121 324 = 121 72
(The standard deviation is 6 2 11 ≈ 0.771 \dfrac{6\sqrt{2}}{11} \approx 0.771 11 6 2 ≈ 0.771 .)
Squaring the mean instead of finding the mean of the squares. E ( X 2 ) E(X^2) E ( X 2 ) is ∑ x 2 P ( X = x ) \sum x^2P(X = x) ∑ x 2 P ( X = x ) , not [ E ( X ) ] 2 [E(X)]^2 [ E ( X ) ] 2 . In Example 2, E ( X 2 ) = 3.7 E(X^2) = 3.7 E ( X 2 ) = 3.7 but [ E ( X ) ] 2 = 2.89 [E(X)]^2 = 2.89 [ E ( X ) ] 2 = 2.89 .
Forgetting to subtract. E ( X 2 ) E(X^2) E ( X 2 ) on its own is not the variance. Finish with − [ E ( X ) ] 2 - [E(X)]^2 − [ E ( X ) ] 2 .
Writing Var(aX + b) = aVar(X) + b. Adding a constant doesn’t change the spread, and multiplying by a a a multiplies the variance by a 2 a^2 a 2 . For Y = 5 X − 8 Y = 5X - 8 Y = 5 X − 8 , Var ( Y ) = 25 Var ( X ) \text{Var}(Y) = 25\,\text{Var}(X) Var ( Y ) = 25 Var ( X ) , not 5 Var ( X ) − 8 5\,\text{Var}(X) - 8 5 Var ( X ) − 8 .
A negative variance or standard deviation. Var ( − 2 X ) = 4 Var ( X ) \text{Var}(-2X) = 4\,\text{Var}(X) Var ( − 2 X ) = 4 Var ( X ) , which is positive, and the standard deviation is 2 σ 2\sigma 2 σ , not − 2 σ -2\sigma − 2 σ . Square a a a for the variance; use ∣ a ∣ |a| ∣ a ∣ for the standard deviation.
Mixing up variance and standard deviation. Read which one the question asks for. If you’re given σ = 3 \sigma = 3 σ = 3 , then Var ( X ) = 9 \text{Var}(X) = 9 Var ( X ) = 9 .
Using the sample standard deviation on a GDC. For a probability distribution, use σ x \sigma_x σ x , not s x s_x s x .
1. (Warm-up) Find E ( X ) E(X) E ( X ) , Var ( X ) \text{Var}(X) Var ( X ) and the standard deviation of X X X .
x x x 1 1 1 2 2 2 3 3 3 P ( X = x ) P(X = x) P ( X = x ) 0.2 0.2 0.2 0.5 0.5 0.5 0.3 0.3 0.3
Solution E ( X ) = 0.2 + 1.0 + 0.9 = 2.1 E ( X 2 ) = 0.2 + 2.0 + 2.7 = 4.9 E(X) = 0.2 + 1.0 + 0.9 = 2.1 \qquad E(X^2) = 0.2 + 2.0 + 2.7 = 4.9 E ( X ) = 0.2 + 1.0 + 0.9 = 2.1 E ( X 2 ) = 0.2 + 2.0 + 2.7 = 4.9 Var ( X ) = 4.9 − 2.1 2 = 4.9 − 4.41 = 0.49 \text{Var}(X) = 4.9 - 2.1^2 = 4.9 - 4.41 = 0.49 Var ( X ) = 4.9 − 2. 1 2 = 4.9 − 4.41 = 0.49 The standard deviation is 0.49 = 0.7 \sqrt{0.49} = 0.7 0.49 = 0.7 .
2. (Warm-up) E ( X ) = 4 E(X) = 4 E ( X ) = 4 and Var ( X ) = 9 \text{Var}(X) = 9 Var ( X ) = 9 . Find:
(a) E ( 3 X − 2 ) E(3X - 2) E ( 3 X − 2 ) and Var ( 3 X − 2 ) \text{Var}(3X - 2) Var ( 3 X − 2 ) ;
(b) E ( 5 − X ) E(5 - X) E ( 5 − X ) and Var ( 5 − X ) \text{Var}(5 - X) Var ( 5 − X ) .
Solution (a) E ( 3 X − 2 ) = 3 ( 4 ) − 2 = 10 E(3X - 2) = 3(4) - 2 = 10 E ( 3 X − 2 ) = 3 ( 4 ) − 2 = 10 . Var ( 3 X − 2 ) = 3 2 ( 9 ) = 81 \text{Var}(3X - 2) = 3^2(9) = 81 Var ( 3 X − 2 ) = 3 2 ( 9 ) = 81 .
(b) 5 − X = − X + 5 5 - X = -X + 5 5 − X = − X + 5 , so a = − 1 a = -1 a = − 1 , b = 5 b = 5 b = 5 . E ( 5 − X ) = − 4 + 5 = 1 E(5 - X) = -4 + 5 = 1 E ( 5 − X ) = − 4 + 5 = 1 . Var ( 5 − X ) = ( − 1 ) 2 ( 9 ) = 9 \text{Var}(5 - X) = (-1)^2(9) = 9 Var ( 5 − X ) = ( − 1 ) 2 ( 9 ) = 9 .
3. (Core) P ( X = x ) = k ( x + 1 ) P(X = x) = k(x + 1) P ( X = x ) = k ( x + 1 ) for x = 0 , 1 , 2 , 3 x = 0, 1, 2, 3 x = 0 , 1 , 2 , 3 . Find k k k , E ( X ) E(X) E ( X ) and Var ( X ) \text{Var}(X) Var ( X ) .
Solution k ( 1 + 2 + 3 + 4 ) = 10 k = 1 k(1 + 2 + 3 + 4) = 10k = 1 k ( 1 + 2 + 3 + 4 ) = 10 k = 1 , so k = 0.1 k = 0.1 k = 0.1 . The probabilities are 0.1 , 0.2 , 0.3 , 0.4 0.1, 0.2, 0.3, 0.4 0.1 , 0.2 , 0.3 , 0.4 .
E ( X ) = 0 + 0.2 + 0.6 + 1.2 = 2 E ( X 2 ) = 0 + 0.2 + 1.2 + 3.6 = 5 E(X) = 0 + 0.2 + 0.6 + 1.2 = 2 \qquad E(X^2) = 0 + 0.2 + 1.2 + 3.6 = 5 E ( X ) = 0 + 0.2 + 0.6 + 1.2 = 2 E ( X 2 ) = 0 + 0.2 + 1.2 + 3.6 = 5 Var ( X ) = 5 − 2 2 = 1 \text{Var}(X) = 5 - 2^2 = 1 Var ( X ) = 5 − 2 2 = 1
4. (Core) A fair coin is tossed three times, and X X X is the number of heads. Write down the probability distribution of X X X , and find E ( X ) E(X) E ( X ) and Var ( X ) \text{Var}(X) Var ( X ) .
Solution
x x x 0 0 0 1 1 1 2 2 2 3 3 3 P ( X = x ) P(X = x) P ( X = x ) 1 8 \tfrac{1}{8} 8 1 3 8 \tfrac{3}{8} 8 3 3 8 \tfrac{3}{8} 8 3 1 8 \tfrac{1}{8} 8 1
E ( X ) = 0 + 3 + 6 + 3 8 = 12 8 = 1.5 E ( X 2 ) = 0 + 3 + 12 + 9 8 = 24 8 = 3 E(X) = \frac{0 + 3 + 6 + 3}{8} = \frac{12}{8} = 1.5 \qquad E(X^2) = \frac{0 + 3 + 12 + 9}{8} = \frac{24}{8} = 3 E ( X ) = 8 0 + 3 + 6 + 3 = 8 12 = 1.5 E ( X 2 ) = 8 0 + 3 + 12 + 9 = 8 24 = 3 Var ( X ) = 3 − 1.5 2 = 0.75 \text{Var}(X) = 3 - 1.5^2 = 0.75 Var ( X ) = 3 − 1. 5 2 = 0.75 Check: X ∼ B ( 3 , 0.5 ) X \sim B(3, 0.5) X ∼ B ( 3 , 0.5 ) , and the binomial formulas give n p = 1.5 np = 1.5 n p = 1.5 and n p ( 1 − p ) = 0.75 np(1 - p) = 0.75 n p ( 1 − p ) = 0.75 . ✓
5. (Core) A game costs $8 to play. You roll a fair die and win twice the score in dollars. Let W W W be your profit in dollars.
(a) Write W W W in terms of the score X X X , and find E ( W ) E(W) E ( W ) and the standard deviation of W W W .
(b) What should the game cost for it to be fair?
Solution (a) W = 2 X − 8 W = 2X - 8 W = 2 X − 8 . From Example 1, E ( X ) = 3.5 E(X) = 3.5 E ( X ) = 3.5 and Var ( X ) = 35 12 \text{Var}(X) = \dfrac{35}{12} Var ( X ) = 12 35 .
E ( W ) = 2 ( 3.5 ) − 8 = − 1 SD ( W ) = 2 35 12 = 3.42 (3 s.f.) E(W) = 2(3.5) - 8 = -1 \qquad \text{SD}(W) = 2\sqrt{\frac{35}{12}} = 3.42 \text{ (3 s.f.)} E ( W ) = 2 ( 3.5 ) − 8 = − 1 SD ( W ) = 2 12 35 = 3.42 (3 s.f.) On average you lose $1 per game.
(b) With a cost of c c c dollars, E ( 2 X − c ) = 7 − c E(2X - c) = 7 - c E ( 2 X − c ) = 7 − c . This is 0 0 0 when c = 7 c = 7 c = 7 , so the game is fair if it costs $7.
6. (Core) The random variable X X X has E ( X ) = 0.5 E(X) = 0.5 E ( X ) = 0.5 and this distribution.
x x x − 1 -1 − 1 0 0 0 2 2 2 5 5 5 P ( X = x ) P(X = x) P ( X = x ) 0.3 0.3 0.3 p p p q q q 0.1 0.1 0.1
Find p p p and q q q , and the standard deviation of X X X .
Solution Mean: − 0.3 + 0 + 2 q + 0.5 = 0.5 -0.3 + 0 + 2q + 0.5 = 0.5 − 0.3 + 0 + 2 q + 0.5 = 0.5 , so 2 q = 0.3 2q = 0.3 2 q = 0.3 and q = 0.15 q = 0.15 q = 0.15 . Total: 0.3 + p + 0.15 + 0.1 = 1 0.3 + p + 0.15 + 0.1 = 1 0.3 + p + 0.15 + 0.1 = 1 , so p = 0.45 p = 0.45 p = 0.45 .
E ( X 2 ) = 1 ( 0.3 ) + 0 + 4 ( 0.15 ) + 25 ( 0.1 ) = 0.3 + 0.6 + 2.5 = 3.4 E(X^2) = 1(0.3) + 0 + 4(0.15) + 25(0.1) = 0.3 + 0.6 + 2.5 = 3.4 E ( X 2 ) = 1 ( 0.3 ) + 0 + 4 ( 0.15 ) + 25 ( 0.1 ) = 0.3 + 0.6 + 2.5 = 3.4 Var ( X ) = 3.4 − 0.5 2 = 3.15 σ = 3.15 = 1.77 (3 s.f.) \text{Var}(X) = 3.4 - 0.5^2 = 3.15 \qquad \sigma = \sqrt{3.15} = 1.77 \text{ (3 s.f.)} Var ( X ) = 3.4 − 0. 5 2 = 3.15 σ = 3.15 = 1.77 (3 s.f.)
7. (Core) The daily maximum temperature C C C (∘ C ^\circ\text{C} ∘ C ) in a city in July has mean 22 22 22 and standard deviation 4 4 4 . The temperature in degrees Fahrenheit is F = 1.8 C + 32 F = 1.8C + 32 F = 1.8 C + 32 . Find the mean, standard deviation and variance of F F F .
Solution E ( F ) = 1.8 ( 22 ) + 32 = 71.6 SD ( F ) = 1.8 ( 4 ) = 7.2 Var ( F ) = 7.2 2 = 51.84 E(F) = 1.8(22) + 32 = 71.6 \qquad \text{SD}(F) = 1.8(4) = 7.2 \qquad \text{Var}(F) = 7.2^2 = 51.84 E ( F ) = 1.8 ( 22 ) + 32 = 71.6 SD ( F ) = 1.8 ( 4 ) = 7.2 Var ( F ) = 7. 2 2 = 51.84 (Adding 32 32 32 changes the mean but not the spread.)
8. (Challenge) E ( X ) = 2 E(X) = 2 E ( X ) = 2 and Var ( X ) = 3 \text{Var}(X) = 3 Var ( X ) = 3 .
(a) Find E ( X 2 ) E(X^2) E ( X 2 ) and E ( ( 2 X + 1 ) 2 ) E\big((2X + 1)^2\big) E ( ( 2 X + 1 ) 2 ) .
(b) Find constants a > 0 a \gt 0 a > 0 and b b b so that Y = a X + b Y = aX + b Y = a X + b has E ( Y ) = 0 E(Y) = 0 E ( Y ) = 0 and Var ( Y ) = 1 \text{Var}(Y) = 1 Var ( Y ) = 1 .
Solution (a) Var ( X ) = E ( X 2 ) − [ E ( X ) ] 2 \text{Var}(X) = E(X^2) - [E(X)]^2 Var ( X ) = E ( X 2 ) − [ E ( X ) ] 2 , so E ( X 2 ) = 3 + 4 = 7 E(X^2) = 3 + 4 = 7 E ( X 2 ) = 3 + 4 = 7 .
E ( ( 2 X + 1 ) 2 ) = E ( 4 X 2 + 4 X + 1 ) = 4 ( 7 ) + 4 ( 2 ) + 1 = 37 E\big((2X + 1)^2\big) = E(4X^2 + 4X + 1) = 4(7) + 4(2) + 1 = 37 E ( ( 2 X + 1 ) 2 ) = E ( 4 X 2 + 4 X + 1 ) = 4 ( 7 ) + 4 ( 2 ) + 1 = 37 (b) Var ( Y ) = a 2 ( 3 ) = 1 \text{Var}(Y) = a^2(3) = 1 Var ( Y ) = a 2 ( 3 ) = 1 , so a = 1 3 a = \dfrac{1}{\sqrt{3}} a = 3 1 (taking a > 0 a \gt 0 a > 0 ). E ( Y ) = 2 3 + b = 0 E(Y) = \dfrac{2}{\sqrt{3}} + b = 0 E ( Y ) = 3 2 + b = 0 , so b = − 2 3 b = -\dfrac{2}{\sqrt{3}} b = − 3 2 .
So Y = X − 2 3 Y = \dfrac{X - 2}{\sqrt{3}} Y = 3 X − 2 : subtract the mean and divide by the standard deviation. That’s standardizing, just like a z-score.
9. (Challenge) X X X takes only the values 0 0 0 and a a a , where a > 0 a \gt 0 a > 0 , with P ( X = a ) = p P(X = a) = p P ( X = a ) = p . Given that E ( X ) = 2 E(X) = 2 E ( X ) = 2 and Var ( X ) = 6 \text{Var}(X) = 6 Var ( X ) = 6 , find a a a and p p p .
Solution E ( X ) = a p = 2 E(X) = ap = 2 E ( X ) = a p = 2 and E ( X 2 ) = a 2 p E(X^2) = a^2p E ( X 2 ) = a 2 p , so
Var ( X ) = a 2 p − ( a p ) 2 = a 2 p ( 1 − p ) = 6 \text{Var}(X) = a^2p - (ap)^2 = a^2p(1 - p) = 6 Var ( X ) = a 2 p − ( a p ) 2 = a 2 p ( 1 − p ) = 6 Write a 2 p ( 1 − p ) = a ( a p ) ( 1 − p ) = 2 a ( 1 − p ) = 6 a^2p(1 - p) = a(ap)(1 - p) = 2a(1 - p) = 6 a 2 p ( 1 − p ) = a ( a p ) ( 1 − p ) = 2 a ( 1 − p ) = 6 , so a ( 1 − p ) = 3 a(1 - p) = 3 a ( 1 − p ) = 3 , which means a − a p = 3 a - ap = 3 a − a p = 3 . Since a p = 2 ap = 2 a p = 2 , a = 5 a = 5 a = 5 , and then p = 2 5 = 0.4 p = \dfrac{2}{5} = 0.4 p = 5 2 = 0.4 .
Check: E ( X ) = 5 ( 0.4 ) = 2 E(X) = 5(0.4) = 2 E ( X ) = 5 ( 0.4 ) = 2 and Var ( X ) = 25 ( 0.4 ) ( 0.6 ) = 6 \text{Var}(X) = 25(0.4)(0.6) = 6 Var ( X ) = 25 ( 0.4 ) ( 0.6 ) = 6 . ✓