TITLE: Integral $\int_{-2}^0 \frac{x}{\sqrt{e^x+(x+2)^2}}dx$
QUESTION [8 upvotes]: I am trying to evaluate $$\int_{-2}^0 \frac{x}{\sqrt{e^x+(x+2)^2}}dx$$ So far I had no succes using trig substitution or integration by parts, also some random substitution like $x=2t$ and moved the exponential to the numerator, but I am stuck. Could you perhaps give me an idea? (this is a college admission problem)

REPLY [7 votes]: Mathematica could not solve this as written,
$$
I=\int_{-2}^0 \frac{x}{\sqrt{e^x+(x+2)^2}}dx
$$
I introduced a parameter $a$
$$
I(a)=\int_{-2}^0 \frac{x}{\sqrt{a e^x+(x+2)^2}}dx
$$
took a Mellin transform with respect to $a$
$$
\mathcal{M}_a[I(a)](s)= \Gamma(s)\Gamma\left(\frac{1}{2}-s\right)\int_{-2}^0 \frac{x \left(\frac{e^x}{(2+x)^2}\right)^{-s}}{\sqrt{\pi}\sqrt{(x+2)^2}}dx
$$
Mathematica can solve this
$$
\mathcal{M}_a[I(a)](s)= \frac{-4^s\Gamma(s)\Gamma\left(\frac{1}{2}-s\right)}{\sqrt{\pi}s}
$$
and the inverse Mellin transform gives \begin{equation}
I(a) = -2 \text{arcsinh}\left(\frac{2}{\sqrt{a}}\right)
\end{equation}
which for $a=1$ checks out numerically as around $I \approx -2.88727$