Theorem: Order.iso_of_countable_dense
File: Mathlib/Order/CountableDenseLinearOrder.lean

tactic: rcases(F a).prop with ⟨f, hf, ha⟩
state_before: α : Type u_1
β : Type u_2
inst✝¹¹ : LinearOrder α
inst✝¹⁰ : LinearOrder β
inst✝⁹ : Encodable α
inst✝⁸ : DenselyOrdered α
inst✝⁷ : NoMinOrder α
inst✝⁶ : NoMaxOrder α
inst✝⁵ : Nonempty α
inst✝⁴ : Encodable β
inst✝³ : DenselyOrdered β
inst✝² : NoMinOrder β
inst✝¹ : NoMaxOrder β
inst✝ : Nonempty β
to_cofinal : α ⊕ β → Cofinal (PartialIso α β) := fun p => Sum.recOn p (definedAtLeft β) (definedAtRight α)
our_ideal : Ideal (PartialIso α β) := idealOfCofinals default to_cofinal
F : (a : α) → { b // ∃ f, f ∈ our_ideal ∧ (a, b) ∈ ↑f } :=
  fun a => funOfIdeal a our_ideal (_ : ∃ x, x ∈ to_cofinal (Sum.inl a) ∧ x ∈ idealOfCofinals default to_cofinal)
G : (b : β) → { a // ∃ f, f ∈ our_ideal ∧ (a, b) ∈ ↑f } :=
  fun b => invOfIdeal b our_ideal (_ : ∃ x, x ∈ to_cofinal (Sum.inr b) ∧ x ∈ idealOfCofinals default to_cofinal)
a : α
b : β
⊢ cmp a ((fun b => ↑(G b)) b) = cmp ((fun a => ↑(F a)) a) b

tactic: rcases(G b).prop with ⟨g, hg, hb⟩
state_before: case intro.intro
α : Type u_1
β : Type u_2
inst✝¹¹ : LinearOrder α
inst✝¹⁰ : LinearOrder β
inst✝⁹ : Encodable α
inst✝⁸ : DenselyOrdered α
inst✝⁷ : NoMinOrder α
inst✝⁶ : NoMaxOrder α
inst✝⁵ : Nonempty α
inst✝⁴ : Encodable β
inst✝³ : DenselyOrdered β
inst✝² : NoMinOrder β
inst✝¹ : NoMaxOrder β
inst✝ : Nonempty β
to_cofinal : α ⊕ β → Cofinal (PartialIso α β) := fun p => Sum.recOn p (definedAtLeft β) (definedAtRight α)
our_ideal : Ideal (PartialIso α β) := idealOfCofinals default to_cofinal
F : (a : α) → { b // ∃ f, f ∈ our_ideal ∧ (a, b) ∈ ↑f } :=
  fun a => funOfIdeal a our_ideal (_ : ∃ x, x ∈ to_cofinal (Sum.inl a) ∧ x ∈ idealOfCofinals default to_cofinal)
G : (b : β) → { a // ∃ f, f ∈ our_ideal ∧ (a, b) ∈ ↑f } :=
  fun b => invOfIdeal b our_ideal (_ : ∃ x, x ∈ to_cofinal (Sum.inr b) ∧ x ∈ idealOfCofinals default to_cofinal)
a : α
b : β
f : PartialIso α β
hf : f ∈ our_ideal
ha : (a, ↑(F a)) ∈ ↑f
⊢ cmp a ((fun b => ↑(G b)) b) = cmp ((fun a => ↑(F a)) a) b

tactic: rcases our_ideal.directed _ hf _ hg with ⟨m, _, fm, gm⟩
state_before: case intro.intro.intro.intro
α : Type u_1
β : Type u_2
inst✝¹¹ : LinearOrder α
inst✝¹⁰ : LinearOrder β
inst✝⁹ : Encodable α
inst✝⁸ : DenselyOrdered α
inst✝⁷ : NoMinOrder α
inst✝⁶ : NoMaxOrder α
inst✝⁵ : Nonempty α
inst✝⁴ : Encodable β
inst✝³ : DenselyOrdered β
inst✝² : NoMinOrder β
inst✝¹ : NoMaxOrder β
inst✝ : Nonempty β
to_cofinal : α ⊕ β → Cofinal (PartialIso α β) := fun p => Sum.recOn p (definedAtLeft β) (definedAtRight α)
our_ideal : Ideal (PartialIso α β) := idealOfCofinals default to_cofinal
F : (a : α) → { b // ∃ f, f ∈ our_ideal ∧ (a, b) ∈ ↑f } :=
  fun a => funOfIdeal a our_ideal (_ : ∃ x, x ∈ to_cofinal (Sum.inl a) ∧ x ∈ idealOfCofinals default to_cofinal)
G : (b : β) → { a // ∃ f, f ∈ our_ideal ∧ (a, b) ∈ ↑f } :=
  fun b => invOfIdeal b our_ideal (_ : ∃ x, x ∈ to_cofinal (Sum.inr b) ∧ x ∈ idealOfCofinals default to_cofinal)
a : α
b : β
f : PartialIso α β
hf : f ∈ our_ideal
ha : (a, ↑(F a)) ∈ ↑f
g : PartialIso α β
hg : g ∈ our_ideal
hb : (↑(G b), b) ∈ ↑g
⊢ cmp a ((fun b => ↑(G b)) b) = cmp ((fun a => ↑(F a)) a) b

tactic: exact m.prop (a, _) (fm ha) (_, b) (gm hb)
state_before: case intro.intro.intro.intro.intro.intro.intro
α : Type u_1
β : Type u_2
inst✝¹¹ : LinearOrder α
inst✝¹⁰ : LinearOrder β
inst✝⁹ : Encodable α
inst✝⁸ : DenselyOrdered α
inst✝⁷ : NoMinOrder α
inst✝⁶ : NoMaxOrder α
inst✝⁵ : Nonempty α
inst✝⁴ : Encodable β
inst✝³ : DenselyOrdered β
inst✝² : NoMinOrder β
inst✝¹ : NoMaxOrder β
inst✝ : Nonempty β
to_cofinal : α ⊕ β → Cofinal (PartialIso α β) := fun p => Sum.recOn p (definedAtLeft β) (definedAtRight α)
our_ideal : Ideal (PartialIso α β) := idealOfCofinals default to_cofinal
F : (a : α) → { b // ∃ f, f ∈ our_ideal ∧ (a, b) ∈ ↑f } :=
  fun a => funOfIdeal a our_ideal (_ : ∃ x, x ∈ to_cofinal (Sum.inl a) ∧ x ∈ idealOfCofinals default to_cofinal)
G : (b : β) → { a // ∃ f, f ∈ our_ideal ∧ (a, b) ∈ ↑f } :=
  fun b => invOfIdeal b our_ideal (_ : ∃ x, x ∈ to_cofinal (Sum.inr b) ∧ x ∈ idealOfCofinals default to_cofinal)
a : α
b : β
f : PartialIso α β
hf : f ∈ our_ideal
ha : (a, ↑(F a)) ∈ ↑f
g : PartialIso α β
hg : g ∈ our_ideal
hb : (↑(G b), b) ∈ ↑g
m : PartialIso α β
left✝ : m ∈ ↑our_ideal
fm : f ≤ m
gm : g ≤ m
⊢ cmp a ((fun b => ↑(G b)) b) = cmp ((fun a => ↑(F a)) a) b