For what value does $\int_0^{\infty} \frac{1-\cos x}{x^a} dx$ converge? My question is for what realnumber $a$ does this converge?
$$\int_0^{\infty} \frac{1-\cos x}{x^a} dx$$
I want a specific proof for this.
Thanks in advance! 
 A: hint

Near zero,

we have
$$1-\cos (x)\sim \frac {x^2}{2} $$ thus
$\int_0 f (x)dx $ has the same nature than
$$\int_0\frac {dx}{x^{a-2}} $$ which converges if $a-2 <1\iff a <3$ .

Near $+\infty $,

By Dirichlet test, $\int^{+\infty}\frac {\cos (x)}{x^a}dx $ converges if $a>0$.
and $\int^{+\infty}\frac {dx}{x^a} $ converges if $a>1$.
from this, 
$$1 <a <3\implies \int_0^{+\infty}f (x)dx $$ converges.
Now if $a \le0$, for $x\ge1$, we have
$$x^{-a}\ge1\implies x^{-a}(1-\cos (x))\ge (1-\cos (x)) $$
and $\int^{+\infty}(1-\cos (x))dx $ divergent.

Finally it converges iff $1 <a <3$.

A: An alternative proof comes from the following property of the Laplace transform:
$$ \int_{0}^{+\infty} f(x)\,g(x)\,dx = \int_{0}^{+\infty}(\mathcal{L} f)(s)\,(\mathcal{L} g)(s)\,ds. $$
It is easy to check that the Laplace transform of $1-\cos x$ is $\frac{1}{s(1+s^2)}$, while the inverse Laplace transform of $\frac{1}{x^\alpha}$ is $\frac{s^{\alpha-1}}{\Gamma(\alpha)}$ by the integral definition of the $\Gamma$ function. It follows that
$$ \int_{0}^{+\infty}\frac{1-\cos x}{x^\alpha}\,dx = \frac{1}{\Gamma(\alpha)}\int_{0}^{+\infty}\frac{s^{\alpha-2}}{1+s^2}\,ds $$
where the last integral is convergent as soon as $\alpha>1$ (we need integrability in a right neighbourhood of the origin) and $\alpha<3$ (we ned integrability in a left neighbourhood of $+\infty$).
Summarizing,
$$\boxed{ \forall \alpha\in(1,3),\quad \int_{0}^{+\infty}\frac{1-\cos x}{x^\alpha}\,dx = \frac{1}{\Gamma(\alpha)}\cdot\frac{-\frac{\pi}{2}}{\cos\left(\frac{\pi\alpha}{2}\right)}=\color{red}{-\frac{\pi}{2\,\Gamma(\alpha)\cos\left(\frac{\pi\alpha}{2}\right)}}.}$$
