Triangle calculator

Please enter what you know about the triangle:
Symbols definition of ABC triangle

You have entered side a, b and angle α.

Triangle has two solutions: a=12.3; b=15.6; c=4.95111104075 and a=12.3; b=15.6; c=18.59658284954.

#1 Obtuse scalene triangle.

Sides: a = 12.3   b = 15.6   c = 4.95111104075

Area: T = 25.33661213537
Perimeter: p = 32.85111104075
Semiperimeter: s = 16.42655552038

Angle ∠ A = α = 41° = 0.71655849933 rad
Angle ∠ B = β = 123.6887529396° = 123°41'15″ = 2.15987546316 rad
Angle ∠ C = γ = 15.31224706044° = 15°18'45″ = 0.26772530287 rad

Height: ha = 4.12196945291
Height: hb = 3.24882206864
Height: hc = 10.23545208523

Median: ma = 9.80437873872
Median: mb = 5.20220906503
Median: mc = 13.82773868259

Inradius: r = 1.54224818851
Circumradius: R = 9.37441564832

Vertex coordinates: A[4.95111104075; 0] B[0; 0] C[-6.8222359044; 10.23545208523]
Centroid: CG[-0.62437495455; 3.41215069508]
Coordinates of the circumscribed circle: U[2.47655552038; 9.04113735796]
Coordinates of the inscribed circle: I[0.82655552038; 1.54224818851]

Exterior (or external, outer) angles of the triangle:
∠ A' = α' = 139° = 0.71655849933 rad
∠ B' = β' = 56.31224706044° = 56°18'45″ = 2.15987546316 rad
∠ C' = γ' = 164.6887529396° = 164°41'15″ = 0.26772530287 rad


How did we calculate this triangle?

The calculation of the triangle progress in two phases. The first phase is such that we try to calculate all three sides of the triangle from the input parameters. The first phase is different for the different triangles query entered. The second phase is the calculation of other characteristics of the triangle, such as angles, area, perimeter, heights, the center of gravity, circle radii, etc. Some input data also results in two to three correct triangle solutions (e.g., if the specified triangle area and two sides - typically resulting in both acute and obtuse) triangle).

1. Input data entered: side a, b and angle α.

a=12.3 b=15.6 α=41a = 12.3 \ \\ b = 15.6 \ \\ α = 41^\circ

2. From angle α, side b and side a we calculate side c - by using the law of cosines and quadratic equation:

a2=b2+c22bccosα  12.32=15.62+c22 15.6 c cos41   c223.547c+92.07=0  p=1;q=23.547;r=92.07 D=q24pr=23.54724192.07=186.178331699 D>0  c1,2=q±D2p=23.55±186.182 c1,2=11.77346945±6.82235904397 c1=18.5958284954 c2=4.95111040751   Factored form of the equation:  (c18.5958284954)(c4.95111040751)=0   c>0  c=18.596a^2 = b^2 + c^2 - 2b c \cos α \ \\ \ \\ 12.3^2 = 15.6^2 + c^2 - 2 \cdot \ 15.6 \cdot \ c \cdot \ \cos 41^\circ \ \\ \ \\ \ \\ c^2 -23.547c +92.07 =0 \ \\ \ \\ p=1; q=-23.547; r=92.07 \ \\ D = q^2 - 4pr = 23.547^2 - 4\cdot 1 \cdot 92.07 = 186.178331699 \ \\ D>0 \ \\ \ \\ c_{1,2} = \dfrac{ -q \pm \sqrt{ D } }{ 2p } = \dfrac{ 23.55 \pm \sqrt{ 186.18 } }{ 2 } \ \\ c_{1,2} = 11.77346945 \pm 6.82235904397 \ \\ c_{1} = 18.5958284954 \ \\ c_{2} = 4.95111040751 \ \\ \ \\ \text{ Factored form of the equation: } \ \\ (c -18.5958284954) (c -4.95111040751) = 0 \ \\ \ \\ \ \\ c > 0 \ \\ \ \\ c = 18.596

Now we know the lengths of all three sides of the triangle, and the triangle is uniquely determined. Next, we calculate another its characteristics - same procedure as calculation of the triangle from the known three sides SSS.

a=12.3 b=15.6 c=4.95a = 12.3 \ \\ b = 15.6 \ \\ c = 4.95

3. The triangle perimeter is the sum of the lengths of its three sides

