Slope Calculator

Calculate slope, distance, and midpoint between two points.

Point 1
Point 2

Frequently Asked Questions

How is slope calculated?

Slope (m) = rise/run = (y2 - y1)/(x2 - x1). For points (2, 3) and (6, 11): m = (11 - 3)/(6 - 2) = 8/4 = 2. A positive slope rises left to right; negative slope falls. Slope of 0 is horizontal; undefined slope (division by 0) is vertical. The calculator handles all cases.

What is the distance formula?

Distance = sqrt((x2-x1)^2 + (y2-y1)^2). This is derived from the Pythagorean theorem — the distance between two points is the hypotenuse of a right triangle formed by the horizontal and vertical distances. For (1, 2) and (4, 6): d = sqrt(9 + 16) = sqrt(25) = 5.

How do I find the midpoint?

The midpoint is the average of the coordinates: ((x1+x2)/2, (y1+y2)/2). For points (2, 4) and (8, 10): midpoint = ((2+8)/2, (4+10)/2) = (5, 7). The midpoint is equidistant from both original points along the line connecting them.

What is slope-intercept form?

Slope-intercept form is y = mx + b, where m is the slope and b is the y-intercept (where the line crosses the y-axis). The calculator derives b from one of your points: b = y1 - m*x1. This form is the most commonly used equation of a line and is directly usable for graphing.

What does the visual graph show?

The graph plots both input points, draws the line through them, labels the slope (rise/run), marks the midpoint, and shows the line equation. It provides a visual confirmation of the calculated values and helps students understand the geometric meaning of slope, distance, and midpoint.