Resources For Teachers For Tutors For Students & Parents Pricing
Year 12 Maths - Specialist (Unit 3 & Unit 4) Statistical inference

Linear combinations of random variables

20 practice questions 0 video lessons Theory + worked examples

Master linear combinations of random variables in Year 12 VCE Specialist Mathematics. A linear combination such as \(aX+b\) or \(aX+bY\) is built from random variables and constants, with mean \(E(aX+bY)=aE(X)+bE(Y)\) and, for independent \(X,Y\), variance \(\mathrm{Var}(aX+bY)=a^2\mathrm{Var}(X)+b^2\mathrm{Var}(Y)\). It sits in the Data analysis, probability and statistics area of study of the VCE Mathematics Study Design (VCAA), within the Statistical inference topic of Unit 4.

You will learn to find the mean by linearity and the variance by squaring each coefficient — noting that variances add for a difference and that \(\mathrm{Var}(2X)=4\,\mathrm{Var}(X)\) differs from \(\mathrm{Var}(X_1+X_2)=2\,\mathrm{Var}(X)\) — and use that a combination of independent normals is again normal to find probabilities.

Create a free accountTrack your progress and save your work as you go.
Create free account

Theory

A linear combination of random variables is an expression such as \(aX+b\) or \(aX+bY\) built from random variables and constants. In Year 12 Specialist Mathematics you find its mean with \(E(aX+bY)=aE(X)+bE(Y)\) and its variance with \(\operatorname{Var}(aX+bY)=a^2\operatorname{Var}(X)+b^2\operatorname{Var}(Y)\) for independent \(X,Y\) — where the variances add for both a sum and a difference — and use that a combination of independent normals is itself normal.

A random variable \(X\) has a mean (expected value) \(E(X)=\mu\) and a variance \(\operatorname{Var}(X)=\sigma^2\); its standard deviation is \(\operatorname{SD}(X)=\sqrt{\operatorname{Var}(X)}\). A linear combination scales and shifts one or more random variables, e.g. \(aX+b\) or \(aX+bY\).

Transforming one variable. Multiplying by a constant \(a\) and adding a constant \(b\) gives \(E(aX+b)=aE(X)+b\). The variance ignores the shift and squares the scale: \(\operatorname{Var}(aX+b)=a^2\operatorname{Var}(X)\). So adding a constant slides the distribution but never changes its spread.

Combining independent variables. For independent \(X\) and \(Y\), expectation is linear: \(E(aX+bY)=aE(X)+bE(Y)\). Each coefficient is squared in the variance and the results are added: \(\operatorname{Var}(aX+bY)=a^2\operatorname{Var}(X)+b^2\operatorname{Var}(Y)\). Because \((-1)^2=1\), the variances add for a difference too: \(\operatorname{Var}(X-Y)=\operatorname{Var}(X)+\operatorname{Var}(Y)\).

The \(2X\) versus \(X_1+X_2\) distinction. Scaling and summing are not the same. \(\operatorname{Var}(2X)=2^2\operatorname{Var}(X)=4\operatorname{Var}(X)\), but for two independent copies \(\operatorname{Var}(X_1+X_2)=2\operatorname{Var}(X)\). Doubling by scaling spreads the distribution more than adding two independent copies.

iid sums and normality. For \(n\) independent, identically distributed variables each with mean \(\mu\) and variance \(\sigma^2\): \(E(X_1+\cdots+X_n)=n\mu\) and \(\operatorname{Var}(X_1+\cdots+X_n)=n\sigma^2\). If the variables are normal, any linear combination is also normal, so you can add means, add variances, then standardise to find probabilities.

