Lean library · module TopologyByExample.Spaces.FiniteSupportSequences
Eventually-zero real sequences
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
definition finiteSupportSequences
TopologyByExample.finiteSupportSequences
The linear subspace of eventually-zero real sequences.
def finiteSupportSequences : Submodule ℝ (ℕ → ℝ)
Definition
where
carrier := {f | ∃ N, ∀ n, N ≤ n → f n = 0}
zero_mem' := ⟨0, by simp⟩
add_mem' := by
rintro f g ⟨N, hN⟩ ⟨M, hM⟩
exact ⟨max N M, fun n hn ↦ by simp [hN n (le_trans (le_max_left _ _) hn),
hM n (le_trans (le_max_right _ _) hn)]⟩
smul_mem' := by
rintro a f ⟨N, hN⟩
exact ⟨N, fun n hn ↦ by simp [hN n hn]⟩
definition FiniteSupportSequences
TopologyByExample.FiniteSupportSequences
Eventually-zero sequences with the topology induced from the countable product.
abbrev FiniteSupportSequences
:= finiteSupportSequences
On this site: Space: Eventually-zero real sequences
definition initialSupport
TopologyByExample.FiniteSupportSequences.initialSupport
Sequences supported strictly below a fixed index.
def initialSupport (N : ℕ) : Submodule ℝ FiniteSupportSequences
Definition
where
carrier := {f | ∀ n, N ≤ n → (f : ℕ → ℝ) n = 0}
zero_mem' := by simp
add_mem' := by intro f g hf hg n hn; simp [hf n hn, hg n hn]
smul_mem' := by intro a f hf n hn; simp [hf n hn]
definition unitSequence
TopologyByExample.FiniteSupportSequences.unitSequence
A sequence with one nonzero coordinate.
def unitSequence (N : ℕ) : FiniteSupportSequences
Definition
:=
⟨fun n ↦ if n = N then 1 else 0, ⟨N + 1, fun n hn ↦ by
have : n ≠ N := by omega
simp [this]⟩⟩
theorem isClosed_initialSupport
TopologyByExample.FiniteSupportSequences.isClosed_initialSupport
Bounded initial supports form closed subspaces.
theorem isClosed_initialSupport (N : ℕ) :
IsClosed (initialSupport N : Set FiniteSupportSequences)
Proof
:= by
have he : (initialSupport N : Set FiniteSupportSequences) =
⋂ n, ⋂ (_ : N ≤ n), {f : FiniteSupportSequences | (f : ℕ → ℝ) n = 0} := by
ext f
simp [initialSupport]
rw [he]
exact isClosed_iInter fun n ↦ isClosed_iInter fun _ ↦
isClosed_eq ((continuous_apply n).comp continuous_subtypeVal) continuous_const
theorem initialSupport_ne_top
TopologyByExample.FiniteSupportSequences.initialSupport_ne_top
No fixed initial segment supports every eventually-zero sequence.
theorem initialSupport_ne_top (N : ℕ) : initialSupport N ≠ ⊤
Proof
:= by
intro h
have hx : unitSequence N ∈ initialSupport N := h ▸ Submodule.mem_top
have he := hx N le_rfl
simp [unitSequence] at he
theorem nowhereDense_initialSupport
TopologyByExample.FiniteSupportSequences.nowhereDense_initialSupport
Each bounded-support subspace is nowhere dense.
theorem nowhereDense_initialSupport (N : ℕ) :
IsNowhereDense (initialSupport N : Set FiniteSupportSequences)
Proof
:= by
apply (isClosed_initialSupport N).isNowhereDense_iff.mpr
by_contra h
exact initialSupport_ne_top N ((initialSupport N).eq_top_of_nonempty_interior'
(Set.ne_empty_iff_nonempty.mp h))
theorem isMeagre_univ
TopologyByExample.FiniteSupportSequences.isMeagre_univ
The whole sequence space is meagre in itself.
theorem isMeagre_univ : IsMeagre (univ : Set FiniteSupportSequences)
Proof
:= by
have he : (⋃ N, (initialSupport N : Set FiniteSupportSequences)) = univ := by
apply eq_univ_of_forall
intro f
obtain ⟨N, hN⟩ := f.property
exact mem_iUnion.mpr ⟨N, hN⟩
rw [← he]
exact isMeagre_iUnion fun N ↦ (nowhereDense_initialSupport N).isMeagre
theorem not_secondCategory
TopologyByExample.FiniteSupportSequences.not_secondCategory
The sequence space is not of second category.
theorem not_secondCategory : ¬¬IsMeagre (univ : Set FiniteSupportSequences)
Proof
:=
fun h ↦ h isMeagre_univ
On this site: The space of eventually-zero real sequences is not of second category
theorem not_baireSpace
TopologyByExample.FiniteSupportSequences.not_baireSpace
This sequence space is not a Baire space.
theorem not_baireSpace : ¬BaireSpace FiniteSupportSequences
Proof
:= by
intro h
exact not_isMeagre_of_isOpen isOpen_univ (Set.univ_nonempty) isMeagre_univ
theorem arcConnectedSpace
TopologyByExample.FiniteSupportSequences.arcConnectedSpace
Straight segments give injective paths between distinct sequences.
theorem arcConnectedSpace : ArcConnectedSpace FiniteSupportSequences
On this site: The space of eventually-zero real sequences is arc connected
theorem metrizableSpace
TopologyByExample.FiniteSupportSequences.metrizableSpace
The inherited countable-product topology is metrizable.
theorem metrizableSpace : MetrizableSpace FiniteSupportSequences
Proof
:=
(IsEmbedding.subtypeVal :
IsEmbedding (fun f : FiniteSupportSequences ↦ (f : ℕ → ℝ))).metrizableSpace
On this site: The space of eventually-zero real sequences is metrizable
theorem secondCountableTopology
TopologyByExample.FiniteSupportSequences.secondCountableTopology
A countable base restricts from the ambient countable product.
theorem secondCountableTopology : SecondCountableTopology FiniteSupportSequences
Proof
:=
(IsEmbedding.subtypeVal :
IsEmbedding (fun f : FiniteSupportSequences ↦ (f : ℕ → ℝ))).secondCountableTopology
definition fromInitial
TopologyByExample.FiniteSupportSequences.fromInitial
Extend a finite tuple by zero.
def fromInitial (N : ℕ) (f : Fin N → ℝ) : FiniteSupportSequences
:=
⟨fun n ↦ if h : n < N then f ⟨n, h⟩ else 0,
⟨N, fun n hn ↦ by simp [not_lt.mpr hn]⟩⟩
theorem continuous_fromInitial
TopologyByExample.FiniteSupportSequences.continuous_fromInitial
Extending finite tuples by zero is continuous.
theorem continuous_fromInitial (N : ℕ) : Continuous (fromInitial N)
Proof
:= by
apply Continuous.subtype_mk
apply continuous_pi
intro n
by_cases h : n < N
· simpa [fromInitial, h] using (continuous_apply (⟨n, h⟩ : Fin N))
· simpa [fromInitial, h] using (continuous_const : Continuous (fun _ : Fin N → ℝ ↦ (0 : ℝ)))
theorem sigmaCompactSpace
TopologyByExample.FiniteSupportSequences.sigmaCompactSpace
The finite-dimensional subspaces give a countable σ-compact cover.
theorem sigmaCompactSpace : SigmaCompactSpace FiniteSupportSequences
Proof
:= by
apply isSigmaCompact_univ_iff.mp
have he : (⋃ N, range (fromInitial N)) = univ := by
apply eq_univ_of_forall
intro f
obtain ⟨N, hN⟩ := f.property
refine mem_iUnion.mpr ⟨N, (fun n ↦ (f : ℕ → ℝ) n), ?_⟩
apply Subtype.ext
funext n
by_cases h : n < N
· simp [fromInitial, h]
· simp [fromInitial, h, hN n (Nat.le_of_not_lt h)]
rw [← he]
exact isSigmaCompact_iUnion _ fun N ↦ isSigmaCompact_range (continuous_fromInitial N)
On this site: The space of eventually-zero real sequences is σ-compact
theorem locallyArcConnectedSpace
TopologyByExample.FiniteSupportSequences.locallyArcConnectedSpace
Convex neighbourhoods supply local arcs.
theorem locallyArcConnectedSpace : LocallyArcConnectedSpace FiniteSupportSequences
Proof
:= by
refine ⟨fun x U hU hx ↦ ?_⟩
obtain ⟨V, ⟨hV, hconv⟩, hsub⟩ :=
(LocallyConvexSpace.convex_basis (𝕜 := ℝ) x).mem_iff.mp (hU.mem_nhds hx)
exact ⟨interior V, isOpen_interior, mem_interior_iff_mem_nhds.mpr hV,
interior_subset.trans hsub, arcConnectedSpace_of_convex hconv.interior⟩
On this site: The space of eventually-zero real sequences is locally arc connected
theorem not_isCompletelyMetrizableSpace
TopologyByExample.FiniteSupportSequences.not_isCompletelyMetrizableSpace
No complete metric induces this topology.
theorem not_isCompletelyMetrizableSpace : ¬IsCompletelyMetrizableSpace FiniteSupportSequences
Proof
:=
fun _ ↦ not_baireSpace baireSpace_of_isCompletelyMetrizableSpace
instance
The zero sequence and a unit sequence are distinct.
instance : Nontrivial FiniteSupportSequences
Proof
:= by
refine ⟨⟨0, unitSequence 0, ?_⟩⟩
intro h
have := congrArg (fun f : FiniteSupportSequences ↦ (f : ℕ → ℝ) 0) h
simp [unitSequence] at this