Logo

MonoCalc

/

Center of Mass Calculator

Physics
Center of mass, not center of gravity
Gravity never enters this calculation. g cancels out of the weighted average, which is why the center of mass and the center of gravity coincide in any uniform gravitational field — and why no gravity value is asked for anywhere below.
LabelMass (kg)x (m)y (m)

Worked examples

One object per line as mass, x, y, z — extra axes are ignored when they are switched off.
Center of mass
(2.333, 3.000) m
Total mass M
6.000 kg
Distance from origin
3.801 m
Objects in the system
3

System diagram — marker area scales with mass

Each object drawn at its coordinates with dashed moment arms running to the computed center of massm₁m₂m₃COM (2.333, 3.000) m

First moments and per-object contributions

ObjectMass (kg)m·x (kg·m)m·y (kg·m)ShareDistance to COM
m₁1.0000.0000.0000.0 %3.801 m
m₂2.0008.0000.00025.0 %3.432 m
m₃3.0006.00018.00075.0 %3.018 m
Total6.00014.00018.000100.0 %

Moment of inertia and the parallel-axis theorem

Distance from the COM axis to the axis you want the inertia about. Leave blank to use the origin.
I about the COM axis (Σmᵢdᵢ²)65.333 kg·m²
Offset d used3.801 m
I = I_cm + M·d² about the parallel axis152.000 kg·m²
Direct check Σmᵢrᵢ² about the same axis152.000 kg·m²

The two routes agree exactly, which is the parallel-axis theorem doing its job. Never square a rounded distance — carry d² unrounded, as the tool does here.

Step-by-step working

Formula (applied to each axis independently): x_cm = Σ(mᵢ·xᵢ) / Σmᵢ, y_cm = Σ(mᵢ·yᵢ) / Σmᵢ

Total mass Σm = 1 + 2 + 3 = 6

Σmx = (1 × 0) + (2 × 4) + (3 × 2) = 14

x_cm = 14 / 6 = 2.333333

Σmy = (1 × 0) + (2 × 0) + (3 × 6) = 18

y_cm = 18 / 6 = 3

I_cm = Σmᵢdᵢ² = 65.333333 kg·m² (dᵢ measured from the center of mass)

Parallel-axis theorem: I = I_cm + M·d²

I = 65.333333 + 6 × (3.800585)² = 152 kg·m²

Direct check Σmᵢrᵢ² about the same axis = 152 kg·m²

Display options

About This Tool

Center of Mass Calculator – Centroid, Balance and Barycenter

The center of massis the single point at which a system's entire mass can be treated as concentrated for the purposes of translational motion. Push a wrench across a table and it tumbles in a complicated way, but one point of it travels in a clean straight line — that point is the center of mass. This center of mass calculator locates it for point-mass systems in one, two or three dimensions, for composite shapes with holes cut out of them, for two-body barycenters, and for balance problems where you know the pivot and need the missing mass.

The formula, one axis at a time

Every mode rests on the same weighted average, applied independently to each axis:

x_cm = Σ(mᵢ · xᵢ) / Σmᵢ

A two-dimensional problem is therefore just two one-dimensional problems that happen to share a denominator. For masses of 1 kg at (0, 0), 2 kg at (4, 0) and 3 kg at (2, 6), the total mass is 6 kg, the first moments are Σmx = 14 and Σmy = 18 kg·m, and the center of mass sits at (2.333, 3.000) m. Notice that the answer is pulled toward the 3 kg mass — the weighting is what separates a center of mass from a plain geometric centroid.

First moments and why they vanish

The numerators Σmx, Σmy and Σmz are called first moments, and they are worth looking at directly. Measure positions from the center of mass instead of from the origin and every first moment becomes exactly zero. That is the defining property of the point: it is the location about which the mass-weighted displacements cancel. The contribution breakdown in the tool shows each object's share of the total first moment, which makes it obvious at a glance when one heavy object is dominating the result.

Holes count as negative mass

When a body has uniform density, mass is proportional to area or volume, so areas can serve directly as weights. Removing material is then arithmetically identical to adding a region of negativearea at the hole's own centroid. A 10 × 10 cm plate with a 2 cm-radius hole centred at (7, 5) has a net area of 87.434 cm² and a center of mass at x = 4.713 cm — displaced away from the hole, exactly as intuition demands.

