Question:
Find the direction cosines of the vector joining the points A (1, 2, –3) and
B (–1, –2, 1) directed from A to B.
Solution:
The given points are $A(1,2,-3)$ and $B(-1,-2,1)$.
$\therefore \overrightarrow{\mathrm{AB}}=(-1-1) \hat{i}+(-2-2) \hat{j}+\{1-(-3)\} \hat{k}$
$\Rightarrow \overrightarrow{\mathrm{AB}}=-2 \hat{i}-4 \hat{j}+4 \hat{k}$
$\therefore|\overrightarrow{\mathrm{AB}}|=\sqrt{(-2)^{2}+(-4)^{2}+4^{2}}=\sqrt{4+16+16}=\sqrt{36}=6$
Hence, the direction cosines of $\overrightarrow{\mathrm{AB}}$ are $\left(-\frac{2}{6},-\frac{4}{6}, \frac{4}{6}\right)=\left(-\frac{1}{3},-\frac{2}{3}, \frac{2}{3}\right)$.