Introduction to 3D Geometry and Direction Angles

In three-dimensional geometry, describing the orientation of a straight line is one of the first essential ideas. Consider a directed line LL. If this line makes angles α\alpha, β\beta, and γ\gamma with the positive directions of the x-, y-, and z-axes respectively, then these are called the direction angles of the directed line.

  • If a line does not pass through the origin, we can always draw a line through the origin parallel to it. Since parallel lines have the same orientation, they have the same direction angles.
  • If the direction of the line is reversed, then the new direction angles become πα\pi-\alpha, πβ\pi-\beta, and πγ\pi-\gamma.
  • Thus, a line has two opposite orientations, and changing the orientation changes the signs of its direction cosines.

This idea is important because in 3D geometry, we often study a line through its direction rather than its exact position.

Direction Cosines of a Line

If α\alpha, β\beta, and γ\gamma are the direction angles of a directed line, then the numbers cosα,cosβ,cosγ\cos\alpha, \quad \cos\beta, \quad \cos\gamma are called the direction cosines of the line. These are usually denoted by l,m,nl, m, n respectively: l=cosα,m=cosβ,n=cosγ.l = \cos\alpha, \qquad m = \cos\beta, \qquad n = \cos\gamma.

These three numbers completely determine the direction of the line.

Fundamental Identity: The direction cosines always satisfy l2+m2+n2=1.l^2 + m^2 + n^2 = 1.

Why this is true: Take any point P(x,y,z)P(x,y,z) on the line at distance rr from the origin. Then the coordinates of PP can be written as x=lr,y=mr,z=nr.x = lr, \qquad y = mr, \qquad z = nr. Using the distance formula, r2=x2+y2+z2.r^2 = x^2 + y^2 + z^2. Substituting x=lr,y=mr,z=nrx=lr, y=mr, z=nr gives r2=l2r2+m2r2+n2r2=r2(l2+m2+n2).r^2 = l^2r^2 + m^2r^2 + n^2r^2 = r^2(l^2+m^2+n^2). Since r0r \neq 0 for any non-origin point on the line, dividing by r2r^2 yields l2+m2+n2=1.l^2+m^2+n^2=1.

This identity is the most important test for checking whether a given triple can be direction cosines.

Direction Ratios of a Line

Any three numbers a,b,ca, b, c which are proportional to the direction cosines l,m,nl, m, n of a line are called the direction ratios of the line. Thus, for some non-zero constant kk, l=ak,m=bk,n=ck.l = ak, \qquad m = bk, \qquad n = ck. Equivalently, la=mb=nc=k.\frac{l}{a} = \frac{m}{b} = \frac{n}{c} = k.

Unlike direction cosines, direction ratios do not need to satisfy any special identity like a2+b2+c2=1a^2+b^2+c^2=1. Any three real numbers, not all zero, can serve as direction ratios.

Converting Direction Ratios to Direction Cosines

Since l=ak,m=bk,n=ck,l=ak,\quad m=bk,\quad n=ck, and also l2+m2+n2=1,l^2+m^2+n^2=1, we get a2k2+b2k2+c2k2=1a^2k^2+b^2k^2+c^2k^2=1 k2(a2+b2+c2)=1.k^2(a^2+b^2+c^2)=1. So, k=±1a2+b2+c2.k = \pm \frac{1}{\sqrt{a^2+b^2+c^2}}. Hence the direction cosines are l=±aa2+b2+c2,m=±ba2+b2+c2,n=±ca2+b2+c2.l = \pm \frac{a}{\sqrt{a^2+b^2+c^2}}, \qquad m = \pm \frac{b}{\sqrt{a^2+b^2+c^2}}, \qquad n = \pm \frac{c}{\sqrt{a^2+b^2+c^2}}.

The same sign must be taken throughout for one orientation of the line. Taking the opposite common sign gives the opposite orientation.

Direction Cosines and Ratios of a Line Joining Two Points

Let a line pass through two points P(x1,y1,z1)P(x_1,y_1,z_1) and Q(x2,y2,z2)Q(x_2,y_2,z_2). Then the vector PQ=(x2x1)i^+(y2y1)j^+(z2z1)k^\overrightarrow{PQ} = (x_2-x_1)\hat{i} + (y_2-y_1)\hat{j} + (z_2-z_1)\hat{k} gives the direction of the line from PP to QQ.

