I defined a one-dimensional momentum operator $\hat{p}=-i\hbar\frac{\partial}{\partial{x}}$ in Mathematica
p = -I * h * D[#, x]&
and I want to get the kinetic energy operator $\hat{T}=\hat{p}^2/2m=-\frac{\hbar^2}{2m}\frac{\partial^2}{\partial x^2}$ from it, so
T = p^2/(2m)
but it gives the wrong result
What can I do about it? Do I have to derive the operators by hand?