Adding random variables shifts the centre and changes the spread Two normal curves on one axis. The left, taller and narrower curve is a single variable X with mean 50 and variance 16. The right, wider and lower curve is the sum T = X1 + X2 with mean 100 and variance 32. Adding the two variables has added the means (50 plus 50 equals 100) and added the variances (16 plus 16 equals 32), so the sum is centred further right and is more spread out. X ~ N(50, 16) T = X₁+X₂ ~ N(100, 32) 50 100
Adding shifts the centre and changes the spread: \(X\sim N(50,16)\) becomes \(T=X_1+X_2\sim N(100,32)\) — the means add \((50+50)\) and the variances add \((16+16)\).
2X versus the sum of two independent copies X1 + X2 Two normal curves share the same centre at 40. The wider, lower gold curve is 2X, whose variance is four times Var(X); the narrower, taller navy curve is X1 + X2, whose variance is only two times Var(X). Doubling by scaling spreads the distribution more than adding two independent copies, even though both have the same mean. mean 40 X₁+X₂: Var = 2Var(X) 2X: Var = 4Var(X)
Same centre, different spread. \(\operatorname{Var}(2X)=4\operatorname{Var}(X)\) (wider) while \(\operatorname{Var}(X_1+X_2)=2\operatorname{Var}(X)\) (narrower) — scaling spreads more than summing two independent copies.

Transforming one variable by a scale \(a\) and a shift \(b\) (the shift changes the mean but not the variance):

\[ E(aX+b)=aE(X)+b,\qquad \operatorname{Var}(aX+b)=a^2\operatorname{Var}(X) \]
E(aX+b)=aE(X)+b

For independent \(X\) and \(Y\), expectation is linear and the squared coefficients multiply the variances, which then add:

\[ E(aX+bY)=aE(X)+bE(Y) \]
\[ \operatorname{Var}(aX+bY)=a^2\operatorname{Var}(X)+b^2\operatorname{Var}(Y) \]
Var(aX+bY)=a2Var(X)+b2Var(Y)

Because \((-1)^2=1\), the variances add for a difference too, and for \(n\) independent identically distributed variables the sum has:

\[ \operatorname{Var}(X-Y)=\operatorname{Var}(X)+\operatorname{Var}(Y),\qquad E\Big(\textstyle\sum_{i=1}^n X_i\Big)=n\mu,\quad \operatorname{Var}\Big(\textstyle\sum_{i=1}^n X_i\Big)=n\sigma^2 \]
QuantityScale one variableSum of independent
Mean\(aE(X)+b\)\(E(X)+E(Y)\)
Variance\(a^2\operatorname{Var}(X)\)\(\operatorname{Var}(X)+\operatorname{Var}(Y)\)
Scaling is not summing. \(\operatorname{Var}(2X)=4\operatorname{Var}(X)\) but \(\operatorname{Var}(X_1+X_2)=2\operatorname{Var}(X)\). A linear combination of independent normal variables is again normal, so add means, add variances, then standardise with \(z=\dfrac{x-\mu}{\sigma}\).

How to work with a linear combination

  1. Read off each variable's mean and variance. Note whether a distribution is given as \(N(\mu,\sigma^2)\) (mean, variance) and confirm the variables are independent.
  2. Find the mean by linearity: \(E(aX+bY)=aE(X)+bE(Y)\) (and \(+b\) for any added constant).
  3. Find the variance by squaring the coefficients and adding: \(\operatorname{Var}(aX+bY)=a^2\operatorname{Var}(X)+b^2\operatorname{Var}(Y)\) — variances add for a difference as well; a constant term contributes nothing.
  4. Take the standard deviation as \(\sqrt{\operatorname{Var}}\) when needed, and keep \(\operatorname{Var}(2X)=4\operatorname{Var}(X)\) separate from \(\operatorname{Var}(X_1+X_2)=2\operatorname{Var}(X)\).
  5. For a probability with normals, the combination is normal: use its mean and variance, standardise \(z=\dfrac{x-\mu}{\sigma}\), and read the required area.
