Tutorials › Calculus III › The Pythagorean Identity for Vector Components

Dot Products and Projections · Tutorial 63 of 999

The Pythagorean Identity for Vector Components

Learn to justify the Pythagorean identity for perpendicular vector components and use it to find an unknown length without losing track of signs.

Beginner 9 min read

What You'll Learn

  • State the sum-of-squares identity for perpendicular vectors.
  • Derive the identity from dot-product properties.
  • Apply it to parallel and perpendicular parts of a vector.
  • Recover an unknown component length from the other lengths.
  • Distinguish a signed scalar component from a nonnegative length.
  • Check whether the given lengths can form a valid decomposition.

Why Perpendicular Components Produce a Sum of Squares

A vector can be split into parts that point in different directions. When those parts are perpendicular, the length of the original vector is linked to the lengths of its components by the same sum-of-squares relationship as the sides of a right triangle.

This identity is useful in both directions: it can calculate the length of a vector from its components, or recover one component length when the other lengths are known. The key condition is perpendicularity. Without it, the same sum-of-squares formula need not hold.

Definition: Vectors \(\mathbf{a}\) and \(\mathbf{b}\) are perpendicular, or orthogonal, when \(\mathbf{a}\cdot\mathbf{b}=0\). The length, or norm, of a vector \(\mathbf{v}\) is denoted by \(\|\mathbf{v}\|\).

The Pythagorean Identity for Vector Components

Suppose a vector \(\mathbf{v}\) is the sum of two perpendicular vectors, \(\mathbf{a}\) and \(\mathbf{b}\). Then \(\mathbf{a}\) and \(\mathbf{b}\) are its components, and their lengths combine as follows.

Theorem: If \(\mathbf{v}=\mathbf{a}+\mathbf{b}\) and \(\mathbf{a}\cdot\mathbf{b}=0\), then
$$ \|\mathbf{v}\|^2=\|\mathbf{a}\|^2+\|\mathbf{b}\|^2. $$

Because lengths are nonnegative, the equivalent identity for lengths is \(\|\mathbf{v}\|=\sqrt{\|\mathbf{a}\|^2+\|\mathbf{b}\|^2}\). The squares are essential: lengths themselves do not generally add.

Why the Identity Holds

The proof follows directly from the definition of the norm and the dot product. The squared norm of any vector \(\mathbf{x}\) is \(\mathbf{x}\cdot\mathbf{x}\), and the dot product is distributive over vector addition.

1
Write the squared norm as a dot product.
Since \(\mathbf{v}=\mathbf{a}+\mathbf{b}\), we have \(\|\mathbf{v}\|^2=(\mathbf{a}+\mathbf{b})\cdot(\mathbf{a}+\mathbf{b})\).
2
Expand using distributivity.
The result is \(\mathbf{a}\cdot\mathbf{a}+\mathbf{a}\cdot\mathbf{b}+\mathbf{b}\cdot\mathbf{a}+\mathbf{b}\cdot\mathbf{b}\).
3
Use perpendicularity.
Since \(\mathbf{a}\cdot\mathbf{b}=0\), and the dot product is symmetric, both mixed terms vanish.
4
Recognize the squared lengths.
The remaining terms are \(\mathbf{a}\cdot\mathbf{a}=\|\mathbf{a}\|^2\) and \(\mathbf{b}\cdot\mathbf{b}=\|\mathbf{b}\|^2\), proving the identity.
$$ \begin{aligned} \|\mathbf{v}\|^2 &=(\mathbf{a}+\mathbf{b})\cdot(\mathbf{a}+\mathbf{b})\\ &=\mathbf{a}\cdot\mathbf{a}+\mathbf{a}\cdot\mathbf{b} +\mathbf{b}\cdot\mathbf{a}+\mathbf{b}\cdot\mathbf{b}\\ &=\|\mathbf{a}\|^2+\|\mathbf{b}\|^2. \end{aligned} $$

