Application of the change of variables theorem on the n-ball. Let f:$\mathbb{R} \to \mathbb{R}$ be continuous function and $z \in \mathbb{R}^n$. Show that
$$
\int_Bf(\langle x,z \rangle)=\int_Bf(x_n|z|)
$$
where $x=(x_1,...,x_n)$ and $B=\{x\in \mathbb{R}^n ; |x| \leq 1\}$.
My idea is to apply the change of variables theorem. I tried to find an orthogonal tranformation $h(x)=Qx$ such that $|detDh|=|detQ|=|\pm1|=1$. But I couldn't find such transformation. I would appreciate any tips on how to find this transformation or a new idea on how to solve this problem.
 A: Note that if $z=0$, then the equality is trivially satisfied, so let's suppose $z\neq 0$. One way to specify an orthogonal transformation (or actually any linear transformation) is to specify what it does to a basis.
Since $z\neq 0$, the orthogonal complement $\{z\}^{\perp} = \ker(\langle z, \cdot\rangle)$ is an $n-1$ dimensional subspace of $\Bbb{R}^n$. Now, choose an orthonormal basis $\{\xi_1, \dots, \xi_{n-1}\}$ for this subspace, and define $\zeta := \frac{z}{\lVert z \rVert}$. Then, $\{\xi_1, \dots, \xi_{n-1}, \zeta\}$ is an orthonormal basis for $\Bbb{R}^n$. Define $h:\Bbb{R}^n \to \Bbb{R}^n$ to be the linear transformation such that
\begin{align}
\begin{cases}
h(\xi_i) &= e_i \quad \text{for $i\in \{1,\dots, n-1\}$} \\
h(\zeta) &= e_n
\end{cases}
\end{align}
where $\{e_1, \dots, e_n\}$ is the standard ordered orthonormal basis of $\Bbb{R}^n$. Now, since $h$ is a linear transformation which maps an orthonormal basis bijectively to an orthonormal basis, it follows that $h$ preserves inner products, i.e it is an orthogonal linear transformation (which automatically means $|\det h| = 1$).
This transformation has the additional property that $h(z) = h(\lVert z \rVert \zeta) = \lVert z\rVert h(\zeta) = \lVert z\rVert e_n$; i.e it maps $z$ to the positive $n^{th}$ axis.
