How do you find the derivative of f(x)= cos (sin (4x))?

Dec 19, 2017

$\frac{\mathrm{dy}}{\mathrm{dx}} = - 4 \cos \left(4 x\right) \sin \left(\sin \left(4 x\right)\right)$

Explanation:

$\text{differentiate using the "color(blue)"chain rule}$

$\text{given "y=f(g(h(x)))" then }$

dy/dx=f'(g(h(x))xxg'(h(x))xxh'(x)

$y = \cos \left(\sin \left(4 x\right)\right)$

$\frac{\mathrm{dy}}{\mathrm{dx}} = \sin \left(\sin \left(4 x\right)\right) \times \frac{d}{\mathrm{dx}} \left(\sin \left(4 x\right)\right) \times \frac{d}{\mathrm{dx}} \left(4 x\right)$

$\textcolor{w h i t e}{\frac{\mathrm{dy}}{\mathrm{dx}}} = \sin \left(\sin \left(4 x\right)\right) \times - \cos \left(4 x\right) \times 4$

$\textcolor{w h i t e}{\frac{\mathrm{dy}}{\mathrm{dx}}} = - 4 \cos \left(4 x\right) \sin \left(\sin \left(4 x\right)\right)$

Dec 19, 2017

Rewrite $f \left(x\right)$ as a composition of $3$ functions, where we will use the chain rule to find the derivative of each function in a way that lets us find the final derivative:

$\frac{\mathrm{df}}{\mathrm{dx}} = - 4 \sin \left(\sin \left(4 x\right)\right) \cos \left(4 x\right)$

Explanation:

I'd break up the function composition into several parts. Here we have $\cos \left(\sin \left(4 x\right)\right)$, which does three things:

1. It multiplies the input by $4$,
2. It takes the sine value of the result from the above,
3. It takes the cosine value of the result from the above.

If we have $f \left(x\right) = \cos \left(\sin \left(4 x\right)\right)$, we could have

$f \left(x\right) = {f}_{3} \left({f}_{2} \left({f}_{1} \left(x\right)\right)\right)$ where

${f}_{1} \left(x\right) = 4 x$

${f}_{2} \left(x\right) = \sin \left(x\right)$

${f}_{3} \left(x\right) = \cos \left(x\right)$

Which should be doing each step from the inside, out. Then we can use the chain rule, which to me is more of a method than a rule. Here's how it goes:

Start from the innermost layer, taking the derivative of ${f}_{1} \left(x\right)$ with respect to $x$.

$\frac{{\mathrm{df}}_{1}}{\mathrm{dx}} = \frac{d}{\mathrm{dx}} {f}_{1} \left(x\right) = \frac{d}{\mathrm{dx}} 4 x = 4$

We also have:

$\frac{{\mathrm{df}}_{1}}{\mathrm{dx}} = 4 \rightarrow {\mathrm{df}}_{1} = 4 \mathrm{dx}$

What we did was solve for ${\mathrm{df}}_{1}$, a tiny nudge in ${f}_{1}$, in terms of $\mathrm{dx}$, a tiny nudge in $x$. Next, we'll take the derivative of ${f}_{2} \left(x\right)$, but in terms of ${f}_{1} \left(x\right)$:

$\frac{{\mathrm{df}}_{2}}{{\mathrm{df}}_{1}} = \frac{d}{{\mathrm{df}}_{1}} {f}_{2} \left({f}_{1}\right) = \frac{d}{{\mathrm{df}}_{1}} \sin \left({f}_{1}\right) = \cos \left({f}_{1}\right)$

Solving for a tiny nudge in ${\mathrm{df}}_{2}$, we "multiply" by ${\mathrm{df}}_{1}$:

$\frac{{\mathrm{df}}_{2}}{{\mathrm{df}}_{1}} = \cos \left({f}_{1}\right) \rightarrow {\mathrm{df}}_{2} = \cos \left({f}_{1}\right) {\mathrm{df}}_{1}$

Then, we evaluate ${f}_{1}$ and ${\mathrm{df}}_{1}$ in terms of $x$ and $\mathrm{dx}$:

$\cos \left({f}_{1}\right) {\mathrm{df}}_{1} = \cos \left(4 x\right) 4 \mathrm{dx} = 4 \cos \left(4 x\right) \mathrm{dx}$

Now, the tiny nudge is no longer in terms of ${\mathrm{df}}_{1}$, but it is now in terms of $\mathrm{dx}$:

${\mathrm{df}}_{2} = 4 \cos \left(4 x\right) \mathrm{dx} \rightarrow \frac{{\mathrm{df}}_{2}}{\mathrm{dx}} = 4 \cos \left(4 x\right)$

And so is the derivative! What we have left to do is ${f}_{3} \left(x\right)$, whose tiny nudge we'll first find in terms of ${\mathrm{df}}_{2}$:

$\frac{{\mathrm{df}}_{3}}{{\mathrm{df}}_{2}} = \frac{d}{{\mathrm{df}}_{2}} {f}_{3} \left({f}_{2}\right) = \frac{d}{{\mathrm{df}}_{2}} \cos \left({f}_{2}\right) = - \sin \left({f}_{2}\right)$

$\frac{{\mathrm{df}}_{3}}{{\mathrm{df}}_{2}} = - \sin \left({f}_{2}\right) \rightarrow {\mathrm{df}}_{3} = - \sin \left({f}_{2}\right) {\mathrm{df}}_{2}$

Then we'll "unroll" things, first evaluating ${f}_{2}$ in terms of ${f}_{1}$ and ${\mathrm{df}}_{2}$ in terms of $\mathrm{dx}$:

${\mathrm{df}}_{3} = - \sin \left({f}_{2}\right) {\mathrm{df}}_{2} \rightarrow - \sin \left(\sin \left({f}_{1}\right)\right) 4 \cos \left(4 x\right) \mathrm{dx}$

Then evaluating ${f}_{1}$ in terms of $x$:

$\rightarrow {\mathrm{df}}_{3} = - \sin \left(\sin \left(4 x\right)\right) 4 \cos \left(4 x\right) \mathrm{dx}$

Simplifying to make things look neater:

${\mathrm{df}}_{3} = - 4 \sin \left(\sin \left(4 x\right)\right) \cos \left(4 x\right) \mathrm{dx}$

And finally "divide" by $\mathrm{dx}$:

$\frac{{\mathrm{df}}_{3}}{\mathrm{dx}} = - 4 \sin \left(\sin \left(4 x\right)\right) \cos \left(4 x\right)$

This is not only the derivative of ${f}_{3} \left(x\right)$, but because we had solved this through the derivatives of ${f}_{2} \left(x\right)$ and ${f}_{1} \left(x\right)$ from the inside out, this is our final answer, the derivative of $f \left(x\right) = \cos \left(\sin \left(4 x\right)\right)$:

$\frac{\mathrm{df}}{\mathrm{dx}} = - 4 \sin \left(\sin \left(4 x\right)\right) \cos \left(4 x\right)$