# What is the specific Hilbert space of the finite square well?

For a free particle, the QM Hilbert space is $$L^2(-\infty,\infty)$$ which is the space of all square integrable functions. As a result, this space does not contain functions of the form $$e^{\alpha x}$$ or $$e^{-\alpha x}$$ as they are not square integrable, per the bounds. For an infinite square well (of width $$a$$), the space is $$L^2(-a,a)$$ and as a result functions of the form $$e^{\alpha x}$$ and $$e^{-\alpha x}$$ are perfectly acceptable as they are square integrable between $$(-a,a)$$ (not to imply these are physically realizable states, but mathematically there is nothing wrong with them). The finite square well (also of width $$a$$) has known solutions of the form $$\psi_{1}=Ae^{\alpha x}$$ for $$x<-a$$, $$\psi_{2}=B\sin(kx)+C\cos(kx)$$ for $$-a, and $$\psi_{3}=De^{-\alpha x}$$ for $$x>a$$. My confusion then is that the finite square well appears to be 3 separate Hilbert spaces which are piece-wise defined, something along the lines of $$L^{2}(-\infty,a)$$ for $$x<-a$$, $$L^{2}(-a,a)$$ for $$-a, and $$L^{2}(a,\infty)$$ for $$x>a$$. Is this correct? I have never seen this discussed or indicated anywhere and am just looking for a clarification. If this is correct, is there a term for connecting spaces like this, as it doesnt appear to be a tensor sum or tensor product of the spaces?

The Hilbert space is simply $$L^2(\mathbb{R})$$, there is no piece-wise definition: it is the wave function that is piece-wise defined, but the three pieces $$\psi_1$$, $$\psi_2$$ and $$\psi_3$$ are subject to the boundary conditions in $$x=\pm a$$ so that the global wave function is continuous and continuously differentiable $$\forall x \in \mathbb{R}$$. In checking if $$\psi\in L^2(\mathbb{R})$$, you would square-integrate $$\psi_1$$ from $$-\infty$$ to $$-a$$, $$\psi_2$$ from $$-a$$ to $$a$$, and $$\psi_3$$ from $$a$$ to $$\infty$$, and doing so each of the three integrals yields a finite result.
• Thanks for the reply! The only thing at seems odd to me is that we are using $e^x$ and $e^{-x}$ in a space in which they are not elements (although I understand in this case the overall wave function remains square-integrable). Does that not cause a problem, or is my understanding incorrect? Commented Feb 2, 2021 at 15:34
• We are not using $e^x$ for all $x$, we are using $e^x$ for $x<-a$, which is an element of $L^2(\mathbb{R})$ (and the same goes for $e^{-x}$). Commented Feb 2, 2021 at 16:02
• Can you clarify a little further why it is acceptable to use $e^{x}$ for $x<-a$? It was my understanding that $e^{x}$ was not an element of the space $L^{2}(-\infty,\infty)$ at all, however you are saying it is an element, but only of part of the space? Commented Feb 2, 2021 at 17:41