Distance, Midpoint and Slope – Coordinate Geometry Complete Guide

Learn the distance formula, midpoint, and slope in coordinate geometry. Includes step-by-step examples and proven tips for faster exam problem-solving.
Distance formula, midpoint formula, and slope explained with a coordinate geometry example graph.

What Are the Distance, Midpoint, and Slope Formulas?

These three formulas form the foundation of coordinate geometry. Before solving problems, understand what each one represents and how they connect.

  1. Distance Formula – d = √[(x₂ – x₁)² + (y₂ – y₁)²]
  2. Midpoint Formula – M = ((x₁ + x₂)/2, (y₁ + y₂)/2)
  3. Slope Formula – m = (y₂ – y₁)/(x₂ – x₁)

How the Distance Formula Comes from the Pythagorean Theorem

The distance formula is not a separate rule you need to memorise in isolation. It comes directly from the Pythagorean theorem, and understanding that connection makes it much easier to recall under pressure.

Picture any two points on a coordinate plane, say A(x₁, y₁) and B(x₂, y₂). Draw a horizontal line from A and a vertical line from B. They meet at a right angle, forming a right triangle where AB is the hypotenuse, the horizontal leg has length |x₂ – x₁|, and the vertical leg has length |y₂ – y₁|.

Applying the Pythagorean theorem gives AB² = (x₂ – x₁)² + (y₂ – y₁)².

If you know the Pythagorean theorem, you already know where this formula comes from.

Key tip

You do not need to decide which point is first and which is second. Because both differences are squared, the sign disappears either way. Subtract consistently across both coordinates.

Midpoint Formula Explained with Examples

The midpoint of a segment is the average of the x-coordinates and the average of the y-coordinates of the two endpoints. Adding each pair and dividing by two gives the value that sits exactly halfway between them in each direction.

M = ((x₁ + x₂)/2, (y₁ + y₂)/2)

Example 1. Proving a quadrilateral is a parallelogram

The vertices of quadrilateral ABCD are A(1, 2), B(7, 4), C(9, 8), and D(3, 6). Show that ABCD is a parallelogram by proving the diagonals bisect each other.

A quadrilateral is a parallelogram if and only if its diagonals share the same midpoint. Find the midpoint of each diagonal.

  • Midpoint of diagonal AC = ((1 + 9) / 2,  (2 + 8) / 2) = (5, 5)
  • Midpoint of diagonal BD = ((7 + 3) / 2,  (4 + 6) / 2) = (5, 5)
  • Both midpoints are (5, 5), so the diagonals bisect each other and ABCD is a parallelogram.

Key tip

A quadrilateral is a parallelogram if and only if its diagonals bisect each other (i.e., share the same midpoint). This property is very useful when proving a figure is a parallelogram or finding unknown coordinates.

The Slope Formula

Slope tells you how steep a line is and which direction it goes. The slope formula divides the vertical change by the horizontal change between any two points on the line.

m = (y₂ – y₁)/(x₂ – x₁)

The numerator is the rise and the denominator is the run. The ratio tells you how many units the line rises for every one unit it moves right.

Types of slope

  1. Positive slope  The line rises from left to right.
  2. Negative slope The line falls from left to right.
  3. Zero slope The line is perfectly horizontal. Rise = 0, so m = 0.
  4. Undefined slope The line is perfectly vertical. Run = 0, so slope is undefined.

Key tip

Horizontal lines are written as y = k and have a slope of 0. Vertical lines are written as x = k and have an undefined slope. Recognizing these special cases quickly saves time when working with slopes and equations of lines.

Slope-Intercept Form and Point-Slope Form

Two main forms are commonly used for writing the equation of a line.

1. Slope-intercept form

y = mx + b

Here m is the slope and b is the y-intercept. This form is useful when you need to read the slope or y-intercept directly from an equation.

2. Point-slope form

y – y₁ = m(x – x₁)

Here (x, y) is any known point on the line and m is the slope. Expand and solve for y to convert to slope-intercept form.

