Check the convergence of $\sum\limits_{n=1}^\infty \int^r_0 \sin^n(x)\cos(x)\,\mathrm dx$ where $r>0$ 
Check the convergence of the series $$\sum_{n=1}^\infty \int^r_0 \sin^n(x)\cos(x) \,\mathrm{d}x,$$ where $r\gt 0$ is some real number.

Hi. First I wanted to see whether the general term $$\int^r_0 \sin^n(x)\cos(x)\,\mathrm{d}x$$ approaches zero when $n$ approaches $\infty$, but I am not sure on how to do it. If it converges, as I see it, I need to find a function larger than $$f(x)=\sin^n(x)\cos(x)$$ that converges and then according to the direct comparison test and the monotonicity property of definite integrals we'll show the desired…
I might be wrong with my direction of course… I would be happy to get your help. Thank you.
 A: \begin{align*}
&\mathrel{\phantom{=}}\sum_{n=1}^\infty \int^r_0 \sin^n(x)\cos(x)\,\mathrm{d}x=\sum_{n=1}^\infty \int^{x=r}_{x=0} \sin^n(x)\,\mathrm{d}(\sin x)\\&=\sum_{n=1}^\infty \int_0^{\sin r} u^n\,\mathrm{d}u= \int_0^{\sin r}\sum_{n=1}^\infty u^n\,\mathrm{d}u=\int_0^{\sin r}\left(\frac{1}{1-u}-1\right)\mathrm{d}u\\&=-\ln(1-\sin r)-\sin r,
\end{align*}
which is convergent for all values of $r$ except where $\sin r =1$.
A: An antiderivative for $(\sin^n x)\cos x$ is $(\sin^{n+1}x)/(n+1).$ So the series equals
$$\sum_{n=1}^{\infty}\frac{\sin^{n+1}r}{n+1}.$$
There are 3 cases: i)$\,|\sin r|<1$: Here we have absolute convergence, hence convergence.
ii) $\sin r = -1.$ Here we have the series $\sum (-1)^{n+1}/(n+1).$ This series converges (conditionally) by the alternating series test.
iii) $\sin r = 1$: Here we have the series $\sum 1/(n+1) = \infty.$
In terms of $r,$ we have absolute convergence for $r\in (0,\infty)\setminus \{\pi/2+m\pi:m\in \mathbb N\},$ conditional convergence for $r\in \{3\pi/2 + 2m\pi: m\in \mathbb N\},$ and divergence for $r\in \{\pi/2 + 2m\pi: m\in \mathbb N\}.$
