How to derive chi-square distribution with $2$ degrees of freedom? $$X=z_1^2+z_2^2 \\ f(z_1,z_2)=\frac1{2\pi} \exp\left[\frac{-1}{2}(z_1^2+z_2^2)\right]$$
Consider the transformation $$z_1=r\cos(\theta), \qquad z_2=r\sin(\theta),$$ so that $$X=z_1^2+z_2^2=r^2\cos^2(\theta)+r^2\sin^2(\theta)=r^2.$$ From here I don’t know how to complete.