<s>[INST] Integration of powers of the $\sin x$ I have to evalute
$$\int_0^{\frac{\pi}{2}}(\sin x)^z\ dx.$$
I put this integral in Wolfram Alpha, and the result is
$$\frac{\sqrt{\pi}\Gamma\left(\frac{z+1}{2}\right)}{2\Gamma\left(\frac{z}{2}+1\right)},$$
but I don't know why. If $z$ is a positive integer, then one can do integration by parts, many times. Eventually, this yields
$$\int_0^{\frac{\pi}{2}}(\sin x)^{2z}\ dx=\frac{(2z-1)!!}{(2z)!!}\frac{\pi}{2},$$
where $(2n-1)!!=1\cdot 3\cdots (2n-1)$, and $(2n)!!=2\cdot 4\cdots 2n$.
I appreciate your help.
 [/INST] Just, following Theo's hint
$$
\begin{align*}
\int_{0}^{\frac{\pi}{2}}{(\sin\psi)^x}d\psi&= \int_{0}^{\frac{\pi}{2}}{(\sin\psi)^{2\cdot \frac{1}{2}(x+1)-1}(\cos\psi)^{2\cdot \frac{1}{2}-1}}d\psi\\
&=\frac{1}{2}B\left( \frac{x+1}{2},\frac{1}{2} \right)\\
&= \frac{1}{2}\cdot \frac{\Gamma\left(\frac{x+1}{2}\right)\Gamma\left(\frac{1}{2}\right)}{\Gamma\left( \frac{x}{2}+1 \right)}\\
&=\frac{\sqrt{\pi}\Gamma\left(\frac{x+1}{2}\right)}{2\Gamma\left( \frac{x}{2}+1 \right)}.
\end{align*}$$
</s>