ruc-ai4math/mathlib_handler_benchmark_410 huggingface dataset:
-- BitVec.getLsb_rotateRight
@[simp]
theorem getLsb_rotateRight {x : BitVec w} {r i : Nat} :
    (x.rotateRight r).getLsb i =
      cond (i < w - (r % w))
      (x.getLsb ((r % w) + i))
      (decide (i < w) && x.getLsb (i - (w - (r % w)))) 
Arguments: {w : Nat} {x : BitVec w} {r i : Nat}
Goal: (x.rotateRight r).getLsb i =
  bif decide (i < w - r % w) then x.getLsb (r % w + i) else decide (i < w) && x.getLsb (i - (w - r % w))
-- BitVec.toNat_twoPow
@[simp, bv_toNat]
theorem toNat_twoPow (w : Nat) (i : Nat) : (twoPow w i).toNat = 2^i % 2^w 
Arguments: (w i : Nat)
Goal: (BitVec.twoPow w i).toNat = 2 ^ i % 2 ^ w
-- BitVec.getLsb_twoPow
@[simp]
theorem getLsb_twoPow (i j : Nat) : (twoPow w i).getLsb j = ((i < w) && (i = j)) 
Arguments: {w : Nat} (i j : Nat)
Goal: (BitVec.twoPow w i).getLsb j = (decide (i < w) && decide (i = j))
-- BitVec.and_twoPow_eq
theorem and_twoPow_eq (x : BitVec w) (i : Nat) :
    x &&& (twoPow w i) = if x.getLsb i then twoPow w i else 0#w 
Arguments: {w : Nat} (x : BitVec w) (i : Nat)
Goal: x &&& BitVec.twoPow w i = if x.getLsb i = true then BitVec.twoPow w i else 0#w
-- BitVec.mul_twoPow_eq_shiftLeft
@[simp]
theorem mul_twoPow_eq_shiftLeft (x : BitVec w) (i : Nat) :
    x * (twoPow w i) = x <<< i 
Arguments: {w : Nat} (x : BitVec w) (i : Nat)
Goal: x * BitVec.twoPow w i = x <<< i
-- Lean.Compiler.LCNF.Phase.le_refl
@[simp] theorem Phase.le_refl (p : Phase) : p ≤ p 
Arguments: (p : Lean.Compiler.LCNF.Phase)
Goal: p ≤ p
-- Lean.Compiler.LCNF.Pass.phaseInv
structure Pass where
    occurrence : Nat := 0
    phase : Phase
    phaseOut : Phase := phase
  phaseInv : phaseOut ≥ phase := by simp_arith
    name : Name
    run : Array Decl → CompilerM (Array Decl)
Arguments: (self : Lean.Compiler.LCNF.Pass)
Goal: self.phaseOut ≥ self.phase
-- Array.singleton_def
@[simp] theorem singleton_def (v : α) : singleton v = #[v] 
Arguments: {α : Type u_1} (v : α)
Goal: Array.singleton v = #[v]
-- Array.toArray_data
@[simp] theorem toArray_data : (a : Array α) → a.data.toArray = a
  
Arguments: {α : Type u_1} (a : Array α)
Goal: List.toArray a.data = a
-- Array.data_length
@[simp] theorem data_length {l : Array α} : l.data.length = l.size 
Arguments: {α : Type u_1} {l : Array α}
Goal: l.data.length = l.size
-- Array.mkEmpty_eq
@[simp] theorem mkEmpty_eq (α n) : @mkEmpty α n = #[] 
Arguments: (α : Type u_1) (n : Nat)
Goal: Array.mkEmpty n = #[]
-- Array.size_toArray
@[simp] theorem size_toArray (as : List α) : as.toArray.size = as.length 
Arguments: {α : Type u_1} (as : List α)
Goal: (List.toArray as).size = as.length
-- Array.size_mk
@[simp] theorem size_mk (as : List α) : (Array.mk as).size = as.length 
Arguments: {α : Type u_1} (as : List α)
Goal: { data := as }.size = as.length
-- Array.getElem_eq_data_getElem
theorem getElem_eq_data_getElem (a : Array α) (h : i < a.size) : a[i] = a.data[i] 
Arguments: {α : Type u_1} {i : Nat} (a : Array α) (h : i < a.size)
Goal: a[i] = a.data[i]
-- Array.getElem_eq_data_get
@[deprecated getElem_eq_data_getElem (since := "2024-06-12")]
theorem getElem_eq_data_get (a : Array α) (h : i < a.size) : a[i] = a.data.get ⟨i, h⟩ 
Arguments: {α : Type u_1} {i : Nat} (a : Array α) (h : i < a.size)
Goal: a[i] = a.data.get ⟨i, h⟩
-- Array.foldlM_eq_foldlM_data.aux
theorem foldlM_eq_foldlM_data.aux [Monad m]
    (f : β → α → m β) (arr : Array α) (i j) (H : arr.size ≤ i + j) (b) :
    foldlM.loop f arr arr.size (Nat.le_refl _) i j b = (arr.data.drop j).foldlM f b 
