Points, Lines and the Coordinate Plane
Mark any two points on a sheet of graph paper and join them with a ruler. What you get is a straight piece of line. Take the points P(3, 4) and Q(-2, -3). P is 3 units to the right of the origin and 4 units up. Q is 2 units to the left and 3 units down. Joining them gives the line segment PQ, and it happens to pass through the origin O.

From the same two points you can make more than one kind of straight line. You can stop exactly at P and Q, which gives a line segment. You can start at one point and go on forever through the other, which gives a ray. You can extend it forever in both directions, which gives a line. Whatever you choose, only one straight line can pass through two given points. That is why two points are enough to fix a line.
Line segment: the part of a straight line between two fixed end points, such as PQ. It has a definite length.
Ray: a part of a straight line that starts at one point and goes on without end in one direction.
Straight line: a line that goes on without end in both directions and never bends. Through any two different points there is exactly one straight line.
What the Equation of a Line Means
A straight line on the coordinate plane is made of countless points, and each point has coordinates (x, y). For a particular line, the x and y of its points are not random. They obey one fixed rule. When that rule is written as an equation in x and y, we call it the equation of the line.
Equation of a straight line: a relation between x and y that is satisfied by the coordinates of every point on the line and by no point off the line.
Two tests follow from this. If a point lies on the line, its coordinates make the equation true. If a point's coordinates make the equation true, the point lies on the line.
The simplest lines to study are the two axes themselves and the lines that run parallel to them. Their equations contain only one of the two letters, as you will see.
Equation of the X-axis
Look at the points P, Q and R on the X-axis in the grid below. Counting the squares, their coordinates are P(1, 0), Q(4, 0) and R(-3, 0). The x-coordinates are all different because the points are at different distances from the origin. The y-coordinate, however, is 0 every time, because none of these points has moved up or down from the X-axis.

This is true of every point on the X-axis, not only these three. Any point on the X-axis has height zero. So along the whole X-axis, the value of y is always 0, while x can be any number.
\[ \text{Equation of the X-axis: } y = 0 \]
Equation of the Y-axis
Now look at A, B and C on the Y-axis in the same grid. Their coordinates are A(0, 6), B(0, 4) and C(0, -2). This time the y-coordinates change, but the x-coordinate is 0 every time. A point on the Y-axis has not moved left or right from the Y-axis at all.
Every point of the Y-axis is like this. Along the whole Y-axis, the value of x is always 0, while y can be any number.
\[ \text{Equation of the Y-axis: } x = 0 \]
Students often swap these two. The X-axis is the line where y is zero, so its equation is y = 0. The Y-axis is the line where x is zero, so its equation is x = 0. Ask yourself which coordinate stays fixed on the line, and that letter goes in the equation.
Equation of a Line Parallel to the X-axis
Let AB be a straight line parallel to the X-axis X'OX. It cuts the Y-axis at the point M, where OM = b. So M is the point (0, b). Take any point P(x, y) on AB and draw PN perpendicular to OX, meeting the X-axis at N.

Step 1: OMPN has four right angles, since AB is parallel to OX and both OM and PN are perpendicular to OX. So OMPN is a rectangle, and its opposite sides are equal:
\[ PN = OM \]
Step 2: Writing each length in coordinates. PN is the height of P above the X-axis, which is its y-coordinate, and OM is given as b:
\[ PN = y, \quad OM = b \]
Step 3: Putting these into PN = OM gives the value of y at P:
\[ y = b \]
Step 4: P was any point on AB, chosen freely. So the same holds everywhere on AB, and moving b to the left side gives the equation of the line:
\[ y - b = 0 \]
The equation of a straight line parallel to the X-axis is y = b, or y - b = 0, where b is the distance of the line from the X-axis. A line parallel to the X-axis is a horizontal line: every point on it is at the same height.
The number b carries a sign. If the line is above the X-axis, b is positive: the line 5 units above has equation y = 5. If the line is below the X-axis, b is negative: the line 5 units below has equation y = -5, which is y + 5 = 0. When b = 0 the line sits on the X-axis itself, and y = b becomes y = 0, the equation you already found for the X-axis.
Equation of a Line Parallel to the Y-axis
Let AB be a straight line parallel to the Y-axis YOY'. It cuts the X-axis at the point N, where ON = a. So N is the point (a, 0). Take any point P(x, y) on AB and draw PM perpendicular to OY, meeting the Y-axis at M.

