Position operator is self adjoint Let $H=L^2(\Bbb{R})$ with the linear (unbounded) operator $P(f)(x)=x\cdot f(x)$ for each $x\in\mathbb{R}$. Have a look at the following domain:
$$D(P)=\{f\in L^2(\mathbb{R}):\int_{\mathbb{R}}{x^2\cdot|f(x)|^2\ dx}<\infty\}$$
I want to prove that $D(P)$ is dense in $H$. I think the reason is that all functions with compact support lies in $D(P)$. The second thing is, I want to show that $P$ is self-adjoint, in particular that $D(P)=D(P^*)$. The inclusion $P\subset P^*$ is easy (just play with integrals). Can someone help me with the other inclusion? 
Thanks a lot.
 A: You have a symmetric operator $P$. That is, $(Pf,g)=(f,Pg)$ for all $f,g \in \mathcal{D}(P)$. A general method for showing that a symmetric operator $P$ is densely-defined and selfadjoint is to show that $(P\pm iI)$ are surjective, which is easy to apply in your case because, for all $g \in L^{2}(\mathbb{R})$, one has $\frac{1}{x\pm i}g \in L^{2}$ and $(P\pm iI)((x\pm i)^{-1}g) =g$.

Theorem: Let $P : \mathcal{D}(P)\subseteq H\rightarrow H$ be a symmetric linear operator on a complex Hilbert space $H$. Then $P$ is densely-defined and selfadjoint if $P\pm iI$ are surjective.

Proof: Let $P$ be as stated and suppose that $P\pm iI$ are surjective. Then $\mathcal{D}(P)$ is dense iff $\mathcal{D}(P)^{\perp}=\{0\}$. So, suppose $h \perp \mathcal{D}(P)$. Then $h=(P+iI)g$ for some $g\in\mathcal{D}(P)$, which gives
$$
       0 = \Im (h,g)= \Im ((P+iI)g,g) = \|g\|^{2}.
$$
Hence, $g=0$, which proves that $\mathcal{D}(P)$ is dense.
Therefore $P^{\star}$ is closed and densely-defined. And $P^{\star}$ is an extension of $P$ because $P$ is symmetric. To show that $P=P^{\star}$, it is enough to show that $\mathcal{D}(P^{\star})\subseteq \mathcal{D}(P)$. Let $g \in \mathcal{D}(P^{\star})$. By assumption, $(P^{\star}+iI)g=(P+iI)h$ for some $h\in\mathcal{D}(P)$. Therefore, for all $f \in \mathcal{D}(P)$,
\begin{align}
     ((P-iI)f,g) & = (f,(P^{\star}+iI)g) \\& =(f,(P+iI)h)=((P-iI)f,h)
\end{align}
So $g-h \perp \mathcal{R}(P-iI)=H$, which gives $g = h \in\mathcal{D}(P)$. $\;\;\Box$