p=a+b+c=12.3+15.6+4.95=32.85p = a+b+c = 12.3+15.6+4.95 = 32.85

4. Semiperimeter of the triangle

The semiperimeter of the triangle is half its perimeter. The semiperimeter frequently appears in formulas for triangles that it is given a separate name. By the triangle inequality, the longest side length of a triangle is less than the semiperimeter.

s=p2=32.852=16.43s = \dfrac{ p }{ 2 } = \dfrac{ 32.85 }{ 2 } = 16.43

5. The triangle area using Heron's formula

Heron's formula gives the area of a triangle when the length of all three sides are known. There is no need to calculate angles or other distances in the triangle first. Heron's formula works equally well in all cases and types of triangles.

T=s(sa)(sb)(sc) T=16.43(16.4312.3)(16.4315.6)(16.434.95) T=641.92=25.34T = \sqrt{ s(s-a)(s-b)(s-c) } \ \\ T = \sqrt{ 16.43(16.43-12.3)(16.43-15.6)(16.43-4.95) } \ \\ T = \sqrt{ 641.92 } = 25.34

6. Calculate the heights of the triangle from its area.

There are many ways to find the height of the triangle. The easiest way is from the area and base length. The area of a triangle is half of the product of the length of the base and the height. Every side of the triangle can be a base; there are three bases and three heights (altitudes). Triangle height is the perpendicular line segment from a vertex to a line containing the base.

T=aha2  ha=2 Ta=2 25.3412.3=4.12 hb=2 Tb=2 25.3415.6=3.25 hc=2 Tc=2 25.344.95=10.23T = \dfrac{ a h _a }{ 2 } \ \\ \ \\ h _a = \dfrac{ 2 \ T }{ a } = \dfrac{ 2 \cdot \ 25.34 }{ 12.3 } = 4.12 \ \\ h _b = \dfrac{ 2 \ T }{ b } = \dfrac{ 2 \cdot \ 25.34 }{ 15.6 } = 3.25 \ \\ h _c = \dfrac{ 2 \ T }{ c } = \dfrac{ 2 \cdot \ 25.34 }{ 4.95 } = 10.23

7. Calculation of the inner angles of the triangle using a Law of Cosines

The Law of Cosines is useful for finding the angles of a triangle when we know all three sides. The cosine rule, also known as the law of cosines, relates all three sides of a triangle with an angle of a triangle. The Law of Cosines is the extrapolation of the Pythagorean theorem for any triangle. Pythagorean theorem works only in a right triangle. Pythagorean theorem is a special case of the Law of Cosines and can be derived from it because the cosine of 90° is 0. It is best to find the angle opposite the longest side first. With the Law of Cosines, there is also no problem with obtuse angles as with the Law of Sines, because cosine function is negative for obtuse angles, zero for right, and positive for acute angles. We also use inverse cosine called arccosine to determine the angle from cosine value.

a2=b2+c22bccosα  α=arccos(b2+c2a22bc)=arccos(15.62+4.95212.322 15.6 4.95)=41  b2=a2+c22accosβ β=arccos(a2+c2b22ac)=arccos(12.32+4.95215.622 12.3 4.95)=1234115" γ=180αβ=180411234115"=151845"a^2 = b^2+c^2 - 2bc \cos α \ \\ \ \\ α = \arccos(\dfrac{ b^2+c^2-a^2 }{ 2bc } ) = \arccos(\dfrac{ 15.6^2+4.95^2-12.3^2 }{ 2 \cdot \ 15.6 \cdot \ 4.95 } ) = 41^\circ \ \\ \ \\ b^2 = a^2+c^2 - 2ac \cos β \ \\ β = \arccos(\dfrac{ a^2+c^2-b^2 }{ 2ac } ) = \arccos(\dfrac{ 12.3^2+4.95^2-15.6^2 }{ 2 \cdot \ 12.3 \cdot \ 4.95 } ) = 123^\circ 41'15" \ \\ γ = 180^\circ - α - β = 180^\circ - 41^\circ - 123^\circ 41'15" = 15^\circ 18'45"

8. Inradius

An incircle of a triangle is a circle which is tangent to each side. An incircle center is called incenter and has a radius named inradius. All triangles have an incenter, and it always lies inside the triangle. The incenter is the intersection of the three angle bisectors. The product of the inradius and semiperimeter (half the perimeter) of a triangle is its area.

