Cambridge International AS & A Level · Topic 1.6
A-Level Further Maths 9231 / Topic 1.6 / AS & A Level

Two lines that never meet, and the one segment that joins them best.

In three dimensions two lines can miss each other without being parallel. Between such skew lines there is exactly one shortest segment, and it is perpendicular to both lines. The vector product gives its direction, a scalar product gives its length, and two simultaneous equations give its end points.

The key idea

Lines \(\mathbf{r} = \mathbf{a}_{1} + \lambda\mathbf{b}_{1}\) and \(\mathbf{r} = \mathbf{a}_{2} + \mu\mathbf{b}_{2}\) are skew when they are not parallel and do not meet. The vector \(\mathbf{n} = \mathbf{b}_{1} \times \mathbf{b}_{2}\) is perpendicular to both, and the shortest distance between them is \(d = \dfrac{|(\mathbf{a}_{2} - \mathbf{a}_{1}) \cdot \mathbf{n}|}{|\mathbf{n}|}\). To find where the shortest segment touches the lines, take general points \(P\) on the first and \(Q\) on the second and solve \(\overrightarrow{PQ} \cdot \mathbf{b}_{1} = 0\), \(\overrightarrow{PQ} \cdot \mathbf{b}_{2} = 0\); the common perpendicular is the line through \(P\) and \(Q\). A distance of zero means the lines intersect.

P Q b₁ b₂ l₁: r = a₁ + λb₁ l₂: r = a₂ + μb₂ shortest distance |PQ| PQ ∥ n = b₁ × b₂
Fig. 1: skew lines l₁ and l₂ lie in two parallel planes. The common perpendicular PQ meets both lines at right angles and is parallel to n = b₁ × b₂; its length |PQ| is the shortest distance between the lines
Section 01

Not parallel, and never meet.

In a plane, two lines either are parallel or cross. In three dimensions there is a third possibility: lines that are not parallel but still never meet, like a road on a bridge and a railway running underneath it in a different direction. Such lines are called skew. To show that two lines are skew you must check two things, and both are needed.

Worked example Showing two lines are skew
Show that the lines \(l_{1}\) and \(l_{2}\) are skew. \[l_{1}: \mathbf{r} = \begin{pmatrix}0\\-1\\1\end{pmatrix} + \lambda\begin{pmatrix}1\\2\\0\end{pmatrix}, \qquad l_{2}: \mathbf{r} = \begin{pmatrix}1\\0\\5\end{pmatrix} + \mu\begin{pmatrix}1\\0\\-1\end{pmatrix}\]
  1. Directions: \(\begin{pmatrix}1\\2\\0\end{pmatrix}\) is not a multiple of \(\begin{pmatrix}1\\0\\-1\end{pmatrix}\) (the second has \(y\)-component 0, the first does not), so the lines are not parallel.
  2. Equate components: \(x\): \(\lambda = 1 + \mu\); \(y\): \(-1 + 2\lambda = 0\); \(z\): \(1 = 5 - \mu\).
  3. From \(y\): \(\lambda = \tfrac{1}{2}\); then \(x\) gives \(\mu = -\tfrac{1}{2}\).
  4. Check \(z\): \(l_{1}\) gives \(1\), \(l_{2}\) gives \(5 - (-\tfrac{1}{2}) = 5.5\). These differ, so there is no common point.
Answer: Not parallel and no point in common, so the lines are skew.
Worked example Distance from a point to a line
Find the shortest distance from \(A(5, -1, 1)\) to the line \(\mathbf{r} = \begin{pmatrix}1\\0\\2\end{pmatrix} + t\begin{pmatrix}2\\1\\-2\end{pmatrix}\).
  1. General point \(F = (1 + 2t,\; t,\; 2 - 2t)\), so \(\overrightarrow{AF} = \begin{pmatrix}2t - 4\\t + 1\\1 - 2t\end{pmatrix}\).
  2. Perpendicular: \(2(2t - 4) + (t + 1) - 2(1 - 2t) = 9t - 9 = 0\), so \(t = 1\) and \(F = (3, 1, 0)\).
  3. \(\overrightarrow{AF} = \begin{pmatrix}-2\\2\\-1\end{pmatrix}\), so \(|AF| = \sqrt{4 + 4 + 1} = 3\).
  4. Check with the cross product: \(\begin{pmatrix}4\\-1\\-1\end{pmatrix} \times \begin{pmatrix}2\\1\\-2\end{pmatrix} = \begin{pmatrix}3\\6\\6\end{pmatrix}\), of length 9, and \(9 \div 3 = 3\).