Center of mass is not center of gravity
In a uniform gravitational field the two points coincide, because g appears in every term of the weighted average and cancels out of the ratio. Center of mass is purely geometric and this calculator never uses g at all. The two only separate across a body large enough that gravity measurably varies from one end to the other.

Barycenters and balance problems

For two bodies separated by a distance d, the common center of mass lies at r₁ = d · m₂ / (m₁ + m₂)from the first body's centre. The Earth–Moon barycenter works out at about 4,668 km from Earth's centre, which is less than Earth's 6,371 km mean radius — so the Earth does not orbit a point in empty space, it wobbles about a point buried inside itself. The balance mode inverts the same formula: given a fulcrum position and every mass but one, it solves for the unknown mass or the unknown position that puts the system in equilibrium.

From center of mass to moment of inertia

The center of mass is also the gateway to rotational dynamics. Compute I_cm = Σmᵢdᵢ² about an axis through it, then shift to any parallel axis with the parallel-axis theorem, I = I_cm + Md². For the three-particle system above this gives 65.333 + 6 × 14.444 = 152.000 kg·m² about the origin, which matches the direct sum Σmᵢrᵢ² exactly. If your hand check disagrees slightly, the usual culprit is squaring a rounded distance instead of carrying unrounded.

Frequently Asked Questions

Is the Center of Mass Calculator free?

Yes, Center of Mass Calculator is totally free :)

Can I use the Center of Mass Calculator offline?

Yes, you can install the webapp as PWA.

Is it safe to use Center of Mass Calculator?

Yes, any data related to Center of Mass Calculator only stored in your browser (if storage required). You can simply clear browser cache to clear all the stored data. We do not store any data on server.

How does the Center of Mass Calculator work?

It applies the mass-weighted average x_cm = Σ(mᵢxᵢ) / Σmᵢ independently to each active axis, so a 2D system is simply two 1D calculations sharing the same denominator. Every mass and coordinate is converted to SI before summation, which is what lets you mix units between rows. The numerators Σmx, Σmy and Σmz are reported as first moments, because those are the quantities that vanish about the center of mass.

What is the difference between center of mass and center of gravity?

In a uniform gravitational field they are the same point, because g appears in every term of the weighted average and cancels out of the ratio. Center of mass is purely geometric — it depends only on masses and positions, and this tool never uses g at all. The two only separate in a non-uniform field, such as across a body large enough that gravity measurably differs from one end to the other.

Why is a hole treated as negative mass?

For a body of uniform density, mass is proportional to area or volume, so areas can be used directly as weights. Cutting a hole removes material, which is arithmetically identical to adding a region of negative area at the hole's own centroid. A 10 × 10 cm plate with a 2 cm-radius hole centred at x = 7 has its center of mass at x = 4.713 cm — shifted away from the hole, which is the sanity check to expect.

Can the center of mass lie outside the object?

Yes, and it often does. The center of mass of a ring, a horseshoe or a boomerang sits in empty space, because it is an average position rather than a material point. The Earth–Moon barycenter is the opposite case: at 4,668 km from Earth's centre it falls inside the Earth, whose mean radius is 6,371 km, so the Earth wobbles about an internal point rather than orbiting a point in space.

How do I use the center of mass to find a moment of inertia?

Compute I_cm = Σmᵢdᵢ² about an axis through the center of mass, then shift it to any parallel axis with the parallel-axis theorem, I = I_cm + Md². The tool reports both together with the offset d it used. Keep d² unrounded when you check the arithmetic by hand — squaring a value already rounded for display is the most common source of a mismatch between the two routes.

What is center-of-mass velocity used for?

v_cm = Σ(mᵢvᵢ) / Σmᵢ is the velocity of the frame in which the system's total momentum is exactly zero, which is why it is the natural frame for analysing collisions. Two masses of 2 kg at +10 m/s and 3 kg at −4 m/s give v_cm = 8 / 5 = 1.6 m/s. Because no external force acts during a collision, v_cm is unchanged by the impact — elastic or not.