# I Closed form solution for this integral

1. Feb 14, 2017

### Oedipus

After series of algebraic simplifications, I ended up with the following integral:

$\int_0^\infty \exp(-Kx) \arctan(x) dx$

As far as I searched, there is no closed form solution for the integral. But, K is my design variable that I need to optimize later. To do this, I need to take K out of the integral. Can you manipulate this integral to express e.g., as a closed form function of K, multiplied with an integral independent of K?

2. Feb 14, 2017

### blue_leaf77

I guess there is a closed form in terms of cosine and sine integrals, Ci(x) and Si(x) respectively. If you are interested in this way, try solving that integral using partial integration first by choosing $dv = e^{-Kx}dx$ and $u = \arctan x$. For the integral $\int v \ du$ you will get
$$\int_0^{\infty} \frac{\exp(-Kx)}{1+x^2} \ dx$$
This integral can be shown to have the result expressible in terms of $\textrm{Ci}(K)$ and $\textrm{Si}(K)$. These integrals have a "friendly" derivative when you want to find the optimal $K$. Although the ultimate solution for $K$ might not be solvable analytically.

3. Feb 15, 2017

### Oedipus

Thank you blue_leaf77. I tried but it is still very difficult to solve for optimal K. My overall expression for the objective is in fact a function of this integral. Here I only provided the most problematic part.

After integration by parts I have,

\begin{aligned} \frac{1}{K}\int_0^\infty \frac{\exp(-Kx)}{1+x^2}dx &= \frac{i}{2K}\left[ e^{iK}\text{Ei}(-K(x+i)) - e^{-iK}\text{Ei}(-K(x-i)) \right]^{x=\infty}_{x=0}\\ &=\frac{i}{2K}\left[ -e^{iK}\text{Ei}(-iK)) + e^{-iK}\text{Ei}(iK) \right]\end{aligned}

where $\text{Ei}(x)=-\int_{-x}^\infty\frac{e^{-t}}{t}dt$ or $\text{Ei}(x)=-\int_{1}^\infty\frac{e^{tx}}{t}dt$. This is the same as what you said when $\text{Ci(x)}$ and $\text{Si(x)}$ are replaced with $\text{Ei(x)}$.

4. Feb 15, 2017

### blue_leaf77

If you can get the derivative of $\textrm{Ei}(x)$ in terms of basic functions I think that will be helpful, have you found it?

5. Feb 15, 2017

### Oedipus

The derivative of $\text{Ei}(x)$ can be calculated, but the overall optimization problem I am attempting cannot be solved simply by setting the derivative to zero.