For $\alpha > 0$, define the function: $g(x) = |x|^\alpha \cos(1/x^2)$, for $x \neq 0$, $g(x) = 0$, when $x = 0$ Define $$g(x) = \begin{cases}|x|^\alpha\cos(1/x^2) & x\neq 0\\ 0 & x = 0\end{cases}.$$
Determine what values of $\alpha>0$ is $g(x)$ differentiable at $x = 0$. 
I had this question on an assignment and I got it wrong. Apparently the answer is $\alpha > 1$, however, I am having trouble understanding this, can someone help me?
In approaching this question, I determined that first I need continuity at $x = 0$. Therefore, I need a value for $\alpha$, such that $$\lim_{x \to 0} |x|^\alpha\cos(1/x^2) = 0.$$
So for this requirement, I need $\alpha\geq 1$. Is that correct? Because if I just test $(0.001)^{0.001}$, this gives something like $0.99$.
I will also need to ensure that $g'(x)$ from the left and right to be equal, so that there are no corners, or cusps at $x = 0$ (i.e. $g'(0) = 0$, since $\cos$ and $\sin$ oscillate). 
Since $\cos(1/x^2)$ and $\sin(1/x^2)$ oscillate between $-1$ and $1$, I will need $2|x|^{\alpha - 3} \to 0$, as $x \to 0$, in order to have both the left and right derivatives the same.
So for the $(\alpha - 3)$, I would need this to be  $\geq 1$. Therefore $\alpha > 4$. 
Can someone help me to understand what I am getting wrong here?
 A: A start: There is no continuity problem at $0$, for any $\alpha>0$.  For fix $\alpha$. Note that $|\cos(1/x^2)|\le 1$, so for all $x$ we have $|g(x)|\le |x|^\alpha$.  But for fixed $\alpha$, we can make $|x|^\alpha$ arbitrarily close to $0$ by choosing $|x|$ small enough.
So continuity is not the issue.  For differentiability, there is no problem possibly at $x=0$. It may be best to go back to the definition of the derivative. So we want to know whether
$$\lim_{h\to 0} \frac{|h|^\alpha\cos(1/h^2) -0}{h}$$
exists.
You will find that the limit does exist when $\alpha >1$, and doesn't when $0 \lt \alpha\le 1$. Since this is homework, and probably you can now continue, I will pause at this point.
A: Any even function is differentiable at $0$ if and only if its right derivative there is $0$. Can you see why this is true? Try to prove it. Observe your function is an even function. Now the right derivative is
$$\lim_{x\to0^+}\frac{|x|^\alpha\cos(1/x^2)}{x}=\lim_{x\to0^+}x^{\alpha-1}\cos(1/x^2)=\cdots $$
because $|x|=x$ for $x\ge0$. Can you finish?
