Sum-to-Product Calculator - Trig Identity Converter

Which sum are you converting?

Type numbers (75), multiples of π (2pi/3), or expressions in one variable (5x, x/2, 3x + 15). Symbolic angles are what you need for solving equations.

Results

sin(5x) + sin(3x) equals

2 sin(4x) cos(x)

Half-sum (A + B)/2

4x

Half-difference (A − B)/2

x

Identity applied

sin A + sin B = 2 sin((A+B)/2) cos((A−B)/2)

Step-by-step conversion

1. sin A + sin B = 2 sin((A+B)/2) cos((A−B)/2)

2. A = 5x, B = 3x

3. (A + B)/2 = (5x + 3x)/2 = 4x

4. (A − B)/2 = (5x − 3x)/2 = x

5. sin(5x) + sin(3x) = 2 sin(4x) cos(x)

Numeric check at x = 1 rad

Sum form

-0.958924 + 0.14112

-0.817804

Product form

2 × -0.756802 × 0.540302

-0.817804

✓ Both sides agree to 9 decimal places — the conversion is exact, not an approximation.

sin(5x) + sin(3x) plotted against its envelope ±2 cos(x)

x = 0x = 12.5664 rad

The green curve is the sum; the dashed pair is the slow factor scaled to ±2. The product form says the sum is one fast wave whose amplitude is squeezed by the slow one — that is exactly what beats are.

All four sum-to-product conversions for A = 5x and B = 3x

Sum formProduct form
sin(5x) + sin(3x)2 sin(4x) cos(x)
sin(5x) − sin(3x)2 cos(4x) sin(x)
cos(5x) + cos(3x)2 cos(4x) cos(x)
cos(5x) − cos(3x)−2 sin(4x) sin(x)

Solving sin(5x) + sin(3x) = 0

A product is zero only when a factor is zero. That is the whole reason for converting: 2 sin(4x) cos(x) splits into 2 independent equations.

sin(4x) = 0

x = πn/4

Solutions in [0, )

0π/4π/23π/4π5π/43π/27π/4

cos(x) = 0

x = π/2 + πn

Solutions in [0, )

π/23π/2

Check both lists before you write a final answer — when one frequency is a multiple of the other, the second family often repeats values already in the first.

How to Use This Calculator

  1. Tap the button that matches your expression — sin A + sin B, sin A − sin B, cos A + cos B, or cos A − cos B. Order matters for the two subtraction cases.
  2. Set “Angle unit” first. Degrees mode reads 75 as 75°; radian mode accepts pi or π.
  3. Type the angles into “Angle A” and “Angle B”. Use the same letter in both — 5x and 3x, not 5x and 3t.
  4. Read the product form at the top, then the step-by-step box to see the half-sum and half-difference that produced it.
  5. If your angles contain a variable, scroll to “Solving … = 0” for the general solution and every root in one full turn.

Share this calculator

Help others solve their calculations

Found this calculator helpful? Share it with your friends, students, or colleagues who might need it!

Sum-to-Product Calculator: Rewriting Sine and Cosine Sums as Products

About the Author

Marko Šinko - Co-Founder & Lead Developer

Marko Šinko

Co-Founder & Lead Developer, AI Math Calculator

Lepoglava, Croatia
Advanced Algorithm Expert

Croatian developer with a Computer Science degree from University of Zagreb and expertise in advanced algorithms. Co-founder of award-winning projects, ensuring precise mathematical computations and reliable calculator tools.

📅 Published:
Sum-to-Product Calculator illustration showing two separate sine waves merging into one product expression with half-angle brackets

A sum-to-product calculator exists for one reason: a sum has no zero-product property, and a product does. Faced with sin 5x + sin 3x = 0 you can stare at it all night — there is no algebraic move that pulls x out of a sum of two sines. Rewrite the same thing as 2 sin 4x cos x and it falls apart in one line, because a product is zero exactly when one of its factors is. That single structural change is what the four sum-to-product identities buy you, and it is why they show up in equation-solving, in integration, and in the physics of beating tones. Here are the four formulas, then the reasoning behind them, then the places they actually earn their keep.

