Solving the free particle problem in momentum space $\newcommand{\ket}[1]{|#1\rangle}$$\newcommand{\bra}[1]{\langle#1|}$(Note: this question was asked before here but I didn't follow the answer.)
For the free particle, Schrödinger's equation is given by
$$i\hbar\frac{d}{dt}\ket{\psi(t)} = \frac{P^2}{2m}\ket{\psi(t)}.$$
I would like to solve for the wave function in momentum space, i.e. $\psi(p,t) = \langle p\ket{\psi(t)}$. My first step was to try solve the eigenvalue problem
$$H\ket{E} = \frac{P^2}{2m}\ket{E} = E\ket{E}$$
in momentum space, which yields
$$ \frac{1}{2m}\bra{p}P^2\ket{E} = E\langle p\ket{E},\\\frac{p^2}{2m}\psi_E(p) = E\psi_E(p).$$
where $P\ket{p}=p\ket{p}$ and $\psi_E(p) = \langle p \ket{E}$.
I'm not entirely sure where to go from here to determine $E$ and $\psi_E(p)$. It seems like $E = p^2 / 2m$, but the fact that $p$ is a variable confuses me.
 A: Another way to look at this problem is to consider it in position space, and then transform the solution to it's momentum space representation. While this may seem like an unnecessary amount of work, it may illuminate to you the delta function solution in a different way. So, in position space we have
$$-\frac{\hbar^2}{2m}\frac{d^2\psi}{dx^2}=E\psi\:\:\:\xrightarrow{\kappa^2\:\equiv\:2mE/\hbar^2}\:\:\: \frac{d^2\psi}{dx^2}=-\kappa^2\psi\:\:\:\rightarrow\:\:\:\psi(x)=Ae^{i\kappa x}+Be^{-i\kappa x}$$
Before casting this into its momentum space representation, recall the integral representation of the Dirac delta function (which can be arrived at by considering orthogonality of position or momentum eigenstates): 
$$\delta(\alpha-\beta)=\frac{1}{2\pi\hbar}\int e^{ix(\alpha-\beta)/\hbar}dx.$$
Using the above, let's Fourier transform our solution to get its momentum representation:
$$\psi(p) = \frac{1}{\sqrt{2\pi\hbar}}\int\psi(x)e^{-ipx/\hbar}dx = \frac{A}{\sqrt{2\pi\hbar}}\int e^{ix(\kappa-p/\hbar)}dx + \frac{B}{\sqrt{2\pi\hbar}}\int e^{ix(-\kappa-p/\hbar)}dx\\ = \sqrt{2\pi\hbar}\Big[A\delta(\kappa-p/\hbar)+B\delta(-\kappa-p/\hbar)\Big].$$
Now stick in $\kappa = \sqrt{2mE}/\hbar$, and use the fact that $\delta(-x) = \delta(x)$ and  $\:\delta(\alpha x) = \delta(x)/|\alpha|$ to rewrite this as
$$\psi(p) = \tilde{A}\delta(p-\sqrt{2mE}) + \tilde{B}\delta(p+\sqrt{2mE}),$$
where I've collected constants and called them $\tilde{A}$ and $\tilde{B}$ for simplicity of the final solution. Obviously this is more work than noticing the solution in momentum space corresponds to delta function behavior, but perhaps you'll find this route illuminating; or, if nothing else, a nice consistency check.
A: You get the solution of
$$ \frac{p^2}{2m}\psi_E(p) = E\psi_E(p) $$
as follows
$$ \left(\frac{p^2}{2m}-E \right)\psi_E(p) = 0 $$
For this equation to hold it must be either $\frac{p^2}{2m}-E = 0$ or $\psi_E(p) = 0$.
That means for every $p$ except for $p=\pm\sqrt{2mE}$ it must be $\psi_E(p) = 0$.
Only for $p=\sqrt{2mE}$ and $p=-\sqrt{2mE}$ it is allowed that $\psi_E(p)$ is non-zero.
So the most general solution to all this is (using the Dirac delta function)
$$ \psi_E(p) = A \delta(p-\sqrt{2mE}) + B \delta(p+\sqrt{2mE})$$
where $A$ and $B$ are arbitrary constants.
