What is the Fourier transform of $1/|x|$?
I looked it up in several tables and calculated it in Mathematica and Matlab. Some tables say that the answer is simply $$\frac{1}{|\omega|}$$ and in other table it is $$-\sqrt{\frac{2}{\pi}}\ln|\omega|$$ and in Mathematica and Matlab (mupad) it is $$-\sqrt{\frac{2}{\pi}}\ln|\omega|-2\gamma$$ where $\gamma$ is the Euler–Mascheroni constant. Why are there so many answers? Are they all equivalent in some way or two (or all) of them are wrong?
$\endgroup$ 83 Answers
$\begingroup$Although it is too late, let me give an explanation in hope for future reference.
Let me first compute the distributional Fourier transform (FT) of the function $f(x) = \log|x|$. Since $f$ is locally integrable and has slow growth, $f$ defines a tempered distribution on $\mathbb{R}$. So its FT is also well-defined.
Before we proceed, let us fix the convention for FT. Here, we will use the version
$$ \mathcal{F}[f](\xi) = \hat{f}(\xi) = \int_{\mathbb{R}} e^{-2\pi i \xi x} f(x) \, dx. $$
Now with a bit of computation, you can check that for any Schwartz function $\varphi \in \mathcal{S}(\mathbb{R})$,
\begin{align*} \langle \hat{f}, \varphi \rangle = \langle \hat{\varphi}, f \rangle &= \int_{\mathbb{R}} \hat{\varphi}(x) \log|x| \, dx \\ &= -(\gamma + \log(2\pi))\varphi(0) - \int_{\mathbb{R}} \frac{\varphi(x) - \varphi(0)\mathbf{1}_{[-1,1]}(x)}{|x|} \, dx. \tag{1} \end{align*}
This means that $\hat{f}$ does not reduce to a linear combination of locally integrable functions and Dirac delta. But if we restrict the domain of $\hat{f}$ onto the space $X=\{\varphi \in \mathcal{S}(\mathbb{R}) : \varphi(0)= 0\}$, then the FT has the following nice representation:
$$ \hat{f}(x) = -(\gamma + \log(2\pi))\delta_0(x) - \frac{1}{|x|} \quad \text{on } X. \tag{2}$$
Precisely in this sense, we may loosely say that the FT of $\frac{1}{|x|}$ is $- \log|\xi| - \gamma - \log(2\pi)$ in light of the inverse FT.
But wait! Since $\text{(21)}$ is being considered on the space $X$ where $\varphi(0) = 0$, taking Dirac delta gives no difference. So we can equally say that
$$ \hat{f}(x) = -\frac{1}{|x|} \quad \text{on } X $$
and hence we can also say that the FT of $\frac{1}{|x|}$ is simply $-\log |\xi|$. There is no contradiction on this, since we are considering this distribution on the subspace
$$ \mathcal{F}[X] = \left\{\varphi \in \mathcal{S}(\mathbb{R}) : \int_{\mathbb{R}} \varphi(x) \, dx = 0 \right\}$$
and thus adding constants makes no difference.
I am not good at physics, but I guess we can give a physical interpretation of it. Notice that $\text{(1)}$ has a term that cancels out the singularity of $\frac{1}{|x|}$. So in a very loose sense, it has the form
$$ (\log |x|)^{\wedge}(\xi) = - \frac{1}{|\xi|} + \infty \cdot \delta_0(\xi) \qquad \Leftrightarrow \quad \left( \frac{1}{|x|}\right)^{\wedge}(x) = \infty - \log |\xi|. $$
Thus in order that we can ignore the cancellation part, we should work on the situation where the addition of constant does not affect the meaning of the FT of $\frac{1}{|x|}$. Probably this is the case for potentials, where only the difference in values has actual physical meaning.
Addendum. (Derivation of $\text{(1)}$) The key trick is the following Frullani-type integral
$$ \forall a > 0 \ : \quad \int_{0}^{\infty} \frac{e^{-2\pi s} - e^{-2\pi as}}{s} \, ds = \log a. $$
From this, we find that
\begin{align*} \int_{\mathbb{R}} \hat{\varphi}(x) \log|x| \, dx &= \int_{\mathbb{R}} \hat{\varphi}(x) \left( \int_{0}^{\infty} \frac{e^{-2\pi s} - e^{-2\pi |x|s}}{s} \, ds \right) \, dx \\ &= \int_{0}^{\infty} \frac{1}{s} \left( \int_{\mathbb{R}} \hat{\varphi}(x) (e^{-2\pi s} - e^{-2\pi |x|s}) \, dx \right) \, ds \tag{i} \\ &= \int_{0}^{\infty} \frac{1}{s} \left( e^{-2\pi s} \varphi(0) - \int_{\mathbb{R}} \hat{\varphi}(x) e^{-2\pi |x|s} \, dx \right) \, ds \tag{ii} \\ &= \int_{0}^{\infty} \left( \frac{e^{-2\pi s}}{s} \varphi(0) - \int_{\mathbb{R}} \frac{\varphi(x)}{\pi(s^2 + x^2)} \, dx \right) \, ds \tag{iii} \end{align*}
Here,
(i) We interchanged the order of integrations by Fubini's theorem. It is not hard to check that the integrability condition is indeed met.
(ii) We utilized Fourier inversion $\varphi(\xi) = \int_{\mathbb{R}} \hat{\varphi}(x) e^{2\pi i \xi x} \, dx$.
(iii) We utilized the fact that $\langle \hat{\varphi}, \psi \rangle = \langle \varphi, \hat{\psi} \rangle$ for any integrable functions $\varphi, \psi$, together with the fact that the FT of $e^{-2\pi s |\cdot|}$ is $\frac{1}{\pi(s^2 + (\cdot)^2)}$.
Now we add and subtract the term
$$ \int_{\mathbb{R}} \frac{\varphi(0) \mathbf{1}_{[-1,1]}(x)}{\pi(s^2 + x^2)} \, dx = \frac{2\arctan(1/s)}{\pi s} \, \varphi(0)$$
inside the outer integral. Then
\begin{align*} \int_{\mathbb{R}} \hat{\varphi}(x) \log|x| \, dx &= \varphi(0) \int_{0}^{\infty} \left( \frac{e^{-2\pi s}}{s} - \frac{2\arctan(1/s)}{\pi s} \right) \, ds \\ &\qquad + \int_{0}^{\infty} \int_{\mathbb{R}} \left( \frac{\varphi(x) - \varphi(0) \mathbf{1}_{[-1,1]}(x)}{\pi(s^2 + x^2)} \right) \, dx \, ds \end{align*}
Now the first term is just a constant multiple of $\varphi(0)$, and this constant turns out to have the value
$$ \int_{0}^{\infty} \left( \frac{e^{-2\pi s}}{s} - \frac{2\arctan(1/s)}{\pi s} \right) \, ds = -\gamma - \log(2\pi). $$
For the second term, interchanging the order of integrations using Fubini's theorem gives
$$ \int_{\mathbb{R}} \frac{\varphi(x) - \varphi(0) \mathbf{1}_{[-1,1]}(x)}{|x|} \, dx $$
Therefore the claim follows.
$\endgroup$ 3 $\begingroup$This can be computed rigorously in terms of distributions, see here. The transform of a distribution is defined as $$(\mathcal F[f], \phi) = (f, \mathcal F[\phi]).$$ If $f$ is a regular distribution, induced by an ordinary function $f_o$, and the order of integration in the resulting double integral can be changed, we get $$(\mathcal F[f], \phi) = \int dx f_o(x) \mathcal F[\phi](x) = \\ \int dx f_o(x) \int d\xi \phi(\xi) e^{i x \xi} = \\ \int d\xi \left( \int dx f_o(x) e^{i \xi x} \right) \phi(\xi) = \\ \int d\xi F_o(\xi) \phi(\xi),$$ which means that $\mathcal F[f]$ is a regular distribution induced by $F_o$. Further, $F_o = (f, e^{i \xi x})$ (this can be thought of as just a shorthand notation for the integral, since $e^{i \xi x}$ is not in the space of test functions), which explains why it's valid to compute $\mathcal F[f]$ by directly applying $f$ to $e^{i \xi x}$: $$\mathcal F\!\left[ |x|^{-1} \right] = 2\int_0^{1} dx \frac {\cos \xi x - 1} x + 2\int_1^\infty dx \frac {\cos \xi x} x = -2 \ln |\xi| - 2 \gamma.$$
$\endgroup$ 4 $\begingroup$To be fully rigorous, we should concede that $1/|x|$ is not directly a distn on $\mathbb R$. But it does arise as an even tempered distn $u$ such that $x\cdot u=sign(x)$.
Up to a constant, Fourier transform gives ${d\over dx}\hat{u}=PV{1\over x}$. This equation has at least solution $\hat{u}=\log|x|$. The associated homog eqn has only multiples of $1$ as solns, so the eqn’s solns are $\hat{u}=\log|x|+c$ for arbitrary constants $c$ (and with the normalization constant).
The constant $c$ be determined by evaluation against $e^{-\pi x^2}$.
$\endgroup$ 2More in general
"Zoraya ter Beek, age 29, just died by assisted suicide in the Netherlands. She was physically healthy, but psychologically depressed. It's an abomination that an entire society would actively facilitate, even encourage, someone ending their own life because they had no hope. Th…"