Vector and Coordinate Geometry Formulas

Operations with vectors and coordinates in the plane and in space: sum and difference, length, dot product, the angle between vectors, the distance between points, the midpoint of a segment, the slope of a line and the distance from a point to a line.

14 formulas · Grades 8–11

All 14 formulas on this page
  1. Distance between two points
  2. Midpoint of a segment (coordinates)
  3. Dot product of vectors
  4. Length of a vector from its coordinates
  5. Sum of vectors by coordinates
  6. Cosine of the angle between vectors (2D)
  7. Slope of a line through two points
  8. Distance from a point to a line
  9. Radius of a circle from its equation
  10. Difference of vectors by coordinates
  11. Dot product of vectors (via magnitudes and angle)
  12. Angle between vectors in space
  13. Length of a vector in space
  14. Distance between two points in space

Distance between two points

Grade 8
d=(x2−x1)2+(y2−y1)2d = \sqrt{(x_2-x_1)^2 + (y_2-y_1)^2}

Length of the segment between two points on the coordinate plane.

ABd
d is the distance between points A and B in the plane.
Legend:
  • 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

Midpoint of a segment (coordinates)

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

Coordinates of the point bisecting a segment.

ABM
M is the midpoint of segment AB.
Legend:
  • 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

Dot product of vectors

Grade 9
a⃗⋅b⃗=x1x2+y1y2\vec{a} \cdot \vec{b} = x_1 x_2 + y_1 y_2

Dot product of two 2D vectors from their coordinates.

ab
The dot product is calculated from the vectors' coordinates.
Legend:
  • x1 — x-coordinate of the first vector
  • y1 — y-coordinate of the first vector
  • x2 — x-coordinate of the second vector
  • y2 — y-coordinate of the second vector

Length of a vector from its coordinates

Grade 9
∣a⃗∣=x2+y2|\vec{a}| = \sqrt{x^2 + y^2}

Length (magnitude) of a vector in the plane.

xy
The vector's length follows from the Pythagorean theorem on its coordinates.
Legend:
  • x — Coordinate x
  • y — Coordinate y

Sum of vectors by coordinates

Grade 9
a⃗+b⃗=(ax+bx, ay+by)\vec{a}+\vec{b} = (a_x+b_x,\ a_y+b_y)

Adding vectors coordinate-wise.

aba+b
Vectors are added by the 'triangle rule'.
Legend:
  • a_x — x-coordinate of vector a
  • a_y — y-coordinate of vector a
  • b_x — x-coordinate of vector b
  • b_y — y-coordinate of vector b

Cosine of the angle between vectors (2D)

Grade 9
cos⁡φ=a⃗⋅b⃗∣a⃗∣∣b⃗∣\cos\varphi = \frac{\vec a \cdot \vec b}{|\vec a||\vec b|}

Cosine of the angle between two vectors in the plane from their coordinates.

α
Cosine of the angle between vectors in the plane.
Legend:
  • a_x — x-coordinate of vector a
  • a_y — y-coordinate of vector a
  • b_x — x-coordinate of vector b
  • b_y — y-coordinate of vector b

Slope of a line through two points

Grade 9
k=y2−y1x2−x1k = \frac{y_2-y_1}{x_2-x_1}

Slope of the line passing through two given points.

ΔxΔy
k is the ratio of the change in y to the change in x.
Legend:
  • 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

Distance from a point to a line

Grade 9
d=∣Ax0+By0+C∣A2+B2d = \frac{|Ax_0+By_0+C|}{\sqrt{A^2+B^2}}

Shortest distance from a point to a line given by Ax + By + C = 0.

Md
d is the shortest (perpendicular) distance from the point to the line.
Legend:
  • A — Coefficient a
  • B — Coefficient b
  • C — Coefficient c
  • x0 — Coordinate x0
  • y0 — Coordinate y0

Radius of a circle from its equation

Grade 9
r=(x−a)2+(y−b)2r = \sqrt{(x-a)^2+(y-b)^2}

Radius of a circle centred at (a, b) passing through the point (x, y).

r(a, b)(x, y)
The circle's centre is at (a, b), the point (x, y) lies on it.
Legend:
  • x0 — Coordinate x0
  • y0 — Coordinate y0
  • x — Coordinate x
  • y — Coordinate y

Difference of vectors by coordinates

Grade 9
a⃗−b⃗=(ax−bx, ay−by)\vec a-\vec b = (a_x-b_x,\ a_y-b_y)

Subtracting vectors coordinate-wise.

aba−b
The vector difference points from the tip of b to the tip of a.
Legend:
  • ax — a_x
  • ay — a_y
  • bx — b_x
  • by — b_y

Dot product of vectors (via magnitudes and angle)

Grade 9
A⃗⋅B⃗=∣a⃗∣⋅∣b⃗∣⋅cos⁡α\vec{A} \cdot \vec{B} = |\vec a| \cdot |\vec b| \cdot \cos\alpha

Dot product of vectors through their lengths and the angle between them.

αab
α is the angle between vectors a and b.
Legend:
  • a — Magnitude of vector a (|a|)
  • b — Magnitude of vector b (|b|)
  • alpha — Angle α (deg)

Angle between vectors in space

Grade 11
cos⁡θ=x1x2+y1y2+z1z2∣a⃗∣⋅∣b⃗∣\cos \theta = \frac{x_1 x_2 + y_1 y_2 + z_1 z_2}{|\vec{a}| \cdot |\vec{b}|}

Cosine of the angle between two 3D vectors from their coordinates.

α
The angle between vectors in three-dimensional space.
Legend:
  • a_x — x-coordinate of the first vector
  • a_y — y-coordinate of the first vector
  • a_z — z-coordinate of the first vector
  • b_x — x-coordinate of the second vector
  • b_y — y-coordinate of the second vector
  • b_z — z-coordinate of the second vector

Length of a vector in space

Grade 11
∣a⃗∣=x2+y2+z2|\vec a| = \sqrt{x^2+y^2+z^2}

Length (magnitude) of a vector in 3D space from its coordinates.

xyz
In space, a third coordinate z is added.
Legend:
  • x — a_x
  • y — a_y
  • z — a_z

Distance between two points in space

Grade 11
AB=(x2−x1)2+(y2−y1)2+(z2−z1)2AB = \sqrt{(x_2-x_1)^2+(y_2-y_1)^2+(z_2-z_1)^2}

Length of the segment between two points in 3D space.

ABd
The distance between points in three-dimensional space.
Legend:
  • x1 — x-coordinate of the first point
  • y1 — y-coordinate of the first point
  • z1 — z-coordinate of the first point
  • x2 — x-coordinate of the second point
  • y2 — y-coordinate of the second point
  • z2 — z-coordinate of the second point