l3lab/ntp-mathlib huggingface dataset:
theorem lt_nmul_iff₃ :
    d < a ⨳ b ⨳ c ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ b' ⨳ c ♯ a' ⨳ b ⨳ c' ♯ a ⨳ b' ⨳ c' ≤
          a' ⨳ b ⨳ c ♯ a ⨳ b' ⨳ c ♯ a ⨳ b ⨳ c' ♯ a' ⨳ b' ⨳ c' := by
  -- Porting note: was `refine' ⟨fun h => _, _⟩`, but can't get that to work?
  constructor
  · intro h
    rcases lt_nmul_iff.1 h with ⟨e, he, c', hc, H₁⟩
    rcases lt_nmul_iff.1 he with ⟨a', ha, b', hb, H₂⟩
    refine' ⟨a', ha, b', hb, c', hc, _⟩
    have := nadd_le_nadd H₁ (nmul_nadd_le H₂ hc.le)
    simp only [nadd_nmul, nadd_assoc] at this
    rw [nadd_left_comm, nadd_left_comm d, nadd_left_comm, nadd_le_nadd_iff_left,
      nadd_left_comm (a ⨳ b' ⨳ c), nadd_left_comm (a' ⨳ b ⨳ c), nadd_left_comm (a ⨳ b ⨳ c'),
      nadd_le_nadd_iff_left, nadd_left_comm (a ⨳ b ⨳ c'), nadd_left_comm (a ⨳ b ⨳ c')] at this
    simpa only [nadd_assoc]
  · rintro ⟨a', ha, b', hb, c', hc, h⟩
    have := h.trans_lt (nmul_nadd_lt₃ ha hb hc)
    repeat' rw [nadd_lt_nadd_iff_right] at this
    

Proof state:
case mpr.intro.intro.intro.intro.intro.intro
a b c d a' : Ordinal.{u}
ha : a' < a
b' : Ordinal.{u}
hb : b' < b
c' : Ordinal.{u}
hc : c' < c
h : d ♯ a' ⨳ b' ⨳ c ♯ a' ⨳ b ⨳ c' ♯ a ⨳ b' ⨳ c' ≤ a' ⨳ b ⨳ c ♯ a ⨳ b' ⨳ c ♯ a ⨳ b ⨳ c' ♯ a' ⨳ b' ⨳ c'
this : d < a ⨳ b ⨳ c
⊢ d < a ⨳ b ⨳ c

Next tactic:
assumption
theorem nmul_le_iff₃ :
    a ⨳ b ⨳ c ≤ d ↔
      ∀ a' < a, ∀ b' < b, ∀ c' < c,
        a' ⨳ b ⨳ c ♯ a ⨳ b' ⨳ c ♯ a ⨳ b ⨳ c' ♯ a' ⨳ b' ⨳ c' <
          d ♯ a' ⨳ b' ⨳ c ♯ a' ⨳ b ⨳ c' ♯ a ⨳ b' ⨳ c' := by
  

Proof state:
a b c d : Ordinal.{u}
⊢ a ⨳ b ⨳ c ≤ d ↔
    ∀ a' < a,
      ∀ b' < b,
        ∀ c' < c, a' ⨳ b ⨳ c ♯ a ⨳ b' ⨳ c ♯ a ⨳ b ⨳ c' ♯ a' ⨳ b' ⨳ c' < d ♯ a' ⨳ b' ⨳ c ♯ a' ⨳ b ⨳ c' ♯ a ⨳ b' ⨳ c'

Next tactic:
rw [← not_iff_not]
theorem nmul_le_iff₃ :
    a ⨳ b ⨳ c ≤ d ↔
      ∀ a' < a, ∀ b' < b, ∀ c' < c,
        a' ⨳ b ⨳ c ♯ a ⨳ b' ⨳ c ♯ a ⨳ b ⨳ c' ♯ a' ⨳ b' ⨳ c' <
          d ♯ a' ⨳ b' ⨳ c ♯ a' ⨳ b ⨳ c' ♯ a ⨳ b' ⨳ c' := by
  rw [← not_iff_not]; 

Proof state:
a b c d : Ordinal.{u}
⊢ ¬a ⨳ b ⨳ c ≤ d ↔
    ¬∀ a' < a,
        ∀ b' < b,
          ∀ c' < c, a' ⨳ b ⨳ c ♯ a ⨳ b' ⨳ c ♯ a ⨳ b ⨳ c' ♯ a' ⨳ b' ⨳ c' < d ♯ a' ⨳ b' ⨳ c ♯ a' ⨳ b ⨳ c' ♯ a ⨳ b' ⨳ c'

Next tactic:
simp [lt_nmul_iff₃]
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  

Proof state:
a b c d : Ordinal.{u}
⊢ d < a ⨳ (b ⨳ c) ↔
    ∃ a' < a,
      ∃ b' < b,
        ∃ c' < c,
          d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
            a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c')

Next tactic:
simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  

Proof state:
a b c d : Ordinal.{u}
⊢ (∃ a' < b,
      ∃ b' < c,
        ∃ c' < a,
          toOrdinal
              (toNatOrdinal d + toNatOrdinal (a' ⨳ b' ⨳ a) + toNatOrdinal (a' ⨳ c ⨳ c') + toNatOrdinal (b ⨳ b' ⨳ c')) ≤
            toOrdinal
              (toNatOrdinal (a' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ b' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ c') +
                toNatOrdinal (a' ⨳ b' ⨳ c'))) ↔
    ∃ a' < a,
      ∃ b' < b,
        ∃ c' < c,
          toOrdinal
              (toNatOrdinal d + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a)) ≤
            toOrdinal
              (toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) +
                toNatOrdinal (b' ⨳ c' ⨳ a'))

Next tactic:
constructor
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  constructor <;> 

Proof state:
case mp
a b c d : Ordinal.{u}
⊢ (∃ a' < b,
      ∃ b' < c,
        ∃ c' < a,
          toOrdinal
              (toNatOrdinal d + toNatOrdinal (a' ⨳ b' ⨳ a) + toNatOrdinal (a' ⨳ c ⨳ c') + toNatOrdinal (b ⨳ b' ⨳ c')) ≤
            toOrdinal
              (toNatOrdinal (a' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ b' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ c') +
                toNatOrdinal (a' ⨳ b' ⨳ c'))) →
    ∃ a' < a,
      ∃ b' < b,
        ∃ c' < c,
          toOrdinal
              (toNatOrdinal d + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a)) ≤
            toOrdinal
              (toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) +
                toNatOrdinal (b' ⨳ c' ⨳ a'))

Next tactic:
rintro ⟨b', hb, c', hc, a', ha, h⟩
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  constructor <;> 

Proof state:
case mpr
a b c d : Ordinal.{u}
⊢ (∃ a' < a,
      ∃ b' < b,
        ∃ c' < c,
          toOrdinal
              (toNatOrdinal d + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a)) ≤
            toOrdinal
              (toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) +
                toNatOrdinal (b' ⨳ c' ⨳ a'))) →
    ∃ a' < b,
      ∃ b' < c,
        ∃ c' < a,
          toOrdinal
              (toNatOrdinal d + toNatOrdinal (a' ⨳ b' ⨳ a) + toNatOrdinal (a' ⨳ c ⨳ c') + toNatOrdinal (b ⨳ b' ⨳ c')) ≤
            toOrdinal
              (toNatOrdinal (a' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ b' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ c') +
                toNatOrdinal (a' ⨳ b' ⨳ c'))

Next tactic:
rintro ⟨b', hb, c', hc, a', ha, h⟩
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  constructor <;> rintro ⟨b', hb, c', hc, a', ha, h⟩
  · 

Proof state:
case mp.intro.intro.intro.intro.intro.intro
a b c d b' : Ordinal.{u}
hb : b' < b
c' : Ordinal.{u}
hc : c' < c
a' : Ordinal.{u}
ha : a' < a
h :
  toOrdinal (toNatOrdinal d + toNatOrdinal (b' ⨳ c' ⨳ a) + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a')) ≤
    toOrdinal
      (toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a'))
⊢ ∃ a' < a,
    ∃ b' < b,
      ∃ c' < c,
        toOrdinal
            (toNatOrdinal d + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a)) ≤
          toOrdinal
            (toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) +
              toNatOrdinal (b' ⨳ c' ⨳ a'))

Next tactic:
use a', ha, b', hb, c', hc
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  constructor <;> rintro ⟨b', hb, c', hc, a', ha, h⟩
  · use a', ha, b', hb, c', hc; 

Proof state:
case right
a b c d b' : Ordinal.{u}
hb : b' < b
c' : Ordinal.{u}
hc : c' < c
a' : Ordinal.{u}
ha : a' < a
h :
  toOrdinal (toNatOrdinal d + toNatOrdinal (b' ⨳ c' ⨳ a) + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a')) ≤
    toOrdinal
      (toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a'))
⊢ toOrdinal (toNatOrdinal d + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a)) ≤
    toOrdinal
      (toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) + toNatOrdinal (b' ⨳ c' ⨳ a'))

Next tactic:
convert h using 1
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  constructor <;> rintro ⟨b', hb, c', hc, a', ha, h⟩
  · use a', ha, b', hb, c', hc; convert h using 1 <;> 

Proof state:
case h.e'_3
a b c d b' : Ordinal.{u}
hb : b' < b
c' : Ordinal.{u}
hc : c' < c
a' : Ordinal.{u}
ha : a' < a
h :
  toOrdinal (toNatOrdinal d + toNatOrdinal (b' ⨳ c' ⨳ a) + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a')) ≤
    toOrdinal
      (toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a'))
⊢ toOrdinal (toNatOrdinal d + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a)) =
    toOrdinal (toNatOrdinal d + toNatOrdinal (b' ⨳ c' ⨳ a) + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a'))

Next tactic:
abel_nf
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  constructor <;> rintro ⟨b', hb, c', hc, a', ha, h⟩
  · use a', ha, b', hb, c', hc; convert h using 1 <;> 

Proof state:
case h.e'_4
a b c d b' : Ordinal.{u}
hb : b' < b
c' : Ordinal.{u}
hc : c' < c
a' : Ordinal.{u}
ha : a' < a
h :
  toOrdinal (toNatOrdinal d + toNatOrdinal (b' ⨳ c' ⨳ a) + toNatOrdinal (b' ⨳ c ⨳ a') + toNatOrdinal (b ⨳ c' ⨳ a')) ≤
    toOrdinal
      (toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a'))
⊢ toOrdinal
      (toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) +
        toNatOrdinal (b' ⨳ c' ⨳ a')) =
    toOrdinal
      (toNatOrdinal (b' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ c' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ a') + toNatOrdinal (b' ⨳ c' ⨳ a'))

Next tactic:
abel_nf
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  constructor <;> rintro ⟨b', hb, c', hc, a', ha, h⟩
  · use a', ha, b', hb, c', hc; convert h using 1 <;> abel_nf
  · 

Proof state:
case mpr.intro.intro.intro.intro.intro.intro
a b c d b' : Ordinal.{u}
hb : b' < a
c' : Ordinal.{u}
hc : c' < b
a' : Ordinal.{u}
ha : a' < c
h :
  toOrdinal (toNatOrdinal d + toNatOrdinal (c' ⨳ c ⨳ b') + toNatOrdinal (b ⨳ a' ⨳ b') + toNatOrdinal (c' ⨳ a' ⨳ a)) ≤
    toOrdinal
      (toNatOrdinal (b ⨳ c ⨳ b') + toNatOrdinal (c' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ a' ⨳ a) + toNatOrdinal (c' ⨳ a' ⨳ b'))
⊢ ∃ a' < b,
    ∃ b' < c,
      ∃ c' < a,
        toOrdinal
            (toNatOrdinal d + toNatOrdinal (a' ⨳ b' ⨳ a) + toNatOrdinal (a' ⨳ c ⨳ c') + toNatOrdinal (b ⨳ b' ⨳ c')) ≤
          toOrdinal
            (toNatOrdinal (a' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ b' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ c') +
              toNatOrdinal (a' ⨳ b' ⨳ c'))

Next tactic:
use c', hc, a', ha, b', hb
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  constructor <;> rintro ⟨b', hb, c', hc, a', ha, h⟩
  · use a', ha, b', hb, c', hc; convert h using 1 <;> abel_nf
  · use c', hc, a', ha, b', hb; 

Proof state:
case right
a b c d b' : Ordinal.{u}
hb : b' < a
c' : Ordinal.{u}
hc : c' < b
a' : Ordinal.{u}
ha : a' < c
h :
  toOrdinal (toNatOrdinal d + toNatOrdinal (c' ⨳ c ⨳ b') + toNatOrdinal (b ⨳ a' ⨳ b') + toNatOrdinal (c' ⨳ a' ⨳ a)) ≤
    toOrdinal
      (toNatOrdinal (b ⨳ c ⨳ b') + toNatOrdinal (c' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ a' ⨳ a) + toNatOrdinal (c' ⨳ a' ⨳ b'))
⊢ toOrdinal (toNatOrdinal d + toNatOrdinal (c' ⨳ a' ⨳ a) + toNatOrdinal (c' ⨳ c ⨳ b') + toNatOrdinal (b ⨳ a' ⨳ b')) ≤
    toOrdinal
      (toNatOrdinal (c' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ a' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ b') + toNatOrdinal (c' ⨳ a' ⨳ b'))

Next tactic:
convert h using 1
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  constructor <;> rintro ⟨b', hb, c', hc, a', ha, h⟩
  · use a', ha, b', hb, c', hc; convert h using 1 <;> abel_nf
  · use c', hc, a', ha, b', hb; convert h using 1 <;> 

Proof state:
case h.e'_3
a b c d b' : Ordinal.{u}
hb : b' < a
c' : Ordinal.{u}
hc : c' < b
a' : Ordinal.{u}
ha : a' < c
h :
  toOrdinal (toNatOrdinal d + toNatOrdinal (c' ⨳ c ⨳ b') + toNatOrdinal (b ⨳ a' ⨳ b') + toNatOrdinal (c' ⨳ a' ⨳ a)) ≤
    toOrdinal
      (toNatOrdinal (b ⨳ c ⨳ b') + toNatOrdinal (c' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ a' ⨳ a) + toNatOrdinal (c' ⨳ a' ⨳ b'))
⊢ toOrdinal (toNatOrdinal d + toNatOrdinal (c' ⨳ a' ⨳ a) + toNatOrdinal (c' ⨳ c ⨳ b') + toNatOrdinal (b ⨳ a' ⨳ b')) =
    toOrdinal (toNatOrdinal d + toNatOrdinal (c' ⨳ c ⨳ b') + toNatOrdinal (b ⨳ a' ⨳ b') + toNatOrdinal (c' ⨳ a' ⨳ a))

Next tactic:
abel_nf
theorem lt_nmul_iff₃' :
    d < a ⨳ (b ⨳ c) ↔
      ∃ a' < a, ∃ b' < b, ∃ c' < c,
        d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') ≤
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') := by
  simp only [nmul_comm _ (_ ⨳ _), lt_nmul_iff₃, nadd_eq_add, NatOrdinal.toOrdinal_toNatOrdinal]
  constructor <;> rintro ⟨b', hb, c', hc, a', ha, h⟩
  · use a', ha, b', hb, c', hc; convert h using 1 <;> abel_nf
  · use c', hc, a', ha, b', hb; convert h using 1 <;> 

Proof state:
case h.e'_4
a b c d b' : Ordinal.{u}
hb : b' < a
c' : Ordinal.{u}
hc : c' < b
a' : Ordinal.{u}
ha : a' < c
h :
  toOrdinal (toNatOrdinal d + toNatOrdinal (c' ⨳ c ⨳ b') + toNatOrdinal (b ⨳ a' ⨳ b') + toNatOrdinal (c' ⨳ a' ⨳ a)) ≤
    toOrdinal
      (toNatOrdinal (b ⨳ c ⨳ b') + toNatOrdinal (c' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ a' ⨳ a) + toNatOrdinal (c' ⨳ a' ⨳ b'))
⊢ toOrdinal
      (toNatOrdinal (c' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ a' ⨳ a) + toNatOrdinal (b ⨳ c ⨳ b') +
        toNatOrdinal (c' ⨳ a' ⨳ b')) =
    toOrdinal
      (toNatOrdinal (b ⨳ c ⨳ b') + toNatOrdinal (c' ⨳ c ⨳ a) + toNatOrdinal (b ⨳ a' ⨳ a) + toNatOrdinal (c' ⨳ a' ⨳ b'))

Next tactic:
abel_nf
theorem nmul_le_iff₃' :
    a ⨳ (b ⨳ c) ≤ d ↔
      ∀ a' < a, ∀ b' < b, ∀ c' < c,
        a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') <
          d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') := by
  

Proof state:
a b c d : Ordinal.{u}
⊢ a ⨳ (b ⨳ c) ≤ d ↔
    ∀ a' < a,
      ∀ b' < b,
        ∀ c' < c,
          a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') <
            d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c')

Next tactic:
rw [← not_iff_not]
theorem nmul_le_iff₃' :
    a ⨳ (b ⨳ c) ≤ d ↔
      ∀ a' < a, ∀ b' < b, ∀ c' < c,
        a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') <
          d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c') := by
  rw [← not_iff_not]; 

Proof state:
a b c d : Ordinal.{u}
⊢ ¬a ⨳ (b ⨳ c) ≤ d ↔
    ¬∀ a' < a,
        ∀ b' < b,
          ∀ c' < c,
            a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') <
              d ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c')

Next tactic:
simp [lt_nmul_iff₃']
theorem nmul_assoc : ∀ a b c, a ⨳ b ⨳ c = a ⨳ (b ⨳ c)
  | a, b, c => by
    

Proof state:
a✝ b✝ c✝ d : Ordinal.{u}
a b c : Ordinal.{u_1}
⊢ a ⨳ b ⨳ c = a ⨳ (b ⨳ c)

Next tactic:
apply le_antisymm
theorem nmul_assoc : ∀ a b c, a ⨳ b ⨳ c = a ⨳ (b ⨳ c)
  | a, b, c => by
    apply le_antisymm
    · 

Proof state:
case a
a✝ b✝ c✝ d : Ordinal.{u}
a b c : Ordinal.{u_1}
⊢ a ⨳ b ⨳ c ≤ a ⨳ (b ⨳ c)

Next tactic:
rw [nmul_le_iff₃]
theorem nmul_assoc : ∀ a b c, a ⨳ b ⨳ c = a ⨳ (b ⨳ c)
  | a, b, c => by
    apply le_antisymm
    · rw [nmul_le_iff₃]
      

Proof state:
case a
a✝ b✝ c✝ d : Ordinal.{u}
a b c : Ordinal.{u_1}
⊢ ∀ a' < a,
    ∀ b' < b,
      ∀ c' < c,
        a' ⨳ b ⨳ c ♯ a ⨳ b' ⨳ c ♯ a ⨳ b ⨳ c' ♯ a' ⨳ b' ⨳ c' < a ⨳ (b ⨳ c) ♯ a' ⨳ b' ⨳ c ♯ a' ⨳ b ⨳ c' ♯ a ⨳ b' ⨳ c'

Next tactic:
intro a' ha b' hb c' hc
theorem nmul_assoc : ∀ a b c, a ⨳ b ⨳ c = a ⨳ (b ⨳ c)
  | a, b, c => by
    apply le_antisymm
    · rw [nmul_le_iff₃]
      intro a' ha b' hb c' hc
      -- Porting note: the next line was just
      -- repeat' rw [nmul_assoc]
      -- but we need to spell out the arguments for the termination checker.
      

Proof state:
case a
a✝ b✝ c✝ d : Ordinal.{u}
a b c a' : Ordinal.{u_1}
ha : a' < a
b' : Ordinal.{u_1}
hb : b' < b
c' : Ordinal.{u_1}
hc : c' < c
⊢ a' ⨳ b ⨳ c ♯ a ⨳ b' ⨳ c ♯ a ⨳ b ⨳ c' ♯ a' ⨳ b' ⨳ c' < a ⨳ (b ⨳ c) ♯ a' ⨳ b' ⨳ c ♯ a' ⨳ b ⨳ c' ♯ a ⨳ b' ⨳ c'

Next tactic:
rw [nmul_assoc a' b c, nmul_assoc a b' c, nmul_assoc a b c', nmul_assoc a' b' c',
        nmul_assoc a' b' c, nmul_assoc a' b c', nmul_assoc a b' c']
theorem nmul_assoc : ∀ a b c, a ⨳ b ⨳ c = a ⨳ (b ⨳ c)
  | a, b, c => by
    apply le_antisymm
    · rw [nmul_le_iff₃]
      intro a' ha b' hb c' hc
      -- Porting note: the next line was just
      -- repeat' rw [nmul_assoc]
      -- but we need to spell out the arguments for the termination checker.
      rw [nmul_assoc a' b c, nmul_assoc a b' c, nmul_assoc a b c', nmul_assoc a' b' c',
        nmul_assoc a' b' c, nmul_assoc a' b c', nmul_assoc a b' c']
      

Proof state:
case a
a✝ b✝ c✝ d : Ordinal.{u}
a b c a' : Ordinal.{u_1}
ha : a' < a
b' : Ordinal.{u_1}
hb : b' < b
c' : Ordinal.{u_1}
hc : c' < c
⊢ a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') <
    a ⨳ (b ⨳ c) ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c')

Next tactic:
exact nmul_nadd_lt₃' ha hb hc
theorem nmul_assoc : ∀ a b c, a ⨳ b ⨳ c = a ⨳ (b ⨳ c)
  | a, b, c => by
    apply le_antisymm
    · rw [nmul_le_iff₃]
      intro a' ha b' hb c' hc
      -- Porting note: the next line was just
      -- repeat' rw [nmul_assoc]
      -- but we need to spell out the arguments for the termination checker.
      rw [nmul_assoc a' b c, nmul_assoc a b' c, nmul_assoc a b c', nmul_assoc a' b' c',
        nmul_assoc a' b' c, nmul_assoc a' b c', nmul_assoc a b' c']
      exact nmul_nadd_lt₃' ha hb hc
    · 

Proof state:
case a
a✝ b✝ c✝ d : Ordinal.{u}
a b c : Ordinal.{u_1}
⊢ a ⨳ (b ⨳ c) ≤ a ⨳ b ⨳ c

Next tactic:
rw [nmul_le_iff₃']
theorem nmul_assoc : ∀ a b c, a ⨳ b ⨳ c = a ⨳ (b ⨳ c)
  | a, b, c => by
    apply le_antisymm
    · rw [nmul_le_iff₃]
      intro a' ha b' hb c' hc
      -- Porting note: the next line was just
      -- repeat' rw [nmul_assoc]
      -- but we need to spell out the arguments for the termination checker.
      rw [nmul_assoc a' b c, nmul_assoc a b' c, nmul_assoc a b c', nmul_assoc a' b' c',
        nmul_assoc a' b' c, nmul_assoc a' b c', nmul_assoc a b' c']
      exact nmul_nadd_lt₃' ha hb hc
    · rw [nmul_le_iff₃']
      

Proof state:
case a
a✝ b✝ c✝ d : Ordinal.{u}
a b c : Ordinal.{u_1}
⊢ ∀ a' < a,
    ∀ b' < b,
      ∀ c' < c,
        a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') <
          a ⨳ b ⨳ c ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c')

Next tactic:
intro a' ha b' hb c' hc
theorem nmul_assoc : ∀ a b c, a ⨳ b ⨳ c = a ⨳ (b ⨳ c)
  | a, b, c => by
    apply le_antisymm
    · rw [nmul_le_iff₃]
      intro a' ha b' hb c' hc
      -- Porting note: the next line was just
      -- repeat' rw [nmul_assoc]
      -- but we need to spell out the arguments for the termination checker.
      rw [nmul_assoc a' b c, nmul_assoc a b' c, nmul_assoc a b c', nmul_assoc a' b' c',
        nmul_assoc a' b' c, nmul_assoc a' b c', nmul_assoc a b' c']
      exact nmul_nadd_lt₃' ha hb hc
    · rw [nmul_le_iff₃']
      intro a' ha b' hb c' hc
      -- Porting note: the next line was just
      -- repeat' rw [← nmul_assoc]
      -- but we need to spell out the arguments for the termination checker.
      

Proof state:
case a
a✝ b✝ c✝ d : Ordinal.{u}
a b c a' : Ordinal.{u_1}
ha : a' < a
b' : Ordinal.{u_1}
hb : b' < b
c' : Ordinal.{u_1}
hc : c' < c
⊢ a' ⨳ (b ⨳ c) ♯ a ⨳ (b' ⨳ c) ♯ a ⨳ (b ⨳ c') ♯ a' ⨳ (b' ⨳ c') <
    a ⨳ b ⨳ c ♯ a' ⨳ (b' ⨳ c) ♯ a' ⨳ (b ⨳ c') ♯ a ⨳ (b' ⨳ c')

Next tactic:
rw [← nmul_assoc a' b c, ← nmul_assoc a b' c, ← nmul_assoc a b c', ← nmul_assoc a' b' c',
        ← nmul_assoc a' b' c, ← nmul_assoc a' b c', ← nmul_assoc a b' c']
theorem nmul_assoc : ∀ a b c, a ⨳ b ⨳ c = a ⨳ (b ⨳ c)
  | a, b, c => by
    apply le_antisymm
    · rw [nmul_le_iff₃]
      intro a' ha b' hb c' hc
      -- Porting note: the next line was just
      -- repeat' rw [nmul_assoc]
      -- but we need to spell out the arguments for the termination checker.
      rw [nmul_assoc a' b c, nmul_assoc a b' c, nmul_assoc a b c', nmul_assoc a' b' c',
        nmul_assoc a' b' c, nmul_assoc a' b c', nmul_assoc a b' c']
      exact nmul_nadd_lt₃' ha hb hc
    · rw [nmul_le_iff₃']
      intro a' ha b' hb c' hc
      -- Porting note: the next line was just
      -- repeat' rw [← nmul_assoc]
      -- but we need to spell out the arguments for the termination checker.
      rw [← nmul_assoc a' b c, ← nmul_assoc a b' c, ← nmul_assoc a b c', ← nmul_assoc a' b' c',
        ← nmul_assoc a' b' c, ← nmul_assoc a' b c', ← nmul_assoc a b' c']
      

Proof state:
case a
a✝ b✝ c✝ d : Ordinal.{u}
a b c a' : Ordinal.{u_1}
ha : a' < a
b' : Ordinal.{u_1}
hb : b' < b
c' : Ordinal.{u_1}
hc : c' < c
⊢ a' ⨳ b ⨳ c ♯ a ⨳ b' ⨳ c ♯ a ⨳ b ⨳ c' ♯ a' ⨳ b' ⨳ c' < a ⨳ b ⨳ c ♯ a' ⨳ b' ⨳ c ♯ a' ⨳ b ⨳ c' ♯ a ⨳ b' ⨳ c'

Next tactic:
exact nmul_nadd_lt₃ ha hb hc
theorem nmul_succ (a b) : a ⨳ succ b = a ⨳ b ♯ a := by 

Proof state:
a b : Ordinal.{u_1}
⊢ a ⨳ succ b = a ⨳ b ♯ a

Next tactic:
rw [← nadd_one, nmul_nadd_one]
theorem succ_nmul (a b) : succ a ⨳ b = a ⨳ b ♯ b := by 

Proof state:
a b : Ordinal.{u_1}
⊢ succ a ⨳ b = a ⨳ b ♯ b

Next tactic:
rw [← nadd_one, nadd_one_nmul]
theorem mul_le_nmul (a b : Ordinal.{u}) : a * b ≤ a ⨳ b := by
  

Proof state:
a b : Ordinal.{u}
⊢ a * b ≤ a ⨳ b

Next tactic:
refine b.limitRecOn ?_ ?_ ?_
theorem mul_le_nmul (a b : Ordinal.{u}) : a * b ≤ a ⨳ b := by
  refine b.limitRecOn ?_ ?_ ?_
  · 

Proof state:
case refine_1
a b : Ordinal.{u}
⊢ a * 0 ≤ a ⨳ 0

Next tactic:
simp
theorem mul_le_nmul (a b : Ordinal.{u}) : a * b ≤ a ⨳ b := by
  refine b.limitRecOn ?_ ?_ ?_
  · simp
  · 

Proof state:
case refine_2
a b : Ordinal.{u}
⊢ ∀ (o : Ordinal.{u}), a * o ≤ a ⨳ o → a * succ o ≤ a ⨳ succ o

Next tactic:
intro c h
theorem mul_le_nmul (a b : Ordinal.{u}) : a * b ≤ a ⨳ b := by
  refine b.limitRecOn ?_ ?_ ?_
  · simp
  · intro c h
    

Proof state:
case refine_2
a b c : Ordinal.{u}
h : a * c ≤ a ⨳ c
⊢ a * succ c ≤ a ⨳ succ c

Next tactic:
rw [mul_succ, nmul_succ]
theorem mul_le_nmul (a b : Ordinal.{u}) : a * b ≤ a ⨳ b := by
  refine b.limitRecOn ?_ ?_ ?_
  · simp
  · intro c h
    rw [mul_succ, nmul_succ]
    

Proof state:
case refine_2
a b c : Ordinal.{u}
h : a * c ≤ a ⨳ c
⊢ a * c + a ≤ a ⨳ c ♯ a

Next tactic:
exact (add_le_nadd _ a).trans (nadd_le_nadd_right h a)
theorem mul_le_nmul (a b : Ordinal.{u}) : a * b ≤ a ⨳ b := by
  refine b.limitRecOn ?_ ?_ ?_
  · simp
  · intro c h
    rw [mul_succ, nmul_succ]
    exact (add_le_nadd _ a).trans (nadd_le_nadd_right h a)
  · 

Proof state:
case refine_3
a b : Ordinal.{u}
⊢ ∀ (o : Ordinal.{u}), IsLimit o → (∀ o' < o, a * o' ≤ a ⨳ o') → a * o ≤ a ⨳ o

Next tactic:
intro c hc H
theorem mul_le_nmul (a b : Ordinal.{u}) : a * b ≤ a ⨳ b := by
  refine b.limitRecOn ?_ ?_ ?_
  · simp
  · intro c h
    rw [mul_succ, nmul_succ]
    exact (add_le_nadd _ a).trans (nadd_le_nadd_right h a)
  · intro c hc H
    

Proof state:
case refine_3
a b c : Ordinal.{u}
hc : IsLimit c
H : ∀ o' < c, a * o' ≤ a ⨳ o'
⊢ a * c ≤ a ⨳ c

Next tactic:
rcases eq_zero_or_pos a with (rfl | ha)