How would you integrate $\int_{0}^1 \frac{1-\cos x}{x^2}\,dx$ How would you integrate $$\int_{0}^1 \frac{1-\cos x}{x^2}\,dx?$$
I'm trying to see whether this diverges or converges by the way. Any help in that way would be great!
 A: I don't think you can express this integral in terms of elementary functions. Otherwise you would have found a way to express the sin integral in terms of elementary functions.
We have:
$$
\int_{0}^1\frac{1-\cos x}{x^2}
$$
We can integrate by parts. Let $u = 1-\cos x$ and $v'=\frac{1}{x^2}$ giving $u' = \sin x$ and $v = \frac{-1}{x}$.
Thus we have:
$$
\begin{align} 
\int_{0}^1\frac{1-\cos x}{x^2} &=  \left .\frac{\cos x-1}{x}\ \right \rvert_{0}^1 + \int_{0}^1\frac{\sin x}{x} \\
\end{align}
$$
This leaves us with finding the integral of $\sin x \over x$. This is a known non-elementary function called (creatively) the sine integral, $\text{Si}(x)$, and is defined as:
$$
\text{Si}(x) = \int_0^x\frac{\sin t}{t}dt
$$
Thus we have:
$$
\begin{align}
\int_{0}^1\frac{1-\cos x}{x^2} &= \left .\frac{\cos x-1}{x}\right \rvert_{0}^1 + \text{Si}(1) \\
&= \cos(1) - 1 + \text{Si}(1) \\
&\approx 0.486385
\end{align}
$$
Note: the left term can be evaluated at $x=0$ by taking limits of the term to 0.
I got the value of $\text{Si}(1)$ using the taylor expansion. Alternatively you could have started with the taylor expansion of the original equation but it would have inadvertently led you to the taylor expansion of $\text{Si}(1)$ in some form.
A: Hint: remark that $\cos x \leq 1$, so your integrand is non-negative. Also, remark that $\lim_{x \to 0} \frac{1-\cos x}{x^2} = 1/2$
A: $$\frac{1-\cos x}{x^2} = \frac{1}{2!}-\frac{x^2}{4!}+\frac{x^4}{6!}-\ldots \tag{1}$$
hence by termwise integration:
$$ \int_{0}^{1}\frac{1-\cos x}{x^2}\,dx = \frac{1}{2!}-\frac{1}{3\cdot 4!}+\frac{1}{5\cdot 6!}-\ldots = \sum_{k\geq 0}\frac{(-1)^k}{(2k+1)\cdot (2k+2)!} \tag{2}$$
where the last series converges very fast and with alternating signs. You just need to take four or five terms to get an extremely accurate approximation of the given, non-elementary integral, equal to $-1+\cos(1)+\text{Si}(1)$ by integration by parts.
You may also use the Laplace transform to state:
$$ \int_{0}^{1}\frac{1-\cos x}{x^2}\,dx = \left(\frac{\pi}{2}-1+\cos(1)\right)+\int_{0}^{+\infty}\frac{\cos(1)+s\sin(1)}{(1+s^2)\,e^s}\,ds.\tag{3} $$
A: As per Dr. MV's suggestion, integrate by parts
\begin{align}
\int\limits_{0}^{1} \frac{1-\cos x}{x^{2}} dx &= \lim_{a \to 0} \int\limits_{a}^{1} \frac{1-\cos x}{x^{2}} dx \\
&= \lim_{a \to 0} \frac{\cos x - 1}{x}\Big|_{a}^{1} + \int\limits_{a}^{1} \frac{\sin x}{x} dx \\
&= \cos(1) - 1 - \lim_{a \to 0} \frac{\cos a - 1}{a} + \int\limits_{0}^{1} \frac{\sin x}{x} dx \\
&= \cos(1) - 1 + \mathrm{Si}(1)
\end{align}