Arguments: {m : Type u_1 → Type u_2} {β : Type u_1} {α : Type u_3} [Monad m] (f : β → α → m β) (arr : Array α) (i j : Nat) (H : arr.size ≤ i + j) (b : β)
Goal: Array.foldlM.loop f arr arr.size ⋯ i j b = List.foldlM f b (List.drop j arr.data)
-- Array.foldlM_eq_foldlM_data
theorem foldlM_eq_foldlM_data [Monad m]
    (f : β → α → m β) (init : β) (arr : Array α) :
    arr.foldlM f init = arr.data.foldlM f init 
Arguments: {m : Type u_1 → Type u_2} {β : Type u_1} {α : Type u_3} [Monad m] (f : β → α → m β) (init : β) (arr : Array α)
Goal: Array.foldlM f init arr 0 = List.foldlM f init arr.data
-- Array.foldl_eq_foldl_data
theorem foldl_eq_foldl_data (f : β → α → β) (init : β) (arr : Array α) :
    arr.foldl f init = arr.data.foldl f init 
Arguments: {β : Type u_1} {α : Type u_2} (f : β → α → β) (init : β) (arr : Array α)
Goal: Array.foldl f init arr 0 = List.foldl f init arr.data
-- Array.foldrM_eq_reverse_foldlM_data.aux
theorem foldrM_eq_reverse_foldlM_data.aux [Monad m]
    (f : α → β → m β) (arr : Array α) (init : β) (i h) :
    (arr.data.take i).reverse.foldlM (fun x y => f y x) init = foldrM.fold f arr 0 i h init 
Arguments: {m : Type u_1 → Type u_2} {α : Type u_3} {β : Type u_1} [Monad m] (f : α → β → m β) (arr : Array α) (init : β) (i : Nat) (h : i ≤ arr.size)
Goal: List.foldlM (fun x y => f y x) init (List.take i arr.data).reverse = Array.foldrM.fold f arr 0 i h init
-- Array.foldrM_eq_reverse_foldlM_data
theorem foldrM_eq_reverse_foldlM_data [Monad m] (f : α → β → m β) (init : β) (arr : Array α) :
    arr.foldrM f init = arr.data.reverse.foldlM (fun x y => f y x) init 
Arguments: {m : Type u_1 → Type u_2} {α : Type u_3} {β : Type u_1} [Monad m] (f : α → β → m β) (init : β) (arr : Array α)
Goal: Array.foldrM f init arr arr.size = List.foldlM (fun x y => f y x) init arr.data.reverse
-- Array.foldrM_eq_foldrM_data
theorem foldrM_eq_foldrM_data [Monad m]
    (f : α → β → m β) (init : β) (arr : Array α) :
    arr.foldrM f init = arr.data.foldrM f init 
Arguments: {m : Type u_1 → Type u_2} {α : Type u_3} {β : Type u_1} [Monad m] (f : α → β → m β) (init : β) (arr : Array α)
Goal: Array.foldrM f init arr arr.size = List.foldrM f init arr.data
-- Array.foldr_eq_foldr_data
theorem foldr_eq_foldr_data (f : α → β → β) (init : β) (arr : Array α) :
    arr.foldr f init = arr.data.foldr f init 
