What the formula says
Put t = tan(x/2). Then
- sin x = 2t / (1 + t²)
- cos x = (1 − t²) / (1 + t²)
- tan x = 2t / (1 − t²)
Holds when tan(x/2) exists, that is when x is not 180° + n · 360°. The formula for tan x also needs t² ≠ 1, because tan x has no value at 90° + n · 180°.
What makes the formulas useful is that everything ends up in one variable. An expression in sin x and cos x becomes a fraction in t, and a fraction can be handled with algebra.
It is also called the Weierstrass substitution.
Where the formulas come from
Start with the double angle formula for the sine, writing x as twice x/2:
- sin x = 2 sin(x/2) cos(x/2)
Then write 1 as sin²(x/2) + cos²(x/2), by the Pythagorean identity, and divide the top and bottom by cos²(x/2):
- sin x = 2 sin(x/2) cos(x/2) / (sin²(x/2) + cos²(x/2)) = 2 tan(x/2) / (tan²(x/2) + 1) = 2t / (1 + t²)
The same treatment of cos x = cos²(x/2) − sin²(x/2) gives (1 − t²)/(1 + t²). The division by cos²(x/2) is the reason for the condition: it only works when cos(x/2) ≠ 0.
Worked examples
A check. x = 50°, so x/2 = 25° and t = tan 25° ≈ 0.4663. Then t² ≈ 0.2174 and 1 + t² ≈ 1.2174. That gives sin 50° ≈ 2 · 0.4663 / 1.2174 ≈ 0.766 and cos 50° ≈ (1 − 0.2174) / 1.2174 ≈ 0.643. Both agree with a calculator.
Backwards: the angle from t. If t = 1/2, then sin x = 1/(1 + 1/4) = 0.8 and cos x = (3/4)/(5/4) = 0.6. That is the 3-4-5 triangle, and x ≈ 53.13°. Each t gives a point on the unit circle: (2t)² + (1 − t²)² = (1 + t²)², so sin²x + cos²x comes to 1.
An integral. The integral of 1/(1 + cos x) dx has no obvious ordinary rule. With t = tan(x/2), dx = 2 dt/(1 + t²) and 1 + cos x = 2/(1 + t²). The integrand becomes (1 + t²)/2 · 2/(1 + t²) = 1, so the integral is t + C = tan(x/2) + C. Differentiate to check: the derivative of tan(x/2) is 1/(2cos²(x/2)) = 1/(1 + cos x).
The substitution is for integrands that are rational in sin x and cos x. Shorter routes often exist (an ordinary substitution, or product-to-sum), and the half-angle substitution is what is left when none of them works.
Common mistakes
- Forgetting dx. The substitution changes the differential too: dx = 2 dt/(1 + t²). Without it the integral is wrong.
- Crossing x = 180°. There t goes to infinity. An integral over an interval containing 180° (or 180° + n · 360°) has to be split in two.
- Mixing up the numerators for sine and cosine. The sine has 2t on top and the cosine 1 − t². Check with t = 0 (x = 0°): sin 0° = 0 and cos 0° = 1.
- Taking t to be tan x. t is the tangent of the half angle. Use tan x = 2t/(1 − t²) for the whole angle.
Common questions
Why is it called the Weierstrass substitution?
The name comes from Karl Weierstrass, who taught it in his lectures. The substitution is older than that, and
many textbooks simply call it the tangent half-angle substitution or the t-substitution.
How does the tangent formula follow from the addition formula?
It is the tangent addition formula with u = x/2 and
v = x/2, which gives 2t/(1 − t²).
Do I need to memorise them?
That depends on the course and on which formula sheet is allowed. The derivation above takes three lines and is the safest way to get the signs right.

