I'm working through problem 1.17 in Pattern Recognition and Machine Learning where I'm getting:
\begin{align*} \Gamma(x+1) = & \int_{0}^{\infty} u^{(x+1)-1}e^{-u} \hspace{1mm} du \\ = & \big[-u^x e^{-u} \big]_{0}^{\infty} - \int_{0}^{\infty} e^{-u}xu^{x-1} \hspace{1mm} du & \text{(simplify and integrate by parts*)} \end{align*}
*$f=u^x$, $g_u=e^{-u}$, $f_u= xu^{x-1}$, and $g=\int e^{-u} \hspace{1mm} du$. To solve the integral for $g$: \begin{align*} g= & - \int e^s \hspace{1mm} ds & \text{(substitute $s = -u$ and $-ds = du$)} \\ = & -e^s + C & \text{(by known antidervative)} \\ = & -e^{-u} + C & \text{(substitute $s = -u$)} \end{align*}
The book (in the link above) says the integration by parts results in (notice the plus sign - otherwise equivalent): $$\big[-e^{-u}u^x \big]_{0}^{\infty} \boldsymbol{+} \int_{0}^{\infty} xu^{x-1}e^{-u}$$
I've gone over my work again and again. I can't see where I made a mistake.