T=rs r=Ts=25.3416.43=1.54T = rs \ \\ r = \dfrac{ T }{ s } = \dfrac{ 25.34 }{ 16.43 } = 1.54

9. Circumradius

The circumcircle of a triangle is a circle that passes through all of the triangle's vertices, and the circumradius of a triangle is the radius of the triangle's circumcircle. Circumcenter (center of circumcircle) is the point where the perpendicular bisectors of a triangle intersect.

R=abc4 rs=12.3 15.6 4.954 1.542 16.426=9.37R = \dfrac{ a b c }{ 4 \ r s } = \dfrac{ 12.3 \cdot \ 15.6 \cdot \ 4.95 }{ 4 \cdot \ 1.542 \cdot \ 16.426 } = 9.37

10. Calculation of medians

A median of a triangle is a line segment joining a vertex to the midpoint of the opposite side. Every triangle has three medians, and they all intersect each other at the triangle's centroid. The centroid divides each median into parts in the ratio 2:1, with the centroid being twice as close to the midpoint of a side as it is to the opposite vertex. We use Apollonius's theorem to calculate the length of a median from the lengths of its side.

ma=2b2+2c2a22=2 15.62+2 4.95212.322=9.804 mb=2c2+2a2b22=2 4.952+2 12.3215.622=5.202 mc=2a2+2b2c22=2 12.32+2 15.624.9522=13.827m_a = \dfrac{ \sqrt{ 2b^2+2c^2 - a^2 } }{ 2 } = \dfrac{ \sqrt{ 2 \cdot \ 15.6^2+2 \cdot \ 4.95^2 - 12.3^2 } }{ 2 } = 9.804 \ \\ m_b = \dfrac{ \sqrt{ 2c^2+2a^2 - b^2 } }{ 2 } = \dfrac{ \sqrt{ 2 \cdot \ 4.95^2+2 \cdot \ 12.3^2 - 15.6^2 } }{ 2 } = 5.202 \ \\ m_c = \dfrac{ \sqrt{ 2a^2+2b^2 - c^2 } }{ 2 } = \dfrac{ \sqrt{ 2 \cdot \ 12.3^2+2 \cdot \ 15.6^2 - 4.95^2 } }{ 2 } = 13.827



#2 Acute scalene triangle.

Sides: a = 12.3   b = 15.6   c = 18.59658284954

Area: T = 95.16596972508
Perimeter: p = 46.49658284954
Semiperimeter: s = 23.24879142477

Angle ∠ A = α = 41° = 0.71655849933 rad
Angle ∠ B = β = 56.31224706044° = 56°18'45″ = 0.9832838022 rad
Angle ∠ C = γ = 82.68875293956° = 82°41'15″ = 1.44331696383 rad

Height: ha = 15.47331215042
Height: hb = 12.2199961186
Height: hc = 10.23545208523

Median: ma = 16.02437298628
Median: mb = 13.70106357048
Median: mc = 10.53296624182

Inradius: r = 4.09332574095
Circumradius: R = 9.37441564832

Vertex coordinates: A[18.59658284954; 0] B[0; 0] C[6.8222359044; 10.23545208523]
Centroid: CG[8.47327291798; 3.41215069508]
Coordinates of the circumscribed circle: U[9.29879142477; 1.19331472727]
Coordinates of the inscribed circle: I[7.64879142477; 4.09332574095]

Exterior (or external, outer) angles of the triangle:
∠ A' = α' = 139° = 0.71655849933 rad
∠ B' = β' = 123.6887529396° = 123°41'15″ = 0.9832838022 rad
∠ C' = γ' = 97.31224706044° = 97°18'45″ = 1.44331696383 rad

Calculate another triangle

How did we calculate this triangle?

The calculation of the triangle progress in two phases. The first phase is such that we try to calculate all three sides of the triangle from the input parameters. The first phase is different for the different triangles query entered. The second phase is the calculation of other characteristics of the triangle, such as angles, area, perimeter, heights, the center of gravity, circle radii, etc. Some input data also results in two to three correct triangle solutions (e.g., if the specified triangle area and two sides - typically resulting in both acute and obtuse) triangle).

1. Input data entered: side a, b and angle α.

a=12.3 b=15.6 α=41a = 12.3 \ \\ b = 15.6 \ \\ α = 41^\circ

