Algebras of adjointable operators on dense subspaces of Hilbert space Let $W$ be a proper dense subspace of a Hilbert space $H$ (e.g., the space of smooth square-integrable functions on the unit interval $[0, 1]$). Let $BA(W)$ denote the set of bounded, adjointable operators on the (incomplete) inner product space $W$, i.e., the bounded linear operators $T$ on $H$ such that $W$ is both $T$-invariant and $T^*$-invariant. This is (canonically) a unital *-subalgebra of $B(H)$. Is it dense in $B(H)$ in the operator norm topology? If so, what is a simple proof?
 A: I will assume that $\mathcal{H}$ is a separable Hilbert space. For $W\subset \mathcal{H},$ let $\{e_n\}_{n=1}^\infty$ denote an orthonormal basis of $W,$ i.e. a maximal orthonormal collection of elements. Since $W$ is dense, the set $\{e_n\}_{n=1}^\infty$ is an orthonormal basis in $\mathcal{H}.$
Let $W_0$ denote the linear span of $\{e_n\}_{n=1}^\infty$. Then $W_0\subset W.$
We will consider the family $\mathcal{A}$ of all bounded operators $T,$ such that $T(W_0)\subset W_0$ and $T^*(W_0)\subset W_0.$ We claim that $\mathcal{A}$ is dense in $B(\mathcal{H}).$
Fix $0\neq A\in B(\mathcal{H}).$ Let $P_n$ denote the orthogonal projection on ${\rm span}\,\{e_1,e_2,\ldots, e_n\}$ and $Q_n=I-P_n.$  For a fixed $\varepsilon >0$ there exist $k_n\ge n$ such that
$$\|Q_{k_n}Ae_n\|\le 2^{-n/2}\varepsilon,\quad  \|Q_{k_n}A^*e_n\|\le 2^{-n/2}\varepsilon,\quad n\ge 1$$
Consider the operator $R$ given by
$$Rx=\sum_{n=1}^\infty \langle x,e_n\rangle Q_{k_n}Ae_n+\sum_{n=1}^\infty \langle x, Q_{k_n}A^*e_n\rangle e_n$$
We claim that $R$ is bounded. Indeed, by the Cauchy-Schwarz inequality we have
$$\sum_{n=1}^\infty |\langle x,e_n\rangle |\|Q_{k_n}Ae_n\|\le \|x\|\left (\sum_{n=1}^\infty \|Q_{k_n}Ae_n\|^2\right )^{1/2}\le \varepsilon\,\|x\|$$
and
$$\displaylines{\left \|\sum_{n=1}^\infty \langle x, Q_{k_n}A^*e_n\rangle e_n\right \|=\left (\sum_{n=1}^\infty |\langle x, Q_{k_n}A^*e_n\rangle |^2\right )^{1/2}\\ \le 
\|x\|\,\left (\sum_{n=1}^\infty  \|Q_{k_n}A^*e_n\|^2\right )^{1/2} \le \varepsilon\,\|x\|}
$$
Let $B=A-R.$ Then $\|A-B\|\le 2\varepsilon. $ Moreover $B(W_0)\subset W_0.$ Indeed
$$\displaylines{Be_m=Ae_m-Re_m=Ae_m-Q_{k_m}Ae_m-\sum_{n=1}^m \langle e_m, Q_{k_n}A^*e_n\rangle e_n\\ =P_{k_m}Ae_m-\sum_{n=1}^m \langle e_m, Q_{k_n}A^*e_n\rangle e_n\in W_0}$$
Observe that
$$B^*=A^* -R^*=A^*- \sum_{n=1}^\infty \langle x, Q_{k_n}Ae_n\rangle e_n-\sum_{n=1}^\infty \langle x,e_n\rangle  Q_{k_n}A^*e_n$$ Hence $B^*(W_0)\subset W_0.$
Remark The above is a partial answer, because the operators, which leave $W_0$ invariant do not need to leave the space $W$ invariant.
