maths2u
Tier
⌕ Search ⌘K
Theorem

The Cauchy–Schwarz inequality

T-018Home MU-103Threads structure
Statement

Let \( V \) be a vector space over the field \( \mathbb{F} \in \{\mathbb{R}, \mathbb{C}\} \), equipped with an inner product \( \langle \cdot , \cdot \rangle : V \times V \to \mathbb{F} \); that is, a map which is linear in its first argument, conjugate-symmetric (\( \langle v, u \rangle = \overline{\langle u, v \rangle} \) for all \( u, v \in V \)), and positive definite (\( \langle u, u \rangle \ge 0 \) with equality if and only if \( u = 0 \)). Write \( \lVert u \rVert := \sqrt{\langle u, u \rangle} \). Then for all \( u, v \in V \), \[ \lvert \langle u, v \rangle \rvert \;\le\; \lVert u \rVert \, \lVert v \rVert , \] with equality if and only if \( u \) and \( v \) are linearly dependent.

Why it matters

Cauchy–Schwarz is the single most-used inequality in linear algebra and analysis. It is the engine behind the triangle inequality for the norm induced by an inner product (so it certifies that \( \lVert \cdot \rVert \) really is a norm), it makes the definition of angle \( \cos\theta = \frac{\langle u, v \rangle}{\lVert u \rVert \lVert v \rVert} \) legitimate in real spaces by forcing the quotient into \( [-1, 1] \), and it gives continuity of the inner product itself.

Beyond geometry, its avatars run through the whole degree: the correlation coefficient of two random variables lies in \( [-1,1] \), \( L^2 \) integral estimates, Bessel's inequality and Fourier analysis, and the Heisenberg uncertainty principle in quantum mechanics are all Cauchy–Schwarz in costume. Any time you must trade "a pairing of two objects" for "sizes of the objects separately," this is the tool.

