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
- Skew-line formula: d = |(a2 − a1) · (b1 × b2)||b1 × b2| (not in formula booklet — memorise).
- Geometric meaning: project the displacement a2 − a1 onto the common perpendicular direction b1 × b2.
- Scalar product method (alternative): find feet F1, F2 with b1 · F1F2 = 0 AND b2 · F1F2 = 0; then |F1F2|.
- Parallel lines (b1 × b2 = 0): pick any point on one line, find the point-to-line distance to the other.
- Intersecting lines: distance = 0 (they meet).
- Coincident lines: distance = 0 (they’re the same line).
- Use different parameters (λ, μ) for the two lines.
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… | Approach | Distance |
|---|
| Skew | vector product OR scalar product method | positive value from formula |
| Parallel (not coincident) | pick a point on one line, use point-to-line distance | positive constant gap |
| Intersecting | — | 0 |
| Coincident | — | 0 |
🧭 Recipe — shortest distance between two skew lines
- Compute b1 × b2 — the common perpendicular direction. If it’s 0, the lines are parallel — switch method.
- Compute a2 − a1 — the displacement between anchors.
- Take the dot product (a2 − a1) · (b1 × b2).
- Take absolute value and divide by |b1 × b2|.
- Sanity check: if your answer is 0, the lines must intersect or be coincident — verify.
Worked examples
WE 1Shortest 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 2Shortest 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 3Shortest 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 4Show 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 5Distance 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 6Application — 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
- Check parallel first: if b1 × b2 = 0, switch to the point-to-line method.
- Take absolute value of the dot product — distance is always non-negative.
- Always rationalise a single √ in the denominator (e.g., 2/√3 → 2√3/3) unless told otherwise.
- If the answer is 0, lines intersect or are coincident — go back and check the classification.
- For parallel lines, any point on one will give the same distance to the other — pick the simplest.
⚠ Common mistakes
- Forgetting absolute value in the numerator — distance must be non-negative.
- Sign errors in the j-component of the cross product (the determinant flips sign).
- Using the formula on parallel lines — the cross product is zero, formula breaks. Switch to point-to-line.
- Confusing “shortest distance between paths” with “closest approach in time” for moving objects — the latter requires same time on both paths.
- Computing |a2 − a1| as the answer — that’s the gap between anchors, not the perpendicular distance.
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 →