Tutorials › Real Analysis › Nowhere Dense Sets

Topology of the Real Line · Tutorial 267 of 1000

Nowhere Dense Sets

Learn to recognize nowhere dense sets, use an interval test for them, and understand why finite unions behave differently from countable unions.

Intermediate 9 min read

What You'll Learn

  • Define a nowhere dense subset of the real line using the interior of its closure
  • Apply the interval characterization to test whether a set is nowhere dense
  • Distinguish a nowhere dense set from a set that is merely not dense
  • Verify examples involving integers and a convergent sequence
  • Prove that finite unions of nowhere dense sets are nowhere dense
  • Explain why a countable union of nowhere dense sets need not be nowhere dense

When a Set Fails to Fill Any Interval

Perfect sets are closed and have no isolated points: every point in the set is approached by other points of the set. Nowhere dense sets describe a different kind of local behavior. Rather than asking whether each point can be approached by other set points, we ask whether the set, even after its limit points are added, contains any open interval.

The closure matters because a set can omit limit points and still be crowded throughout an interval. The rationals, for instance, are not a counterexample to density just because they do not contain every real number: their closure is the whole real line. To test whether a set is nowhere dense, take its closure first, then check whether that closure has any interior.

Definition: A set \(E\subseteq\mathbb{R}\) is nowhere dense if \(\operatorname{int}(\overline{E})=\varnothing\). Equivalently, the closure of \(E\) contains no nonempty open interval.

This definition does not require \(E\) to be closed. If \(E\) is closed, then \(\overline{E}=E\), so the condition reduces to \(\operatorname{int}(E)=\varnothing\). But for a set that is not closed, checking only its interior can give the wrong answer: it is the interior of the closure that must be empty.

An Interval Test

The definition has a useful local formulation. A set is nowhere dense precisely when, inside every nonempty open interval, we can find a smaller nonempty open interval that misses the set entirely. This is stronger than saying that an interval is not contained in the set: it says that a whole subinterval can be avoided.

Theorem (Interval Characterization of Nowhere Dense Sets): For \(E\subseteq\mathbb{R}\), the following are equivalent:
  • \(E\) is nowhere dense.
  • Every nonempty open interval \(I\) contains a nonempty open interval \(J\) such that \(J\cap E=\varnothing\).

Proof. Suppose first that \(E\) is nowhere dense, and let \(I\) be a nonempty open interval. Since \(\operatorname{int}(\overline{E})=\varnothing\), the interval \(I\) cannot be contained in \(\overline{E}\). Choose \(y\in I\setminus\overline{E}\). The complement of the closed set \(\overline{E}\) is open, so there is an \(r_1>0\) such that \(B_{r_1}(y)\cap\overline{E}=\varnothing\). Since \(I\) is open and \(y\in I\), there is also an \(r_2>0\) such that \(B_{r_2}(y)\subseteq I\). Set \(r=\min\{r_1,r_2\}\). Then \(J=B_r(y)\) is a nonempty open interval contained in \(I\), and it is disjoint from \(\overline{E}\), hence also from \(E\).

Conversely, suppose every nonempty open interval contains a nonempty open subinterval disjoint from \(E\). If \(\operatorname{int}(\overline{E})\ne\varnothing\), there is a nonempty open interval \(I\subseteq\overline{E}\). By the assumed property, \(I\) contains a nonempty open interval \(J\) with \(J\cap E=\varnothing\). Because \(J\) is open, each of its points has a neighborhood contained in \(J\), and that neighborhood misses \(E\). No point of \(J\) can therefore belong to \(\overline{E}\). This contradicts \(J\subseteq I\subseteq\overline{E}\). Thus \(\operatorname{int}(\overline{E})=\varnothing\), and \(E\) is nowhere dense. \(\square\)

The direction of the interval test is worth noticing. It does not claim that every interval is disjoint from \(E\), or even that it is disjoint from \(E\) after removing a few points. It guarantees a smaller open interval free of \(E\), however small that interval may need to be.

Worked Example: The Integers Are Nowhere Dense

Let \(E=\mathbb{Z}\). The integers are locally finite: every bounded interval contains only finitely many integers. By the Locally Finite Sets Are Closed theorem, \(\mathbb{Z}\) is closed, so \(\overline{\mathbb{Z}}=\mathbb{Z}\). It remains to check that its interior is empty.

Every nonempty open interval contains an irrational number, by the Density of the Irrationals theorem. An irrational number is not an integer, so no nonempty open interval can be contained in \(\mathbb{Z}\). Therefore \(\operatorname{int}(\mathbb{Z})=\varnothing\), and \(\mathbb{Z}\) is nowhere dense.

The interval characterization gives a direct version of the same conclusion: within any open interval, choose an irrational point. Since \(\mathbb{Z}\) is closed and the chosen point is not an integer, a sufficiently small open interval around it misses \(\mathbb{Z}\).

A Set and Its Closure Can Both Be Nowhere Dense

A convergent sequence provides an example in which the set is not closed, but its closure still has empty interior. The accumulation point must be included in the closure calculation; omitting it would leave the main topological feature unexplained.

Worked Example: A Convergent Sequence Is Nowhere Dense

Let \(E=\{1/n:n\geq1\}\). The point \(0\) is an accumulation point of \(E\), because the distinct points \(1/n\) approach \(0\). There are no other accumulation points. To see this, fix \(x\ne0\). If \(x<0\), a sufficiently small ball around \(x\) contains no positive terms of the sequence. If \(x>0\), choose \(N\) so large that \(1/n<x/2\) for every \(n\geq N\). The tail of the sequence then stays at least \(x/2\) away from \(x\). The remaining points \(1,1/2,\ldots,1/(N-1)\) form a finite set, so a sufficiently small ball around \(x\) avoids each of them unless \(x\) is one of those terms. In that case, the ball can be chosen to contain that term and no other term. Thus no \(x\ne0\) is an accumulation point.

