diff -r 92c001d93225 -r 1d1772a89026 Nominal/Nominal2_Base.thy --- a/Nominal/Nominal2_Base.thy Tue Jan 18 06:55:18 2011 +0100 +++ b/Nominal/Nominal2_Base.thy Tue Jan 18 11:02:57 2011 +0100 @@ -518,6 +518,18 @@ unfolding permute_set_eq using a by (auto simp add: swap_atom) +lemma swap_set_in_eq: + assumes a: "a \ S" "b \ S" "sort_of a = sort_of b" + shows "(a \ b) \ S = (S - {a}) \ {b}" + unfolding permute_set_eq + using a by (auto simp add: swap_atom) + +lemma swap_set_both_in: + assumes a: "a \ S" "b \ S" + shows "(a \ b) \ S = S" + unfolding permute_set_eq + using a by (auto simp add: swap_atom) + lemma mem_permute_iff: shows "(p \ x) \ (p \ X) \ x \ X" unfolding mem_def permute_fun_def permute_bool_def @@ -1717,7 +1729,7 @@ by (rule_tac S="supp p" in perm_struct_induct) (auto intro: zero swap) -lemma perm_subset_induct[consumes 1, case_names zero swap plus]: +lemma perm_struct_induct2[consumes 1, case_names zero swap plus]: assumes S: "supp p \ S" assumes zero: "P 0" assumes swap: "\a b. \sort_of a = sort_of b; a \ b; a \ S; b \ S\ \ P (a \ b)" @@ -1727,6 +1739,14 @@ by (induct p rule: perm_struct_induct) (auto intro: zero plus swap simp add: supp_swap) +lemma perm_simple_struct_induct2[case_names zero swap plus]: + assumes zero: "P 0" + assumes swap: "\a b. \sort_of a = sort_of b; a \ b\ \ P (a \ b)" + assumes plus: "\p1 p2. \P p1; P p2\ \ P (p1 + p2)" + shows "P p" +by (rule_tac S="supp p" in perm_struct_induct2) + (auto intro: zero swap plus) + lemma supp_perm_eq: assumes "(supp x) \* p" shows "p \ x = x" @@ -1751,7 +1771,7 @@ from assms have "supp p \ {a. a \ x}" unfolding supp_perm fresh_star_def fresh_def by auto then show "p \ x = x" - proof (induct p rule: perm_subset_induct) + proof (induct p rule: perm_struct_induct2) case zero show "0 \ x = x" by simp next @@ -1925,7 +1945,6 @@ section {* Renaming permutations *} - lemma set_renaming_perm: assumes b: "finite bs" shows "\q. (\b \ bs. q \ b = p \ b) \ supp q \ bs \ (p \ bs)"