Derivative of a function when it is squared. Was wondering when you are for example finding $dw/dt$ but you are given a function like $w^2(t)=r^2-2\cos(t)$, when r is some constant, how you are supposed to solve it? Are you supposed to incorporate chain rule?

thanks
You've got $$w^2=r^2-2\cos(t).$$ Now differentiate everything with respect to $t$ to give $$\underbrace{2w \cdot\frac{\mathrm{d}w}{\mathrm{d}t}}_{\text{chain rule}}=0+2\sin(t).$$

Now re-arrange this to find $\frac{\mathrm{d}w}{\mathrm{d}t}.$



Note that $r$ is constant, so $r^2$ is constant, so the derivative of $r^2$ wrt $\ t\ $ is zero.
A derivative, conceptually, is the rate of change.  Constants do not change over the dependent variables.  

r is a constant, there for r^2 is a constant.  The derivative of a constant is 0, thus can be effectively ignored.