Evanalysis
9.4Estimated reading time: 8 min

9.4 Cauchy-Schwarz and triangle inequalities

Study Cauchy-Schwarz and triangle inequalities as the two core estimates that control length, angle, and equality cases in inner-product spaces.

Course contents

MATH1030: Linear algebra I

Rigorous linear algebra notes on systems, matrices, structure, and proof, with interaction used only where it clarifies the mathematics.

Chapter 1Systems of equations1 sections
Chapter 4Solution structure1 sections
Chapter 5Invertibility1 sections

The inner product gives formulas for length and angle. The next question is: what restrictions do those formulas obey?

Two answers dominate the subject:

  • the Cauchy-Schwarz inequality controls the size of an inner product by the lengths of the two vectors;
  • the triangle inequality says the direct path from 0 to u+vu+v is never longer than taking the two steps through u and then u+vu+v.

These inequalities are not optional technicalities. They are the estimates that make Euclidean geometry work algebraically.

Cauchy-Schwarz inequality

Theorem

Cauchy-Schwarz inequality

For all vectors v,wRmv,w\in\mathbb{R}^m,

v,wvw.|\langle v,w\rangle|\le\|v\|\,\|w\|.

Equality holds if and only if v and w are linearly dependent.

The inequality says an inner product can never be larger in magnitude than the product of the two lengths. That is exactly what makes the cosine formula

cosθ=v,wvw\cos\theta=\frac{\langle v,w\rangle}{\|v\|\,\|w\|}

meaningful: the right-hand side always stays between 1-1 and 1.

Proof

The quadratic-polynomial proof

Worked example

Check Cauchy-Schwarz numerically

Let

v=[123],w=[456].v= \begin{bmatrix} 1\\2\\3 \end{bmatrix}, \qquad w= \begin{bmatrix} 4\\5\\6 \end{bmatrix}.

Then

v,w=32,v=14,w=77.\langle v,w\rangle=32, \qquad \|v\|=\sqrt{14}, \qquad \|w\|=\sqrt{77}.

So

v,w=32,vw=1477=107832.83.|\langle v,w\rangle|=32, \qquad \|v\|\,\|w\|=\sqrt{14\cdot77}=\sqrt{1078}\approx32.83.

Indeed,

3232.83.32\le32.83.

Triangle inequality

Theorem

Triangle inequality

For all vectors u,vRmu,v\in\mathbb{R}^m,

u+vu+v.\|u+v\|\le\|u\|+\|v\|.

Equality holds if and only if at least one of u and v is a nonnegative scalar multiple of the other.

The geometric reading is direct: in Euclidean space, one side of a triangle is never longer than the sum of the other two sides.

Proof

Why Cauchy-Schwarz implies triangle inequality

Theorem

Reverse triangle inequality

For all vectors u,vRmu,v\in\mathbb{R}^m,

uvuv.\|u-v\|\ge\bigl|\|u\|-\|v\|\bigr|.

Equality holds under the same nonnegative-multiple condition.

This version is often easier to use when you want a lower bound instead of an upper bound.

Equality cases matter

The equalities are not side remarks. They tell you exactly when the estimate is tight.

  • In Cauchy-Schwarz, equality means the two vectors point in the same or opposite direction, so one is a scalar multiple of the other.
  • In the triangle inequality, equality means the two vectors point in the same direction with a nonnegative scalar factor, so walking along u and then v really does trace one straight segment.

Worked example

When triangle inequality becomes equality

Let

u=[20],v=[30].u= \begin{bmatrix} 2\\0 \end{bmatrix}, \qquad v= \begin{bmatrix} 3\\0 \end{bmatrix}.

Then v=32uv=\frac32u, so v is a nonnegative scalar multiple of u. Hence

u+v=[50]=5=2+3=u+v.\|u+v\|=\left\| \begin{bmatrix} 5\\0 \end{bmatrix} \right\|=5 =2+3 =\|u\|+\|v\|.

So equality holds.

Common mistake

Common mistake

Equality in Cauchy-Schwarz is not the same as orthogonality

Orthogonality means v,w=0\langle v,w\rangle=0. Equality in Cauchy-Schwarz means

v,w=vw,|\langle v,w\rangle|=\|v\|\,\|w\|,

which happens when the vectors are linearly dependent, not when they are perpendicular. These are almost opposite geometric situations.

Quick check

Quick check

What does Cauchy-Schwarz say about v,w|\langle v,w\rangle|?

State the inequality directly.

Solution

Answer

Quick check

If u and v point in exactly the same direction, can equality hold in the triangle inequality?

Assume one is a nonnegative scalar multiple of the other.

Solution

Answer

Quick check

If vwv\perp w, what does Cauchy-Schwarz reduce to?

Use v,w=0\langle v,w\rangle=0.

Solution

Answer

Exercises

Quick check

Use Cauchy-Schwarz to show that (1,2),(3,4)(1,2)(3,4)|\langle (1,2),(3,4)\rangle| \le \|(1,2)\|\,\|(3,4)\|.

Compute both sides numerically.

Solution

Guided solution

Quick check

Find u+v\|u+v\| and compare it with u+v\|u\|+\|v\| for u=(1,0)u=(1,0) and v=(0,1)v=(0,1).

This is the right-angle case.

Solution

Guided solution

Quick check

Use the reverse triangle inequality to bound uv\|u-v\| from below when u=7\|u\|=7 and v=3\|v\|=3.

Apply the formula directly.

Solution

Guided solution

Read 9.1 Inner products, norms, and angles first, because these inequalities are built directly from the inner-product and norm formulas.

The coefficient formulas in 9.2 Orthogonal sets and orthonormal bases and the geometry of 9.3 Gram-Schmidt orthogonalization both rely on the estimates proved here.

Section mastery checkpoint

Answer each question correctly to complete this section checkpoint. Correct progress: 0%.

Skills: cauchy-schwarz, inner-product, norm

What does the Cauchy-Schwarz inequality say about the inner product of v and w?

Attempts used: 0

Attempts remaining: Unlimited attempts

Preview does not consume an attempt.

Submit records a graded attempt.

Key terms in this unit

More notes in this series