Theorem: LRAT.DefaultFormula.restoreAssignments_performRupCheck
Proof state before:
case intro.h₂.inl.intro
n : Nat
f : DefaultFormula n
f_assignments_size : f.assignments.size = n
rupHints : Array Nat
f' : DefaultFormula n := (f.performRupCheck rupHints).fst
f'_def : f' = (f.performRupCheck rupHints).fst
f'_assignments_size : f'.assignments.size = n
derivedLits : List (Literal (PosFin n))
derivedLits_satisfies_invariant :
  f.derivedLits_invariant f_assignments_size (f.performRupCheck rupHints).fst.assignments f'_assignments_size
    derivedLits
derivedLits_arr : Array (Literal (PosFin n)) := { data := derivedLits }
derivedLits_arr_def : derivedLits_arr = { data := derivedLits }
derivedLits_arr_nodup : ∀ (i j : Fin derivedLits_arr.size), i ≠ j → derivedLits_arr[i] ≠ derivedLits_arr[j]
motive : Nat → Array Assignment → Prop := f.clear_insert_induction_motive f_assignments_size derivedLits_arr
h_base : f.clear_insert_induction_motive f_assignments_size derivedLits_arr 0 f'.assignments
h_inductive :
  ∀ (idx : Fin derivedLits_arr.size) (assignments : Array Assignment),
    motive (↑idx) assignments →
      f.clear_insert_induction_motive f_assignments_size derivedLits_arr (↑idx + 1)
        (clearUnit assignments derivedLits_arr[idx])
h_size : (Array.foldl (fun b => clearUnit b) f'.assignments derivedLits_arr 0).size = n
i : Nat
hi1 : i < (Array.foldl clearUnit f'.assignments { data := derivedLits } 0).size
hi2✝ : i < f.assignments.size
hi2 : i < n
h1 : (Array.foldl (fun b => clearUnit b) f'.assignments derivedLits_arr 0)[↑⟨i, hi2⟩] = f.assignments[↑⟨i, hi2⟩]
right✝ : ∀ (j : Fin derivedLits_arr.size), ↑j ≥ derivedLits_arr.size → derivedLits_arr[j].fst.val ≠ ↑⟨i, hi2⟩
⊢ (Array.foldl clearUnit f'.assignments { data := derivedLits } 0)[i] = f.assignments[i]
Tactic:
simp only [← derivedLits_arr_def]
Proof state after:
case intro.h₂.inl.intro
n : Nat
f : DefaultFormula n
f_assignments_size : f.assignments.size = n
rupHints : Array Nat
f' : DefaultFormula n := (f.performRupCheck rupHints).fst
f'_def : f' = (f.performRupCheck rupHints).fst
f'_assignments_size : f'.assignments.size = n
derivedLits : List (Literal (PosFin n))
derivedLits_satisfies_invariant :
  f.derivedLits_invariant f_assignments_size (f.performRupCheck rupHints).fst.assignments f'_assignments_size
    derivedLits
derivedLits_arr : Array (Literal (PosFin n)) := { data := derivedLits }
derivedLits_arr_def : derivedLits_arr = { data := derivedLits }
derivedLits_arr_nodup : ∀ (i j : Fin derivedLits_arr.size), i ≠ j → derivedLits_arr[i] ≠ derivedLits_arr[j]
motive : Nat → Array Assignment → Prop := f.clear_insert_induction_motive f_assignments_size derivedLits_arr
h_base : f.clear_insert_induction_motive f_assignments_size derivedLits_arr 0 f'.assignments
h_inductive :
  ∀ (idx : Fin derivedLits_arr.size) (assignments : Array Assignment),
    motive (↑idx) assignments →
      f.clear_insert_induction_motive f_assignments_size derivedLits_arr (↑idx + 1)
        (clearUnit assignments derivedLits_arr[idx])
h_size : (Array.foldl (fun b => clearUnit b) f'.assignments derivedLits_arr 0).size = n
i : Nat
hi1 : i < (Array.foldl clearUnit f'.assignments { data := derivedLits } 0).size
hi2✝ : i < f.assignments.size
hi2 : i < n
h1 : (Array.foldl (fun b => clearUnit b) f'.assignments derivedLits_arr 0)[↑⟨i, hi2⟩] = f.assignments[↑⟨i, hi2⟩]
right✝ : ∀ (j : Fin derivedLits_arr.size), ↑j ≥ derivedLits_arr.size → derivedLits_arr[j].fst.val ≠ ↑⟨i, hi2⟩
⊢ (Array.foldl clearUnit f'.assignments { data := derivedLits } 0 derivedLits_arr.size)[i] = f.assignments[i]