Law of Sines Calculator

The law of sines says every side of a triangle bears the same ratio to the sine of its opposite angle, and that single equality solves any triangle where you already have one matched side-and-angle pair. This calculator handles both cases: two angles with a side (AAS or ASA), which always gives exactly one triangle, and two sides with a non-included angle (SSA), which may give two, one or none. When two triangles fit, it shows both rather than quietly picking one. Angles are in degrees.

Calculator

This calculator runs in your browser. Enable JavaScript for live results — the inputs, formula and worked example below remain fully readable without it.

Inputs this calculator takes, with typical values
InputWhat to enterExample
What you knowAAS is always determinate; SSA is the ambiguous case.Two angles and a side (AAS / ASA)
Angle AThe angle opposite side a. This is the pair the sine rule is built on.40 °
Side a (opposite angle A)The side facing angle A, in any unit.10
Angle BThe second known angle, opposite side b. A + B must be under 180°.60 °
Side b (opposite angle B)The second known side, in the same unit as side a. Used in SSA mode.10

It returns

  • Side c (opposite angle C) — The side the sine rule solves for in both modes.
  • Angle B — In SSA mode this is the acute solution; check the warnings for the obtuse alternative.
  • Angle C
  • Side b
  • Area
  • Perimeter
  • Circumradius R — Radius of the circle through all three vertices; the common ratio a/sin A equals 2R.

The formula

asinA=bsinB=csinC=2R
sinB=bsinAa

In plain text: a / sin A = b / sin B = c / sin C = 2R

  • a, b, cSide lengths (units)
  • A, B, CThe angles opposite sides a, b and c respectively (degrees)
  • RCircumradius — radius of the circle through all three vertices (units)

The common ratio equals the circumdiameter 2R, which is the extended law of sines. It needs one complete side-and-opposite-angle pair to start from.

Updated Category Triangle Solvers & Trigonometric Laws Verified against published test cases Reading time 10 min

One ratio, shared by all three sides

In any triangle, a side divided by the sine of the angle facing it gives the same number for all three pairs: a/sin A = b/sin B = c/sin C. That shared value is not arbitrary — it equals the diameter of the circle through all three vertices, 2R, which is why the relationship is sometimes called the extended law of sines.

The proof is short. Drop the altitude h from vertex C onto side c. In the two right triangles it creates, h = b·sin A and h = a·sin B. Setting those equal gives b·sin A = a·sin B, which rearranges to a/sin A = b/sin B. Repeat with a different altitude for the third ratio.

The rule needs a complete pair to start: one side together with the angle opposite it. Given that, one more piece of information finishes the triangle. Two angles and any side is the well-behaved case, because the third angle is just 180° minus the other two, and every side then follows from a single multiplication. Two sides and a non-included angle is the awkward case, because the inverse sine cannot tell an angle from its supplement — sin 60° and sin 120° are the same number.

If you have no matched pair at all — three sides, or two sides with the angle between them — the sine rule cannot start, and you need the law of cosines calculator instead.

The two modes, and why SSA is ambiguous

AAS and ASA. Find the third angle first, C = 180° − A − B. Then each unknown side is the known side scaled by a ratio of sines: b = a·sin B / sin A. Because the angles are fixed before any side is computed, exactly one triangle exists and there is nothing to check beyond A + B < 180°. ASA and AAS differ only in which side you were handed; the arithmetic is identical once the third angle is filled in.

SSA. Here you compute sin B = b·sin A / a and then take the inverse sine — and arcsin only ever returns the acute answer. The obtuse angle 180° − B has the same sine and may also close a valid triangle. Whether it does depends on a comparison you can make before computing anything:

  • If b·sin A > a, then sin B would exceed 1 and no triangle exists — side a is too short to reach the far side.
  • If b·sin A = a exactly, there is one right triangle, with B = 90°.
  • If a < b (and a > b·sin A), two triangles exist, one with B acute and one with B obtuse.
  • If a ≥ b, one triangle exists: the obtuse alternative would make A + B exceed 180°, so it is rejected.

The quantity b·sin A is the altitude from vertex C to line AB. Picture swinging side a from vertex B like a compass: if its length is shorter than that altitude it never reaches the line, if it equals the altitude it just touches, and if it is between the altitude and b it crosses in two places. That picture is the whole ambiguous case, and this calculator reports both crossings when they exist.

