Math Help - Find the Coefficient of Correlation. (Need help understanding the posted solution)

1. Find the Coefficient of Correlation. (Need help understanding the posted solution)

$\\\text{Given }n\text{ random variables }X_1,X_2,...,X_n\text{ each having the same variance of }\sigma^2\text{, and defining}\\\\U=2X_1+X_2+...+X_{n-1}\text{ and }V=X_2+X_3+...+2X_n\text{, find the coefficient of correlation between U and V.}$

Solution:

$\\\rho_{UV}=\frac{Cov[U,V]}{\sigma_U\sigma_V}\text{; }\sigma^2_U=(4+1+1+1+...+1)\sigma^2=(n+2)\sigma^2= \sigma^2_V\text{.}\\\\\text{Since the X's are independent, if }i\neq j\text{ then }Cov[X_i,X_j]=0\text{. Then, noting that }\\\\Cov[W,W]=Var[W]\text{,}\\\\\text{we have }Cov[U,V]=Cov[2X_1,X_2]+Cov[2X_1,X_3]+...+Cov[X_{n-1},2X_n]=\\\\Var[X_2]+Var[X_3]+...+Var[X_{n-1}]=(n-2)\sigma^2\text{.}\\\\\text{Then, }\rho_{UV}=\frac{(n-2)\sigma^2}{(n+2)\sigma^2}=\frac{(n-2)}{(n+2)}$

I understand the first line. The rest is confusing. I don't understand how $Cov[U,V]$ is found. Any help would be appreciated. Thanks

Edit: I guess it helps to take the time to type everything out and look at it. I have an understanding of the solution now, but I wouldn't be able to come up with a solution on my own. I'd love any insights for this sort of problem. Thanks

2. Re: Find the Coefficient of Correlation. (Need help understanding the posted solution

Hey downthesun01.

The definition of covariance is Cov[X,Y] = E[XY] - E[X]E[Y].

If X and Y are independent then P(A and B) = P(A)P(B) and from that you can prove that E[XY] = E[X]E[Y] which would prove that Cov[X,Y] = 0 for this particular case of X and Y being independent.

The rest of the argument expands out Cov[U,V] in terms of the Xi terms and note that Cov[Xi,Xj] = 0 for i != j (which is what they used above for independent random variables) and when i = j then you calculate E[Xi^2] which can be calculated in the normal way if you know the probability density function.

Thats the basic idea behind the independence and the algebra that is used.