Centroid calculator (composite shapes and polygons)

Enter your values. The answer and the full worked solution update as you type.

Result

Area A4737
x̄61.9
ȳ35.08
Ix (about the centroid)5251529
Iy (about the centroid)3131049
PartAxyA·xA·y
rectangle 120 × 202400601014400024000
rectangle 20 × 10020006070120000140000
triangle45080303600013500
hole: circle r = 6−113.160100−6786−11310

Use the same length unit for every value; the area is in that unit squared.

Find the centroid of a composite area. Describe it as rectangles, triangles, circles and semicircles, with holes subtracted, or enter the corner points of a polygon. The calculator gives the total area, the centroid coordinates x̄ and ȳ and the second moments of area about the centroidal axes, with a table of every part.

Step-by-step solution

Area and centroid of each part

rectangle 120 × 20: A = 2400, x = 60, y = 10
rectangle 20 × 100: A = 2000, x = 60, y = 70
triangle: A = 450, x = 80, y = 30
hole: circle r = 6: A = −113.1, x = 60, y = 100
Holes count as negative areas. The centroid of a triangle is the average of its corners; that of a semicircle lies 4r/(3π) from the flat side.

Centroid of the whole shape

A = ΣA = 4737
x̄ = ΣA·x/ΣA = 293214/4737 = 61.9
ȳ = ΣA·y/ΣA = 166190/4737 = 35.08

Second moments about the centroid (parallel axis theorem)

Ix = Σ(I0 + A·(y − ȳ)²) = 5251529
Iy = Σ(I0 + A·(x − x̄)²) = 3131049

Key formulas

Centroid
ȳ = ΣAiyi/ΣAi
Rectangle
I = bh³/12
Parallel-axis theorem
I = Ic + A·d²
Composite section
I = Σ(Ic,i + Aidi²)

How to find the centroid of a composite shape

  1. Split the shape into simple parts whose area and centroid you know, and treat holes as negative areas.
  2. Rectangle: centroid in the middle. Triangle: the average of the three corners. Semicircle: 4r/(3π) from the flat side.
  3. Multiply each area by the coordinates of its centroid and add up: ΣA·x and ΣA·y.
  4. Divide by the total area: x̄ = ΣA·x/ΣA and ȳ = ΣA·y/ΣA.
  5. For a polygon, use the shoelace formulas with the corner points in order.

Questions and answers

How do I enter the parts?

One part per entry, separated by semicolons: rect x y width height (with x, y the lower-left corner), tri x1 y1 x2 y2 x3 y3, circle xc yc r, semicircle xc yc r (flat side down, on the line y = yc). Put hole in front of a part to subtract it.

Can the centroid lie outside the shape?

Yes. For an L-shape, a ring or a C-shape the centroid is often in the empty space.

Do the polygon points have to go in a particular direction?

No, clockwise and anticlockwise both work. They must go round the outline in order, and the edges must not cross each other.

Why does a hole count as a negative area?

The shape with a hole is the full shape minus the hole, so both its area and its first moment of area are the full values minus those of the hole.

Practise it yourself

Practise Centroid & second moment of area

A calculator gives the answer. In the exam you need the method: practise it with new problems, hints and worked solutions.

</> Embed

Free for teachers and schools: paste this code into your course page, LMS or website. Students can use the calculator and its worked solution without an account.

More calculators