For a class on Monte-Carlo simulation methods I want to do a comparison of Monte-Carlo integration and numerical integration on sparse grids. For this purpose I need a function $f$ defined over the $n$-dimensional hypercube $[-1,1]^n$ of which I know the value of the integral $\int_{[-1,1]^n} f$ in order to compare the calculation errors of the different methods. I thought about integrating the unit $n$-sphere as this is defined over the hypercube and the exact volume of the unit $n$-sphere is given by
$$V_n=\frac{\pi^{\frac{n}{2}}}{\Gamma (\frac{n}{2} +1)}$$
Now integrating the whole $n$-sphere will result in the integral being 0 as it is symmetric. That's why I thought about using only the upper unit $n$-sphere. Then the value of the integral would be given by $V_n/2$. However, I did not manage to come up with a function describing this upper half of the $n$-sphere. In the 2-dimensional case the upper sphere $U_2$ would be given by $U_2=\{ x_2= \sqrt{1-x_1^2},x_2\geq 0\}$ or in the more general case of the unit $n$-ball $U_n = \{ \sqrt{1- \sum_{i=1}^{n-1} x_i^2 }, x_n \geq 0 \}$.
Is there a way to express $U_n$ as a function that I could plug into my implemented integration algorithms to integrate it over the $n$-dimensional hypercube?