# Math Help - Basic Chain Rule Problem with Trig Functions

1. ## [SOLVED] Basic Chain Rule Problem with Trig Functions

Hi, everyone. First post but I have a feeling I'll be coming back often.

Problem: For what values of $x$ in the interval $[0,2\Pi]$ does the graph of $f(x)=\cos^2(x)+\sin(x)$ have a horizontal tangent?

Answer: $f'(x)=-2\cos(x)\sin(x)+\cos(x)$

f(x) has horizontal tangents at $x=\frac{\Pi}{2}, \frac{3\Pi}{2}$

I don't have a problem getting the x-values for the horizontal tangents but I can't get the right derivative. Here's my work:

$f(x)=\cos^2(x)+\sin(x)$

$f(x)=u^2+\sin(x)$, $u=\cos(x)$

$\frac{dy}{du}=2u+\cos(x)$, $\frac{du}{dx}=-\sin(x)$

$\frac{dy}{dx}=(2u+\cos(x))(-\sin(x))$

$\frac{dy}{dx}=-2u\sin(x)-\sin(x)\cos(x)$

Substitute $\frac{du}{dx}$ back into the equation.

$\frac{dy}{dx}=-2\sin(x)\cos(x)-\sin(x)\cos(x)$

$\frac{dy}{dx}=-3\sin(x)\cos(x)$

Where is my error?

Tim

2. $\frac{dy}{dx}=(2u+\cos(x))(-\sin(x))$

This is incorrect. You are only using the chain rule for the $\cos^2 x$ part, so leave the sin(x) part out of it.

It should be: $\frac{dy}{dx}=(2u)(-\sin(x))+\cos(x)$

3. Thank you SO much! That was too simple.

$0=-2\cos(x)\sin(x)+\cos(x)$

$0=\cos(x)$ at $\frac{\pi}{2}$ and $\frac{3\pi}{2}$

Don't ask me why I put $\frac{5\pi}{6}$ up there, it's wrong and I edited that out. Must have copied that down in error.

Thanks again, Educated!
Tim