Consequently \(E'=\{0\}\). By the Closure as the Union of a Set and Its Derived Set theorem, $$ \overline{E}=E\cup E'=\{0\}\cup\{1/n:n\geq1\}. $$ Every point of \(\overline{E}\) is rational. Since the irrationals are dense in \(\mathbb{R}\), every nonempty open interval contains a point outside \(\overline{E}\); hence \(\overline{E}\) contains no nonempty open interval. It follows that \(\operatorname{int}(\overline{E})=\varnothing\), so \(E\) is nowhere dense. Notice that \(E\) itself omits its limit point \(0\), but this does not prevent it from being nowhere dense.

Finite Unions Preserve Nowhere Denseness

Combining a finite number of nowhere dense sets does not suddenly produce a set whose closure contains an interval. One way to understand this is to use the interval characterization repeatedly: first find a subinterval avoiding the first set, then a smaller one avoiding the second, and continue. The finiteness of the list ensures this process ends with a nonempty interval.

Theorem (Finite Unions of Nowhere Dense Sets): If \(E_1,\ldots,E_m\subseteq\mathbb{R}\) are nowhere dense and \(m\) is a positive integer, then \(\bigcup_{j=1}^{m}E_j\) is nowhere dense.

Proof. Let \(I\) be any nonempty open interval. The Interval Characterization of Nowhere Dense Sets gives a nonempty open interval \(I_1\subseteq I\) disjoint from \(E_1\). Applying the same characterization to \(E_2\) inside \(I_1\), choose a nonempty open interval \(I_2\subseteq I_1\) disjoint from \(E_2\). Continue in this way: at each step \(j\), choose a nonempty open interval \(I_j\subseteq I_{j-1}\) such that \(I_j\cap E_j=\varnothing\), where \(I_0=I\). This is possible because \(I_{j-1}\) is a nonempty open interval and \(E_j\) is nowhere dense.

The final interval \(I_m\) is nonempty and is contained in \(I\). Since \(I_m\subseteq I_j\) for every \(j\), it misses every \(E_j\), and therefore $$ I_m\cap\left(\bigcup_{j=1}^{m}E_j\right)=\varnothing. $$ Every nonempty open interval \(I\) thus contains a nonempty open subinterval disjoint from the finite union. The interval characterization shows that the union is nowhere dense. \(\square\)

A related simple fact is that every subset of a nowhere dense set is nowhere dense. If \(A\subseteq E\), then monotonicity of closure gives \(\overline{A}\subseteq\overline{E}\). Hence \(\operatorname{int}(\overline{A})\subseteq\operatorname{int}(\overline{E})=\varnothing\). This is often useful when a set can be placed inside a larger set whose closure is already understood.

Worked Example: A Finite Union of Discrete Sets

Consider \(A=2\mathbb{Z}\) and \(B=2\mathbb{Z}+1\), the even and odd integers. Each is locally finite, hence closed by the Locally Finite Sets Are Closed theorem. Each has empty interior: every nonempty open interval contains an irrational, which belongs to neither set. Thus both \(A\) and \(B\) are nowhere dense. The finite-union theorem implies that \(A\cup B\) is nowhere dense.

In this instance \(A\cup B=\mathbb{Z}\), so the conclusion agrees with the direct verification in the earlier example. The point of the theorem is that one need not separately compute the closure and interior of every finite union: the interval-avoidance argument handles the union at once.

Why Countable Unions Are Different

The finite-union theorem should not be extended to countably many sets without additional hypotheses. The rationals are a countable union of nowhere dense sets, yet they are dense in the real line and therefore are not nowhere dense themselves. Indeed, \(\mathbb{Q}\) is countable, so it can be listed as \(\{q_1,q_2,\ldots\}\). Each singleton \(\{q_n\}\) is closed and has empty interior, hence is nowhere dense. But $$ \mathbb{Q}=\bigcup_{n=1}^{\infty}\{q_n\}, $$ and the Density of the Rationals theorem gives \(\overline{\mathbb{Q}}=\mathbb{R}\). Thus \(\operatorname{int}(\overline{\mathbb{Q}})=\mathbb{R}\), not the empty set.

This example also separates two statements that may sound similar. A set can be nowhere dense even when it is infinite, as the integer set and the convergent sequence show. On the other hand, being countable does not guarantee nowhere denseness: the rationals are countable and dense. The definition concerns the interior of the closure, not the number of points in the set.

When testing a candidate, first identify its closure; for a nonclosed set, do not replace this step with a check of its own interior. Then ask whether any nonempty open interval lies inside that closure. Alternatively, use the interval characterization and try to find a smaller open interval avoiding the set in every interval you are given. These tests focus attention on the feature that matters: nowhere dense sets may occur throughout the line, but their closure never fills an interval.

Check Your Understanding

Use the definition, interval characterization, and examples to answer the following questions.

  1. Why is nowhere denseness defined using \(\operatorname{int}(\overline{E})\), rather than just \(\operatorname{int}(E)\)?
  2. In the interval characterization, why does an open interval disjoint from \(E\) also contain no point of \(\overline{E}\)?
  3. What is the closure of \(\{1/n:n\geq1\}\), and which point is its only accumulation point?
  4. How does repeatedly choosing a smaller interval prove that a finite union of nowhere dense sets is nowhere dense?
  5. Why does the representation of \(\mathbb{Q}\) as a countable union of singleton sets not contradict the finite-union theorem?