Geometry

Trapezoid Calculator — Area and Diagonals

Work out the area, midline and perimeter of a trapezoid from its two parallel sides, height and legs.

Formula and sources updated · Data sources · 1View algorithm, constants and default inputs (JSON)

Enter your values

Area 36.000unit²
Results

Area (unit²)

Area (unit²)Schematic; not to scale. a · Top side (b₁): 6.00 / b · Bottom side (b₂): 12.00 / h · Height: 4.00 / c · Left leg: 5.00 / d · Right leg: 5.00abhcdSchematic; not to scale.a · Top side (b₁): 6.00b · Bottom side (b₂): 12.00h · Height: 4.00c · Left leg: 5.00d · Right leg: 5.00

About this calculator

Enter both parallel bases, the perpendicular height and both legs in the same length unit. All five measurements must describe one trapezoid. The calculator checks the legs before returning area, midline, perimeter and diagonals; it also accepts equal bases when the legs fit.

Worked example

calculated with the default values below

Top side (b₁) 6 · Bottom side (b₂) 12 · Height 4 · Left leg 5 · Right leg 5 Area 36.000 unit² · Midline 9.000 unit · Perimeter 28.000 unit · Diagonal 1 9.8489 unit · Diagonal 2 9.8489 unit

Method and assumptions

Area is the average of the parallel bases multiplied by perpendicular height; the midline is that average. Perimeter is the sum of both bases and both legs. With bases 6 and 12, height 4 and legs 5 and 5, area is 36 square units, midline 9 and perimeter 28. The left leg gives a horizontal projection of either sign; the calculator chooses a sign consistent with the right leg and uses Pythagoras for both diagonals. Leg compatibility allows a difference of 0.01 length units or one hundred-millionth of the larger calculated/entered right leg, whichever is larger. This is an input-fit tolerance, not a measurement uncertainty estimate. Every input must be greater than zero and at most 100000; a leg cannot be shorter than the height.

Data sources

Disclaimer

These calculators give general mathematical results. They suit study, planning and estimation — verify anything that feeds a graded submission, a published figure or a financial commitment.

Maintained by: CalcDelta Formula and sources updated ·

Implementation source

This record describes the implementation used by this page. It is not independent validation. External references, when available, support only the stated formula or definition; estimates and custom rules retain their own assumptions.

View algorithm, constants and default inputs (JSON)

Formula and variables

A = (a+b)h/2; m = (a+b)/2; P = a+b+c+d; x = ±√(c²−h²); D₁ = √((x+a)²+h²); D₂ = √((b−x)²+h²)

a,b
Parallel top and bottom bases
h
Perpendicular height
c,d
Left and right legs
x
Signed horizontal projection of the left leg, chosen to fit the right leg
A,m,P
Area, midline and perimeter
D₁,D₂
Diagonals

Legs shorter than the perpendicular height or incompatible with the bases are rejected. The horizontal projection may have either sign; no invalid leg is repaired by clipping. Use one consistent length unit; area uses its square.

Embed this calculator

Copy the iframe snippet to place this calculator on your site. No account required. The snippet stays in sync with the inputs currently shown.

Frequently asked questions

Which sides are the bases?

Enter the two parallel sides as the top and bottom bases; they may have equal or different lengths. Area is their average multiplied by the perpendicular height. The two legs are used for the perimeter and must be consistent with the same trapezoid.

Can I use a slanted leg as the height?

No. Enter the perpendicular distance between the parallel bases. A slanted leg is at least as long as that height, and using it in the area formula would overstate the area unless the leg is perpendicular to the bases.

Why might the calculator reject my measurements?

The bases, height and both legs must describe one possible trapezoid. Each leg must be at least as long as the perpendicular height, and the two leg lengths must fit the selected base lengths. Incompatible measurements produce an error instead of misleading perimeter or diagonal values.