Skip to content

Coordinate geometry: points, midpoints and distances

Coordinate geometry turns a diagram into algebra. A point is described by an ordered pair, and lengths and positions can be calculated exactly rather than estimated from a drawing.

These foundations support straight lines, circles, vectors, calculus and mechanics. The formulae are simple, but signs, subtraction order and exact values need care.

You should be able to:

  • work confidently with negative numbers;
  • substitute into formulae;
  • square integers and simplify square roots;
  • use Pythagoras’ theorem.

Review exact arithmetic, indices, roots and surds or Pythagoras and trigonometry if needed.

A point PP in the Cartesian plane has coordinates

P(x,y).P(x,y).

The first coordinate gives horizontal position and the second gives vertical position. Starting at the origin O(0,0)O(0,0):

  • positive xx means move right;
  • negative xx means move left;
  • positive yy means move up;
  • negative yy means move down.

Order matters. The points (2,5)(2,-5) and (5,2)(-5,2) are different.

The axes split the plane into four quadrants:

QuadrantSign of xxSign of yy
I++++
II-++
III--
IV++-

A point on an axis is not in any quadrant. For example, (0,4)(0,4) is on the yy axis and (3,0)(-3,0) is on the xx axis.

Let A(3,5)A(-3,5).

  1. Reflection in the xx axis changes the sign of the yy coordinate: (3,5)(3,5).(-3,5)\mapsto(-3,-5).
  2. Reflection in the yy axis changes the sign of the xx coordinate: (3,5)(3,5).(-3,5)\mapsto(3,5).
  3. Reflection in the origin changes both signs: (3,5)(3,5).(-3,5)\mapsto(3,-5).
  4. Reflection in the line y=xy=x swaps the coordinates: (3,5)(5,3).(-3,5)\mapsto(5,-3).

These rules follow from geometry. They are not all versions of “change the signs”.

Suppose

A(x1,y1),B(x2,y2).A(x_1,y_1),\qquad B(x_2,y_2).

Moving from AA to BB produces the signed changes

Δx=x2x1,Δy=y2y1.\boxed{\Delta x=x_2-x_1},\qquad \boxed{\Delta y=y_2-y_1}.

The symbol Δ\Delta means change in. A negative change is meaningful: it records leftward or downward movement.

Worked example 2: calculate a displacement

Section titled “Worked example 2: calculate a displacement”

For A(4,3)A(-4,3) and B(2,5)B(2,-5),

Δx=2(4)=6,\Delta x=2-(-4)=6,

and

Δy=53=8.\Delta y=-5-3=-8.

Thus the move from AA to BB is 66 units right and 88 units down. Reversing the journey reverses both signs:

B to A:Δx=6,Δy=8.B\text{ to }A:\qquad \Delta x=-6,\quad \Delta y=8.

This ordered change (Δx,Δy)(\Delta x,\Delta y) is also the vector from AA to BB. See vectors for vector notation and operations.

The midpoint lies halfway between the endpoints in both coordinate directions. For A(x1,y1)A(x_1,y_1) and B(x2,y2)B(x_2,y_2),

M(x1+x22,y1+y22).\boxed{M\left(\frac{x_1+x_2}{2},\frac{y_1+y_2}{2}\right)}.

This is simply the mean of the two xx coordinates and the mean of the two yy coordinates.

Find the midpoint of A(7,4)A(-7,4) and B(5,2)B(5,-2).

M=(7+52,4+(2)2)=(22,22)=(1,1).M=\left(\frac{-7+5}{2},\frac{4+(-2)}{2}\right) =\left(\frac{-2}{2},\frac{2}{2}\right) =(-1,1).

Check geometrically. From AA to MM the change is (6,3)(6,-3), and from MM to BB it is also (6,3)(6,-3). Therefore MM really is halfway along the segment.

Worked example 4: recover a missing endpoint

Section titled “Worked example 4: recover a missing endpoint”

The midpoint of A(3,4)A(3,-4) and B(x,y)B(x,y) is M(2,5)M(-2,5). Find BB.

Use each coordinate separately:

3+x2=23+x=4x=7,\frac{3+x}{2}=-2 \quad\Longrightarrow\quad 3+x=-4 \quad\Longrightarrow\quad x=-7, 4+y2=54+y=10y=14.\frac{-4+y}{2}=5 \quad\Longrightarrow\quad -4+y=10 \quad\Longrightarrow\quad y=14.

Hence

B(7,14).\boxed{B(-7,14)}.

A quicker check is that MA=(5,9)M-A=(-5,9), so B=M+(5,9)=(7,14)B=M+(-5,9)=(-7,14).

Common misconception: halve each coordinate

Section titled “Common misconception: halve each coordinate”

The midpoint of (2,8)(2,8) and (10,4)(10,4) is not (1,4)(1,4) or (5,2)(5,2). You must first add corresponding coordinates, then divide by 22:

(2+102,8+42)=(6,6).\left(\frac{2+10}{2},\frac{8+4}{2}\right)=(6,6).

The horizontal and vertical changes between A(x1,y1)A(x_1,y_1) and B(x2,y2)B(x_2,y_2) form the perpendicular sides of a right angled triangle. By Pythagoras’ theorem,

