Calculators/Mathematics/Analytic geometry

Analytic geometry

Distance · midpoint · equation of a line · drawing

Analytic geometry — illustration
Point A
xy
Point B
xy
Distance |AB|5
Midpoint(3, 3.5)
Slope a0.75
Equation of line ABy = 0.75x + 1.25
Vector AB[4, 3]
AB

|AB| = √[(x_B−x_A)² + (y_B−y_A)²]. Midpoint: ((x_A+x_B)/2, (y_A+y_B)/2). Slope: a = (y_B−y_A)/(x_B−x_A).

Basic calculations on points in the coordinate plane. The distance between two points A(xA,yA)A(x_A,y_A) and B(xB,yB)B(x_B,y_B):

∣AB∣=(xB−xA)2+(yB−yA)2|AB|=\sqrt{(x_B-x_A)^2+(y_B-y_A)^2}

The midpoint of a segment is the average of the coordinates: S=(xA+xB2,yA+yB2)S=\left(\tfrac{x_A+x_B}{2},\tfrac{y_A+y_B}{2}\right). The slope of the line through these points: a=yB−yAxB−xAa=\dfrac{y_B-y_A}{x_B-x_A}, with its slope-intercept equation y=ax+by=ax+b.

The calculator draws both points, the segment and its midpoint on the coordinate plane.

Examples

A(1, 2), B(5, 5)
→ |AB| = 5, midpoint (3, 3.5), a = 0.75, y = 0.75x + 1.25
A(0, 0), B(3, 4)
→ |AB| = 5 (a 3-4-5 triangle)

Frequently asked questions

How do I find the equation of a line through two points?+

First the slope a = (y_B − y_A)/(x_B − x_A), then the intercept b by substituting one point into y = ax + b. The calculator returns the finished equation.

What if the points share the same x-coordinate?+

The line is vertical (x = const) and has no slope — the calculator detects this case and gives the equation in the form x = c.

Found this calculator useful? Share it.

It's free — send it to a friend who's revising.

Teaching? Embed this calculator on your site.

Free widget — paste it on your school site, blog or notes. It links to the full version.

Teaching a class or tutoring? Guide students in NexTutor →