equal
deleted
inserted
replaced
105 apply (auto dest: guarantees_type [THEN subsetD] |
105 apply (auto dest: guarantees_type [THEN subsetD] |
106 simp add: merge_spec_def merge_increasing_def) |
106 simp add: merge_spec_def merge_increasing_def) |
107 done |
107 done |
108 |
108 |
109 lemma (in merge) merge_Allowed: |
109 lemma (in merge) merge_Allowed: |
110 "Allowed(M) = (preserves(lift(Out)) Int preserves(lift(iOut)))" |
110 "Allowed(M) = (preserves(lift(Out)) \<inter> preserves(lift(iOut)))" |
111 apply (insert merge_spec preserves_type [of "lift (Out)"]) |
111 apply (insert merge_spec preserves_type [of "lift (Out)"]) |
112 apply (auto simp add: merge_spec_def merge_allowed_acts_def Allowed_def safety_prop_Acts_iff) |
112 apply (auto simp add: merge_spec_def merge_allowed_acts_def Allowed_def safety_prop_Acts_iff) |
113 done |
113 done |
114 |
114 |
115 lemma (in merge) M_ok_iff: |
115 lemma (in merge) M_ok_iff: |
116 "G \<in> program ==> |
116 "G \<in> program ==> |
117 M ok G <-> (G \<in> preserves(lift(Out)) & |
117 M ok G \<longleftrightarrow> (G \<in> preserves(lift(Out)) & |
118 G \<in> preserves(lift(iOut)) & M \<in> Allowed(G))" |
118 G \<in> preserves(lift(iOut)) & M \<in> Allowed(G))" |
119 apply (cut_tac merge_spec) |
119 apply (cut_tac merge_spec) |
120 apply (auto simp add: merge_Allowed ok_iff_Allowed) |
120 apply (auto simp add: merge_Allowed ok_iff_Allowed) |
121 done |
121 done |
122 |
122 |
164 apply (subgoal_tac "length (x ` iOut) \<in> nat") |
164 apply (subgoal_tac "length (x ` iOut) \<in> nat") |
165 prefer 2 apply (simp add: length_type [OF iOut_value_type]) |
165 prefer 2 apply (simp add: length_type [OF iOut_value_type]) |
166 apply (subgoal_tac "xa \<in> nat") |
166 apply (subgoal_tac "xa \<in> nat") |
167 apply (simp_all add: Ord_mem_iff_lt) |
167 apply (simp_all add: Ord_mem_iff_lt) |
168 prefer 2 apply (blast intro: lt_trans) |
168 prefer 2 apply (blast intro: lt_trans) |
169 apply (drule_tac x = "nth (xa, x`iOut)" and P = "%elt. ?X (elt) --> elt<Nclients" in bspec) |
169 apply (drule_tac x = "nth (xa, x`iOut)" and P = "%elt. ?X (elt) \<longrightarrow> elt<Nclients" in bspec) |
170 apply (simp add: ltI nat_into_Ord) |
170 apply (simp add: ltI nat_into_Ord) |
171 apply (blast dest: ltD) |
171 apply (blast dest: ltD) |
172 done |
172 done |
173 |
173 |
174 theorem (in merge) merge_bag_Follows: |
174 theorem (in merge) merge_bag_Follows: |