internlm/Lean-Github huggingface dataset:
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_denote_mem_prefix
Proof state before:
case hprefix.size_le
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
assign : α → Bool
aig : AIG α
distance : Nat
input : aig.RefStream w
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
start : Nat
hstart : start < aig.decls.size
⊢ { aig := aig, ref := { gate := start, hgate := hstart } }.aig.decls.size ≤
    (go aig input distance curr hcurr s).aig.decls.size
Tactic:
. intros
  apply go_le_size
Proof state after:
no goals
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_denote_mem_prefix
Proof state before:
case hprefix.idx_eq
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
assign : α → Bool
aig : AIG α
distance : Nat
input : aig.RefStream w
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
start : Nat
hstart : start < aig.decls.size
⊢ ∀ (idx : Nat) (h : idx < { aig := aig, ref := { gate := start, hgate := hstart } }.aig.decls.size),
    (go aig input distance curr hcurr s).aig.decls[idx] =
      { aig := aig, ref := { gate := start, hgate := hstart } }.aig.decls[idx]
Tactic:
intros
Proof state after:
case hprefix.idx_eq
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
assign : α → Bool
aig : AIG α
distance : Nat
input : aig.RefStream w
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
start : Nat
hstart : start < aig.decls.size
idx✝ : Nat
h✝ : idx✝ < { aig := aig, ref := { gate := start, hgate := hstart } }.aig.decls.size
⊢ (go aig input distance curr hcurr s).aig.decls[idx✝] =
    { aig := aig, ref := { gate := start, hgate := hstart } }.aig.decls[idx✝]
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_denote_mem_prefix
Proof state before:
case hprefix.idx_eq
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
assign : α → Bool
aig : AIG α
distance : Nat
input : aig.RefStream w
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
start : Nat
hstart : start < aig.decls.size
idx✝ : Nat
h✝ : idx✝ < { aig := aig, ref := { gate := start, hgate := hstart } }.aig.decls.size
⊢ (go aig input distance curr hcurr s).aig.decls[idx✝] =
    { aig := aig, ref := { gate := start, hgate := hstart } }.aig.decls[idx✝]
Tactic:
apply go_decl_eq
Proof state after:
no goals
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_denote_mem_prefix
Proof state before:
case hprefix.size_le
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
assign : α → Bool
aig : AIG α
distance : Nat
input : aig.RefStream w
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
start : Nat
hstart : start < aig.decls.size
⊢ { aig := aig, ref := { gate := start, hgate := hstart } }.aig.decls.size ≤
    (go aig input distance curr hcurr s).aig.decls.size
Tactic:
apply go_le_size
Proof state after:
no goals
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx : ¬idx < distance
⊢ idx - distance < w
Tactic:
omega
Proof state after:
no goals
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
⊢ ∀ (idx : Nat) (hidx1 : idx < w),
    curr ≤ idx →
      ⟦{ aig := (go aig input distance curr hcurr s).aig,
            ref := (go aig input distance curr hcurr s).stream.getRef idx hidx1 },
          assign⟧ =
        if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
intro idx hidx1 hidx2
Proof state after:
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
⊢ ⟦{ aig := (go aig input distance curr hcurr s).aig,
        ref := (go aig input distance curr hcurr s).stream.getRef idx hidx1 },
      assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
⊢ ⟦{ aig := (go aig input distance curr hcurr s).aig,
        ref := (go aig input distance curr hcurr s).stream.getRef idx hidx1 },
      assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
generalize hgo : go aig input distance curr hcurr s = res
Proof state after:
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
hgo : go aig input distance curr hcurr s = res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
hgo : go aig input distance curr hcurr s = res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
unfold go at hgo
Proof state after:
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
hgo :
  (if hidx : curr < w then
      if hdist : curr < distance then
        let res := aig.mkConstCached false;
        let aig_1 := res.aig;
        let zeroRef := res.ref;
        let_fun hfinal := ⋯;
        let s := s.cast hfinal;
        let input := input.cast hfinal;
        let s := s.pushRef zeroRef;
        go aig_1 input distance (curr + 1) ⋯ s
      else
        let s := s.pushRef (input.getRef (curr - distance) ⋯);
        go aig input distance (curr + 1) ⋯ s
    else
      let_fun hcurr := ⋯;
      { aig := aig, stream := hcurr ▸ s }) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
hgo :
  (if hidx : curr < w then
      if hdist : curr < distance then
        let res := aig.mkConstCached false;
        let aig_1 := res.aig;
        let zeroRef := res.ref;
        let_fun hfinal := ⋯;
        let s := s.cast hfinal;
        let input := input.cast hfinal;
        let s := s.pushRef zeroRef;
        go aig_1 input distance (curr + 1) ⋯ s
      else
        let s := s.pushRef (input.getRef (curr - distance) ⋯);
        go aig input distance (curr + 1) ⋯ s
    else
      let_fun hcurr := ⋯;
      { aig := aig, stream := hcurr ▸ s }) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