Hypotheses
Positive semi-definiteness: \( \langle w, w \rangle \ge 0 \) for all \( w \).Drop it and the inequality dies outright. On \( \mathbb{R}^2 \) take the Minkowski form \( \langle x, y \rangle = x_1 y_1 - x_2 y_2 \) (bilinear, symmetric, but indefinite). With \( u = (1,0) \), \( v = (1,1) \): \( \langle u, v \rangle = 1 \) but \( \langle v, v \rangle = 0 \), so \( \lvert \langle u, v \rangle \rvert = 1 \gt 0 = \lVert u \rVert \lVert v \rVert \).
Conjugate symmetry: \( \langle v, u \rangle = \overline{\langle u, v \rangle} \).Without it \( \langle w, w \rangle \) need not even be real, and the statement collapses. On \( \mathbb{R}^2 \) the bilinear form \( \langle x, y \rangle = x_1 y_2 \) is not symmetric; with \( u = (1,0) \), \( v = (0,1) \) we get \( \langle u, v \rangle = 1 \) yet \( \langle u, u \rangle = \langle v, v \rangle = 0 \).
Sesquilinearity (linearity in the first slot; conjugate-linearity in the second follows).The proof expands \( \lVert u - \lambda v \rVert^2 \) term by term; a merely additive or non-homogeneous pairing gives no such expansion. E.g. \( \langle x, y \rangle := \lvert x_1 y_1 \rvert + \lvert x_2 y_2 \rvert \) on \( \mathbb{R}^2 \) is positive but not bilinear, and the projection trick is unavailable.
Positive definiteness (not just semi-definiteness) — needed only for the equality clause.The inequality itself survives with a semi-definite form (see Problem 5), but the characterisation of equality fails: on \( \mathbb{R}^2 \) let \( \langle x, y \rangle = x_1 y_1 \). Then \( u = (1,1) \), \( v = (1,2) \) are linearly independent, yet \( \lvert \langle u, v \rangle \rvert = 1 = \lVert u \rVert \lVert v \rVert \).
Proof
1
Case \( v = 0 \): then \( \langle u, v \rangle = 0 \) and \( \lVert v \rVert = 0 \), so both sides equal \( 0 \) and the inequality holds; moreover \( \{u, 0\} \) is linearly dependent, so the equality clause is consistent.
\( \langle u, 0 \rangle = \overline{\langle 0, u \rangle} = \overline{\langle 0 \cdot 0, u \rangle} = \overline{0 \cdot \langle 0, u \rangle} = 0 \), using conjugate symmetry and linearity in the first argument. A
2
Assume henceforth \( v \ne 0 \), and define \[ \lambda := \frac{\langle u, v \rangle}{\lVert v \rVert^2} \in \mathbb{F}. \]
Legal because positive definiteness gives \( \lVert v \rVert^2 = \langle v, v \rangle \gt 0 \) when \( v \ne 0 \). This \( \lambda \) is the coefficient of the orthogonal projection of \( u \) onto the line \( \mathbb{F}v \) — the key idea of the whole proof: compare \( u \) with its shadow on \( v \). B
3
\[ 0 \;\le\; \lVert u - \lambda v \rVert^2 \;=\; \langle u - \lambda v,\; u - \lambda v \rangle . \]
Positive semi-definiteness of the inner product, applied to the vector \( u - \lambda v \in V \). A
4
\[ \langle u - \lambda v, u - \lambda v \rangle = \lVert u \rVert^2 - \overline{\lambda}\,\langle u, v \rangle - \lambda\,\langle v, u \rangle + \lvert \lambda \rvert^2 \lVert v \rVert^2 . \]
Expand using linearity in the first slot and conjugate-linearity in the second: \( \langle u, \lambda v \rangle = \overline{\lambda} \langle u, v \rangle \) (conjugate-linearity in the second argument, itself a consequence of first-slot linearity plus conjugate symmetry), \( \langle \lambda v, u \rangle = \lambda \langle v, u \rangle \), and \( \langle \lambda v, \lambda v \rangle = \lambda \overline{\lambda} \langle v, v \rangle = \lvert \lambda \rvert^2 \lVert v \rVert^2 \). C
5
Substituting \( \lambda = \langle u, v \rangle / \lVert v \rVert^2 \) and \( \langle v, u \rangle = \overline{\langle u, v \rangle} \): \[ \overline{\lambda}\langle u, v \rangle = \frac{\lvert \langle u, v \rangle \rvert^2}{\lVert v \rVert^2}, \qquad \lambda \langle v, u \rangle = \frac{\lvert \langle u, v \rangle \rvert^2}{\lVert v \rVert^2}, \qquad \lvert \lambda \rvert^2 \lVert v \rVert^2 = \frac{\lvert \langle u, v \rangle \rvert^2}{\lVert v \rVert^2}, \] \[ \text{hence} \quad 0 \;\le\; \lVert u - \lambda v \rVert^2 \;=\; \lVert u \rVert^2 - \frac{\lvert \langle u, v \rangle \rvert^2}{\lVert v \rVert^2}. \]
Direct computation with \( z\overline{z} = \lvert z \rvert^2 \) for \( z \in \mathbb{C} \); the three middle terms combine as \( -2\frac{\lvert \langle u,v \rangle \rvert^2}{\lVert v \rVert^2} + \frac{\lvert \langle u,v \rangle \rvert^2}{\lVert v \rVert^2} \). C
6
\[ \lvert \langle u, v \rangle \rvert^2 \;\le\; \lVert u \rVert^2 \, \lVert v \rVert^2 \quad\Longrightarrow\quad \lvert \langle u, v \rangle \rvert \;\le\; \lVert u \rVert \, \lVert v \rVert . \]
Multiply the inequality of Step 5 by \( \lVert v \rVert^2 \gt 0 \) and rearrange; then take square roots, which is legal because both sides are non-negative and \( t \mapsto \sqrt{t} \) is monotone increasing on \( [0, \infty) \). A
7
Equality analysis (\( v \ne 0 \)): equality in Step 6 holds \( \iff \lVert u - \lambda v \rVert^2 = 0 \iff u = \lambda v \). Conversely, if \( u = \alpha v \) for some \( \alpha \in \mathbb{F} \), then \( \lvert \langle u, v \rangle \rvert = \lvert \alpha \rvert \, \lVert v \rVert^2 = \lVert u \rVert \, \lVert v \rVert \).
Tracing back: equality in the final line forces \( \lVert u \rVert^2 - \lvert \langle u,v \rangle \rvert^2 / \lVert v \rVert^2 = 0 \), i.e. the quantity in Step 5 vanishes; positive definiteness then gives \( u - \lambda v = 0 \), so \( u \in \mathbb{F} v \). The converse is the computation \( \langle \alpha v, v \rangle = \alpha \lVert v \rVert^2 \) and \( \lVert \alpha v \rVert = \lvert \alpha \rvert \lVert v \rVert \) (homogeneity of the norm). Together with Step 1 this is exactly: equality \( \iff \) \( \{u, v\} \) linearly dependent. B
Result
\[ \lvert \langle u, v \rangle \rvert \;\le\; \lVert u \rVert \, \lVert v \rVert \qquad \text{for all } u, v \in V, \] \[ \text{with equality} \iff u, v \text{ linearly dependent.} \]