Answer: \(3\), with foot of the perpendicular \(F(3, 1, 0)\)
Your turn
Decide whether the lines \(\mathbf{r} = \begin{pmatrix}1\\1\\0\end{pmatrix} + \lambda\begin{pmatrix}1\\-1\\2\end{pmatrix}\) and \(\mathbf{r} = \begin{pmatrix}0\\-4\\4\end{pmatrix} + \mu\begin{pmatrix}1\\2\\-1\end{pmatrix}\) are parallel, intersecting or skew.
Examiner trap

Two easy ways to lose the mark. Showing only that the directions are not parallel proves nothing about skewness: non-parallel lines can still intersect. And two of the three component equations can always be solved; the test is whether the values of \(\lambda\) and \(\mu\) also satisfy the third. Say clearly which equation fails.

Section 02

One vector perpendicular to both: the vector product.

The shortest segment between two skew lines must be perpendicular to both of them (Fig. 1); if it were not, sliding one end along its line would shorten it. You met in the last two lessons that \(\mathbf{b}_{1} \times \mathbf{b}_{2}\) is perpendicular to both \(\mathbf{b}_{1}\) and \(\mathbf{b}_{2}\), so it gives the direction of that segment.

Take any point \(A_{1}\) on the first line and any point \(A_{2}\) on the second. The vector \(\mathbf{a}_{2} - \mathbf{a}_{1}\) joins the lines, but usually not by the shortest route. Its component along \(\mathbf{n}\) is the same for every joining vector, because moving along either line changes it by a multiple of \(\mathbf{b}_{1}\) or \(\mathbf{b}_{2}\), and both have zero scalar product with \(\mathbf{n}\). That component is the shortest distance:

\[\mathbf{n} = \mathbf{b}_{1} \times \mathbf{b}_{2}, \qquad d = \frac{|(\mathbf{a}_{2} - \mathbf{a}_{1}) \cdot \mathbf{n}|}{|\mathbf{n}|}.\]
Worked example Shortest distance by formula
Find the shortest distance between the skew lines \(l_{1}\) and \(l_{2}\) of the first example: \[l_{1}: \mathbf{r} = \begin{pmatrix}0\\-1\\1\end{pmatrix} + \lambda\begin{pmatrix}1\\2\\0\end{pmatrix}, \qquad l_{2}: \mathbf{r} = \begin{pmatrix}1\\0\\5\end{pmatrix} + \mu\begin{pmatrix}1\\0\\-1\end{pmatrix}\]
  1. \(\mathbf{n} = \begin{pmatrix}1\\2\\0\end{pmatrix} \times \begin{pmatrix}1\\0\\-1\end{pmatrix} = \begin{pmatrix}2(-1) - 0(0)\\0(1) - 1(-1)\\1(0) - 2(1)\end{pmatrix} = \begin{pmatrix}-2\\1\\-2\end{pmatrix}\), and \(|\mathbf{n}| = 3\).
  2. \(\mathbf{a}_{2} - \mathbf{a}_{1} = \begin{pmatrix}1\\1\\4\end{pmatrix}\), so \((\mathbf{a}_{2} - \mathbf{a}_{1}) \cdot \mathbf{n} = -2 + 1 - 8 = -9\).
  3. \(d = \dfrac{|-9|}{3} = 3\).
Answer: \(3\)
Worked example Zero distance: the lines meet
The lines \(\mathbf{r} = \begin{pmatrix}2\\1\\0\end{pmatrix} + \lambda\begin{pmatrix}1\\-1\\1\end{pmatrix}\) and \(\mathbf{r} = \begin{pmatrix}0\\k\\2\end{pmatrix} + \mu\begin{pmatrix}2\\1\\0\end{pmatrix}\) intersect. Find \(k\) and the point of intersection.
  1. \(\mathbf{n} = \begin{pmatrix}1\\-1\\1\end{pmatrix} \times \begin{pmatrix}2\\1\\0\end{pmatrix} = \begin{pmatrix}-1\\2\\3\end{pmatrix}\), and \(\mathbf{a}_{2} - \mathbf{a}_{1} = \begin{pmatrix}-2\\k - 1\\2\end{pmatrix}\).
  2. \((\mathbf{a}_{2} - \mathbf{a}_{1}) \cdot \mathbf{n} = 2 + 2(k - 1) + 6 = 2k + 6\), so the distance is \(\dfrac{|2k + 6|}{\sqrt{14}}\).
  3. The lines are not parallel, so they meet exactly when \(2k + 6 = 0\): \(k = -3\).
  4. Point: \(z\) gives \(\lambda = 2\), so \((4, -1, 2)\). Check on the second line with \(\mu = 2\): \((4, -3 + 2, 2) = (4, -1, 2)\).
