0

So the problem I am stuck on is this: find the derivative of $$y = \cos^2(x^3 + x^2)$$

I am very lost in all of this, so please explain the steps, that would be a great help.

Amzoti
  • 56,093
Ethan
  • 105

4 Answers4

4

You need to use the chain rule.

$$y = \cos^2(x^3 + x^2) = \big(\cos(x^3 + x^2)\big)^2$$

We have a function $y$ which is a composite of three functions: $f(g(h(x)))$ where $$h(x) = x^3+x^2,\quad g(h(x)) = \cos(h(x)),\, \quad f(g(h(x))) = [g(h(x))]^2,$$ so our derivative is going to require that we find the product of $h'(x), g'(h(x)),$ and $f'(g(h(x)))$ $$\dfrac{dy}{dx} = \underbrace{2\big(\cos(x^3+ x^2)\big)}_{f'(g(h(x)))}\big(\underbrace{-\sin(x^3 + x^2)}_{g'(h(x))}\big)\cdot \underbrace{\frac{d}{dx}\big(x^3 + x^2)}_{h'(x)}$$ $$= -2\big(\cos(x^3+ x^2)\big)\big(\sin(x^3 + x^2)\big)(3x^2 + 2x)$$ $$= -2(3x^2 + 2x)\big(\cos(x^3+ x^2)\big)\big(\sin(x^3 + x^2)\big)$$ $$ = (-3x^2 - 2x)\sin\big(2(x^3 + x^2)\big)$$

In moving from the second to last to the last equivalency, I simplified by invoking the double-angle angle formula which tells us that $2\cos\alpha\sin\alpha = \sin(2\alpha)$.

amWhy
  • 209,954
  • This is excellent, but one question. Where does the sin part come from? Please don't just say the chain rule, is it because the cos was squared? – Ethan Oct 12 '14 at 14:05
  • $\frac{dy}{dx} \cos \alpha = -\sin \alpha$. The $2\cos(x^3+x^2)$ is due to the power rule: we have a function squared, so $(f(x))^2 = 2f(x)\cdot f'(x)$. And $f(x) = \cos(g(x)),$ so $f'(x) = -\sin(g(x))\cdot g'(x)$. – amWhy Oct 12 '14 at 14:08
  • Okay that's what I expected, thanks so much. – Ethan Oct 12 '14 at 14:13
  • You're welcome, Ethan. – amWhy Oct 12 '14 at 14:22
0

we get by the chain rule $2\cos(x^3+x^2)(-\sin(x^3+x^2))(3x^2+2x)$

0

This is a function of function. Look at it from above. What is it? It is [something] squared. What is the derivative of [something] squared? Just 2*[something]. However, this something is also a function. What is it? It is cos[something]. What is derivative of cos[something]? -sin of this something, but again this something is a function which you also need to take derivative of. This kind of reasoning is called chain rule of differentiation.

$y' = 2 \cos(x^3+x^2) \cdot (-\sin(x^3 + x^2)) \cdot (3x^2+2x)$

mathisfun
  • 319
0

$\newcommand{\dd}{\mathop{}\!\mathrm{d}}\newcommand{\per}{\cdot}$ First of all, we apply the rule for deriving composite functions: $$\frac{\dd f\circ g}{\dd x}=\frac{\dd f}{\dd g}\cdot\frac{\dd g}{\dd x}.$$ We see $\cos^2$ as the composition of $g(x)=\cos(x)$ and $f(x)=x^2$, so: $$\frac{\dd(\cos^2(x))}{\dd x}=\frac{\dd(\cos^2x)}{\dd(\cos x)}\per\frac{\dd(\cos x)}{\dd x}=-2\cos(x)\per\sin(x).$$ But then we don't have $\cos(x)$, but $\cos(x^3+x^2)$, so we multiply by the extra derivative and change the arguments of the trig functions: $$\frac{\dd(\cos^2(x^3+x^2))}{\dd x}=-2\cos(x^3+x^2)\sin(x^3+x^2)\per(3x^2+2x).$$

MickG
  • 8,645