Reading. The pairing of two vectors can never exceed the product of their individual sizes. A vector's "shadow" on another vector is never longer than the vector itself — the inequality is literally the statement that orthogonal projection cannot lengthen.

Scope. Valid in every real or complex inner product space, of any dimension, complete or not: \( \mathbb{R}^n \) and \( \mathbb{C}^n \) with the standard products, \( \ell^2 \), \( C[a,b] \) with \( \langle f, g \rangle = \int_a^b f \overline{g} \), \( L^2(\mu) \) (after identifying a.e.-equal functions), spaces of random variables with \( \langle X, Y \rangle = \mathbb{E}[X\overline{Y}] \). The inequality (not the equality clause) even survives for positive semi-definite Hermitian forms. It does not apply to indefinite forms (Minkowski/Lorentzian geometry) or to non-symmetric bilinear pairings.

Corollaries & converses
  • Triangle inequality. \( \lVert u + v \rVert \le \lVert u \rVert + \lVert v \rVert \) (Problem 2); hence \( \lVert \cdot \rVert = \sqrt{\langle \cdot, \cdot \rangle} \) is a genuine norm and every inner product space is a normed (hence metric) space.
  • Angles exist. In a real inner product space, \( \frac{\langle u, v \rangle}{\lVert u \rVert \lVert v \rVert} \in [-1, 1] \) for nonzero \( u, v \), so \( \theta := \arccos \) of that quotient is well-defined.
  • Continuity of the inner product. \( \lvert \langle u_n, v_n \rangle - \langle u, v \rangle \rvert \le \lVert u_n - u \rVert \lVert v_n \rVert + \lVert u \rVert \lVert v_n - v \rVert \to 0 \); crucial for Hilbert space arguments that pass limits through \( \langle \cdot, \cdot \rangle \).
  • Classical special cases. \( \left( \sum_{i=1}^n a_i b_i \right)^2 \le \left( \sum_{i=1}^n a_i^2 \right)\left( \sum_{i=1}^n b_i^2 \right) \) (Cauchy, 1821) and \( \left( \int_a^b fg \right)^2 \le \int_a^b f^2 \int_a^b g^2 \) (Bunyakovsky, 1859).
  • Probability. \( \lvert \operatorname{Cov}(X, Y) \rvert \le \sigma_X \sigma_Y \), so the correlation coefficient satisfies \( \lvert \rho \rvert \le 1 \) (Problem 4).
  • Converse (equality clause). Equality \( \Rightarrow \) linear dependence holds — but only under positive definiteness; for semi-definite forms it fails (see Fails without).
  • A converse-type theorem nearby. Not every norm admits an inner product producing it via \( \lVert u \rVert = \sqrt{\langle u,u \rangle} \): by the Jordan–von Neumann theorem a norm arises from an inner product iff it satisfies the parallelogram law \( \lVert u+v \rVert^2 + \lVert u-v \rVert^2 = 2\lVert u \rVert^2 + 2\lVert v \rVert^2 \); e.g. the \( \sup \)-norm on \( C[0,1] \) does not.
