Centre and spread from a density
A continuous density gives the mean through a value-weighted integral. The second moment then gives variance, and the square root of variance gives standard deviation
- Weight values by the density Multiply each value by its density before integrating over the support \(\displaystyle E(X)=\int_a^b xf(x)\,dx\)
- Find the second moment separately Use squared values to calculate the second moment before finding variance \(\displaystyle E(X^2)=\int_a^b x^2f(x)\,dx\)
- Subtract the squared mean Variance is the second moment minus the square of the mean \(\displaystyle \operatorname{Var}(X)=E(X^2)-[E(X)]^2\)
- Take the principal square root Standard deviation is the non-negative square root of variance \(\displaystyle \operatorname{SD}(X)=\sqrt{\operatorname{Var}(X)}\)
Worked example
A continuous random variable has the density shown below and is zero elsewhere. Find its mean and variance
- \(\displaystyle E(X)=\int_0^3x\left(\frac{2x}{9}\right)\,dx=\frac{2}{9}\int_0^3x^2\,dx\)Use x times the density to form the expected-value integral
- \(\displaystyle E(X)=\frac{2}{9}\left[\frac{x^3}{3}\right]_0^3=\frac{2}{9}(9-0)=2\)Evaluate the integral over the complete support to obtain the mean
- \(\displaystyle E(X^2)=\int_0^3x^2\left(\frac{2x}{9}\right)\,dx=\frac{2}{9}\left[\frac{x^4}{4}\right]_0^3=\frac{2}{9}\left(\frac{81}{4}-0\right)=\frac{9}{2}\)Use x squared times the density to obtain the second moment
- \(\displaystyle \operatorname{Var}(X)=\frac{9}{2}-2^2=\frac{1}{2}\)Subtract the squared mean from the second moment
Common mistakes
Difficulty levels
Questions about this topic
Why is the mean not necessarily the value with the greatest density?+
The mean is a weighted average of all values in the support. The highest density identifies where values are most concentrated, not the average value
What is the difference between variance and standard deviation?+
Variance is the average squared distance from the mean. Standard deviation is the principal square root of variance and has the same units as X.
Why is the second moment calculated separately?+
Variance uses the second moment and the square of the mean, which are generally different. Calculate the second moment with its own integral
Can I use a calculator?+
A calculator is allowed unless a question is marked no calculator
Which year level and chapter is this?+
Year 12, VCE Units 3 & 4, Mathematical Methods, chapter 12: Continuous probability distributions