Member-only story

Comparing the Tightness of Four Concentration Inequalities

Helene
8 min readJan 4, 2022

--

We have now been introduced to four different concentration inequalities: Markov’s Inequality, Chebyshev’s Inequality, Hoeffding’s Inequality, and Bernstein’s Inequality. In this article, we will revisit all of them and use Python code to compare all of them visually. So, let us get started!

Revisiting Random Variables

Before we dive into the different inequalities, let us first quickly re-hash what is meant by a random variable since they are the heart of all four inequalities. If you have already a good grasp of it, then simply skip this section. So, what exactly is a random variable? A random variable is simply defined as a set of possible values from a random experiment.

Now, this might not seem like a very clear definition, so let us take an intuitive example to illustrate. Imagine that we have a single coin, which we want to throw multiple times, for example, n times. Then we can denote the outcome with a random variable. One possible random variable could be the number of heads in n throws with the coin. It could also have been the number of tails; the idea is the same. Let us show it visually:

We can see that we have a coin, which we throw independently 10 times. We have then defined two random variables, X and Y, over the results. Here, Y…

--

--

No responses yet