The integral of $\frac{\cos(x)}{x}$ from $0$ to $1$ So I have a test next week and I saw this question:
proof that $\ \int_{0}^{1} \frac{\cos(x)}{x} \, \mathrm{d}x $ is not convergent.
So first of all I know this is improper integral.
When I saw the solution (a student done few years ago) it says that:
since $\forall\ 0 \leq x \leq 1$ $ 0 \leq \frac{\cos(x)}{x}$
And therefore we can use the limit comparison in order to check if it is not convergent. So
$\lim \frac{\frac{\cos(x)}{x}}{\frac{1}{x}}= 1 $ while $x\rightarrow 0$ 
and because $\ \int_{0}^{1} \frac{1}{x} \, \mathrm{d}x $ is not convergent then 
$\ \int_{0}^{1} \frac{\cos(x)}{x} \, \mathrm{d}x $ is not covergent also.
but as far as I know he should checked that 
$\lim \frac{\frac{\cos(x)}{x}}{\frac{1}{x}} < \infty $ while $x\rightarrow \infty$ in order to determine something and not zero.
Am I missing something, because clearly he is right in the final answer but is way is true ?
Thanks in advanced
 A: Assume the contrary that $\displaystyle \int_0^1 \frac{\cos x}{x} dx $ does exist.
Let $M > 0$ be any upper bound of the integral. Notice $\cos(x) \ge \cos(1) > 0$ on $[0,1]$,
we find for any $\epsilon \in (0,1)$, we have
$$M \ge \int_0^1 \frac{\cos x}{x} dx \ge \int_\epsilon^1 \frac{\cos x}{x} dx \ge
\int_\epsilon^1 \frac{\cos(1)}{x} dx = \cos(1)\log\frac{1}{\epsilon}\tag{*}$$
If we choose $\epsilon < e^{-\frac{M}{\cos(1)}}$,  L.H.S of $(*)$ will be greater than $M$.
This is a contradiction and hence the original assumption that $\displaystyle \int_0^1 \frac{\cos x}{x} dx$ exists is wrong. 
When you get into latter part of your course which allow you to be a little bit sloppy about the most elementary stuff. You can prove the same statement by first claiming
$\displaystyle \frac{\cos x}{x} \ge 0 $ on $[0,1]$ and then compare your integral with one that is known to diverge. In this case, $\displaystyle \int_0^1 \frac{\cos(1)}{x} dx\;$ is again a good choice.
A: If $\lim_{x \to 0} (\cos x / x) / (1/x)$ is a non-zero constant (like 1), and both functions have a single discontinuity at $0$, then $\int_0^1 \frac{\cos x}{x} dx$ is indeed divergent if and only if $\int_0^1 \frac{1}{x} dx$ is divergent.  
A: You do not need to check what is happening beyond the region of integral.
Technically you could define a new function $g(x)=\frac{1}{x}$ within the interval, and anything you want, say $1$, outside. Likewise you could do the same with $f(x)=\frac{\cos(x)}{x}$ in $[0,1]$, and $0$ outside.
Then your condition on $x\to \infty$ will hold for $\frac{f(x)}{g(x)}$, which is essentially $\frac{cos(x)/x}{1/x}$ in the interval $[0,1]$.
A: Well, note that $\cos(x)$ > $\cos(1)$ for your specific interval. Therefore, we can use the fact that $\frac{\cos(x)}{x} \geq \frac{\cos(1)}{x}$. If we can show that the integral of the lesser function, $\frac{\cos(1)}{x}$ is divergent, then we can show that the integral of the greater function must also be divergent. Therefore, we must attempt to show that the following is divergent: 
$\int_{0}^{1}\frac{\cos(1)}{x}\mathrm{d}x$. This is fairly simple. As you pointed out, $\int_{0}^{1}\frac{1}{x}\mathrm{d}x$ is divergent, because of the behavior of $\ln(x)$ at $x=0$. We can rewrite $\int_{0}^{1}\frac{\cos(1)}{x}\mathrm{d}x$ by factoring out the $\cos(1)$:
$\cos(1)\int_{0}^{1}\frac{1}{x}\mathrm{d}x$.
The above is clearly divergent, since we know that $\int_{0}^{1}\frac{1}{x}\mathrm{d}x$ is divergent. Thus, we have proven that
$\int_{0}^{1}\frac{\cos(1)}{x}\mathrm{d}x$ is divergent. Since
$\frac{\cos(x)}{x} \geq \frac{\cos(1)}{x}$, the integral of the greater function, $\frac{\cos(x)}{x}$ must also be divergent from 0 to 1. 
