added remdups_filter lemma
authornipkow
Fri, 04 Dec 2009 08:26:25 +0100
changeset 33945 8493ed132fed
parent 33944 ab87cceed53f
child 33946 fcc20072df9a
added remdups_filter lemma
src/HOL/List.thy
--- a/src/HOL/List.thy	Wed Dec 02 17:53:44 2009 +0100
+++ b/src/HOL/List.thy	Fri Dec 04 08:26:25 2009 +0100
@@ -2665,6 +2665,10 @@
 apply(rule length_remdups_leq)
 done
 
+lemma remdups_filter: "remdups(filter P xs) = filter P (remdups xs)"
+apply(induct xs)
+apply auto
+done
 
 lemma distinct_map:
   "distinct(map f xs) = (distinct xs & inj_on f (set xs))"