# Given $m\in[0,1]$, can we find a dense subset of $[0,1]$ whose Lebesgue measure is exactly $m$?

Consider the collection of subsets $$A$$ of the unit interval $$[0,1]$$ which are dense, meaning that for every $$x\in[0,1]$$, for every $$\varepsilon>0$$, there exists $$a\in A$$ such that $$|x-a|<\varepsilon$$. What are the Lebesgue measures of these sets?

Clearly these sets are bounded above by the unit interval itself, which is dense and has Lebesgue measure $$1$$. On the other hand, the set $$\Bbb Q \cap [0,1]$$ is dense and has Lebesgue measure null.

My question is this: for any $$m\in[0,1]$$, does there exist a dense subset $$A\subseteq[0,1]$$ with Lebesgue measure $$m$$?

Edit: I found out that if $$A$$ has measure $$m$$ and satisfies $$|A\cap I|=m|I|$$ for every interval $$I\subseteq[0,1]$$ (a better, stronger condition) where $$|\cdot|$$ denotes Lebesgue measure, then the density at a point $$x\in A$$ is given by

$$d(x) = \lim_{\varepsilon\rightarrow0} \frac{|A\cap(x-\varepsilon,x+\varepsilon)|}{|(x-\varepsilon,x+\varepsilon)|} = \begin{cases} |A|/2 & \text{if } x=0\text{ or }1 \\ |A| & \text{if }x\in(0,1) \end{cases}$$

Lebesgue's density theorem says that if $$A$$ is measurable then $$d(x)=1$$ for almost all $$x\in A$$, and since we established $$d(x)=|A|$$ for $$x\in(0,1)$$, which is almost all of $$[0,1]$$, this implies $$|A|=1$$.

The answer is yes. For $$m\in [0,1]$$ consider the set $$A:=[0,m]\cup(\mathbb{Q}\cap [0,1])$$. This is clearly dense and has measure $$m$$.

• Great! However, this set is quite "lop-sided". I am wondering if there is a more evenly distributed example. – M. Nestor Aug 9 '19 at 4:59
• Then I refer to the answer of saz. Take an evenly distributed set of Lebesgue measure $m$ and "add" $\mathbb{Q}\cap [0,1]$. – Jonas Lenz Aug 9 '19 at 5:07
• @M.Nestor Depends on what you mean by evenly distributed. It would be cool if, given a constant $0 < c < 1$, it were possible to find a measurable set $A$ such that $m(A \cap I) = c m(I)$ for every interval $I \subseteq [0,1]$. This turns out to be impossible – Bungo Aug 9 '19 at 5:16
• @Bungo After reading that post, it seems that what I am after is precisely Lebesgue's density theorem. Thanks! – M. Nestor Aug 9 '19 at 5:17

Well, yes. Just take any set $$B$$ of Lebesgue measure $$m$$ (e.g. $$B=[0,m]$$) and consider

$$A := B \cup (\mathbb{Q} \cap [0,1]).$$

The set has Lebesgue measure $$m$$ and it is dense in $$[0,1]$$.

It's a bit more tricky to construct an open dense set $$A$$ with small Lebesgue measure $$m$$. Here, one approach is to consider an enumeration $$(q_n)_{n \in \mathbb{N}}$$ of $$\mathbb{Q} \cap [0,1]$$ and $$A := \bigcup_{n \in \mathbb{N}} (q_n-\epsilon 2^{-n},q_n+\epsilon 2^{-n})$$ for fixed $$\epsilon>0$$. The set $$A$$ is open and has Lebesgue measure $$\leq \epsilon$$.

Remark: Note that there does not exist an open dense set with Lebesgue measure zero. In this sense, the best we can achieve is to have an open dense set of arbitrarily small Lebesgue measure, as above.

• For the 2nd example, the set must be less than $\epsilon$ since there are some overlaps between those intervals, right? – efhvcjnfdbgefg Aug 9 '19 at 5:14
• @efhvcjnfdbgefg Yes, that's correct. There are plenty of overlaps (... exactly because the rationals are dense). – saz Aug 9 '19 at 5:15
• In fact $\varepsilon$ must always be an overestimate, since any interval $(q_n-2^{-n}\varepsilon,q_n+2^{-n}\varepsilon)$ must contain another $q_m$, guaranteeing overlap at least $\min\{\varepsilon2^{-m},\varepsilon2^{-n}\}$. – M. Nestor Aug 9 '19 at 5:23
• My above comment doesn't change the validity, since the overestimate varies continuously, you can always find $\varepsilon$ such that the true measure is precisely $m$. – M. Nestor Aug 13 '19 at 17:47

Sure. Take $$[0,m]\cup(\mathbb{Q}\cap [0,1])=[0,m]\overset{\cdot}{\cup}(\mathbb{Q}\cap(m,1]).$$