Theorem: Cardinal.mk_subset_mk_lt_cof
File: Mathlib/SetTheory/Cardinal/Cofinality.lean

tactic: rcases eq_or_ne #α 0 with (ha | ha)
state_before: α✝ : Type u_1
r : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
⊢ #{ s // #↑s < (#α).ord.cof } = #α
state_after: case inl
α✝ : Type u_1
r : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α = 0
⊢ #{ s // #↑s < (#α).ord.cof } = #α

case inr
α✝ : Type u_1
r : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
⊢ #{ s // #↑s < (#α).ord.cof } = #α

tactic: have h' : IsStrongLimit #α := ⟨ha, h⟩
state_before: case inr
α✝ : Type u_1
r : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
⊢ #{ s // #↑s < (#α).ord.cof } = #α
state_after: case inr
α✝ : Type u_1
r : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
⊢ #{ s // #↑s < (#α).ord.cof } = #α

tactic: rcases ord_eq α with ⟨r, wo, hr⟩
state_before: case inr
α✝ : Type u_1
r : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
⊢ #{ s // #↑s < (#α).ord.cof } = #α
state_after: case inr.intro.intro
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
⊢ #{ s // #↑s < (#α).ord.cof } = #α

tactic: haveI := wo
state_before: case inr.intro.intro
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
⊢ #{ s // #↑s < (#α).ord.cof } = #α
state_after: case inr.intro.intro
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ #{ s // #↑s < (#α).ord.cof } = #α

tactic: apply le_antisymm
state_before: case inr.intro.intro
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ #{ s // #↑s < (#α).ord.cof } = #α
state_after: case inr.intro.intro.a
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ #{ s // #↑s < (#α).ord.cof } ≤ #α

case inr.intro.intro.a
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ #α ≤ #{ s // #↑s < (#α).ord.cof }

tactic: simp [ha]
state_before: case inl
α✝ : Type u_1
r : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α = 0
⊢ #{ s // #↑s < (#α).ord.cof } = #α
state_after: no goals

tactic: conv_rhs => rw [← mk_bounded_subset h hr]
state_before: case inr.intro.intro.a
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ #{ s // #↑s < (#α).ord.cof } ≤ #α
state_after: case inr.intro.intro.a
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ #{ s // #↑s < (#α).ord.cof } ≤ #{ s // Bounded r s }

tactic: apply mk_le_mk_of_subset
state_before: case inr.intro.intro.a
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ #{ s // #↑s < (#α).ord.cof } ≤ #{ s // Bounded r s }
state_after: case inr.intro.intro.a.h
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ (fun x =>
      Quotient.liftOn₂ (#↑x) (#α).ord.cof (fun α β => Nonempty (α ↪ β)) instLE.proof_1 ∧
        ¬Quotient.liftOn₂ (#α).ord.cof (#↑x) (fun α β => Nonempty (α ↪ β)) instLE.proof_1) ⊆
    fun x => ∃ a, ∀ b ∈ x, r b a

tactic: intro s hs
state_before: case inr.intro.intro.a.h
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ (fun x =>
      Quotient.liftOn₂ (#↑x) (#α).ord.cof (fun α β => Nonempty (α ↪ β)) instLE.proof_1 ∧
        ¬Quotient.liftOn₂ (#α).ord.cof (#↑x) (fun α β => Nonempty (α ↪ β)) instLE.proof_1) ⊆
    fun x => ∃ a, ∀ b ∈ x, r b a
state_after: case inr.intro.intro.a.h
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
s : Set α
hs :
  s ∈ fun x =>
    Quotient.liftOn₂ (#↑x) (#α).ord.cof (fun α β => Nonempty (α ↪ β)) instLE.proof_1 ∧
      ¬Quotient.liftOn₂ (#α).ord.cof (#↑x) (fun α β => Nonempty (α ↪ β)) instLE.proof_1
⊢ s ∈ fun x => ∃ a, ∀ b ∈ x, r b a

tactic: rw [hr] at hs
state_before: case inr.intro.intro.a.h
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
s : Set α
hs :
  s ∈ fun x =>
    Quotient.liftOn₂ (#↑x) (#α).ord.cof (fun α β => Nonempty (α ↪ β)) instLE.proof_1 ∧
      ¬Quotient.liftOn₂ (#α).ord.cof (#↑x) (fun α β => Nonempty (α ↪ β)) instLE.proof_1
⊢ s ∈ fun x => ∃ a, ∀ b ∈ x, r b a
state_after: case inr.intro.intro.a.h
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
s : Set α
hs :
  s ∈ fun x =>
    Quotient.liftOn₂ (#↑x) (type r).cof (fun α β => Nonempty (α ↪ β)) instLE.proof_1 ∧
      ¬Quotient.liftOn₂ (type r).cof (#↑x) (fun α β => Nonempty (α ↪ β)) instLE.proof_1
⊢ s ∈ fun x => ∃ a, ∀ b ∈ x, r b a

tactic: exact lt_cof_type hs
state_before: case inr.intro.intro.a.h
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
s : Set α
hs :
  s ∈ fun x =>
    Quotient.liftOn₂ (#↑x) (type r).cof (fun α β => Nonempty (α ↪ β)) instLE.proof_1 ∧
      ¬Quotient.liftOn₂ (type r).cof (#↑x) (fun α β => Nonempty (α ↪ β)) instLE.proof_1
⊢ s ∈ fun x => ∃ a, ∀ b ∈ x, r b a
state_after: no goals

tactic: refine @mk_le_of_injective α _ (fun x => Subtype.mk {x} ?_) ?_
state_before: case inr.intro.intro.a
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ #α ≤ #{ s // #↑s < (#α).ord.cof }
state_after: case inr.intro.intro.a.refine_1
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
x : α
⊢ #↑{x} < (#α).ord.cof

case inr.intro.intro.a.refine_2
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ Injective fun x => ⟨{x}, ⋯⟩

tactic: rw [mk_singleton]
state_before: case inr.intro.intro.a.refine_1
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
x : α
⊢ #↑{x} < (#α).ord.cof
state_after: case inr.intro.intro.a.refine_1
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
x : α
⊢ 1 < (#α).ord.cof

tactic: exact one_lt_aleph0.trans_le (aleph0_le_cof.2 (ord_isLimit h'.isLimit.aleph0_le))
state_before: case inr.intro.intro.a.refine_1
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
x : α
⊢ 1 < (#α).ord.cof
state_after: no goals

tactic: intro a b hab
state_before: case inr.intro.intro.a.refine_2
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
⊢ Injective fun x => ⟨{x}, ⋯⟩
state_after: case inr.intro.intro.a.refine_2
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
a b : α
hab : (fun x => ⟨{x}, ⋯⟩) a = (fun x => ⟨{x}, ⋯⟩) b
⊢ a = b

tactic: simpa [singleton_eq_singleton_iff] using hab
state_before: case inr.intro.intro.a.refine_2
α✝ : Type u_1
r✝ : α✝ → α✝ → Prop
α : Type u_2
h : ∀ x < #α, 2 ^ x < #α
ha : #α ≠ 0
h' : (#α).IsStrongLimit
r : α → α → Prop
wo : IsWellOrder α r
hr : (#α).ord = type r
this : IsWellOrder α r
a b : α
hab : (fun x => ⟨{x}, ⋯⟩) a = (fun x => ⟨{x}, ⋯⟩) b
⊢ a = b
state_after: no goals