Riemann surface
matlab

1.1.1 Exercise: Second moment from mean and variance
How are mean $m$, variance $v$ and 2nd moment $s$ related to each other? In other words, if mean and variance of a one-dimensional distribution were given. How could you compute the corresponding 2 nd moment?
Hint: Assume $x$ to be the data values and $\bar{x}$ their mean. Then play around with the corresponding expressions for mean $\bar{x}=\langle x\rangle$, variance $\left\langle(x-\bar{x})^2\right\rangle$ and second moment $\left\langle x^2\right\rangle$.

Solution: Let $x$ be the data values and $\bar{x}$ their mean. For the second moment we then get
\begin{aligned} s & =\left\langle x^2\right\rangle \ & =\left\langle((x-\bar{x})+\bar{x})^2\right\rangle \ & =\left\langle(x-\bar{x})^2+2(x-\bar{x}) \bar{x}+\bar{x}^2\right\rangle \ & =\left\langle(x-\bar{x})^2\right\rangle+\langle 2(x-\bar{x}) \bar{x}\rangle+\left\langle\bar{x}^2\right\rangle \ & =\left\langle(x-\bar{x})^2\right\rangle+2(\underbrace{\langle x\rangle}_{=\bar{x}}-\bar{x}) \bar{x}+\bar{x}^2 \ & =\left\langle(x-\bar{x})^2\right\rangle+\bar{x}^2 \ & =v+m^2 . \end{aligned}
Thus, the 2nd moment is the sum of the variance and the square of the mean.

1.1.2 Exercise: Second moment of a uniform distribution
Calculate the second moment of a uniform, i.e. flat, distribution in $[-1,+1]$. This is a distribution where every value between -1 and +1 is equally likely and other values are impossible.

Solution:
The second moment is
\begin{aligned} \left\langle x^2\right\rangle & =\int_{-1}^{+1}(1 / 2) x^2 \mathrm{~d} x \ & =(1 / 2)\left[(1 / 3) x^3\right]_{-1}^{+1} \ & =(1 / 2)(1 / 3+1 / 3) \ & =1 / 3 . \end{aligned}
This might be bit surprising, since one might think that such a distribution has a standard deviation of 0.5 and therefore a variance of $0.5^2=0.25$. However, due to the square in the second moment, larger values are weighted more than smaller values. Thus, the variance of this distribution is $1 / 3$ and its standard deviation $1 / \sqrt{3} \approx 0.577$

E-mail: help-assignment@gmail.com  微信:shuxuejun

help-assignment™是一个服务全球中国留学生的专业代写公司