Matheno - Learn Well and Excel

A.3 Derivatives of sin x and cos x

On this screen we’re going to develop formally the derivatives of $\sin x$ and $\cos x,$ which we will need again and again. We’ll of course also practice using them in the Practice Problems below.

In case you’d simply like to memorize these results so you can move on:

Derivatives of sin x and cos x
\[\dfrac{d}{dx}\sin x = \cos x \quad \text{and} \quad \dfrac{d}{dx}\cos x = -\sin x\]

Yep: the derivative of sin is cosine, and the derivative of cosine is negative sine.
You just gotta remember those.

Tip iconMany students find it helpful to remember that, as it turns out, the trig functions that start with “co,” like “cosine,” have a negative sign in their derivatives, while the trig functions without “co” at their start do not. Hence we can quickly remember that the derivative of cosine is negative sine, while the derivative of sine is (positive) cosine.

You can see a full list of the trig function derivatives on our Handy Table of Trig Function Derivatives, quickly accessible from the “Key Formulas” drop-down menu toward the upper right of every screen. We’ll develop the results for sin and cos below, and for the other trig functions later in this Chapter once we have more tools.


I. Derivative of $\sin x$: $\dfrac{d}{dx}\sin x = \cos x$

 
To find the derivative of $\sin x,$ we start, as always, with the definition of the derivative applied to the function. Recall the definition of the derivative:
\[\dfrac{d}{dx}f(x) = \lim_{h \to 0}\frac{f(x+h) – f(x)}{h}\]

We have $f(x) = \sin (x)$.
Hence
\[f(x+ h) = \sin(x+h) = \sin x \cos h + \sin h \cos x\] where we used the sine addition formula $\sin(x+y) = \sin x \cos y + \sin y \cos x$. (All such trig formulas are available in our Handy Table of Trig Formulas and Identities, also available from the Key Formulas drop-down menu in the upper right of every screen.)

Making these substitutions in the definition of the derivative for $f(x) = \sin x$ gives us
\begin{align*}
\dfrac{d}{dx}\sin x &= \lim_{h \to 0}\frac{\sin(x+h) – \sin x}{h} \\[8px] &= \lim_{h \to 0}\frac{(\sin x \cos h + \sin h \cos x) – \sin x}{h} \\[8px] &= \lim_{h \to 0}\frac{\sin x \cos h – \sin x + \sin h \cos x }{h} \\[8px] &= \lim_{h \to 0}\frac{\sin x \cos h – \sin x}{h} + \lim_{h \to 0}\frac{\sin h \cos x}{h}\\[8px] &= \lim_{h \to 0}\frac{\sin x \,(\cos h – 1)}{h} + \lim_{h \to 0}\frac{\cos x \sin h}{h} \quad [\sin x \text{ and } \cos x \text{ are unaffected by the limit}] \\[8px] &= \sin x\left[ \lim_{h \to 0}\frac{\cos h -1}{h}\right] + \cos x \left[ \lim_{h \to 0}\frac{\sin h}{h}\right] \quad (*)
\end{align*}
You might recognize the “Special Trig Limits” we learned when we were first exploring limits:
\[\lim_{\theta \to 0}\frac{\cos \theta – 1}{\theta} = 0 \quad \text{and}\quad \lim_{\theta \to 0} \frac{\sin \theta}{\theta} = 1\] The actual reason we introduced those then is because we need them now to complete our proof, continuing from the line marked (*):
\begin{align*}
& \phantom{\lim_{h \to 0}\frac{\sin x \cos h – \sin x}{h} + \lim_{h \to 0}\frac{\sin h \cos x}{h} \quad [\sin x \text{ and } \cos x \text{ are unaffected by the limit}]} \\
\dfrac{d}{dx}\sin x &= \sin x\left[ \lim_{h \to 0}\frac{\cos h -1}{h}\right] + \cos x \left[ \lim_{h \to 0}\frac{\sin h}{h}\right] \quad (*) \\[8px] &= \sin x\cancelto{0}{\left[\lim_{h \to 0}\frac{\cos h -1}{h} \right]} + \cos x \cancelto{1}{\left[\lim_{h \to 0}\frac{\sin h}{h} \right]} \\[8px] &= \cos x
\end{align*}
That is, we have the key result:

\[ \dfrac{d}{dx}\sin x = \cos x\]

The following Exploration let’s you explore this relationship graphically.

EXPLORATION 1: Moveable tangent line for $y = \sin x$

The top graph below shows $y = \sin x.$