Example 1 — Mean and variance of a combination
Independent random variables \(X\) and \(Y\) have \(E(X)=10\), \(\operatorname{Var}(X)=4\), \(E(Y)=6\) and \(\operatorname{Var}(Y)=9\). Find \(E(X+Y)\), \(\operatorname{Var}(X+Y)\) and \(\operatorname{Var}(2X+Y)\).
Solution

Mean of the sum, \(E(X+Y)=E(X)+E(Y)\):

\(E(X+Y)\)\(=\)\(10+6\)
\(=\)\(16\)

Variance of the sum (independent, so variances add):

\(\operatorname{Var}(X+Y)\)\(=\)\(4+9\)
\(=\)\(13\)

Variance of \(2X+Y\) — square each coefficient:

\(\operatorname{Var}(2X+Y)\)\(=\)\(2^2\operatorname{Var}(X)+\operatorname{Var}(Y)\)
\(=\)\(4\times 4+9\)
\(=\)\(25\)

\(E(X+Y)=16\), \(\operatorname{Var}(X+Y)=13\) and \(\operatorname{Var}(2X+Y)=25\).

Example 2 — A general linear combination
Independent random variables \(X\) and \(Y\) have \(E(X)=4\), \(E(Y)=5\), \(\operatorname{Var}(X)=5\) and \(\operatorname{Var}(Y)=2\). Find \(E(2X+3Y)\) and \(\operatorname{Var}(2X-3Y)\).
Solution

Mean by linearity, \(E(2X+3Y)=2E(X)+3E(Y)\):

\(E(2X+3Y)\)\(=\)\(2\times 4+3\times 5\)
\(=\)\(8+15\)
\(=\)\(23\)

Variance — square each coefficient, then add (variances add for the difference):

\(\operatorname{Var}(2X-3Y)\)\(=\)\(2^2\operatorname{Var}(X)+(-3)^2\operatorname{Var}(Y)\)
\(=\)\(4\times 5+9\times 2\)
\(=\)\(20+18\)
\(=\)\(38\)

\(E(2X+3Y)=23\) and \(\operatorname{Var}(2X-3Y)=38\).

Example 3 — Probability for a sum of normals
Independent normal variables are \(X\sim N(100,\,25)\) and \(Y\sim N(80,\,144)\) (each stated as mean, variance). Find \(P(X+Y>193)\), to four decimal places.
Solution

A sum of independent normals is normal — add means and variances:

\(E(X+Y)\)\(=\)\(100+80=180\)
\(\operatorname{Var}(X+Y)\)\(=\)\(25+144=169\)
\(\operatorname{SD}(X+Y)\)\(=\)\(\sqrt{169}=13\)

Standardise and read the upper tail:

\(z\)\(=\)\(\dfrac{193-180}{13}=1\)
\(P(X+Y>193)\)\(=\)\(1-\Phi(1)\)
\(=\)\(0.1587\)

\(P(X+Y>193)=0.1587\).

Adding random variables shifts the centre and changes the spread Two normal curves on one axis. The left, taller and narrower curve is a single variable X with mean 50 and variance 16. The right, wider and lower curve is the sum T = X1 + X2 with mean 100 and variance 32. Adding the two variables has added the means (50 plus 50 equals 100) and added the variances (16 plus 16 equals 32), so the sum is centred further right and is more spread out. X ~ N(50, 16) T = X₁+X₂ ~ N(100, 32) 50 100
Example 4 — 2X versus X₁+X₂
A random variable \(X\) has mean \(15\) and variance \(16\). Let \(X_1\), \(X_2\) be two independent copies of \(X\). Find \(\operatorname{Var}(2X)\) and \(\operatorname{Var}(X_1+X_2)\), and say why they differ.
Solution

Scaling squares the coefficient:

\(\operatorname{Var}(2X)\)\(=\)\(2^2\operatorname{Var}(X)\)
\(=\)\(4\times 16\)
\(=\)\(64\)

Summing two independent copies only doubles the variance:

