Taking the Hamiltonian eigenvalue problem into position space? I'm having a hard time notationally understanding the relationship of:
$$ \hat{H} \vert{\psi}\rangle = E\vert \psi\rangle  $$
and
$$\hat{H} \psi(x) = E\psi(x) $$
Here's my thought process: Starting from the equation:
$$ \hat{H} \vert{\psi}\rangle = E\vert \psi\rangle  $$
$$ \hat{H} \int dx \vert x \rangle \langle x\vert \psi \rangle = E\int dx \vert x \rangle \langle x\vert \psi \rangle  $$
We know that $$  \langle x\vert \psi \rangle = \psi(x)$$ in our position representation. Does this mean that $ \hat{H} $ in Dirac notation translates to $ \hat{H} \int dx \vert x \rangle $ in position representation? Something about this seems quite strange to me.
 A: It's better to do it this way. Start with the expression without reference to any basis
$$\hat{H} \vert{\psi}\rangle = E\vert \psi\rangle$$
Then bring in $\langle x|$
$$\langle x|\hat{H} \vert{\psi}\rangle =\langle x| E\vert \psi\rangle$$
You are correct in having $\langle x|\psi\rangle=\psi(x)$, so the right hand side with scalar $E$ easily becomes $E\psi(x)$
On the left hand side we exploit our completeness relation
$$\langle x|\hat{H} \vert{\psi}\rangle = \int\langle x|\hat{H}|x'\rangle\langle x' \vert{\psi}\rangle\,\text dx'= \int\langle x|\hat{H}|x'\rangle\psi(x')\,\text dx'$$
Since $\hat H =\hat H(\hat X,\hat P)$, the matrix elements of $\hat H$ in the position basis are given as 
$$\langle x|\hat{H}|x'\rangle=\delta(x'-x)H\left(x',\frac{\text d}{\text dx'}\right)$$
Therefore, we end up with
$$\langle x|\hat{H} \vert{\psi}\rangle =H\psi(x)$$
And so we have
$$H\psi(x)=E\psi(x)$$
A: Note that, formally, the Hilbert space in the position representation is $L^2(\mathbb R^n)$, so that $|\psi\rangle$ is indeed an $L^2$-function.