Therefore, the direction ratios of the line segment PQPQ are a=x2x1,b=y2y1,c=z2z1.a = x_2 - x_1, \qquad b = y_2 - y_1, \qquad c = z_2 - z_1.

If the length of PQPQ is d=(x2x1)2+(y2y1)2+(z2z1)2,d = \sqrt{(x_2-x_1)^2 + (y_2-y_1)^2 + (z_2-z_1)^2}, then the direction cosines of the directed line from PP to QQ are l=x2x1d,m=y2y1d,n=z2z1d.l = \frac{x_2-x_1}{d}, \qquad m = \frac{y_2-y_1}{d}, \qquad n = \frac{z_2-z_1}{d}.

If we reverse the direction and consider QQ to PP, then each of these changes sign.

Collinearity Test using Direction Ratios

Three points A,B,CA, B, C are collinear if the direction ratios of ABAB are proportional to the direction ratios of BCBC (or ACAC). In other words, the vectors AB\overrightarrow{AB} and BC\overrightarrow{BC} must be parallel.

Example 1: Finding Direction Cosines from Angles

If a line makes angles 90,6090^\circ, 60^\circ, and 3030^\circ with the positive directions of x-, y-, and z-axes respectively, find its direction cosines.

Solution: Step 1: Write the given direction angles: α=90,β=60,γ=30.\alpha = 90^\circ, \qquad \beta = 60^\circ, \qquad \gamma = 30^\circ. Step 2: Use the definition l=cosα,m=cosβ,n=cosγ.l = \cos\alpha, \qquad m = \cos\beta, \qquad n = \cos\gamma. Step 3: Evaluate each cosine: l=cos90=0,l = \cos 90^\circ = 0, m=cos60=12,m = \cos 60^\circ = \frac{1}{2}, n=cos30=32.n = \cos 30^\circ = \frac{\sqrt{3}}{2}. Step 4: Verify the identity: l2+m2+n2=02+(12)2+(32)2=0+14+34=1.l^2+m^2+n^2 = 0^2 + \left(\frac12\right)^2 + \left(\frac{\sqrt3}{2}\right)^2 = 0 + \frac14 + \frac34 = 1. So the values are correct.

Answer: 0,12,320, \frac{1}{2}, \frac{\sqrt{3}}{2}

Example 2: Converting Direction Ratios to Direction Cosines

If a line has direction ratios 2,1,22, -1, -2, determine its direction cosines.

Solution: Step 1: Let the direction ratios be a=2,b=1,c=2.a=2, \qquad b=-1, \qquad c=-2. Step 2: Compute a2+b2+c2=22+(1)2+(2)2=4+1+4=9=3.\sqrt{a^2+b^2+c^2} = \sqrt{2^2+(-1)^2+(-2)^2} = \sqrt{4+1+4} = \sqrt9 = 3. Step 3: Divide each direction ratio by 3 to get one set of direction cosines: l=23,m=13,n=23.l = \frac{2}{3}, \qquad m = -\frac{1}{3}, \qquad n = -\frac{2}{3}. Step 4: Since a line can be taken in the opposite direction as well, the opposite set is also valid: 23,13,23.-\frac23, \qquad \frac13, \qquad \frac23. If the direction is not specified, either set represents the same line.

Answer: One possible set is 23,13,23\frac{2}{3}, -\frac{1}{3}, -\frac{2}{3}; the opposite set is also valid.

Example 3: Line Joining Two Points

Find the direction cosines of the line passing through the two points (2,4,5)(-2, 4, -5) and (1,2,3)(1, 2, 3).

Solution: Step 1: Let P(2,4,5),Q(1,2,3).P(-2,4,-5), \qquad Q(1,2,3). Then the direction ratios of the directed line from PP to QQ are a=1(2)=3,b=24=2,c=3(5)=8.a = 1-(-2)=3, \qquad b = 2-4=-2, \qquad c = 3-(-5)=8. So the direction ratios are 3,2,83,-2,8.

Step 2: Find the length of PQPQ: PQ=32+(2)2+82=9+4+64=77.PQ = \sqrt{3^2+(-2)^2+8^2} = \sqrt{9+4+64} = \sqrt{77}. Step 3: Divide each direction ratio by 77\sqrt{77}: l=377,m=277,n=877.l = \frac{3}{\sqrt{77}}, \qquad m = -\frac{2}{\sqrt{77}}, \qquad n = \frac{8}{\sqrt{77}}. Step 4: Check: (377)2+(277)2+(877)2=9+4+6477=1.\left(\frac{3}{\sqrt{77}}\right)^2 + \left(-\frac{2}{\sqrt{77}}\right)^2 + \left(\frac{8}{\sqrt{77}}\right)^2 = \frac{9+4+64}{77} = 1. Hence these are correct.

