Consider
$$
\int_{-\infty}^{\infty}\cos(\omega x)\frac{\arctan\left(\frac{1}{x}\right)}{x} dx, \quad \text{for } \omega > 0,
$$
although for $\omega \in \mathbb{C}$ would be interesting. What is the above cosine transform? Does it exist?
My attempt so far: for $x \in \mathbb{R}$ we know that
$$
\arctan(x) + \arctan(1/x) = \text{sign}(x)\pi/2,
$$
and we know that
$$
\int_{-\infty}^{\infty}\cos(\omega x)\frac{\arctan(x)}{x} dx = \pi \Gamma(0,|\omega|),
$$
where $\Gamma$ is the upper incomplete Gamma function. Using this, then
$$
\begin{align}
\int_{-\infty}^{\infty}\cos(\omega x)\frac{\arctan\left(\frac{1}{x}\right)}{x} dx
&= \int_{0}^{\infty}\cos(\omega x)\frac{\arctan\left(\frac{1}{x}\right)}{x} dx + \int_{-\infty}^{0}\cos(\omega x)\frac{\arctan\left(\frac{1}{x}\right)}{x} dx \\
&= -\int_{-\infty}^{\infty}\cos(\omega x)\frac{\arctan\left(x\right)}{x} dx -\frac{\pi}{2}\int_{-\infty}^{0}\cos(\omega x)\frac{1}{x} dx + \frac{\pi}{2}\int_{0}^{\infty}\cos(\omega x)\frac{1}{x} dx \\
&= -\pi\Gamma(0,|\omega|) – \pi\int_{0}^{\infty}\cos(\omega x)\frac{1}{x} dx.
\end{align}
$$
But the integral on the right does not make sense. I assume this is not the correct approach.
Best Answer
If I am not running completely nuts, we can attack this via fantasy and brute force. First of all notice that the integral is even, hence we can write it as
$$2\int_0^{+\infty} \cos(\omega x) \dfrac{\arctan(1/x)}{x}\ \text{d}x$$
Now we call this integral $F(\omega, x)$.
Let's now differentiate wrt $\omega$:
$$\dfrac{\partial F}{\partial\omega} = -2\int_0^{+\infty} \sin(\omega x) \arctan\left(\dfrac{1}{x}\right)\ \text{d}x$$
This integral can be computed (there are lots of ways to do this, also it is absolutely convergent), and we have:
$$\dfrac{\partial F}{\partial \omega} = -2\left(\frac{\pi e^{-\frac{\omega}{2}} \sinh \left(\frac{\omega}{2}\right)}{\omega}\right)$$
This result holds iff $\omega > 0$ if $\omega\in\mathbb{R}$, or as I wrote in the comment, for $\Im(\omega)\leq 0$ but we can manage to extend it for every $\omega \in \mathbb{C}$.
If you master a bit of elementary calculus techniques, you can easily find that
$$\left(\frac{\pi e^{-\frac{\omega}{2}} \sinh \left(\frac{\omega}{2}\right)}{\omega}\right) = \frac{\pi -\pi e^{-\omega}}{2 \omega}$$
To get $F(\omega)$ we now integrate this with respect to $\omega$:
$$F(\omega) = -2\int \frac{\pi -\pi e^{-\omega}}{2 \omega}\ \text{d}\omega$$
The integration is rather easy, and it does make a Special Function to pop out: the Exponential Integral Special Function:
$$-2\int \frac{\pi -\pi e^{-\omega}}{2 \omega} = -\pi (\log (\omega)-\text{Ei}(-\omega))$$
You can find more on the Exponential Integral here: https://en.wikipedia.org/wiki/Exponential_integral
P.s. In a more rigorous way, we should attack the first part with the principal value method, just to be sure. But eventually it leads to the same result.