LINES AND PLANES

5. LINES AND PLANES

A great deal of analytic geometry can be simplified by the use of vector notation. Such things as equations of lines and planes, and distances between points or be- tween lines and planes often occur in physics and it is very useful to be able to find them quickly. We shall talk about three-dimensional space most of the time although the ideas apply also to two dimensions. In analytic geometry a point is

a set of three coordinates (x, y, z); we shall think of this point as the head of a vector r = ix + jy + kz with tail at the origin. Most of the time the vector will

be in the background of our minds and we shall not draw it; we shall just plot the point (x, y, z) which is the head of the vector. In other words, the point (x, y, z) and the vector r will be synonymous. We shall also use vectors joining two points. In Figure 5.1 the vector A from (1, 2, 3) to (x, y, z) is

Thus we have two ways of writing vector equations; we may choose the one we prefer. Note the possible advantage of writing (1, 0, −2) for i−2k; since the zero is explicitly written, there is less chance of accidentally confusing i − 2k with i − 2j = (1, −2, 0). On the other hand, 5j is simpler than (0, 5, 0).

In two dimensions, we write the equation of a straight line through (x 0 ,y 0 ) with slope m as

y−y 0

= m.

x−x 0

Section 5 Lines and Planes 107

Figure 5.2

Suppose, instead of the slope, we are given a vector in the direction of the line, say A = ia+jb (Figure 5.2). Then the line through (x 0 ,y 0 ) and in the direction A is determined and we should be able to write its equation. The directed line segment from (x 0 ,y 0 ) to any point (x, y) on the line is the vector r − r 0 with components x−x 0 and y − y 0 :

r−r 0 = i(x − x 0 ) + j(y − y 0 ).

This vector is parallel to A = ia + jb. Now if two vectors are parallel, their compo-

This is the equation of the given straight line. As a check we see that the slope of the line is m = b/a, so (5.3) is the same as (5.1).

Another way to write this equation is to say that if r − r 0 and A are parallel vectors, one is some scalar multiple of the other, that is,

r−r 0 = At, or r = r 0 + At,

where t is the scalar multiple. We can think of t as a parameter; the component form of (5.4) is a set of parametric equations of the line, namely

Eliminating t yields the equation of the line in (5.3). In three dimensions, the same ideas can be used. We want the equations of

a straight line through a given point (x 0 ,y 0 ,z 0 ) and parallel to a given vector

A = ai + bj + ck. If (x, y, z) is any point on the line, the vector joining (x 0 ,y 0 ,z 0 ) and (x, y, z) is parallel to A. Then its components x − x 0 ,y−y 0 ,z−z 0 are proportional to the components a, b, c of A and we have

