src/HOL/BNF_Def.thy
changeset 67091 1393c2340eec
parent 66198 4a5589dd8e1a
child 67399 eab6ce8368fa
equal deleted inserted replaced
67090:0ec94bb9cec4 67091:1393c2340eec
   178   by simp
   178   by simp
   179 
   179 
   180 lemma case_sum_o_inj: "case_sum f g \<circ> Inl = f" "case_sum f g \<circ> Inr = g"
   180 lemma case_sum_o_inj: "case_sum f g \<circ> Inl = f" "case_sum f g \<circ> Inr = g"
   181   by auto
   181   by auto
   182 
   182 
   183 lemma map_sum_o_inj: "map_sum f g o Inl = Inl o f" "map_sum f g o Inr = Inr o g"
   183 lemma map_sum_o_inj: "map_sum f g \<circ> Inl = Inl \<circ> f" "map_sum f g \<circ> Inr = Inr \<circ> g"
   184   by auto
   184   by auto
   185 
   185 
   186 lemma card_order_csum_cone_cexp_def:
   186 lemma card_order_csum_cone_cexp_def:
   187   "card_order r \<Longrightarrow> ( |A1| +c cone) ^c r = |Func UNIV (Inl ` A1 \<union> {Inr ()})|"
   187   "card_order r \<Longrightarrow> ( |A1| +c cone) ^c r = |Func UNIV (Inl ` A1 \<union> {Inr ()})|"
   188   unfolding cexp_def cone_def Field_csum Field_card_of by (auto dest: Field_card_order)
   188   unfolding cexp_def cone_def Field_csum Field_card_of by (auto dest: Field_card_order)
   260   unfolding eq_onp_def by auto
   260   unfolding eq_onp_def by auto
   261 
   261 
   262 lemma eq_onp_True: "eq_onp (\<lambda>_. True) = (op =)"
   262 lemma eq_onp_True: "eq_onp (\<lambda>_. True) = (op =)"
   263   unfolding eq_onp_def by simp
   263   unfolding eq_onp_def by simp
   264 
   264 
   265 lemma Ball_image_comp: "Ball (f ` A) g = Ball A (g o f)"
   265 lemma Ball_image_comp: "Ball (f ` A) g = Ball A (g \<circ> f)"
   266   by auto
   266   by auto
   267 
   267 
   268 lemma rel_fun_Collect_case_prodD:
   268 lemma rel_fun_Collect_case_prodD:
   269   "rel_fun A B f g \<Longrightarrow> X \<subseteq> Collect (case_prod A) \<Longrightarrow> x \<in> X \<Longrightarrow> B ((f o fst) x) ((g o snd) x)"
   269   "rel_fun A B f g \<Longrightarrow> X \<subseteq> Collect (case_prod A) \<Longrightarrow> x \<in> X \<Longrightarrow> B ((f \<circ> fst) x) ((g \<circ> snd) x)"
   270   unfolding rel_fun_def by auto
   270   unfolding rel_fun_def by auto
   271 
   271 
   272 lemma eq_onp_mono_iff: "eq_onp P \<le> eq_onp Q \<longleftrightarrow> P \<le> Q"
   272 lemma eq_onp_mono_iff: "eq_onp P \<le> eq_onp Q \<longleftrightarrow> P \<le> Q"
   273   unfolding eq_onp_def by auto
   273   unfolding eq_onp_def by auto
   274 
   274