internlm/Lean-Github huggingface dataset:
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Tactic:
have s1 : Env.Nodup (hd :: tl) := well_formed_env_has_no_dup (hd :: tl) h1
Proof state after:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Tactic:
have s2 : ∃ E1 : Env, (hd :: tl) = E1 ++ tl
Proof state after:
case s2
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
⊢ ∃ E1, hd :: tl = E1 ++ tl

D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Theorem: MM0.lem_4
Proof state before:
case s2
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
⊢ ∃ E1, hd :: tl = E1 ++ tl

D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Tactic:
apply Exists.intro [hd]
Proof state after:
case s2
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
⊢ hd :: tl = [hd] ++ tl

D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Theorem: MM0.lem_4
Proof state before:
case s2
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
⊢ hd :: tl = [hd] ++ tl

D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Tactic:
simp
Proof state after:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1 : Env.WellFormed (hd :: tl)
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Tactic:
unfold Env.WellFormed at h1
Proof state after:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h1 :
  (∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False) ∧
    IsMetaVarOrAllDefInEnv tl hd.F ∧ Env.WellFormed tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h2 : d ∈ hd :: tl
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h1 :
  (∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False) ∧
    IsMetaVarOrAllDefInEnv tl hd.F ∧ Env.WellFormed tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Tactic:
simp at h2
Proof state after:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h1 :
  (∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False) ∧
    IsMetaVarOrAllDefInEnv tl hd.F ∧ Env.WellFormed tl
h2 : d = hd ∨ d ∈ tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h1 :
  (∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False) ∧
    IsMetaVarOrAllDefInEnv tl hd.F ∧ Env.WellFormed tl
h2 : d = hd ∨ d ∈ tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Tactic:
cases h1
Proof state after:
case intro
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h2 : d = hd ∨ d ∈ tl
left✝ : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
right✝ : IsMetaVarOrAllDefInEnv tl hd.F ∧ Env.WellFormed tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h2 : d = hd ∨ d ∈ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right : IsMetaVarOrAllDefInEnv tl hd.F ∧ Env.WellFormed tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Tactic:
cases h1_right
Proof state after:
case intro
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h2 : d = hd ∨ d ∈ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
left✝ : IsMetaVarOrAllDefInEnv tl hd.F
right✝ : Env.WellFormed tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h2 : d = hd ∨ d ∈ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I V M (hd :: tl) (def_ name args)
Tactic:
simp only [Holds]
Proof state after:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h2 : d = hd ∨ d ∈ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    if name = hd.name ∧ args.length = hd.args.length then
      Holds D I (Function.updateListITE V hd.args (List.map V args)) M tl hd.F
    else Holds D I V M tl (def_ name args)
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h2 : d = hd ∨ d ∈ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    if name = hd.name ∧ args.length = hd.args.length then
      Holds D I (Function.updateListITE V hd.args (List.map V args)) M tl hd.F
    else Holds D I V M tl (def_ name args)
Tactic:
split_ifs
Proof state after:
case pos
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h2 : d = hd ∨ d ∈ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
h✝ : name = hd.name ∧ args.length = hd.args.length
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I (Function.updateListITE V hd.args (List.map V args)) M tl hd.F

case neg
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h2 : d = hd ∨ d ∈ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
h✝ : ¬(name = hd.name ∧ args.length = hd.args.length)
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔ Holds D I V M tl (def_ name args)
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h2 : d = hd ∨ d ∈ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
c1 : ¬(name = hd.name ∧ args.length = hd.args.length)
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔ Holds D I V M tl (def_ name args)
Tactic:
case _ c1 =>
  cases h2
  case inl c2 =>
    subst c2
    simp at c1
    cases h3
    case intro h3_left h3_right =>
      exfalso
      exact c1 h3_left h3_right
  case inr c2 =>
    specialize ih h1_right_right c2
    simp only [← ih]
    apply holds_coincide_env D I (Function.updateListITE V d.args (List.map V args)) M tl (hd :: tl) d.F s2
    apply def_in_well_formed_env_is_meta_var_or_all_def_in_env tl d h1_right_right c2
    exact s1
Proof state after:
no goals
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h2 : d = hd ∨ d ∈ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
c1 : name = hd.name ∧ args.length = hd.args.length
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I (Function.updateListITE V hd.args (List.map V args)) M tl hd.F
Tactic:
cases h2
Proof state after:
case inl
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
c1 : name = hd.name ∧ args.length = hd.args.length
h✝ : d = hd
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I (Function.updateListITE V hd.args (List.map V args)) M tl hd.F

case inr
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
c1 : name = hd.name ∧ args.length = hd.args.length
h✝ : d ∈ tl
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I (Function.updateListITE V hd.args (List.map V args)) M tl hd.F
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
c1 : name = hd.name ∧ args.length = hd.args.length
c2 : d = hd
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I (Function.updateListITE V hd.args (List.map V args)) M tl hd.F
Tactic:
case inl c2 =>
  subst c2
  exact holds_coincide_env D I (Function.updateListITE V d.args (List.map V args)) M tl (d :: tl) d.F s2 h1_right_left s1
Proof state after:
no goals
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
hd : Definition
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
s1 : Env.Nodup (hd :: tl)
s2 : ∃ E1, hd :: tl = E1 ++ tl
h1_left : ∀ d' ∈ tl, hd.name = d'.name → hd.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl hd.F
h1_right_right : Env.WellFormed tl
c1 : name = hd.name ∧ args.length = hd.args.length
c2 : d = hd
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (hd :: tl) d.F ↔
    Holds D I (Function.updateListITE V hd.args (List.map V args)) M tl hd.F
Tactic:
subst c2
Proof state after:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1_right_right : Env.WellFormed tl
s1 : Env.Nodup (d :: tl)
s2 : ∃ E1, d :: tl = E1 ++ tl
h1_left : ∀ d' ∈ tl, d.name = d'.name → d.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl d.F
c1 : name = d.name ∧ args.length = d.args.length
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (d :: tl) d.F ↔
    Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F
Theorem: MM0.lem_4
Proof state before:
D : Type
I : Interpretation D
V : Valuation D
M : MetaValuation D
d : Definition
name : DefName
args : List VarName
h3 : name = d.name ∧ args.length = d.args.length
tl : List Definition
ih :
  Env.WellFormed tl →
    d ∈ tl →
      (Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F ↔ Holds D I V M tl (def_ name args))
h1_right_right : Env.WellFormed tl
s1 : Env.Nodup (d :: tl)
s2 : ∃ E1, d :: tl = E1 ++ tl
h1_left : ∀ d' ∈ tl, d.name = d'.name → d.args.length = d'.args.length → False
h1_right_left : IsMetaVarOrAllDefInEnv tl d.F
c1 : name = d.name ∧ args.length = d.args.length
⊢ Holds D I (Function.updateListITE V d.args (List.map V args)) M (d :: tl) d.F ↔
    Holds D I (Function.updateListITE V d.args (List.map V args)) M tl d.F
Tactic:
exact holds_coincide_env D I (Function.updateListITE V d.args (List.map V args)) M tl (d :: tl) d.F s2 h1_right_left s1
Proof state after:
no goals