IB Maths AA HL Topic 3 β€” Geometry & Trigonometry Paper 1 & 2 ~7 min read HL only

Shortest Distance Between Two Lines

For two skew lines, the shortest distance lies along the common perpendicular β€” the unique direction perpendicular to both. The vector product b1 Γ— b2 gives that direction directly, so a clean one-step formula handles most exam questions.

πŸ“˜ What you need to know

The shortest-distance formula

Shortest distance between skew lines d  =  |(a2 βˆ’ a1) Β· (b1 Γ— b2)||b1 Γ— b2|

The vector b1 Γ— b2 is perpendicular to both lines β€” exactly the direction of the common perpendicular. Projecting the displacement a2 βˆ’ a1 onto this direction (and taking magnitude) gives the shortest distance.

Two methods

Vector product (faster)
d = |(a2 βˆ’ a1) Β· n||n|
where n = b1 Γ— b2
no parameters β€” three vector operations
Scalar product (also gives feet)
b1 Β· F1F2 = 0
b2 Β· F1F2 = 0
solve for Ξ», ΞΌ; gives feet F1, F2 too
When to use which: vector product if you only need the distance β€” it’s faster. Scalar product if you also need the feet of the perpendicular F1 and F2 on each line.

Special cases

Lines are…ApproachDistance
Skewvector product OR scalar product methodpositive value from formula
Parallel (not coincident)pick a point on one line, use point-to-line distancepositive constant gap
Intersectingβ€”0
Coincidentβ€”0

🧭 Recipe β€” shortest distance between two skew lines

  1. Compute b1 Γ— b2 β€” the common perpendicular direction. If it’s 0, the lines are parallel β€” switch method.
  2. Compute a2 βˆ’ a1 β€” the displacement between anchors.
  3. Take the dot product (a2 βˆ’ a1) Β· (b1 Γ— b2).
  4. Take absolute value and divide by |b1 Γ— b2|.
  5. Sanity check: if your answer is 0, the lines must intersect or be coincident β€” verify.

Worked examples

WE 1

Shortest distance between two skew lines

Find the shortest distance between the lines r1 = (1, 2, 3) + Ξ»(1, 1, 0) and r2 = (4, 1, 4) + ΞΌ(1, 0, 1).

Step 1: b₁ Γ— bβ‚‚ i: (1)(1) βˆ’ (0)(0) = 1 j: βˆ’[(1)(1) βˆ’ (0)(1)] = βˆ’1 k: (1)(0) βˆ’ (1)(1) = βˆ’1 b₁ Γ— bβ‚‚ = (1, βˆ’1, βˆ’1);   |b₁ Γ— bβ‚‚| = √3 Step 2: aβ‚‚ βˆ’ a₁ and dot product aβ‚‚ βˆ’ a₁ = (3, βˆ’1, 1) (aβ‚‚βˆ’a₁)Β·(b₁×bβ‚‚) = (3)(1) + (βˆ’1)(βˆ’1) + (1)(βˆ’1) = 3 Distance = |3|/√3 = √3 positive value β†’ lines are skew, not intersecting
WE 2

Shortest distance with integer answer

Find the shortest distance between the lines r1 = (3, 1, 2) + Ξ»(1, 0, βˆ’1) and r2 = (5, 1, 3) + ΞΌ(1, βˆ’2, 0).

Step 1: b₁ Γ— bβ‚‚ i: (0)(0) βˆ’ (βˆ’1)(βˆ’2) = βˆ’2 j: βˆ’[(1)(0) βˆ’ (βˆ’1)(1)] = βˆ’1 k: (1)(βˆ’2) βˆ’ (0)(1) = βˆ’2 b₁ Γ— bβ‚‚ = (βˆ’2, βˆ’1, βˆ’2);   |…| = √(4+1+4) = 3 Step 2: aβ‚‚ βˆ’ a₁ = (2, 0, 1) (aβ‚‚βˆ’a₁)Β·(b₁×bβ‚‚) = (2)(βˆ’2) + (0)(βˆ’1) + (1)(βˆ’2) = βˆ’6 Distance = 6/3 = 2 always take the absolute value of the dot product before dividing
WE 3

Shortest distance using the scalar product method

Find the shortest distance between the lines r1 = (1, 2, 3) + Ξ»(1, βˆ’1, 0) and r2 = (3, 4, 5) + ΞΌ(0, 1, βˆ’1) using the scalar product method.