Key tip

Point-slope form is usually faster because you plug in the given point directly without solving for b. Use slope-intercept only when the y-intercept is specifically asked for.

Parallel and Perpendicular Lines

Parallel lines

Parallel lines have equal slopes.

m₁ = m₂

Two lines that never intersect run in exactly the same direction, so their slopes are identical. Their y-intercepts are different, otherwise they would be the same line.

Perpendicular lines

Perpendicular slopes are negative reciprocals.

m₁ × m₂ = -1

Two lines that meet at a right angle have slopes whose product equals -1. Flip the fraction and change the sign to find the negative reciprocal.

Key tip

Slope 4 becomes -1/4. Slope -2/5 becomes 5/2. The product of any slope and its negative reciprocal is always -1.

Example 1. Perpendicular line and its x-intercept

Line p has equation 3x + 4y = 12. Line q passes through (1, -2) and is perpendicular to p. Find the equation of q and the x-intercept of q.

Step 1. Find the slope of p by rewriting in slope-intercept form.

  • 4y = -3x + 12   so   y = (-3/4)x + 3
  • Slope of p = -3/4

Step 2. Find the slope of q using the negative reciprocal.

  • Slope of q = 4/3

Step 3. Write the equation of q through (1, -2).

  • y – (-2) = (4/3)(x – 1)
  • y + 2 = (4/3)x – 4/3
  • y = (4/3)x – 10/3

Step 4. Find the x-intercept by setting y = 0.

  • 0 = (4/3)x – 10/3
  • (4/3)x = 10/3   so   4x = 10   so   x = 5/2
  • x-intercept of q = (5/2, 0)

Finding the Equation of a Line Given Two Points

This three-step process combines the slope formula, point-slope form, and algebra.

Step 1. Calculate the slope using m = (y2 – y1) / (x2 – x1).

Step 2. Substitute the slope and one point into point-slope form.

Step 3. Expand and simplify into slope-intercept form if needed.

Example 2. Line through two points and its intersection with another line

Find the equation of the line through (-4, 5) and (2, -1). Then find where this line intersects y = 2x – 3.

Step 1. Find the slope.

  • m = (-1 – 5) / (2 – (-4)) = -6 / 6 = -1

Step 2. Write the equation using point (-4, 5).

  • y – 5 = -1(x – (-4)) = -1(x + 4)
  • y – 5 = -x – 4
  • y = -x + 1

Step 3. Find the intersection with y = 2x – 3 by substituting.

  • -x + 1 = 2x – 3
  • 1 + 3 = 3x   so   x = 4/3
  • y = 2(4/3) – 3 = 8/3 – 9/3 = -1/3
  • Intersection point = (4/3, -1/3)

Key tip

When two lines intersect, set the equations equal to each other and solve for x, then substitute back to get y. This two-step substitution is often faster than elimination.

Challenging Coordinate Geometry Questions with Step-by-Step Solutions

Question 1.

In the xy-plane, point A is at (2, 8) and point B is at (6, 2). The perpendicular bisector of segment AB intersects the y-axis at point C. What is the y-coordinate of point C?

A. 7/3 B. 5/3 C. 7 D. 3

Solution

Step 1. Find the midpoint of AB.

M = ((2 + 6) / 2,  (8 + 2) / 2) = (4, 5)

Step 2. Find the slope of AB.

m_AB = (2 – 8) / (6 – 2) = -6 / 4 = -3/2

Step 3. Find the slope of the perpendicular bisector.

m_perp = -1 / (-3/2) = 2/3

Step 4. Write the equation of the perpendicular bisector through M(4, 5).

y – 5 = (2/3)(x – 4)

Step 5. Set x = 0 to find where the line crosses the y-axis.

y – 5 = (2/3)(0 – 4) = -8/3

y = 5 – 8/3 = 15/3 – 8/3 = 7/3

Answer is A

Key rule

