Let $f$ be a real valued uniformly continuous function on $\mathbb{R}$ that is lebesgue integrable.
Show that $\lim_{|x|\rightarrow \infty}f(x)=0$.
Suppose that $$\int_{\mathbb{R}}f(x)dx=M<\infty$$
Suppose that $\lim_{|x|\rightarrow \infty}f(x)=L\neq 0$ i.e., given $\epsilon>0$ there exists $R$ such that for all $|x|>R$ we have $|f(x)-L|<\epsilon$ i.e., $-\epsilon+L<f(x)<\epsilon+L$ for all $x:|x|>R$
We then have $$\int_{\mathbb{R}}f(x)dx= \int_{-\infty}^{-R}f(x)dx+\int_{-R}^R f(x)dx+\int_R^{\infty}f(x)dx$$ $$\geq (-\epsilon+L)(\mu(-\infty,R)+\mu(R,\infty))+2RL$$
Where $L$ is the maximum of $f(x)$ on $[-R,R]$..
I some how plan to manipulate $(-\epsilon+L)(\mu(-\infty,R)+\mu(R,\infty))+2RL$ to be strictly greater than $M$ then by getting a contradiction.
could not proceed beyond this.
Have not yet used uniform continuity as of now.
By $\lim_{|x|\rightarrow \infty}f(x)=0$ we mean :
Negation of this is that :
In particular, for each $n$ there exists $x_n$ such that $|x_n|>n$ and $|f(x_n)|>\epsilon$.
As $f$ is uniformly continuous :
We have $|f(x_n)|>\epsilon/2$. Let $a\in(x_n-\delta/2,x_n+\delta/2)$. Suppose $|f(a)|\leq \epsilon/2$ then we have $$|f(x_n)|\leq |f(x_n)-f(a)|+|f(a)|<\epsilon/2+\epsilon/2=\epsilon.$$
This says that $|f(a)|>\epsilon/2$ for all $a\in(x_n-\delta/2,x_n+\delta/2)$..
We can choose $\delta'<\min\{1,\delta\}$ and put $\delta'=\delta$, abuse of notation.. This is to make sure that the intervals $(x_n-\delta/2,x_n+\delta/2)$ are disjoint.. In this case, we do have $(x_n-\delta/2,x_n+\delta/2)\subset(n,n+1)$.. I realize that this is where we use $|x_n>n|$... I am explicitly assuming $x_n\in (n,n+1)$.. no idea how to get rid of this assumption..
As those intervals are disjoint, we now have $$\int_{\mathbb{R}}|f(x)|dx\geq \sum_{n=1}^{\infty}\int_{x_n-\delta/2}^{x_n+\delta/2}|f(x)|dx\geq \sum_{n=1}^{\infty}\epsilon/2\delta=\infty.$$
Only gap is the assumption that $x_n\in (n,n+1)$..