Sequence that converges in $L^{2}$ on the real line but nowhere pointwise 
Give a sequence of functions $f_{n}:\mathbb{R}\to\mathbb{R}$ that converge in $L^{2}$ but pointwise nowhere.

I know that on bounded intervals such as $[0,1]$, the typical example of a sequence converging in $L^{2}$ but pointwise nowhere is the characteristic functions for intervals that get smaller eg. $f_{1} = 1_{[0,1]}, f_{2} = 1_{[0,\frac{1}{2})}, f_{3} = 1_{[\frac{1}{2},1]}, f_{4} = 1_{[0,\frac{1}{4})}...etc.$
How would one generalise this example to the real line or unbounded domains? I thought about doing this on each interval $[n,n+1)$ for $n\in\mathbb{Z}$, but since there are infinitely many of these, I can no longer be sure this converges in $L^{2}$.
 A: Note  Of course an answer to the question is very simple. Lest anyone get the wrong idea about that from the slightly hairy nature of this post, I point out that there
are three parts below:  a one-line answer to the question, then an easy generalization using a big theorem, and finally an elementary proof of the big theorem:
Answer to the Question
Say $Q_n$ is a partition of $[-n,n)$ into $2n^2$ intervals, each of length $1/n$. Now combine all those intervals into a single sequence, by first listing all the intervals in $Q_1$, then all the intervals in $Q_2$, etc.
A Generalization
In fact you can do the same thing on any $\sigma$-finite non-atomic measure space:


Lemma. If $\mu$ is a non-atomic probability measure on $X$ then $X$ can be partitioned into $E_1\cup\dots\cup E_n$ where $\mu(E_j)=1/n$.


Proof: Someone's Theorem (proved below) says that if $\mu$ is non-atomic and $0<t<\mu(E)<\infty$ then there exists $F\subset E$ with $\mu(F)=t$. So we can find $E_1\subset X$ with $\mu(E_1)=1/n$, then $E_2\subset X\setminus E_1$ with $\mu(E_2)=1/n$, etc. (If there's a set of measure zero left over at the end then just add it to $E_1$.)


Cor. If $\mu$ is a finite non-atomic measure on $X$ then there exists $(f_n)\subset L^2$ with $||f_n||_2\to0$  but $f_n(x)\not\to0$ for every $x$.


Proof: Wlog $\mu(X)=1$; use the lemma to imitate the standard construction for $[0,1]$.


Cor. If $\mu$ is a $\sigma$-finite non-atomic measure on $X$ then there exists $(f_n)\subset L^2$ with $||f_n||_2\to0$  but $f_n(x)\not\to0$ for every $x$.


Proof: we get from finite to $\sigma$-finite using the same method as we use at the start to  get from  $[a,b]$ to $\Bbb R$.
And pleasantly


Exercise. If $\mu$ is a measure on $X$ and there exists $(f_n)\subset L^2$ with $||f_n||_2\to0$  but $f_n(x)\not\to0$ for every $x$ then $\mu$ is $\sigma$-finite and non-atomic.


The Big Theorem
Thinking about it, yesterday Someone's Theorem didn't seem quite as easy as I thought. Thanks to @Gabriel Romon for pointing out the proof here. The proof I gave yesterday involved transfinite  recursion;  the  proofs at that link seem to use transfinite recursion or Zorn's lemma.  Today we have a more elementary argument, involving neither:
Assume until further notice  that $\mu$  is a non-atomic probability measure on $X$.


Lemma 1. If $\mu(E)>0$ then there exists $F\subset E$ with $0<\mu(F)\le\mu(E)/2$.


Proof: Since $\mu$ is non-atomic there exists $S\subset E$ with  $0<\mu(S)<\mu(E)$. Now either $F=S$ or $F=E\setminus S$ works.


Cor. If $\mu(E)>0$ and $\epsilon>0$ there exists $F\subset E$ with $0<\mu(F)<\epsilon$.


Proof: $\lim_{n\to\infty}2^{-n}\mu(E)=0$.


Main Lemma. If $\mu(E)>0$ there exists $F\subset E$ with $\frac13\mu(E)\le\mu(F)\le\frac23\mu(E)$.