Fails without
  • Without positivity (indefinite form): on \( \mathbb{R}^2 \) with \( \langle x, y \rangle = x_1 y_1 - x_2 y_2 \), take \( u = (1, 0) \) and \( v = (1, 1) \). Then \( \langle u, v \rangle = 1 \), while \( \langle v, v \rangle = 1 - 1 = 0 \), so \( \lVert u \rVert \lVert v \rVert = 1 \cdot 0 = 0 \lt 1 = \lvert \langle u, v \rangle \rvert \). The inequality is false, and worse, "null vectors" \( v \ne 0 \) with \( \langle v, v \rangle = 0 \) exist — the geometry of special relativity, where Cauchy–Schwarz genuinely reverses on timelike vectors.
  • Without symmetry: on \( \mathbb{R}^2 \) with the bilinear form \( \langle x, y \rangle = x_1 y_2 \), take \( u = (1, 0) \), \( v = (0, 1) \). Then \( \langle u, v \rangle = 1 \) but \( \langle u, u \rangle = 0 \) and \( \langle v, v \rangle = 0 \), so the right-hand side is \( 0 \lt 1 \).
  • Equality clause without definiteness: on \( \mathbb{R}^2 \) with the positive semi-definite form \( \langle x, y \rangle = x_1 y_1 \), take \( u = (1, 1) \), \( v = (1, 2) \): these are linearly independent, yet \( \lvert \langle u, v \rangle \rvert = 1 \) and \( \lVert u \rVert \lVert v \rVert = 1 \cdot 1 = 1 \). Equality no longer detects dependence — only dependence modulo the null space \( \{ w : \langle w, w \rangle = 0 \} \).
Common errors
  • Dropping the modulus over \( \mathbb{C} \). Writing \( \langle u, v \rangle \le \lVert u \rVert \lVert v \rVert \) is meaningless in a complex space: \( \langle u, v \rangle \) is a complex number and complex numbers are not ordered. The theorem bounds \( \lvert \langle u, v \rangle \rvert \).
  • The circular angle "proof". Arguing \( \langle u, v \rangle = \lVert u \rVert \lVert v \rVert \cos\theta \) and \( \lvert \cos\theta \rvert \le 1 \) is circular in abstract spaces: the angle \( \theta \) is defined via Cauchy–Schwarz, not the other way round.
  • Dividing by \( \lVert v \rVert \) without excluding \( v = 0 \). The projection coefficient \( \lambda = \langle u, v \rangle / \lVert v \rVert^2 \) requires \( v \ne 0 \); the degenerate case must be handled separately (Step 1).
  • Misstating the equality condition as \( u = v \). Equality holds iff one vector is a scalar multiple of the other — e.g. \( u = (1,1) \), \( v = (3,3) \) in \( \mathbb{R}^2 \) achieve equality with \( u \ne v \); and over \( \mathbb{C} \), the scalar may be any complex number, so "equality iff \( u, v \) point the same way" is also wrong.
  • Applying it to non-inner products. Students bound \( x_1 y_1 - x_2 y_2 \) or a general bilinear form by "Cauchy–Schwarz"; the theorem needs positive (semi-)definiteness, full stop.
  • Squaring carelessly. Concluding \( \lvert \langle u,v \rangle \rvert \le \lVert u \rVert \lVert v \rVert \) from the squared version requires both sides non-negative; conversely, deducing the squared version from the unsquared one is fine, but mixing the two mid-argument without noting monotonicity of \( t \mapsto t^2 \) on \( [0,\infty) \) loses marks in a rigour-first course.
Discussion

The proof deserves a second look, because it is a single geometric idea dressed in algebra: subtract from \( u \) its orthogonal projection \( \lambda v \) onto the line spanned by \( v \), and observe that what remains has non-negative squared length. Everything else is bookkeeping. The residual \( u - \lambda v \) is precisely the component of \( u \) orthogonal to \( v \) (check: \( \langle u - \lambda v, v \rangle = \langle u, v \rangle - \lambda \lVert v \rVert^2 = 0 \)), so Step 5 is the Pythagorean identity \( \lVert u \rVert^2 = \lVert \lambda v \rVert^2 + \lVert u - \lambda v \rVert^2 \) in disguise: Cauchy–Schwarz says a right-angled triangle's leg is no longer than its hypotenuse.

