Center of mass calculator for up to four masses

This center of mass calculator uses the formula from OpenStax University Physics: x = Σ m·x / Σ m and y = Σ m·y / Σ m. Example: 2 kg at (0; 0), 1 kg at (3; 0) and 1 kg at (0; 3) have their centre of mass at (0.75; 0.75).

Source: OpenStax University Physics Volume 1, 9.6 Center of Mass: r_CM = (1/M) Σ m_j r_j, components x and y (Eq. 9.30–9.32); Example 9.16 Earth–Moon: 5.97 × 10²⁴ kg, 7.36 × 10²² kg, 3.82 × 10⁸ m (read 10.10.2026). Updated: .

0 = not used
0 = not used
0 = not used
0 = not used
My ToolboxYour inputs are saved in this browser only.

Result

Centre of mass
x = 0.75, y = 0.75
Calculation
Pointm(x; y)m · xm · y
Mass 12(0; 0)00
Mass 21(3; 0)30
Mass 31(0; 3)03
Sum433
Centre of mass(0.75; 0.75)3 ÷ 43 ÷ 4
Calculated with x = Σ m·x / Σ m and y = Σ m·y / Σ m. Any unit works, as long as all masses and all coordinates use the same one.

How it is calculated

The centre of mass is the mass-weighted average of all positions. OpenStax writes it as r = (1/M) Σ m·r, which splits into one formula per axis: x = Σ m·x / Σ m and y = Σ m·y / Σ m. Heavy masses pull the result towards them; the centre of mass can lie where there is no mass at all.

Worked examples

Masses and positionsCentre of mass
30 kg at x = 0 m, 60 kg at x = 3 m (seesaw)x = 2 m
2 kg (0; 0), 1 kg (3; 0), 1 kg (0; 3)(0.75; 0.75)
L-shape: 20 cm² at (1; 5), 16 cm² at (6; 1)(3.22; 3.22)
Earth 5.97 × 10²⁴ kg at 0, Moon 7.36 × 10²² kg at 3.82 × 10⁸ m4.65 × 10⁶ m from Earth’s centre

The seesaw: (30 · 0 + 60 · 3) / 90 = 180 / 90 = 2 m, so the balance point is 2 m from the lighter child. In OpenStax Example 9.16 the Earth–Moon centre lies inside the Earth. The book prints 4.64 × 10⁶ m; recalculated with its own data the value is 4.65 × 10⁶ m, i.e. about 1720 km below the surface (6.37 × 10⁶ m − 4.65 × 10⁶ m).

Centroid of a composite shape

For a flat plate of uniform thickness and material, mass is proportional to area. Split the shape into rectangles or triangles, enter each part’s area as the “mass” and its own centre as the position. The L-shape above consists of a 2 × 10 bar (centre (1; 5)) and an 8 × 2 bar (centre (6; 1)); both coordinates come out as 116 / 36 = 3.22 because the shape is symmetric about the diagonal. The centre of a single triangle is given by the triangle centroid calculator; how mass is distributed around an axis is measured by the moment of inertia calculator.

Frequently asked questions

What is the formula for the centre of mass?

x = Σ m·x / Σ m and y = Σ m·y / Σ m – multiply each mass by its coordinate, add up and divide by the total mass.

Where is the balance point of 30 kg and 60 kg on a 3 m seesaw?

2 m from the 30 kg end: (60 · 3) / 90 = 2.

Can I use it for a composite area?

Yes. Enter the part areas instead of masses and the centre of each part as its position. This holds for plates of uniform thickness and material.

Where is the centre of mass of Earth and Moon?

About 4.65 × 10⁶ m from the Earth’s centre, inside the Earth. OpenStax prints 4.64 × 10⁶ m.

Which units should I use?

Any, as long as they are consistent: all masses in kg (or all areas in cm²), all coordinates in the same length unit. The result has that length unit.

Can the centre of mass be outside the object?

Yes. For an L-shape or a ring it lies where there is no material – OpenStax notes that no mass needs to be at the centre of mass.

Sources and legal basis

As of: · Editorial policy

Related tools