My Math Forum Calulate expected value of X^2
 User Name Remember Me? Password

 Probability and Statistics Basic Probability and Statistics Math Forum

 February 19th, 2017, 09:52 AM #1 Senior Member   Joined: Feb 2015 From: london Posts: 121 Thanks: 0 Calulate expected value of X^2 $\displaystyle X = \frac{A_1 + A_2 + ... + A_n}{\sqrt{n}}$ where $\displaystyle A_1,A_2,..A_n$ are independent random variables satisfying $\displaystyle P(X_i =1) = p$ $\displaystyle P(X_i =-1) = 1-p$ $\displaystyle E[X^2] = \frac{1}{n} . E [(A_1 + A_2 +.. A_n) * (A_1 + A_2 + .. A_n )]$ $\displaystyle E[X^2] = \frac{1}{n} . \sum_{i=1}^{n} \sum_{j=1}^{n} E[A_i *A_j]$ $\displaystyle E[X^2] = \frac{1}{n} . n^2 . [2p^2 - 2(1-p)^2 ]$ $\displaystyle E[X^2] = n . [2p^2 - 2(1-p)^2 ]$ My calculation appears wrong because from the question, I know that $\displaystyle E[X] = (2p-1)\sqrt(n)$ $\displaystyle Var[X] = 4p (1-p )$ i.e you can calculate $\displaystyle E[X^2] = Var(X) - (E[X])^2$, however I am very puzzled as why my calculation doesnt work? Any help much appreciated.
 February 19th, 2017, 11:58 AM #2 Senior Member     Joined: Sep 2015 From: USA Posts: 1,977 Thanks: 1026 going from line 5 to line 6 is wrong. Most of those terms are 0 because the $A_i$'s are independent. A much easier way of going about this is noting that variances of independent random variables add, and that standard deviations scale. $E[A_i] = p - (1-p)=2p-1$ $E[A_i^2] = p + (1-p) = 1$ $Var[A_i] = E[A_i^2] -\left(E[A_i]\right)^2 = 1 - (2p-1)^2 = 4p(1-p)$ $Var\left[\dfrac{A_i}{\sqrt{n}}\right] = \dfrac 1 n Var[A_i] = \dfrac{4p(1-p)}{n}$ $Var\left[\displaystyle{\sum_{i=1}^n}~\dfrac{A_i}{\sqrt{n}} \right] = n Var\left[\dfrac{A_i}{\sqrt{n}}\right] = 4p(1-p)$ $E\left[\displaystyle{\sum_{i=1}^n}~\dfrac{A_i}{\sqrt{n}} \right] = n \dfrac{E[A_i]}{\sqrt{n}} = \sqrt{n}(2p-1)$ $E\left[\left(\displaystyle{\sum_{i=1}^n}~\dfrac{A_i}{ \sqrt{n}}\right)^2\right] = 4p(1-p) + \left( \sqrt{n}(2p-1)\right)^2 = 4 n p^2-4 n p+n-4 p^2+4 p$
February 19th, 2017, 02:02 PM   #3
Global Moderator

Joined: May 2007

Posts: 6,527
Thanks: 588

Quote:
 going from line 5 to line 6 is wrong. Most of those terms are 0 because the Ai's are independent.
Terms are not 0, unless p=1/2.

 March 1st, 2017, 12:43 PM #4 Senior Member   Joined: Feb 2015 From: london Posts: 121 Thanks: 0 Sorry for the late reply. Thanks both for the answers. Romsek, your method certainly looks easier. I did actually manage to work out where I was going wrong for anyone interested: $\displaystyle E[X^2] = \frac{1}{n} [ \sum_{i=1}^{n} E[A_i^2] + \sum_{i != j}^{n^2} E[A_i] E[A_j] ]$

 Tags calulate, expected

 Thread Tools Display Modes Linear Mode

 Similar Threads Thread Thread Starter Forum Replies Last Post manich44 Algebra 10 February 10th, 2016 02:55 PM abalest14 Algebra 4 February 7th, 2016 07:10 PM statssav Probability and Statistics 5 June 11th, 2015 05:33 AM jbergin Advanced Statistics 0 December 30th, 2014 09:29 AM echoMan Algebra 3 October 22nd, 2014 11:25 PM

 Contact - Home - Forums - Cryptocurrency Forum - Top