The history explains the three-barrelled name. Augustin-Louis Cauchy proved the finite-sum case in his 1821 Cours d'analyse. Viktor Bunyakovsky, a student of Cauchy in Paris, published the integral version in 1859 — a quarter century before Hermann Schwarz's 1888 rediscovery, which is why Russian-tradition texts say "Cauchy–Bunyakovsky". Schwarz's contribution was the modern viewpoint: his argument works in any inner product space, and it is his quadratic-in-\( t \) discriminant trick (Problem 5) that most textbooks still teach. The abstract formulation had to wait for the axiomatisation of Hilbert spaces by Hilbert, Schmidt and von Neumann in the early twentieth century.

Structurally, Cauchy–Schwarz sits at the base of a tower of inequalities. It is the \( p = q = 2 \) case of Hölder's inequality \( \lvert \int f \overline{g} \rvert \le \lVert f \rVert_p \lVert g \rVert_q \) with \( \frac{1}{p} + \frac{1}{q} = 1 \), and it implies Minkowski's inequality (the triangle inequality in \( L^p \) for \( p = 2 \)). In probability it yields \( \lvert \rho \rvert \le 1 \) and the second-moment method; in numerical linear algebra it controls condition numbers and convergence of gradient methods; in quantum mechanics, applied to the vectors \( (A - \langle A \rangle)\psi \) and \( (B - \langle B \rangle)\psi \), it produces the Robertson uncertainty relation \( \sigma_A \sigma_B \ge \frac{1}{2} \lvert \langle [A, B] \rangle \rvert \), of which Heisenberg's principle is the case \( A = x \), \( B = p \).

Two refinements matter at the frontier of a first course. First, the proof of the inequality never used definiteness — only \( \langle w, w \rangle \ge 0 \) — provided one replaces the division by \( \lVert v \rVert^2 \) with the discriminant argument (Problem 5). This semi-definite version is the workhorse of the GNS construction in operator algebras, where one starts from a positive linear functional \( \varphi \) on a \( C^* \)-algebra, forms the semi-definite pairing \( \langle a, b \rangle = \varphi(b^* a) \), and uses Cauchy–Schwarz to show that the null set \( N = \{ a : \varphi(a^* a) = 0 \} \) is a left ideal — the quotient then carries an honest inner product. Second, there are operator-valued strengthenings (the Kadison and Cauchy–Schwarz operator inequalities \( \varphi(a)^* \varphi(a) \le \varphi(a^* a) \) for unital completely positive maps) in which the modulus is replaced by the operator order; these reduce to the classical statement when the algebra is \( \mathbb{C} \).

Common misconceptions. Cauchy–Schwarz is not "obvious from the picture": the picture presupposes that angles make sense, which is exactly what the theorem licenses. It is not restricted to finite dimensions — no dimension count appears anywhere in the proof — and it does not require completeness: it holds in every inner product space, Hilbert or not. Finally, equality is not rare bookkeeping: the equality case is used constantly (e.g. to show that extremisers of variational problems are eigenvectors, or that \( \lvert \rho \rvert = 1 \) forces an affine relation \( Y = aX + b \) almost surely).

Worked examples

Example 1 (finite sums). Show that for all real numbers \( a, b, c \), \( (a + b + c)^2 \le 3\,(a^2 + b^2 + c^2) \), and determine when equality holds.

1
Work in \( \mathbb{R}^3 \) with the standard inner product \( \langle x, y \rangle = \sum_{i=1}^3 x_i y_i \), and set \( u = (a, b, c) \), \( v = (1, 1, 1) \).
The standard dot product is bilinear, symmetric and positive definite, so the theorem applies. A
2
\[ \langle u, v \rangle = a + b + c, \qquad \lVert u \rVert = \sqrt{a^2 + b^2 + c^2}, \qquad \lVert v \rVert = \sqrt{3}. \]
Direct computation from the definitions. A
3
\[ \lvert a + b + c \rvert \;\le\; \sqrt{3}\,\sqrt{a^2 + b^2 + c^2} \quad\Longrightarrow\quad (a+b+c)^2 \le 3\,(a^2+b^2+c^2). \]
Cauchy–Schwarz applied to \( u, v \); then square both (non-negative) sides. B
4
Equality \( \iff u = \lambda v \) for some \( \lambda \in \mathbb{R} \), i.e. \( a = b = c \).
Equality clause of the theorem: \( v \ne 0 \), so equality forces \( u \in \mathbb{R}v \). A
\[ (a + b + c)^2 \;\le\; 3\,(a^2 + b^2 + c^2), \qquad \text{equality} \iff a = b = c. \]

