JC · H2 Mathematics · Vectors summary video
This page explains how to write the vector equation of a line in H2 Maths vectors, how to change it to cartesian form and how to change it back. Start with the film, which runs for about 3 and a half minutes and works through one example in three steps. Below it you will find the three steps, one fully worked example through two points that ends with a cartesian equation changed back to vector form, the common slips to watch for, and a practice question to try yourself.
Vector equation of a line at a glance
- A line needs: one point on it, with position vector , and one direction along it, .
- Step 1: the direction is when the line passes through and .
- Step 2: , .
- Step 3: for cartesian form, write as , make the subject of each row and set the three equal.
- Going back: set the equal fractions to a new letter such as , make , , the subject, and read the position and the direction off the constants and the terms.
What a line needs: a point and a direction
To write the equation of a line you need one point on it and one direction along it. The point is given by a position vector , and the direction by a vector parallel to the line. From the point , add copies of : one , two , minus one . Each copy lands on a point of the line, and every point of the line is reached this way. Writing the number of copies as gives
How to find the vector equation of a line and its cartesian form in three steps
Step 1: the direction vector
If the line passes through and , then is parallel to the line, so use it as the direction vector :
Step 2: r = a + λm
Each value of gives a different point on the line. Always write that is a real number: it is part of the equation. Equations of lines are not unique: any point on the line and any parallel vector will do.
Step 3: cartesian form, with no λ
Cartesian form uses , and only. Write as , combine the right side into one vector, and read off one equation for each of , and . Make the subject of each: subtract the position, then divide by the direction. All three equal , so set them equal to each other.
Use cartesian form only when the question asks for it. Otherwise, work in vector form.
Worked example: vector equation of a line through two points and its cartesian equation
Question. The points and have position vectors and .
(a) Find a vector equation of the line through and .
(b) Find a cartesian equation of .
(c) Another line has cartesian equation
Write in vector form.
Part (a), Step 1. is parallel to the line, so it is the direction vector :
Step 2. Use as the point on the line:
Part (b), Step 3. Write as and combine the right side:
So , and . Make the subject of each, subtracting the position and dividing by the direction:
They all equal , so set them equal to each other:
Check. With the vector equation gives , which is . In the cartesian equation, gives , so all three fractions agree.
Part (c). To go back, set the equal fractions to , since is taken:
Make and the subject: and . Now is always 5. There is no in it, so its direction part is zero: . Read the position from the constants and the direction from the coefficients of :

From the Vectors summary and formula sheet · page 2, section 7
Vector equation of a line and cartesian equation
Common slips with the vector equation of a line and cartesian form
- Leaving out that λ is a real number. Writing and stopping. Fix: always add , because it is part of the equation.
- Losing the sign of the position. The in the position vector gives in the cartesian equation, not . Fix: subtract the position from the variable, so .
- Dropping the zero in the direction when going back. A fixed , such as , is a zero in the direction vector. Fix: write and give the direction .
- Using again in a second line. Fix: use a different letter, such as , when is already taken.
- Using cartesian form when it is not asked for. Fix: work in vector form unless the question asks for cartesian form.
Practice question: try one yourself
The points and have position vectors and .
(a) Find a vector equation of the line through and .
(b) Find a cartesian equation of .
(c) A line has cartesian equation
Write in vector form.
Show the answer
(a) , so , .
(b) .
(c) Set the fractions to : , , . So , .
Check: with in (a) you reach , which is , and in (b) gives .
Vector equation of a line FAQs
How do you find the vector equation of a line through two points?
Subtract the position vectors to get the direction vector m = AB = OB − OA. Then write r = a + λm, using either point as a and adding that λ is a real number.
How do you change a vector equation of a line into cartesian form?
Write r as (x, y, z), so that x, y and z each equal a number plus λ times a number. Make λ the subject of each one by subtracting the position and dividing by the direction, then set the three expressions equal to each other.
How do you change a cartesian equation of a line back into vector form?
Set the equal fractions to a new letter such as μ, make x, y and z the subject, then read the position vector from the constants and the direction vector from the coefficients of μ. A variable given on its own, such as z = 5, has a zero in the direction vector.
Is the vector equation of a line unique?
No. Any point on the line can be the position vector, and any non-zero multiple of the direction vector can be the direction, so different correct answers can look different. Check by substituting a point of one answer into the other.
More H2 Maths vectors practice
The section on forming equations of lines and planes in our H2 Maths vectors notes carries more examples. For questions from school papers with worked solutions, try JC1 H2 Maths promo questions on vectors and JC2 H2 Maths prelim questions on vectors.
Next in the Vectors films
Transcript: vector equation of a line film
Here’s a line through two points, A and B. To write its equation, you need one point on the line, and one direction along it. We’ll write it in vector form, then change it to cartesian form, and back. That’s three steps. Let’s do them with an example.
The points A and B have position vectors two, minus one, three, and six, one, zero. Part a. Find a vector equation of the line l through A and B. Part b. Find a cartesian equation of l.
Step one. The direction. A B is parallel to the line, so we use it as the direction vector. A B is O B minus O A. That’s four, two, minus three. Call it m.
Step two. From A, add copies of m: one m, two m, minus one m. Each lands on a point R of the line. So r equals a plus lambda m. Each value of lambda gives a different point on the line. Here, r equals two, minus one, three, plus lambda, four, two, minus three. And write lambda is a real number. It’s part of the equation. Equations of lines are not unique. Any point on the line, and any parallel vector, will do.
Step three. Cartesian form uses x, y and z, with no lambda. Write r as x, y, z. So x is two plus four lambda, y is minus one plus two lambda, and z is three minus three lambda. Make lambda the subject of each one. Subtract the position, then divide by the direction. So lambda is x minus two, over four. It’s also y plus one, over two, and z minus three, over minus three. They all equal lambda, so set them equal to each other. That’s the cartesian equation. Use cartesian form only when the question asks for it. Otherwise, work in vector form.
Part c. Another line has cartesian equation x plus two, over three, equals y minus one, over minus four, and z equals five. To go back, set the equal fractions to mu, since lambda is taken. Then x is minus two plus three mu, and y is one minus four mu. z is always five. There’s no mu in it, so its direction part is zero. So r equals minus two, one, five, plus mu, three, minus four, zero.
Three steps. A B for the direction. Then r equals a plus lambda m. Then make lambda the subject of each part, and set them equal. Watch for two slips. Always write lambda is a real number. And watch the signs. y plus one comes from the minus one in the position vector. Going back, a fixed z means a zero in the direction vector.
JC H2 Maths classes at Math Academy
Math Academy is run by the Ang family, three family teachers who are all NUS Mathematics graduates. Our JC1 and JC2 H2 Maths classes are taught by Mr Ian Ang, with at most 9 students in each class, in a weekly 2 hour lesson at our centre opposite Bukit Gombak MRT or live online. Every lesson is recorded, and each topic comes with his notes. To read more about our H2 maths tuition, visit the homepage, or WhatsApp us on 8859 1092.