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

Let us assume the given two points of line be X(–2,4,–5) and Y(1,2,3).


Let us also assume the direction ratios for the given line be (r1, r2, r3).


We know that direction ratios for a line passing through points (x1, y1, z1) and (x2, y2, z2) is (x2–x1, y2–y1, z2–z1).


So, using this property the direction ratios for the given line is, (r1, r2, r3) = (1–(–2), 2–4, 3–(–5))


(r1, r2, r3) = (1+2, 2–4, 3+5)


(r1, r2, r3) = (3, –2, 8)


Let us assume be the direction cosines of the given line.


We know that for a line of direction ratios r1, r2, r3 and having direction cosines has the following property.





Let us substitute the values of r1, r2, r3 to find the values of .











The Direction Cosines for the given line is .


3