I am trying to solve this real integral using complex integration with semi circle. To do this with semicircle I noticed that the function is even, so $\int_{-\infty}^{+\infty}f\left(x\right)dx=2\int_{0}^{+\infty}f\left(x\right)dx$.
$$ \int_{0}^{+\infty}\frac{e^{\cos(x)}\cos\left(\sin\left(x\right)\right)}{a^{2}+x^{2}}dx. $$
I observe the function $\displaystyle f\left(z\right)=\frac{e^{e^{iz}}}{a^{2}+z^{2}}$. Because I want to solve the integral using semi circle, only pole $z=ia$ is inside the circle. The residue in that pole is $\frac{e^{e^{-a}}}{i2a}$ and the value of integral is
$$\int_{C_{R}}f\left(z\right)dz+\int_{-R}^{R}f\left(z\right)dz=2\pi i\cdot\frac{e^{e^{-a}}}{i2a}=\frac{\pi e^{e^{-a}}}{a}.$$
Now I want to solve the integral $\int_{C_{R}}f\left(z\right)dz$:
With the identity $z=Re^{i\theta}$ we have $dz=Rie^{i\theta}d\theta$. Now:
\begin{align*} \left|\int_{C_{R}}f\left(z\right)dz\right| & \leq\int_{C_{R}}\left|f\left(z\right)\right|dz\\ & \leq\int_{0}^{\pi}\left|\frac{e^{e^{i\cdot Re^{i\theta}}}}{a^{2}+R^{2}e^{i2\theta}}\cdot R\right|\cdot{\left|ie^{i\theta}\right|}\cdot d\theta\\ & =\int_{0}^{\pi}\left|\frac{e^{e^{i\cdot Re^{i\theta}}}}{a^{2}+R^{2}e^{i2\theta}}\cdot R\right|\cdot d\theta. \end{align*}
I use $R^{2}=\left|R^{2}e^{i2\theta}\right|=\left|R^{2}e^{i2\theta}+a^{2}-a^{2}\right|\leq\left|R^{2}e^{i2\theta}+a^{2}\right|+\left|-a^{2}\right|$ thus
$$\left|R^{2}e^{i2\theta}+a^{2}\right|\geq R^{2}-a^{2}\,\,\Rightarrow\,\,\frac{1}{\left|R^{2}e^{i2\theta}+a^{2}\right|}\leq\frac{1}{R^{2}-a^{2}}.$$
Now
\begin{align*} \left|\int_{C_{R}}f\left(z\right)dz\right| & \leq\int_{0}^{\pi}\frac{\left|e^{e^{i\cdot Re^{i\theta}}}\right|R}{R^{2}-a^{2}}\cdot d\theta\\ & =\frac{R}{R^{2}-a^{2}}\int_{0}^{\pi}\left|e^{e^{i\cdot Re^{i\theta}}}\right|d\theta=\frac{R}{R^{2}-a^{2}}\int_{0}^{\pi}\left|e^{e^{iR\left(\cos\theta+i\sin\theta\right)}}\right|d\theta\\ & =\frac{R}{R^{2}-a^{2}}\int_{0}^{\pi}\left|e^{e^{iR\cos\theta}\cdot e^{-R\sin\theta}}\right|d\theta \end{align*}
I don't know what to do with the last integral. Colud someone help me?