Worked example: an AAS triangle and an ambiguous one

Part one, AAS. A = 40°, B = 60°, and the side opposite A measures 10.000 m.

  1. Third angle. C = 180 − 40 − 60 = 80°.
  2. Common ratio. a/sin A = 10 / sin 40° = 10 / 0.642788 = 15.557238. This is 2R.
  3. Side b. b = 15.557238 × sin 60° = 15.557238 × 0.866025 = 13.4730 m.
  4. Side c. c = 15.557238 × sin 80° = 15.557238 × 0.984808 = 15.3209 m.
  5. Circumradius. R = 15.557238 / 2 = 7.7786 m.
  6. Area. ½ab·sin C = ½ × 10 × 13.4730 × 0.984808 = 66.3414 m².
  7. Check. The largest side (c) faces the largest angle (C = 80°), and the smallest side (a) faces the smallest angle. Consistent.

Part two, SSA. Now suppose you know a = 7.000, b = 10.000 and A = 40°.

  1. Altitude test. b·sin A = 10 × 0.642788 = 6.42788. Since 6.42788 < 7 < 10, we are in the two-solution band.
  2. sin B. = b·sin A / a = 6.42788 / 7 = 0.918268.
  3. Acute solution. B = arcsin 0.918268 = 66.6742°, so C = 180 − 40 − 66.6742 = 73.3258°, and c = 7 × sin 73.3258° / sin 40° = 7 × 0.957952 / 0.642788 = 10.4322.
  4. Obtuse solution. B = 180 − 66.6742 = 113.3258°, so C = 26.6742°, and c = 7 × 0.448916 / 0.642788 = 4.8887.

Both are genuine triangles with a = 7, b = 10 and A = 40°. They differ in third side by more than a factor of two, so choosing between them from a sketch or a third measurement is not optional.

Reading the result and avoiding the trap

Start with the ordering check: the largest angle always faces the largest side, and the smallest faces the smallest. If your output breaks that ordering, an input pair has been mismatched — almost always an angle entered against the wrong side.

In SSA mode, read the warning before the numbers. The outputs always show the acute solution because arcsin produces it, and when a second triangle exists the calculator lists both in the table. Deciding between them needs information the trigonometry does not have: a sketch showing whether the angle at B looks obtuse, a rough measurement of the third side, or the knowledge that the triangle is acute by construction. The two candidate positions of vertex B sit on the same line, mirror images of each other about the foot of the altitude from C, and there is no algebraic way to prefer one.

The circumradius is a useful by-product. R = a/(2 sin A) is the radius of the circle through all three vertices, which is directly usable in layout work: mark the circumcircle and every vertex falls on it. On a right triangle R is exactly half the hypotenuse, since a 90° angle inscribed in a circle always subtends a diameter — a check the calculator's own numbers confirm when you set A = 90°.

On precision: solving for a side is stable, but solving for an angle from a sine is poorly conditioned near 90°, because the sine curve is flat there and a small error in the ratio moves the angle a long way. The standard defence is to solve the largest angle with the cosine rule first, then finish with the sine rule on angles that are certainly acute.

The SSA cases for b = 10 and A = 40&deg;

The altitude from C is b·sin A = 10 × sin 40° = 6.4279. How side a compares with that altitude and with b decides how many triangles fit.
Side aConditionTrianglesAngle B
3.0000a < b·sin ANonesin B = 2.1426, impossible
6.4279a = b·sin AOne (right)90.0000°
7.0000b·sin A < a < bTwo66.6742° or 113.3258°
9.0000b·sin A < a < bTwo45.5784° or 134.4216°
10.0000a = bOne (isosceles)40.0000°
12.0000a > bOne32.3884°

At a = b the obtuse alternative would be 140°, and 40° + 140° = 180° leaves no third angle, so it is rejected. Every row above is sin B = 10·sin40°/a evaluated at that a.

