Frullani 's theorem in a complex context. It is possible to prove that $$\int_{0}^{\infty}\frac{e^{-ix}-e^{-x}}{x}dx=-i\frac{\pi}{2}$$ and in this case the Frullani's theorem does not hold since, if we consider the function $f(x)=e^{-x}$, we should have $$\int_{0}^{\infty}\frac{e^{-ax}-e^{-bx}}{x}dx$$ where $a,b>0$. But if we apply this theorem, we get $$\int_{0}^{\infty}\frac{e^{-ix}-e^{-x}}{x}dx=\log\left(\frac{1}{i}\right)=-i\frac{\pi}{2}$$ which is the right result.

Questions: is it only a coincidence? Is it possible to generalize the theorem to complex numbers? Is it a known result? And if it is, where can I find a proof of it?

Thank you.
 A: I think you may simply consider 
$$ f(\alpha) = \int_{0}^{+\infty}\frac{e^{-\alpha x}-e^{-x}}{x}\,dx $$
as a complex variable function with the assumption $\text{Re}(\alpha)>0$. Then:
$$ f'(\alpha) = -\int_{0}^{+\infty}e^{-\alpha x}\,dx =-\frac{1}{\alpha} $$
and $f(1)=0$, so

$$ f(\alpha) = -\int_{1}^{\alpha}\frac{dz}{z}.$$

