Given the series:
$$\sum_{n=1}^\infty \frac{\cos x^n}{n}$$
This is similar to
$$\sum_{n=1}^{\infty}\frac{x^n}{n}$$
This series converges on $-1 \le x \lt 1$ and converges uniformly on $(-1,0)$
If I use the root test, for the above series, I get
$$\lim_{n \to \infty} \frac{(x^n)^{\frac{1}{n}}}{(n)^{\frac{1}{n}}} =\left(\frac{x}{1}\right)=x$$
And then if $|x|\lt 1$ it converges, greater than $1$ diverges and $x=1$ we get a known series that doesn't converge. What am I doing wrong here?
The series is not "similar" to the series $\sum_{n\ge 1}\frac{x^n}{n}$.
Note that for $|x|<1$, $-1<x^n<1$, with $\lim_{n\to \infty}x^n=0$.
Therefore, we have for $|x|<1$
$$\sum_{n=1}^N \frac{\cos(x^n)}{n}=\sum_{n=1}^N \left(\frac{1+O\left(x^{2n}\right)}{n}\right)$$
which diverges by comparison to the harmonic series.