Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

The density of a continuous random variable $X$ is

$$f_X(x) = \begin{cases}\frac{p+1}{2}|x|^p&\mathrm{\ if\ } |x|\le1\\ 0&\mathrm{\ otherwise }\end{cases}$$

Here $p$ is a parameter taking values between $-0.5$ and $0.5$. How do I find the values of $p$ that maximize and minimize $Var(X)$?

share|cite|improve this question
up vote 3 down vote accepted

Doing it from first principles, you have

$$\mathrm{Var}(X)=\mathrm{E}\left[\left(X-\mathrm{E}(X)\right)^2\right]=\int_{-\infty}^\infty(x-\mu)^2f_X(x)~dx\;,$$ where $$\mu=\int_{-\infty}^\infty xf_X(x)~dx\;.$$

The function $f_X(x)$ is even (i.e., symmetric about the $y$-axis), so

$$\begin{align*} \int_{-\infty}^0 xf_X(x)~dx&=\int_\infty^0(-x)f_X(-x)~d(-x)\\ &=\int_0^\infty(-x)f_X(x)~dx\\ &=-\int_0^\infty xf_X(x)~dx\;, \end{align*}$$

and therefore $$\mu=\int_{-\infty}^0 xf_X(x)~dx+\int_0^\infty xf_X(x)~dx=0\;.$$ Thus,

$$\begin{align*} \mathrm{Var}(X)&=\int_{-1}^1x^2\left(\frac{p+1}2\right)|x|^p~dx\\ &=\frac{p+1}2\int_{-1}^1 x^2|x|^p~dx\\ &=(p+1)\int_0^1 x^{p+2}~dx\\ &=\frac{p+1}{p+3}\;. \end{align*}$$

Now it’s just a first-semester calculus problem in maximizing and minimizing the function $$v(p)=\frac{p+1}{p+3}=1-\frac2{p+3}$$ over the interval $\left[-\frac12,\frac12\right]$. This is easy: $$v'(p)=\frac2{(p+3)^2}>0$$ over the entire interval, so the variance is increasing over the entire interval. Thus, it must have its minimum value at $p=-\frac12$ and its maximum at $p=\frac12$. (Actually, you shouldn’t even need any calculus to see that $v(p)$ is increasing.)

share|cite|improve this answer
Shouldn't it be $\int_{-\infty}^{\infty}(x−μ)^2fX(x) dx$ and not $\int_{-\infty}^{\infty}(x−μ)fX(x) dx$? – idealistikz Oct 1 '12 at 3:42
@idealistikz: It should indeed; thanks. – Brian M. Scott Oct 1 '12 at 5:19

Given that $|x|^p$ has even symmetry, we conclude that $\mathbb{E} (X) = 0$. Therefore, the variance is

$$\text{Var} (X) = \mathbb{E} (X^2) = \displaystyle\int_{-1}^1 x^2 f_X (x) dx = \displaystyle\int_{-1}^1 x^2 \left(\frac{p+1}{2}\right) |x|^p dx = \left(\frac{p+1}{2}\right) \displaystyle\int_{-1}^1 x^2 |x|^p dx$$

and, since the integrand has even symmetry, we obtain

$$\text{Var} (X) = (p+1) \displaystyle\int_{0}^1 x^{p+2} dx = \left(\frac{p+1}{p+3}\right)$$

Assuming that this is correct, then plot the graph of $f (p) := \frac{p+1}{p+3}$ to optimize the variance.

share|cite|improve this answer
Plotting the graph is both unnecessary and an uncertain method. – Brian M. Scott Sep 30 '12 at 8:59
@BrianM.Scott: True. But I am lazy and felt like shortening the post. – Rod Carvalho Sep 30 '12 at 9:03
As Brian says: $\dfrac{p+1}{p+3} = 1-\frac{2}{p+3}$ which makes it easy and short – Henry Sep 30 '12 at 15:48
@Henry: Leaving the "easy and short" work to the OP is even easier and shorter. Unless I am paid by the word, which I am not, I will take the liberty of leaving some work to the OP. – Rod Carvalho Sep 30 '12 at 17:21

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.