I'm trying to calculate the following integral:
$$ \int_0^1 e^{-\lambda(1-x)} (1-x)^{n-1} x^{k-n} dx $$ It seems like kind of a combination of Gamma and Beta function. I'm suspecting that it has something to do with both of them, however I can't see the connection.
Any hint would be welcome!
The integrand is the product of an exponential and a polynomial. You can pull out a factor $e^{-\lambda}$ and compute the antiderivative explicitly.
Let it be $Q(x)e^{\lambda x}$, such that
$$(Q(x)e^{\lambda x})'=(\lambda Q(x)+Q'(x))e^{\lambda x}=P(x)e^{\lambda x}=\sum_{j=0}^{n-1}\binom{n-1}j(-1)^jx^{j+k-n}e^{\lambda x}.$$
The unknown coefficients of $Q$ form a bidiagonal system of equations, which is straigthforward to solve ($\lambda q_i+iq_{i-1}=p_i$), and the definite integral is
$$Q(1)-Q(0)e^{-\lambda},$$ where $Q(1)$ is the sum of the coefficients of $Q$.