AB2=(x2x1)2+(y2y1)2.AB^2=(x_2-x_1)^2+(y_2-y_1)^2.

Since distance is non-negative,

AB=(x2x1)2+(y2y1)2.\boxed{AB=\sqrt{(x_2-x_1)^2+(y_2-y_1)^2}}.

Subtraction order does not affect the distance because each difference is squared. It is nevertheless safest to use one consistent order.

Worked example 5: calculate an exact distance

Section titled “Worked example 5: calculate an exact distance”

Find the distance between P(2,7)P(-2,7) and Q(4,1)Q(4,-1).

First find the coordinate changes:

Δx=4(2)=6,Δy=17=8.\Delta x=4-(-2)=6,\qquad \Delta y=-1-7=-8.

Then

PQ=62+(8)2=36+64=100=10.PQ=\sqrt{6^2+(-8)^2} =\sqrt{36+64} =\sqrt{100} =10.

The sign of 8-8 describes direction, but its contribution to length is (8)2=64(-8)^2=64.

Worked example 6: simplify a surd distance

Section titled “Worked example 6: simplify a surd distance”

Find the distance from A(1,2)A(-1,2) to B(5,7)B(5,7).

AB=(5(1))2+(72)2=62+52=61.AB=\sqrt{(5-(-1))^2+(7-2)^2} =\sqrt{6^2+5^2} =\sqrt{61}.

Because 6161 has no square factor greater than 11, 61\sqrt{61} is the exact answer. A decimal approximation is

617.81.\sqrt{61}\approx7.81.

Unless a question requests a decimal or stated accuracy, keep the exact surd.

If two points have the same yy coordinate, their separation is horizontal:

(x1,c) to (x2,c):x2x1.(x_1,c)\text{ to }(x_2,c):\qquad |x_2-x_1|.

If they have the same xx coordinate, their separation is vertical:

(c,y1) to (c,y2):y2y1.(c,y_1)\text{ to }(c,y_2):\qquad |y_2-y_1|.

The absolute value is necessary because a length cannot be negative.

Common misconception: adding coordinate changes

Section titled “Common misconception: adding coordinate changes”

For a move 33 units right and 44 units up, the straight line distance is not 3+4=73+4=7. That sum is the length of a route along the two perpendicular sides. The direct distance is

32+42=5.\sqrt{3^2+4^2}=5.

Midpoint is the special case of dividing a segment in the ratio 1:11:1. More generally, suppose PP divides the segment from A(x1,y1)A(x_1,y_1) to B(x2,y2)B(x_2,y_2) internally so that

AP:PB=m:n.AP:PB=m:n.

Then PP is the fraction mm+n\dfrac{m}{m+n} of the way from AA to BB:

P=A+mm+n(BA).P=A+\frac{m}{m+n}(B-A).

In coordinates,

P(nx1+mx2m+n,ny1+my2m+n).\boxed{P\left(\frac{nx_1+mx_2}{m+n},\frac{ny_1+my_2}{m+n}\right)}.

Notice the crossed weights. The coefficient of AA is nn, while the coefficient of BB is mm. The movement form is often easier to remember and less prone to error.

Points A(2,1)A(-2,1) and B(10,7)B(10,7) are joined. Point PP satisfies AP:PB=1:2AP:PB=1:2. Find PP.

Because the whole segment contains 1+2=31+2=3 equal parts, PP is one third of the way from AA to BB.

BA=(10(2),71)=(12,6).B-A=(10-(-2),7-1)=(12,6).

One third of this change is (4,2)(4,2), so

P=(2,1)+(4,2)=(2,3).P=(-2,1)+(4,2)=(2,3).

Check:

PA=(4,2),BP=(8,4)=2(4,2).P-A=(4,2),\qquad B-P=(8,4)=2(4,2).

Therefore AP:PB=1:2AP:PB=1:2, as required. A point in a 1:21:2 ratio is closer to AA, not closer to BB.

Using coordinates to prove geometric facts

Section titled “Using coordinates to prove geometric facts”

A diagram can suggest a result, but coordinate calculations can establish it. Useful tests include:

ClaimCoordinate evidence
Same pointboth coordinates are equal
Same midpointmidpoint formula gives identical coordinates
Equal lengthssquared distances are equal
Point lies on perpendicular bisector of ABABits distances from AA and BB are equal
Parallelogramdiagonals have the same midpoint
Isosceles triangletwo side lengths are equal

When comparing lengths, use squared distances. This avoids unnecessary square roots: for non-negative lengths, AB=ACAB=AC exactly when AB2=AC2AB^2=AC^2.

Worked example 8: prove a triangle is isosceles

Section titled “Worked example 8: prove a triangle is isosceles”

Let A(1,2)A(-1,2), B(5,4)B(5,4) and C(3,2)C(3,-2). Show that triangle ABCABC is isosceles.

Calculate squared side lengths:

