calculate $ \intop_{a}^{b}\left(x-a\right)^{n}\left(x-b\right)^{n}dx $ I need to calculate $ \intop_{a}^{b}\left(x-a\right)^{n}\left(x-b\right)^{n}dx $ this.
Now, this exercise came with hints. I have followed the hints and proved :
$ \intop_{-1}^{1}\left(1-x^{2}\right)^{n}dx=\prod_{k=2}^{n}\frac{2k}{2k+1}\cdot\frac{8}{3} $
And now the last hint is to use the result I got from the last integral, and use linear substitution. Still, could'nt figure out how to do it.
Thanks in advance.
 A: Substitute  $x=\frac12[(b-a)y+(b+a)]$ to get
$$ \intop_{a}^{b}\left(x-a\right)^{n}\left(x-b\right)^{n}dx 
= (-1)^n\left( \frac{b-a}2\right)^{2n+1}I_n
$$
where, per integration-by-parts,,
$$I_n=\int_{-1}^1(1-y^2)^ndy=\frac{2n}{2n+1}I_{n-1},\>\>\> I_0=2
$$
A: Let $x=a\sin^2t+b\cos^2t \implies dx=2(a-b)\sin t \cos t$
So $$I=\int_{a}^{b} (x-a)^n~(x-b)^n~dx=\int_{\pi/2}^{0} (b-a)^n \cos^{2n} t(a-b)^{2n} \sin^n t dt.$$
$$\implies I=2(-1)^n (b-a)^{2n+1}\int_{0}^{\pi/2} \sin^{2n+1}t ~\cos^{2n+1} t ~dt$$
$$\implies I==(-1)^n (b-a)^{2n+1} \frac{\Gamma^2(1+n)}{\Gamma(2n+2)}.$$
Here we have used $\beta-$integral in terms of $\Gamma$ function, see:
https://en.wikipedia.org/wiki/Beta_function
A: I will try to answer in the intended way.
Why might we want to think of a linear transformation? Well, we have already computed the integral involving $(1-y^2) = -(y-1)(y+1)$. (I have relabelled for clarity) Now, a linear transformation $y = mx + c$ is completely specified by two points, so we can set $(x,y) = (a, -1), (b, 1)$ to be those two points.
Let us assume that $a<b$. Then, we get $-1 = ma + c$, $1 = mb + c$ so $m(b-a) = 2$, giving $m = 2/(b - a)$ and $c = 1 - 2b/(b - a) = -(b+a)/(b-a)$.
Let your integral problem be $I$, Let $J = \int_{-1}^1 (-1)^n(y-1)^n(y+1)^n dy$.
Then it should be straightforward from here.
A: Notice that
$$
\begin{align}
\int^b_a(x-a)^n(x-b)^n\,dx&=\int^{b-a}_0x^n(x-(b-a))^n\,dx=(b-a)^n\int^{b-a}_0x^n\big(\tfrac{x}{b-a}-1\big)^n\,dx
\end{align}
$$
The change of variables $u=\frac{x}{b-a}$ reduces the expression to
$$
\begin{align}
\int^b_a(x-a)^n(x-b)^n\,dx&=(b-a)^{2n+1}\int^1_0u^n(u-1)^n\,du=(b-a)^{2n+1}B(n+1,n+1)\\
&=(b-a)^{2n-1}\frac{\Gamma(n+1)\Gamma(n+1)}{\Gamma(2n+2)}=(b-a)^{2n+1}\frac{(n!)^2}{(2n+1)!}
\end{align}
$$
where $B(x,y)$ is the well known beta function. The rest should be straight forward (using the relation between beta and gamma function).