Reading. The square of a sum is at most \( n \) times the sum of squares (here \( n = 3 \)) — the arithmetic mean is bounded by the quadratic mean.

Scope. The same choice \( v = (1, \dots, 1) \in \mathbb{R}^n \) gives \( \left( \sum_{i=1}^n a_i \right)^2 \le n \sum_{i=1}^n a_i^2 \) for every \( n \in \mathbb{N} \).

Example 2 (integrals). Show that \( \int_0^1 \sqrt{x(1-x)}\, dx \le \frac{1}{2} \), without computing the integral.

1
Work in \( V = C[0,1] \), the real vector space of continuous functions on \( [0,1] \), with \( \langle f, g \rangle = \int_0^1 f(x) g(x)\, dx \). This is an inner product: bilinearity and symmetry are properties of the integral, and if \( f \ne 0 \) then \( f^2 \gt 0 \) on some interval by continuity, so \( \int_0^1 f^2 \gt 0 \).
Verification of the hypotheses on the ambient space — positive definiteness genuinely needs continuity here. B
2
Take \( f(x) = \sqrt{x} \) and \( g(x) = \sqrt{1 - x} \); both are continuous on \( [0,1] \), and \[ \langle f, g \rangle = \int_0^1 \sqrt{x}\,\sqrt{1-x}\; dx = \int_0^1 \sqrt{x(1-x)}\, dx . \]
The target integral is realised as an inner product of two legitimate members of \( V \). B
3
\[ \lVert f \rVert^2 = \int_0^1 x\, dx = \frac{1}{2}, \qquad \lVert g \rVert^2 = \int_0^1 (1 - x)\, dx = \frac{1}{2}. \]
Elementary integration. A
4
\[ \int_0^1 \sqrt{x(1-x)}\, dx \;=\; \langle f, g \rangle \;\le\; \lVert f \rVert \lVert g \rVert \;=\; \sqrt{\tfrac{1}{2}} \cdot \sqrt{\tfrac{1}{2}} \;=\; \frac{1}{2}, \] and the inequality is strict, since \( f \) and \( g \) are not scalar multiples of one another (\( f(0) = 0 \ne g(0) \), \( g(1) = 0 \ne f(1) \)).
Cauchy–Schwarz, plus its equality clause to certify strictness. (The true value is \( \pi/8 \approx 0.3927 \).) B
\[ \int_0^1 \sqrt{x(1-x)}\, dx \;\lt\; \frac{1}{2}. \]

Reading. Splitting an integrand into a product of two simpler square roots converts a hard integral bound into two trivial ones.

Scope. The template \( \int fg \le \left( \int f^2 \right)^{1/2} \left( \int g^2 \right)^{1/2} \) works on any interval for any \( f, g \) continuous (or in \( L^2 \)); choosing the factorisation of the integrand is the only creative step.