The four sum-to-product identities. In every one, S = (A+B)/2 and D = (A−B)/2.
Sum formProduct formWatch for
sin A + sin B2 sin S cos DSine keeps the half-sum
sin A − sin B2 cos S sin DFunctions swap places
cos A + cos B2 cos S cos DThe only all-cosine one
cos A − cos B−2 sin S sin DThe minus sign lives here

One Pattern, Four Rows

Nobody memorises four unrelated formulas. Look at the table again and three rules do all the work. Every right-hand side is 2 times a product of two trig functions. The first factor always takes the half-sum S = (A+B)/2, the second always takes the half-difference D = (A−B)/2 — that never varies. What changes is which functions appear, and there the logic is almost boringly consistent: adding sines gives you sine-first, subtracting sines flips it to cosine-first, the cosine sum stays all-cosine, and the cosine difference is the odd one out with two sines and a leading minus.

That minus sign is where marks go missing. It is not decorative. Cosine decreases on 0 to π, so a bigger angle gives a smaller cosine, and cos A − cos B comes out negative whenever A > B in that range — the minus sign is the formula being honest about direction. Drop it and every answer flips sign. The other trap is order: sin A − sin B and sin B − sin A differ by a sign because D changes sign, while both sum identities are symmetric and don’t care which angle you call A. Type the angles into the calculator in the order they appear in your problem and this stops being something you have to think about.

Where the Formulas Come From

These aren’t new identities. They’re the angle-addition formulas read backwards, and deriving them takes about four lines. Start with the two expansions:

sin(S + D) = sin S cos D + cos S sin D

sin(S − D) = sin S cos D − cos S sin D

add them: sin(S + D) + sin(S − D) = 2 sin S cos D

Now the trick. Set A = S + D and B = S − D. Solving that little system gives S = (A+B)/2 and D = (A−B)/2, and substituting turns the line above into sin A + sin B = 2 sin((A+B)/2) cos((A−B)/2). Subtract the two expansions instead of adding and you get the sin A − sin B row. Do the same with the cosine expansions — where cos(S+D) and cos(S−D) differ by the sign of the sin S sin D term — and the last two rows drop out, minus sign included. The same substitution powers the double angle identities (set A = B) and the half angle formulas, which is a useful thing to notice: half-sum and half-difference are the same halving idea applied to two angles at once.

Solving sin 5x + sin 3x = 0 in Four Lines

This is the problem the identity was invented for. A = 5x and B = 3x, so S = (5x+3x)/2 = 4x and D = (5x−3x)/2 = x:

sin 5x + sin 3x = 2 sin 4x cos x = 0

sin 4x = 0 → 4x = nπ → x = nπ/4

cos x = 0 → x = π/2 + nπ

Two families, and here is the part textbooks skip. List the first family inside one turn: 0, π/4, π/2, 3π/4, π, 5π/4, 3π/2, 7π/4 — eight values. Now list the second: π/2 and 3π/2. Both are already there, because π/2 = 2π/4 and 3π/2 = 6π/4. The cosine factor contributes nothing new for this particular pair of frequencies. Students routinely hand in ten solutions where there are eight, and the marker takes the difference. Whether the second family is redundant depends entirely on the arithmetic between the two frequencies, so check it every time rather than assuming either way — the calculator above prints both lists side by side so the overlap is visible at a glance.

One more warning about this shape of problem. If you see 2 sin 4x cos x = 0 and divide both sides by cos x to “simplify”, you have just deleted every root where cos x = 0. Dividing by an expression that can be zero loses solutions. Set each factor to zero instead — always.

Getting Exact Values Out of Ugly Angles

The second real use is turning angles you have no reference value for into angles you do. Take cos 75° − cos 15°. Neither cosine is a value you know by heart, and a decimal answer is worth no marks in an exact-value question. Convert with the cosine-difference row: S = (75+15)/2 = 45° and D = (75−15)/2 = 30°, both straight off the unit circle.

cos 75° − cos 15° = −2 sin 45° sin 30°

= −2 × (√2/2) × (1/2) = −√2/2 ≈ −0.707107

check: 0.258819 − 0.965926 = −0.707107 ✓