Answer: \(k = -3\); the lines meet at \((4, -1, 2)\)
Your turn
Find the shortest distance between \(\mathbf{r} = \begin{pmatrix}1\\0\\1\end{pmatrix} + \lambda\begin{pmatrix}2\\1\\0\end{pmatrix}\) and \(\mathbf{r} = \begin{pmatrix}0\\2\\0\end{pmatrix} + \mu\begin{pmatrix}0\\1\\1\end{pmatrix}\).
Examiner trap

Divide by \(|\mathbf{n}|\), not by \(|\mathbf{a}_{2} - \mathbf{a}_{1}|\) and not by \(|\mathbf{n}|^{2}\). And check the vector product component by component: a sign slip in the middle component (it is \(b_{3}c_{1} - b_{1}c_{3}\)) gives a vector that is not perpendicular to both lines, and the distance comes out wrong. A quick test: \(\mathbf{n} \cdot \mathbf{b}_{1}\) and \(\mathbf{n} \cdot \mathbf{b}_{2}\) must both be zero.

Stage 1 · Learn

Check your understanding

Four quick checks. Each correct answer earns XP and records this skill on your profile.

Quick check+10 XP

Two lines in three dimensions are skew when they

Quick check+10 XP

For the lines \(\mathbf{r} = \mathbf{a}_{1} + \lambda\mathbf{b}_{1}\) and \(\mathbf{r} = \mathbf{a}_{2} + \mu\mathbf{b}_{2}\), which vector is parallel to their common perpendicular?

Quick check+10 XP

For two skew lines, \(\mathbf{a}_{2} - \mathbf{a}_{1} = \begin{pmatrix}1\\2\\3\end{pmatrix}\) and \(\mathbf{n} = \mathbf{b}_{1} \times \mathbf{b}_{2} = \begin{pmatrix}2\\-1\\2\end{pmatrix}\). The shortest distance between the lines is

Quick check+10 XP

Two lines are not parallel, and \(\dfrac{|(\mathbf{a}_{2} - \mathbf{a}_{1}) \cdot \mathbf{n}|}{|\mathbf{n}|} = 0\). What can you conclude?

Section 03

Find the end points: the common perpendicular.

The formula gives the length of the shortest segment but not where it is. To find its end points \(P\) and \(Q\), and so the equation of the common perpendicular, work with general points on the two lines.

Worked example End points and the common perpendicular
For the skew lines \(l_{1}: \mathbf{r} = \begin{pmatrix}0\\-1\\1\end{pmatrix} + \lambda\begin{pmatrix}1\\2\\0\end{pmatrix}\) and \(l_{2}: \mathbf{r} = \begin{pmatrix}1\\0\\5\end{pmatrix} + \mu\begin{pmatrix}1\\0\\-1\end{pmatrix}\), find the points \(P\) on \(l_{1}\) and \(Q\) on \(l_{2}\) for which \(PQ\) is perpendicular to both lines, and an equation of the common perpendicular.
  1. \(P = (\lambda,\; -1 + 2\lambda,\; 1)\) and \(Q = (1 + \mu,\; 0,\; 5 - \mu)\), so \(\overrightarrow{PQ} = \begin{pmatrix}1 + \mu - \lambda\\1 - 2\lambda\\4 - \mu\end{pmatrix}\).
  2. \(\overrightarrow{PQ} \cdot \mathbf{b}_{1} = (1 + \mu - \lambda) + 2(1 - 2\lambda) = 3 + \mu - 5\lambda = 0\).
  3. \(\overrightarrow{PQ} \cdot \mathbf{b}_{2} = (1 + \mu - \lambda) - (4 - \mu) = 2\mu - \lambda - 3 = 0\), so \(\lambda = 2\mu - 3\).
  4. Substitute: \(3 + \mu - 10\mu + 15 = 0\), so \(\mu = 2\) and \(\lambda = 1\).
  5. \(P = (1, 1, 1)\), \(Q = (3, 0, 3)\), \(\overrightarrow{PQ} = \begin{pmatrix}2\\-1\\2\end{pmatrix}\) and \(|PQ| = 3\), the distance found by the formula. \(\overrightarrow{PQ}\) is a multiple of \(\mathbf{n} = \begin{pmatrix}-2\\1\\-2\end{pmatrix}\), as it must be.
