# Non-central Chi-squared Distribution

If squares of k independent standard normal random variables (mean=0, variance=1) are added, it gives rise to central Chi-squared distribution with ‘k’ degrees of freedom. Instead, if squares of k independent normal random variables with non-zero mean (mean $$\neq$$ 0 , variance=1) are added, it gives rise to non-central Chi-squared distribution.

The non-central Chi-squared distribution is a generalization of Chi-square distribution. A non-central Chi squared distribution is defined by two parameters: 1) degrees of freedom and 2) non-centrality parameter.

As we know from previous article, the degrees of freedom specify the number of independent random variables we want to square and sum-up to make the Chi-squared distribution. Non-centrality parameter is the sum of squares of means of the each independent underlying Normal random variable.

The non-centrality parameter is given by

The PDF of the non-central Chi-squared distribution is given by

In the above equation, $$f_{\chi_k}(x;\lambda)$$ indicates the non-central Chi-squared distribution with $$k$$ degrees of freedom with non-centrality parameter specified by $$\lambda$$ and the factor $$f_{\chi_{k+2n}}(x)$$ indicates the ordinary central Chi-squared distribution with $$k+2n$$ degrees of freedom.

The factor $$e^{-\frac{\lambda}{2}}\frac{{(\frac{\lambda}{2})}^n}{n!}$$ gives the probabilities of Poisson Distribution. So, the PDF of the non-central Chi-squared distribution can be termed as a weighted sum of Chi-squared probability with weights being equal to the probabilities of Poisson distribution.

## Method of Generating non-central Chi-squared random variable:

Parameters required: k – the degrees of freedom and $$\lambda$$ – non-centrality parameter.

• For a given degree of freedom (k), let the k normal random variables be $$X_1,X_2,…,X_k$$ with variances $${\sigma_1}^2 ,{\sigma_2}^2,…,{\sigma_k}^2 =1$$ and mean $$\mu_1,\mu_2,…\mu_k$$
• Now, our goal is to add squares of the k independent normal random variables with variances=1 and means satisfying the following criteria
• Put $$\mu_1=\sqrt{\lambda}$$ and $$\mu_2,…\mu_k = 0$$
• Generate k-1 standard normal random variables with $$\mu=0$$ and $${\sigma}^2 =1$$ and one normal random variable with $$\mu= \sqrt{\lambda}$$ and $${\sigma}^2 =1$$
• Squaring and summing-up all the k random variables give the non-central Chi-squared random variable
• The PDF can be plotted using histogram method

Non-central Chi-squared distribution is related to Rician Distribution and the central Chi-squared distribution is related to Rayleigh distribution.

## Matlab Code:

Check this book for full Matlab code.
Simulation of Digital Communication Systems Using Matlab – by Mathuranathan Viswanathan