Skip to the content

Topics Covered

Expectation Moments via E Covariance Uncorrelated vs Independent Addition Theorem Multiplication Theorem Properties of E, Var, Cov Chebyshev's Inequality β₂ ≥ β₁ + 1 Cauchy-Schwarz Inequality
On this page
  1. 1. Mathematical Expectation
  2. 2. Moments via Expectation
  3. 3. Covariance via Expectation
  4. 4. Addition Theorem of Expectation
  5. 5. Multiplication Theorem of Expectation
  6. 6. Properties
  7. 7. Chebyshev's Inequality
  8. 8. Cauchy–Schwarz Inequality
  9. Worked Problems on Mathematical Expectation
  10. Key Take-aways from Unit 4

1. Mathematical Expectation

DEFINITION

The mathematical expectation (or expected value, mean) of a random variable \(X\) is the long-run average value of \(X\) over many repetitions of the experiment.

FORMULA \[ E(X) \;=\; \begin{cases} \displaystyle \sum_x x\, p(x), & \text{discrete}\\[6pt] \displaystyle \int_{-\infty}^{\infty} x\, f(x)\,dx, & \text{continuous} \end{cases} \]

Provided the sum / integral converges absolutely.

Expectation of a Function

\[ E[g(X)] \;=\; \begin{cases} \displaystyle \sum_x g(x)\, p(x), & \text{discrete}\\[6pt] \displaystyle \int_{-\infty}^{\infty} g(x)\, f(x)\,dx, & \text{continuous} \end{cases} \]
EXAMPLE 1 (Discrete)

\(X\) has PMF \(p(0)=0.2,\; p(1)=0.5,\; p(2)=0.3\).
\(E(X) = 0(0.2) + 1(0.5) + 2(0.3) = 1.1\).
\(E(X^2) = 0 + 1(0.5) + 4(0.3) = 1.7\).

EXAMPLE 2 (Continuous)

For \(f(x) = 2x,\; 0 \le x \le 1\):
\(E(X) = \int_0^1 x \cdot 2x \,dx = 2/3\).
\(E(X^2) = \int_0^1 x^2 \cdot 2x\,dx = 1/2\).
Variance = \(1/2 - (2/3)^2 = 1/2 - 4/9 = 1/18\).

Conditional Expectation and Conditional Variance

The conditional expectation of \(Y\) given \(X = x\) is the mean of the conditional distribution:

\[ E(Y \mid X = x) = \sum_y y\,P(Y = y \mid X = x) \quad\text{or}\quad \int y\, f_{Y\mid X}(y\mid x)\,dy. \]

Regarded as a function of the random variable \(X\), \(E(Y\mid X)\) is itself a random variable. Two fundamental identities follow:

\[ \textbf{Tower / total-expectation: } \; E(Y) = E\big[E(Y \mid X)\big]; \] \[ \textbf{Variance decomposition: } \; \text{Var}(Y) = E\big[\text{Var}(Y\mid X)\big] + \text{Var}\big[E(Y\mid X)\big]. \]

The second (the "law of total variance") splits total variability into the average within-group variance plus the variance of the group means — the same idea that underlies ANOVA.

EXAMPLE

Joint pmf of \((X,Y)\): \(P(0,0)=0.10\), \(P(0,1)=0.20\), \(P(0,2)=0.10\), \(P(1,0)=0.20\), \(P(1,1)=0.30\), \(P(1,2)=0.10\). Then \(P(X=0)=0.4,\ P(X=1)=0.6\), and

\(E(Y\mid X=0) = (0\cdot0.10 + 1\cdot0.20 + 2\cdot0.10)/0.4 = 1.0\); \(E(Y\mid X=1) = (0\cdot0.20 + 1\cdot0.30 + 2\cdot0.10)/0.6 = 0.833\).

Check the tower property: \(E[E(Y\mid X)] = 0.4(1.0) + 0.6(0.833) = 0.90 = E(Y)\). ✓

When the Expectation Exists

ABSOLUTE CONVERGENCE

The sum \(\sum x\,p(x)\) or the integral \(\int x f(x)\,dx\) defines \(E(X)\) only when it converges absolutely, that is, when

\[ \sum_x |x|\,p(x) < \infty \qquad\text{or}\qquad \int_{-\infty}^{\infty} |x|\,f(x)\,dx < \infty . \]