2. From angle α, side b and side a we calculate side c - by using the law of cosines and quadratic equation:

a2=b2+c22bccosα  12.32=15.62+c22 15.6 c cos41   c223.547c+92.07=0  p=1;q=23.547;r=92.07 D=q24pr=23.54724192.07=186.178331699 D>0  c1,2=q±D2p=23.55±186.182 c1,2=11.77346945±6.82235904397 c1=18.5958284954 c2=4.95111040751   Factored form of the equation:  (c18.5958284954)(c4.95111040751)=0   c>0  c=18.596a^2 = b^2 + c^2 - 2b c \cos α \ \\ \ \\ 12.3^2 = 15.6^2 + c^2 - 2 \cdot \ 15.6 \cdot \ c \cdot \ \cos 41^\circ \ \\ \ \\ \ \\ c^2 -23.547c +92.07 =0 \ \\ \ \\ p=1; q=-23.547; r=92.07 \ \\ D = q^2 - 4pr = 23.547^2 - 4\cdot 1 \cdot 92.07 = 186.178331699 \ \\ D>0 \ \\ \ \\ c_{1,2} = \dfrac{ -q \pm \sqrt{ D } }{ 2p } = \dfrac{ 23.55 \pm \sqrt{ 186.18 } }{ 2 } \ \\ c_{1,2} = 11.77346945 \pm 6.82235904397 \ \\ c_{1} = 18.5958284954 \ \\ c_{2} = 4.95111040751 \ \\ \ \\ \text{ Factored form of the equation: } \ \\ (c -18.5958284954) (c -4.95111040751) = 0 \ \\ \ \\ \ \\ c > 0 \ \\ \ \\ c = 18.596

Now we know the lengths of all three sides of the triangle, and the triangle is uniquely determined. Next, we calculate another its characteristics - same procedure as calculation of the triangle from the known three sides SSS.

a=12.3 b=15.6 c=18.6a = 12.3 \ \\ b = 15.6 \ \\ c = 18.6

3. The triangle perimeter is the sum of the lengths of its three sides

p=a+b+c=12.3+15.6+18.6=46.5p = a+b+c = 12.3+15.6+18.6 = 46.5

4. Semiperimeter of the triangle

The semiperimeter of the triangle is half its perimeter. The semiperimeter frequently appears in formulas for triangles that it is given a separate name. By the triangle inequality, the longest side length of a triangle is less than the semiperimeter.

s=p2=46.52=23.25s = \dfrac{ p }{ 2 } = \dfrac{ 46.5 }{ 2 } = 23.25

5. The triangle area using Heron's formula

Heron's formula gives the area of a triangle when the length of all three sides are known. There is no need to calculate angles or other distances in the triangle first. Heron's formula works equally well in all cases and types of triangles.

T=s(sa)(sb)(sc) T=23.25(23.2512.3)(23.2515.6)(23.2518.6) T=9055.37=95.16T = \sqrt{ s(s-a)(s-b)(s-c) } \ \\ T = \sqrt{ 23.25(23.25-12.3)(23.25-15.6)(23.25-18.6) } \ \\ T = \sqrt{ 9055.37 } = 95.16

6. Calculate the heights of the triangle from its area.

There are many ways to find the height of the triangle. The easiest way is from the area and base length. The area of a triangle is half of the product of the length of the base and the height. Every side of the triangle can be a base; there are three bases and three heights (altitudes). Triangle height is the perpendicular line segment from a vertex to a line containing the base.

T=aha2  ha=2 Ta=2 95.1612.3=15.47 hb=2 Tb=2 95.1615.6=12.2 hc=2 Tc=2 95.1618.6=10.23T = \dfrac{ a h _a }{ 2 } \ \\ \ \\ h _a = \dfrac{ 2 \ T }{ a } = \dfrac{ 2 \cdot \ 95.16 }{ 12.3 } = 15.47 \ \\ h _b = \dfrac{ 2 \ T }{ b } = \dfrac{ 2 \cdot \ 95.16 }{ 15.6 } = 12.2 \ \\ h _c = \dfrac{ 2 \ T }{ c } = \dfrac{ 2 \cdot \ 95.16 }{ 18.6 } = 10.23

7. Calculation of the inner angles of the triangle using a Law of Cosines