Proof. Suppose not: For every $F\subset E$ either $\mu(F)<\frac13\mu(E)$ or $\mu(F)>\frac23\mu(E)$. Let $$S=\{F\subset E:\mu(F)< \mu(E)/3\}$$ and $$s=\sup\{\mu(F):F\in S\}.$$
The key observation is that if $F_1,F_2\in S$ then $F_1\cup F_2\in S$; this is clear, since $\mu(F_1\cup F_2)<\frac23\mu(E)$, hence $\mu(F_1\cup F_2)<\frac13\mu(E)$.
Now there exist $A_n\in S$ with $\mu(A_n)\to s$. If $F_n=\bigcup_{k=1}^n A_k$ then $(F_n)\subset S$, $F_n\subset F_{n+1}$ and also $\mu(F_n)\ge\mu(A_n)$, so $\mu(F_n)\to s$. So if $F=\bigcup F_n$ then $$\mu(F)=s.\quad\text{(got it!)}$$
So we're done if we can show $s=\frac13\mu(E)$. Suppose otoh $\epsilon=\frac13\mu(E)-s>0$. Now there exists $A\subset E\setminus F$ with $0<\mu(A)<\epsilon$; hence $F\cup A\in S$ and $\mu(F\cup A)>s$, contradiction.


Main Corollary. If $E_1\subset E_2$ there exists $E_3$ with $E_1\subset E_3\subset E_2$ and $\mu(E_2)-\mu(E_3)\le\frac23(\mu(E_2)-\mu(E_1))$ and $\mu(E_3)-\mu(E_1)\le\frac23(\mu(E_2)-\mu(E_1))$.


Proof: Take $A\subset E_2\setminus E_1$ with $\frac13\mu(E_2\setminus E_1)\le\mu(A)\le\frac23\mu(E_2\setminus E_1))$; let $E_3=E_1\cup A$ and do the math.
(In fact, although we won't use this below, if we define $d(E,F)=\mu(E\Delta F)$ then for any two sets $E_1$ and $E_2$ there exists $E_3$ such that $d(E_1,E_3)\le\frac23 d(E_1,E_2)$ and $d(E_3,E_2)\le\frac23 d(E_1,E_2)$: Take $A\subset E_1\Delta E_2$ such that [etc] and let $E_3=(E_1\cap E_2)\cup A$.)


$\frac12$Theorem. $\{\mu(F):F\subset E\}$ is dense in $[0,\mu(E)]$.


Proof. Starting with $\emptyset\subset E$ and applying the Main Corollary repeatedly we obtain $\emptyset=E_0\subset\dots\subset E_n=E$ such that $\mu(E_{j+1})-\mu(E_j)<\epsilon$ for every $j$.


Theorem (Seirpinski). If $0<t<\mu(E)$ then there exists $F\subset E$ with $\mu(F)=t$.


Proof. We will construct a sequence of disjoint sets $E_n\subset E$ with $\sum\mu(E_n)=t$. Note that throughout the construction $F_n$ will denote the set $$F_n=\bigcup_{k=0}^n E_k.$$
Let $E_0=\emptyset$. Suppose $E_0,\dots,E_n$ have been chosen, such that $$\mu(F_n)<t.$$ Now $$0<t-\mu(F_n)<\mu(E)-\mu(F_n)=\mu(E\setminus F_n),$$so the  $\frac12$theorem  (with $E\setminus F_n$ in place of $E$) shows that there exists $E_{n+1}\subset E\setminus F_n$ with $$t-\mu(F_n)-\frac1n<\mu(E_{n+1})<t-\mu(F_n).$$Adding $\mu(F_n)$ to all three sides we obtain $t-\frac1n<\mu(F_{n+1})<t$. So if $F=\bigcup F_n$ then $\mu(F)=t$.
A Better Version
So that's the proof for a finite non-atomic measure. The result for an infinite non-atomic measure
follows from this:


Lemma. If $\mu$ is an infinite non-atomic measure on $X$ then
$\sup\{\mu(E):\mu(E)<\infty\}=\infty$.


Proof. This is exactly like the proof of the Main Lemma above. Suppose
the sup is $\alpha<\infty$.  Since the union of two sets of finite
measure  has finite measure it follows as before that there exist $E_n$ with $\mu(E_n)<\infty$, $E_n\subset E_{n+1}$ and $\mu(E_n)\to\alpha$; hence there exists
$E$ with $\mu(E)=\alpha$. Now since $\mu$ is non-atomic there
exists $A\subset X\setminus E$ with $0<\mu(A)<\infty$, and hence
$\alpha<\mu(E\cup A)<\infty$, contradiction.
