diff -r 78623a0f294b -r 8f5420681039 Nominal/Ex/Foo1.thy --- a/Nominal/Ex/Foo1.thy Sat Nov 27 23:00:16 2010 +0000 +++ b/Nominal/Ex/Foo1.thy Sun Nov 28 16:37:34 2010 +0000 @@ -154,11 +154,11 @@ fixes c::"'a::fs" 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" - and "\assn' trm. (bn4 assn') \* c \ y = Let4 assn' trm \ P" + and "\name trm. {atom name} \* c \ y = Lam name trm \ P" + and "\(c::'a::fs) assn trm. set (bn1 assn) \* c \ y = Let1 assn trm \ P" + and "\(c::'a::fs) assn trm. set (bn2 assn) \* c \ y = Let2 assn trm \ P" + and "\(c::'a::fs) assn trm. set (bn3 assn) \* c \ y = Let3 assn trm \ P" + and "\(c::'a::fs) assn' trm. (bn4 assn') \* c \ y = Let4 assn' trm \ P" shows "P" apply(rule_tac y="y" in foo.exhaust(1)) apply(rule assms(1)) @@ -168,6 +168,115 @@ apply(rule exI)+ apply(assumption) apply(rule assms(3)) +apply(subgoal_tac "\p::perm. (p \ {atom name}) \* (c, name, trm)") +apply(erule exE) +apply(perm_simp) +apply(rule_tac exI)+ +apply(rule conjI) +apply(simp add: fresh_star_prod) +apply(erule conjE)+ +apply(assumption) +apply(simp) +apply(simp add: foo.eq_iff) +(* HERE *) +defer +defer +apply(rule assms(4)) +apply(subgoal_tac "\p::perm. (p \ (set (bn1 assg))) \* (c, assg, trm)") +apply(erule exE) +apply(perm_simp add: tt1) +apply(simp only: fresh_star_prod) +apply(erule conjE)+ +apply(rule_tac exI)+ +apply(rule conjI) +apply(assumption) +apply(simp add: foo.eq_iff) +apply(rule conjI) +apply(simp only: tt1[symmetric]) +defer +apply(rule uu1) +defer +apply(rule assms(5)) +apply(subgoal_tac "\p::perm. (p \ (set (bn2 assg))) \* (c, assg, trm)") +apply(erule exE) +apply(perm_simp add: tt2) +apply(simp only: fresh_star_prod) +apply(erule conjE)+ +apply(rule_tac exI)+ +apply(rule conjI) +apply(assumption) +apply(simp add: foo.eq_iff) +apply(rule conjI) +apply(simp only: tt2[symmetric]) +defer +apply(rule uu2) +defer +apply(rule refl) +apply(subst (asm) fresh_star_supp_conv) +apply(simp) + + +lemma strong_exhaust2: + fixes c::"'a::fs" + 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" + and "\assn' trm. \(bn4 assn') \* c; y = Let4 assn' trm\ \ P" + shows "P" +apply(rule strong_exhaust1[where y="y"]) +apply(erule exE)+ +apply(rule assms(1)) +apply(assumption) +apply(erule exE)+ +apply(rule assms(2)) +apply(assumption) +apply(erule exE | erule conjE)? +apply(rule assms(3)) +apply(drule_tac x="c" in spec) +apply(erule exE | erule conjE)+ +apply(assumption)+ +apply(drule_tac x="c" in spec) +apply(erule exE | erule conjE)+ +apply(assumption)+ +apply(erule exE | erule conjE)+ +apply(rule assms(4)) +apply(assumption)+ +apply(erule exE | erule conjE)+ +apply(rule assms(5)) +apply(assumption)+ +apply(erule exE | erule conjE)+ +apply(rule assms(6)) +apply(assumption)+ +apply(erule exE | erule conjE)+ +apply(rule assms(7)) +apply(assumption)+ +done + + + + + + + + + + + + +apply(rule_tac y="y" in foo.exhaust(1)) +apply(rule assms(1)) +apply(rule exI) +apply(assumption) +apply(rule assms(2)) +apply(rule exI)+ +apply(assumption) +apply(rule assms(3)) +apply(rule_tac p="p" in permute_boolE) +apply(perm_simp) +apply(simp) apply(subgoal_tac "\q. (q \ {atom name}) \* c \ supp (Lam name trm) \* q") apply(erule exE) apply(erule conjE)