Since $\text{Re}(\alpha)>0$, the last complex integral is well defined, and you may define $\text{Re}\,f(\alpha)$ over $\left\{\text{Re}(z)\geq 0\right\}\setminus 2\pi i \mathbb{Z}$ by analytic continuation, since $\text{Re}\log\alpha = \log\|\alpha\|$. We also have $f(\alpha)=f(\bar{\alpha})$ by the Schwarz' reflection principle and 
$$ f(\alpha)=-f\left(\frac{1}{\alpha}\right) $$
by the obvious substitution. Another chance is given by the well-known lemma 
$$ \int_{0}^{+\infty}f(x)\frac{dx}{x} = \int_{0}^{+\infty}\mathcal{L}(f)(s)\,ds, $$
but we have to be careful with that, since in our case we are considering a Laplace transform on the boundary of its convergence domain.
The Cantarini-Frullani's theorem has just born :D
A: Note that from Cauchy's Integral Theorem
$$\oint_C \frac{e^{-iz}}{z}\,dz=0 \tag 1$$
where $C$ is the closed contour comprised of (i) the line segment from $\epsilon>0$ to $R$, (ii) the quarter circle of radius $R$ centered at the origin from $R$ to $-iR$, (iii) the line segment from $-iR$ to $-i\epsilon$, and (iv) the quarter circle of radius $\epsilon$ centered at the origin from $-i\epsilon$ to $\epsilon$.
We can write $(2)$ as 
$$\begin{align}\oint_C \frac{e^{-iz}}{z}\,dz&=\int_\epsilon^R \frac{e^{-ix}}{x}\,dx+\int_R^\epsilon \frac{e^{-y}}{-iy}\,(-i)\,dy\\\\
&+\int_0^{-\pi/2}\frac{e^{iRe^{i\phi}}}{Re^{i\phi}}\,iRe^{i\phi}\,d\phi\\\\
&+\int_{-\pi/2}^0\frac{e^{i\epsilon e^{i\phi}}}{\epsilon e^{i\phi}}\,i\epsilon e^{i\phi}\,d\phi\tag 2
\end{align}$$
As $R\to \infty$, the third integral on the right-hand side of $(2)$ approaches zero.  As $\epsilon \to 0$, the fourth integral on the right-hand side of $(2)$ approaches $i\pi/2$.  Thus, we see that
$$\int_0^\infty \frac{e^{-ix}-e^{-x}}{x}\,dx=-i\pi/2 \tag 3$$
as was to be shown!
A: $\newcommand{\bbx}[1]{\,\bbox[8px,border:1px groove navy]{{#1}}\,}
 \newcommand{\braces}[1]{\left\lbrace\,{#1}\,\right\rbrace}
 \newcommand{\bracks}[1]{\left\lbrack\,{#1}\,\right\rbrack}
 \newcommand{\dd}{\mathrm{d}}
 \newcommand{\ds}[1]{\displaystyle{#1}}
 \newcommand{\expo}[1]{\,\mathrm{e}^{#1}\,}
 \newcommand{\ic}{\mathrm{i}}
 \newcommand{\mc}[1]{\mathcal{#1}}
 \newcommand{\mrm}[1]{\mathrm{#1}}
 \newcommand{\pars}[1]{\left(\,{#1}\,\right)}
 \newcommand{\partiald}[3][]{\frac{\partial^{#1} #2}{\partial #3^{#1}}}
 \newcommand{\root}[2][]{\,\sqrt[#1]{\,{#2}\,}\,}
 \newcommand{\totald}[3][]{\frac{\mathrm{d}^{#1} #2}{\mathrm{d} #3^{#1}}}
 \newcommand{\verts}[1]{\left\vert\,{#1}\,\right\vert}$
\begin{align}
&\int_{0}^{\infty}{\expo{-\ic x} - \expo{-x} \over x}\,\dd x =
\int_{0}^{\infty}\pars{\expo{-\ic x} - \expo{-x}}
\int_{0}^{\infty}\expo{-xt}\,\dd t\,\dd x
\\[5mm] = &\
\int_{0}^{\infty}\int_{0}^{\infty}
\bracks{\expo{-\pars{t + \ic}x} - \expo{-\pars{t + 1}x}}\dd x\,\dd t =
\int_{0}^{\infty}
\pars{{1 \over t + \ic} - {1 \over t + 1}}\dd t =
\left.\ln\pars{t + \ic \over t + 1}\right\vert_{\ t\ =\ 0}^{\ t\ \to\ \infty}
\\[5mm] = &\
-\ln\pars{\ic} =\
\bbox[#ffe,10px,border:1px dotted navy]{\ds{-\,{\pi \over 2}\,\ic}}
\end{align}
A: 
The following development provides a possible way forward to generalizing Frullani's Theorem for complex parameters.

Let $a$ and $b$ be complex numbers such that $\arg(a)\ne \arg(b)+n\pi$, $ab\ne 0$, and let $\epsilon$ and $R$ be positive numbers.
In the complex plane, let $C$ be the  closed contour defined by the line segments (i) from $a\epsilon$ to $aR$, (ii) from $aR$ to $bR$, (iii) from $bR$ to $b\epsilon$, and (iv) from $b\epsilon$ to $a\epsilon$.
Let $f$ be analytic in and on $C$ for all $\epsilon$ and $R$.  Using Cauchy's Integral Theorem, we can write
$$\begin{align}
0&=\oint_{C}\frac{f(z)}{z}\,dz\\\\
&=\int_\epsilon^R \frac{f(ax)-f(bx)}{x}\,dx\\\\
&+\int_0^1 \frac{f(aR+(b-a)Rt)}{a+(b-a)t}\,(b-a)\,dt\\\\
&-\int_0^1 \frac{f(a\epsilon+(b-a)\epsilon t)}{a+(b-a) t}\,(b-a)\,dt\tag1
\end{align}$$
Rearranging $(1)$ reveals that
$$\begin{align}
\int_\epsilon^R \frac{f(ax)-f(bx)}{x}\,dx&=\int_0^1 \frac{f(a\epsilon+(b-a)\epsilon t)}{a+(b-a) t}\,(b-a)\,dt\\\\ &-\int_0^1 \frac{f(aR+(b-a)Rt)}{a+(b-a)t}\,(b-a)\,dt \tag 2
\end{align}$$
If $\lim_{R\to \infty}\int_0^1 \frac{f(aR+(b-a)Rt)}{a+(b-a)t}\,(b-a)\,dt=0$, then we find that
$$\begin{align}
\int_0^\infty \frac{f(ax)-f(bx)}{x}\,dx&=f(0)(b-a)\int_0^1\frac{1}{a+(b-a)t}\,dt\\\\
&=f(0)\log(|b/a|)\\\\
&+if(0)\left(\arctan\left(\frac{|b|^2-\text{Re}(\bar a  b)}{\text{Im}(\bar a b)}\right)-\arctan\left(\frac{\text{Re}(\bar a b)-|a|^2}{\text{Im}(\bar a b)}\right)\right) \tag 3
\end{align}$$
Since $(a-b)\int_0^1 \frac{1}{a+(b-a)t}\,dt$, $ab\ne 0$ is continuous in $a$ and $b$, then $(3)$ is valid for $\arg(a)=\arg(b)+n\pi$ also.


Note that the tangent of the term in large parentheses on the right-hand side of $(3)$ is
.
$$\begin{align}
\frac{\text{Im}(\bar a b)}{\text{Re}(\bar a  b)}&=\tan\left(\arctan\left(\frac{
|b|^2-\text{Re}(\bar a b)}{\text{Im}(\bar a b)}\right)-\arctan\left(\frac{\text{Re}(\bar a b)-|a|^2}{\text{Im}(\bar a b)}\right)\right)\\\\
&=\tan\left(\arctan\left(\frac{\text{Im}(b)}{\text{Re}(b)}\right)-\arctan\left(\frac{\text{Im}(a)}{\text{Re}(a)}\right)\right)
\end{align}$$

