equal
deleted
inserted
replaced
1 theory Class3 |
1 theory Class3 |
2 imports Class2 |
2 imports Class2 |
3 begin |
3 begin |
4 |
4 |
5 text {* 3rd Main Lemma *} |
5 text \<open>3rd Main Lemma\<close> |
6 |
6 |
7 lemma Cut_a_redu_elim: |
7 lemma Cut_a_redu_elim: |
8 assumes a: "Cut <a>.M (x).N \<longrightarrow>\<^sub>a R" |
8 assumes a: "Cut <a>.M (x).N \<longrightarrow>\<^sub>a R" |
9 shows "(\<exists>M'. R = Cut <a>.M' (x).N \<and> M \<longrightarrow>\<^sub>a M') \<or> |
9 shows "(\<exists>M'. R = Cut <a>.M' (x).N \<and> M \<longrightarrow>\<^sub>a M') \<or> |
10 (\<exists>N'. R = Cut <a>.M (x).N' \<and> N \<longrightarrow>\<^sub>a N') \<or> |
10 (\<exists>N'. R = Cut <a>.M (x).N' \<and> N \<longrightarrow>\<^sub>a N') \<or> |
2244 apply(rule SNaI) |
2244 apply(rule SNaI) |
2245 apply(drule nrename_aredu) |
2245 apply(drule nrename_aredu) |
2246 apply(blast)+ |
2246 apply(blast)+ |
2247 done |
2247 done |
2248 |
2248 |
2249 text {* helper-stuff to set up the induction *} |
2249 text \<open>helper-stuff to set up the induction\<close> |
2250 |
2250 |
2251 abbreviation |
2251 abbreviation |
2252 SNa_set :: "trm set" |
2252 SNa_set :: "trm set" |
2253 where |
2253 where |
2254 "SNa_set \<equiv> {M. SNa M}" |
2254 "SNa_set \<equiv> {M. SNa M}" |
2357 apply(simp add: trm.inject) |
2357 apply(simp add: trm.inject) |
2358 apply(rule sym) |
2358 apply(rule sym) |
2359 apply(simp add: alpha fresh_prod fresh_atm) |
2359 apply(simp add: alpha fresh_prod fresh_atm) |
2360 done |
2360 done |
2361 |
2361 |
2362 text {* 3rd lemma *} |
2362 text \<open>3rd lemma\<close> |
2363 |
2363 |
2364 lemma CUT_SNa_aux: |
2364 lemma CUT_SNa_aux: |
2365 assumes a1: "<a>:M \<in> (\<parallel><B>\<parallel>)" |
2365 assumes a1: "<a>:M \<in> (\<parallel><B>\<parallel>)" |
2366 and a2: "SNa M" |
2366 and a2: "SNa M" |
2367 and a3: "(x):N \<in> (\<parallel>(B)\<parallel>)" |
2367 and a3: "(x):N \<in> (\<parallel>(B)\<parallel>)" |
4925 apply(drule validn_fresh) |
4925 apply(drule validn_fresh) |
4926 apply(auto) |
4926 apply(auto) |
4927 done |
4927 done |
4928 |
4928 |
4929 |
4929 |
4930 text {* typing relation *} |
4930 text \<open>typing relation\<close> |
4931 |
4931 |
4932 inductive |
4932 inductive |
4933 typing :: "ctxtn \<Rightarrow> trm \<Rightarrow> ctxtc \<Rightarrow> bool" ("_ \<turnstile> _ \<turnstile> _" [100,100,100] 100) |
4933 typing :: "ctxtn \<Rightarrow> trm \<Rightarrow> ctxtc \<Rightarrow> bool" ("_ \<turnstile> _ \<turnstile> _" [100,100,100] 100) |
4934 where |
4934 where |
4935 TAx: "\<lbrakk>validn \<Gamma>;validc \<Delta>; (x,B)\<in>set \<Gamma>; (a,B)\<in>set \<Delta>\<rbrakk> \<Longrightarrow> \<Gamma> \<turnstile> Ax x a \<turnstile> \<Delta>" |
4935 TAx: "\<lbrakk>validn \<Gamma>;validc \<Delta>; (x,B)\<in>set \<Gamma>; (a,B)\<in>set \<Delta>\<rbrakk> \<Longrightarrow> \<Gamma> \<turnstile> Ax x a \<turnstile> \<Delta>" |