I'm trying to get practice using Rodrigues' formula for Legendre Polynomials, but it's being quite confusing to manipulate that $n$-th derivative. Basically, I'm trying to calculate:
$$\int_{-1}^1 x^n P_n(x) dx$$
using Rodrigues' formula. Substituing $P_n$ we have
$$\int_{-1}^1 x^n P_n(x)dx = \dfrac{1}{2^n n!} \int_{-1}^1 x^n \dfrac{d^n}{dx^n}(x^2-1)^ndx$$
Now integrating by parts I have the following:
$$\int_{-1}^1 x^nP_n(x)dx=\dfrac{1}{2^n n!}\left(x^n \dfrac{d^{n-1}}{dx^{n-1}}(x^2-1)^n \bigg|_{-1}^1 - n\int_{-1}^1 x^{n-1} \dfrac{d^{n-1}}{dx^{n-1}}(x^2-1)^ndx\right)$$
Now I don't know how to evaluate that boundary term, also I would need to do integration by parts again, but then what? I imagine I would keep doing it until the derivative disappears. In the process I would get a lot of boundary terms and then in the end
$$\int_{-1}^1x^nP_n(x)dx = \dfrac{1}{2^n n!}\left([\text{Boundary terms}] + (-1)^n n!\int_{-1}^1(x^2 -1)^n dx\right)$$
Where the $(-1)^n$ comes because at each step the new integral is multiplied by the sign of the last one and the $n!$ appears because the $n$ on the first integral multiplies $(n-1)$ on the second and so forth.
But still, this is something I see intuitively, how can I really calculate that? Also, how to deal with all those boundary terms? How to make this computation in a good way?