I am not a mathematician, so I don't quite understand how comes that a variance of some discrete probability distribution could exceed the variance of the discrete uniform distribution. I thought that variance of any distribution will be capped by the variance of the flat distribution.

My case:
I have the following probability distribution for the discrete random variable on the [0,4] interval:

I compute the variance of this distribution using:
$$ \text{Var}(X) = \sum_{i=1}^n p_i\,\cdot\,(x_i - \mu)^2 $$ and I get 2.1275, while the variance for the discrete uniform distribution, according to this formula $$ \text{Var}(X) = \frac{n^2 - 1}{12}, \quad \text{where }n=b-a+1 $$ should be 2.0 on the same interval, i.e., for $b-a = 4$.

This bugs me a lot. Please tell me what I am missing. Thank you for your time.

  • 2
    $\begingroup$ Surely a symmetric U-shaped distribution (i.e. with more probability near the ends than the middle) will have a higher variance than the uniform (since more of the distribution is further from the mean). $\endgroup$
    – Glen_b
    Aug 19, 2021 at 9:43
  • $\begingroup$ @Glen_b Now that you've said that, it makes perfect sense to me that this could be the case. In physics we just don't encounter these scenarios and such possibility of having U-shaped distributions didn't even cross my mind. Thank you. $\endgroup$ Aug 19, 2021 at 9:54
  • $\begingroup$ You made an error. Most of your probability is concentrated on the values $0,1,$ and $2,$ which (intuitively) must make the standard deviation substantially less than $(2-0)/2 = 1.$ I compute the variance as $0.4475$ rather than $2.1275.$ $\endgroup$
    – whuber
    Aug 19, 2021 at 18:47
  • 1
    $\begingroup$ @whuber You are right, I pasted a wrong line from my data file which looked very similar to the other line for which I obtain 2.1275 for the variance. I am very sorry, I fixed the question. Thank you for pointing this out. $\endgroup$ Aug 20, 2021 at 7:35

1 Answer 1


Popoviciu's inequality states that the sharp upper bound on the variance $\sigma^2$ of any bounded probability distribution with support on $[a, b]$ is: $$ \sigma^2\leq \frac{1}{4}(b - a)^2 $$ In your case, $a= 0, b = 4$ so we have $\sigma^2\leq 4$. This is achieved precisely when half of the probability is concentrated at each of the two bounds.

  • $\begingroup$ Wow. So the variance of any bounded probability distribution is not bounded by the variance of the flat distribution... Thanks. $\endgroup$ Aug 19, 2021 at 9:38

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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