Theorem: Turing.TM2to1.addBottom_modifyNth
File: Mathlib/Computability/TuringMachine.lean

tactic: cases n <;>
  simp only [addBottom, ListBlank.head_cons, ListBlank.modifyNth, ListBlank.tail_cons]
state_before: K : Type u_2
inst✝² : DecidableEq K
Γ : K → Type u_1
Λ : Type ?u.599871
inst✝¹ : Inhabited Λ
σ : Type ?u.599877
inst✝ : Inhabited σ
f : ((k : K) → Option (Γ k)) → (k : K) → Option (Γ k)
L : ListBlank ((k : K) → Option (Γ k))
n : ℕ
⊢ ListBlank.modifyNth (fun a => (a.fst, f a.snd)) n (addBottom L) = addBottom (ListBlank.modifyNth f n L)

tactic: congr
state_before: case succ
K : Type u_2
inst✝² : DecidableEq K
Γ : K → Type u_1
Λ : Type ?u.599871
inst✝¹ : Inhabited Λ
σ : Type ?u.599877
inst✝ : Inhabited σ
f : ((k : K) → Option (Γ k)) → (k : K) → Option (Γ k)
L : ListBlank ((k : K) → Option (Γ k))
n✝ : ℕ
⊢ ListBlank.cons (true, ListBlank.head L)
      (ListBlank.modifyNth (fun a => (a.fst, f a.snd)) n✝
        (ListBlank.map { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) }
          (ListBlank.tail L))) =
    ListBlank.cons (true, ListBlank.head L)
      (ListBlank.map { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) }
        (ListBlank.modifyNth f n✝ (ListBlank.tail L)))

tactic: symm
state_before: case succ.e_l
K : Type u_2
inst✝² : DecidableEq K
Γ : K → Type u_1
Λ : Type ?u.599871
inst✝¹ : Inhabited Λ
σ : Type ?u.599877
inst✝ : Inhabited σ
f : ((k : K) → Option (Γ k)) → (k : K) → Option (Γ k)
L : ListBlank ((k : K) → Option (Γ k))
n✝ : ℕ
⊢ ListBlank.modifyNth (fun a => (a.fst, f a.snd)) n✝
      (ListBlank.map { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) } (ListBlank.tail L)) =
    ListBlank.map { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) }
      (ListBlank.modifyNth f n✝ (ListBlank.tail L))

tactic: apply ListBlank.map_modifyNth
state_before: case succ.e_l
K : Type u_2
inst✝² : DecidableEq K
Γ : K → Type u_1
Λ : Type ?u.599871
inst✝¹ : Inhabited Λ
σ : Type ?u.599877
inst✝ : Inhabited σ
f : ((k : K) → Option (Γ k)) → (k : K) → Option (Γ k)
L : ListBlank ((k : K) → Option (Γ k))
n✝ : ℕ
⊢ ListBlank.map { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) }
      (ListBlank.modifyNth f n✝ (ListBlank.tail L)) =
    ListBlank.modifyNth (fun a => (a.fst, f a.snd)) n✝
      (ListBlank.map { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) } (ListBlank.tail L))

tactic: intro
state_before: case succ.e_l.H
K : Type u_2
inst✝² : DecidableEq K
Γ : K → Type u_1
Λ : Type ?u.599871
inst✝¹ : Inhabited Λ
σ : Type ?u.599877
inst✝ : Inhabited σ
f : ((k : K) → Option (Γ k)) → (k : K) → Option (Γ k)
L : ListBlank ((k : K) → Option (Γ k))
n✝ : ℕ
⊢ ∀ (x : (k : K) → Option (Γ k)),
    PointedMap.f { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) } (f x) =
      ((PointedMap.f { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) } x).fst,
        f (PointedMap.f { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) } x).snd)

tactic: rfl
state_before: case succ.e_l.H
K : Type u_2
inst✝² : DecidableEq K
Γ : K → Type u_1
Λ : Type ?u.599871
inst✝¹ : Inhabited Λ
σ : Type ?u.599877
inst✝ : Inhabited σ
f : ((k : K) → Option (Γ k)) → (k : K) → Option (Γ k)
L : ListBlank ((k : K) → Option (Γ k))
n✝ : ℕ
x✝ : (k : K) → Option (Γ k)
⊢ PointedMap.f { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) } (f x✝) =
    ((PointedMap.f { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) } x✝).fst,
      f (PointedMap.f { f := Prod.mk false, map_pt' := (_ : (false, default) = (false, default)) } x✝).snd)