Step 1: OMPN is a rectangle, because AB is parallel to OY and PM, ON are both perpendicular to OY. Its opposite sides PM and ON are equal, and PM is the distance of P from the Y-axis, which is its x-coordinate:
\[ ON = PM = x \]
Step 2: ON is also given as a:
\[ ON = a \]
Step 3: Both are the same length ON, so the value of x at P is a:
\[ x = a \]
Step 4: P is an arbitrary point on AB, so x equals a all along AB. Moving a to the left side gives the equation of the line:
\[ x - a = 0 \]
The equation of a straight line parallel to the Y-axis is x = a, or x - a = 0, where a is the distance of the line from the Y-axis. A line parallel to the Y-axis is a vertical line: every point on it is the same distance to the right or left.
Again a carries a sign. A line 3 units to the right of the Y-axis is x = 3. A line 3 units to the left is x = -3, or x + 3 = 0. When a = 0 the line is the Y-axis itself, and x = a becomes x = 0.
Horizontal and Vertical Lines Side by Side
| Line | What stays fixed | Equation | Example |
| X-axis | y is always 0 | y = 0 | (7, 0) lies on it |
| Y-axis | x is always 0 | x = 0 | (0, -4) lies on it |
| Parallel to X-axis (horizontal) | y is always b | y = b or y - b = 0 | y = 2 passes through (-6, 2) |
| Parallel to Y-axis (vertical) | x is always a | x = a or x - a = 0 | x = -1 passes through (-1, 9) |

Notice two things in the picture. First, a horizontal line never meets the X-axis and a vertical line never meets the Y-axis, because they are parallel to them. Second, any horizontal line and any vertical line cross at exactly one point. The lines x = 4 and y = 2 cross at (4, 2): at that point x must be 4 and y must be 2 at the same time.
A line parallel to the X-axis is written with y, not x. It is tempting to think "X-axis, so x = something", but a line parallel to the X-axis keeps the same height, and height is y. The same trap works the other way for lines parallel to the Y-axis.
Worked Examples
Example 1: Find the equation of the straight line parallel to the X-axis that passes through (4, -3).
Step 1: A line parallel to the X-axis has the form:
\[ y = b \]
Step 2: The point (4, -3) is on the line, so its y-coordinate must equal b:
\[ b = -3 \]
Step 3: Putting b = -3 into y = b and moving the number to the left side:
\[ y + 3 = 0 \]
The x-coordinate 4 plays no part. Every point of this line has y = -3, whatever its x.
Example 2: Find the equation of the straight line parallel to the Y-axis that passes through (-5, 2).
Step 1: A line parallel to the Y-axis has the form:
\[ x = a \]
Step 2: The point (-5, 2) is on the line, so its x-coordinate gives a:
\[ a = -5 \]
Step 3: Substituting and moving the number to the left side:
\[ x + 5 = 0 \]
Example 3: Find the equation of the straight line parallel to the Y-axis at a distance of 6 units to the left of it.
Step 1: To the left of the Y-axis, x-coordinates are negative, so every point of this line has x equal to -6:
\[ x = -6 \]
Step 2: Writing it with zero on the right side:
\[ x + 6 = 0 \]
Example 4: Find the equation of the straight line joining (2, 7) and (2, -4).
Step 1: Comparing the coordinates of the two points. The x-coordinates are equal:
\[ x_1 = x_2 = 2 \]
Step 2: Two points with the same x lie straight above one another, so the line through them is parallel to the Y-axis with a = 2. Its equation is:
\[ x - 2 = 0 \]
Quick check: if two points have the same y-coordinate, the line joining them is parallel to the X-axis. If they have the same x-coordinate, it is parallel to the Y-axis.
Example 5: Find the area of the rectangle bounded by the lines x = 0, y = 0, x = 5 and y = 4.
Step 1: Finding the corners where these lines meet. Each corner takes its x from a vertical line and its y from a horizontal line:
\[ (0, 0),\ (5, 0),\ (5, 4),\ (0, 4) \]
Step 2: The length runs along the X-axis from x = 0 to x = 5, and the breadth runs up from y = 0 to y = 4:
\[ l = 5, \quad b = 4 \]
Step 3: Multiplying length by breadth:
\[ A = 5 \times 4 = 20 \text{ sq. units} \]
Axes Equations Inside a Figure
Many problems draw a line cutting both axes and give only letters for the points where it cuts them. The equations of the axes tell you at once what those coordinates must look like. A point on the X-axis satisfies y = 0, so it is (a, 0). A point on the Y-axis satisfies x = 0, so it is (0, b). With that settled, the formulas you already know do the rest.
Example 6: A line cuts the X-axis at A and the Y-axis at B. P(2, 3) is the midpoint of AB. Find A and B, and show that OP = AP = BP.

