Suppose we have to compute $∂_{x}\theta(y-x)$, where $θ$ is the Heaviside step function, how do I find the result?
Intuitively I would just use the chain rule $\partial_{x}\theta(y-x)=-\delta(y-x)$ because $\partial_{x}\theta(x)=\delta(x).$
However if I use a test function $\psi\in L_{2}(\mathbb{R})$ then we find that $$\langle \theta'|\psi\rangle \equiv \int_{\mathbb{R}} dx\,\theta'(x-y)\psi(x)=-\int_{\mathbb{R}} dx\psi'(x)\theta(x-y)=-\int_{y}^{\infty} dx\psi'(x)=\psi(y)=\langle \delta_{y}|\psi\rangle$$ Thus the result should be $\theta'(y-x)=\delta(x-y)$. I'm more convinced of the latter, which is the correct one?
I made a mistake as Ted said in the comment section, indeed $$ \begin{split} \langle \theta^\prime(y-x)|\psi\rangle & = \int_{\mathbb{R}} dx \theta^\prime(y-x)\psi(x) \\ & =-\int_{\mathbb{R}} dxθ(y-x)\psi^\prime(x)\\ & =-\int_{-\infty}^{y} dx\psi'(x)=-\psi(y) =\langle -\delta(x-y)|\psi\rangle \end{split}$$ So at the end of the day the two results coincide.