Advertisement

Triangle inequality calculator

Test three lengths, or find the open interval of possible third-side lengths. Equality gives a flat shape rather than a triangle.

Calculator

Result
Valid triangle
Third side must exceed
1
Third side must be below
7
Shortest-sides sum minus longest
2

Advertisement

How this calculator works

A straight segment is the shortest route between two points. Going by the third vertex must therefore be longer than the opposite side in a non-flat triangle. Checking the two shortest sides against the longest is sufficient. With two sides fixed, rearranging all three inequalities gives an open interval for the third.

Formula

Triangle test: shortest + middle > longest. Third-side bounds: |a-b| < c < a+b.

Worked example

With a = 3 m and b = 4 m, the third side must lie strictly between 1 m and 7 m. A value of 5 m works; 7 m produces a flat shape.

Advertisement

Frequently asked questions

Why is the lower endpoint excluded?

At c = |a-b| the smaller sides line up inside the largest side, leaving no enclosed area.

Can zero be a side?

No. Triangle sides have positive lengths, even when the lower bound is zero because a equals b.

Does passing the test mean the triangle is right?

No. It only confirms existence. Classify the angles separately or compare the squares of the side lengths.

Sources

Advertisement