Triangle formulas
- Area from a side and its height: A = a · ha / 2
- Area from three sides (Heron’s formula): A = √(s · (s − a) · (s − b) · (s − c)), with s = (a + b + c) / 2
- Perimeter: P = a + b + c
- Angles (law of cosines): cos α = (b² + c² − a²) / (2 · b · c)
- Inradius r = A / s, circumradius R = a · b · c / (4 · A)
Side a lies opposite angle α, b opposite β and c opposite γ. The height ha runs from the opposite corner straight down to side a, so every side has its own height: ha = 2 · A / a.
Any triangle from three sides
Example with a = 5 cm, b = 6 cm and c = 7 cm:
s = (5 + 6 + 7) / 2 = 9 cm A = √(9 · 4 · 3 · 2) = √216 ≈ 14.70 cm² P = 5 + 6 + 7 = 18 cm cos α = (36 + 49 − 25) / 84 → α ≈ 44.42°
Three lengths form a triangle only when each one is shorter than the other two together (the triangle inequality). 5, 6 and 12 do not, because 5 + 6 < 12.
Right triangle
- Hypotenuse (Pythagoras): c = √(a² + b²)
- Area: A = a · b / 2
- Height to the hypotenuse: hc = a · b / c
The legs a and b meet at the right angle, so each is the height onto the other. Example with legs of 3 cm and 4 cm: the hypotenuse is √(9 + 16) = 5 cm, the area 3 · 4 / 2 = 6 cm² and the perimeter 12 cm.
Isosceles and equilateral triangle
- Isosceles, base a and legs b: h = √(b² − (a/2)²), A = a · h / 2, P = a + 2 · b
- Equilateral, side a: h = a · √3 / 2, A = √3/4 · a², P = 3 · a
The height of an isosceles triangle splits it into two right triangles. Example with a base of 6 cm and legs of 5 cm: h = √(25 − 9) = 4 cm and A = 6 · 4 / 2 = 12 cm². An equilateral triangle with a side of 6 cm has h ≈ 5.20 cm and A ≈ 15.59 cm².
Frequently asked questions
How do I find the area with only a base and a height?
Multiply them and halve the result: A = a · h / 2. A triangle with a base of 10 cm and a height of 4 cm has an area of 20 cm², whatever its other sides are.
How do I find the third side of a right triangle?
For the hypotenuse use c = √(a² + b²). For a missing leg use b = √(c² − a²): with a hypotenuse of 13 and a leg of 5, the other leg is √(169 − 25) = 12.
How do I know if a triangle is acute, right or obtuse?
Compare the square of the longest side c with the other two: equal to a² + b² means right, smaller means acute, larger means obtuse. The calculator shows the kind in its results.
Why do the angles always add up to 180°?
A line through one corner parallel to the opposite side makes the same angles with the other two sides as the triangle does, and together they form a straight angle. So α + β + γ = 180°.