I know that $ \phi(w) \in \mathscr S(R) $ (Schwartz space) and then the test is asking to evaluate this integral:
$$ \int_0^\infty w \ \hat{\phi}(w) \ dw $$
I know that the answer is the follow $$ \int_{-\infty}^\infty \log|x|\phi''(x)dx -i\pi\phi'(0) $$
Looking at the answer I'm quite sure I have to integrate by parts but I don't know how to handle this because of the Fourier Transform. I thought I could swap the FT because $ \phi(w) \in \mathscr S(R) $ but if I understood correctly the integral had to be from $ -\infty $ to $ \infty $ and not from 0 to $ \infty $. Also the integrand is not even neither.
Can somebody please explain how to do this?
Edit: $$ \hat{\phi}(w) = \int_{-\infty}^\infty \phi(x)e^{-iwx}dx $$
Using the $\xi$ convention for the Fourier transform (adapt it to your problem with the $\omega$ convention) $$\langle 2i \pi \xi \hat{\phi} , 1_{\xi > 0} \rangle = \langle \phi', pv.(\frac{1}{-2 i\pi x}) + \frac{\delta}{2} \rangle = \frac{\phi'(0)}{2}+\langle \phi'', \frac{\log|x|}{2i\pi} \rangle$$ because $ pv.(\frac{1}{-2 i\pi x}) + \frac{\delta}{2}$ is the inverse FT of $1_{\xi > 0}$, and $ pv.(\frac{1}{ x})$ is the distributional derivative of $\log|x|$