Arguments: {α : Type u_1} {β : Type u_2} (f : α → β → β) (init : β) (arr : Array α)
Goal: Array.foldr f init arr arr.size = List.foldr f init arr.data
-- Array.push_data
@[simp] theorem push_data (arr : Array α) (a : α) : (arr.push a).data = arr.data ++ [a] 
Arguments: {α : Type u_1} (arr : Array α) (a : α)
Goal: (arr.push a).data = arr.data ++ [a]
-- Array.foldrM_push
theorem foldrM_push [Monad m] (f : α → β → m β) (init : β) (arr : Array α) (a : α) :
    (arr.push a).foldrM f init = f a init >>= arr.foldrM f 
Arguments: {m : Type u_1 → Type u_2} {α : Type u_3} {β : Type u_1} [Monad m] (f : α → β → m β) (init : β) (arr : Array α) (a : α)
Goal: Array.foldrM f init (arr.push a) (arr.push a).size = do
  let init ← f a init
  Array.foldrM f init arr arr.size
-- Array.foldrM_push'
@[simp] theorem foldrM_push' [Monad m] (f : α → β → m β) (init : β) (arr : Array α) (a : α) :
    (arr.push a).foldrM f init (start := arr.size + 1) = f a init >>= arr.foldrM f 
Arguments: {m : Type u_1 → Type u_2} {α : Type u_3} {β : Type u_1} [Monad m] (f : α → β → m β) (init : β) (arr : Array α) (a : α)
Goal: Array.foldrM f init (arr.push a) (arr.size + 1) = do
  let init ← f a init
  Array.foldrM f init arr arr.size
-- Array.foldr_push
theorem foldr_push (f : α → β → β) (init : β) (arr : Array α) (a : α) :
    (arr.push a).foldr f init = arr.foldr f (f a init) 
Arguments: {α : Type u_1} {β : Type u_2} (f : α → β → β) (init : β) (arr : Array α) (a : α)
Goal: Array.foldr f init (arr.push a) (arr.push a).size = Array.foldr f (f a init) arr arr.size
-- Array.foldr_push'
@[simp] theorem foldr_push' (f : α → β → β) (init : β) (arr : Array α) (a : α) :
    (arr.push a).foldr f init (start := arr.size + 1) = arr.foldr f (f a init) 
Arguments: {α : Type u_1} {β : Type u_2} (f : α → β → β) (init : β) (arr : Array α) (a : α)
Goal: Array.foldr f init (arr.push a) (arr.size + 1) = Array.foldr f (f a init) arr arr.size
-- Array.toListAppend_eq
@[simp] theorem toListAppend_eq (arr : Array α) (l) : arr.toListAppend l = arr.data ++ l 
Arguments: {α : Type u_1} (arr : Array α) (l : List α)
Goal: arr.toListAppend l = arr.data ++ l
-- Array.toList_eq
@[simp] theorem toList_eq (arr : Array α) : arr.toList = arr.data 
Arguments: {α : Type u_1} (arr : Array α)
Goal: arr.toList = arr.data
-- Array.toListRev_eq
@[simp] theorem toListRev_eq (arr : Array α) : arr.toListRev = arr.data.reverse 
Arguments: {α : Type u_1} (arr : Array α)
Goal: arr.toListRev = arr.data.reverse
-- Array.get_push_lt
theorem get_push_lt (a : Array α) (x : α) (i : Nat) (h : i < a.size) :
    have : i < (a.push x).size := by simp [*, Nat.lt_succ_of_le, Nat.le_of_lt]
    (a.push x)[i] = a[i] 
Arguments: {α : Type u_1} (a : Array α) (x : α) (i : Nat) (h : i < a.size)
Goal: let_fun this := ⋯;
(a.push x)[i] = a[i]
-- Array.get_push_eq
@[simp] theorem get_push_eq (a : Array α) (x : α) : (a.push x)[a.size] = x 
Arguments: {α : Type u_1} (a : Array α) (x : α)
Goal: (a.push x)[a.size] = x
-- Array.get_push
theorem get_push (a : Array α) (x : α) (i : Nat) (h : i < (a.push x).size) :
    (a.push x)[i] = if h : i < a.size then a[i] else x 