Problems
  1. Let \( u = (1, 2, 2) \) and \( v = (3, 0, 4) \) in \( \mathbb{R}^3 \) with the standard inner product. Verify the Cauchy–Schwarz inequality numerically for this pair, and decide (with justification from the theorem) whether equality holds.
    Solution \( \langle u, v \rangle = 1 \cdot 3 + 2 \cdot 0 + 2 \cdot 4 = 11 \). \( \lVert u \rVert = \sqrt{1 + 4 + 4} = 3 \), \( \lVert v \rVert = \sqrt{9 + 0 + 16} = 5 \). The theorem asserts \( \lvert 11 \rvert \le 3 \cdot 5 = 15 \), which holds. Equality would require \( u = \lambda v \) for some \( \lambda \in \mathbb{R} \); comparing second coordinates gives \( 2 = \lambda \cdot 0 = 0 \), a contradiction, so \( u, v \) are linearly independent and the inequality is strict — consistent with \( 11 \lt 15 \).
  2. Prove the triangle inequality: in any inner product space over \( \mathbb{F} \in \{\mathbb{R}, \mathbb{C}\} \), \( \lVert u + v \rVert \le \lVert u \rVert + \lVert v \rVert \) for all \( u, v \).
    Solution Expand using sesquilinearity and conjugate symmetry: \[ \lVert u + v \rVert^2 = \langle u + v, u + v \rangle = \lVert u \rVert^2 + \langle u, v \rangle + \overline{\langle u, v \rangle} + \lVert v \rVert^2 = \lVert u \rVert^2 + 2\operatorname{Re}\langle u, v \rangle + \lVert v \rVert^2 . \] Since \( \operatorname{Re} z \le \lvert z \rvert \) for every \( z \in \mathbb{C} \), Cauchy–Schwarz gives \( \operatorname{Re}\langle u, v \rangle \le \lvert \langle u, v \rangle \rvert \le \lVert u \rVert \lVert v \rVert \). Hence \[ \lVert u + v \rVert^2 \le \lVert u \rVert^2 + 2 \lVert u \rVert \lVert v \rVert + \lVert v \rVert^2 = \left( \lVert u \rVert + \lVert v \rVert \right)^2 . \] Both sides are non-negative, so taking square roots (monotone on \( [0, \infty) \)) yields \( \lVert u + v \rVert \le \lVert u \rVert + \lVert v \rVert \).
  3. Let \( a_1, \dots, a_n \gt 0 \). Prove that \[ \left( \sum_{i=1}^n a_i \right) \left( \sum_{i=1}^n \frac{1}{a_i} \right) \ge n^2, \] and determine when equality holds.
    Solution In \( \mathbb{R}^n \) with the standard inner product, set \( u = \left( \sqrt{a_1}, \dots, \sqrt{a_n} \right) \) and \( v = \left( \frac{1}{\sqrt{a_1}}, \dots, \frac{1}{\sqrt{a_n}} \right) \) (legitimate since each \( a_i \gt 0 \)). Then \[ \langle u, v \rangle = \sum_{i=1}^n \sqrt{a_i} \cdot \frac{1}{\sqrt{a_i}} = n, \qquad \lVert u \rVert^2 = \sum_{i=1}^n a_i, \qquad \lVert v \rVert^2 = \sum_{i=1}^n \frac{1}{a_i}. \] Cauchy–Schwarz in squared form gives \( n^2 = \lvert \langle u, v \rangle \rvert^2 \le \lVert u \rVert^2 \lVert v \rVert^2 = \left( \sum a_i \right)\left( \sum \frac{1}{a_i} \right) \). Equality holds iff \( u = \lambda v \) for some \( \lambda \), i.e. \( \sqrt{a_i} = \lambda / \sqrt{a_i} \) for all \( i \), i.e. \( a_i = \lambda \) for all \( i \): all the \( a_i \) are equal.
  4. Let \( X, Y \) be real random variables on a probability space with \( \mathbb{E}[X^2] \lt \infty \), \( \mathbb{E}[Y^2] \lt \infty \), and positive variances \( \sigma_X^2, \sigma_Y^2 \). Prove that the correlation coefficient \( \rho = \dfrac{\operatorname{Cov}(X, Y)}{\sigma_X \sigma_Y} \) satisfies \( \lvert \rho \rvert \le 1 \), and show that \( \lvert \rho \rvert = 1 \) implies \( Y = aX + b \) almost surely for some constants \( a \ne 0, b \).
    Solution Let \( \tilde{X} = X - \mathbb{E}[X] \), \( \tilde{Y} = Y - \mathbb{E}[Y] \). On the space \( L^2 \) of square-integrable random variables modulo almost-sure equality, \( \langle U, W \rangle := \mathbb{E}[U W] \) is a real inner product: bilinearity and symmetry come from linearity of expectation, \( \mathbb{E}[U^2] \ge 0 \), and \( \mathbb{E}[U^2] = 0 \) implies \( U = 0 \) a.s., which is the zero element of the quotient space — this is why we must work modulo null sets to get definiteness. Now \[ \operatorname{Cov}(X, Y) = \mathbb{E}[\tilde{X}\tilde{Y}] = \langle \tilde{X}, \tilde{Y} \rangle, \qquad \sigma_X = \lVert \tilde{X} \rVert, \qquad \sigma_Y = \lVert \tilde{Y} \rVert . \] Cauchy–Schwarz gives \( \lvert \operatorname{Cov}(X, Y) \rvert \le \sigma_X \sigma_Y \), i.e. \( \lvert \rho \rvert \le 1 \). If \( \lvert \rho \rvert = 1 \), the equality clause forces linear dependence in \( L^2 \): \( \tilde{Y} = a \tilde{X} \) a.s. for some \( a \in \mathbb{R} \) (\( a \ne 0 \) since \( \sigma_Y \gt 0 \); indeed \( \sigma_Y = \lvert a \rvert \sigma_X \)). Unwinding, \( Y = aX + b \) a.s. with \( b = \mathbb{E}[Y] - a\,\mathbb{E}[X] \).
  5. (Semi-definite Cauchy–Schwarz.) Let \( V \) be a complex vector space and \( \langle \cdot, \cdot \rangle \) a Hermitian sesquilinear form that is only positive semi-definite: \( \langle w, w \rangle \ge 0 \) for all \( w \), but possibly \( \langle w, w \rangle = 0 \) for some \( w \ne 0 \). Prove that \( \lvert \langle u, v \rangle \rvert \le \sqrt{\langle u, u \rangle} \sqrt{\langle v, v \rangle} \) still holds for all \( u, v \). (Hint: the projection trick divides by \( \langle v, v \rangle \), which may vanish; find another route.)
    Solution If \( \langle u, v \rangle = 0 \) there is nothing to prove, so assume \( \langle u, v \rangle \ne 0 \) and choose \( \theta \in \mathbb{R} \) with \( \langle u, v \rangle = e^{i\theta} \lvert \langle u, v \rangle \rvert \). For every \( t \in \mathbb{R} \), semi-definiteness applied to \( u - t e^{i\theta} v \) gives \[ 0 \le \langle u - t e^{i\theta} v,\; u - t e^{i\theta} v \rangle = \langle u, u \rangle - t\, \overline{e^{i\theta}} \langle u, v \rangle - t\, e^{i\theta} \langle v, u \rangle + t^2 \langle v, v \rangle . \] Now \( \overline{e^{i\theta}} \langle u, v \rangle = e^{-i\theta} e^{i\theta} \lvert \langle u, v \rangle \rvert = \lvert \langle u, v \rangle \rvert \), and by Hermitian symmetry \( e^{i\theta} \langle v, u \rangle = e^{i\theta} \overline{\langle u, v \rangle} = e^{i\theta} e^{-i\theta} \lvert \langle u, v \rangle \rvert = \lvert \langle u, v \rangle \rvert \). So the real quadratic \[ p(t) := \langle v, v \rangle\, t^2 \;-\; 2 \lvert \langle u, v \rangle \rvert\, t \;+\; \langle u, u \rangle \] satisfies \( p(t) \ge 0 \) for all \( t \in \mathbb{R} \). Two cases. (i) If \( \langle v, v \rangle \gt 0 \): a real quadratic with positive leading coefficient that is non-negative everywhere has discriminant \( \le 0 \), so \( 4 \lvert \langle u, v \rangle \rvert^2 - 4 \langle v, v \rangle \langle u, u \rangle \le 0 \), which is the claim. (ii) If \( \langle v, v \rangle = 0 \): then \( p(t) = -2 \lvert \langle u, v \rangle \rvert t + \langle u, u \rangle \) is an affine function of \( t \) that is non-negative for all \( t \in \mathbb{R} \); letting \( t \to +\infty \), this forces \( \lvert \langle u, v \rangle \rvert = 0 \), contradicting our assumption \( \langle u, v \rangle \ne 0 \) — so in this case \( \langle u, v \rangle = 0 \) and the inequality reads \( 0 \le 0 \). In both cases \( \lvert \langle u, v \rangle \rvert \le \sqrt{\langle u, u \rangle} \sqrt{\langle v, v \rangle} \). (Note the equality clause is genuinely lost: with \( \langle x, y \rangle = x_1 \overline{y_1} \) on \( \mathbb{C}^2 \), the independent vectors \( (1,1) \) and \( (1,2) \) achieve equality.)