Centroid Formula (and How It Differs from a Midpoint)

The centroid is the average of several points: for a triangle, ((x₁+x₂+x₃)/3, (y₁+y₂+y₃)/3). How it differs from a midpoint, with worked examples.

You Just Averaged Three Points. That Is a Centroid, Not a Midpoint

You have three meeting points on a map, so you average the latitudes and longitudes and call it the “midpoint.” That single action is the most common geometry error on the web. The average of three or more coordinate pairs is the centroid of the point set, not a midpoint. The centroid formula for a set of points is the arithmetic mean of their coordinates, but the term “midpoint” belongs exclusively to a line segment between two endpoints. The centroid formula for triangles and point sets differs from a midpoint, and the calculator returns a centroid when you enter three or more locations.

Midpoint vs. Centroid: The Two-Point Rule

A midpoint is the exact center of a line segment. It exists only between two defined endpoints. The 2D formula is M = ((x1 + x2)/2, (y1 + y2)/2). For 3D, add the z-coordinate in the same way. The midpoint is a ratio division at exactly 1:1. Any other ratio, 2:1, 3:1, produces a different point on the segment, not the midpoint.

A centroid is the average of all points in a set. For three points, that average is the centroid of the triangle formed by them. For ten points, it is the centroid of that point cloud. The centroid formula for n points is C = ( (x1 + x2 + ... + xn)/n , (y1 + y2 + ... + yn)/n ). The key rule: exactly two points give a midpoint; three or more give a centroid. If you enter three coordinates into a midpoint calculator, it silently computes a centroid, a different geometric concept, and labels it incorrectly.

Centroid of a Triangle: Formula and Medians

The centroid of a triangle is the intersection point of its three medians. A median is a line segment from a vertex to the midpoint of the opposite side. The centroid is also the triangle's center of mass, assuming uniform density. The formula is direct: given vertices A(x1, y1), B(x2, y2), C(x3, y3), the centroid is C = ((x1 + x2 + x3)/3, (y1 + y2 + y3)/3).

Why the Medians Matter

Each median passes through the centroid, and the centroid divides each median in a 2:1 ratio, two parts from vertex to centroid, one part from centroid to the midpoint of the opposite side. This property is why the centroid is the balance point: the triangle balances exactly on a pin placed at the centroid. If you cut the triangle from a uniform sheet of material, it would balance at that single point.

The Medians Diagram

Draw triangle ABC. From vertex A, draw a line to the midpoint of side BC. From vertex B, draw a line to the midpoint of side AC. From vertex C, draw a line to the midpoint of side AB. The three lines intersect at a single point, the centroid. The lines themselves are the medians. The centroid is always inside the triangle, unlike the circumcenter or orthocenter, which can fall outside for obtuse triangles.

Centroid of n Points

The centroid of a set of n points in a plane is the arithmetic mean of all x-coordinates and all y-coordinates. This is sometimes called the average of points, the arithmetic mean center, or the centroid of a point set. For points in 3D, add the z-coordinate. The formula generalises to any number of dimensions: C = (1/n) * Σ of each coordinate vector.

What This Actually Means

If you have five restaurant locations on a map, the centroid of those five points is the point that minimises the sum of squared distances to each location. That is not necessarily the most convenient meeting point, travel time depends on roads, not straight lines, but it is the geometric center of the set. The calculator returns this arithmetic mean when you enter three or more points.

Critical failure case: If the points are collinear (all lie on one straight line), the centroid still exists as a point on that line, but the “centroid of the triangle” is undefined because three collinear points do not form a triangle. The polygon area-centroid formula fails here because the area A equals zero, and division by zero yields an undefined result. Always check collinearity before applying polygon formulas.

Worked Examples: Centroid and Midpoint in Practice

Example 1: Centroid of a Triangle

Find the centroid of triangle with vertices A(2, 3), B(6, 1), C(4, 5). Use the centroid formula for a triangle: C_x = (2 + 6 + 4)/3 = 12/3 = 4. C_y = (3 + 1 + 5)/3 = 9/3 = 3. The centroid is at (4, 3). Now verify: The midpoint of side BC is ((6+4)/2, (1+5)/2) = (5, 3). The median from A to that midpoint is the line from (2, 3) to (5, 3). The centroid (4, 3) lies on that line. The midpoint of side AC is ((2+4)/2, (3+5)/2) = (3, 4). The median from B to that midpoint is the line from (6, 1) to (3, 4). The centroid (4, 3) also lies on that line. All three medians intersect at (4, 3).

Example 2: Centroid of Four Points (and Why It Is Not a Midpoint)

Find the centroid of points P(1, 1), Q(4, 2), R(2, 5), S(5, 3). Add the x-coordinates: 1 + 4 + 2 + 5 = 12. Divide by 4: C_x = 3. Add the y-coordinates: 1 + 2 + 5 + 3 = 11. Divide by 4: C_y = 2.75. The centroid is at (3, 2.75). None of these points are endpoints of a single line segment, so there is no midpoint. Calling (3, 2.75) a “midpoint of the four points” is wrong. It is the average of points, the centroid of the point set.

Note on Polygons: Area Centroid Differs

The polygon area-centroid formula is different from the centroid of a point set. For a simple polygon with vertices listed in order (counterclockwise or clockwise), the centroid is weighted by area, not by vertex count. The formulas, from Weisstein’s “Geometric Centroid” on MathWorld, use a signed area A: A = (1/2) * Σ (x_i * y_{i+1} - x_{i+1} * y_i). Then C_x = (1/(6A)) * Σ ((x_i + x_{i+1}) * (x_i * y_{i+1} - x_{i+1} * y_i)), and C_y = (1/(6A)) * Σ ((y_i + y_{i+1}) * (x_i * y_{i+1} - x_{i+1} * y_i)).

This formula applies only to non-self-intersecting polygons with vertices in order. It is undefined for collinear points (A = 0). The arithmetic mean of three to five points is sometimes called the “centroid of the polygon,” but this is accurate only if it is specified as the centroid of the point set, not of the polygon itself. If your points do not form a closed shape, use the arithmetic mean formula, not the polygon formula.

Common Questions

What is the centroid formula for a triangle?

The centroid of a triangle is found by averaging the x-coordinates and y-coordinates of its three vertices: C = ((x1 + x2 + x3)/3, (y1 + y2 + y3)/3). This point is the intersection of the three medians.

How do I know if I should use a midpoint or a centroid?

Count the number of points. Exactly two points: use the midpoint formula. Three or more points: use the centroid formula. The midpoint is for line segments; the centroid is for point sets or polygons.

Can three collinear points have a centroid?

Three collinear points have a centroid as a point set (the average of their coordinates), but they do not form a triangle, so the polygon area-centroid formula is undefined because the area is zero. The term 'centroid of the triangle' is meaningless for collinear points.

What does the calculator return when I enter three points?

It returns the centroid of those three points, the arithmetic mean of their coordinates. It is not a midpoint. The calculator labels it as the centroid when three or more points are entered.

Why is the centroid of a polygon different from the average of its vertices?

The polygon area-centroid formula weights each vertex by the area of the triangles formed with adjacent vertices.For irregular polygons, the area centroid shifts toward larger-area sections.