Lean library Β· module TopologyByExample.Theorems.RealLineIllustrations

Exact statements for the real-line illustrations

Source file

This file was written by Codex (OpenAI's AI model) working under the direction of David R. MacIver, who reviews it and is responsible for it.

Imports

theorem reciprocal_accumulation

TopologyByExample.BookIllustrations.reciprocal_accumulation

Infinite accumulation without condensation in the reciprocal-interval union.

theorem reciprocal_accumulation :
    AccPt (0 : ℝ) (π“Ÿ ReciprocalSubsets.intervalUnion) ∧
    (βˆ€ U ∈ 𝓝 (0 : ℝ), (U ∩ ReciprocalSubsets.intervalUnion).Infinite) ∧
    βˆƒ U ∈ 𝓝 (0 : ℝ), (U ∩ ReciprocalSubsets.intervalUnion).Countable
Proof
:=
  ⟨BookReciprocals.accPt_intervalUnion, fun _ h ↦ BookReciprocals.infinite_intervalUnion_in_nhds h,
    BookReciprocals.countable_intervalUnion_in_some_nhds⟩

On this site: Reciprocal sequence with a closed interval: Infinite accumulation without condensation

theorem reciprocal_sequence

TopologyByExample.BookIllustrations.reciprocal_sequence

The reciprocal sequence is Cauchy without a cluster point in its own subspace.

theorem reciprocal_sequence :
    CauchySeq BookReciprocals.sequence ∧
    (βˆ€ x, Β¬MapClusterPt x atTop BookReciprocals.sequence) ∧
    Β¬CompleteSpace ReciprocalSubsets.reciprocalSet
Proof
:=
  ⟨BookReciprocals.cauchySeq_sequence, BookReciprocals.not_mapClusterPt_sequence,
    BookReciprocals.not_completeSpace_reciprocal⟩

On this site: Countably infinite discrete space: An incomplete inherited metric on a discrete subspace

theorem harmonic_bijection

TopologyByExample.BookIllustrations.harmonic_bijection

A continuous bijection between a discrete set and the convergent sequence.

theorem harmonic_bijection :
    Function.Bijective BookConvergentSequence.enumeration ∧
    Continuous BookConvergentSequence.enumeration ∧ IsEmpty (β„• β‰ƒβ‚œ FortSpaces.harmonicSet)
Proof
:=
  ⟨BookConvergentSequence.enumeration_bijective, BookConvergentSequence.continuous_enumeration,
    BookConvergentSequence.not_homeomorphic⟩

On this site: Ordinal space of a countable successor ordinal above \(\omega\): A continuous bijection from a discrete space

theorem even_reciprocals

TopologyByExample.BookIllustrations.even_reciprocals

The specific even-reciprocal witness to failure of extremal disconnectedness.

theorem even_reciprocals :
    IsOpen (range BookConvergentSequence.evenPoint) ∧
    closure (range BookConvergentSequence.evenPoint) =
      insert BookConvergentSequence.zeroPoint (range BookConvergentSequence.evenPoint) ∧
    Β¬IsOpen (closure (range BookConvergentSequence.evenPoint))
Proof
:=
  ⟨BookConvergentSequence.isOpen_range_evenPoint, BookConvergentSequence.closure_evenPoint,
    BookConvergentSequence.not_isOpen_closure_evenPoint⟩

On this site: Ordinal space of a countable successor ordinal above \(\omega\): An open subset whose closure is not open

theorem alternating_sequence

TopologyByExample.BookIllustrations.alternating_sequence

The alternating enumeration has zero as a cluster point but not as a limit.

theorem alternating_sequence :
    range BookReciprocals.alternating = AlternatingReciprocals.subset ∧
    AccPt (0 : ℝ) (π“Ÿ (range BookReciprocals.alternating)) ∧
    (βˆ€ U ∈ 𝓝 (0 : ℝ), (U ∩ range BookReciprocals.alternating).Infinite) ∧
    MapClusterPt (0 : ℝ) atTop BookReciprocals.alternating ∧
    Β¬Tendsto BookReciprocals.alternating atTop (𝓝 (0 : ℝ))
Proof
:=
  ⟨BookReciprocals.range_alternating, BookReciprocals.accPt_alternating_range,
    fun _ h ↦ BookReciprocals.infinite_alternating_in_nhds h,
    BookReciprocals.alternating_cluster_zero,
    BookReciprocals.alternating_not_tendsto_zero⟩

On this site: Ordinal space of a countable limit ordinal above \(\omega\): A cluster point that is not a limit of the enumeration

theorem shrinking_intervals

TopologyByExample.BookIllustrations.shrinking_intervals

The shrinking intervals and the failure of interior to preserve countable intersections.

theorem shrinking_intervals :
    (βˆ€ n, Nonempty (BookIntervals.shrinking n β‰ƒβ‚œ ℝ)) ∧
    (β‹‚ n, BookIntervals.shrinking n) = {1} ∧
    interior (β‹‚ n, BookIntervals.shrinking n) = βˆ… ∧
    (β‹‚ n, interior (BookIntervals.shrinking n)) = {1}
Proof
:=
  ⟨fun n ↦ ⟨BookIntervals.shrinkingHomeomorph n⟩, BookIntervals.iInter_shrinking,
    BookIntervals.interior_iInter_shrinking, BookIntervals.iInter_interior_shrinking⟩

On this site: Real line: Interior and a countable intersection of intervals

theorem regular_open_union

TopologyByExample.BookIllustrations.regular_open_union

A union of two regular open intervals need not be regular open.

theorem regular_open_union :
    interior (closure BookIntervals.leftOpen) = BookIntervals.leftOpen ∧
    interior (closure BookIntervals.rightOpen) = BookIntervals.rightOpen ∧
    PuncturedInterval.subset β‰  interior (closure PuncturedInterval.subset)
Proof
:=
  ⟨BookIntervals.component_interiors_closures.1, BookIntervals.component_interiors_closures.2,
    BookIntervals.punctured_ne_interior_closure⟩

On this site: Punctured open interval: A union of regular open sets need not be regular open

theorem adjoining_closed_intervals

TopologyByExample.BookIllustrations.adjoining_closed_intervals

Regular closed intervals and their intersection and interior-of-union comparisons.

theorem adjoining_closed_intervals :
    closure (interior (Icc (0 : ℝ) (1 / 2))) = Icc 0 (1 / 2) ∧
    closure (interior (Icc (1 / 2 : ℝ) 1)) = Icc (1 / 2) 1 ∧
    Icc (0 : ℝ) (1 / 2) ∩ Icc (1 / 2) 1 = {1 / 2} ∧
    closure (interior ({1 / 2} : Set ℝ)) β‰  {1 / 2} ∧
    interior (Icc (0 : ℝ) (1 / 2)) βˆͺ interior (Icc (1 / 2) 1) = PuncturedInterval.subset ∧
    interior (Icc (0 : ℝ) (1 / 2) βˆͺ Icc (1 / 2) 1) = Ioo 0 1
Proof
:=
  ⟨BookIntervals.component_closures_interiors.1, BookIntervals.component_closures_interiors.2,
    BookIntervals.closed_intersection, BookIntervals.singleton_not_regularClosed,
    BookIntervals.interiors_union, BookIntervals.interior_union⟩

On this site: Unit interval: Adjoining closed intervals and their interiors

theorem mutual_interval_embeddings

TopologyByExample.BookIllustrations.mutual_interval_embeddings

Mutual embeddings do not imply homeomorphism, even for two real intervals.

theorem mutual_interval_embeddings :
    IsEmbedding BookEmbeddings.openToClosed ∧ IsEmbedding BookEmbeddings.closedToOpen ∧
    range (fun x ↦ (BookEmbeddings.closedToOpen x).val) = Icc (1 / 4 : ℝ) (3 / 4) ∧
    IsEmpty (Ioo (0 : ℝ) 1 β‰ƒβ‚œ Icc (0 : ℝ) 1)
Proof
:=
  ⟨BookEmbeddings.isEmbedding_openToClosed, BookEmbeddings.isEmbedding_closedToOpen,
    BookEmbeddings.range_closedToOpen_val, BookEmbeddings.not_homeomorphic_intervals⟩

On this site: Unit interval: Mutual embeddings without a homeomorphism

theorem reciprocal_metric

TopologyByExample.BookIllustrations.reciprocal_metric

An ordinary complete and a reciprocal incomplete metric with the same discrete topology.

theorem reciprocal_metric :
    (βˆ€ n m, BookReciprocals.reciprocalMetric.dist n m =
      |(n : ℝ) - m| / (((n : ℝ) + 1) * ((m : ℝ) + 1))) ∧
    BookReciprocals.reciprocalMetric.toUniformSpace.toTopologicalSpace =
      (inferInstance : TopologicalSpace β„•) ∧
    Β¬@CompleteSpace β„• BookReciprocals.reciprocalMetric.toUniformSpace ∧ CompleteSpace β„• ∧
    @CauchySeq β„• β„• BookReciprocals.reciprocalMetric.toUniformSpace inferInstance (fun n ↦ n)
Proof
:=
  ⟨BookReciprocals.reciprocalMetric_dist, BookReciprocals.reciprocalMetric_topology,
    BookReciprocals.reciprocalMetric_not_complete, BookReciprocals.ordinaryMetric_complete,
    BookReciprocals.reciprocalMetric_cauchy⟩

On this site: Countably infinite discrete space: Complete and incomplete metrics with the same discrete topology

theorem capped_balls

TopologyByExample.BookIllustrations.capped_balls

The closure of a capped open ball differs from the corresponding closed ball.

theorem capped_balls :
    @Metric.ball ℝ (BoundedMetrics.cappedMetric ℝ).toPseudoMetricSpace 0 1 = Ioo (-1) 1 ∧
    closure (@Metric.ball ℝ (BoundedMetrics.cappedMetric ℝ).toPseudoMetricSpace 0 1) =
      Icc (-1) 1 ∧
    @Metric.closedBall ℝ (BoundedMetrics.cappedMetric ℝ).toPseudoMetricSpace 0 1 = univ
Proof
:=
  ⟨BoundedMetrics.real_capped_unit_ball, BoundedMetrics.real_closure_capped_unit_ball,
    BoundedMetrics.real_capped_unit_closedBall⟩

On this site: Real line: The closure of an open ball can be smaller than the closed ball

theorem iterated_metrics

TopologyByExample.BookIllustrations.iterated_metrics

The exact topology and distances of every fractional iteration.

theorem iterated_metrics (X : Type*) [MetricSpace X] (n : β„•) :
    (BoundedMetrics.iteratedMetric X n).toUniformSpace.toTopologicalSpace =
      (inferInstance : TopologicalSpace X) ∧
    (βˆ€ x y : X, (BoundedMetrics.iteratedMetric X n).dist x y =
      dist x y / (1 + (n : ℝ) * dist x y)) ∧
    βˆ€ x y : X, (BoundedMetrics.iteratedMetric X (n + 1)).dist x y < 1
Proof
:=
  ⟨BoundedMetrics.iteratedMetric_topology X n, BoundedMetrics.iteratedMetric_dist X n,
    BoundedMetrics.iteratedMetric_dist_lt_one X n⟩

On this site: Theorem: Iterating fractional compression of a metric

theorem compressed_sequence

TopologyByExample.BookIllustrations.compressed_sequence

The compressed real metric's explicit Cauchy sequence and distance comparison.

theorem compressed_sequence :
    (βˆ€ x y : ℝ, CompressedRealMetric.metric.dist x y ≀ dist x y) ∧
    @CauchySeq ℝ β„• CompressedRealMetric.metric.toUniformSpace inferInstance
      (fun n ↦ (n : ℝ)) ∧
    βˆ€ x : ℝ, Β¬MapClusterPt x atTop (fun n : β„• ↦ (n : ℝ))
Proof
:=
  ⟨CompressedRealMetric.metric_dist_le, CompressedRealMetric.metric_cauchy_nat,
    CompressedRealMetric.metric_nat_not_mapClusterPt⟩

On this site: Real line: A Cauchy enumeration escaping every point