Linear Algebra, Interactive EditionXYZ Homework Edition

⇩ Download ▾

6.2 A Line and Its Complement

The projection of the last section split a vector into two perpendicular pieces: one in the plane, one along the normal line. That pairing — plane and normal line — is no accident of the example. Every subspace VV has an orthogonal complement VV^\perp: the set of all vectors perpendicular to every vector of VV. The complement is itself a subspace (perpendicularity survives adding and scaling), and the two mesh so tightly that each determines the other completely.

The figure makes the pairing mechanical. The red line consists of all multiples of the direction vector (a,b,1)(a, b, 1), with aa and bb on sliders. Which vectors (x,y,z)(x, y, z) are perpendicular to it? Exactly those with (x,y,z)·(a,b,1)=0(x, y, z) \cdot (a, b, 1) = 0, that is, ax+by+z=0ax + by + z = 0 — the equation of a plane through the origin, drawn in the scene as the surface z=axbyz = -ax - by. The scene never computes an angle; the plane is perpendicular to the line by construction, because its equation is the perpendicularity condition itself.

A solid red line through the origin piercing a semi-transparent plane, meeting it at a perfect right angle. Two sliders a and b tilt the line's direction; the plane automatically re-tilts to stay exactly perpendicular to the line, so the pair always looks like a pole through a sheet.Explore in 3D (opens in a new tab)
The red line of all multiples of (a,b,1)(a, b, 1) and its orthogonal complement, the plane z=axbyz = -ax - by, whose normal is the line's own direction. The sliders aa and bb tilt the line; the plane re-tilts in lockstep to stay exactly perpendicular.

Explore the figure

  1. At the defaults a=0.6a = 0.6, b=0.4b = -0.4, orbit until the plane is edge-on. Line and plane meet like a pole through a sheet — the right angle holds from every viewing direction that shows the plane as a line.
  2. Drag aa slowly across its range. The line swings one way; the plane counter-tilts instantly. No slider position breaks the perpendicularity, because the plane's formula is the perpendicularity condition.
  3. Set a=0a = 0 and b=0b = 0. The line becomes the zz-axis and the complement flattens into the xyxy-plane — the most familiar line–plane pair in the book, revealed as an orthogonal complement pair.
  4. Count dimensions as you drag: one for the line, two for the plane, three in total, at every slider position. The complement absorbs every direction the line does not use.

Every vector splits, uniquely

The complement pairing is what makes projection bookkeeping exact. Given any vector 𝐰\mathbf{w} and the line direction 𝐝=(a,b,1)\mathbf{d} = (a, b, 1), the piece of 𝐰\mathbf{w} along the line is ((𝐰·𝐝)/(𝐝·𝐝))𝐝\big((\mathbf{w} \cdot \mathbf{d})/(\mathbf{d} \cdot \mathbf{d})\big)\mathbf{d} — the projection onto the line — and what remains is perpendicular to 𝐝\mathbf{d}, hence in the plane. So 𝐰\mathbf{w} = line part + plane part, always. Uniqueness comes from the only vector the two subspaces share: a vector in both is perpendicular to itself, so 𝐰·𝐰=0\mathbf{w} \cdot \mathbf{w} = 0 forces it to be the zero vector. Two decompositions would differ by a shared nonzero vector, and there is none to differ by.

[2310],[5301]\begin{bmatrix}\frac{2}{3} \\ 1 \\ 0\end{bmatrix},\; \begin{bmatrix}-\frac{5}{3} \\ 0 \\ 1\end{bmatrix}
The complement, computed as a null space ✓ Computed · mojocas 0.1.0 ✓ Agrees with the text The complement, computed as a null space, computed exactly by mojocas 0.1.0, and confirmed to agree with the result stated in the text.

The section defines VV^\perp by a condition — every vector perpendicular to the line — and then asserts the condition describes a plane. That assertion is a null space, and here it is computed: the vectors killed by the single row (0.6,0.4,1)(0.6, -0.4, 1) at the default sliders. Two basis vectors come back, so the complement is two-dimensional. It is a plane because the computation says the solution set has two independent directions, not because the picture looks flat.

The engine's basis is (2/3,1,0)(2/3, 1, 0) and (5/3,0,1)(-5/3, 0, 1); the card states (1,0,0.6)(1, 0, -0.6) and (0,1,0.4)(0, 1, 0.4), read straight off z=0.6x+0.4yz = -0.6x + 0.4y. Four different-looking vectors, one plane — a subspace determines no basis, so the check is made by span. It is not a lenient check: drop either vector and it refuses, because the surviving span is then a line rather than the plane.

11
One direction used, two left over ✓ Computed · mojocas 0.1.0 ✓ Agrees with the text One direction used, two left over, computed exactly by mojocas 0.1.0, and confirmed to agree with the result stated in the text.

Explore step 4 asks you to count dimensions while dragging: one for the line, two for the plane, three in total, at every slider position. This is the first of those numbers. Together with the two basis vectors above it is 1+2=31 + 2 = 3 — the rank–nullity theorem, arriving three chapters early as an observation about a picture you can tilt.

[0]\begin{bmatrix}0\end{bmatrix}
The complement piece really is perpendicular ✓ Computed · mojocas 0.1.0 ✓ Agrees with the text The complement piece really is perpendicular, computed exactly by mojocas 0.1.0, and confirmed to agree with the result stated in the text.

The example's second check, done by machine: the leftover piece (0.6,0.4,0.52)(-0.6, 0.4, 0.52) dotted against the line's direction (0.6,0.4,1)(0.6, -0.4, 1). The answer is 00, confirming that in this example what the projection left behind really does lie in the complement. That is the existence half of the split. Uniqueness is a separate argument and rests on VV={0}V \cap V^{\perp} = \{\mathbf{0}\}, which no single dot product can establish.

The engine reaches it by exact rational arithmetic: 0.6-0.6 is carried as 3/5-3/5, not as the nearest binary double, so the three products cancel as fractions and the result is the integer 00 rather than a number that rounds to it. Nothing here hinges on the decimals in this particular example being well behaved.

An original work of XYZ Homework, built around interactive XYZ 3D figures. Its chapter sequence is aligned to Interactive Linear Algebra (Margalit & Rabinoff, Georgia Tech, GNU FDL); this work is original, copies nothing from it, and is not affiliated with or endorsed by its authors. License: CC-BY-NC-SA-4.0.

These eBooks are a prerelease and are not yet certified conformant with WCAG 2.1 AA or ADA Title II. Every page is built against an automated accessibility gate, and the published editions will meet ADA Title II requirements when they release in late September 2026. If something is unusable, please tell us.