split at hgo
Proof state after:
case isTrue
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝ : curr < w
hgo :
  (if hdist : curr < distance then
      let res := aig.mkConstCached false;
      let aig_1 := res.aig;
      let zeroRef := res.ref;
      let_fun hfinal := ⋯;
      let s := s.cast hfinal;
      let input := input.cast hfinal;
      let s := s.pushRef zeroRef;
      go aig_1 input distance (curr + 1) ⋯ s
    else
      let s := s.pushRef (input.getRef (curr - distance) ⋯);
      go aig input distance (curr + 1) ⋯ s) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧

case isFalse
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝ : ¬curr < w
hgo :
  (let_fun hcurr := ⋯;
    { aig := aig, stream := hcurr ▸ s }) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
case isTrue
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝ : curr < w
hgo :
  (if hdist : curr < distance then
      let res := aig.mkConstCached false;
      let aig_1 := res.aig;
      let zeroRef := res.ref;
      let_fun hfinal := ⋯;
      let s := s.cast hfinal;
      let input := input.cast hfinal;
      let s := s.pushRef zeroRef;
      go aig_1 input distance (curr + 1) ⋯ s
    else
      let s := s.pushRef (input.getRef (curr - distance) ⋯);
      go aig input distance (curr + 1) ⋯ s) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧

case isFalse
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝ : ¬curr < w
hgo :
  (let_fun hcurr := ⋯;
    { aig := aig, stream := hcurr ▸ s }) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