Arguments: {α : Type u_1} (a : Array α) (x : α) (i : Nat) (h : i < (a.push x).size)
Goal: (a.push x)[i] = if h : i < a.size then a[i] else x
-- Array.mapM_eq_foldlM
theorem mapM_eq_foldlM [Monad m] [LawfulMonad m] (f : α → m β) (arr : Array α) :
    arr.mapM f = arr.foldlM (fun bs a => bs.push <$> f a) #[] 
Arguments: {m : Type u_1 → Type u_2} {α : Type u_3} {β : Type u_1} [Monad m] [LawfulMonad m] (f : α → m β) (arr : Array α)
Goal: Array.mapM f arr = Array.foldlM (fun bs a => bs.push <$> f a) #[] arr 0
-- Array.mapM_eq_foldlM.aux
theorem mapM_eq_foldlM [Monad m] [LawfulMonad m] (f : α → m β) (arr : Array α) :
    arr.mapM f = arr.foldlM (fun bs a => bs.push <$> f a) #[] 
Arguments: {m : Type u_1 → Type u_2} {α : Type u_3} {β : Type u_1} [Monad m] [LawfulMonad m] (f : α → m β) (arr : Array α) (i : Nat) (r : Array β)
Goal: Array.mapM.map f arr i r = List.foldlM (fun bs a => bs.push <$> f a) r (List.drop i arr.data)
-- Array.map_data
@[simp] theorem map_data (f : α → β) (arr : Array α) : (arr.map f).data = arr.data.map f 
Arguments: {α : Type u_1} {β : Type u_2} (f : α → β) (arr : Array α)
Goal: (Array.map f arr).data = List.map f arr.data
-- Array.size_map
@[simp] theorem size_map (f : α → β) (arr : Array α) : (arr.map f).size = arr.size 
Arguments: {α : Type u_1} {β : Type u_2} (f : α → β) (arr : Array α)
Goal: (Array.map f arr).size = arr.size
-- Array.pop_data
@[simp] theorem pop_data (arr : Array α) : arr.pop.data = arr.data.dropLast 
Arguments: {α : Type u_1} (arr : Array α)
Goal: arr.pop.data = arr.data.dropLast
-- Array.append_eq_append
@[simp] theorem append_eq_append (arr arr' : Array α) : arr.append arr' = arr ++ arr' 
Arguments: {α : Type u_1} (arr arr' : Array α)
Goal: arr.append arr' = arr ++ arr'
-- Array.append_data
@[simp] theorem append_data (arr arr' : Array α) :
    (arr ++ arr').data = arr.data ++ arr'.data 
Arguments: {α : Type u_1} (arr arr' : Array α)
Goal: (arr ++ arr').data = arr.data ++ arr'.data
-- Array.appendList_eq_append
@[simp] theorem appendList_eq_append
    (arr : Array α) (l : List α) : arr.appendList l = arr ++ l 
Arguments: {α : Type u_1} (arr : Array α) (l : List α)
Goal: arr.appendList l = arr ++ l
-- Array.appendList_data
@[simp] theorem appendList_data (arr : Array α) (l : List α) :
    (arr ++ l).data = arr.data ++ l 
Arguments: {α : Type u_1} (arr : Array α) (l : List α)
Goal: (arr ++ l).data = arr.data ++ l
-- Array.appendList_nil
@[simp] theorem appendList_nil (arr : Array α) : arr ++ ([] : List α) = arr 
Arguments: {α : Type u_1} (arr : Array α)
Goal: arr ++ [] = arr
-- Array.appendList_cons
@[simp] theorem appendList_cons (arr : Array α) (a : α) (l : List α) :
    arr ++ (a :: l) = arr.push a ++ l 
Arguments: {α : Type u_1} (arr : Array α) (a : α) (l : List α)
Goal: arr ++ a :: l = arr.push a ++ l
-- Array.foldl_data_eq_bind
theorem foldl_data_eq_bind (l : List α) (acc : Array β)
    (F : Array β → α → Array β) (G : α → List β)
    (H : ∀ acc a, (F acc a).data = acc.data ++ G a) :
    (l.foldl F acc).data = acc.data ++ l.bind G 
Arguments: {α : Type u_1} {β : Type u_2} (l : List α) (acc : Array β) (F : Array β → α → Array β) (G : α → List β) (H : ∀ (acc : Array β) (a : α), (F acc a).data = acc.data ++ G a)
Goal: (List.foldl F acc l).data = acc.data ++ l.bind G
-- Array.foldl_data_eq_map
theorem foldl_data_eq_map (l : List α) (acc : Array β) (G : α → β) :
    (l.foldl (fun acc a => acc.push (G a)) acc).data = acc.data ++ l.map G 
Arguments: {α : Type u_1} {β : Type u_2} (l : List α) (acc : Array β) (G : α → β)
Goal: (List.foldl (fun acc a => acc.push (G a)) acc l).data = acc.data ++ List.map G l
-- Array.size_uset
theorem size_uset (a : Array α) (v i h) : (uset a i v h).size = a.size 
Arguments: {α : Type u_1} (a : Array α) (v : α) (i : USize) (h : i.toNat < a.size)
Goal: (a.uset i v h).size = a.size
-- Array.anyM_eq_anyM_loop
theorem anyM_eq_anyM_loop [Monad m] (p : α → m Bool) (as : Array α) (start stop) :
    anyM p as start stop = anyM.loop p as (min stop as.size) (Nat.min_le_right ..) start 
Arguments: {m : Type → Type u_1} {α : Type u_2} [Monad m] (p : α → m Bool) (as : Array α) (start stop : Nat)
Goal: Array.anyM p as start stop = Array.anyM.loop p as (min stop as.size) ⋯ start
-- Array.anyM_stop_le_start
theorem anyM_stop_le_start [Monad m] (p : α → m Bool) (as : Array α) (start stop)
    (h : min stop as.size ≤ start) : anyM p as start stop = pure false 
Arguments: {m : Type → Type u_1} {α : Type u_2} [Monad m] (p : α → m Bool) (as : Array α) (start stop : Nat) (h : min stop as.size ≤ start)
Goal: Array.anyM p as start stop = pure false
-- Array.mem_def
theorem mem_def (a : α) (as : Array α) : a ∈ as ↔ a ∈ as.data 
Arguments: {α : Type u_1} (a : α) (as : Array α)
Goal: a ∈ as ↔ a ∈ as.data
-- Array.get_eq_getElem
@[simp] theorem get_eq_getElem (a : Array α) (i : Fin _) : a.get i = a[i.1] 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size)
Goal: a.get i = a[↑i]
-- Array.getElem?_lt
theorem getElem?_lt
    (a : Array α) {i : Nat} (h : i < a.size) : a[i]? = some (a[i]) 
Arguments: {α : Type u_1} (a : Array α) {i : Nat} (h : i < a.size)
Goal: a[i]? = some a[i]
-- Array.getElem?_ge
theorem getElem?_ge
    (a : Array α) {i : Nat} (h : i ≥ a.size) : a[i]? = none 
Arguments: {α : Type u_1} (a : Array α) {i : Nat} (h : i ≥ a.size)
Goal: a[i]? = none
-- Array.get?_eq_getElem?
@[simp] theorem get?_eq_getElem? (a : Array α) (i : Nat) : a.get? i = a[i]? 
Arguments: {α : Type u_1} (a : Array α) (i : Nat)
Goal: a.get? i = a[i]?
-- Array.getElem?_len_le
theorem getElem?_len_le (a : Array α) {i : Nat} (h : a.size ≤ i) : a[i]? = none 
Arguments: {α : Type u_1} (a : Array α) {i : Nat} (h : a.size ≤ i)
Goal: a[i]? = none
-- Array.getD_get?
theorem getD_get? (a : Array α) (i : Nat) (d : α) :
  Option.getD a[i]? d = if p : i < a.size then a[i]'p else d 
Arguments: {α : Type u_1} (a : Array α) (i : Nat) (d : α)
Goal: a[i]?.getD d = if p : i < a.size then a[i] else d
-- Array.getD_eq_get?
@[simp] theorem getD_eq_get? (a : Array α) (n d) : a.getD n d = (a[n]?).getD d 
Arguments: {α : Type u_1} (a : Array α) (n : Nat) (d : α)
Goal: a.getD n d = a[n]?.getD d
-- Array.get!_eq_getD
theorem get!_eq_getD [Inhabited α] (a : Array α) : a.get! n = a.getD n default 
Arguments: {α : Type u_1} {n : Nat} [Inhabited α] (a : Array α)
Goal: a.get! n = a.getD n default
-- Array.get!_eq_getElem?
@[simp] theorem get!_eq_getElem? [Inhabited α] (a : Array α) (i : Nat) : a.get! i = (a.get? i).getD default 
Arguments: {α : Type u_1} [Inhabited α] (a : Array α) (i : Nat)
Goal: a.get! i = (a.get? i).getD default
-- Array.getElem_set_eq
@[simp] theorem getElem_set_eq (a : Array α) (i : Fin a.size) (v : α) {j : Nat}
      (eq : i.val = j) (p : j < (a.set i v).size) :
    (a.set i v)[j]'p = v 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size) (v : α) {j : Nat} (eq : ↑i = j) (p : j < (a.set i v).size)
Goal: (a.set i v)[j] = v
-- Array.getElem_set_ne
@[simp] theorem getElem_set_ne (a : Array α) (i : Fin a.size) (v : α) {j : Nat} (pj : j < (a.set i v).size)
    (h : i.val ≠ j) : (a.set i v)[j]'pj = a[j]'(size_set a i v ▸ pj) 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size) (v : α) {j : Nat} (pj : j < (a.set i v).size) (h : ↑i ≠ j)
Goal: (a.set i v)[j] = a[j]
-- Array.getElem_set
theorem getElem_set (a : Array α) (i : Fin a.size) (v : α) (j : Nat)
    (h : j < (a.set i v).size) :
    (a.set i v)[j]'h = if i = j then v else a[j]'(size_set a i v ▸ h) 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size) (v : α) (j : Nat) (h : j < (a.set i v).size)
Goal: (a.set i v)[j] = if ↑i = j then v else a[j]
-- Array.getElem?_set_eq
@[simp] theorem getElem?_set_eq (a : Array α) (i : Fin a.size) (v : α) :
    (a.set i v)[i.1]? = v 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size) (v : α)
Goal: (a.set i v)[↑i]? = some v
-- Array.getElem?_set_ne
@[simp] theorem getElem?_set_ne (a : Array α) (i : Fin a.size) {j : Nat} (v : α)
    (ne : i.val ≠ j) : (a.set i v)[j]? = a[j]? 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size) {j : Nat} (v : α) (ne : ↑i ≠ j)
Goal: (a.set i v)[j]? = a[j]?
-- Array.set!_is_setD
@[simp] theorem set!_is_setD : @set! = @setD 
Goal: @Array.set! = @Array.setD
-- Array.size_setD
@[simp] theorem size_setD (a : Array α) (index : Nat) (val : α) :
  (Array.setD a index val).size = a.size 
Arguments: {α : Type u_1} (a : Array α) (index : Nat) (val : α)
Goal: (a.setD index val).size = a.size
-- Array.getElem_setD_eq
@[simp] theorem getElem_setD_eq (a : Array α) {i : Nat} (v : α) (h : _) :
  (setD a i v)[i]'h = v 
Arguments: {α : Type u_1} (a : Array α) {i : Nat} (v : α) (h : i < (a.setD i v).size)
Goal: (a.setD i v)[i] = v
-- Array.getElem?_setD_eq
@[simp]
theorem getElem?_setD_eq (a : Array α) {i : Nat} (p : i < a.size) (v : α) : (a.setD i v)[i]? = some v 
Arguments: {α : Type u_1} (a : Array α) {i : Nat} (p : i < a.size) (v : α)
Goal: (a.setD i v)[i]? = some v
-- Array.getD_get?_setD
@[simp] theorem getD_get?_setD (a : Array α) (i : Nat) (v d : α) :
  Option.getD (setD a i v)[i]? d = if i < a.size then v else d 
Arguments: {α : Type u_1} (a : Array α) (i : Nat) (v d : α)
Goal: (a.setD i v)[i]?.getD d = if i < a.size then v else d
-- Array.size_ofFn_go
@[simp] theorem size_ofFn_go {n} (f : Fin n → α) (i acc) :
    (ofFn.go f i acc).size = acc.size + (n - i) 
Arguments: {α : Type u_1} {n : Nat} (f : Fin n → α) (i : Nat) (acc : Array α)
Goal: (Array.ofFn.go f i acc).size = acc.size + (n - i)
-- Array.size_ofFn
@[simp] theorem size_ofFn (f : Fin n → α) : (ofFn f).size = n 
Arguments: {n : Nat} {α : Type u_1} (f : Fin n → α)
Goal: (Array.ofFn f).size = n
-- Array.getElem_ofFn_go
theorem getElem_ofFn_go (f : Fin n → α) (i) {acc k}
    (hki : k < n) (hin : i ≤ n) (hi : i = acc.size)
    (hacc : ∀ j, ∀ hj : j < acc.size, acc[j] = f ⟨j, Nat.lt_of_lt_of_le hj (hi ▸ hin)⟩) :
    haveI : acc.size + (n - acc.size) = n := Nat.add_sub_cancel' (hi ▸ hin)
    (ofFn.go f i acc)[k]'(by simp [*]) = f ⟨k, hki⟩ 
Arguments: {n : Nat} {α : Type u_1} (f : Fin n → α) (i : Nat) {acc : Array α} {k : Nat} (hki : k < n) (hin : i ≤ n) (hi : i = acc.size) (hacc : ∀ (j : Nat) (hj : j < acc.size), acc[j] = f ⟨j, ⋯⟩)
Goal: (Array.ofFn.go f i acc)[k] = f ⟨k, hki⟩
-- Array.getElem_ofFn
@[simp] theorem getElem_ofFn (f : Fin n → α) (i : Nat) (h) :
    (ofFn f)[i] = f ⟨i, size_ofFn f ▸ h⟩ 
Arguments: {n : Nat} {α : Type u_1} (f : Fin n → α) (i : Nat) (h : i < (Array.ofFn f).size)
Goal: (Array.ofFn f)[i] = f ⟨i, ⋯⟩
-- Array.mkArray_data

@[simp] theorem mkArray_data (n : Nat) (v : α) : (mkArray n v).data = List.replicate n v 
Arguments: {α : Type u_1} (n : Nat) (v : α)
Goal: (mkArray n v).data = List.replicate n v
-- Array.getElem_mkArray
@[simp] theorem getElem_mkArray (n : Nat) (v : α) (h : i < (mkArray n v).size) :
    (mkArray n v)[i] = v 
Arguments: {α : Type u_1} {i : Nat} (n : Nat) (v : α) (h : i < (mkArray n v).size)
Goal: (mkArray n v)[i] = v
-- Array.mem_data

theorem mem_data {a : α} {l : Array α} : a ∈ l.data ↔ a ∈ l 
Arguments: {α : Type u_1} {a : α} {l : Array α}
Goal: a ∈ l.data ↔ a ∈ l
-- Array.not_mem_nil
theorem not_mem_nil (a : α) : ¬ a ∈ #[] 
Arguments: {α : Type u_1} (a : α)
Goal: ¬a ∈ #[]
-- Array.getElem?_mem

theorem getElem?_mem {l : Array α} {i : Fin l.size} : l[i] ∈ l 
Arguments: {α : Type u_1} {l : Array α} {i : Fin l.size}
Goal: l[i] ∈ l
-- Array.getElem_fin_eq_data_get
theorem getElem_fin_eq_data_get (a : Array α) (i : Fin _) : a[i] = a.data.get i 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.data.length)
Goal: a[i] = a.data.get i
-- Array.ugetElem_eq_getElem
@[simp] theorem ugetElem_eq_getElem (a : Array α) {i : USize} (h : i.toNat < a.size) :
  a[i] = a[i.toNat] 
