src/HOL/BNF_Cardinal_Order_Relation.thy
changeset 61943 7fba644ed827
parent 61799 4cf66f21b764
child 62343 24106dc44def
equal deleted inserted replaced
61942:f02b26f7d39d 61943:7fba644ed827
   786   using card_of_Well_order[of A] card_of_Well_order[of B]
   786   using card_of_Well_order[of A] card_of_Well_order[of B]
   787         ordLeq_total[of "|A|"] by blast
   787         ordLeq_total[of "|A|"] by blast
   788 qed
   788 qed
   789 
   789 
   790 lemma card_of_Times_Plus_distrib:
   790 lemma card_of_Times_Plus_distrib:
   791   "|A <*> (B <+> C)| =o |A <*> B <+> A <*> C|" (is "|?RHS| =o |?LHS|")
   791   "|A \<times> (B <+> C)| =o |A \<times> B <+> A \<times> C|" (is "|?RHS| =o |?LHS|")
   792 proof -
   792 proof -
   793   let ?f = "\<lambda>(a, bc). case bc of Inl b \<Rightarrow> Inl (a, b) | Inr c \<Rightarrow> Inr (a, c)"
   793   let ?f = "\<lambda>(a, bc). case bc of Inl b \<Rightarrow> Inl (a, b) | Inr c \<Rightarrow> Inr (a, c)"
   794   have "bij_betw ?f ?RHS ?LHS" unfolding bij_betw_def inj_on_def by force
   794   have "bij_betw ?f ?RHS ?LHS" unfolding bij_betw_def inj_on_def by force
   795   thus ?thesis using card_of_ordIso by blast
   795   thus ?thesis using card_of_ordIso by blast
   796 qed
   796 qed
  1036   thus ?thesis using 1 ordLeq_ordIso_trans by blast
  1036   thus ?thesis using 1 ordLeq_ordIso_trans by blast
  1037 qed
  1037 qed
  1038 
  1038 
  1039 lemma card_of_Times_ordLeq_infinite_Field:
  1039 lemma card_of_Times_ordLeq_infinite_Field:
  1040 "\<lbrakk>\<not>finite (Field r); |A| \<le>o r; |B| \<le>o r; Card_order r\<rbrakk>
  1040 "\<lbrakk>\<not>finite (Field r); |A| \<le>o r; |B| \<le>o r; Card_order r\<rbrakk>
  1041  \<Longrightarrow> |A <*> B| \<le>o r"
  1041  \<Longrightarrow> |A \<times> B| \<le>o r"
  1042 by(simp add: card_of_Sigma_ordLeq_infinite_Field)
  1042 by(simp add: card_of_Sigma_ordLeq_infinite_Field)
  1043 
  1043 
  1044 lemma card_of_Times_infinite_simps:
  1044 lemma card_of_Times_infinite_simps:
  1045 "\<lbrakk>\<not>finite A; B \<noteq> {}; |B| \<le>o |A|\<rbrakk> \<Longrightarrow> |A \<times> B| =o |A|"
  1045 "\<lbrakk>\<not>finite A; B \<noteq> {}; |B| \<le>o |A|\<rbrakk> \<Longrightarrow> |A \<times> B| =o |A|"
  1046 "\<lbrakk>\<not>finite A; B \<noteq> {}; |B| \<le>o |A|\<rbrakk> \<Longrightarrow> |A| =o |A \<times> B|"
  1046 "\<lbrakk>\<not>finite A; B \<noteq> {}; |B| \<le>o |A|\<rbrakk> \<Longrightarrow> |A| =o |A \<times> B|"
  1617 
  1617 
  1618 
  1618 
  1619 subsection \<open>Others\<close>
  1619 subsection \<open>Others\<close>
  1620 
  1620 
  1621 lemma card_of_Func_Times:
  1621 lemma card_of_Func_Times:
  1622 "|Func (A <*> B) C| =o |Func A (Func B C)|"
  1622 "|Func (A \<times> B) C| =o |Func A (Func B C)|"
  1623 unfolding card_of_ordIso[symmetric]
  1623 unfolding card_of_ordIso[symmetric]
  1624 using bij_betw_curr by blast
  1624 using bij_betw_curr by blast
  1625 
  1625 
  1626 lemma card_of_Pow_Func:
  1626 lemma card_of_Pow_Func:
  1627 "|Pow A| =o |Func A (UNIV::bool set)|"
  1627 "|Pow A| =o |Func A (UNIV::bool set)|"
  1659     thus "h \<in> (\<lambda>f a. f a) ` {f. range f \<subseteq> B}" using f by auto
  1659     thus "h \<in> (\<lambda>f a. f a) ` {f. range f \<subseteq> B}" using f by auto
  1660   qed(unfold Func_def fun_eq_iff, auto)
  1660   qed(unfold Func_def fun_eq_iff, auto)
  1661 qed
  1661 qed
  1662 
  1662 
  1663 lemma Func_Times_Range:
  1663 lemma Func_Times_Range:
  1664   "|Func A (B <*> C)| =o |Func A B <*> Func A C|" (is "|?LHS| =o |?RHS|")
  1664   "|Func A (B \<times> C)| =o |Func A B \<times> Func A C|" (is "|?LHS| =o |?RHS|")
  1665 proof -
  1665 proof -
  1666   let ?F = "\<lambda>fg. (\<lambda>x. if x \<in> A then fst (fg x) else undefined,
  1666   let ?F = "\<lambda>fg. (\<lambda>x. if x \<in> A then fst (fg x) else undefined,
  1667                   \<lambda>x. if x \<in> A then snd (fg x) else undefined)"
  1667                   \<lambda>x. if x \<in> A then snd (fg x) else undefined)"
  1668   let ?G = "\<lambda>(f, g) x. if x \<in> A then (f x, g x) else undefined"
  1668   let ?G = "\<lambda>(f, g) x. if x \<in> A then (f x, g x) else undefined"
  1669   have "bij_betw ?F ?LHS ?RHS" unfolding bij_betw_def inj_on_def
  1669   have "bij_betw ?F ?LHS ?RHS" unfolding bij_betw_def inj_on_def