awhecmu/canonical-drafter-extract-mathlib huggingface dataset:
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (goal)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
l : List Bool
ih : P
⊢ P
have property : Perfect (C1 (C := (↑ih : Set α)) sorry sorry (ε := u (l.length + 1)) sorry) ∧
  (C1 (C := (↑ih : Set α)) sorry sorry (ε := u (l.length + 1)) sorry).Nonempty
Tactic: use C1 ih.property.1 ih.property.2 (upos (l.length + 1))
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (goal)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
l : List Bool
nil : P
⊢ P
have cons : (a : Bool) → (l : List Bool) → (ih : P) → P
Tactic: induction l with
    | nil => exact ⟨C, ⟨hC, hnonempty⟩⟩
    | cons a l ih =>
      cases a
      · use C0 ih.property.1 ih.property.2 (upos (l.length + 1))
        exact ⟨(h0 _ _ _).1, (h0 _ _ _).2.1⟩
      use C1 ih.property.1 ih.property.2 (upos (l.length + 1))
      exact ⟨(h1 _ _ _).1, (h1 _ _ _).2.1⟩
Cleared hypotheses: l
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (goal)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
DP : List Bool → P :=
  fun (l : List Bool) ↦
    List.rec (motive := fun (l : List Bool) ↦ P) (Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty) C ⋯)
      (fun (a : Bool) (l : List Bool) (ih : P) ↦
        Bool.casesOn (motive := fun (t : Bool) ↦ (h : a = t) → P) a
          (fun (h : a = false) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C0 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          (fun (h : a = true) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C1 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          ⋯)
      l
D : List Bool → Set α := fun (l : List Bool) ↦ (↑(DP l) : Set α)
⊢ ClosureAntitone D
have refine : CantorScheme.Antitone D
Tactic: refine Antitone.closureAntitone ?_ fun l => (DP l).property.1.closed
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (hypothesis)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
DP : List Bool → P :=
  fun (l : List Bool) ↦
    List.rec (motive := fun (l : List Bool) ↦ P) (Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty) C ⋯)
      (fun (a : Bool) (l : List Bool) (ih : P) ↦
        Bool.casesOn (motive := fun (t : Bool) ↦ (h : a = t) → P) a
          (fun (h : a = false) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C0 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          (fun (h : a = true) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C1 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          ⋯)
      l
D : List Bool → Set α := fun (l : List Bool) ↦ (↑(DP l) : Set α)
⊢ ∃ (f : (ℕ → Bool) → α), range f ⊆ C ∧ Continuous f ∧ Injective f
have hanti : ClosureAntitone D
Tactic: have hanti : ClosureAntitone D := by
    refine Antitone.closureAntitone ?_ fun l => (DP l).property.1.closed
    intro l a
    cases a
    · exact (h0 _ _ _).2.2.1
    exact (h1 _ _ _).2.2.1
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (goal)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
DP : List Bool → P :=
  fun (l : List Bool) ↦
    List.rec (motive := fun (l : List Bool) ↦ P) (Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty) C ⋯)
      (fun (a : Bool) (l : List Bool) (ih : P) ↦
        Bool.casesOn (motive := fun (t : Bool) ↦ (h : a = t) → P) a
          (fun (h : a = false) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C0 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          (fun (h : a = true) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C1 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          ⋯)
      l
D : List Bool → Set α := fun (l : List Bool) ↦ (↑(DP l) : Set α)
hanti : ClosureAntitone D
x : ℕ → Bool
⊢ Tendsto (β := ℝ≥0∞) (fun (n : ℕ) ↦ ediam (D (PiNat.res x n))) atTop (nhds 0)
have hgf : ∀ᶠ (b : ℕ) in atTop, 0 ≤ ediam (D (PiNat.res x b))
Tactic: apply tendsto_of_tendsto_of_tendsto_of_le_of_le' tendsto_const_nhds hu
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (goal)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
DP : List Bool → P :=
  fun (l : List Bool) ↦
    List.rec (motive := fun (l : List Bool) ↦ P) (Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty) C ⋯)
      (fun (a : Bool) (l : List Bool) (ih : P) ↦
        Bool.casesOn (motive := fun (t : Bool) ↦ (h : a = t) → P) a
          (fun (h : a = false) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C0 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          (fun (h : a = true) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C1 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          ⋯)
      l
D : List Bool → Set α := fun (l : List Bool) ↦ (↑(DP l) : Set α)
hanti : ClosureAntitone D
x : ℕ → Bool
hgf : ∀ᶠ (b : ℕ) in atTop, 0 ≤ ediam (D (PiNat.res x b))
⊢ Tendsto (β := ℝ≥0∞) (fun (n : ℕ) ↦ ediam (D (PiNat.res x n))) atTop (nhds 0)
have hfh : ∀ᶠ (b : ℕ) in atTop, ediam (D (PiNat.res x b)) ≤ u b
Tactic: apply tendsto_of_tendsto_of_tendsto_of_le_of_le' tendsto_const_nhds hu
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (goal)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
DP : List Bool → P :=
  fun (l : List Bool) ↦
    List.rec (motive := fun (l : List Bool) ↦ P) (Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty) C ⋯)
      (fun (a : Bool) (l : List Bool) (ih : P) ↦
        Bool.casesOn (motive := fun (t : Bool) ↦ (h : a = t) → P) a
          (fun (h : a = false) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C0 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          (fun (h : a = true) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C1 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          ⋯)
      l
D : List Bool → Set α := fun (l : List Bool) ↦ (↑(DP l) : Set α)
hanti : ClosureAntitone D
x : ℕ → Bool
⊢ ∀ᶠ (b : ℕ) in atTop, ediam (D (PiNat.res x b)) ≤ u b
have hfh : ∃ (a : ℕ), ∀ b ≥ a, ediam (D (PiNat.res x b)) ≤ u b
Tactic: rw [eventually_atTop]
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (goal)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
DP : List Bool → P :=
  fun (l : List Bool) ↦
    List.rec (motive := fun (l : List Bool) ↦ P) (Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty) C ⋯)
      (fun (a : Bool) (l : List Bool) (ih : P) ↦
        Bool.casesOn (motive := fun (t : Bool) ↦ (h : a = t) → P) a
          (fun (h : a = false) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C0 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          (fun (h : a = true) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C1 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          ⋯)
      l
D : List Bool → Set α := fun (l : List Bool) ↦ (↑(DP l) : Set α)
hanti : ClosureAntitone D
x : ℕ → Bool
⊢ ∃ (a : ℕ), ∀ b ≥ a, ediam (D (PiNat.res x b)) ≤ u b
have hfh : ∀ (m : ℕ) (hm : 1 ≤ m), ediam (D (PiNat.res x m)) ≤ u m
Tactic: refine ⟨1, fun m (hm : 1 ≤ m) => ?_⟩
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (hypothesis)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
DP : List Bool → P :=
  fun (l : List Bool) ↦
    List.rec (motive := fun (l : List Bool) ↦ P) (Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty) C ⋯)
      (fun (a : Bool) (l : List Bool) (ih : P) ↦
        Bool.casesOn (motive := fun (t : Bool) ↦ (h : a = t) → P) a
          (fun (h : a = false) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C0 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          (fun (h : a = true) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C1 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          ⋯)
      l
D : List Bool → Set α := fun (l : List Bool) ↦ (↑(DP l) : Set α)
hanti : ClosureAntitone D
x : ℕ → Bool
m : ℕ
hm : 1 ≤ m
⊢ ediam (D (PiNat.res x m)) ≤ u m
have hm₁ : m ≠ 0
Tactic: rw [Nat.one_le_iff_ne_zero] at hm
Cleared hypotheses: hm
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (goal)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
DP : List Bool → P :=
  fun (l : List Bool) ↦
    List.rec (motive := fun (l : List Bool) ↦ P) (Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty) C ⋯)
      (fun (a : Bool) (l : List Bool) (ih : P) ↦
        Bool.casesOn (motive := fun (t : Bool) ↦ (h : a = t) → P) a
          (fun (h : a = false) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C0 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          (fun (h : a = true) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C1 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          ⋯)
      l
D : List Bool → Set α := fun (l : List Bool) ↦ (↑(DP l) : Set α)
hanti : ClosureAntitone D
x : ℕ → Bool
m : ℕ
hm : m ≠ 0
⊢ ediam (D (PiNat.res x m)) ≤ u m
have hfh : ∀ (n : ℕ) (hm : n.succ ≠ 0), ediam (D (PiNat.res x n.succ)) ≤ u n.succ
Tactic: rcases Nat.exists_eq_succ_of_ne_zero hm with ⟨n, rfl⟩
Cleared hypotheses: m, hm
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (goal)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
DP : List Bool → P :=
  fun (l : List Bool) ↦
    List.rec (motive := fun (l : List Bool) ↦ P) (Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty) C ⋯)
      (fun (a : Bool) (l : List Bool) (ih : P) ↦
        Bool.casesOn (motive := fun (t : Bool) ↦ (h : a = t) → P) a
          (fun (h : a = false) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C0 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          (fun (h : a = true) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C1 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          ⋯)
      l
D : List Bool → Set α := fun (l : List Bool) ↦ (↑(DP l) : Set α)
hanti : ClosureAntitone D
x : ℕ → Bool
n : ℕ
hm : n.succ ≠ 0
⊢ ediam (D (PiNat.res x n.succ)) ≤ u n.succ
have hfh : ediam (D (x n :: PiNat.res x n)) ≤ u (n + 1)
Tactic: dsimp
-- Lean 4 proof step from Mathlib.Topology.MetricSpace.Perfect (goal)
Goal:
α : Type u_1
inst : MetricSpace α
C : Set α
hC : Perfect C
hnonempty : C.Nonempty
inst_1 : CompleteSpace α
u : ℕ → ℝ≥0∞
upos' : ∀ (n : ℕ), Membership.mem (γ := Set ℝ≥0∞) (Ioo 0 1) (u n)
hu : Tendsto u atTop (nhds 0)
upos : ∀ (n : ℕ), 0 < u n
P : Type (max 0 u_1) := { E : Set α // Perfect E ∧ E.Nonempty }
C0 C1 : {C : Set α} → (hC : Perfect C) → (hnonempty : C.Nonempty) → {ε : ℝ≥0∞} → (hε : 0 < ε) → Set α
h0 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C0 (C := C) hC hnonempty hε) ∧
      (C0 (C := C) hC hnonempty hε).Nonempty ∧ C0 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C0 (C := C) hC hnonempty hε) ≤ ε
h1 :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Perfect (C1 (C := C) hC hnonempty hε) ∧
      (C1 (C := C) hC hnonempty hε).Nonempty ∧ C1 (C := C) hC hnonempty hε ⊆ C ∧ ediam (C1 (C := C) hC hnonempty hε) ≤ ε
hdisj :
  ∀ {C : Set α} (hC : Perfect C) (hnonempty : C.Nonempty) {ε : ℝ≥0∞} (hε : 0 < ε),
    Disjoint (C0 (C := C) hC hnonempty hε) (C1 (C := C) hC hnonempty hε)
DP : List Bool → P :=
  fun (l : List Bool) ↦
    List.rec (motive := fun (l : List Bool) ↦ P) (Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty) C ⋯)
      (fun (a : Bool) (l : List Bool) (ih : P) ↦
        Bool.casesOn (motive := fun (t : Bool) ↦ (h : a = t) → P) a
          (fun (h : a = false) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C0 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          (fun (h : a = true) ↦
            Subtype.mk (p := fun (E : Set α) ↦ Perfect E ∧ E.Nonempty)
              (C1 (C := (↑ih : Set α)) ⋯ ⋯ (ε := u (l.length + 1)) ⋯) ⋯)
          ⋯)
      l
D : List Bool → Set α := fun (l : List Bool) ↦ (↑(DP l) : Set α)
hanti : ClosureAntitone D
x : ℕ → Bool
n : ℕ
hm : n.succ ≠ 0
⊢ ediam (D (x n :: PiNat.res x n)) ≤ u (n + 1)
have hfh : ediam (D (false :: PiNat.res x n)) ≤ u (n + 1)
Tactic: cases x n