Arguments: {α : Type u_1} (a : Array α) {i : USize} (h : i.toNat < a.size)
Goal: a[i] = a[i.toNat]
-- Array.getElem?_eq_getElem
theorem getElem?_eq_getElem (a : Array α) (i : Nat) (h : i < a.size) : a[i]? = a[i] 
Arguments: {α : Type u_1} (a : Array α) (i : Nat) (h : i < a.size)
Goal: a[i]? = some a[i]
-- Array.get?_len_le
theorem get?_len_le (a : Array α) (i : Nat) (h : a.size ≤ i) : a[i]? = none 
Arguments: {α : Type u_1} (a : Array α) (i : Nat) (h : a.size ≤ i)
Goal: a[i]? = none
-- Array.getElem_mem_data
theorem getElem_mem_data (a : Array α) (h : i < a.size) : a[i] ∈ a.data 
Arguments: {α : Type u_1} {i : Nat} (a : Array α) (h : i < a.size)
Goal: a[i] ∈ a.data
-- Array.getElem?_eq_data_get?
theorem getElem?_eq_data_get? (a : Array α) (i : Nat) : a[i]? = a.data.get? i 
Arguments: {α : Type u_1} (a : Array α) (i : Nat)
Goal: a[i]? = a.data.get? i
-- Array.get?_eq_data_get?
theorem get?_eq_data_get? (a : Array α) (i : Nat) : a.get? i = a.data.get? i 
Arguments: {α : Type u_1} (a : Array α) (i : Nat)
Goal: a.get? i = a.data.get? i
-- Array.get!_eq_get?
theorem get!_eq_get? [Inhabited α] (a : Array α) : a.get! n = (a.get? n).getD default 
Arguments: {α : Type u_1} {n : Nat} [Inhabited α] (a : Array α)
Goal: a.get! n = (a.get? n).getD default
-- Array.back_eq_back?
@[simp] theorem back_eq_back? [Inhabited α] (a : Array α) : a.back = a.back?.getD default 
Arguments: {α : Type u_1} [Inhabited α] (a : Array α)
Goal: a.back = a.back?.getD default
-- Array.back?_push
@[simp] theorem back?_push (a : Array α) : (a.push x).back? = some x 
Arguments: {α : Type u_1} {x : α} (a : Array α)
Goal: (a.push x).back? = some x
-- Array.back_push
theorem back_push [Inhabited α] (a : Array α) : (a.push x).back = x 
Arguments: {α : Type u_1} {x : α} [Inhabited α] (a : Array α)
Goal: (a.push x).back = x
-- Array.get?_push_lt
theorem get?_push_lt (a : Array α) (x : α) (i : Nat) (h : i < a.size) :
    (a.push x)[i]? = some a[i] 
