# HG changeset patch # User Christian Urban # Date 1285847026 14400 # Node ID 68ee6913fa8ddd556cc3b1cb5c45d639b7cae829 # Parent cc5d235473411e3517e50fc36e5079ecf26a2d82# Parent 6abeee9e52e326f9c01bf306870d823064a17e9e merged diff -r 6abeee9e52e3 -r 68ee6913fa8d Nominal/Ex/Foo1.thy --- a/Nominal/Ex/Foo1.thy Wed Sep 29 09:51:57 2010 -0400 +++ b/Nominal/Ex/Foo1.thy Thu Sep 30 07:43:46 2010 -0400 @@ -157,26 +157,26 @@ lemma strong_exhaust1: fixes c::"'a::fs" - assumes "\name ca. \c = ca; y = Var name\ \ P" - and "\trm1 trm2 ca. \c = ca; y = App trm1 trm2\ \ P" - and "\name trm ca. \{atom name} \* ca; c = ca; y = Lam name trm\ \ P" - and "\assn trm ca. \set (bn1 assn) \* ca; c = ca; y = Let1 assn trm\ \ P" - and "\assn trm ca. \set (bn2 assn) \* ca; c = ca; y = Let2 assn trm\ \ P" - and "\assn trm ca. \set (bn3 assn) \* ca; c = ca; y = Let3 assn trm\ \ P" + assumes "\name. y = Var name \ P" + and "\trm1 trm2. y = App trm1 trm2 \ P" + and "\name trm. \{atom name} \* c; y = Lam name trm\ \ P" + and "\assn trm. \set (bn1 assn) \* c; y = Let1 assn trm\ \ P" + and "\assn trm. \set (bn2 assn) \* c; y = Let2 assn trm\ \ P" + and "\assn trm. \set (bn3 assn) \* c; y = Let3 assn trm\ \ P" shows "P" apply(rule_tac y="y" in foo.exhaust(1)) apply(rule assms(1)) -apply(auto)[2] +apply(assumption) apply(rule assms(2)) -apply(auto)[2] +apply(assumption) apply(subgoal_tac "\q. (q \ {atom name}) \* c \ supp (Lam name trm) \* q") apply(erule exE) apply(erule conjE) apply(rule assms(3)) apply(perm_simp) apply(assumption) -apply(rule refl) apply(drule supp_perm_eq[symmetric]) +apply(perm_simp) apply(simp) apply(rule at_set_avoiding2) apply(simp add: finite_supp) @@ -187,13 +187,10 @@ apply(erule exE) apply(erule conjE) apply(rule assms(4)) -apply(simp add: set_eqvt) -apply(simp add: tt1) -apply(rule refl) -apply(simp) +apply(perm_simp add: tt1) +apply(assumption) +apply(drule supp_perm_eq[symmetric]) apply(simp add: foo.eq_iff) -apply(drule supp_perm_eq[symmetric]) -apply(simp) apply(simp add: tt1 uu1) apply(rule at_set_avoiding2) apply(simp add: finite_supp) @@ -206,8 +203,6 @@ apply(rule assms(5)) apply(simp add: set_eqvt) apply(simp add: tt2) -apply(rule refl) -apply(simp) apply(simp add: foo.eq_iff) apply(drule supp_perm_eq[symmetric]) apply(simp) @@ -223,8 +218,6 @@ apply(rule assms(6)) apply(simp add: set_eqvt) apply(simp add: tt3) -apply(rule refl) -apply(simp) apply(simp add: foo.eq_iff) apply(drule supp_perm_eq[symmetric]) apply(simp) @@ -236,14 +229,12 @@ apply(simp add: Abs_fresh_star) done -thm foo.exhaust - lemma strong_exhaust2: - assumes "\x y t ca. \c = ca; as = As x y t\ \ P" + assumes "\x y t. as = As x y t \ P" shows "P" apply(rule_tac y="as" in foo.exhaust(2)) apply(rule assms(1)) -apply(auto)[2] +apply(assumption) done @@ -261,17 +252,11 @@ shows "P1 c t" "P2 c as" using assms apply(induction_schema) -apply(rule_tac y="t" in strong_exhaust1) -apply(blast) -apply(blast) -apply(blast) -apply(blast) -apply(blast) -apply(blast) +apply(rule_tac y="t" and c="c" in strong_exhaust1) +apply(simp_all)[6] apply(rule_tac as="as" in strong_exhaust2) -apply(blast) +apply(simp) apply(relation "measure (sum_case (\y. size (snd y)) (\z. size (snd z)))") -apply(auto)[1] apply(simp_all add: foo.size) done diff -r 6abeee9e52e3 -r 68ee6913fa8d Nominal/Ex/Lambda.thy --- a/Nominal/Ex/Lambda.thy Wed Sep 29 09:51:57 2010 -0400 +++ b/Nominal/Ex/Lambda.thy Thu Sep 30 07:43:46 2010 -0400 @@ -26,20 +26,19 @@ lemma strong_exhaust: fixes c::"'a::fs" - assumes "\name ca. \c = ca; y = Var name\ \ P" - and "\lam1 lam2 ca. \c = ca; y = App lam1 lam2\ \ P" - and "\name lam ca. \c = ca; atom name \ ca; y = Lam name lam\ \ P" + assumes "\name. \y = Var name\ \ P" + and "\lam1 lam2. \y = App lam1 lam2\ \ P" + and "\name lam. \atom name \ c; y = Lam name lam\ \ P" shows "P" apply(rule_tac y="y" in lam.exhaust) apply(rule assms(1)) -apply(auto)[2] +apply(assumption) apply(rule assms(2)) -apply(auto)[2] +apply(assumption) apply(subgoal_tac "\q. (q \ (atom name)) \ c \ supp (Lam name lam) \* q") apply(erule exE) apply(erule conjE) apply(rule assms(3)) -apply(rule refl) apply(simp add: atom_eqvt) apply(clarify) apply(drule supp_perm_eq[symmetric]) @@ -64,10 +63,7 @@ apply(blast) apply(blast) apply(relation "measure (\(x,y). size y)") -apply(auto)[1] -apply(simp add: lam.size) -apply(simp add: lam.size) -apply(simp add: lam.size) +apply(simp_all add: lam.size) done section {* Strong Induction Principles*} diff -r 6abeee9e52e3 -r 68ee6913fa8d Nominal/Ex/Let.thy --- a/Nominal/Ex/Let.thy Wed Sep 29 09:51:57 2010 -0400 +++ b/Nominal/Ex/Let.thy Thu Sep 30 07:43:46 2010 -0400 @@ -74,23 +74,22 @@ lemma strong_exhaust1: fixes c::"'a::fs" - assumes "\name ca. \c = ca; y = Var name\ \ P" - and "\trm1 trm2 ca. \c = ca; y = App trm1 trm2\ \ P" - and "\name trm ca. \{atom name} \* ca; c = ca; y = Lam name trm\ \ P" - and "\assn trm ca. \set (bn assn) \* ca; c = ca; y = Let assn trm\ \ P" + assumes "\name. y = Var name \ P" + and "\trm1 trm2. y = App trm1 trm2 \ P" + and "\name trm. \{atom name} \* c; y = Lam name trm\ \ P" + and "\assn trm. \set (bn assn) \* c; y = Let assn trm\ \ P" shows "P" apply(rule_tac y="y" in trm_assn.exhaust(1)) apply(rule assms(1)) -apply(auto)[2] +apply(assumption) apply(rule assms(2)) -apply(auto)[2] +apply(assumption) apply(subgoal_tac "\q. (q \ {atom name}) \* c \ supp (Lam name trm) \* q") apply(erule exE) apply(erule conjE) apply(rule assms(3)) apply(perm_simp) apply(assumption) -apply(rule refl) apply(drule supp_perm_eq[symmetric]) apply(simp) apply(rule at_set_avoiding2) @@ -98,13 +97,12 @@ apply(simp add: finite_supp) apply(simp add: finite_supp) apply(simp add: trm_assn.fresh fresh_star_def) -apply(subgoal_tac "\q. (q \ (set (bn assn))) \* c \ supp ([bn assn]lst.trm) \* q") +apply(subgoal_tac "\q. (q \ (set (bn assn))) \* (c::'a::fs) \ supp ([bn assn]lst.trm) \* q") apply(erule exE) apply(erule conjE) -apply(rule assms(4)) +apply(rule_tac assms(4)) apply(simp add: set_eqvt) apply(simp add: tt) -apply(rule refl) apply(simp) apply(simp add: trm_assn.eq_iff) apply(drule supp_perm_eq[symmetric]) @@ -119,14 +117,14 @@ lemma strong_exhaust2: - assumes "\ca. \c = ca; as = ANil\ \ P" - and "\x t assn ca. \c = ca; as = ACons x t assn\ \ P" + assumes "as = ANil \ P" + and "\x t assn. \as = ACons x t assn\ \ P" shows "P" apply(rule_tac y="as" in trm_assn.exhaust(2)) apply(rule assms(1)) -apply(auto)[2] +apply(assumption) apply(rule assms(2)) -apply(auto)[2] +apply(assumption)+ done @@ -152,8 +150,7 @@ apply(blast) apply(blast) apply(relation "measure (sum_case (\y. size (snd y)) (\z. size (snd z)))") -apply(auto)[1] -apply(simp_all add: trm_assn.size)[7] +apply(simp_all add: trm_assn.size) done text {* *}