Answer: \(P(1, 1, 1)\), \(Q(3, 0, 3)\); common perpendicular \(\mathbf{r} = \begin{pmatrix}1\\1\\1\end{pmatrix} + t\begin{pmatrix}2\\-1\\2\end{pmatrix}\)
Worked example Contrast: parallel lines
Show that the lines \(\mathbf{r} = \begin{pmatrix}1\\2\\0\end{pmatrix} + \lambda\begin{pmatrix}1\\2\\2\end{pmatrix}\) and \(\mathbf{r} = \begin{pmatrix}4\\5\\0\end{pmatrix} + \mu\begin{pmatrix}-2\\-4\\-4\end{pmatrix}\) are parallel, and find the distance between them.
  1. \(\begin{pmatrix}-2\\-4\\-4\end{pmatrix} = -2\begin{pmatrix}1\\2\\2\end{pmatrix}\), so the lines are parallel; take \(\mathbf{b} = \begin{pmatrix}1\\2\\2\end{pmatrix}\), \(|\mathbf{b}| = 3\). They are different lines, since \(\mathbf{a}_{2} - \mathbf{a}_{1} = \begin{pmatrix}3\\3\\0\end{pmatrix}\) is not a multiple of \(\mathbf{b}\).
  2. \((\mathbf{a}_{2} - \mathbf{a}_{1}) \times \mathbf{b} = \begin{pmatrix}3(2) - 0(2)\\0(1) - 3(2)\\3(2) - 3(1)\end{pmatrix} = \begin{pmatrix}6\\-6\\3\end{pmatrix}\), of length \(\sqrt{36 + 36 + 9} = 9\).
  3. \(d = \dfrac{9}{3} = 3\).
Answer: Parallel, at distance \(3\) apart
Your turn
Find the end points \(P\) and \(Q\) of the common perpendicular to \(\mathbf{r} = \begin{pmatrix}0\\0\\-2\end{pmatrix} + \lambda\begin{pmatrix}1\\0\\2\end{pmatrix}\) and \(\mathbf{r} = \begin{pmatrix}4\\1\\-1\end{pmatrix} + \mu\begin{pmatrix}1\\-1\\0\end{pmatrix}\), and the shortest distance.
Examiner trap

The common perpendicular passes through \(P\) and \(Q\), not through \(\mathbf{a}_{1}\) or \(\mathbf{a}_{2}\): writing \(\mathbf{r} = \mathbf{a}_{1} + t\mathbf{n}\) gives a line perpendicular to both directions that usually misses the second line altogether. Also, the two conditions are \(\overrightarrow{PQ} \cdot \mathbf{b}_{1} = 0\) and \(\overrightarrow{PQ} \cdot \mathbf{b}_{2} = 0\), with the direction vectors, never with the position vectors.

Stage 2 · Exam

Exam-style questions

Unlocks once the four checks above are done. Worth more XP, written to AS & A Level Further Mathematics Paper 1 to 4 standard.

Finish the four checks above to unlock the exam questions
Exam style+20 XP

Find the shortest distance between the lines \(\mathbf{r} = \begin{pmatrix}1\\0\\0\end{pmatrix} + \lambda\begin{pmatrix}1\\1\\0\end{pmatrix}\) and \(\mathbf{r} = \begin{pmatrix}0\\0\\3\end{pmatrix} + \mu\begin{pmatrix}0\\1\\1\end{pmatrix}\).

Exam style+20 XP

The lines \(l_{1}: \mathbf{r} = \begin{pmatrix}0\\2\\1\end{pmatrix} + \lambda\begin{pmatrix}1\\-1\\0\end{pmatrix}\) and \(l_{2}: \mathbf{r} = \begin{pmatrix}4\\3\\2\end{pmatrix} + \mu\begin{pmatrix}0\\1\\-1\end{pmatrix}\) are skew. The common perpendicular meets \(l_{1}\) at \(P\). Find \(P\).

Exam style+20 XP

Find the distance between the parallel lines \(\mathbf{r} = \begin{pmatrix}2\\0\\1\end{pmatrix} + \lambda\begin{pmatrix}2\\-1\\2\end{pmatrix}\) and \(\mathbf{r} = \begin{pmatrix}2\\3\\-2\end{pmatrix} + \mu\begin{pmatrix}-4\\2\\-4\end{pmatrix}\).

Exam style+20 XP

The lines \(\mathbf{r} = \begin{pmatrix}0\\1\\2\end{pmatrix} + \lambda\begin{pmatrix}1\\2\\1\end{pmatrix}\) and \(\mathbf{r} = \begin{pmatrix}3\\k\\1\end{pmatrix} + \mu\begin{pmatrix}1\\0\\-1\end{pmatrix}\) intersect. Find \(k\).

Skill unlocked

Skew lines measured, and the vectors section complete.

This skill is now recorded on your profile. Keep the chain going.

-Rank -Level -Score -Topics
Go deeper · practice
Six original Cambridge-style questions
A skewness check, a distance by formula, parallel lines through a foot of perpendicular, a full common perpendicular, a constant that makes two lines meet, and a proof that the perpendicular segment really is the shortest.