Answer: For the directed line from PP to QQ, the direction cosines are 377,277,877\frac{3}{\sqrt{77}}, -\frac{2}{\sqrt{77}}, \frac{8}{\sqrt{77}}.

Example 4: Checking Collinearity

Show that the points A(2,3,4)A(2, 3, -4), B(1,2,3)B(1, -2, 3), and C(3,8,11)C(3, 8, -11) are collinear.

Solution: Step 1: Find the direction ratios of ABAB: AB=(12,23,3(4))=(1,5,7).\overrightarrow{AB} = (1-2,\,-2-3,\,3-(-4)) = (-1,-5,7). So DRs of ABAB are 1,5,7-1,-5,7.

Step 2: Find the direction ratios of BCBC: BC=(31,8(2),113)=(2,10,14).\overrightarrow{BC} = (3-1,\,8-(-2),\,-11-3) = (2,10,-14). So DRs of BCBC are 2,10,142,10,-14.

Step 3: Check proportionality: 12=12,510=12,714=12.\frac{-1}{2} = -\frac12, \qquad \frac{-5}{10} = -\frac12, \qquad \frac{7}{-14} = -\frac12. All three ratios are equal.

Step 4: Therefore, ABBC.\overrightarrow{AB} \parallel \overrightarrow{BC}. Since both segments share the common point BB, the three points must lie on the same straight line.

Answer: Proved. The points are collinear.

Example 5: Finding an Unknown Direction Angle

If a line makes angles 4545^\circ and 6060^\circ with the positive directions of x- and y-axes respectively, find the angle it makes with the positive z-axis.

Solution: Step 1: Given α=45,β=60.\alpha = 45^\circ, \qquad \beta = 60^\circ. We need to find γ\gamma.

Step 2: Use the identity cos2α+cos2β+cos2γ=1.\cos^2\alpha + \cos^2\beta + \cos^2\gamma = 1. Substitute the values: cos245+cos260+cos2γ=1.\cos^2 45^\circ + \cos^2 60^\circ + \cos^2\gamma = 1. That is, (12)2+(12)2+cos2γ=1\left(\frac{1}{\sqrt2}\right)^2 + \left(\frac12\right)^2 + \cos^2\gamma = 1 12+14+cos2γ=1\frac12 + \frac14 + \cos^2\gamma = 1 34+cos2γ=1\frac34 + \cos^2\gamma = 1 cos2γ=14.\cos^2\gamma = \frac14. Step 3: Hence cosγ=±12.\cos\gamma = \pm \frac12. Therefore, γ=60or120.\gamma = 60^\circ \quad \text{or} \quad 120^\circ. Both are possible because the line may be directed in two opposite orientations with respect to the z-axis.

Answer: 6060^\circ or 120120^\circ

Example 6: Trigonometric Identity with Direction Angles

Show that if a line makes angles α,β,γ\alpha, \beta, \gamma with the coordinate axes, then sin2α+sin2β+sin2γ=2\sin^2\alpha + \sin^2\beta + \sin^2\gamma = 2.

Solution: Step 1: Start with the standard identity for direction cosines: cos2α+cos2β+cos2γ=1.\cos^2\alpha + \cos^2\beta + \cos^2\gamma = 1. Step 2: Use cos2θ=1sin2θ.\cos^2\theta = 1 - \sin^2\theta. Then (1sin2α)+(1sin2β)+(1sin2γ)=1.(1-\sin^2\alpha) + (1-\sin^2\beta) + (1-\sin^2\gamma) = 1. Step 3: Simplify: 3(sin2α+sin2β+sin2γ)=1.3 - (\sin^2\alpha + \sin^2\beta + \sin^2\gamma) = 1. Step 4: Rearranging, sin2α+sin2β+sin2γ=2.\sin^2\alpha + \sin^2\beta + \sin^2\gamma = 2. Thus the required relation is proved.

Answer: Proved.

Example 7: Line Equally Inclined to Axes

Find the direction cosines of a line which is equally inclined to the positive coordinate axes.