The lower graph automatically updates to show the value of the function’s derivative at the same point $x=a$ that’s in the upper graph. That is, for each value of $x=a,$ we automatically plot the point $(a, f'(a))$ on the lower graph.

Verify for yourself:

  • Are the zeros of $f'(x)$ where you expect them to be? (That is, where the tangent line to the graph of $y = \sin x$ is horizontal?)
  • Are the maximum and minimum values of $f'(x)$ where you expect them to be? (Where is the slope of the curve $y = \sin x$ steepest in the positive and negative directions?)

Graph of $f(x) = \sin x$ versus x
$\Downarrow$ We automatically plot the point (, ) in the graph below. $\Downarrow$

Graph of f ‘(x) versus x

We can of course show all of the values of $f'(x)$ at once, as if we traced the values we obtain by changing the value of a point-by-point. To do so, check this box:

We hope that you can see for yourself how the way the slope of the tangent line to the curve $y = \sin x$ leads directly to the derivative $f'(x) = \cos x.$

 


II. Derivative of $\cos x$: $\dfrac{d}{dx}\cos x = -\sin x$

 
The approach to finding the derivative of $\cos x$ is very much the same as that for $\sin x$ above; we’ll just make use of a different trig addition formula.

We start of course with the definition of the derivative applied to $g(x) = \cos x.$
Then
\[g(x+h) = \cos(x+h) = \cos x \cos h – \sin x \sin h\] where we have used the trig addition formula $\cos(x+y) = \cos x \cos y – \sin x \sin y.$

The definition of the derivative for $g(x) = \cos x$ then gives us
\begin{align*}
\dfrac{d}{dx}\cos x &= \lim_{h \to 0}\frac{\cos(x+h) – \cos x}{h} \\[8px] &= \lim_{h \to 0}\frac{(\cos x \cos h – \sin x \sin h) – \cos x}{h} \\[8px] &= \lim_{h \to 0}\frac{\cos x \cos h – \cos x – \sin x \sin h }{h} \\[8px] &= \lim_{h \to 0}\frac{\cos x \cos h – \cos x}{h} – \lim_{h \to 0}\frac{\sin x \sin h}{h} \\[8px] &= \lim_{h \to 0}\frac{\cos x (\cos h – 1)}{h} – \lim_{h \to 0}\frac{\sin x \sin h}{h} \quad [\sin x \text{ and } \cos x \text{ are unaffected by the limit}] \\[8px] &= \cos x\left[ \lim_{h \to 0} \frac{\cos h – 1}{h}\right] – \sin x \left[ \lim_{h \to 0}\frac{\sin h}{h}\right] \quad \text{[Same two “special trig limits” as above]}\\[8px] &= \cos x \cancelto{0}{\left[ \lim_{h \to 0}\frac{\cos h – 1}{h}\right]} – \sin x \cancelto{1}{\left[ \lim_{h \to 0}\frac{\sin h}{h}\right]} \\[8px] &= -\sin x
\end{align*}
That is, we have another key result:

\[ \dfrac{d}{dx}\cos x = -\sin x\]

The following Exploration again let’s you see the graphical relationship between the function $g(x) = \cos x$ and its derivative $g'(x) = -\sin x.$

EXPLORATION 2: Moveable tangent line for $y = \cos x$

The top graph below shows $y = \cos x.$

The lower graph automatically updates to show the value of the function’s derivative at the same point $x=a$ that’s in the upper graph. That is, for each value of $x=a,$ we automatically plot the point $(a, f'(a))$ on the lower graph.

Verify for yourself:

  • Are the zeros of $g'(x)$ where you expect them to be? (That is, where the tangent line to the graph of $y = \cos x$ is horizontal?)
  • Are the maximum and minimum values of $g'(x)$ where you expect them to be? (Where is the slope of the curve $y = \cos x$ steepest in the positive and negative directions?)

Graph of $g(x) = \cos x$ versus x
$\Downarrow$ We automatically plot the point (, ) in the graph below. $\Downarrow$
Graph of g'(x) versus x

We can of course show all of the values of $g'(x)$ at once, as if we traced the values we obtain by changing the value of a point-by-point. To do so, check this box:

We hope that you can see for yourself how the way the slope of the tangent line to the curve $y = \cos x$ leads directly to the derivative $f'(x) = -\sin x.$

Practice Problems

As we said above, we’ll use these two derivatives again and again and again, so you’ll have them memorized soon enough. Let’s do a few quick problems now to start:

This content is available to logged-in users.
To interact with all of the content of this page, including Check Questions and Practice Problems (each with a complete solution), you must be logged in.
  • You can immediately sign in for free using your Facebook, Google, or Apple account.
  • If you would rather use your dedicated Matheno.com account, please enter your username and password below. (Don't have a free account but would like one? You can create it in 60 seconds here.)
This content is available to logged-in users.
This content is available to logged-in users.
This content is available to logged-in users.

These two derivatives complete our initial toolkit of derivatives: You can now find the derivative of power functions, polynomials, exponential, and the two fundamental trig functions. In the next section we’ll see how to take the derivative of a function that is the product or quotient of two other functions, things like $xe^x$ and $\dfrac{\sin x}{\cos x}.$


The Upshot

  1. The derivative of $\sin x$ is $\dfrac{d}{dx}\sin x = \cos x.$
  2. The derivative of $\cos x$ is $\dfrac{d}{dx}\cos x = -\sin x.$


Questions or comments about what’s on this screen, or anything else other Calculus-related? Please post on the Forum!