Key takeaways
- d/dx cos(x) = −sin(x), and d/dx cos(ax) = −a·sin(ax).
- The minus sign is there because cosine starts at its peak and goes downhill.
- The #1 mistake is losing the minus sign.
- Multiply by a for derivatives; divide by a only for integrals.
- x must be in radians, not degrees.
In this guide
What is the derivative of cos?
A derivative is the slope of a graph at a point. The cosine graph is a wave that starts at its highest point, 1, when x = 0. Right at the top it is flat, so the slope is 0. Then it heads downhill, so the slope turns negative, and it is steepest at x = π/2, where the slope is −1.
If you plot all those slopes, you get the sine wave turned upside down: −sin(x). That is where the minus sign comes from. Cosine starts by going down.
Why does the derivative of cos matter?
Cosine describes anything that starts at its highest point and swings: a pendulum let go from the top, a weight pulled down on a spring and released, a point on a turning wheel. If cosine gives the position, its derivative gives the velocity.
The minus sign isn’t a trick to memorise. It tells you something real: just after you let go of a pendulum, it is moving back towards the middle.
The formula
| Symbol | What it means | Example |
|---|---|---|
| a | The number multiplying x inside the cosine | 2 |
| x | The point where you want the slope, in radians | 0.5 |
| sin(ax) | Sine of the same angle | sin(1) ≈ 0.8415 |
| −a·sin(ax) | The slope, which the calculator works out | −2 × 0.8415 ≈ −1.6829 |
The factor a comes from the chain rule: the inside ax has derivative a.
How to differentiate cos(ax) step by step
- 1Find a. It is the number in front of x inside the cosine. For cos(x), a = 1.
- 2Change cos to sin. Keep the same inside: sin(ax).
- 3Multiply by a and add a minus sign. You now have −a·sin(ax).
- 4Put in x for a slope at a point. Use radians: work out ax, find its sine, multiply by −a.
More quick results: cos(x/2) gives −(1/2)sin(x/2), and 4cos(x) gives −4sin(x).
Now try it yourself. Enter a and x (in radians) in the calculator below to see the slope with every step.
Try it yourself
Pre-filled with the example — change any value.
Common mistakes to avoid
- Dividing by a instead of multiplying. Dividing by a is for integrals:
∫cos(ax) dx = sin(ax)/a + C. See the sin and cos integral calculator. - Using degrees. The rule only works in radians. Convert with the degrees to radians calculator first.
- Double negatives. For
cos(−2x), a = −2, so the derivative is−(−2)sin(−2x) = 2sin(−2x) = −2sin(2x).
Tips and tricks
- Other insides: for
cos(x²), the inside derivative is 2x, so the answer is−2x·sin(x²). - Squares:
d/dx cos²x = 2cos x × (−sin x) = −2 sin x cos x, which equals−sin(2x). - Acceleration: differentiate twice to get
−a²cos(ax). The acceleration always points back towards the middle.
Where you’ll use it in real life
- Springs: if position is
cos(ωt), velocity is−ω·sin(ωt). - Pendulums: a swing released from its highest point follows a cosine curve (for small swings).
- Wheels and gears: the sideways position of a point on a turning wheel is a cosine.
- Electricity: alternating current is often written with cosine, and its rate of change matters in coils and capacitors.
Quick summary
The derivative of cos(ax) is −a·sin(ax): switch cos to sin, multiply by a, and put a minus sign in front. Work in radians and never drop the minus. Use the calculator above to find the slope at any point, with every step shown.
Worked example
A weight is pulled down and released on a spring, and its position is y = cos(2t) metres after t seconds. What is its velocity (in metres per second) at t = 0.5 seconds? The number in front of t is a = 2, and x = 0.5.
- 01d/dx[cos(2x)] = −2·sin(2x)
- 02At x = 0.5: −2 · sin(1 rad)
- 03sin(1) = 0.8415
- 04= −2 × 0.8415 = -1.6829
These numbers are pre-filled in the calculator above.
Frequently asked questions
What is the derivative of cos 2x?
It is −2sin(2x). Change cos to sin, keep 2x inside, multiply by 2, and add a minus sign.
Why is the derivative of cos x negative?
Cosine starts at its maximum at x = 0 and then decreases, so its slope is negative for a while. The slope values trace out −sin x.
What is the second derivative of cos x?
Differentiate −sin x to get −cos x. So the second derivative of cos x is −cos x.
What is the derivative of cos²x?
Use the chain rule on (cos x)²: 2cos x × (−sin x) = −2 sin x cos x, which also equals −sin(2x).


