I have been trying to derive the formula for $\chi^2$ distribution with $n-1$ degrees of freedom, but I am still having trouble. Assume $A$ is an orthogonal matrix with first row inputs $A_{1i}=n ^ {-1/2}$ for $1 \leq i \leq n$. $Z_1, ..., Z_n$ are i.i.d $N(0, 1)$, and $W=AZ$. Also $\sum_{i = 2}^{n} W_i^{2}$ has a $\chi_{n-1} ^ 2$. How can I show the following?
$\sum_{i = 2}^{n} W_i^{2} = \sum_{i = 1}^{n} (Z_i - \bar{Z})^{2}$