Theorem: LRAT.DefaultFormula.mem_of_insertRatUnits
Proof state before:
case isTrue
n : Nat
f : DefaultFormula n
units : List (Literal (PosFin n))
c : DefaultClause n
h :
  some c ∈ f.clauses.data ∨
    (∃ a,
        (a, false) ∈ f.rupUnits.data ∧ LRAT.DefaultClause.unit (a, false) = c ∨
          (a, true) ∈ f.rupUnits.data ∧ LRAT.DefaultClause.unit (a, true) = c) ∨
      ∃ a,
        (a, false) ∈ (List.foldl insertUnit (f.ratUnits, f.assignments, false) units).fst.data ∧
            LRAT.DefaultClause.unit (a, false) = c ∨
          (a, true) ∈ (List.foldl insertUnit (f.ratUnits, f.assignments, false) units).fst.data ∧
            LRAT.DefaultClause.unit (a, true) = c
hb : ∀ (l : Literal (PosFin n)), l ∈ (f.ratUnits, f.assignments, false).fst.data → l ∈ f.ratUnits.data ∨ l ∈ units
acc : Array (Literal (PosFin n)) × Array Assignment × Bool
ih : ∀ (l : Literal (PosFin n)), l ∈ acc.fst.data → l ∈ f.ratUnits.data ∨ l ∈ units
unit : Literal (PosFin n)
unit_in_units : unit ∈ units
l : Literal (PosFin n)
h✝ : hasAssignment unit.snd acc.2.fst[unit.fst.val]! = true
hl : l ∈ acc.fst.data
⊢ l ∈ f.ratUnits.data ∨ l ∈ units

case isFalse
n : Nat
f : DefaultFormula n
units : List (Literal (PosFin n))
c : DefaultClause n
h :
  some c ∈ f.clauses.data ∨
    (∃ a,
        (a, false) ∈ f.rupUnits.data ∧ LRAT.DefaultClause.unit (a, false) = c ∨
          (a, true) ∈ f.rupUnits.data ∧ LRAT.DefaultClause.unit (a, true) = c) ∨
      ∃ a,
        (a, false) ∈ (List.foldl insertUnit (f.ratUnits, f.assignments, false) units).fst.data ∧
            LRAT.DefaultClause.unit (a, false) = c ∨
          (a, true) ∈ (List.foldl insertUnit (f.ratUnits, f.assignments, false) units).fst.data ∧
            LRAT.DefaultClause.unit (a, true) = c
hb : ∀ (l : Literal (PosFin n)), l ∈ (f.ratUnits, f.assignments, false).fst.data → l ∈ f.ratUnits.data ∨ l ∈ units
acc : Array (Literal (PosFin n)) × Array Assignment × Bool
ih : ∀ (l : Literal (PosFin n)), l ∈ acc.fst.data → l ∈ f.ratUnits.data ∨ l ∈ units
unit : Literal (PosFin n)
unit_in_units : unit ∈ units
l : Literal (PosFin n)
h✝ : ¬hasAssignment unit.snd acc.2.fst[unit.fst.val]! = true
hl :
  l ∈
    (acc.fst.push unit, acc.2.fst.modify unit.fst.val (addAssignment unit.snd),
          acc.2.snd || acc.2.fst[unit.fst.val]! != unassigned).fst.data
⊢ l ∈ f.ratUnits.data ∨ l ∈ units
Tactic:
. exact ih l hl
Proof state after:
case isFalse
n : Nat
f : DefaultFormula n
units : List (Literal (PosFin n))
c : DefaultClause n
h :
  some c ∈ f.clauses.data ∨
    (∃ a,
        (a, false) ∈ f.rupUnits.data ∧ LRAT.DefaultClause.unit (a, false) = c ∨
          (a, true) ∈ f.rupUnits.data ∧ LRAT.DefaultClause.unit (a, true) = c) ∨
      ∃ a,
        (a, false) ∈ (List.foldl insertUnit (f.ratUnits, f.assignments, false) units).fst.data ∧
            LRAT.DefaultClause.unit (a, false) = c ∨
          (a, true) ∈ (List.foldl insertUnit (f.ratUnits, f.assignments, false) units).fst.data ∧
            LRAT.DefaultClause.unit (a, true) = c
hb : ∀ (l : Literal (PosFin n)), l ∈ (f.ratUnits, f.assignments, false).fst.data → l ∈ f.ratUnits.data ∨ l ∈ units
acc : Array (Literal (PosFin n)) × Array Assignment × Bool
ih : ∀ (l : Literal (PosFin n)), l ∈ acc.fst.data → l ∈ f.ratUnits.data ∨ l ∈ units
unit : Literal (PosFin n)
unit_in_units : unit ∈ units
l : Literal (PosFin n)
h✝ : ¬hasAssignment unit.snd acc.2.fst[unit.fst.val]! = true
hl :
  l ∈
    (acc.fst.push unit, acc.2.fst.modify unit.fst.val (addAssignment unit.snd),
          acc.2.snd || acc.2.fst[unit.fst.val]! != unassigned).fst.data
⊢ l ∈ f.ratUnits.data ∨ l ∈ units