Step 1: Since A lies on y = 0 and B lies on x = 0, write:
\[ A(a, 0), \quad B(0, b) \]
Step 2: Using the midpoint formula for the x-coordinate of P:
\[ \frac{a + 0}{2} = 2 \Rightarrow a = 4 \]
Step 3: Using the midpoint formula for the y-coordinate of P:
\[ \frac{0 + b}{2} = 3 \Rightarrow b = 6 \]
So A is (4, 0) and B is (0, 6).
Step 4: Finding OP with the distance formula from O(0, 0):
\[ OP = \sqrt{2^2 + 3^2} = \sqrt{13} \]
Step 5: Finding AP from A(4, 0):
\[ AP = \sqrt{(2 - 4)^2 + (3 - 0)^2} = \sqrt{13} \]
Step 6: Finding BP from B(0, 6):
\[ BP = \sqrt{(2 - 0)^2 + (3 - 6)^2} = \sqrt{13} \]
All three distances are \( \sqrt{13} \) units, so OP = AP = BP.
Example 7: A line cuts the X-axis at A(a, 0) and the Y-axis at B(0, b). The point P(4, 3) on it divides BA so that BP : PA = 2 : 1. Find a and b.

Step 1: P divides the segment from B(0, b) to A(a, 0) in the ratio m : n = 2 : 1. By the section formula, the x-coordinate of P is:
\[ \frac{2 \times a + 1 \times 0}{2 + 1} = 4 \]
Step 2: Multiplying both sides by 3 and dividing by 2:
\[ 2a = 12 \Rightarrow a = 6 \]
Step 3: The y-coordinate of P by the same formula:
\[ \frac{2 \times 0 + 1 \times b}{2 + 1} = 3 \]
Step 4: Multiplying both sides by 3:
\[ b = 9 \]
So a = 6 and b = 9, and the line cuts the axes at A(6, 0) and B(0, 9).
Example 8: The figure below shows O(0, 0), A(a, 0), C(a, b) and B(0, b). Name the line on which each side of OACB lies, and explain why OACB is a rectangle.

- (a) OA joins (0, 0) and (a, 0). Both have y = 0, so OA lies on the X-axis, y = 0.
- (b) OB joins (0, 0) and (0, b). Both have x = 0, so OB lies on the Y-axis, x = 0.
- (c) AC joins (a, 0) and (a, b). Both have x = a, so AC lies on the line x = a, parallel to the Y-axis.
- (d) BC joins (0, b) and (a, b). Both have y = b, so BC lies on the line y = b, parallel to the X-axis.
So OA and BC are both horizontal, and OB and AC are both vertical. Opposite sides are parallel, and every horizontal side meets every vertical side at a right angle, because the axes are perpendicular to each other. A quadrilateral with opposite sides parallel and all angles right angles is a rectangle. The corner C is simply the point where x = a and y = b meet.
The full lesson is waiting for you
The notes are free to read in full. A free account opens the rest of the practice, and tracks your progress and confidence score for every subject. Presentations and videos need approval from Learn Yeti.