The Law of Cosines is useful for finding the angles of a triangle when we know all three sides. The cosine rule, also known as the law of cosines, relates all three sides of a triangle with an angle of a triangle. The Law of Cosines is the extrapolation of the Pythagorean theorem for any triangle. Pythagorean theorem works only in a right triangle. Pythagorean theorem is a special case of the Law of Cosines and can be derived from it because the cosine of 90° is 0. It is best to find the angle opposite the longest side first. With the Law of Cosines, there is also no problem with obtuse angles as with the Law of Sines, because cosine function is negative for obtuse angles, zero for right, and positive for acute angles. We also use inverse cosine called arccosine to determine the angle from cosine value.

a2=b2+c22bccosα  α=arccos(b2+c2a22bc)=arccos(15.62+18.6212.322 15.6 18.6)=41  b2=a2+c22accosβ β=arccos(a2+c2b22ac)=arccos(12.32+18.6215.622 12.3 18.6)=561845" γ=180αβ=18041561845"=824115"a^2 = b^2+c^2 - 2bc \cos α \ \\ \ \\ α = \arccos(\dfrac{ b^2+c^2-a^2 }{ 2bc } ) = \arccos(\dfrac{ 15.6^2+18.6^2-12.3^2 }{ 2 \cdot \ 15.6 \cdot \ 18.6 } ) = 41^\circ \ \\ \ \\ b^2 = a^2+c^2 - 2ac \cos β \ \\ β = \arccos(\dfrac{ a^2+c^2-b^2 }{ 2ac } ) = \arccos(\dfrac{ 12.3^2+18.6^2-15.6^2 }{ 2 \cdot \ 12.3 \cdot \ 18.6 } ) = 56^\circ 18'45" \ \\ γ = 180^\circ - α - β = 180^\circ - 41^\circ - 56^\circ 18'45" = 82^\circ 41'15"

8. Inradius

An incircle of a triangle is a circle which is tangent to each side. An incircle center is called incenter and has a radius named inradius. All triangles have an incenter, and it always lies inside the triangle. The incenter is the intersection of the three angle bisectors. The product of the inradius and semiperimeter (half the perimeter) of a triangle is its area.

T=rs r=Ts=95.1623.25=4.09T = rs \ \\ r = \dfrac{ T }{ s } = \dfrac{ 95.16 }{ 23.25 } = 4.09

9. Circumradius

The circumcircle of a triangle is a circle that passes through all of the triangle's vertices, and the circumradius of a triangle is the radius of the triangle's circumcircle. Circumcenter (center of circumcircle) is the point where the perpendicular bisectors of a triangle intersect.

R=abc4 rs=12.3 15.6 18.64 4.093 23.248=9.37R = \dfrac{ a b c }{ 4 \ r s } = \dfrac{ 12.3 \cdot \ 15.6 \cdot \ 18.6 }{ 4 \cdot \ 4.093 \cdot \ 23.248 } = 9.37

10. Calculation of medians

A median of a triangle is a line segment joining a vertex to the midpoint of the opposite side. Every triangle has three medians, and they all intersect each other at the triangle's centroid. The centroid divides each median into parts in the ratio 2:1, with the centroid being twice as close to the midpoint of a side as it is to the opposite vertex. We use Apollonius's theorem to calculate the length of a median from the lengths of its side.

ma=2b2+2c2a22=2 15.62+2 18.6212.322=16.024 mb=2c2+2a2b22=2 18.62+2 12.3215.622=13.701 mc=2a2+2b2c22=2 12.32+2 15.6218.622=10.53m_a = \dfrac{ \sqrt{ 2b^2+2c^2 - a^2 } }{ 2 } = \dfrac{ \sqrt{ 2 \cdot \ 15.6^2+2 \cdot \ 18.6^2 - 12.3^2 } }{ 2 } = 16.024 \ \\ m_b = \dfrac{ \sqrt{ 2c^2+2a^2 - b^2 } }{ 2 } = \dfrac{ \sqrt{ 2 \cdot \ 18.6^2+2 \cdot \ 12.3^2 - 15.6^2 } }{ 2 } = 13.701 \ \\ m_c = \dfrac{ \sqrt{ 2a^2+2b^2 - c^2 } }{ 2 } = \dfrac{ \sqrt{ 2 \cdot \ 12.3^2+2 \cdot \ 15.6^2 - 18.6^2 } }{ 2 } = 10.53

Calculate another triangle


Look also our friend's collection of math problems and questions:

See more information about triangles or more details on solving triangles.