Skip to content
UniKit

Geometry calculator

Area, perimeter, surface area and volume for 17 shapes — square, rectangle, triangles (including Heron), circle, ellipse, sector, trapezoid, parallelogram, rhombus, regular polygon, sphere, cube, cylinder, cone, prism and square pyramid — with formulas and units.

Runs in your browserEvery computation happens in your browser — your data never leaves this device.

Opposite sides equal with four right angles.

All dimensions share one unit; areas are in square units and volumes in cubic units

Results
Area A48sq unitsFormula: A = a·b
Perimeter P28unitsFormula: P = 2(a + b)
Diagonal d10unitsFormula: d = √(a² + b²)

What this tool does

  • Check areas, perimeters, surface areas and volumes for homework or lesson prep — 17 shapes in one place, each with the formula it uses.
  • Handle triangles without worrying about which measurements you have: base × height or three sides via Heron.
  • Estimate material for DIY projects, sewing or shopping: round tablecloths, conical lampshades and cylindrical buckets are all covered.
  • Control precision: decimal places go from 0 to 10, so numbers drop straight into a report without manual rounding.

Example

Input

Shape "Circle", radius r = 3 (4 decimal places)

Output

Area A = πr² = 28.2743 sq units
Circumference C = 2πr = 18.8496 units
Diameter d = 2r = 6 units

All dimensions share one unit; areas come out in square units and volumes in cubic units. Results are only rounded for display, never during the calculation.

Frequently asked questions

What is the difference between the two triangle options?

"Triangle (base × height)" uses A = b·h/2 and needs just those two values. "Triangle (three sides / Heron)" uses the semiperimeter: A = √(p(p−a)(p−b)(p−c)). If the three sides cannot form a triangle the tool reports an error instead of returning an imaginary area.

Why is the ellipse perimeter approximate?

The perimeter of an ellipse has no elementary closed form. This tool uses Ramanujan's approximation, L ≈ π(a+b)(1 + 3h/(10 + √(4−3h))) with h = (a−b)²/(a+b)², which is accurate to roughly one part per million for ordinary eccentricities.

Why does it reject zero or negative values?

Lengths and radii must be greater than zero, otherwise the shape has no meaning — a circle with radius 0 has no area. On top of that an ellipse needs a ≥ b, a regular polygon needs an integer side count of at least 3, and a sector angle must be between 0 and 360 degrees.

Is 10 decimal places inaccurate?

Not wrong, but be aware that the intermediate math uses IEEE double precision, which carries about 15–16 significant digits. At 10 decimals the last few digits can reflect floating-point noise; 4–6 places is usually plenty and matches real measurement precision.

Does it need a network connection?

No. All formulas run in your browser, the page sends no requests, and the dimensions you type are never recorded.

Keywords:geometry几何area面积perimeter周长volume体积surface area表面积heron海伦公式circlecylinderconesphere

Related tools