For any perpendicular bisector question, find the midpoint first, then flip and negate the original slope to get the perpendicular slope. Substitute the midpoint into point-slope form and set x = 0 to find the y-axis crossing.

Why the other choices are wrong

B (5/3) comes from subtracting 4/3 instead of 8/3 in the final step. C (7) comes from using slope 3/2 instead of 2/3 when finding the negative reciprocal. D (3) comes from using the midpoint y-value without completing the algebra.

Think10x.ai video explaining how to find the perpendicular bisector and its y-intercept

Question 2.

In the xy-plane, the vertices of triangle ABC are A(0, 0), B(8, 0), and C(4, 6). Point D is the midpoint of BC and point E is the midpoint of AC. What is the length of segment DE?

A. 2 B. 4 C. 5 D. 8

Solution

Step 1. Find D, the midpoint of BC.

B = (8, 0),  C = (4, 6)

D = ((8 + 4) / 2,  (0 + 6) / 2) = (6, 3)

Step 2. Find E, the midpoint of AC.

A = (0, 0),  C = (4, 6)

E = ((0 + 4) / 2,  (0 + 6) / 2) = (2, 3)

Step 3. Apply the distance formula to find DE.

DE = sqrt((6 – 2)^2 + (3 – 3)^2) = sqrt(16 + 0) = 4

Answer is B

Key rule

This question tests the Triangle Midsegment Theorem. The segment joining the midpoints of two sides of a triangle is parallel to the third side and exactly half its length. DE is parallel to AB and DE = AB / 2 = 8 / 2 = 4. Recognising this pattern lets you skip the distance formula entirely, but the midpoint-then-distance approach always works as a backup.

Why the other choices are wrong

A (2) comes from halving DE again, confusing the midsegment length with half of a half. C (5) comes from incorrectly treating the coordinates as two legs of a 3-4-5 triangle. D (8) is the full length of AB, not the midsegment connecting the two midpoints.

Think10x.ai video explaining how to find distance between midpoints of a triangle

Frequently Asked Questions

What is the difference between the distance formula and the midpoint formula?

The distance formula produces a single number representing the length of a segment between two points. The midpoint formula produces an ordered pair representing the point exactly halfway between two endpoints. Use the distance formula when a question asks how far apart two points are. Use the midpoint formula when a question asks for the center of a segment or a halfway location.

How do I find a missing endpoint when the midpoint is given?

Set up the midpoint formula as an equation for each coordinate separately. Multiply both sides by 2 to remove the fraction, then solve for the unknown. For example, if the midpoint x-coordinate is 4 and one endpoint x-coordinate is 1, write (1 + x) / 2 = 4, multiply to get 1 + x = 8, then x = 7. Repeat for y.

How do I remember when slope is zero versus undefined?

Horizontal lines have zero slope because the rise is zero and zero divided by any non-zero number is zero. Vertical lines have undefined slope because the run is zero and division by zero is undefined. A horizontal line is flat with no height change. A vertical line goes straight up with no horizontal movement at all.

What is the quickest way to check if two lines are perpendicular?

Multiply their slopes together. If the product equals a negative one, the lines are perpendicular. For example, slopes of 3 and negative one-third multiply to give negative one, confirming perpendicularity. This check takes about five seconds and works for any pair of non-vertical, non-horizontal lines.

When should I use point-slope form instead of slope-intercept form?

Use point-slope form whenever you know the slope and any point on the line that is not the y-intercept. It lets you write the equation in one step without solving for b. Switch to slope-intercept form when the question asks specifically for the y-intercept, or when you want to compare two lines written in the same format.

Can the distance formula ever give a negative answer?

No. Because both differences are squared before adding, the expression inside the square root is always non-negative. The distance formula always returns a positive value or zero when both points are identical. If you get a negative number, check that you squared each difference individually rather than just finding the absolute value of the differences before squaring.

Need Help with Your Own Question?

Upload a clear photo to Think10x.ai and get an instant video explanation. Built for tutors and students. Private by default.

Try Think10x.ai for free

TABLE OF CONTENTS