If the components are not perpendicular, the expansion still applies, but the mixed terms generally remain. In that case, the sum of the squared component lengths alone does not give the squared length of their sum.

Parallel and Perpendicular Parts of a Vector

Let \(\mathbf{u}\) be a unit vector, so \(\|\mathbf{u}\|=1\). For any vector \(\mathbf{v}\), its scalar component in the direction \(\mathbf{u}\) is \(\mathbf{v}\cdot\mathbf{u}\). The vector component parallel to \(\mathbf{u}\) is \((\mathbf{v}\cdot\mathbf{u})\mathbf{u}\); subtracting it from \(\mathbf{v}\) gives the perpendicular component.

$$ \mathbf{p}=(\mathbf{v}\cdot\mathbf{u})\mathbf{u}, \qquad \mathbf{q}=\mathbf{v}-\mathbf{p}. $$

These components are indeed perpendicular: \(\mathbf{q}\cdot\mathbf{u}=\mathbf{v}\cdot\mathbf{u}-(\mathbf{v}\cdot\mathbf{u})(\mathbf{u}\cdot\mathbf{u})=0\), since \(\mathbf{u}\cdot\mathbf{u}=1\). Therefore \(\mathbf{p}\cdot\mathbf{q}=0\), and the Pythagorean identity gives

$$ \|\mathbf{v}\|^2 = (\mathbf{v}\cdot\mathbf{u})^2+\|\mathbf{q}\|^2. $$

The parallel component's length is \(|\mathbf{v}\cdot\mathbf{u}|\), not necessarily \(\mathbf{v}\cdot\mathbf{u}\): the latter is a signed scalar and may be negative. Squaring it gives the same nonnegative contribution to the identity.

Worked Example: Verify the Identity from Vector Components

Let \(\mathbf{v}=(2,1,2)\), and take \(\mathbf{u}=(1,0,0)\), a unit vector. Find the parallel and perpendicular components, then check the identity.

First, \(\|\mathbf{u}\|=\sqrt{1^2+0^2+0^2}=1\). The scalar component along \(\mathbf{u}\) is

$$\mathbf{v}\cdot\mathbf{u}=2(1)+1(0)+2(0)=2.$$

Thus the parallel vector component is \(\mathbf{p}=2(1,0,0)=(2,0,0)\), and the perpendicular component is

$$\mathbf{q}=\mathbf{v}-\mathbf{p}=(2,1,2)-(2,0,0)=(0,1,2).$$

Check perpendicularity: \(\mathbf{p}\cdot\mathbf{q}=2(0)+0(1)+0(2)=0\). The squared lengths are \(\|\mathbf{v}\|^2=2^2+1^2+2^2=9\), \(\|\mathbf{p}\|^2=2^2=4\), and \(\|\mathbf{q}\|^2=0^2+1^2+2^2=5\). Therefore \(9=4+5\), as required. In length form, \(\|\mathbf{v}\|=3\), while \(\sqrt{\|\mathbf{p}\|^2+\|\mathbf{q}\|^2}=\sqrt{4+5}=3\).

Recovering an Unknown Component Length

Rearrange the identity to isolate the unknown squared length. If the total length is \(L\) and one perpendicular component has length \(a\), then the other component has length \(b\) satisfying \(b^2=L^2-a^2\). Since a length cannot be negative, \(b=\sqrt{L^2-a^2}\).

Takeaway: For perpendicular components, an unknown length is the square root of the total squared length minus the known component's squared length. The given lengths must satisfy \(L\geq a\); otherwise, the data cannot describe such a decomposition.

Worked Example: Find the Perpendicular Component Length

A vector has length \(13\), and its scalar component along a unit direction is \(5\). Find the length of its perpendicular component.

For a unit direction, the parallel vector component has length \(|5|=5\). Let \(b\) be the perpendicular component's length. Apply the identity:

$$13^2=5^2+b^2.$$