Mistakes the sine rule invites

  • Pairing a side with the wrong angle. The rule matches each side with the angle opposite it, never with an adjacent one. This is the single most common error and it produces plausible wrong answers.
  • Accepting the arcsin answer in SSA without checking. Inverse sine returns only the acute value. When a < b·sin A there is no triangle, and when b·sin A < a < b there are two.
  • Trying to start from SSS or SAS. Neither gives a matched pair, so the sine rule has nothing to equate. Use the cosine rule to get the first angle, then switch.
  • Solving the largest angle with the sine rule. If it is obtuse, arcsin silently returns its acute supplement. Solve the largest angle with the cosine rule instead.
  • Leaving the calculator in radian mode. sin(40) in radians is 0.745 rather than 0.643, an error large enough to change the answer completely but small enough to look believable.
  • Expecting AAA to work. Three angles fix the shape but not the size; every scaled copy has the same angles, so no side can be recovered.

Where the sine rule sits among triangle methods

The two classical rules divide the work cleanly. Use the sine rule for AAS, ASA and SSA; use the law of cosines calculator for SAS and SSS. A common professional habit is to run the cosine rule once to get the largest angle and then finish with the sine rule, which is faster and immune to the arcsin ambiguity.

For a right triangle you do not need either: the ratios reduce to plain SOHCAHTOA, handled by the right triangle calculator, with the Pythagorean theorem calculator for the sides. If all you want is the area from a solved triangle, the triangle area calculator takes it straight from three sides with Heron's formula.

The rule matters far beyond the classroom because it is the basis of triangulation. Measure one baseline accurately, then measure angles to a distant point from each end; the sine rule converts those two angles and one distance into the two unknown distances. That is how coastal survey, astronomical parallax and the original national geodetic networks were built, and it is why an instrument that measures angles well is worth more than a longer tape. For the underlying angle functions themselves, see the sin cos tan calculator and the inverse trig functions calculator.

Frequently asked questions

What is the law of sines?

In any triangle, a/sin A = b/sin B = c/sin C, where each side is paired with the angle opposite it. The common value equals the diameter of the circumscribed circle, 2R. Given one matched side-and-angle pair plus one more measurement, it solves the whole triangle.

What is the ambiguous case?

It is the SSA situation: two sides and an angle not between them. Because sin B and sin(180° − B) are equal, the inverse sine cannot tell which angle you have. When the side opposite the known angle is shorter than the other known side but longer than the altitude b·sin A, two genuinely different triangles fit and you need extra information to choose.

How do I know how many triangles fit my SSA data?

Compare side a with b·sin A and with b. If a < b·sin A there is none; if a equals b·sin A there is one right triangle; if b·sin A < a < b there are two; if a ≥ b there is one. This calculator runs that test and reports both solutions when two exist.

Can I use the law of sines with three sides?

No. It needs at least one side paired with its opposite angle, and SSS gives no angles at all. Use the law of cosines to find one angle first — take the largest, so the sine rule cannot then hit the arcsin ambiguity — and finish with the sine rule if you prefer.

What is the difference between ASA and AAS?

Only which side you were given: ASA means the known side lies between the two known angles, AAS means it does not. Both are solved identically, because the third angle follows from 180° minus the other two and every side then comes from one sine ratio. Both always give exactly one triangle.

What is the circumradius and why does the calculator report it?

It is the radius of the circle passing through all three vertices, and it equals half the common ratio: R = a/(2 sin A). It is the natural output of the sine rule rather than an extra calculation, and it is directly useful for layout, since striking that circle puts every vertex on it. On a right triangle it is exactly half the hypotenuse.

Why does my answer disagree with the textbook by a factor I cannot place?

Check the angle mode on your own calculator. Evaluating sin(40) in radians gives 0.7451 instead of 0.6428, which propagates into every side. The other frequent cause is pairing a side with an adjacent angle rather than the opposite one.

Can three angles alone determine a triangle?

No. Three angles fix the shape but not the scale, so an infinite family of similar triangles shares them. You need at least one length. That is why the sine rule always requires a side, and why triangulation surveys must measure one baseline no matter how many angles they take.

References

  • CRC Standard Mathematical Tables and Formulae, 33rd ed. — CRC Press
  • Elementary Surveying: An Introduction to Geomatics, 15th ed. (triangulation) — Ghilani, Pearson
  • Trigonometry, 11th ed. — Lial, Hornsby, Schneider and Daniels, Pearson