equal
deleted
inserted
replaced
503 \<forall>v \<in> set vs2. \<Turnstile> v : r \<and> flat v = []; |
503 \<forall>v \<in> set vs2. \<Turnstile> v : r \<and> flat v = []; |
504 length (vs1 @ vs2) = n; length (vs1 @ vs2) \<le> m\<rbrakk> \<Longrightarrow> \<Turnstile> Stars (vs1 @ vs2) : NMTIMES r n m" |
504 length (vs1 @ vs2) = n; length (vs1 @ vs2) \<le> m\<rbrakk> \<Longrightarrow> \<Turnstile> Stars (vs1 @ vs2) : NMTIMES r n m" |
505 | "\<lbrakk>\<forall>v \<in> set vs. \<Turnstile> v : r \<and> flat v \<noteq> []; |
505 | "\<lbrakk>\<forall>v \<in> set vs. \<Turnstile> v : r \<and> flat v \<noteq> []; |
506 length vs > n; length vs \<le> m\<rbrakk> \<Longrightarrow> \<Turnstile> Stars vs : NMTIMES r n m" |
506 length vs > n; length vs \<le> m\<rbrakk> \<Longrightarrow> \<Turnstile> Stars vs : NMTIMES r n m" |
507 |
507 |
508 |
508 |
|
509 |
|
510 |
|
511 |
509 inductive_cases Prf_elims: |
512 inductive_cases Prf_elims: |
510 "\<Turnstile> v : ZERO" |
513 "\<Turnstile> v : ZERO" |
511 "\<Turnstile> v : SEQ r1 r2" |
514 "\<Turnstile> v : SEQ r1 r2" |
512 "\<Turnstile> v : ALT r1 r2" |
515 "\<Turnstile> v : ALT r1 r2" |
513 "\<Turnstile> v : ONE" |
516 "\<Turnstile> v : ONE" |
762 |
765 |
763 lemma L_flat_Prf: |
766 lemma L_flat_Prf: |
764 shows "L(r) = {flat v | v. \<Turnstile> v : r}" |
767 shows "L(r) = {flat v | v. \<Turnstile> v : r}" |
765 using L_flat_Prf1 L_flat_Prf2 by blast |
768 using L_flat_Prf1 L_flat_Prf2 by blast |
766 |
769 |
767 |
770 thm Prf.intros |
|
771 thm Prf.cases |
|
772 |
|
773 lemma |
|
774 assumes "\<Turnstile> v : (STAR r)" |
|
775 shows "\<Turnstile> v : (FROMNTIMES r 0)" |
|
776 using assms |
|
777 apply(erule_tac Prf.cases) |
|
778 apply(simp_all) |
|
779 apply(case_tac vs) |
|
780 apply(auto) |
|
781 apply(subst append_Nil[symmetric]) |
|
782 apply(rule Prf.intros) |
|
783 apply(auto) |
|
784 apply(simp add: Prf.intros) |
|
785 done |
|
786 |
|
787 lemma |
|
788 assumes "\<Turnstile> v : (FROMNTIMES r 0)" |
|
789 shows "\<Turnstile> v : (STAR r)" |
|
790 using assms |
|
791 apply(erule_tac Prf.cases) |
|
792 apply(simp_all) |
|
793 apply(rule Prf.intros) |
|
794 apply(simp) |
|
795 apply(rule Prf.intros) |
|
796 apply(simp) |
|
797 done |
768 |
798 |
769 section {* Sets of Lexical Values *} |
799 section {* Sets of Lexical Values *} |
770 |
800 |
771 text {* |
801 text {* |
772 Shows that lexical values are finite for a given regex and string. |
802 Shows that lexical values are finite for a given regex and string. |