Compute the squares: \(169=25+b^2\). Subtract \(25\) from both sides: \(b^2=144\). Since \(b\) is a length, take the nonnegative square root: \(b=\sqrt{144}=12\).

Check by substitution: \(5^2+12^2=25+144=169=13^2\), so the recovered length satisfies the identity.

The condition on the input lengths is important. If a proposed total length were \(4\) and a perpendicular component already had length \(5\), the calculation would require the other squared length to be \(4^2-5^2=16-25=-9\). No real length has square \(-9\), so those measurements cannot describe perpendicular components of a vector of length \(4\).

Worked Example: Recover a Signed Parallel Component

A vector has length \(10\), and its perpendicular component has length \(6\). Its scalar component along a chosen unit direction is known to be negative. Find that scalar component.

Let \(c\) be the signed scalar component. The identity gives \(10^2=c^2+6^2\). Substituting the squares gives \(100=c^2+36\), so \(c^2=64\). Thus \(c=8\) or \(c=-8\) based on the squared equation. The additional information that the scalar component is negative selects \(c=-8\).

Check with \(\mathbf{u}=(1,0,0)\), \(\mathbf{v}=(-8,6,0)\): its scalar component is \(\mathbf{v}\cdot\mathbf{u}=-8\), and its perpendicular component is \((0,6,0)\), of length \(6\). The vector length is \(\sqrt{(-8)^2+6^2}=\sqrt{64+36}=10\). This verifies both the identity and the negative sign.

What the Squared Identity Does—and Does Not—Tell You

When solving for a length, the nonnegative square root is the correct choice. When solving for a signed scalar component, the squared equation by itself may leave two possibilities. The sign must come from other information, such as whether the vector points with or against the chosen unit direction.

There is also a useful feasibility check. If \(L\) is the total length and \(a\) is the length of one component, then a perpendicular decomposition requires \(L^2-a^2\geq 0\). If this condition fails, the measurements are inconsistent. If it holds, the other component's length is the nonnegative square root of that difference.

Worked Example: Check and Recover a Component

A vector has length \(17\), and one of its perpendicular components has length \(8\). Find the other component length and verify that the data are consistent.

First check that \(17\geq 8\), so the known component is not longer than the total vector. If \(b\) is the other length, then \(17^2=8^2+b^2\). Compute: \(289=64+b^2\), hence \(b^2=225\). As \(b\) is a length, \(b=\sqrt{225}=15\).

Substitution verifies the result: \(8^2+15^2=64+225=289=17^2\). The nonnegative lengths \(8\), \(15\), and \(17\) therefore satisfy the required identity.

A Common Mistake: Adding Lengths Instead of Their Squares

A frequent error is to treat the perpendicular component lengths as if they added directly. For example, if a vector has length \(13\) and its parallel component has length \(5\), the incorrect calculation would be \(13=5+b\), giving \(b=8\). But checking that answer gives \(5^2+8^2=25+64=89\), not \(13^2=169\).

The correction is to apply the identity to squared lengths: \(13^2=5^2+b^2\), so \(b^2=169-25=144\), and \(b=12\). Checking gives \(5^2+12^2=25+144=169=13^2\). The mistake happened because perpendicular lengths form a right-triangle relationship: the squares, not the lengths, satisfy the sum.

Check Your Understanding

Use the perpendicular-component identity to answer each question. Keep scalar signs distinct from lengths.

  1. If \(\mathbf{a}\cdot\mathbf{b}=0\), \(\|\mathbf{a}\|=7\), and \(\|\mathbf{b}\|=24\), what is \(\|\mathbf{a}+\mathbf{b}\|\)?
  2. A vector has length \(25\) and a parallel component of length \(7\). What is the perpendicular component's length?
  3. A vector has length \(10\) and a perpendicular component of length \(8\). What are the possible signed scalar components along a unit direction?
  4. Can perpendicular components of lengths \(6\) and \(8\) sum to a vector of length \(9\)? Explain using the identity.
  5. Why does knowing the square of a signed scalar component not always determine its sign?