\(\operatorname{Var}(X_1+X_2)\)\(=\)\(16+16\)
\(=\)\(32\)

Why they differ: scaling by \(2\) multiplies the variance by \(2^2=4\), while adding two independent copies adds two equal variances, doubling it. So \(2X\) is the more variable.

\(\operatorname{Var}(2X)=64\) but \(\operatorname{Var}(X_1+X_2)=32\).

2X versus the sum of two independent copies X1 + X2 Two normal curves share the same centre at 40. The wider, lower gold curve is 2X, whose variance is four times Var(X); the narrower, taller navy curve is X1 + X2, whose variance is only two times Var(X). Doubling by scaling spreads the distribution more than adding two independent copies, even though both have the same mean. mean 40 X₁+X₂: Var = 2Var(X) 2X: Var = 4Var(X)

Common pitfalls

Forgetting to square the coefficient in the variance. \(\operatorname{Var}(aX)=a^2\operatorname{Var}(X)\), not \(a\operatorname{Var}(X)\). For \(2X\) the variance is \(4\operatorname{Var}(X)\), not \(2\operatorname{Var}(X)\).
Subtracting variances for a difference. For independent variables the variances add for a difference: \(\operatorname{Var}(X-Y)=\operatorname{Var}(X)+\operatorname{Var}(Y)\). They never subtract.
Confusing \(2X\) with \(X_1+X_2\). \(\operatorname{Var}(2X)=4\operatorname{Var}(X)\) but \(\operatorname{Var}(X_1+X_2)=2\operatorname{Var}(X)\). Scaling one variable is not the same as adding two independent copies.
Adding standard deviations. Standard deviations do not add; add the variances first, then take the square root. \(\operatorname{SD}(X_1+X_2)=\sqrt{\operatorname{Var}(X)+\operatorname{Var}(Y)}\).
Reading \(N(\mu,\sigma^2)\) as \(N(\mu,\sigma)\). The second entry is the variance. In \(N(100,25)\) the standard deviation is \(\sqrt{25}=5\), not \(25\).

Frequently asked questions

What is a linear combination of random variables?

It is an expression such as \(aX+b\) or \(aX+bY\) built from random variables and constants. You find its mean with \(E(aX+bY)=aE(X)+bE(Y)\) and, for independent variables, its variance with \(\operatorname{Var}(aX+bY)=a^2\operatorname{Var}(X)+b^2\operatorname{Var}(Y)\).

How do the mean and variance change under aX+b?

The mean transforms fully, \(E(aX+b)=aE(X)+b\), but the variance ignores the shift and squares the scale: \(\operatorname{Var}(aX+b)=a^2\operatorname{Var}(X)\). Adding a constant slides the distribution without changing its spread.

Do variances add or subtract for X - Y?

For independent variables the variances add: \(\operatorname{Var}(X-Y)=\operatorname{Var}(X)+\operatorname{Var}(Y)\), because the coefficient \(-1\) is squared. Variances never subtract.

Why is Var(2X) not the same as Var(X1+X2)?

Scaling squares the coefficient, so \(\operatorname{Var}(2X)=2^2\operatorname{Var}(X)=4\operatorname{Var}(X)\). Adding two independent copies only adds two equal variances, so \(\operatorname{Var}(X_1+X_2)=2\operatorname{Var}(X)\). Scaling spreads a distribution more than summing.

What are the mean and variance of a sum of n iid variables?

If \(X_1,\dots,X_n\) are independent and identically distributed with mean \(\mu\) and variance \(\sigma^2\), then \(E(X_1+\cdots+X_n)=n\mu\) and \(\operatorname{Var}(X_1+\cdots+X_n)=n\sigma^2\).

How do I find a probability for a combination of normals?

A linear combination of independent normal variables is normal. Add the means and add the variances to get the new \(N(\mu,\sigma^2)\), then standardise with \(z=\dfrac{x-\mu}{\sigma}\) and read the required area.