The reason is that an expectation must not depend on the order in which the values are listed. A series that converges but not absolutely can be rearranged to give any total at all (Riemann's rearrangement theorem), so it cannot define a mean.

An example with no mean. \(f(x) = 1/x^2\) for \(x \ge 1\) is a density, since \(\int_1^\infty x^{-2}\,dx = \big[-x^{-1}\big]_1^\infty = 1\). But

\[ \int_1^\infty x \cdot \frac{1}{x^2}\,dx = \int_1^\infty \frac{dx}{x} = \big[\ln x\big]_1^\infty = \infty , \]

so \(E(X)\) does not exist. A distribution can be perfectly proper and still have no mean.

THE STATISTICAL AVERAGES ARE ALL EXPECTATIONS

Choosing \(g\) in \(E[g(X)]\) gives every average used in this course:

The expectation of a constant. If \(X = C\) with probability 1, then \(E(C) = C \cdot 1 = C\); in the continuous form, \(E(C) = \int C f(x)\,dx = C\int f(x)\,dx = C\).

2. Moments via Expectation

RAW MOMENT \[ \mu'_r \;=\; E(X^r) \]
CENTRAL MOMENT \[ \mu_r \;=\; E[(X - \mu)^r] \]

The variance, skewness and kurtosis are special moments:

Central Moments from Raw Moments

DERIVATION OF \(\mu_2 = \mu_2' - \mu_1'^{\,2}\)

Write \(\mu = \mu_1' = E(X)\). Expand the square, then use the linearity of expectation (\(\mu\) is a constant):

\[ \begin{aligned} \mu_2 = E(X - \mu)^2 &= E\big(X^2 - 2\mu X + \mu^2\big) \\ &= E(X^2) - 2\mu\,E(X) + \mu^2 \\ &= \mu_2' - 2\mu_1'\mu_1' + \mu_1'^{\,2} = \mu_2' - \mu_1'^{\,2} . \end{aligned} \]

The same steps with \((X - \mu)^3\) and \((X - \mu)^4\), expanded by the binomial theorem, give

\[ \mu_3 = \mu_3' - 3\mu_2'\mu_1' + 2\mu_1'^{\,3}, \] \[ \mu_4 = \mu_4' - 4\mu_3'\mu_1' + 6\mu_2'\mu_1'^{\,2} - 3\mu_1'^{\,4} . \]

For \(\mu_3\): \(E(X - \mu)^3 = \mu_3' - 3\mu\,\mu_2' + 3\mu^2\mu_1' - \mu^3\), and with \(\mu = \mu_1'\) the last two terms combine to \(3\mu_1'^{\,3} - \mu_1'^{\,3} = 2\mu_1'^{\,3}\). These formulae are used again in Unit 5, where the cumulants are expressed through the moments.

3. Covariance via Expectation

DEFINITION

The covariance of two random variables \(X\) and \(Y\) measures the joint variability:

\[ \text{Cov}(X,Y) \;=\; E[(X - E(X))(Y - E(Y))] \;=\; E(XY) - E(X) E(Y) \]

The correlation coefficient is the standardized covariance:

\[ \rho_{XY} \;=\; \dfrac{\text{Cov}(X,Y)}{\sigma_X\, \sigma_Y}, \qquad -1 \le \rho \le 1. \]
EXAMPLE 1

From Unit 3 Sec 2 Ex 1: \(E(X) = 0(0.4)+1(0.6)=0.6\); \(E(Y) = 1(0.3)+2(0.5)+3(0.2)=1.9\).

The three cells with \(X = 0\) contribute 0, so

\[ E(XY) = 1\cdot 1\cdot 0.20 + 1\cdot 2\cdot 0.30 + 1\cdot 3\cdot 0.10 = 0.20 + 0.60 + 0.30 = 1.10 . \]

Cov = \(1.10 - 0.6 \times 1.9 = 1.10 - 1.14 = -0.04\) (slight negative association).

EXAMPLE 2 (Independent ⇒ Cov = 0)

If \(X,Y\) independent, then \(E(XY) = E(X)E(Y)\), hence Cov\(=0\). The converse is not always true.

Uncorrelated Is Not the Same as Independent

THE SHORTCUT FORMULA, STEP BY STEP

Write \(\mu_X = E(X)\) and \(\mu_Y = E(Y)\), both constants. Multiply out and take expectations term by term:

\[ \begin{aligned} \operatorname{Cov}(X,Y) &= E\big[(X - \mu_X)(Y - \mu_Y)\big] \\ &= E\big(XY - \mu_Y X - \mu_X Y + \mu_X\mu_Y\big) \\ &= E(XY) - \mu_Y\mu_X - \mu_X\mu_Y + \mu_X\mu_Y = E(XY) - E(X)E(Y) . \end{aligned} \]
A COMMON MISTAKE — WHAT \(E(XY) = E(X)E(Y)\) MEANS

A common slip is to call \(X\) and \(Y\) independent when \(E(XY) = E(X)E(Y)\), i.e. \(\operatorname{Cov}(X,Y) = 0\). That condition defines uncorrelated variables, not independent ones. Independence means that the joint distribution factorises, \(P(X = x, Y = y) = P(X = x)\,P(Y = y)\) for every pair. Independence implies zero covariance (§5); the converse is false.

Counterexample. Let \(X\) take the values \(-1, 0, 1\) with probability \(\tfrac13\) each, and let \(Y = X^2\). Then

\[ E(X) = 0, \qquad E(Y) = \tfrac23, \qquad E(XY) = E(X^3) = \tfrac13(-1 + 0 + 1) = 0, \] \[ \operatorname{Cov}(X,Y) = 0 - 0 \cdot \tfrac23 = 0 . \]

Yet \(Y\) is a function of \(X\), as dependent as two variables can be: \(P(X = 0, Y = 0) = \tfrac13\), while \(P(X = 0)\,P(Y = 0) = \tfrac13 \cdot \tfrac13 = \tfrac19\). Covariance measures only linear association, and the relation here is a parabola.

4. Addition Theorem of Expectation

STATEMENT

For any random variables \(X\) and \(Y\) (independent or not),

\[ E(X + Y) \;=\; E(X) + E(Y) \]

More generally, for constants \(a_1, \ldots, a_n\) and r.v.s \(X_1, \ldots, X_n\):

\[ E(a_1 X_1 + a_2 X_2 + \cdots + a_n X_n) \;=\; a_1 E(X_1) + \cdots + a_n E(X_n) \]
PROOF (continuous case)

Let \((X,Y)\) have joint density \(f(x,y)\) with marginals \(f_X\) and \(f_Y\). By the expectation of a function of \((X,Y)\),

\[ \begin{aligned} E(X + Y) &= \int_{-\infty}^{\infty}\!\!\int_{-\infty}^{\infty} (x + y)\, f(x,y)\, dx\, dy \\ &= \iint x\, f(x,y)\, dx\, dy \;+\; \iint y\, f(x,y)\, dx\, dy \\ &= \int_{-\infty}^{\infty} x \Big[\int_{-\infty}^{\infty} f(x,y)\, dy\Big] dx \;+\; \int_{-\infty}^{\infty} y \Big[\int_{-\infty}^{\infty} f(x,y)\, dx\Big] dy \\ &= \int_{-\infty}^{\infty} x\, f_X(x)\, dx \;+\; \int_{-\infty}^{\infty} y\, f_Y(y)\, dy \;=\; E(X) + E(Y). \end{aligned} \]

No independence is assumed — linearity of expectation holds for any \(X, Y\). The discrete case is identical with sums replacing integrals.

EXAMPLE 1

\(X\) = score on first die, \(Y\) = score on second die. \(E(X) = E(Y) = 3.5\). So \(E(X+Y) = 7\).

EXAMPLE 2

\(X\) ~ Binomial(\(n,p\)) is the sum of \(n\) independent Bernoulli(\(p\)) trials. Each Bernoulli has mean \(p\); by linearity \(E(X) = np\).

The Addition Theorem for \(n\) Variables

PROOF BY INDUCTION

Claim: \(E(X_1 + X_2 + \cdots + X_n) = E(X_1) + E(X_2) + \cdots + E(X_n)\) for every \(n\).

  1. Base. For \(n = 2\) this is the theorem just proved.
  2. Step. Suppose it holds for \(r\) variables. Put \(S_r = X_1 + \cdots + X_r\), a single random variable. By the two-variable theorem and then the hypothesis, \[ E(S_r + X_{r+1}) = E(S_r) + E(X_{r+1}) = E(X_1) + \cdots + E(X_r) + E(X_{r+1}) . \]
  3. So it holds for \(r + 1\), and by induction for every \(n\).

Nothing about independence is used at any step.

5. Multiplication Theorem of Expectation

STATEMENT (for independent r.v.)

If \(X\) and \(Y\) are independent random variables, then

\[ E(XY) \;=\; E(X) \cdot E(Y). \]

For \(n\) mutually independent r.v.: \(E(X_1 X_2 \cdots X_n) = \prod E(X_i)\).

EXAMPLE 1

Toss two independent dice. \(E(XY) = E(X) E(Y) = 3.5 \times 3.5 = 12.25\).

EXAMPLE 2

If two independent stocks have expected returns 8 % and 10 %, the expected return of their product (rare in practice) factorizes: \(E(R_1 R_2) = 0.08 \times 0.10 = 0.008\).

Proof of the Multiplication Theorem

PROOF (continuous case)

Let \(f(x, y)\) be the joint p.d.f. of \(X\) and \(Y\), and \(f(x)\), \(f(y)\) their marginal p.d.f.s, so that

\[ E(X) = \int_{-\infty}^{\infty} x\,f(x)\,dx, \qquad E(Y) = \int_{-\infty}^{\infty} y\,f(y)\,dy . \]

Then

\[ \begin{aligned} E(XY) &= \int_{-\infty}^{\infty}\!\!\int_{-\infty}^{\infty} xy\,f(x, y)\,dx\,dy \\ &= \int_{-\infty}^{\infty}\!\!\int_{-\infty}^{\infty} xy\,f(x)\,f(y)\,dx\,dy \\ &\qquad [X, Y \text{ independent, so } f(x, y) = f(x)\,f(y)] \\ &= \left\{\int_{-\infty}^{\infty} x\,f(x)\,dx\right\}\left\{\int_{-\infty}^{\infty} y\,f(y)\,dy\right\} \\ &= E(X)\,E(Y) . \end{aligned} \]

Hence \(E(XY) = E(X)\,E(Y)\). The double integral splits into a product only because the joint density is a product. For discrete variables the same steps run with sums and \(P(X = x_i, Y = y_j) = P(X = x_i)\,P(Y = y_j)\).

GENERALISATION TO \(n\) INDEPENDENT VARIABLES

Statement. The expectation of the product of \(n\) independent random variables is the product of their expectations: \(E(X_1 X_2 \cdots X_n) = E(X_1)\,E(X_2) \cdots E(X_n)\), that is, \(E\!\left(\prod_{i=1}^{n} X_i\right) = \prod_{i=1}^{n} E(X_i)\).

Proof, by mathematical induction. For two independent random variables, \(E(X_1 X_2) = E(X_1)\,E(X_2)\) …(1). Suppose the theorem is true for \(n = r\): \(E\!\left(\prod_{i=1}^{r} X_i\right) = \prod_{i=1}^{r} E(X_i)\) …(2). For \(n = r + 1\),

\[ \begin{aligned} E\!\left(\prod_{i=1}^{r+1} X_i\right) &= E\!\left[\left(\prod_{i=1}^{r} X_i\right) X_{r+1}\right] = E\!\left(\prod_{i=1}^{r} X_i\right) E(X_{r+1}) && [\text{from (1)}] \\ &= \prod_{i=1}^{r} E(X_i)\cdot E(X_{r+1}) = \prod_{i=1}^{r+1} E(X_i) && [\text{from (2)}] . \end{aligned} \]

So the theorem is true for \(n = r + 1\), and by induction for all \(n\).

Step (1) is applied to the two variables \(\prod_{i=1}^{r} X_i\) and \(X_{r+1}\), so they must be independent; that is what mutual independence of \(X_1, \ldots, X_n\) guarantees. Pairwise independence is not enough.

Example. Let \(X\) and \(Y\) be independent, each \(\pm1\) with probability \(\tfrac12\), and \(Z = XY\). Each pair among \(X, Y, Z\) is independent (every pair of signs has probability \(\tfrac14\)), and \(E(X) = E(Y) = E(Z) = 0\). But

\[ E(XYZ) = E(X^2Y^2) = 1 \ne 0 = E(X)E(Y)E(Z) . \]

6. Properties

6.1 Properties of Expectation

  1. \(E(c) = c\) for any constant \(c\).
  2. \(E(cX) = c\, E(X)\).
  3. \(E(aX + b) = a\, E(X) + b\).
  4. \(E(X + Y) = E(X) + E(Y)\) (always; linearity).
  5. If \(X \ge 0\) then \(E(X) \ge 0\).
  6. If \(X \le Y\) then \(E(X) \le E(Y)\).
  7. \(|E(X)| \le E(|X|)\).

6.2 Properties of Variance

  1. \(\text{Var}(c) = 0\).
  2. \(\text{Var}(aX + b) = a^2\, \text{Var}(X)\).
  3. \(\text{Var}(X) = E(X^2) - [E(X)]^2 \ge 0\).
  4. \(\text{Var}(X \pm Y) = \text{Var}(X) + \text{Var}(Y) \pm 2\,\text{Cov}(X,Y)\).
  5. If \(X,Y\) independent: \(\text{Var}(X + Y) = \text{Var}(X) + \text{Var}(Y)\).

6.3 Properties of Covariance

  1. Cov\((X, X) = \text{Var}(X)\).
  2. Cov\((X, Y) = \) Cov\((Y, X)\) (symmetric).
  3. Cov\((aX + b,\; cY + d) = ac\,\)Cov\((X, Y)\).
  4. Cov\((X + Y, Z) = \) Cov\((X, Z) + \) Cov\((Y, Z)\) (bilinear).
  5. If \(X, Y\) independent ⇒ Cov\(=0\); converse not generally true.
EXAMPLE 1

If Var\((X) = 4\), Var\((Y)=9\), Cov\((X,Y) = 2\). Then Var\((X + Y) = 4 + 9 + 2(2) = 17\).

EXAMPLE 2

For \(Z = 3X - 2Y\) with the above: Var\((Z) = 9(4) + 4(9) - 2(3)(2)(2) = 36 + 36 - 24 = 48\).

Why the Properties Hold

PROPERTIES OF EXPECTATION

Let \(X\) be a continuous random variable with p.d.f. \(f(x)\) (for a discrete one, replace integrals by sums).

1. \(E(C) = C\). \(E(C) = \int_{-\infty}^{\infty} C\,f(x)\,dx = C\int_{-\infty}^{\infty} f(x)\,dx = C \cdot 1 = C\).

2. \(E(aX) = aE(X)\). \(E(aX) = \int_{-\infty}^{\infty} ax\,f(x)\,dx = a\int_{-\infty}^{\infty} x\,f(x)\,dx = a\,E(X)\).

3. \(E(aX + b) = aE(X) + b\).

\[ \begin{aligned} E(aX + b) &= \int_{-\infty}^{\infty} (ax + b)\,f(x)\,dx = a\int_{-\infty}^{\infty} x\,f(x)\,dx + b\int_{-\infty}^{\infty} f(x)\,dx \\ &= aE(X) + b \cdot 1 = aE(X) + b . \end{aligned} \]

4. \(E(aX + bY) = aE(X) + bE(Y)\). With \(f(x, y)\) the joint p.d.f. and \(f(x)\), \(f(y)\) the marginals,

\[ \begin{aligned} E(aX + bY) &= \int_{-\infty}^{\infty}\!\!\int_{-\infty}^{\infty} (ax + by)\,f(x, y)\,dx\,dy \\ &= \iint ax\,f(x, y)\,dx\,dy + \iint by\,f(x, y)\,dx\,dy \\ &= a\int_{-\infty}^{\infty} x\left\{\int_{-\infty}^{\infty} f(x, y)\,dy\right\}dx + b\int_{-\infty}^{\infty} y\left\{\int_{-\infty}^{\infty} f(x, y)\,dx\right\}dy \\ &= a\int_{-\infty}^{\infty} x\,f(x)\,dx + b\int_{-\infty}^{\infty} y\,f(y)\,dy = aE(X) + bE(Y) . \end{aligned} \]

5. For a function \(\psi(X)\) and a constant \(a\): (i) \(E[a\psi(X)] = aE[\psi(X)]\); (ii) \(E[\psi(X) + a] = E[\psi(X)] + a\).

\[ \text{(i)}\;\; E[a\psi(X)] = \int_{-\infty}^{\infty} a\,\psi(x)\,f(x)\,dx = a\int_{-\infty}^{\infty} \psi(x)\,f(x)\,dx = aE[\psi(X)] ; \] \[ \begin{aligned} \text{(ii)}\;\; E[\psi(X) + a] &= \int_{-\infty}^{\infty} [\psi(x) + a]\,f(x)\,dx = \int_{-\infty}^{\infty} \psi(x)\,f(x)\,dx + a\int_{-\infty}^{\infty} f(x)\,dx \\ &= E[\psi(X)] + a , \end{aligned} \]

since \(\int_{-\infty}^{\infty} f(x)\,dx = 1\).

6. If \(X \ge 0\), then \(E(X) \ge 0\). \(f(x) = 0\) for \(x < 0\), so

\[ E(X) = \int_{-\infty}^{\infty} x\,f(x)\,dx = \int_{0}^{\infty} x\,f(x)\,dx \ge 0 , \]

because \(x \ge 0\) on the range of integration and \(f(x) \ge 0\) always.

7. If \(X \le Y\), then \(E(X) \le E(Y)\). Since \(X \le Y\), \(X - Y \le 0\), that is, \(Y - X \ge 0\). Taking expectations (property 6 applied to \(Y - X\), then property 4),

\[ E(X - Y) \le 0 \;\Rightarrow\; E(X) - E(Y) \le 0 \;\Rightarrow\; E(X) \le E(Y) . \]

8. \(|E(X)| \le E|X|\). Since \(X \le |X|\), property 7 gives \(E(X) \le E|X|\) …(1). Also, since \(-X \le |X|\), \(E(-X) \le E|X|\), that is, \(-E(X) \le E|X|\) …(2). From (1) and (2), \(|E(X)| \le E|X|\).

PROPERTIES OF VARIANCE

1. \(\operatorname{Var}(C) = 0\) for a constant \(C\). \(\operatorname{Var}(C) = E[C - E(C)]^2 = E[C - C]^2 = 0\), since \(E(C) = C\).

2. \(\operatorname{Var}(aX) = a^2\operatorname{Var}(X)\).

\[ \begin{aligned} \operatorname{Var}(aX) &= E[aX - E(aX)]^2 = E[aX - aE(X)]^2 = E\{a[X - E(X)]\}^2 \\ &= a^2E[X - E(X)]^2 = a^2\operatorname{Var}(X) . \end{aligned} \]

3. \(\operatorname{Var}(aX + b) = a^2\operatorname{Var}(X)\).

\[ \begin{aligned} \operatorname{Var}(aX + b) &= E[aX + b - E(aX + b)]^2 = E[aX + b - aE(X) - b]^2 \\ &= E\{a[X - E(X)]\}^2 = a^2E[X - E(X)]^2 = a^2\operatorname{Var}(X) . \end{aligned} \]

4. \(\operatorname{Var}(aX + bY) = a^2\operatorname{Var}(X) + b^2\operatorname{Var}(Y) + 2ab\operatorname{Cov}(X, Y)\).

\[ \begin{aligned} \operatorname{Var}(aX + bY) &= E[aX + bY - E(aX + bY)]^2 = E[aX + bY - aE(X) - bE(Y)]^2 \\ &= E\{a[X - E(X)] + b[Y - E(Y)]\}^2 \\ &= a^2E[X - E(X)]^2 + b^2E[Y - E(Y)]^2 \\ &\quad + 2ab\,E\{[X - E(X)][Y - E(Y)]\} \\ &= a^2\operatorname{Var}(X) + b^2\operatorname{Var}(Y) + 2ab\operatorname{Cov}(X, Y) , \end{aligned} \]

where the third line squares the bracket, \((u + v)^2 = u^2 + v^2 + 2uv\), and takes the expectation of each term (property 4 of expectation).

5. \(\operatorname{Var}(aX - bY) = a^2\operatorname{Var}(X) + b^2\operatorname{Var}(Y) - 2ab\operatorname{Cov}(X, Y)\). The same steps with \(-b\) in place of \(b\): the deviation is \(a[X - E(X)] - b[Y - E(Y)]\), and squaring gives the cross term \(-2ab[X - E(X)][Y - E(Y)]\).

6. Variance is independent of change of origin but not of scale. Let \(U = (X - a)/h\), where \(a\) is the change of origin and \(h\) the change of scale; then \(X = a + hU\) and

\[ \begin{aligned} \operatorname{Var}(X) &= \operatorname{Var}(a + hU) = E[a + hU - E(a + hU)]^2 = E[a + hU - a - hE(U)]^2 \\ &= E\{h[U - E(U)]\}^2 = h^2E[U - E(U)]^2 = h^2\operatorname{Var}(U) . \end{aligned} \]

The origin \(a\) has dropped out, but the scale \(h\) has not.

PROPERTIES OF COVARIANCE

1. \(\operatorname{Cov}(aX, bY) = ab\operatorname{Cov}(X, Y)\).

\[ \begin{aligned} \operatorname{Cov}(aX, bY) &= E\{[aX - E(aX)][bY - E(bY)]\} = E\{[aX - aE(X)][bY - bE(Y)]\} \\ &= E\{a[X - E(X)]\,b[Y - E(Y)]\} = ab\,E\{[X - E(X)][Y - E(Y)]\} \\ &= ab\operatorname{Cov}(X, Y) . \end{aligned} \]

2. \(\operatorname{Cov}(X + a, Y + b) = \operatorname{Cov}(X, Y)\). Since \(E(a) = a\) and \(E(b) = b\),

\[ \begin{aligned} \operatorname{Cov}(X + a, Y + b) &= E\{[X + a - E(X + a)][Y + b - E(Y + b)]\} \\ &= E\{[X + a - E(X) - a][Y + b - E(Y) - b]\} \\ &= E\{[X - E(X)][Y - E(Y)]\} = \operatorname{Cov}(X, Y) . \end{aligned} \]

3. \(\operatorname{Cov}(aX + b, cY + d) = ac\operatorname{Cov}(X, Y)\).

\[ \begin{aligned} \operatorname{Cov}(aX + b, cY + d) &= E\{[aX + b - E(aX + b)][cY + d - E(cY + d)]\} \\ &= E\{[aX + b - aE(X) - b][cY + d - cE(Y) - d]\} \\ &= E\{a[X - E(X)]\,c[Y - E(Y)]\} \\ &= ac\,E\{[X - E(X)][Y - E(Y)]\} = ac\operatorname{Cov}(X, Y) . \end{aligned} \]

4. \(\operatorname{Cov}(aX + bY, cX + dY) = ac\operatorname{Var}(X) + bd\operatorname{Var}(Y) + (ad + bc)\operatorname{Cov}(X, Y)\).

\[ \begin{aligned} &\operatorname{Cov}(aX + bY, cX + dY) \\ &\quad = E\{[aX + bY - E(aX + bY)][cX + dY - E(cX + dY)]\} \\ &\quad = E\{(a[X - E(X)] + b[Y - E(Y)])(c[X - E(X)] + d[Y - E(Y)])\} \\ &\quad = ac\,E[X - E(X)]^2 + bc\,E\{[X - E(X)][Y - E(Y)]\} \\ &\qquad + ad\,E\{[X - E(X)][Y - E(Y)]\} + bd\,E[Y - E(Y)]^2 \\ &\quad = ac\operatorname{Var}(X) + bc\operatorname{Cov}(X, Y) + ad\operatorname{Cov}(X, Y) + bd\operatorname{Var}(Y) \\ &\quad = ac\operatorname{Var}(X) + bd\operatorname{Var}(Y) + (ad + bc)\operatorname{Cov}(X, Y) . \end{aligned} \]

With \(-b\) and \(-d\) in place of \(b\) and \(d\) this gives \(\operatorname{Cov}(aX - bY, cX - dY) = ac\operatorname{Var}(X) + bd\operatorname{Var}(Y) - (ad + bc)\operatorname{Cov}(X, Y)\).

5. Covariance is independent of change of origin but not of scale. Let \(U = (X - a)/h\) and \(V = (Y - b)/K\), where \(a, b\) are changes of origin and \(h, K\) changes of scale; then \(X = a + hU\), \(Y = b + KV\), and

\[ \begin{aligned} \operatorname{Cov}(X, Y) &= E\{[X - E(X)][Y - E(Y)]\} \\ &= E\{[a + hU - E(a + hU)][b + KV - E(b + KV)]\} \\ &= E\{[a + hU - a - hE(U)][b + KV - b - KE(V)]\} \\ &= E\{h[U - E(U)]\,K[V - E(V)]\} \\ &= hK\,E\{[U - E(U)][V - E(V)]\} = hK\operatorname{Cov}(U, V) . \end{aligned} \]

7. Chebyshev's Inequality

STATEMENT

If \(X\) is any r.v. with mean \(\mu\) and finite variance \(\sigma^2\), then for any \(k > 0\):

\[ P(|X - \mu| \ge k\sigma) \;\le\; \dfrac{1}{k^2} \]

Equivalently: \(P(|X - \mu| < k\sigma) \ge 1 - \dfrac{1}{k^2}\).

This is a distribution-free bound — it holds for any distribution with finite variance.

μ − kσμμ + kσ P(|X−μ| < kσ) ≥ 1 − 1/k² tails tails both tails combined ≤ 1/k² (e.g. k = 2 ⇒ ≤ 25 %, so centre ≥ 75 %)
Fig 4.1 — Chebyshev caps the probability in the two tails beyond \(k\) standard deviations at \(1/k^2\), whatever the shape of the distribution — so at least \(1 - 1/k^2\) of the mass must sit in the central band. The bound is loose (a normal curve keeps ~95 % within \(\pm 2\sigma\), not just 75 %) but it needs no distributional assumption.
EXAMPLE 1

For \(k = 2\): \(P(|X - \mu| \ge 2\sigma) \le 1/4\). At least 75 % of any distribution lies within 2 SDs of mean.

EXAMPLE 2

Let \(X\) have \(\mu = 50,\; \sigma = 4\). Find a lower bound for \(P(40 < X < 60)\).
\(|X - 50| < 10\) means \(k\sigma = 10 \Rightarrow k = 2.5\).
\(P(|X - 50| < 10) \ge 1 - 1/6.25 = 0.84\). At least 84 % of values lie in (40, 60).

Applications of Chebyshev

Markov's Inequality

For a non-negative random variable \(X\) with finite mean and any \(a > 0\),

\[ P(X \ge a) \le \dfrac{E(X)}{a}. \]

Markov's inequality is the one-sided ancestor of Chebyshev's inequality: applying it to \((X-\mu)^2\) with \(a = k^2\sigma^2\) immediately yields Chebyshev's \(P(|X-\mu|\ge k\sigma) \le 1/k^2\).

Proof of Chebyshev's Inequality

PROOF (continuous case)

Let \(X\) be a continuous random variable with p.d.f. \(f(x)\), mean \(\mu\) and variance \(\sigma^2\), and let \(K > 0\). (For a discrete random variable, change integration to summation.) By the definition of variance,

\[ \begin{aligned} \sigma^2 = E[X - \mu]^2 &= \int_{-\infty}^{\infty} (x - \mu)^2 f(x)\,dx \\ &= \int_{-\infty}^{\mu - K\sigma} (x - \mu)^2 f(x)\,dx + \int_{\mu - K\sigma}^{\mu + K\sigma} (x - \mu)^2 f(x)\,dx \\ &\quad + \int_{\mu + K\sigma}^{\infty} (x - \mu)^2 f(x)\,dx \\ &\ge \int_{-\infty}^{\mu - K\sigma} (x - \mu)^2 f(x)\,dx + \int_{\mu + K\sigma}^{\infty} (x - \mu)^2 f(x)\,dx , \end{aligned} \]

since the middle integral, \(\int_{\mu - K\sigma}^{\mu + K\sigma} (x - \mu)^2 f(x)\,dx\), is \(\ge 0\).

For the first integral, \(x \le \mu - K\sigma\), so \(x - \mu \le -K\sigma\), that is, \(-(x - \mu) \ge K\sigma\), and \((x - \mu)^2 \ge K^2\sigma^2\). For the second integral, \(x \ge \mu + K\sigma\), so \(x - \mu \ge K\sigma\) and \((x - \mu)^2 \ge K^2\sigma^2\). So in both integrals \((x - \mu)^2 \ge K^2\sigma^2\), and

\[ \begin{aligned} \sigma^2 &\ge \int_{-\infty}^{\mu - K\sigma} K^2\sigma^2 f(x)\,dx + \int_{\mu + K\sigma}^{\infty} K^2\sigma^2 f(x)\,dx \\ &= K^2\sigma^2\left\{\int_{-\infty}^{\mu - K\sigma} f(x)\,dx + \int_{\mu + K\sigma}^{\infty} f(x)\,dx\right\} \\ &= K^2\sigma^2\{P(X \le \mu - K\sigma) + P(X \ge \mu + K\sigma)\} \\ &= K^2\sigma^2\{P(X - \mu \le -K\sigma) + P(X - \mu \ge K\sigma)\} \\ &= K^2\sigma^2\,P[|X - \mu| \ge K\sigma] . \end{aligned} \]

Dividing by \(\sigma^2\), \(1 \ge K^2\,P[|X - \mu| \ge K\sigma]\), so

\[ P[|X - \mu| \ge K\sigma] \le \frac{1}{K^2} . \]

This can also be written \(P[|X - \mu| < K\sigma] \ge 1 - \dfrac{1}{K^2}\). \(\square\)

THE FORM USED IN PRACTICE

Putting \(c = k\sigma\),

\[ P\big(|X - \mu| \ge c\big) \le \frac{\sigma^2}{c^2}, \qquad P\big(|X - \mu| < c\big) \ge 1 - \frac{\sigma^2}{c^2} . \]

The bound tells us something only if \(\sigma^2/c^2 < 1\), that is \(c > \sigma\) (\(k > 1\)). For a band narrower than one standard deviation, any probability at all is possible in the tails, and the inequality is true but empty. Worked Problem 11 below meets exactly this case.

A Moment Inequality: \(\beta_2 \ge \beta_1 + 1\)

PROOF

To prove \(\beta_2 \ge \beta_1 + 1\), first prove \(\beta_2 \ge \beta_1 - (K^2 + 2K)\) for every constant \(K\). Take \(E(X) = 0\) without loss of generality (moments about the mean do not change with the origin); then \(\mu_r = E(X^r)\). Consider the real-valued function of \(t\)

\[ \begin{aligned} & Z(t) = E[X^2 + tX + K\mu_2]^2 \ge 0 \quad \text{for all } t \\ \Rightarrow\; & E[X^4 + t^2X^2 + K^2\mu_2^2 + 2tX^3 + 2K\mu_2X^2 + 2K\mu_2tX] \ge 0 \\ \Rightarrow\; & E(X^4) + t^2E(X^2) + K^2\mu_2^2 + 2tE(X^3) + 2K\mu_2E(X^2) + 2K\mu_2t\,E(X) \ge 0 \\ \Rightarrow\; & \mu_4 + t^2\mu_2 + K^2\mu_2^2 + 2t\mu_3 + 2K\mu_2^2 \ge 0 \qquad [E(X) = 0] \\ \Rightarrow\; & t^2\mu_2 + 2t\mu_3 + \mu_4 + K^2\mu_2^2 + 2K\mu_2^2 \ge 0 . \end{aligned} \]

\(Z(t)\) is a quadratic expression in \(t\), and \(Z(t) \ge 0\) for all \(t\) is possible only if its discriminant is \(\le 0\):

\[ (2\mu_3)^2 - 4\mu_2\,[\mu_4 + K^2\mu_2^2 + 2K\mu_2^2] \le 0 . \]

Divide by \(4\mu_2^3\) (\(> 0\)):

\[ \begin{aligned} \frac{\mu_3^2}{\mu_2^3} - \left[\frac{\mu_4}{\mu_2^2} + K^2 + 2K\right] &\le 0 \; \Rightarrow \; \beta_1 - [\beta_2 + K^2 + 2K] \le 0 \; \Rightarrow \; \beta_2 \\ &\ge \beta_1 - (K^2 + 2K) . \end{aligned} \]

Let \(K = -1\) (the value that makes \(K^2 + 2K = (K + 1)^2 - 1\) smallest, namely \(-1\)):

\[ \beta_2 \ge \beta_1 - (-1) , \qquad\text{that is,}\qquad \beta_2 \ge \beta_1 + 1 . \]

Notes. (1) With \(K = 0\) we get \(\beta_2 \ge \beta_1\). (2) Since \(\beta_1 \ge 0\), \(\beta_2 \ge \beta_1 + 1\) shows \(\beta_2 \ge 1\). Equality \(\beta_2 = \beta_1 + 1\) holds only for a distribution on two points (a Bernoulli variable with \(p = \tfrac14\) has \(\beta_1 = \tfrac43\), \(\beta_2 = \tfrac73\)).

8. Cauchy–Schwarz Inequality

STATEMENT

For any two r.v. \(X, Y\) with finite second moments,

\[ \big[E(XY)\big]^2 \;\le\; E(X^2)\, E(Y^2) \]

Equivalently using deviations:

\[ \big[\text{Cov}(X,Y)\big]^2 \;\le\; \text{Var}(X)\, \text{Var}(Y) \]

This implies the correlation coefficient \(|\rho_{XY}| \le 1\).

EXAMPLE 1

If \(\text{Var}(X) = 16,\; \text{Var}(Y) = 25\), then by Cauchy-Schwarz, \(\text{Cov}(X,Y)^2 \le 400\), i.e., \(|\text{Cov}(X,Y)| \le 20\).

EXAMPLE 2

Equality holds when \(Y = aX + b\) (linear relationship), giving \(\rho = \pm 1\).

Proof of the Cauchy–Schwarz Inequality

PROOF

Consider the real-valued function of \(t\), \(z(t) = E(X + tY)^2\). For all real \(X\), \(Y\) and \(t\), \((X + tY)^2 \ge 0\), so

\[ z(t) = E[(X + tY)^2] \ge 0 \;\;\forall\, t \;\Rightarrow\; E(X^2) + t^2E(Y^2) + 2t\,E(XY) \ge 0 . \]

\(z(t)\) is a quadratic expression in \(t\): \(\phi(t) = At^2 + Bt + C \ge 0\) with \(A = E(Y^2)\), \(B = 2E(XY)\), \(C = E(X^2)\). When \(A = E(Y^2) > 0\), \(\phi(t) \ge 0\) for every \(t\) is possible only when the discriminant \(B^2 - 4AC \le 0\):

\[ \begin{aligned} [2E(XY)]^2 - 4E(Y^2)\,E(X^2) &\le 0 \; \Rightarrow \; [E(XY)]^2 - E(X^2)\,E(Y^2) \le 0 \; \Rightarrow \; [E(XY)]^2 \\ &\le E(X^2)\,E(Y^2) . \end{aligned} \]

If \(E(Y^2) = 0\), then \(Y = 0\) with probability 1, \(E(XY) = 0\), and both sides are 0.

Equality holds exactly when the discriminant is zero: then \(Z(t_0) = 0\) for some \(t_0\), so \(X + t_0Y = 0\) with probability 1, and \(X\) is a constant multiple of \(Y\). Applied to \(X - \mu_X\) and \(Y - \mu_Y\), the same argument gives the covariance form, with equality when \(Y\) is a linear function \(aX + b\) of \(X\).

Worked Problems on Mathematical Expectation

Fourteen problems: seven that find an expectation from a stated distribution, one on a linear change of variable, four applications of Chebyshev's inequality and two checks of the Cauchy–Schwarz inequality, followed by exercises with answers. Every one uses the same two moves: write down the distribution, then weight each value by its probability (a sum) or by its density (an integral). Answers are exact fractions or closed forms, with decimals only at the end, and each Chebyshev bound is set beside the exact probability it bounds.

A. Expectation from a Distribution

WORKED PROBLEM 1 — sixes in a throw of two dice

Two dice are thrown. Find the expected number of sixes.

Let \(X\) = number of sixes. Of the 36 equally likely pairs, 25 show no six, 10 show exactly one (a six on one die and one of five other faces on the other, either way round) and 1 shows two:

\(x\)012
\(p(x)\)\(\tfrac{25}{36}\)\(\tfrac{5}{18}\)\(\tfrac{1}{36}\)
\[ E(X) = 0 \cdot \tfrac{25}{36} + 1 \cdot \tfrac{10}{36} + 2 \cdot \tfrac{1}{36} = \frac{12}{36} = \frac{1}{3} . \]

One die alone gives a six with probability \(\tfrac16\), so two dice give \(\tfrac16 + \tfrac16 = \tfrac13\) on average: the addition theorem of §4 in action. An expectation is a long-run average; no single throw shows a third of a six.

WORKED PROBLEM 2 — \(E(X)\), \(E(X^2)\) and \(E(3X - 2)^2\)

\(X\) takes the values \(-2, 4, 7\) with probabilities \(\tfrac14, \tfrac12, \tfrac14\). Find \(E(X)\), \(E(X^2)\) and \(E(3X - 2)^2\).

\[ E(X) = -2 \cdot \tfrac14 + 4 \cdot \tfrac12 + 7 \cdot \tfrac14 = -\tfrac12 + 2 + \tfrac74 = \frac{13}{4} = 3.25, \] \[ E(X^2) = 4 \cdot \tfrac14 + 16 \cdot \tfrac12 + 49 \cdot \tfrac14 = 1 + 8 + 12.25 = \frac{85}{4} = 21.25 . \]

For the third, expand the square and use linearity rather than squaring each value:

\[ \begin{aligned} E(3X - 2)^2 &= E(9X^2 - 12X + 4) = 9(21.25) - 12(3.25) + 4 = 191.25 - 39 + 4 \\ &= 156.25 . \end{aligned} \]

Check directly: \(3X - 2\) takes \(-8, 10, 19\), and \(64 \cdot \tfrac14 + 100 \cdot \tfrac12 + 361 \cdot \tfrac14 = 16 + 50 + 90.25 = 156.25\).

WORKED PROBLEM 3 — the larger of two dice

Two dice are thrown. Find the expected value of the larger of the two numbers shown.

The larger is at most \(k\) when both dice are at most \(k\), in \(k^2\) of the 36 pairs; so it equals \(k\) in \(k^2 - (k-1)^2 = 2k - 1\) pairs:

\(x\)123456
\(36\,p(x)\)1357911
\[ \sum x \cdot 36\,p(x) = 1 + 6 + 15 + 28 + 45 + 66 = 161, \qquad E(X) = \frac{161}{36} = 4.4722 . \]

A second route, useful for any variable on \(1, 2, 3, \ldots\): \(E(X) = \sum_{k \ge 1} P(X \ge k)\), and \(P(X \ge k) = 1 - \left(\tfrac{k-1}{6}\right)^2\), giving \(\tfrac{36 + 35 + 32 + 27 + 20 + 11}{36} = \frac{161}{36}\). The larger die averages well above the 3.5 of a single die, as it should.

WORKED PROBLEM 4 — five coins: mean and variance

Five coins are tossed. Find the mean and variance of the number of heads.

\(P(X = x) = \binom5x/32\), giving \(\tfrac1{32}, \tfrac5{32}, \tfrac{10}{32}, \tfrac{10}{32}, \tfrac5{32}, \tfrac1{32}\) for \(x = 0, 1, \ldots, 5\).

\[ \begin{gathered} E(X) = \frac{0 + 5 + 20 + 30 + 20 + 5}{32} = \frac{80}{32} = \frac{5}{2}, \\ E(X^2) = \frac{0 + 5 + 40 + 90 + 80 + 25}{32} = \frac{240}{32} = \frac{15}{2}, \end{gathered} \] \[ \operatorname{Var}(X) = E(X^2) - [E(X)]^2 = \frac{15}{2} - \frac{25}{4} = \frac{5}{4} . \]

These agree with the binomial formulae \(np = 5 \cdot \tfrac12 = \tfrac52\) and \(npq = 5 \cdot \tfrac12 \cdot \tfrac12 = \tfrac54\).

WORKED PROBLEM 5 — \(E(X)\), \(E(X^2)\) and \(E(X - 2)^2\)

\(X\) takes the values \(0, 1, 2, 3\) with probabilities \(\tfrac16, \tfrac12, \tfrac14, \tfrac1{12}\). Find \(E(X)\), \(E(X^2)\) and \(E(X - 2)^2\).

First check that the probabilities add to 1: \(\tfrac{2 + 6 + 3 + 1}{12} = 1\). In twelfths,

\[ E(X) = \frac{0 + 6 + 6 + 3}{12} = \frac{5}{4}, \qquad E(X^2) = \frac{0 + 6 + 12 + 9}{12} = \frac{9}{4}, \] \[ E(X - 2)^2 = E(X^2) - 4E(X) + 4 = \frac{27 - 60 + 48}{12} = \frac{5}{4} = 1.25 . \]

Directly: \((X - 2)^2\) is \(4, 1, 0, 1\), and \(\tfrac46 + \tfrac12 + 0 + \tfrac1{12} = \tfrac{8 + 6 + 1}{12} = \tfrac{15}{12}\). Keep the fractions: rounding \(E(X^2)\) and \(4E(X)\) to a few places before subtracting is the easy way to get the third decimal wrong.

WORKED PROBLEM 6 — throwing until the first six

A die is thrown until a six appears. Find the expected number of throws.

The first six comes on throw \(x\) when the first \(x - 1\) throws are not sixes and throw \(x\) is: \(P(X = x) = (\tfrac56)^{x-1}\tfrac16\), \(x = 1, 2, 3, \ldots\). So

\[ S = E(X) = \tfrac16\left(1 + 2\cdot\tfrac56 + 3\left(\tfrac56\right)^2 + 4\left(\tfrac56\right)^3 + \cdots\right) . \]

Multiply by \(\tfrac56\), which shifts every term one place:

\[ \tfrac56 S = \tfrac16\left(\tfrac56 + 2\left(\tfrac56\right)^2 + 3\left(\tfrac56\right)^3 + \cdots\right) . \]

Subtract term by term: each coefficient drops by exactly 1,

\[ S - \tfrac56 S = \tfrac16\left(1 + \tfrac56 + \left(\tfrac56\right)^2 + \cdots\right) = \tfrac16 \cdot \frac{1}{1 - 5/6} = 1 \quad\Longrightarrow\quad \tfrac16 S = 1, \quad S = 6 . \]

In general the wait for an event of probability \(p\) averages \(1/p\) trials. The series converges absolutely, so the rearrangement is legitimate (§1).

WORKED PROBLEM 7 — a continuous expectation

\(X\) has density \(f(x) = 4x^3\), \(0 \le x \le 1\). Find \(E(X)\).

First, \(\int_0^1 4x^3\,dx = [x^4]_0^1 = 1\), so \(f\) is a density. Then

\[ E(X) = \int_0^1 x \cdot 4x^3\,dx = \Big[\frac{4x^5}{5}\Big]_0^1 = \frac45 . \]

The density rises steeply towards 1, so the mean sits well to the right of the midpoint \(\tfrac12\).

B. A Linear Change of Variable

WORKED PROBLEM 8 — standardising \(X\)

\(E(X) = 50\) and \(\operatorname{Var}(X) = 16\). Find positive constants \(a, b\) such that \(Y = aX - b\) has mean 0 and variance 1.

By the properties of §6,

\[ E(Y) = aE(X) - b = 50a - b = 0, \qquad \operatorname{Var}(Y) = a^2\operatorname{Var}(X) = 16a^2 = 1 . \]

The second gives \(a = \tfrac14\) (taking the positive root), and then the first gives \(b = 50a = 12.5\). So \(Y = \tfrac14X - 12.5 = \dfrac{X - 50}{4}\): subtract the mean, divide by the standard deviation. That is exactly how any variable is standardised.

C. Chebyshev's Inequality in Use

WORKED PROBLEM 9 — sixes in 1080 throws

A fair die is thrown 1080 times. Use Chebyshev's inequality to find a lower bound for the probability of getting between 150 and 210 sixes.

\(X\) = number of sixes \(\sim B(n, p)\) with \(n = 1080\), \(p = \tfrac16\):

\[ \mu = np = 180, \qquad \sigma^2 = npq = 1080 \cdot \tfrac16 \cdot \tfrac56 = 150, \qquad \sigma = 12.247 . \]

The range 150 to 210 is \(180 \pm 30\), so with \(c = 30\),

\[ P(150 \le X \le 210) \ge P\big(|X - 180| < 30\big) \ge 1 - \frac{\sigma^2}{c^2} = 1 - \frac{150}{900} = \frac56 = 0.8333 . \]

The exact binomial probability is \(0.9873\): the bound is true and far from sharp.

WORKED PROBLEM 10 — heads in 1600 tosses

A coin is tossed 1600 times. Show, using Chebyshev's inequality, that the probability of between 720 and 880 heads is at least \(\tfrac{15}{16}\).

\(X \sim B(1600, \tfrac12)\): \(\mu = 800\), \(\sigma^2 = 1600 \cdot \tfrac12 \cdot \tfrac12 = 400\), \(\sigma = 20\). The range is \(800 \pm 80\), i.e. \(k = 80/20 = 4\) standard deviations:

\[ P(720 \le X \le 880) \ge P\big(|X - 800| < 80\big) \ge 1 - \frac{1}{4^2} = \frac{15}{16} . \]

(The exact probability is \(0.999944\).)

WORKED PROBLEM 11 — when Chebyshev says nothing

\(X\) takes the values \(-3, 1, 3, 7\) with probabilities \(\tfrac18, \tfrac18, \tfrac12, \tfrac14\). Use Chebyshev's inequality to find an upper bound for \(P(|X - 3| \ge 1)\).

\[ \begin{gathered} \mu = -\tfrac38 + \tfrac18 + \tfrac32 + \tfrac74 = 3, \qquad E(X^2) = \tfrac98 + \tfrac18 + \tfrac92 + \tfrac{49}{4} = 18, \\ \sigma^2 = 18 - 9 = 9, \quad \sigma = 3 . \end{gathered} \]

With \(c = 1\), \(P\big(|X - 3| \ge 1\big) \le \sigma^2/c^2 = 9\).

A probability cannot exceed 1, so a bound of 9 carries no information at all. It happens because \(c = 1\) is smaller than \(\sigma = 3\) (§7: the inequality is informative only for \(c > \sigma\), i.e. \(k > 1\); here \(k = \tfrac13\)). The honest conclusion is that Chebyshev gives no useful bound for this band. The exact answer is easy, since only \(X = 3\) lies within 1 of the mean:

\[ P\big(|X - 3| \ge 1\big) = 1 - P(X = 3) = 1 - \frac12 = \frac12 . \]
|X − 3| < 1 1/8 1/8 1/2 1/4 -4 -3 -2 -1 0 1 2 3 4 5 6 7 8 x P(|X − 3| ≥ 1) = 1/8 + 1/8 + 1/4 = 1/2
Fig 4.2 — Worked Problem 11. Only the value 3 lies within 1 of the mean, so the exact probability of a deviation of at least 1 is \(1/2\). Chebyshev can say nothing useful here: with \(\sigma = 3\) the band is a third of a standard deviation wide, and the bound \(\sigma^2/c^2 = 9\) exceeds 1.
WORKED PROBLEM 12 — a bound for an exponential variable

\(X\) has density \(f(x) = 2e^{-2x}\), \(x \ge 0\). Use Chebyshev's inequality to bound \(P(|X - \tfrac12| < \tfrac34)\), and compare with the exact value.

Integrating by parts, \(\mu = \int_0^\infty 2xe^{-2x}\,dx = \tfrac12\), and \(E(X^2) = \int_0^\infty 2x^2e^{-2x}\,dx = \tfrac12\). Hence \(\sigma^2 = \tfrac12 - \tfrac14 = \tfrac14\), \(\sigma = \tfrac12\).

With \(c = \tfrac34\) (\(k = 1.5\)),

\[ P\big(|X - \tfrac12| < \tfrac34\big) = P(-\tfrac14 < X < \tfrac54) \ge 1 - \frac{1/4}{9/16} = 1 - \frac49 = \frac59 = 0.5556 . \]

Since \(X \ge 0\), the event is \(0 \le X < \tfrac54\), with exact probability \(\int_0^{5/4} 2e^{-2x}\,dx = 1 - e^{-2.5} = 0.9179\). The tail Chebyshev allows is \(0.4444\); the real tail is \(e^{-2.5} = 0.0821\).

c ≤ σ: bound ≥ 1, no information 0 0.25 0.5 0.75 1 0 0.5 1 1.5 2 c (deviation from the mean μ = 0.5; here σ = 0.5) 0.4444 0.0821 at c = 0.75 (dots): bound 4/9, exact e⁻²·⁵ = 0.0821 Chebyshev bound σ²/c² exact P(|X − 0.5| ≥ c)
Fig 4.3 — Worked Problem 12. For \(f(x) = 2e^{-2x}\) (mean and standard deviation both \(\tfrac12\)) the exact chance of a deviation of at least \(c\) sits far below Chebyshev's \(\sigma^2/c^2\). The bound is honest for every distribution with this variance, which is why it is loose for any one of them; and for \(c \le \sigma\) it says nothing at all.

D. The Cauchy–Schwarz Inequality Checked

WORKED PROBLEM 13 — a discrete joint distribution

Verify the Cauchy–Schwarz inequality for the joint distribution

\(Y = 0\)\(Y = 2\)\(p_X\)
\(X = 1\)\(\tfrac16\)\(\tfrac13\)\(\tfrac12\)
\(X = 3\)\(\tfrac14\)\(\tfrac14\)\(\tfrac12\)
\(p_Y\)\(\tfrac5{12}\)\(\tfrac7{12}\)1

From the margins, \(E(X^2) = 1 \cdot \tfrac12 + 9 \cdot \tfrac12 = 5\) and \(E(Y^2) = 4 \cdot \tfrac7{12} = \tfrac{7}{3}\); from the four cells (two of which have \(Y = 0\) and contribute nothing),

\[ E(XY) = 1 \cdot 2 \cdot \tfrac13 + 3 \cdot 2 \cdot \tfrac14 = \tfrac23 + \tfrac32 = \frac{13}{6} . \] \[ \big[E(XY)\big]^2 = \frac{169}{36} = 4.694 \;\le\; E(X^2)\,E(Y^2) = \frac{35}{3} = 11.667 . \]

The inequality holds, and is strict: \(X\) is not a multiple of \(Y\).

WORKED PROBLEM 14 — a continuous joint density

Verify the Cauchy–Schwarz inequality for \(f(x, y) = 6e^{-(2x + 3y)}\), \(x, y \ge 0\).

The density factorises, \(6e^{-(2x+3y)} = 2e^{-2x} \cdot 3e^{-3y}\), so \(X\) and \(Y\) are independent exponentials with rates 2 and 3. For rate \(\lambda\), \(E(X) = 1/\lambda\) and \(E(X^2) = 2/\lambda^2\) (Worked Problem 12 has \(\lambda = 2\)). So \(E(X^2) = \tfrac12\), \(E(Y^2) = \tfrac29\), and the double integral splits:

\[ \begin{gathered} E(XY) = E(X)\,E(Y) = \tfrac12 \cdot \tfrac13 = \tfrac16, \\ \big[E(XY)\big]^2 = \tfrac{1}{36} \;<\; E(X^2)\,E(Y^2) = \tfrac12 \cdot \tfrac29 = \tfrac19 . \end{gathered} \]

Exercises, with Answers Checked

PRACTICE
  1. Show that \(E(aX - bY) = aE(X) - bE(Y)\) for constants \(a, b\). By the addition theorem and \(E(cX) = cE(X)\).
  2. Show that \(\operatorname{Cov}(aX - bY, cX - dY) = ac\operatorname{Var}(X) + bd\operatorname{Var}(Y) - (ad + bc)\operatorname{Cov}(X,Y)\). Proved in §6, “Why the Properties Hold”.
  3. Show that \(\operatorname{Var}(a + bX) = b^2\operatorname{Var}(X)\). The deviation of \(a + bX\) from its mean is \(b(X - \mu)\).
  4. \(X\) takes \(5, 10, 15, 20\) with probabilities \(\tfrac1{10}, \tfrac25, \tfrac3{10}, \tfrac15\). Find the mean and variance. Ans. mean 13, variance 21: \(E(X) = 0.5 + 4 + 4.5 + 4 = 13\), \(E(X^2) = 2.5 + 40 + 67.5 + 80 = 190\), and \(190 - 169 = 21\).
  5. \(X\) takes \(-1, 2, 4\) with probabilities \(\tfrac14, \tfrac12, \tfrac14\). Find (i) \(E(3X - 1)\), (ii) \(E(X^2)\). Ans. (i) \(\tfrac{17}{4}\), (ii) \(\tfrac{25}{4}\): \(E(X) = -\tfrac14 + 1 + 1 = \tfrac74\), so \(E(3X - 1) = \tfrac{21}{4} - 1\); \(E(X^2) = \tfrac14 + 2 + 4\).
  6. A die is thrown until an even number appears. Find the expected number of throws. Ans. 2: the wait for an event of probability \(\tfrac12\), as in Worked Problem 6 with \(p = \tfrac12\).
  7. Six coins are tossed. Find the expected number of heads. Ans. 3: \(\sum x\binom6x/64 = 192/64\).
  8. \(E(X) = 5\) and \(E(X^2) = 34\). Use Chebyshev's inequality to find a lower bound for \(P(-1 < X < 11)\). Ans. \(\tfrac34\): \(\sigma^2 = 34 - 25 = 9\), the interval is \(|X - 5| < 6\), and \(1 - 9/36 = 3/4\).

Key Take-aways from Unit 4