straight-line distance between the two points (length)
x1
x-coordinate of the first point
y1
y-coordinate of the first point
x2
x-coordinate of the second point
y2
y-coordinate of the second point
The distance between two points is the longest side (the hypotenuse) of a right triangle whose other two sides are the horizontal gap and the vertical gap between the points.
Why it works
Draw a horizontal line from one point and a vertical line from the other; they meet at a right angle. The legs are (x2 − x1) and (y2 − y1), so Pythagoras gives the straight side between the points.
When to use it
You know the coordinates of both points and want how far apart they are in a straight line.
How to use it
Subtract the x-coordinates to get the horizontal gap.
Subtract the y-coordinates to get the vertical gap.
Square both gaps (the signs disappear).
Add the squares.
Take the square root.
To remember: Horizontal gap, vertical gap, Pythagoras.
Other forms
Same formula, another formd=(x1−x2)2+(y1−y2)2The order of subtraction does not matter, because squaring removes the sign.
Special cased=x2+y2When one of the points is the origin (0, 0).
Special cased=∣x2−x1∣When both points lie on the same horizontal line (y1 = y2).
Rearrangedd2=(x2−x1)2+(y2−y1)2Compare squared distances to avoid square roots when you only need to know which is longer.
Worked examples
Story
On a city map drawn in kilometres, the school is at (2, 3) and the library at (8, 11). How far apart are they in a straight line?
Horizontal gap: 8 − 2 = 6 km
Vertical gap: 11 − 3 = 8 km
d=62+82=36+64=100
d=10km
Answer: 10
Picture
Show that A(0, 0), B(3, 4) and C(6, 0) are the corners of an isosceles triangle.
AB=(3−0)2+(4−0)2=25=5
BC=(6−3)2+(0−4)2=25=5
AC=(6−0)2+(0−0)2=6
Two sides are equal (AB = BC = 5), so the triangle is isosceles.
Answer: AB = BC = 5, so ABC is isosceles
Direct
Find the distance between (1, 2) and (4, 6).
x2−x1=4−1=3
y2−y1=6−2=4
d=32+42=9+16=25
d=5
Answer: 5
Reverse
The point (x, 4) is 5 units from (1, 0). Find x.
Try it first, then show the working
(x−1)2+(4−0)2=52
(x−1)2+16=25
(x−1)2=9
x−1=3 or x−1=−3
x = 4 or x = −2
Answer: x = 4 or x = −2
Exam
Find the point on the x-axis that is the same distance from A(2, −5) and B(−2, 9).
Common mistake: Adding the gaps before squaring them, or subtracting in a mixed order such as x2 − y1. Squaring each gap first is what makes Pythagoras work.
Class 9
Midpoint formula
M=(2x1+x2,2y1+y2)
What each letter means
M
the midpoint: the point exactly halfway between the two points
x1
x-coordinate of the first point
y1
y-coordinate of the first point
x2
x-coordinate of the second point
y2
y-coordinate of the second point
The midpoint is halfway along in both directions at once, so each of its coordinates is the average of the two matching coordinates.
Why it works
Going from the first point to the second, x changes by x2 − x1. Half of that change added to x1 lands exactly halfway, and x1 + (x2 − x1) ÷ 2 simplifies to (x1 + x2) ÷ 2. The same happens for y, on its own, because moving across does not change how far up you are.
When to use it
You know both ends of a line segment and want the point exactly in the middle; or you know one end and the middle and want the other end.
How to use it
Add the two x-coordinates and halve the sum.
Add the two y-coordinates and halve the sum.
Write the two results as a pair (x, y): that is the midpoint.
To remember: Midpoint means average. Average the xs, then average the ys.
Other forms
Same formula, another formM=(x1+2x2−x1,y1+2y2−y1)Start at the first point and go half of the way to the second. It gives the same point.
Special caseM=(2x2,2y2)When the first point is the origin (0, 0).
RearrangedB=(2p−x1,2q−y1)When you know one end A (x1, y1) and the midpoint M (p, q), and want the other end B.
Worked examples
Story
On a town map drawn in kilometres, the school is at (−2, 3) and the library is at (6, 9). A bus stop is to be built exactly halfway between them. Where should it go?
x=2−2+6=24=2
y=23+9=212=6
The bus stop goes at (2, 6). Check: from the school it is 4 km across and 3 km up, and from there to the library it is another 4 km across and 3 km up.
Answer: (2, 6)
Picture
The corners of a four-sided shape are A (0, 0), B (4, 0), C (6, 3) and D (2, 3). Show that its diagonals AC and BD cut each other exactly in half.
MAC=(20+6,20+3)=(3,23)
MBD=(24+2,20+3)=(3,23)
Both diagonals have the same midpoint, (3, 1.5). So each diagonal passes through the middle of the other: they cut each other in half.
Answer: Both midpoints are (3, 1.5), so the diagonals cut each other in half
Direct
Find the midpoint of A (2, 4) and B (8, 6).
x=22+8=210=5
y=24+6=210=5
M=(5,5)
Answer: (5, 5)
Reverse
M (−7, 1) is the midpoint of A (3, −4) and B (x, y). Find B.
Try it first, then show the working
23+x=−7
3+x=−14
x=−17
2−4+y=1
−4+y=2
y=6
So B is (−17, 6). Check: from A to M is 10 left and 5 up, and from M to B is another 10 left and 5 up.
Answer: B (−17, 6)
Exam
D (5, 1), E (6, 5) and F (0, 3) are the midpoints of the sides BC, CA and AB of triangle ABC. Find A, B and C.
Try it first, then show the working
D is the midpoint of BC, so B + C = 2D, working with x and y separately. In the same way C + A = 2E and A + B = 2F. Adding all three gives 2(A + B + C) = 2(D + E + F), so A + B + C = D + E + F.
A+B+C=(5+6+0,1+5+3)=(11,9)
A=(11−2×5,9−2×1)=(1,7)
B=(11−2×6,9−2×5)=(−1,−1)
C=(11−2×0,9−2×3)=(11,3)
Check: the midpoint of B and C is ((−1 + 11) ÷ 2, (−1 + 3) ÷ 2) = (5, 1), which is D.
Answer: A (1, 7), B (−1, −1), C (11, 3)
Common mistake: Subtracting instead of adding (that gives half the gap between the points, not the point halfway along), or mixing an x-coordinate with a y-coordinate.
Class 9
Equation of a straight line (slope and y-intercept)
y=ax+b
What each letter means
y
the y-coordinate of a point on the line
x
the x-coordinate of the same point
a
the slope: how much y goes up (or down, if a is negative) each time x goes up by 1
b
the y-intercept: where the line crosses the y-axis, the value of y when x = 0
Every straight line that is not upright can be written as y = ax + b. The number a says how steep the line is and which way it tilts, and b says where it crosses the y-axis.
Why it works
In a linear relationship, each step of 1 in x changes y by the same amount a. Start at the y-axis, where x = 0 and y = b, and take x steps of size 1; y has then changed by a × x, so y = b + ax.
When to use it
A quantity starts at a fixed value and changes by the same amount for each unit of another (a fixed charge plus a rate, a height that grows by the same amount each week), or you need the line through given points.
How to use it
Find b, the value of y when x = 0.
Find a, how much y changes when x goes up by 1.
Write y = ax + b, then put in any x to get its y (or any y and solve for x).
To remember: a is the step, b is the start: y = step × x + start.
Other forms
Special casey=axWhen b = 0: the line passes through the origin (0, 0).
Special casey=bWhen a = 0: the line is flat (parallel to the x-axis).
Rearrangedx=ay−bTo find x for a given y (a must not be 0).
Rearrangedb=y−axTo find the y-intercept from the slope and one point on the line.
Same formula, another formLater books write y = mx + c: m is the slope (our a) and c is the y-intercept (our b). It is the same line.
Worked examples
Story
A taxi charges a fixed ₹50 plus ₹12 for each kilometre, so the fare is y = 12x + 50 rupees for x km. How much is a 15 km ride?
y=12×15+50
=180+50=230
The ride costs ₹230.
Answer: 230
Picture
Where does the line y = 2x − 4 cross the x-axis and the y-axis? What is the area of the triangle it makes with the two axes?
On the y-axis x = 0, so y = 2 × 0 − 4 = −4: the point (0, −4).
On the x-axis y = 0, so 2x − 4 = 0, which gives x = 2: the point (2, 0).
The triangle has a base of 2 along the x-axis and a height of 4 along the y-axis.
21×2×4=4
Answer: It crosses at (2, 0) and (0, −4); the triangle's area is 4 square units
Direct
For the line y = 3x − 2, find y when x = 4.
y=3×4−2
=12−2=10
Answer: 10
Reverse
On the line y = 5x + 7, which value of x gives y = 42?
Try it first, then show the working
5x+7=42
5x=35
x=7
Answer: 7
Exam
The cost y (in rupees) of x GB of mobile data follows y = ax + b. 10 GB costs ₹350 and 20 GB costs ₹550. Find a and b, and say what each one means.
Try it first, then show the working
350=10a+b
550=20a+b
Subtracting the first line from the second: 200 = 10a, so a = 20.
Putting a = 20 in the first line: 350 = 200 + b, so b = 150.
So y = 20x + 150: each GB costs ₹20 (the slope), on top of a fixed ₹150 (the y-intercept).
Answer: a = 20, b = 150
Common mistake: Swapping the roles of a and b (b is the starting value, a is the change for each step), or forgetting that a negative a means the line falls from left to right.
Class 10
Section formula (the point dividing a segment in a ratio)
P=(m1+m2m1x2+m2x1,m1+m2m1y2+m2y1)
What each letter means
P
the point that divides AB in the ratio m1 : m2 (AP : PB = m1 : m2)
m1
the first part of the ratio (the share next to A)
m2
the second part of the ratio (the share next to B)
x1
x-coordinate of A
y1
y-coordinate of A
x2
x-coordinate of B
y2
y-coordinate of B
The point that splits AB in the ratio m1 : m2 is a weighted average of the ends: each end is weighted by the part of the ratio on the far side, so the point sits closer to the end with the smaller share.
Why it works
Drop perpendiculars from A, P and B to the x-axis. The three feet cut the x-axis in the same ratio as P cuts AB (parallel lines cut every transversal in the same ratio). So (x − x1) : (x2 − x) = m1 : m2, which solves to x = (m1x2 + m2x1) ÷ (m1 + m2); the y-coordinate works the same way.
When to use it
Finding a point a given fraction of the way along a segment (points of trisection, a fuel station twice as far from one town as the other), or finding the ratio in which a point or an axis divides a segment.
How to use it
Write the ratio as m1 : m2, with m1 next to A.
x = (m1 × x2 + m2 × x1) ÷ (m1 + m2): each part of the ratio multiplies the far end.
Do the same for y, then write the pair (x, y).
To remember: Cross over: m1 with the far end B, m2 with the far end A.
Other forms
Special caseP=(2x1+x2,2y1+y2)When m1 = m2: the midpoint.
Same formula, another formWith the ratio written k : 1 (k = m1 ÷ m2), the point is ((kx2 + x1) ÷ (k + 1), (ky2 + y1) ÷ (k + 1)): one unknown instead of two when the ratio is what you want.
Worked examples
Story
A straight road runs from town A at (0, 0) to town B at (12, 9), in kilometres. A fuel station is to be built on it twice as far from A as from B. Where should it go?
Twice as far from A as from B means AP : PB = 2 : 1.
x=32×12+1×0=8
y=32×9+1×0=6
Answer: (8, 6)
Picture
Find the points of trisection of the segment from A (2, −2) to B (−7, 4): the two points that cut it into three equal parts.
P is one third of the way from A, so AP : PB = 1 : 2; Q is two thirds of the way, so AQ : QB = 2 : 1.
P=(31×(−7)+2×2,31×4+2×(−2))=(−1,0)
Q=(32×(−7)+1×2,32×4+1×(−2))=(−4,2)
Answer: (−1, 0) and (−4, 2)
Direct
Find the point that divides the segment joining (4, −3) and (8, 5) in the ratio 3 : 1.
x=3+13×8+1×4=428=7
y=3+13×5+1×(−3)=412=3
Answer: (7, 3)
Reverse
In what ratio does the point (−4, 6) divide the segment joining A (−6, 10) and B (3, −8)?
Try it first, then show the working
Let the ratio be k : 1. Then the x-coordinate gives −4 = (3k − 6) ÷ (k + 1).
−4k−4=3k−6
7k=2
So k : 1 = 2 : 7. Check with y: (−8 × 2 + 10 × 7) ÷ 9 = 54 ÷ 9 = 6.
Answer: 2 : 7
Exam
In what ratio does the y-axis divide the segment joining (5, −6) and (−1, −4)? Find the point where they meet.
Try it first, then show the working
On the y-axis x = 0. With the ratio k : 1: (−k + 5) ÷ (k + 1) = 0, so k = 5; the ratio is 5 : 1.
y=65×(−4)+1×(−6)=6−26=−313
The point is (0, −13/3).
Answer: 5 : 1, at (0, −13/3)
Common mistake: Pairing m1 with x1 instead of x2. The share next to A multiplies B's coordinate, which is why the point ends up nearer A when m1 is small.