Resources: https://en.wikipedia.org/wiki/Chi-squared_distribution The PDF of the χ2 distribution is given by χ2(x;k)=2k/2Γ(k/2)1x(k/2)−1e−x/2 Where Γ is the Gamma Function