Equation of a Line in Three Dimensions
A point and a direction are all it takes to describe every point on a line in space — in vector form or its equivalent Cartesian symmetric form.
The vector equation of a line
A line through the point with position vector $\mathbf{a}$, in the direction of vector $\mathbf{d}$, has equation $$\mathbf{r}=\mathbf{a}+\lambda\mathbf{d}, \qquad \lambda\in\mathbb{R}$$ where $\mathbf{r}=(x,y,z)$ is the position vector of a general point on the line.
Direction vector: $\vec{AB}=B-A=(2,-3,5)$.
The Cartesian (symmetric) form
Writing $\mathbf{r}=(x_0,y_0,z_0)+\lambda(l,m,n)$ componentwise gives $x=x_0+\lambda l$, $y=y_0+\lambda m$, $z=z_0+\lambda n$. Solving each for $\lambda$ (where $l,m,n\neq0$) and equating gives the Cartesian form: $$\frac{x-x_0}{l}=\frac{y-y_0}{m}=\frac{z-z_0}{n}$$
Reading off the point ($x_0,y_0,z_0$ where each numerator is zero) and direction (denominators):
Testing whether a point lies on a line
From the $x$-coordinate: $1+3\lambda=7 \Rightarrow \lambda=2$.
Check $y$: $1+2(2)=5$ ✓. Check $z$: $1-2(2)=-3$ ✓.
All three coordinates are consistent with $\lambda=2$, so the point does lie on the line.
The direction vector of a line must be found by subtracting position vectors ($B-A$), not by using either point's coordinates directly as the direction. Also, when testing a point against a line, all three coordinate equations must be checked — matching just one or two is not sufficient.
Collinear points
Points are collinear if they all lie on a single straight line. To test three points $P,Q,S$ for collinearity, form $\vec{PQ}$ and $\vec{PS}$: the points are collinear exactly when these two vectors are parallel (one is a scalar multiple of the other), since that means $Q$ and $S$ both lie on the line through $P$ with direction $\vec{PQ}$.
$\vec{PQ}=Q-P=(3,3,-3)$ and $\vec{PS}=S-P=(6,6,-6)$.
$\vec{PS}=2\vec{PQ}$, so the two vectors are parallel.
Since $\vec{PQ}$ and $\vec{PS}$ are parallel and share the common point $P$, all three points lie on the same line: $P$, $Q$ and $S$ are collinear.
Exam-style questions
Question 1 5 marks
Find the vector equation of the line through $P(4,-1,2)$ parallel to $\mathbf{d}=(1,2,-2)$, and determine whether the point $(6,3,-2)$ lies on this line.
$\mathbf{r}=\begin{pmatrix}4\\-1\\2\end{pmatrix}+\lambda\begin{pmatrix}1\\2\\-2\end{pmatrix}$ (M1, A1)
$x$: $4+\lambda=6\Rightarrow \lambda=2$. Check $y$: $-1+2(2)=3$ ✓. Check $z$: $2-2(2)=-2$ ✓. (M1, A1)
All three coordinates are consistent with $\lambda=2$, so the point does lie on the line. (A1)
Question 2 6 marks
Find the Cartesian equation of the line through $A(-2,3,1)$ and $B(0,-1,4)$.
$\vec{AB}=B-A=(2,-4,3)$ (M1, A1)
$\dfrac{x+2}{2}=\dfrac{y-3}{-4}=\dfrac{z-1}{3}$ (M1, A1, A1, A1)
Question 3 5 marks
The line $l$ has Cartesian equation $\dfrac{x-3}{2}=\dfrac{y+1}{-1}=\dfrac{z-4}{3}$. Find the coordinates of the point on $l$ where $z=10$.
$\dfrac{z-4}{3}=\lambda \Rightarrow \dfrac{10-4}{3}=2=\lambda$ (M1, A1)
$x=3+2(2)=7$; $y=-1-1(2)=-3$ (M1, A1, A1)
Point: $(7,-3,10)$