The same pair of angles run through the sine sum gives sin 75° + sin 15° = 2 sin 45° cos 30° = 2 × (√2/2) × (√3/2) = √6/2 ≈ 1.224745. Two unknown angles in, one clean surd out, no calculator needed. The trick generalises: any two angles whose half-sum and half-difference are both special angles will collapse this way, which in practice means pairs that average to 30°, 45°, or 60° and sit an equal special distance either side. 105° and 15° average to 60° and differ by 45°. 165° and 75° average to 120° and differ by 45°. Spotting that pairing is the whole skill, and it is worth knowing before an exam where the cosine of an arbitrary angle is off-limits.

Beats: What the Product Form Sounds Like

Play a 440 Hz tone and a 444 Hz tone together and you don’t hear two notes. You hear one note, wavering. The sum-to-product identity explains exactly why, and it is the cleanest physical demonstration of the formula anywhere:

sin(2π·440t) + sin(2π·444t)

= 2 sin(2π·442t) · cos(2π·2t)

Read the right-hand side as a description rather than an equation. There is a fast wave at 442 Hz — the average of the two tones, which is the pitch your ear reports — multiplied by a slow cosine at 2 Hz that squeezes and releases its amplitude. The graph in the calculator draws exactly this: the green sum curve pinched inside a dashed envelope.

Now the detail that trips up half the physics class. The cosine factor cycles 2 times per second, but you hear 4 beats per second. Loudness follows the absolute value of the envelope, and |cos| peaks twice per cycle of cos — once positive, once negative — so the audible beat frequency is 2 × 2 = 4 Hz, which is just |444 − 440|. That is the rule piano tuners work by: count the beats per second and you have read the frequency error directly off the two strings, no meter required. Tune until the beating slows to nothing and the strings match. The same maths runs amplitude modulation in radio, moiré patterns in printing, and the interference fringes in a Michelson interferometer — anywhere two nearby frequencies add, a sum-to-product conversion tells you what the combination looks like.

The Six Errors That Cost Marks

  • Losing the minus on cos A − cos B. It is the only identity of the four with a negative coefficient. Forget it and your answer is right in magnitude and wrong in sign, which usually scores zero.
  • Putting the half-difference in the first factor. The half-sum always comes first. In sin A − sin B = 2 cos S sin D, it is the cosine that takes S and the sine that takes D — the functions swap, the angles never do.
  • Dividing by a factor instead of zeroing it. Cancelling cos x from 2 sin 4x cos x = 0 throws away real roots. Every factor gets set to zero separately.
  • Reporting duplicate solutions. When one frequency divides the other, the two solution families overlap. Merge the lists before you count them.
  • Mixing degrees and radians. An answer of x = nπ/4 is nonsense if you set the problem up in degrees; it should read x = 45n°. Pick a unit at the start and keep it.
  • Reaching for it on sin A + cos B. No sum-to-product identity mixes a sine with a cosine. Convert first with cos B = sin(90° − B), then apply the sine rule to the matching pair.

When a Sum-to-Product Calculator Is the Wrong Tool

Converting is not automatically an improvement. If you only need a number, sin 5x + sin 3x and 2 sin 4x cos x cost the same to evaluate — the identity buys you nothing. The product form pays off in four specific situations: solving an equation that equals zero, hunting an exact value from awkward angles, integrating, and describing physical interference where the envelope is the point. That third one often runs backwards: to integrate a product you want it as a sum, which is what a product-to-sum calculator does with the same four identities read right to left.

In signal processing the traffic usually runs the opposite way. Fourier analysis wants everything as a sum of pure sinusoids, so a product of two cosines gets expanded, not factored. Same identities, read right to left. Knowing which direction serves your goal is more useful than knowing the formulas, and if you’re unsure whether a rearrangement you’ve written is even valid, a trig identity verifier will settle it in a second. For the full catalogue of related conversions, the list of trigonometric identities is the reference worth bookmarking, and general trigonometry tools cover the surrounding groundwork.

Frequently Asked Questions

Still Have Questions?

The detailed content on this page provides comprehensive explanations and examples to help you understand better.