How to show that for $|a|<1$: $\int_0^\infty\frac{x^a}{(x+2)^2}\,dx=\frac{a\pi2^{a-1}}{\sin\pi a}$? 
Show that for $|a|<1$:
$$\int_0^\infty\frac{x^a}{(x+2)^2}\,dx=\frac{a\pi2^{a-1}}{\sin\pi a}\,.$$


Let $a$ be a complex number such that $\big|\text{Re}(a)\big|<1$.  If $J(a)$ is the required integral, then when I use the keyhole contour above, I would get
$$(1-e^{i 2\pi a})J(a)=2\pi i\,\text{Res}\left(\frac{z^a}{(z+2)^2},z=-2\right)\,.$$
Now if $t=z+2$, then
$$z^2=(t-2)^a=(-2)^a\left(1+\frac{t}{2}\right)^a=2^a\left(1-a\frac{t}{2}+\mathcal{O}(t^2)\right)\,.$$
Therefore,
$$\text{Res}\left(\frac{z^a}{(z+2)^2},z=-2\right)=-a(-2)^a,$$
making
$$-2ie^{i \pi a}\sin(\pi a) J(a)=2\pi i (-a)(-2)^a=-2\pi i e^{i\pi a}2^a.$$
Hence
$$J(a)=\frac{\pi a 2^a}{\sin(\pi a)}.$$
Are there other solutions?
 A: Through the Laplace transform
$$ \mathcal{L}(x^a) = \frac{\Gamma(a+1)}{s^{a+1}},\qquad \mathcal{L}^{-1}\left(\frac{1}{(x+2)^2}\right) = s e^{-2s} $$
hence the original integral equals
$$ \Gamma(a+1)\int_{0}^{+\infty} s^{-a} e^{-2s}\,ds = 2^{a-1}\Gamma(1+a)\Gamma(1-a)= a 2^{a-1} \Gamma(a)\Gamma(1-a) = \frac{\pi a 2^{a-1}}{\sin(\pi a)} $$
by the reflection formula for the $\Gamma$ function.
A: $\newcommand{\bbx}[1]{\,\bbox[15px,border:1px groove navy]{\displaystyle{#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}$

With $\ds{\verts{\Re\pars{a} < 1}}$:

\begin{align}
\int_{0}^{\infty}{x^{a} \over \pars{x + 2}^{2}}\,\dd x &
\,\,\,\stackrel{x/2\ \mapsto\ x}{=}\,\,\,
2^{a - 1}\int_{0}^{\infty}{x^{a} \over \pars{x + 1}^{2}}\,\dd x
\\[5mm] & \stackrel{x + 1\ \mapsto\ x}{=}\,\,\,
2^{a - 1}\int_{1}^{\infty}{\pars{x - 1}^{a} \over x^{2}}\,\dd x
\\[5mm] & \stackrel{x\ \mapsto\ 1/x}{=}\,\,\,
2^{a - 1}\int_{1}^{0}{\pars{1/x - 1}^{a} \over 1/x^{2}}\,
\pars{-\,{\dd x \over x^{2}}}
\\[5mm] & =
2^{a - 1}\ \overbrace{\int_{0}^{1}x^{-a}\pars{1 - x}^{a}\,\dd x}
^{\ds{\ =\ \mrm{B}\pars{-a + 1, a + 1}}}\\[5mm] & = 
2^{a - 1}\,{\Gamma\pars{-a + 1}\Gamma\pars{a + 1} \over \Gamma\pars{2}}
\\[5mm] & = 
2^{a - 1}\,\Gamma\pars{-a + 1}
\bracks{a\,\Gamma\pars{a}}\qquad
\\[5mm] & = 
2^{a - 1}a\,{\pi \over \sin\pars{\pi a}}
\\[5mm] & = \bbx{2^{a - 1}\,{\pi a \over \sin\pars{\pi a}}}
\end{align}
$\ds{\mrm{B}}$ and $\ds{\Gamma}$ are the
Beta and
Gamma functions, respectively.
