Properties of subsets of topological spaces #
THIS FILE IS SYNCHRONIZED WITH MATHLIB4. Any changes to this file require a corresponding PR to mathlib4.
In this file we define various properties of subsets of a topological space, and some classes on topological spaces.
Main definitions #
We define the following properties for sets in a topological space:
is_compact
: each open cover has a finite subcover. This is defined in mathlib using filters. The main property of a compact set isis_compact.elim_finite_subcover
.is_clopen
: a set that is both open and closed.is_irreducible
: a nonempty set that has contains no non-trivial pair of disjoint opens. See also the section below in the module doc.
For each of these definitions (except for is_clopen
), we also have a class stating that the whole
space satisfies that property:
compact_space
, irreducible_space
Furthermore, we have three more classes:
locally_compact_space
: for every pointx
, every open neighborhood ofx
contains a compact neighborhood ofx
. The definition is formulated in terms of the neighborhood filter.sigma_compact_space
: a space that is the union of a countably many compact subspaces;noncompact_space
: a space that is not a compact space.
On the definition of irreducible and connected sets/spaces #
In informal mathematics, irreducible spaces are assumed to be nonempty.
We formalise the predicate without that assumption as is_preirreducible
.
In other words, the only difference is whether the empty space counts as irreducible.
There are good reasons to consider the empty space to be “too simple to be simple”
See also https://ncatlab.org/nlab/show/too+simple+to+be+simple,
and in particular
https://ncatlab.org/nlab/show/too+simple+to+be+simple#relationship_to_biased_definitions.
A set s
is compact if for every nontrivial filter f
that contains s
,
there exists a ∈ s
such that every set of f
meets every neighborhood of a
.
Equations
- is_compact s = ∀ ⦃f : filter α⦄ [_inst_3 : f.ne_bot], f ≤ filter.principal s → (∃ (a : α) (H : a ∈ s), cluster_pt a f)
Instances for is_compact
The complement to a compact set belongs to a filter f
if each a ∈ s
has a neighborhood t
within s
such that tᶜ
belongs to f
.
If p : set α → Prop
is stable under restriction and union, and each point x
of a compact set s
has a neighborhood t
within s
such that p t
, then p s
holds.
The intersection of a compact set and a closed set is a compact set.
The intersection of a closed set and a compact set is a compact set.
The set difference of a compact set and an open set is a compact set.
A closed subset of a compact set is a compact set.
Alias of the forward direction of is_compact_iff_ultrafilter_le_nhds
.
For every open directed cover of a compact set, there exists a single element of the cover which itself includes the set.
For every open cover of a compact set, there exists a finite subcover.
The neighborhood filter of a compact set is disjoint with a filter l
if and only if the
neighborhood filter of each point of this set is disjoint with l
.
A filter l
is disjoint with the neighborhood filter of a compact set if and only if it is
disjoint with the neighborhood filter of each point of this set.
For every directed family of closed sets whose intersection avoids a compact set, there exists a single element of the family which itself avoids this compact set.
For every family of closed sets whose intersection avoids a compact set, there exists a finite subfamily whose intersection avoids this compact set.
If s
is a compact set in a topological space α
and f : ι → set α
is a locally finite
family of sets, then f i ∩ s
is nonempty only for a finitely many i
.
To show that a compact set intersects the intersection of a family of closed sets, it is sufficient to show that it intersects every finite subfamily.
Cantor's intersection theorem: the intersection of a directed family of nonempty compact closed sets is nonempty.
Cantor's intersection theorem for sequences indexed by ℕ
:
the intersection of a decreasing sequence of nonempty compact closed sets is nonempty.
For every open cover of a compact set, there exists a finite subcover.
A set s
is compact if for every family of closed sets whose intersection avoids s
,
there exists a finite subfamily whose intersection avoids s
.
A set s
is compact if for every open cover of s
, there exists a finite subcover.
A set s
is compact if and only if
for every open cover of s
, there exists a finite subcover.
A set s
is compact if and only if
for every family of closed sets whose intersection avoids s
,
there exists a finite subfamily whose intersection avoids s
.
To show that ∀ y ∈ K, P x y
holds for x
close enough to x₀
when K
is compact,
it is sufficient to show that for all y₀ ∈ K
there P x y
holds for (x, y)
close enough
to (x₀, y₀)
.
If V : ι → set α
is a decreasing family of closed compact sets then any neighborhood of
⋂ i, V i
contains some V i
. We assume each V i
is compact and closed because α
is
not assumed to be Hausdorff. See exists_subset_nhd_of_compact
for version assuming this.
If α
has a basis consisting of compact opens, then an open set in α
is compact open iff
it is a finite union of some elements in the basis
filter.cocompact
is the filter generated by complements to compact sets.
Equations
- filter.cocompact α = ⨅ (s : set α) (hs : is_compact s), filter.principal sᶜ
Instances for filter.cocompact
filter.coclosed_compact
is the filter generated by complements to closed compact sets.
In a Hausdorff space, this is the same as filter.cocompact
.
Equations
- filter.coclosed_compact α = ⨅ (s : set α) (h₁ : is_closed s) (h₂ : is_compact s), filter.principal sᶜ
Instances for filter.coclosed_compact
Sets that are contained in a compact set form a bornology. Its cobounded
filter is
filter.cocompact
. See also bornology.relatively_compact
the bornology of sets with compact
closure.
Equations
- bornology.in_compact α = {cobounded := filter.cocompact α _inst_1, le_cofinite := _}
nhds_contain_boxes s t
means that any open neighborhood of s × t
in α × β
includes
a product of an open neighborhood of s
by an open neighborhood of t
.
If s
and t
are compact sets and n
is an open neighborhood of s × t
, then there exist
open neighborhoods u ⊇ s
and v ⊇ t
such that u × v ⊆ n
.
- is_compact_univ : is_compact set.univ
Type class for compact spaces. Separation is sometimes included in the definition, especially in the French literature, but we do not include it here.
Instances of this typeclass
- subsingleton.compact_space
- finite.compact_space
- compact_space_of_complete_linear_order
- topological_space.noetherian_space.compact_space
- prod.compact_space
- sum.compact_space
- sigma.compact_space
- pi.compact_space
- function.compact_space
- quot.compact_space
- quotient.compact_space
- compact_space_Icc
- metric.sphere.compact_space
- topological_space.compacts.compact_space
- topological_space.nonempty_compacts.to_compact_space
- add_circle.compact_space
- unit_add_circle.compact_space
- circle.compact_space
- ultrafilter_compact
- stone_cech.compact_space
- alexandroff.compact_space
- emetric.closeds.compact_space
- emetric.nonempty_compacts.compact_space
- Gromov_Hausdorff.compact_space_optimal_GH_coupling
- Gromov_Hausdorff.rep_GH_space_compact_space
- CompHaus.compact_space
- Compactum.compact_space
- weak_dual.character_space.compact_space
- prime_spectrum.compact_space
- algebraic_geometry.Scheme.quasi_compact_of_affine
- noncompact_univ : ¬is_compact set.univ
α
is a noncompact topological space if it not a compact space.
A compact discrete space is finite.
If α
is a compact space, then a locally finite family of sets of α
can have only finitely
many nonempty elements.
If α
is a compact space, then a locally finite family of nonempty sets of α
can have only
finitely many elements, set.finite
version.
If α
is a compact space, then a locally finite family of nonempty sets of α
can have only
finitely many elements, fintype
version.
Equations
The comap of the cocompact filter on β
by a continuous function f : α → β
is less than or
equal to the cocompact filter on α
.
This is a reformulation of the fact that images of compact sets are compact.
If X is is_compact then pr₂ : X × Y → Y is a closed map
If f : α → β
is an inducing
map, then the image f '' s
of a set s
is compact if and only
if the set s
is closed.
If f : α → β
is an embedding
(or more generally, an inducing
map, see
inducing.is_compact_iff
), then the image f '' s
of a set s
is compact if and only if the set
s
is closed.
The preimage of a compact set under a closed embedding is a compact set.
A closed embedding is proper, ie, inverse images of compact sets are contained in compacts.
Moreover, the preimage of a compact set is compact, see closed_embedding.is_compact_preimage
.
Finite topological spaces are compact.
The product of two compact spaces is compact.
The disjoint union of two compact spaces is compact.
The coproduct of the cocompact filters on two topological spaces is the cocompact filter on their product.
Tychonoff's theorem: product of compact sets is compact.
Tychonoff's theorem formulated using set.pi
: product of compact sets is compact.
Tychonoff's theorem formulated in terms of filters: filter.cocompact
on an indexed product
type Π d, κ d
the filter.Coprod
of filters filter.cocompact
on κ d
.
- local_compact_nhds : ∀ (x : α) (n : set α), n ∈ nhds x → (∃ (s : set α) (H : s ∈ nhds x), s ⊆ n ∧ is_compact s)
There are various definitions of "locally compact space" in the literature, which agree for
Hausdorff spaces but not in general. This one is the precise condition on X needed for the
evaluation map C(X, Y) × X → Y
to be continuous for all Y
when C(X, Y)
is given the
compact-open topology.
In general it suffices that all but finitely many of the spaces are compact, but that's not straightforward to state and use.
For spaces that are not Hausdorff.
A reformulation of the definition of locally compact space: In a locally compact space,
every open set containing x
has a compact subset containing x
in its interior.
In a locally compact space every point has a compact neighborhood.
In a locally compact space, for every containement K ⊆ U
of a compact set K
in an open
set U
, there is a compact neighborhood L
such that K ⊆ L ⊆ U
: equivalently, there is a
compact L
such that K ⊆ interior L
and L ⊆ U
.
In a locally compact space, every compact set is contained in the interior of a compact set.
- exists_compact_covering : ∃ (K : ℕ → set α), (∀ (n : ℕ), is_compact (K n)) ∧ (⋃ (n : ℕ), K n) = set.univ
A σ-compact space is a space that is the union of a countable collection of compact subspaces.
Note that a locally compact separable T₂ space need not be σ-compact.
The sequence can be extracted using topological_space.compact_covering
.
Instances of this typeclass
- sigma_compact_space_of_locally_compact_second_countable
- separable_locally_compact_group.sigma_compact_space
- separable_locally_compact_add_group.sigma_compact_space
- compact_space.sigma_compact
- prod.sigma_compact_space
- pi.sigma_compact_space
- sum.sigma_compact_space
- sigma.sigma_compact_space
- ulift.sigma_compact_space
A choice of compact covering for a σ
-compact space, chosen to be monotone.
If α
is a σ
-compact space, then a locally finite family of nonempty sets of α
can have
only countably many elements, set.countable
version.
If f : ι → set α
is a locally finite covering of a σ-compact topological space by nonempty
sets, then the index type ι
is encodable.
Equations
- hf.encodable hne = encodable.of_equiv ↥set.univ (equiv.set.univ ι).symm
In a topological space with sigma compact topology, if f
is a function that sends each point
x
of a closed set s
to a neighborhood of x
within s
, then for some countable set t ⊆ s
,
the neighborhoods f x
, x ∈ t
, cover the whole set s
.
In a topological space with sigma compact topology, if f
is a function that sends each
point x
to a neighborhood of x
, then for some countable set s
, the neighborhoods f x
,
x ∈ s
, cover the whole space.
- to_fun : ℕ → set X
- is_compact' : ∀ (n : ℕ), is_compact (self.to_fun n)
- subset_interior_succ' : ∀ (n : ℕ), self.to_fun n ⊆ interior (self.to_fun (n + 1))
- Union_eq' : (⋃ (n : ℕ), self.to_fun n) = set.univ
An exhaustion by compact sets of a
topological space is a sequence of compact sets K n
such that K n ⊆ interior (K (n + 1))
and
(⋃ n, K n) = univ
.
If X
is a locally compact sigma compact space, then compact_exhaustion.choice X
provides
a choice of an exhaustion by compact sets. This choice is also available as
(default : compact_exhaustion X)
.
Instances for compact_exhaustion
- compact_exhaustion.has_sizeof_inst
- compact_exhaustion.has_coe_to_fun
- compact_exhaustion.inhabited
Equations
The minimal n
such that x ∈ K n
.
Prepend the empty set to a compact exhaustion K n
.
Equations
- K.shiftr = {to_fun := λ (n : ℕ), n.cases_on ∅ ⇑K, is_compact' := _, subset_interior_succ' := _, Union_eq' := _}
A choice of an exhaustion by compact sets of a locally compact sigma compact space.
Equations
Equations
- compact_exhaustion.inhabited = {default := compact_exhaustion.choice α _inst_4}
Alias of the forward direction of is_clopen_iff_frontier_eq_empty
.
The intersection of a disjoint covering by two open sets of a clopen set will be clopen.
A preirreducible set s
is one where there is no non-trivial pair of disjoint opens on s
.
An irreducible set s
is one that is nonempty and
where there is no non-trivial pair of disjoint opens on s
.
Equations
- is_irreducible s = (s.nonempty ∧ is_preirreducible s)
Alias of the reverse direction of is_preirreducible_iff_closure
.
Alias of the reverse direction of is_irreducible_iff_closure
.
The set of irreducible components of a topological space.
Equations
- irreducible_components α = maximals has_le.le {s : set α | is_irreducible s}
A maximal irreducible set that contains a given point.
Equations
- is_preirreducible_univ : is_preirreducible set.univ
A preirreducible space is one where there is no non-trivial pair of disjoint opens.
Instances of this typeclass
- to_preirreducible_space : preirreducible_space α
- to_nonempty : nonempty α
An irreducible space is one that is nonempty and where there is no non-trivial pair of disjoint opens.
In a (pre)irreducible space, a nonempty open set is dense.
An infinite type with cofinite topology is an irreducible topological space.
A set s
is irreducible if and only if
for every finite collection of open sets all of whose members intersect s
,
s
also intersects the intersection of the entire collection
(i.e., there is an element of s
contained in every member of the collection).
A set is preirreducible if and only if for every cover by two closed sets, it is contained in one of the two covering sets.
A set is irreducible if and only if for every cover by a finite collection of closed sets, it is contained in one of the members of the collection.
A nonemtpy open subset of a preirreducible subspace is dense in the subspace.
If ∅ ≠ U ⊆ S ⊆ Z
such that U
is open and Z
is preirreducible, then S
is irreducible.