# Commutation relation of position and momentum using Dirac notation

This is likely a very trivial/silly question, but in following a derivation of the position and momentum commutation relation using the dirac notation, I am having trouble justifying a certain step.

Suppose we have some arbitrary Hilbert-space vector $|\psi\rangle$, and we want to know the commutator $[x,p]$ using dirac notation. Then, projecting this onto coordinate space

$$\langle x'|\hat{x}\hat{p} - \hat{p}\hat{x})|\psi\rangle = \langle x'|\hat{x}\hat{p}|\psi\rangle - \langle x'|\hat{p}\hat{x}|\psi\rangle = {\hbar \over i}\langle x'|\hat{x}|{d\over dx}\psi\rangle - \int\langle x'|\hat{p}|x\rangle \langle x|\hat{x}|\psi\rangle dx$$

Is the expansion in the x-basis for the $\langle x'|\hat{p}\hat{x}|\psi\rangle$ term because there is a derivative presumably acting on everything to the right, if not, what is the reason I can't just simply do $\langle x'|\hat{p}\hat{x}|\psi\rangle = x'\langle x'|\hat{p}|\psi\rangle$ and have $[x, p] = 0$. I would like to know if this is also a standard technique when deriving the other commutation relations (namely position and energy, and momentum and energy). Thank you.

• If you like this question you may also enjoy reading this and this Phys.SE posts. Nov 9 '14 at 9:56

Your claim that the derivative is in the expansion of $\langle x'|\hat{p}\hat{x}|\psi\rangle$ acts on everythin on the right is correct. Realize that $$\langle x|\hat{p}|\psi\rangle=\frac{\hbar}{i}\frac{d}{dx}\langle x|\psi\rangle=\frac{\hbar}{i}\frac{d}{dx}\psi(x)$$ So $$\langle x'|\hat{p}\hat{x}|\psi\rangle=\frac{\hbar}{i}\frac{d}{dx'}\langle x'|\hat{x}|\psi\rangle=\frac{\hbar}{i}\frac{d}{dx'}\left[x'\psi(x')\right]=\frac{\hbar}{i}\left[\psi(x')+x'\frac{d}{dx'}\psi(x')\right]$$ Substituting this in your expression $$\langle x'|[\hat{x},\hat{p}]|\psi\rangle=\frac{\hbar}{i}x'\frac{d}{dx'}\psi(x')-\frac{\hbar}{i}\left[\psi(x')+x'\frac{d}{dx'}\psi(x')\right]=-\frac{\hbar}{i}\psi(x')=i\hbar\psi(x')$$ That is, we have $[\hat{x},\hat{p}]=i\hbar$. I think that using Dirac notation to derive commutators in these cases is too messy. If you just use position representation, the derivations are clearer: $$[\hat{x},\hat{p}]\psi(x)=x\frac{\hbar}{i}\frac{d}{dx}\psi(x)-\frac{\hbar}{i}\frac{d}{dx}\left[x\psi(x)\right]=i\hbar\psi(x)$$