# Thread: Correlation between two chi-squared random variables

1. ## Correlation between two chi-squared random variables

Hi Folks!

Let X1 have a chi-squared distribution with 1 degree-of-freedom.
Let Xn have a chi-squared distribution with n degrees-of-freedom.

Next, consider

Z = X1+Xn

Then, assuming that X1 and Xn are independent, Z has a chi-squared distribution with n+1 degrees-of-freedom.

Are you able to provide any comments on how to obtain

correlation(X1,Z)?

Cheers!

Der

2. ## Re: Correlation between two chi-squared random variables

Hey DerWundermann.

You need to find the joint distribution of X1 and Z and then from that calculate Cov(X,Y) = E[XY] - E[X]E[Y]

Remember that P(A|B) = P(A and B)/P(B) and that P(A) = Integral/Sum_out P(A|B=b)*P(B=b) for all appropriate b.

4. ## Re: Correlation between two chi-squared random variables

am i being a bit dim here or can you just note that the conditional correlation Cor(Z,X1|Xn) is 1 for all possible values of Xn?

(i suspect im being a bit dim...so the question becomes, why not?)

5. ## Re: Correlation between two chi-squared random variables

My comments in post #4 are wrong, but i haven't figured out why yet.

an alternative method which i think is valid and does not require calculating the joint distribution is:

$Corr(X_1,X_1 + X_n) = \frac{Cov(X1,X_1 + X_n)}{\sqrt{Var(X_1)} \sqrt{Var(X_1 + X_n))}}$

$=\frac{Cov(X_1,X_1) + Cov(X_1,X_n)}{\sqrt{Var(X_1)}\sqrt{(Var(X_1) + Var(X_n))}}$

$=\frac{Var(X_1) + 0}{\sqrt{Var(X_1)}\sqrt{(Var(X_1) + Var(X_n))}}$

$=\sqrt{\frac{Var(X_1)}{Var(X_1) + Var(X_n)}$

$=\sqrt{\frac{2}{2 + 2n}$

$=\sqrt{\frac{1}{1 + n}$

Very clever!