Skip to content

Regular Polygon Calculator

Pick the number of sides and enter the side length to get the area, perimeter, angles, apothem, circumradius and diagonals, with a drawing. Advanced solves from any one measurement and adds frame cuts, cost and irregular shapes.

More options
Hexagon

Any whole number from 3 to 1,000.

What do you know?

The length of one edge. Fractions like 3 1/2 work too.

Frame or stave cuts (woodwork, metal; leave blank to skip)

The side above is the outside edge of the frame. Each piece is cut at the same angle on both ends.

Material cost (paving, tiles, fabric; leave blank to skip)
%
Irregular polygon from corners (shoelace formula; leave blank to skip)

Go round the edge in order, clockwise or anticlockwise. Pairs like (0,0) (6,0) on one line work too.

ResultUpdates as you type
Step-by-step working

    How your polygon is worked out

    Cut the shape into equal triangles from the centre. Each one is a side wide and an apothem tall.

    1. 1

      Cut into triangles

      360° ÷ 6
      = 60° each

    2. 2

      Find the apothem

      2 ÷ (2 × tan 30°)
      a = 1.73205 cm

    3. 3

      Add up the area

      ½ × 12 × 1.73205
      A = 10.3923 cm²

    4. 4

      Corner angles

      (6 − 2) × 180 ÷ 6
      120° inside

    Read more: the formulas, a worked example, frames and the shoelace formula

    A regular polygon has all its sides the same length and all its corners the same angle. Lines from the centre to each corner cut it into n equal triangles. Each triangle is one side wide, and its height is the apothem (centre to the middle of a side). The circumradius is the distance from the centre to a corner. Once you know n and any one length, everything else follows.

    The formula

    area A = n × s² ÷ (4 × tan(180° ÷ n)) = ½ × perimeter × apothem
    perimeter P = n × s
    apothem a = s ÷ (2 × tan(180° ÷ n))
    circumradius R = s ÷ (2 × sin(180° ÷ n))
    interior angle = (n − 2) × 180° ÷ n
    exterior angle = central angle = 360° ÷ n
    sum of interior angles = (n − 2) × 180°
    diagonals = n × (n − 3) ÷ 2
    side from apothem: s = 2 × a × tan(180° ÷ n)
    side from circumradius: s = 2 × R × sin(180° ÷ n)
    side from area: s = √(4 × A × tan(180° ÷ n) ÷ n)
    frame miter angle = 180° ÷ n; inside edge = s − 2 × board width × tan(180° ÷ n)
    shoelace area = ½ × |(x₁y₂ − x₂y₁) + (x₂y₃ − x₃y₂) + … + (xₙy₁ − x₁yₙ)|

    Worked example

    A hexagon (n = 6) with sides of 2 cm. 180° ÷ 6 = 30°, tan 30° = 0.577350 and sin 30° = 0.5.

    • Perimeter = 6 × 2 = 12 cm.
    • Apothem = 2 ÷ (2 × 0.577350) = 2 ÷ 1.154701 = 1.73205 cm (exactly √3).
    • Circumradius = 2 ÷ (2 × 0.5) = 2 ÷ 1 = 2 cm. On a hexagon the corners are one side away from the centre.
    • Area = 6 × 2² ÷ (4 × 0.577350) = 24 ÷ 2.309401 = 10.3923 cm² (exactly 6√3). Check: ½ × 12 × 1.73205 = 10.3923.
    • Interior angle = (6 − 2) × 180 ÷ 6 = 720 ÷ 6 = 120°; exterior angle = 360 ÷ 6 = 60°; the six corners add up to 720°.
    • Diagonals = 6 × (6 − 3) ÷ 2 = 18 ÷ 2 = 9.

    The default irregular polygon in Advanced is a house shape with corners (0, 0), (6, 0), (6, 4), (3, 7), (0, 4) in metres. The shoelace terms are 0 × 0 − 6 × 0 = 0, 6 × 4 − 6 × 0 = 24, 6 × 7 − 3 × 4 = 30, 3 × 4 − 0 × 7 = 12 and 0 × 0 − 0 × 4 = 0. They add up to 66, so the area is 66 ÷ 2 = 33 m²: a 6 × 4 rectangle (24 m²) plus a roof triangle of 6 × 3 ÷ 2 = 9 m².

    Frames, staves and nuts

    For a frame with n pieces, set the miter saw to 180° ÷ n on both ends of every piece: 60° for a triangle, 45° for a square, 36° for a pentagon, 30° for a hexagon and 22.5° for an octagon. For a hexagon frame with a 30 cm outside edge and 4 cm wide boards, each piece is 30 cm on its long (outside) edge and 30 − 2 × 4 × 0.577350 = 30 − 4.61880 = 25.3812 cm on its short (inside) edge, and you need 6 × 30 = 180 cm of board plus the blade allowance. Staves for a bucket or barrel use the same angle as a bevel. Spanners and nuts are sized across the flats (2 × apothem); across the corners is 2 × circumradius.

    Material cost

    A hexagon patio with 2 m sides covers 10.3923 m². With 10% extra for cuts that is 10.3923 × 1.10 = 11.4315 m², and at 25 a square metre it costs 11.4315 × 25 = 285.79 in your currency.

    Polygon names

    3 triangle, 4 square, 5 pentagon, 6 hexagon, 7 heptagon, 8 octagon, 9 nonagon, 10 decagon, 11 hendecagon, 12 dodecagon, 20 icosagon, 100 hectogon, 1,000 chiliagon. Other sizes are called n-gons, such as a 15-gon. As n grows, the polygon gets closer to a circle: a 1,000-gon with circumradius 1 has an area of 3.14157, against π = 3.14159.

    Standard geometry, no rates or rules that change. For circles and arcs use the circle calculator; for triangles that are not equilateral, the triangle calculator; for other shapes, the area calculator.

    Common questions

    How do I find the area of a regular polygon?

    Multiply the number of sides by the side squared, then divide by 4 × tan(180° ÷ n): A = n × s² ÷ (4 × tan(180°/n)). A hexagon with 2 cm sides gives 6 × 4 ÷ (4 × tan 30°) = 24 ÷ 2.3094 = 10.3923 cm², which is exactly 6√3. Another way is half the perimeter times the apothem: ½ × 12 × 1.73205 = 10.3923.

    How do I work out the interior angle of a polygon?

    Take 2 away from the number of sides, multiply by 180 and divide by the number of sides: (n − 2) × 180 ÷ n. An octagon has (8 − 2) × 180 ÷ 8 = 135° at each corner, and a hexagon has 120°. All the interior angles add up to (n − 2) × 180, so 1,080° for an octagon.

    What is the apothem?

    The apothem is the distance from the centre straight out to the middle of a side, at right angles to it. It is also the radius of the biggest circle that fits inside (the inradius). For side s it is s ÷ (2 × tan(180°/n)). On a hexagon nut it is half the distance across the flats.

    What angle do I cut for a hexagon or octagon frame?

    Set the miter saw to 180 ÷ n on both ends of every piece: 30° for a hexagon, 22.5° for an octagon, 45° for a square and 36° for a pentagon. Each joint then closes at the polygon's interior angle. Advanced also gives the short-point length on the inside edge for your board width.

    How many diagonals does a polygon have?

    n × (n − 3) ÷ 2. Each corner joins to every other corner except itself and its two neighbours, and each diagonal gets counted twice. A hexagon has 6 × 3 ÷ 2 = 9 diagonals; a triangle has none.

    How do I find the area of an irregular polygon?

    List the corners in order as x, y coordinates and use the shoelace formula: multiply each x by the next y, take away the next x times this y, add these up and halve the total. Switch to Advanced and type the corners into the irregular polygon box; it also gives the perimeter and the centre point.

    Related calculators

    Area calculatorArea and perimeter of 15 shapes, from rectangles and triangles to sectors and polygons, in mixed units with a scale drawing and steps.Circle calculatorRadius, diameter, circumference and area from any one, in terms of π, plus arc length, sector, chord, segment and ring area, with steps.Triangle calculatorSolve any triangle from SSS, SAS, ASA, AAS or SSA (both answers when two fit), right triangles by Pythagoras, or three points, with a drawing and the working.Trigonometry calculatorsin, cos, tan, csc, sec and cot in degrees, radians, gradians or DMS, with exact √ values, a unit circle, and inverses with every answer in 0–360°.

    Made by Zulu Calculator, part of AlphaZulu LLC. Formulas are shown in full and rule figures are checked against official sources; see how we build calculators.

    Embed this calculator on your site

    Free to use on your website or blog. Paste this code where you want the calculator to appear. Please keep the credit link.

    Regular polygon calculator by Zulu Calculator ↗