Arguments: {α : Type u_1} (a : Array α) (x : α) (i : Nat) (h : i < a.size)
Goal: (a.push x)[i]? = some a[i]
-- Array.get?_push_eq
theorem get?_push_eq (a : Array α) (x : α) : (a.push x)[a.size]? = some x 
Arguments: {α : Type u_1} (a : Array α) (x : α)
Goal: (a.push x)[a.size]? = some x
-- Array.get?_push
theorem get?_push {a : Array α} : (a.push x)[i]? = if i = a.size then some x else a[i]? 
Arguments: {α : Type u_1} {x : α} {i : Nat} {a : Array α}
Goal: (a.push x)[i]? = if i = a.size then some x else a[i]?
-- Array.get?_size
@[simp] theorem get?_size {a : Array α} : a[a.size]? = none 
Arguments: {α : Type u_1} {a : Array α}
Goal: a[a.size]? = none
-- Array.data_set
@[simp] theorem data_set (a : Array α) (i v) : (a.set i v).data = a.data.set i.1 v 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size) (v : α)
Goal: (a.set i v).data = a.data.set (↑i) v
-- Array.get_set_eq
theorem get_set_eq (a : Array α) (i : Fin a.size) (v : α) :
    (a.set i v)[i.1] = v 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size) (v : α)
Goal: (a.set i v)[↑i] = v
-- Array.get?_set_eq
theorem get?_set_eq (a : Array α) (i : Fin a.size) (v : α) :
    (a.set i v)[i.1]? = v 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size) (v : α)
Goal: (a.set i v)[↑i]? = some v
-- Array.get?_set_ne
@[simp] theorem get?_set_ne (a : Array α) (i : Fin a.size) {j : Nat} (v : α)
    (h : i.1 ≠ j) : (a.set i v)[j]? = a[j]? 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size) {j : Nat} (v : α) (h : ↑i ≠ j)
Goal: (a.set i v)[j]? = a[j]?
-- Array.get?_set
theorem get?_set (a : Array α) (i : Fin a.size) (j : Nat) (v : α) :
    (a.set i v)[j]? = if i.1 = j then some v else a[j]? 
Arguments: {α : Type u_1} (a : Array α) (i : Fin a.size) (j : Nat) (v : α)
Goal: (a.set i v)[j]? = if ↑i = j then some v else a[j]?