. dsimp at hgo
  cases Nat.eq_or_lt_of_le hidx2 with
  | inl heq =>
    split at hgo
    . split
      . rw [← hgo]
        rw [go_getRef]
        rw [AIG.RefStream.getRef_push_ref_eq']
        . rw [go_denote_mem_prefix]
          . simp
          . simp [Ref.hgate]
        . rw [heq]
      . omega
    . split
      . omega
      . rw [← hgo]
        rw [go_getRef]
        rw [AIG.RefStream.getRef_push_ref_eq']
        . rw [go_denote_mem_prefix]
          . simp [heq]
          . simp [Ref.hgate]
        . rw [heq]
  | inr =>
    split at hgo
    . split
      . next hidx =>
        rw [← hgo]
        rw [go_eq_eval_getLsb]
        . simp [hidx]
        . omega
      . next hidx =>
        rw [← hgo]
        rw [go_eq_eval_getLsb]
        . simp only [hidx, ↓reduceDite, RefStream.getRef_cast, Ref_cast']
          rw [AIG.LawfulOperator.denote_mem_prefix (f := AIG.mkConstCached)]
        . omega
    . split
      . omega
      . next hidx =>
        rw [← hgo]
        rw [go_eq_eval_getLsb]
        . simp [hidx]
        . omega
Proof state after:
case isFalse
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝ : ¬curr < w
hgo :
  (let_fun hcurr := ⋯;
    { aig := aig, stream := hcurr ▸ s }) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
case isFalse
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝ : ¬curr < w
hgo :
  (let_fun hcurr := ⋯;
    { aig := aig, stream := hcurr ▸ s }) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
. omega
Proof state after:
no goals
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
case isTrue
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝ : curr < w
hgo :
  (if hdist : curr < distance then
      let res := aig.mkConstCached false;
      let aig_1 := res.aig;
      let zeroRef := res.ref;
      let_fun hfinal := ⋯;
      let s := s.cast hfinal;
      let input := input.cast hfinal;
      let s := s.pushRef zeroRef;
      go aig_1 input distance (curr + 1) ⋯ s
    else
      let s := s.pushRef (input.getRef (curr - distance) ⋯);
      go aig input distance (curr + 1) ⋯ s) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
dsimp at hgo
Proof state after:
case isTrue
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝ : curr < w
hgo :
  (if hdist : curr < distance then
      go (aig.mkConstCached false).aig (input.cast ⋯) distance (curr + 1) ⋯
        ((s.cast ⋯).pushRef (aig.mkConstCached false).ref)
    else go aig input distance (curr + 1) ⋯ (s.pushRef (input.getRef (curr - distance) ⋯))) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
case isTrue
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝ : curr < w
hgo :
  (if hdist : curr < distance then
      go (aig.mkConstCached false).aig (input.cast ⋯) distance (curr + 1) ⋯
        ((s.cast ⋯).pushRef (aig.mkConstCached false).ref)
    else go aig input distance (curr + 1) ⋯ (s.pushRef (input.getRef (curr - distance) ⋯))) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
cases Nat.eq_or_lt_of_le hidx2 with
| inl heq =>
  split at hgo
  . split
    . rw [← hgo]
      rw [go_getRef]
      rw [AIG.RefStream.getRef_push_ref_eq']
      . rw [go_denote_mem_prefix]
        . simp
        . simp [Ref.hgate]
      . rw [heq]
    . omega
  . split
    . omega
    . rw [← hgo]
      rw [go_getRef]
      rw [AIG.RefStream.getRef_push_ref_eq']
      . rw [go_denote_mem_prefix]
        . simp [heq]
        . simp [Ref.hgate]
      . rw [heq]
| inr =>
  split at hgo
  . split
    . next hidx =>
      rw [← hgo]
      rw [go_eq_eval_getLsb]
      . simp [hidx]
      . omega
    . next hidx =>
      rw [← hgo]
      rw [go_eq_eval_getLsb]
      . simp only [hidx, ↓reduceDite, RefStream.getRef_cast, Ref_cast']
        rw [AIG.LawfulOperator.denote_mem_prefix (f := AIG.mkConstCached)]
      . omega
  . split
    . omega
    . next hidx =>
      rw [← hgo]
      rw [go_eq_eval_getLsb]
      . simp [hidx]
      . omega
Proof state after:
no goals
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
case isTrue.inl
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝ : curr < w
hgo :
  (if hdist : curr < distance then
      go (aig.mkConstCached false).aig (input.cast ⋯) distance (curr + 1) ⋯
        ((s.cast ⋯).pushRef (aig.mkConstCached false).ref)
    else go aig input distance (curr + 1) ⋯ (s.pushRef (input.getRef (curr - distance) ⋯))) =
    res
heq : curr = idx
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
split at hgo
Proof state after:
case isTrue.inl.isTrue
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝¹ : curr < w
heq : curr = idx
h✝ : curr < distance
hgo :
  go (aig.mkConstCached false).aig (input.cast ⋯) distance (curr + 1) ⋯
      ((s.cast ⋯).pushRef (aig.mkConstCached false).ref) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧

case isTrue.inl.isFalse
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝¹ : curr < w
heq : curr = idx
h✝ : ¬curr < distance
hgo : go aig input distance (curr + 1) ⋯ (s.pushRef (input.getRef (curr - distance) ⋯)) = res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
case isTrue.inl.isTrue
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝¹ : curr < w
heq : curr = idx
h✝ : curr < distance
hgo :
  go (aig.mkConstCached false).aig (input.cast ⋯) distance (curr + 1) ⋯
      ((s.cast ⋯).pushRef (aig.mkConstCached false).ref) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧

case isTrue.inl.isFalse
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝¹ : curr < w
heq : curr = idx
h✝ : ¬curr < distance
hgo : go aig input distance (curr + 1) ⋯ (s.pushRef (input.getRef (curr - distance) ⋯)) = res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
. split
  . rw [← hgo]
    rw [go_getRef]
    rw [AIG.RefStream.getRef_push_ref_eq']
    . rw [go_denote_mem_prefix]
      . simp
      . simp [Ref.hgate]
    . rw [heq]
  . omega
Proof state after:
case isTrue.inl.isFalse
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝¹ : curr < w
heq : curr = idx
h✝ : ¬curr < distance
hgo : go aig input distance (curr + 1) ⋯ (s.pushRef (input.getRef (curr - distance) ⋯)) = res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
case isTrue.inl.isFalse
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝¹ : curr < w
heq : curr = idx
h✝ : ¬curr < distance
hgo : go aig input distance (curr + 1) ⋯ (s.pushRef (input.getRef (curr - distance) ⋯)) = res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
. split
  . omega
  . rw [← hgo]
    rw [go_getRef]
    rw [AIG.RefStream.getRef_push_ref_eq']
    . rw [go_denote_mem_prefix]
      . simp [heq]
      . simp [Ref.hgate]
    . rw [heq]
Proof state after:
no goals
Theorem: BVExpr.bitblast.blastShiftLeftConst.go_eq_eval_getLsb
Proof state before:
case isTrue.inl.isTrue
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝¹ : curr < w
heq : curr = idx
h✝ : curr < distance
hgo :
  go (aig.mkConstCached false).aig (input.cast ⋯) distance (curr + 1) ⋯
      ((s.cast ⋯).pushRef (aig.mkConstCached false).ref) =
    res
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    if hidx : idx < distance then false else ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧
Tactic:
split
Proof state after:
case isTrue.inl.isTrue.isTrue
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝² : curr < w
heq : curr = idx
h✝¹ : curr < distance
hgo :
  go (aig.mkConstCached false).aig (input.cast ⋯) distance (curr + 1) ⋯
      ((s.cast ⋯).pushRef (aig.mkConstCached false).ref) =
    res
h✝ : idx < distance
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ = false

case isTrue.inl.isTrue.isFalse
α : Type
inst✝² : BEq α
inst✝¹ : Hashable α
inst✝ : DecidableEq α
w : Nat
aig : AIG α
distance : Nat
input : aig.RefStream w
assign : α → Bool
curr : Nat
hcurr : curr ≤ w
s : aig.RefStream curr
idx : Nat
hidx1 : idx < w
hidx2 : curr ≤ idx
res : RefStreamEntry α w
h✝² : curr < w
heq : curr = idx
h✝¹ : curr < distance
hgo :
  go (aig.mkConstCached false).aig (input.cast ⋯) distance (curr + 1) ⋯
      ((s.cast ⋯).pushRef (aig.mkConstCached false).ref) =
    res
h✝ : ¬idx < distance
⊢ ⟦{ aig := res.aig, ref := res.stream.getRef idx hidx1 }, assign⟧ =
    ⟦{ aig := aig, ref := input.getRef (idx - distance) ⋯ }, assign⟧