AB2=(5(1))2+(42)2=62+22=40,AB^2=(5-(-1))^2+(4-2)^2=6^2+2^2=40, AC2=(3(1))2+(22)2=42+(4)2=32,AC^2=(3-(-1))^2+(-2-2)^2=4^2+(-4)^2=32, BC2=(35)2+(24)2=(2)2+(6)2=40.BC^2=(3-5)^2+(-2-4)^2=(-2)^2+(-6)^2=40.

Thus AB2=BC2AB^2=BC^2, so AB=BCAB=BC. Therefore

ABC is isosceles at B.\boxed{\triangle ABC\text{ is isosceles at }B.}

Naming the equal sides also identifies the vertex where they meet.

Worked example 9: prove a quadrilateral is a parallelogram

Section titled “Worked example 9: prove a quadrilateral is a parallelogram”

Let A(1,2)A(1,2), B(6,3)B(6,3), C(8,7)C(8,7) and D(3,6)D(3,6). Prove that ABCDABCD is a parallelogram.

The midpoint of diagonal ACAC is

(1+82,2+72)=(92,92).\left(\frac{1+8}{2},\frac{2+7}{2}\right) =\left(\frac92,\frac92\right).

The midpoint of diagonal BDBD is

(6+32,3+62)=(92,92).\left(\frac{6+3}{2},\frac{3+6}{2}\right) =\left(\frac92,\frac92\right).

The diagonals therefore bisect each other. Hence ABCDABCD is a parallelogram.

This argument proves more than a sketch could. It uses a defining property of parallelograms.

Worked example 10: find a point from equal distances

Section titled “Worked example 10: find a point from equal distances”

Point P(k,4)P(k,4) is equidistant from A(1,1)A(-1,1) and B(5,3)B(5,3). Find kk.

Equate squared distances:

PA2=(k+1)2+(41)2=(k+1)2+9,PA^2=(k+1)^2+(4-1)^2=(k+1)^2+9, PB2=(k5)2+(43)2=(k5)2+1.PB^2=(k-5)^2+(4-3)^2=(k-5)^2+1.

Therefore

(k+1)2+9=(k5)2+1.(k+1)^2+9=(k-5)^2+1.

Expand and simplify:

k2+2k+1+9=k210k+25+1,k^2+2k+1+9=k^2-10k+25+1, 2k+10=10k+26,2k+10=-10k+26, 12k=16,12k=16, k=43.\boxed{k=\frac43}.

The k2k^2 terms cancel because the set of points equidistant from two fixed points is a straight line, the perpendicular bisector of ABAB.

For a coordinate geometry problem:

  1. Label every point clearly.
  2. Identify the required object: a point, signed change, midpoint or length.
  3. Write the relevant formula before substituting.
  4. Keep one subtraction order throughout each calculation.
  5. Use brackets around negative coordinates.
  6. Keep exact surds unless approximation is requested.
  7. Check the result against the diagram’s broad geometry, but never trust a diagram as proof.

For example, writing 5(2)5-(-2) is safer than trying to manage two signs mentally.

Try these without looking back.

  1. In which quadrant is (6,1)(-6,-1)? What is its reflection in the yy axis?
  2. Find the signed horizontal and vertical changes from A(4,3)A(4,-3) to B(2,5)B(-2,5).
  3. Find the midpoint of P(8,7)P(-8,7) and Q(6,5)Q(6,-5).
  4. The midpoint of A(3,8)A(-3,8) and BB is (2,1)(2,1). Find BB.
  5. Find the exact distance between C(2,1)C(-2,-1) and D(4,7)D(4,7).
  6. Point RR is two fifths of the way from A(1,3)A(1,-3) to B(11,7)B(11,7). Find RR.
  7. Points X(0,1)X(0,1), Y(4,4)Y(4,4) and Z(7,0)Z(7,0) form a triangle. Show that it is isosceles.
  8. Point (t,0)(t,0) is equidistant from (2,3)(-2,3) and (4,1)(4,1). Find tt.
  1. Quadrant III. Reflection in the yy axis: (6,1)(6,-1).
  2. Δx=24=6\Delta x=-2-4=-6 and Δy=5(3)=8\Delta y=5-(-3)=8.
  3. (8+62,752)=(1,1)\left(\dfrac{-8+6}{2},\dfrac{7-5}{2}\right)=(-1,1).
  4. B=(2(2)(3),2(1)8)=(7,6)B=(2(2)-(-3),2(1)-8)=(7,-6).
  5. CD=62+82=10CD=\sqrt{6^2+8^2}=10.
  6. BA=(10,10)B-A=(10,10), so R=(1,3)+25(10,10)=(5,1)R=(1,-3)+\dfrac25(10,10)=(5,1).
  7. XY2=42+32=25XY^2=4^2+3^2=25 and YZ2=32+(4)2=25YZ^2=3^2+(-4)^2=25, so XY=YZXY=YZ.
  8. (t+2)2+9=(t4)2+1(t+2)^2+9=(t-4)^2+1, giving 12t=412t=4 and t=13t=\dfrac13.

Continue to straight-line graphs to turn coordinate changes into gradients and equations. Then study circle geometry, where distance from a fixed centre becomes the defining idea.

For the full A-level treatment, including perpendicular lines and intersections, see straight lines in coordinate geometry. Coordinate displacement also becomes more powerful in vectors.