A related post here. In which the author claimed, if $X_{i}\sim N(\mu,\sigma^2),i=1,\cdots,n$ are iid then
$$\frac{(n-1)s^2}{\sigma^2}\sim \chi^2(n-1)$$
in which $s^2$ is the unbiased sample variance. i.e. $s^2=\frac1{n-1}\sum(X_i-\bar X)^2$ where $\bar X=\frac1n\sum X_i$.
I want a proof of it. But I can't do one on my own. In fact, contrary to my initial suspicion that $X_i-X$ are uncorrelated, I actually got \begin{align} \mathsf{Cov}\,(X_i-\bar X,X_j-\bar X) &=\mathsf{Cov}\,(X_i,X_j)+\mathsf{Var}\,(\bar X,\bar X)-2\mathsf{Cov}\,(X_i,\bar X)\\ &=0+\frac1{n^2}n\sigma^2-2\frac1n\sigma^2\\ &=-\frac1n\sigma^2\ne 0 \end{align}
So where does the Chi square come from?