$L^2$ Integrable function that is not $L^1$ integrable

3.9k Views Asked by At

suppose we have:

$$ f(x) = \begin{cases} 1 & x \in \mathbb{Q} \\ -1 & x \in \mathbb{R} \setminus \mathbb Q \end{cases} $$

It seems to me that while $f$ is not integrable, $f^2(x) = 1$ is integrable. Am I wrong about $f$ being not integrable?

2

There are 2 best solutions below

0
On

Why do you think that $f^2=1$ is integrable?

$\int_R f^2=\int_R1=\infty$

0
On

On the real line, its not hard to construct $L^2$ functions which are not $L^1$ and vice versa (on most spaces, $L^p$ spaces don't nest -- exceptions include things like $\ell^p$ spaces, or on compact intervals).

$f(x) = \begin{cases} 1/x & x>1 \\ 0 & o.w. \end{cases}$ is in $L^2$ but not in $L^1$.

$f(x) = \begin{cases} 1/\sqrt{x} & 0<x<1 \\ 0 & o.w. \end{cases}$ is in $L^1$ but not in $L^2$.

The function you have is not in $L^1(\mathbb{R})$ or $L^2(\mathbb{R})$ -- you need $\int_\mathbb{R} |f|^p < \infty$ for it to be in $L^p$. For $p=1,2$, that integral is infinite.