Step 1: General points and F₁Fβ‚‚ F₁ = (1+Ξ», 2βˆ’Ξ», 3);   Fβ‚‚ = (3, 4+ΞΌ, 5βˆ’ΞΌ) F₁Fβ‚‚ = (2βˆ’Ξ», 2+ΞΌ+Ξ», 2βˆ’ΞΌ) Step 2: Two perpendicularity equations b₁·F₁Fβ‚‚ = (2βˆ’Ξ») βˆ’ (2+ΞΌ+Ξ») = βˆ’2Ξ» βˆ’ ΞΌ = 0 … (i) bβ‚‚Β·F₁Fβ‚‚ = (2+ΞΌ+Ξ») βˆ’ (2βˆ’ΞΌ) = Ξ» + 2ΞΌ = 0 … (ii) Step 3: Solve From (i): ΞΌ = βˆ’2Ξ»; sub (ii): Ξ» βˆ’ 4Ξ» = 0 β†’ Ξ» = 0, ΞΌ = 0 Step 4: Substitute, find magnitude F₁Fβ‚‚ = (2, 2, 2);   |F₁Fβ‚‚| = √12 = 2√3 Distance = 2√3 two equations, two unknowns β€” solve simultaneously
WE 4

Show two lines are skew, then find their shortest distance

(a) Show that the lines r1 = (1, 1, 0) + Ξ»(1, 0, 1) and r2 = (2, 3, 1) + ΞΌ(0, 1, 1) are skew. (b) Find the shortest distance between them.

Part (a): Show skew x: 1 + Ξ» = 2 β†’ Ξ» = 1 y: 1 = 3 + ΞΌ β†’ ΞΌ = βˆ’2 z: Ξ» = 1 + ΞΌ β†’ 1 = 1 + (βˆ’2) = βˆ’1 βœ— Inconsistent β†’ skew (and directions aren’t parallel) Part (b): Vector product method b₁ Γ— bβ‚‚ = (βˆ’1, βˆ’1, 1);   |…| = √3 aβ‚‚ βˆ’ a₁ = (1, 2, 1) (aβ‚‚βˆ’a₁)Β·(b₁×bβ‚‚) = βˆ’1 βˆ’ 2 + 1 = βˆ’2 Distance = 2/√3 = 2√3/3 always rationalise the denominator unless the question says otherwise
WE 5

Distance between two parallel lines

Show that the lines r1 = (3, 2, 1) + Ξ»(1, 2, 2) and r2 = (5, 1, 1) + ΞΌ(2, 4, 4) are parallel, and find the shortest distance between them.

Step 1: Parallel check bβ‚‚ = (2, 4, 4) = 2(1, 2, 2) = 2b₁ βœ“ β†’ parallel Step 2: Pick point P = (5, 1, 1) on lβ‚‚; find distance from P to l₁ A = (3, 2, 1);   AP = P βˆ’ A = (2, βˆ’1, 0) Step 3: AP Γ— b₁ (using b₁ for direction of l₁) i: (βˆ’1)(2) βˆ’ (0)(2) = βˆ’2 j: βˆ’[(2)(2) βˆ’ (0)(1)] = βˆ’4 k: (2)(2) βˆ’ (βˆ’1)(1) = 5 AP Γ— b₁ = (βˆ’2, βˆ’4, 5);   |…| = √(4+16+25) = √45 = 3√5 Step 4: Apply point-to-line formula |b₁| = 3;   distance = 3√5/3 Distance = √5 for parallel lines, the b₁ Γ— bβ‚‚ formula fails (cross product is 0) β€” switch to point-to-line
WE 6

Application β€” minimum separation between flight paths

Two aircraft fly in straight lines. Aircraft A’s path is given by r = (4, 2, βˆ’1) + t(2, 1, βˆ’2) and aircraft B’s path by r = (6, 2, 1) + s(1, 2, 2), where coordinates are in km. Find the minimum distance between the two flight paths.

Step 1: Cross product of directions b₁ Γ— bβ‚‚: i: (1)(2)βˆ’(βˆ’2)(2) = 6              j: βˆ’[(2)(2)βˆ’(βˆ’2)(1)] = βˆ’6              k: (2)(2)βˆ’(1)(1) = 3 b₁ Γ— bβ‚‚ = (6, βˆ’6, 3);   |…| = √81 = 9 Step 2: aβ‚‚ βˆ’ a₁ = (2, 0, 2) (aβ‚‚βˆ’a₁)Β·(b₁×bβ‚‚) = 12 + 0 + 6 = 18 Minimum distance = 18/9 = 2 km paths treated as full lines β€” minimum separation along their geometric paths, regardless of timing

πŸ’‘ Top tips

⚠ Common mistakes

That closes Vector Equations of Lines. Up next: Vector Planes. A plane in 3D needs three pieces of information β€” a point, plus two non-parallel direction vectors (or equivalently, a normal vector). The same scalar/vector product toolkit you’ve built here transfers across, with a few new equations: vector form, parametric form, Cartesian form, and the all-important normal form n Β· (r βˆ’ a) = 0.

Need help with Vector Equations of Lines?

Get 1-on-1 help from an IB examiner who knows exactly what Paper 1 & 2 are looking for.

Book Free Session β†’