File tree Expand file tree Collapse file tree 1 file changed +17
-3
lines changed Expand file tree Collapse file tree 1 file changed +17
-3
lines changed Original file line number Diff line number Diff line change @@ -101,10 +101,24 @@ using assms proof (induct xs arbitrary: ys)
101101 by simp
102102next
103103 case ( Cons a xs )
104- hence ys : "set ys = insert a (set (removeAll a ys)) "
105- by ( auto )
104+ consider ( a_in ) "a \<in> set xs" | ( a_notin ) "a \<notin> set xs "
105+ by blast
106106 then show ?case
107- by ( metis ( no_types , lifting ) Cons.hyps Cons.prems ( 1 ) Cons.prems ( 2 ) Diff_insert_absorb foldr_scene_union_removeAll insertCI insert_absorb list.simps ( 15 ) pairwise_insert set_removeAll )
107+ proof cases
108+ case a_in
109+ then show ?thesis
110+ by ( metis Cons remdups.simps ( 2 ) set_remdups )
111+ next
112+ case a_notin
113+ then have *: "\<Squnion>\<^sub>S xs = \<Squnion>\<^sub>S (removeAll a ys)"
114+ using Cons ( 2 , 3 ) by ( auto intro !: Cons ( 1 ) simp : pairwise_insert )
115+ then have "\<Squnion>\<^sub>S (a#xs) = (\<Squnion>\<^sub>S xs) \<squnion>\<^sub>S a"
116+ by ( simp add : scene_union_commute )
117+ also have "... = \<Squnion>\<^sub>S (removeAll a ys) \<squnion>\<^sub>S a"
118+ using * by simp
119+ finally show ?thesis
120+ using foldr_scene_union_removeAll Cons ( 2 , 3 ) by auto
121+ qed
108122qed
109123
110124lemma foldr_scene_removeAll :
You can’t perform that action at this time.
0 commit comments