TITLE: Are functions in Lp space always bounded?
QUESTION [9 upvotes]: I know that functions in $L^2$ space have finite norms by definition, but are they also bounded "almost everywhere" ?
So say for instance the following functions norm is finite but it is not bounded.
$$ f(x) = \frac{1}{(x-\frac{1}{2})^2} ~~ ; ~~~ f(x) \in L^2[(0,1),\mu] $$
$$ {\|f(x)\|}_2 = \left(\int_0^1{\frac{1}{(x-\frac{1}{2})^2}}\right)^{1/2}$$
$$ {\|f(x)\|}_2 = \left(\left. {\frac{1}{(x-\frac{1}{2})}}\right]_0^1\right)^{1/2}$$
$$ {\|f(x)\|}_2 = 2$$

REPLY [14 votes]: Let's fix the definitions first. 

A function $f:(0,1)\to\mathbb R$ is called bounded if there is a number $M$ such that $|f(x)|\le M$ for all $x\in (0,1)$. 

Since the elements of $L^p$ are not functions, but equivalence classes of functions, the concept of boundedness must be adjusted. 

A function $f:[0,1]\to\mathbb R$ is called essentially bounded if there is a number $M$ such that $|f(x)|\le M$ for almost all $x\in (0,1)$. (That is, the inequality holds on some set $E$ such that $(0,1)\setminus E$ has zero measure.)

If two functions $f,g$ belong to the same equivalence class and $f$ is essentially bounded, then $g$ is also essentially bounded. Thus, the property of being essentially bounded makes sense for elements of $L^p$. 
Does it hold for all elements of $L^p$? Yes if $p=\infty$ (by definition), no if $p<\infty$. For example, the function $f(x)=x^{-1/(p+1)}$ defines an element of $L^p((0,1))$ which is not essentially bounded. For every $M$, the set $\{x:|f(x)|>M\}$ contains an interval, and therefore is not a null set.

Remark. One often  allows functions to take values in the extended real line $[-\infty, \infty]$. In this case, one can say that every element of $L^p$ is finite almost everywhere.