We know from lecture that the $\Gamma$-function has the property $\Gamma(2)=\Gamma(1)=1$. If I evaluate the corresponding integral: $$\Gamma(x)=\int^{\infty}_0 t^{x-1}e^{-t} dt$$ at $x=1$ then I get: $\Gamma(1)=1$. So far so good.
However, if I evaluate the integral at $x=2$ I don't get $\Gamma(2)=1$.
This is my calculation: $$\Gamma(2)=\int^{\infty}_0 t^{2-1}e^{-t} dt=\int^{\infty}_0 te^{-t} dt=-te^{-t}\vert^{\infty}_0-\int^{\infty}_0e^{-t}dt =-te^{-t}\vert^{\infty}_0-1 =-1 $$
Maybe someone can tell me where I am wrong.
You dropped a minus sign. After the integration by parts, the integral in the second term gets a minus sign both from the anti-derivative of $\mathrm e^{-t}$ and from the minus sign in the rule for integration by parts; so it should be positive.