Solution: Step 1: If the line is equally inclined to the positive x-, y-, and z-axes, then the direction angles are equal, so the direction cosines are equal: l=m=n.l = m = n. Step 2: Use the identity l2+m2+n2=1.l^2 + m^2 + n^2 = 1. Since l=m=nl=m=n, 3l2=1    l2=13    l=13.3l^2 = 1 \implies l^2 = \frac13 \implies l = \frac{1}{\sqrt3}. We take the positive value because the line is equally inclined to the positive axes.

Step 3: Therefore, l=m=n=13.l = m = n = \frac{1}{\sqrt3}.

Answer: (13,13,13)\left(\frac{1}{\sqrt3}, \frac{1}{\sqrt3}, \frac{1}{\sqrt3}\right)

Example 8: Finding Point Coordinates from DCs and Distance

A line passes through the origin and has direction cosines 13,23,23\frac{1}{3}, -\frac{2}{3}, \frac{2}{3}. Find the coordinates of the point on this line which is at a distance of 6 units from the origin.

Solution: Step 1: Let the required point be P(x,y,z)P(x,y,z). Since the line passes through the origin and the distance of the point from the origin is r=6r=6, we use x=lr,y=mr,z=nr.x = lr, \qquad y = mr, \qquad z = nr. Step 2: Substitute the given direction cosines: x=136=2,x = \frac13 \cdot 6 = 2, y=236=4,y = -\frac23 \cdot 6 = -4, z=236=4.z = \frac23 \cdot 6 = 4. So one point is P(2,4,4).P(2,-4,4). Step 3: Since the line extends in the opposite direction also, the point at the same distance on the opposite side of the origin is (2,4,4).(-2,4,-4).

Answer: (2,4,4)(2,-4,4) or (2,4,4)(-2,4,-4)

Example 9: Direction Cosines of the Coordinate Axes

What are the direction cosines of the x-, y-, and z-axes?

Solution: Step 1: For the x-axis, the direction angles are 0,90,90.0^\circ, 90^\circ, 90^\circ. Therefore, cos0,cos90,cos90=1,0,0.\cos 0^\circ, \cos 90^\circ, \cos 90^\circ = 1,0,0. So the direction cosines of the x-axis are (1,0,0)(1,0,0).

Step 2: For the y-axis, the direction angles are 90,0,90.90^\circ, 0^\circ, 90^\circ. Therefore, the direction cosines are (0,1,0)(0,1,0).

Step 3: For the z-axis, the direction angles are 90,90,0.90^\circ, 90^\circ, 0^\circ. Therefore, the direction cosines are (0,0,1)(0,0,1).

Answer: x-axis: (1,0,0)(1,0,0); y-axis: (0,1,0)(0,1,0); z-axis: (0,0,1)(0,0,1)

Example 10: Direction Ratios of a Perpendicular Line

Find the direction ratios of a line perpendicular to two lines whose direction ratios are 1,2,31, 2, 3 and 2,1,4-2, 1, 4.

Solution: Step 1: A vector perpendicular to both given lines must be perpendicular to the vectors u=1,2,3,v=2,1,4.\vec{u} = \langle 1,2,3 \rangle, \qquad \vec{v} = \langle -2,1,4 \rangle. So its direction ratios can be obtained from the cross product u×v\vec{u} \times \vec{v}.

Step 2: Compute the cross product: u×v=i^j^k^123214\vec{u} \times \vec{v} = \begin{vmatrix} \hat{i} & \hat{j} & \hat{k} \\ 1 & 2 & 3 \\ -2 & 1 & 4 \end{vmatrix} =i^(2431)j^(143(2))+k^(112(2))= \hat{i}(2\cdot 4 - 3\cdot 1) - \hat{j}(1\cdot 4 - 3\cdot(-2)) + \hat{k}(1\cdot 1 - 2\cdot(-2)) =i^(83)j^(4+6)+k^(1+4)= \hat{i}(8-3) - \hat{j}(4+6) + \hat{k}(1+4) =5i^10j^+5k^.= 5\hat{i} - 10\hat{j} + 5\hat{k}. Step 3: Therefore, one set of direction ratios is 5,10,5,5, -10, 5, which simplifies to 1,2,1.1, -2, 1. The opposite set 1,2,1-1,2,-1 is also valid.

Answer: One possible set of direction ratios is 1,2,11,-2,1.