TITLE: if $\int_1^\infty f(x)dx$ exist, then $\int_1^\infty f^2(x)dx$ exist?
QUESTION [8 upvotes]: I'm facing some difficulty in proving/disproving this sentence:

Consider $f: [0, \infty ) \rightarrow \mathbb{R}, f$ is continuous.
  if $\displaystyle \int_1^\infty f(x)dx$ exist, then $\displaystyle \int_1^\infty f^2(x)dx$ exist.

REPLY [3 votes]: I'll just expand my comment here. One thing I want to point out is that Clement's example is, in a sense, better because it is unconditionally integrable while my example $f(x) = (\sin x) / \sqrt{1 + x}$ is conditional.
To show that my function is conditionally integrable, I use the definition $\int_1^\infty f(x) dx = \lim_{y \to \infty} \int_1^y f(x) dx$. In fact, I'll show that $\int_0^\infty f(x) dx = \lim_{y \to \infty} \int_0^y f(x) dx$ exists.
First, I'll prove that $\lim_{n \to \infty} \int_0^{2n\pi} f(x) dx$ exists. For each non-negative integer $n$, define $s_n = \int_{2n\pi}^{2(n+1)\pi} f(x) dx$. We can bound each $s_n$ as follows.
\begin{align}
p_n = \int_{2n\pi}^{(2n+1)\pi} f(x) dx
& = \int_{2n\pi}^{(2n+1)\pi} \frac{\sin x}{\sqrt{1 + x}} dx \\
& \le \int_{2n\pi}^{(2n+1)\pi} \frac{\sin x}{\sqrt{1 + 2n\pi}} dx \\
& = \frac{2}{\sqrt{1 + 2n\pi}} \\
m_n = \int_{(2n+1)\pi}^{(2n+2)\pi} f(x) dx
& = \int_{(2n+1)\pi}^{(2n+2)\pi} \frac{\sin x}{\sqrt{1 + x}} dx \\
& \le \int_{(2n+1)\pi}^{(2n+2)\pi} \frac{\sin x}{\sqrt{1 + (2n + 2)\pi}} dx \\
& = -\frac{2}{\sqrt{1 + 2(n + 1)\pi}}
\end{align}
Therefore,
\begin{align}
s_n = p_n + m_n & \le \frac{2}{\sqrt{1 + 2n\pi}} - \frac{2}{\sqrt{1 + 2(n+1)\pi}}.
\end{align}
It is easy to see that $s_n \ge 0$, so the sequence $\{S_n\}$ of partial sums $S_n = \sum_{i=0}^n s_i$ is monotonically increasing and bounded above by $2$ (the sum is telescoping), hence convergent. 
For $y \in [2n\pi, (2n+1)\pi]$, we have $S_n \le \int_0^y f(x) dx \le S_n + p_n$. For $y \in [(2n+1)\pi, 2(n+1)\pi]$, we have $S_n + p_n \ge \int_0^y f(x) dx \ge S_{n+1}$. This is sufficient to conclude that $\int_0^\infty f(x) dx = \lim_{y \to \infty} \int_0^y f(x) dx = \lim_{n\to\infty} S_n$.