text: # Related to Gamma distribution and chi square distribution
  
  I have $2N$ independent normal random variables $X_1,X_2\cdots X_{2N}$ where every variable has mean zero and variance $\frac{1}{2}$. I want to find the cumulative distribution function of $T=X_1^2+X_2^2+\cdots X_{2N}^2$. I know that I can make $N$ exponential random variables (where every exponential random variable will have mean $1$) and the sum of these $N$ exponential random variables will follow a gamma distribution. Therefore the CDF will be $$\text{cdf of T}=\frac{\gamma(N,x)}{\Gamma(N)}$$. However, if I try to find it through chi square distribution then my answer does not matches with the above one. Here is my attempt with chi square distribution
  
  My attempt with chi square distribution:
  
  We know that $T=\left(\frac{1}{2}\right)\left[2\times X_1^2+2\times X_2^2+\cdots 2\times X_{2N}^2\right]$. Now every $2\times X_i^2$ is a standard normal random variable. Therefore the probability density function of $T$ will be (according to https://stats.stackexchange.com/questions/118676/relationship-between-gamma-and-chi-squared-distribution) $$\text{pdf of T}=\frac{1}{\sigma^2}\times f_{\chi^2}(\frac{x}{\sigma^2},2N)=2\times \frac{1}{2^N\Gamma(N)} x^{n-1}e^{-x}$$ and corresponding to this the CDF of $T$ is $$F_T(c)=\int_0^{\infty}\text{pdf of T }dx=\frac{1}{2^{N-1}\Gamma(N)}\gamma(N,c)$$ which is not exactly same as my very first equation above. Please guide where I am doing it wrong.
  
  The $\chi^2$ distribution with $2N$ degrees of freedom is the distribution of the sum of squares of $2N$ standard normal random variables. Let $F_{2N}(x)$ be the cdf of that. In your case, the normal random variables $X_j$ have variance $1/2$ rather than $1$, so $X_j = Y_j/\sqrt{2}$ where $Y_j$ is a standard normal random variable, and $T = \sum_{j} X_j^2 = (1/2) \sum_j Y_j^2$. Thus the CDF for $T$ is
  
  $$F_T(x) = P(T \le x) = P(2T \le 2x) = F_{2N}(2x)$$
  
  • Thanks alot for your answer. Can you point the error in my attempt. I will be very thankful to you. Commented Aug 30, 2016 at 2:26
explanation: The document discusses the cumulative distribution function (CDF) of a sum of squared normal random variables and compares two methods to derive it: using the gamma distribution and using the chi-square distribution. The document contains a question about why the results from these two methods do not match and requests guidance on where the error might be.
distilabel_metadata.content: Evaluate the user given text extract and determine if it contains a math question and optionally and answer to this question.
  
  Output rules:
  
  1. Briefly describe the document and mention if it contains a question or a question and answer.
  2. Finalize the output with: Label: no-question,question,question-and-answer,multiple-question,multiple-question-and-answer
distilabel_metadata.role: system
distilabel_metadata.content: # Related to Gamma distribution and chi square distribution
  
  I have $2N$ independent normal random variables $X_1,X_2\cdots X_{2N}$ where every variable has mean zero and variance $\frac{1}{2}$. I want to find the cumulative distribution function of $T=X_1^2+X_2^2+\cdots X_{2N}^2$. I know that I can make $N$ exponential random variables (where every exponential random variable will have mean $1$) and the sum of these $N$ exponential random variables will follow a gamma distribution. Therefore the CDF will be $$\text{cdf of T}=\frac{\gamma(N,x)}{\Gamma(N)}$$. However, if I try to find it through chi square distribution then my answer does not matches with the above one. Here is my attempt with chi square distribution
  
  My attempt with chi square distribution:
  
  We know that $T=\left(\frac{1}{2}\right)\left[2\times X_1^2+2\times X_2^2+\cdots 2\times X_{2N}^2\right]$. Now every $2\times X_i^2$ is a standard normal random variable. Therefore the probability density function of $T$ will be (according to https://stats.stackexchange.com/questions/118676/relationship-between-gamma-and-chi-squared-distribution) $$\text{pdf of T}=\frac{1}{\sigma^2}\times f_{\chi^2}(\frac{x}{\sigma^2},2N)=2\times \frac{1}{2^N\Gamma(N)} x^{n-1}e^{-x}$$ and corresponding to this the CDF of $T$ is $$F_T(c)=\int_0^{\infty}\text{pdf of T }dx=\frac{1}{2^{N-1}\Gamma(N)}\gamma(N,c)$$ which is not exactly same as my very first equation above. Please guide where I am doing it wrong.
  
  The $\chi^2$ distribution with $2N$ degrees of freedom is the distribution of the sum of squares of $2N$ standard normal random variables. Let $F_{2N}(x)$ be the cdf of that. In your case, the normal random variables $X_j$ have variance $1/2$ rather than $1$, so $X_j = Y_j/\sqrt{2}$ where $Y_j$ is a standard normal random variable, and $T = \sum_{j} X_j^2 = (1/2) \sum_j Y_j^2$. Thus the CDF for $T$ is
  
  $$F_T(x) = P(T \le x) = P(2T \le 2x) = F_{2N}(2x)$$
  
  • Thanks alot for your answer. Can you point the error in my attempt. I will be very thankful to you. Commented Aug 30, 2016 at 2:26
distilabel_metadata.role: user
distilabel_metadata.raw_output_q_a_detector_0: The document discusses the cumulative distribution function (CDF) of a sum of squared normal random variables and compares two methods to derive it: using the gamma distribution and using the chi-square distribution. The document contains a question about why the results from these two methods do not match and requests guidance on where the error might be.
  
  Label: question-and-answer