x−x 0 y−y 0 z−z 0 (symmetric equations of a straight line, (5.6)

If c, for instance, happens to be zero, we would have to write (5.6) in the form

108 Linear Algebra Chapter 3

x−x 0 y−y 0 (symmetric equations of a straight line (5.7)

, z=z 0

a b when c = 0).

As in the two-dimensional case, equations (5.6) and (5.7) could be written

  x=x 0 + at,

(parametric equations (5.8)

r=r 0 + At, or

y=y 0 + bt,

of a straight line).

z=z 0 + ct,

The parametric equations (5.8) have a partic- ularly useful interpretation when the parameter t means time. Consider a particle m (electron, billiard ball, or star) moving along the straight line L in Figure 5.3. Position yourself at the ori-

gin and watch m move from P 0 to P along L.

Your line of sight is the vector r; it swings from r 0 at t = 0 to r = r 0 + At at time t. Note that the velocity of m is dr/dt = A; A is a vector along the line of motion.

Figure 5.3 Going back to two dimensions, suppose we want the equation of a straight line L

through the point (x 0 ,y 0 ) and perpendicular to a given vector N = ai+bj. As above, the vector

r−r 0 = (x − x 0 )i + (y − y 0 )j

lies along the line. This time we want this vector perpendicular to N; recall that two vectors are perpendicular if their dot product is zero. Setting the dot product

of N and r − r 0 equal to zero gives y−y 0 a

This is the desired equation of the straight line L perpendicular to N. As a check, note from Figure 5.4 that the slope of the line L is

tan θ = − cot φ = −a/b.

Figure 5.4 Figure 5.5

In three dimensions, we use this method to write the equation of a plane. If (x 0 ,y 0 ,z 0 ) is a given point in the plane and (x, y, z) is any other point in the plane,

Section 5 Lines and Planes 109

the vector (Figure 5.5) r−r 0 = (x − x 0 )i + (y − y 0 )j + (z − z 0 )k is in the plane. If N = ai + bj + ck is normal (perpendicular) to the plane, then N

and r − r 0 are perpendicular, so the equation of the plane is N · (r − r 0 ) = 0, or

a(x − x 0 ) + b(y − y 0 ) + c(z − z 0 ) = 0,

(5.10) (equation of a plane)

or ax + by + cz = d, where d = ax 0 + by 0 + cz 0 .

If we are given equations like the ones above, we can read backwards to find A or N. Thus we can say that the equations (5.6), (5.7), and (5.8) are the equations of a straight line which is parallel to the vector A = ai + bj+ ck, and either equation in (5.10) is the equation of a plane perpendicular to the vector N = ai + bj + ck.

Example 1. Find the equation of the plane through the three points A(−1, 1, 1), B(2, 3, 0), C(0, 1, −2).

A vector joining any pair of the given points lies in the plane. Two such vectors −−→

are AB = (2, 3, 0) − (−1, 1, 1) = (3, 2, −1) and AC = (1, 0, −3). The cross product of these two vectors is perpendicular to the plane. This is

k N=( −−→ AB) × ( −→ AC) = 32 −1 = −6i + 8j − 2k.

Now we write the equation of the plane with normal direction N through one of the given points, say B, using (5.10):

−6(x − 2) + 8(y − 3) − 2z = 0 or 3x − 4y + z + 6 = 0. (Note that we could have divided N by −2 to save arithmetic.)

Example 2. Find the equations of a line through (1, 0, −2) and perpendicular to the plane of Example 1. The vector 3i − 4j + k is perpendicular to the plane of Example 1 and so parallel to the desired line. Thus by (5.6) the symmetric equations of the line are

By (5.8) the parametric equations of the line are r = i − 2k + (3i − 4j + k)t or, if you like, r = (1, 0, −2) + (3, −4, 1)t.

Vectors give us a very convenient way of finding distances between points and lines or planes. Suppose we want to find the (perpendicular) distance from a point P

110 Linear Algebra Chapter 3

Figure 5.6

to the plane (5.10). (See Figure 5.6.) We pick any point Q we like in the plane (just by looking at the equation of the plane and thinking of some simple numbers x, y, z that satisfy it). The distance P R is what we want. Since P R and RQ are perpendicular (because P R is perpendicular to the plane), we have from Figure 5.6

P R = P Q cos θ.

From the equation of the plane, we can find a vector N normal to the plane. If we divide N by its magnitude, we have a unit vector normal to the plane; we denote

this unit vector by n. Then | P Q · n| = (P Q) cos θ, which is what we need in (5.11) to find P R. (We have put in absolute value signs because −−→ P Q · n might be negative, whereas (P Q) cos θ, with θ acute as in Figure 5.6, is positive.)

Example 3. Find the distance from the point P (1, −2, 3) to the plane 3x − 2y + z + 1 = 0. One point in the plane is (1, 2, 0); call this point Q. Then the vector from P to Q is

−−→ P Q = (1, 2, 0) − (1, −2, 3) = (0, 4, −3) = 4j − 3k.

From the equation of the plane we get the normal vector

N = 3i − 2j + k. √

We get n by dividing N by |N| =

14. Then we have

√ |P R| = PQ·n

We can find the distance from a point P to a line in a similar way. In Figure 5.7 we want the perpendicular distance P R. We select any point on the line [that is, we pick any (x, y, z) satisfying the equations of the line]; call this point Q. Then (see Figure 5.7) P R = P Q sin θ. Let

A be a vector along the line and u a unit vector along the line (obtained by dividing A by its magnitude). Then

−−→ PQ×u

so we get

−−→ |P R| = PQ×u

Figure 5.7

Section 5 Lines and Planes 111

Example 4. Find the distance from P (1, 2, −1) to the line joining P 1 (0, 0, 0) and P 2 (−1, 0, 2). −−−→

Let A = P 1 P 2 = −i + 2k; this is a vector along the line. Then a unit vector √ along the line is u = (1/ 5)(−i + 2k). Let us take Q to be P 1 (0, 0, 0). Then

−−→ P Q = −i − 2j + k, so we get for the distance |P R|:

|P R| = √ |(−i − 2j + k) × (−i + 2k)| = √ | − 4i + j − 2k| =

It is also straightforward to find the distance between two skew lines (and if you really want to appreciate vectors, just look up this calculation in an analytic geometry book that doesn’t use vectors!). Pick two points P and Q, one on each

line (Figure 5.8). Then | P Q · n|, where n is a unit vector perpendicular to both lines, is the distance we want. Now if A and B are vectors along the two lines, then

A × B is perpendicular to both, and n is just A × B divided by |A × B|.

Figure 5.8

Example 5. Find the distance between the lines r = i−2j+(i−k)t and r = 2j−k+(j−i)t. If we write the first line as r = r 0 + At, then (the head of) r 0 is a simple choice for P , so we have

P = (1, −2, 0) and A = i − k.

Similarly, from the second line we find

Q = (0, 2, −1) and B = j − i. √

Then A × B = i + j + k and n =

−−→ P Q = (0, 2, −1) − (1, −2, 0) = (−1, 4, −1) = −i + 4j − k.

Thus we get for the distance between the lines −−→

√ PQ·n

√ (i + j + k)/ 3 3 = 2/ 3.

Example 6. Find the direction of the line of intersection of the planes x − 2y + 3z = 4 and 2x + y − z = 5.

The desired line lies in both planes, and so is perpendicular to the two normal vectors to the planes, namely i − 2j + 3k and 2i + j − k. Then the direction of the line is that of the cross product of these normal vectors; this is −i + 7j + 5k.

112 Linear Algebra Chapter 3

Example 7. Find the cosine of the angle between the planes of Example 6. The angle between the planes is the same as the angle between the normals to the planes. Thus our problem is to find the angle between the vectors A = i−2j+3k √ √ and B = 2i + j − k. Since A · B = |A| |B| cos θ, we have −3 = 14 6 cos θ, and so cos θ = −

acute angle is π − θ, or arc cos

PROBLEMS, SECTION 5

In Problems 1 to 5, all lines are in the (x, y) plane. 1. Write the equation of the straight line through (2, −3) with slope 3/4, in the para-

metric form r = r 0 + At.

2. Find the slope of the line whose parametric equation is r = (i − j) + (2i + 3j)t. 3. Write, in parametric form [as in Problem 1], the equation of the straight line that

joins (1, −2) and (3, 0). 4. Write, in parametric form, the equation of the straight line that is perpendicular to

r = (2i + 4j) + (i − 2j)t and goes through (1, 0). 5. Write, in parametric form, the equation of the y axis.

Find the symmetric equations (5.6) or (5.7) and the parametric equations (5.8) of a line, and/or the equation (5.10) of the plane satisfying the following given conditions.

6. Line through (1, −1, −5) and (2, −3, −3). 7. Line through (2, 3, 4) and (5, 1, −2). 8. Line through (0, −2, 4) and (3, −2, −1). 9. Line through (−1, 3, 7) and (−1, −2, 7). 10. Line through (3, 4, −1) and parallel to 2i − 3j + 6k. 11. Line through (4, −1, 3) and parallel to i − 2k. 12. Line through (5, −4, 2) and parallel to the line r = i − j + (5i − 2j + k)t. 13. Line through (3, 0, −5) and parallel to the line r = (2, 1, −5) + (0, −3, 1)t. 14. Plane containing the triangle ABC of Problem 4.11. 15. Plane through the origin and the points in Problem 8. 16. Plane through the point and perpendicular to the line in Problem 12. 17. Plane through the point and perpendicular to the line in Problem 13. 18. Plane containing the two parallel lines in Problem 12. 19. Plane containing the two parallel lines in Problem 13. 20. Plane containing the three points (0, 1, 1), (2, 1, 3), and (4, 2, 1).

In Problems 21 to 23, find the angle between the given planes. 21. 2x + 6y − 3z = 10 and 5x + 2y − z = 12. 22. 2x − y − z = 4 and 3x − 2y − 6z = 7. 23. 2x + y − 2z = 3 and 3x − 6y − 2z = 4.

Section 5 Lines and Planes 113

24. Find a point on both the planes (that is, on their line of intersection) in Problem 21. Find a vector parallel to the line of intersection. Write the equations of the line of intersection of the planes. Find the distance from the origin to the line.

25. As in Problem 24, find the equations of the line of intersection of the planes in Problem 22. Find the distance from the point (2, 1, −1) to the line.

26. As in Problem 24, find the equations of the line of intersection of the planes in Problem 23. Find the distance from the point (1, 0, 0) to the line.

27. Find the equation of the plane through (2, 3, −2) and perpendicular to both planes in Problem 21.

28. Find the equation of the plane through (−4, −1, 2) and perpendicular to both planes in Problem 22.

29. Find a point on the plane 2x − y − z = 13. Find the distance from (7, 1, −2) to the plane.

30. Find the distance from the origin to the plane 3x − 2y − 6z = 7. 31. Find the distance from (−2, 4, 5) to the plane 2x + 6y − 3z = 10. 32. Find the distance from (3, −1, 2) to the plane 5x − y − z = 4. 33. Find the perpendicular distance between the two parallel lines in Problem 12. 34. Find the distance (perpendicular is understood) between the two parallel lines in

Problem 13. 35. Find the distance from (2, 5, 1) to the line in Problem 10. 36. Find the distance from (3, 2, 5) to the line in Problem 11. 37. Determine whether the lines

4 1 4 intersect. Two suggestions: (1) Can you find the intersection point, if any? (2) Con-

sider the distance between the lines. 38. Find the angle between the lines in Problem 37.

In Problems 39 and 40, show that the given lines intersect and find the acute angle between them.

39. r = 2j + k + (3i − k)t 1 and

r = 7i + 2k + (2i − j + k)t 2 .

r = (4, −4, −1) + (0, 3, 2)t 2 . In Problems 41 to 44, find the distance between the two given lines. 41. r = (4, 3, −1) + (1, 1, 1)t

40. r = (5, −2, 0) + (1, −1, −1)t 1 and

r = (4, −1, 1) + (1, −2, −1)t. 42. The line that joins (0, 0, 0) to (1, 2, −1), and the line that joins (1, 1, 1) to (2, 3, 4). 43. x−1

44. The x axis and r = j − k + (2i − 3j + k)t. 45. A particle is traveling along the line (x − 3)/2 = (y + 1)/(−2) = z − 1. Write the

equation of its path in the form r = r 0 + At. Find the distance of closest approach of the particle to the origin (that is, the distance from the origin to the line). If t represents time, show that the time of closest approach is t = −(r 0 ·

A)/|A| 2 . Use this value to check your answer for the distance of closest approach. Hint: See

Figure 5.3. If P is the point of closest approach, what is A · r?

114 Linear Algebra Chapter 3