File: Mathlib/SetTheory/Game/Birthday.lean

full_name: SetTheory.PGame.birthday
code: /-- The birthday of a pre-game is inductively defined as the least strict upper bound of the
birthdays of its left and right games. It may be thought as the "step" in which a certain game is
constructed. -/
noncomputable def birthday : PGame.{u} → Ordinal.{u}
  
goal: SetTheory.PGame → Ordinal.{u}

full_name: SetTheory.PGame.birthday_def
code: theorem birthday_def (x : PGame) :
    birthday x =
      max (lsub.{u, u} fun i => birthday (x.moveLeft i))
        (lsub.{u, u} fun i => birthday (x.moveRight i)) 
goal: x.birthday = max (Ordinal.lsub fun i => (x.moveLeft i).birthday) (Ordinal.lsub fun i => (x.moveRight i).birthday)

full_name: SetTheory.PGame.birthday_moveLeft_lt
code: theorem birthday_moveLeft_lt {x : PGame} (i : x.LeftMoves) :
    (x.moveLeft i).birthday < x.birthday 
goal: (x.moveLeft i).birthday < x.birthday

full_name: SetTheory.PGame.birthday_moveRight_lt
code: theorem birthday_moveRight_lt {x : PGame} (i : x.RightMoves) :
    (x.moveRight i).birthday < x.birthday 
goal: (x.moveRight i).birthday < x.birthday

full_name: SetTheory.PGame.lt_birthday_iff
code: theorem lt_birthday_iff {x : PGame} {o : Ordinal} :
    o < x.birthday ↔
      (∃ i : x.LeftMoves, o ≤ (x.moveLeft i).birthday) ∨
        ∃ i : x.RightMoves, o ≤ (x.moveRight i).birthday 
goal: o < x.birthday ↔ (∃ i, o ≤ (x.moveLeft i).birthday) ∨ ∃ i, o ≤ (x.moveRight i).birthday

full_name: SetTheory.PGame.Relabelling.birthday_congr
code: theorem Relabelling.birthday_congr : ∀ {x y : PGame.{u}}, x ≡r y → birthday x = birthday y
  
goal: x.Relabelling y → x.birthday = y.birthday

full_name: SetTheory.PGame.birthday_eq_zero
code: @[simp]
theorem birthday_eq_zero {x : PGame} :
    birthday x = 0 ↔ IsEmpty x.LeftMoves ∧ IsEmpty x.RightMoves 
goal: x.birthday = 0 ↔ IsEmpty x.LeftMoves ∧ IsEmpty x.RightMoves

full_name: SetTheory.PGame.birthday_zero
code: @[simp]
theorem birthday_zero : birthday 0 = 0 
goal: SetTheory.PGame.birthday 0 = 0

full_name: SetTheory.PGame.birthday_one
code: @[simp]
theorem birthday_one : birthday 1 = 1 
goal: SetTheory.PGame.birthday 1 = 1

full_name: SetTheory.PGame.birthday_star
code: @[simp]
theorem birthday_star : birthday star = 1 
goal: SetTheory.PGame.star.birthday = 1

full_name: SetTheory.PGame.neg_birthday
code: @[simp]
theorem neg_birthday : ∀ x : PGame, (-x).birthday = x.birthday
  
goal: (-x).birthday = x.birthday

full_name: SetTheory.PGame.toPGame_birthday
code: @[simp]
theorem toPGame_birthday (o : Ordinal) : o.toPGame.birthday = o 
goal: o.toPGame.birthday = o

full_name: SetTheory.PGame.le_birthday
code: theorem le_birthday : ∀ x : PGame, x ≤ x.birthday.toPGame
  
goal: x ≤ x.birthday.toPGame

full_name: SetTheory.PGame.neg_birthday_le
code: theorem neg_birthday_le : -x.birthday.toPGame ≤ x 
goal: -x.birthday.toPGame ≤ x

full_name: SetTheory.PGame.birthday_add
code: @[simp]
theorem birthday_add : ∀ x y : PGame.{u}, (x + y).birthday = x.birthday ♯ y.birthday
  
goal: (x + y).birthday = x.birthday.nadd y.birthday

full_name: SetTheory.PGame.birthday_add_zero
code: theorem birthday_add_zero : (a + 0).birthday = a.birthday 
goal: (a + 0).birthday = a.birthday

full_name: SetTheory.PGame.birthday_zero_add
code: theorem birthday_zero_add : (0 + a).birthday = a.birthday 
goal: (0 + a).birthday = a.birthday

full_name: SetTheory.PGame.birthday_add_one
code: theorem birthday_add_one : (a + 1).birthday = Order.succ a.birthday 
goal: (a + 1).birthday = Order.succ a.birthday

full_name: SetTheory.PGame.birthday_one_add
code: theorem birthday_one_add : (1 + a).birthday = Order.succ a.birthday 
goal: (1 + a).birthday = Order.succ a.birthday

full_name: SetTheory.PGame.birthday_natCast
code: @[simp]
theorem birthday_natCast : ∀ n : ℕ, birthday n = n
  
goal: (↑n).birthday = ↑n

full_name: SetTheory.PGame.birthday_add_nat
code: theorem birthday_add_nat (n : ℕ) : (a + n).birthday = a.birthday + n 
goal: (a + ↑n).birthday = a.birthday + ↑n

full_name: SetTheory.PGame.birthday_nat_add
code: theorem birthday_nat_add (n : ℕ) : (↑n + a).birthday = a.birthday + n 
goal: (↑n + a).birthday = a.birthday + ↑n