- Practice
- About 17 min
- 5 practice questions
Foot of the perpendicular and distance from a point to a line
Find the foot of the perpendicular from a point to a line, the perpendicular distance and the image of the point, using the general-point method and the projection shortcut for the distance.
If something looks wrong, please tell us.
Given a point and a line, three things are asked again and again: the foot of the perpendicular from the point, the perpendicular distance, and the image (reflection) of the point in the line. One method gives all three, and a quicker formula gives the distance alone. Both rest on the general point of a line from the foundation course.
The general-point method
Let the line pass through A with direction b, and let P be the given point. Every point of the line is Q = A + λb. The foot of the perpendicular is the one point Q for which PQ is perpendicular to the line, that is PQ · b = 0. This is a linear equation in λ. Once λ is known, the foot is Q, the distance is |PQ|, and the image of P is P′ = 2Q − P, because Q is the midpoint of PP′.
Foot: Q = A + λb with PQ · b = 0, which gives λ = (AP · b)/|b|². Distance: |PQ|, or directly √(|AP|² − (AP · b)²/|b|²), or |AP × b|/|b|. Image: 2Q − P.
Worked example 1: foot, distance and image
Find the foot of the perpendicular from P(5, 4, −1) to the line (x − 1)/2 = y/1 = (z − 2)/(−2), the distance and the image. The general point is Q(1 + 2λ, λ, 2 − 2λ), so PQ = (2λ − 4, λ − 4, 3 − 2λ). Setting PQ · (2, 1, −2) = 0: 2(2λ − 4) + (λ − 4) − 2(3 − 2λ) = 9λ − 18 = 0, so λ = 2. The foot is Q(5, 2, −2). Then PQ = (0, −2, −1), so the distance is √5, and the image is 2Q − P = (10 − 5, 4 − 4, −4 + 1) = (5, 0, −3).
The quick distance formulas
When only the distance is asked, skip the foot. In worked example 1, A(1, 0, 2) is on the line and AP = (4, 4, −3). Projection route: |AP|² = 16 + 16 + 9 = 41 and AP · b = 8 + 4 + 6 = 18, so the projection of AP on the line has length 18/3 = 6 and d² = 41 − 36 = 5. Cross-product route: AP × b = (4·(−2) − (−3)·1, (−3)·2 − 4·(−2), 4·1 − 4·2) = (−5, 2, −4), of length √45 = 3√5, and d = 3√5/3 = √5. Both agree with the general-point method. The projection route needs no cross product and is usually faster.
Worked example 2: a vector-form line and an image
Find the image of P(4, 1, 3) in the line r = (2î + k̂) + λ(î − ĵ + k̂). With A(2, 0, 1): AP = (2, 1, 2), AP · b = 2 − 1 + 2 = 3 and |b|² = 3, so λ = 1. The foot is Q = (3, −1, 2). Check: PQ = (−1, −2, −1) and PQ · b = −1 + 2 − 1 = 0. The image is 2Q − P = (2, −3, 1).
Worked example 3: from the origin, with fractions
Find the foot of the perpendicular from the origin O to the line through A(3, 0, 3) parallel to (2, 1, 2), and the distance. Here AO = (−3, 0, −3) and AO · b = −6 − 6 = −12, so λ = −12/9 = −4/3. The foot is (3 − 8/3, −4/3, 3 − 8/3) = (1/3, −4/3, 1/3), and the distance is √(1/9 + 16/9 + 1/9) = √2. Check with the projection route: |OA|² = 18 and the projection is 12/3 = 4, so d² = 18 − 16 = 2.
Traps to avoid
- Use PQ · b = 0, not OQ · b = 0: the perpendicular starts at P, not at the origin.
- The image is 2Q − P; Q − P is only the vector from P to the foot.
- In λ = (AP · b)/|b|², A must be the same point of the line that you use in Q = A + λb.
- Keep fractional values of λ exact; rounding spoils the foot and the image.
Key takeaways. Write the general point, make PQ perpendicular to the direction, and read the foot, distance and image from one value of λ. For the distance alone, use |AP|² minus the square of the projection.
Check your understanding
-
1. What is the foot of the perpendicular from P(1, 5, −1) to the line x/1 = (y − 1)/2 = (z + 1)/2?
- (2, 5, 3)
- (0, 1, −1)
- (1, 1, 3)
- (1, 3, 1)
Show answer
Answer: D. General point Q(λ, 1 + 2λ, −1 + 2λ), so PQ = (λ − 1, 2λ − 4, 2λ). PQ · (1, 2, 2) = (λ − 1) + 2(2λ − 4) + 4λ = 9λ − 9 = 0 gives λ = 1, so Q = (1, 3, 1). (2, 5, 3) is on the line but PQ is not perpendicular to it there.
-
2. What is the perpendicular distance of P(5, 1, 1) from the line r = λ(2î + ĵ − 2k̂)?
- 3
- 3√3
- 3√2
- √2
Show answer
Answer: C. Projection route with A = O: |OP|² = 27 and OP · b = 10 + 1 − 2 = 9, so the projection is 9/3 = 3. Then d² = 27 − 9 = 18 and d = 3√2. The value 3 is the projection itself and 3√3 is |OP|.
-
3. What is the image of P(2, 5, 2) in the line (x − 1)/2 = (y − 2)/1 = z/2?
- (3, 3, 2)
- (4, 1, 2)
- (1, 7, 2)
- (−4, −1, −2)
Show answer
Answer: B. With A(1, 2, 0): AP = (1, 3, 2), AP · b = 2 + 3 + 4 = 9 and |b|² = 9, so λ = 1 and the foot is Q(3, 3, 2). Check: PQ = (1, −2, 0) and 2 − 2 + 0 = 0. The image is 2Q − P = (6 − 2, 6 − 5, 4 − 2) = (4, 1, 2). (3, 3, 2) is only the foot.
-
4. In the general-point method for the foot of the perpendicular from P to the line Q = A + λb, which condition fixes λ?
- PQ · b = 0
- OQ · b = 0
- PQ × b = 0
- |PQ| = |b|
Show answer
Answer: A. The foot is where the segment from P meets the line at a right angle, so PQ · b = 0. OQ · b = 0 would give the foot from the origin instead, and PQ × b = 0 would make PQ parallel to the line.
-
5. For what value of k is the foot of the perpendicular from P(k, 4, 1) to the line r = λ(î + 2ĵ + 2k̂) the point (1, 2, 2)?
- 1
- −1
- 9
- −9
Show answer
Answer: B. (1, 2, 2) is the point λ = 1. The foot has λ = (OP · b)/|b|² = (k + 8 + 2)/9, so k + 10 = 9 and k = −1. Check: PQ = (2, −2, 1) and 2 − 4 + 2 = 0.
Sign in to keep track of the lessons you finish.