diff --git a/thys/Independence_CH/CH.thy b/thys/Independence_CH/CH.thy --- a/thys/Independence_CH/CH.thy +++ b/thys/Independence_CH/CH.thy @@ -1,442 +1,438 @@ section\Forcing extension satisfying the Continuum Hypothesis\ theory CH imports Kappa_Closed_Notions Cohen_Posets_Relative begin -context M_ctm3_AC +context M_ctm2_AC begin declare Fn_rel_closed[simp del, rule del, simplified setclass_iff, simp, intro] declare Fnle_rel_closed[simp del, rule del, simplified setclass_iff, simp, intro] abbreviation Coll :: "i" where "Coll \ Fn\<^bsup>M\<^esup>(\\<^bsub>1\<^esub>\<^bsup>M\<^esup>, \\<^bsub>1\<^esub>\<^bsup>M\<^esup>, \ \\<^bsup>M\<^esup> 2)" abbreviation Colleq :: "i" where "Colleq \ Fnle\<^bsup>M\<^esup>(\\<^bsub>1\<^esub>\<^bsup>M\<^esup>, \\<^bsub>1\<^esub>\<^bsup>M\<^esup>, \ \\<^bsup>M\<^esup> 2)" lemma Coll_in_M[intro,simp]: "Coll \ M" by simp lemma Colleq_refl : "refl(Coll,Colleq)" unfolding Fnle_rel_def Fnlerel_def refl_def using RrelI by simp subsection\Collapse forcing is sufficiently closed\ \ \Kunen IV.7.14, only for \<^term>\\\<^bsub>1\<^esub>\\ lemma succ_omega_closed_Coll: "succ(\)-closed\<^bsup>M\<^esup>(Coll,Colleq)" proof - \ \Case for finite sequences\ have "n\\ \ \f \ n \<^sub><\\<^bsup>M\<^esup> (Coll,converse(Colleq)). \q\M. q \ Coll \ (\\\M. \ \ n \ \q, f ` \\ \ Colleq)" for n proof (induct rule:nat_induct) case 0 then show ?case using zero_lt_Aleph_rel1 zero_in_Fn_rel by (auto simp del:setclass_iff) (rule bexI[OF _ zero_in_M], auto) next case (succ x) then have "\f\succ(x) \<^sub><\\<^bsup>M\<^esup> (Coll,converse(Colleq)). \\ \ succ(x). \f`x, f ` \\ \ Colleq" proof(intro ballI) fix f \ assume "f\succ(x) \<^sub><\\<^bsup>M\<^esup> (Coll,converse(Colleq))" "\\succ(x)" moreover from \x\\\ this have "f\succ(x) \<^sub><\ (Coll,converse(Colleq))" using mono_seqspace_rel_char nat_into_M by simp moreover from calculation succ consider "\\x" | "\=x" by auto then show "\f`x, f ` \\ \ Colleq" proof(cases) case 1 then have "\\, x\ \ Memrel(succ(x))" "x\succ(x)" "\\succ(x)" by auto with \f\succ(x) \<^sub><\ (Coll,converse(Colleq))\ show ?thesis using mono_mapD(2)[OF _ \\\succ(x)\ _ \\\, x\ \ Memrel(succ(x))\] unfolding mono_seqspace_def by auto next case 2 with \f\succ(x) \<^sub><\ (Coll,converse(Colleq))\ show ?thesis using Colleq_refl mono_seqspace_is_fun[THEN apply_type] unfolding refl_def by simp qed qed moreover note \x\\\ moreover from this have "f`x \ Coll" if "f: succ(x) \<^sub><\\<^bsup>M\<^esup> (Coll,converse(Colleq))" for f using that mono_seqspace_rel_char[simplified, of "succ(x)" Coll "converse(Colleq)"] nat_into_M[simplified] mono_seqspace_is_fun[of "converse(Colleq)"] by (intro apply_type[of _ "succ(x)"]) (auto simp del:setclass_iff) ultimately show ?case using transM[of _ Coll] by (auto dest:transM simp del:setclass_iff, rule_tac x="f`x" in bexI) (auto simp del:setclass_iff, simp) qed moreover \ \Interesting case: Countably infinite sequences.\ have "\f\M. f \ \ \<^sub><\\<^bsup>M\<^esup> (Coll,converse(Colleq)) \ (\q\M. q \ Coll \ (\\\M. \ \ \ \ \q, f ` \\ \ Colleq))" proof(intro ballI impI) fix f let ?rnf="f``\" assume "f\M" "f \ \ \<^sub><\\<^bsup>M\<^esup> (Coll,converse(Colleq))" moreover from this have "f\\ \<^sub><\ (Coll,converse(Colleq))" "f\\ \ Coll" using mono_seqspace_rel_char mono_mapD(2) nat_in_M by auto moreover from this have "countable\<^bsup>M\<^esup>(f`x)" if "x\\" for x using that Fn_rel_is_function countable_iff_lesspoll_rel_Aleph_rel_one by auto moreover from calculation have "?rnf \ M" "f\\\Coll" using nat_in_M image_closed Pi_iff by simp_all moreover from calculation have 1:"\d\?rnf. d \ h \ d \ g" if "h \ ?rnf" "g \ ?rnf" for h g proof - from calculation have "?rnf={f`x . x\\}" using image_function[of f \] Pi_iff domain_of_fun by auto from \?rnf=_\ that obtain m n where eq:"h=f`m" "g=f`n" "n\\" "m\\" by auto then have "m\n\\" "m\m\n" "n\m\n" using Un_upper1_le Un_upper2_le nat_into_Ord by simp_all with calculation eq \?rnf=_\ have "f`(m\n)\?rnf" "f`(m\n) \ h" "f`(m\n) \ g" using Fnle_relD mono_map_lt_le_is_mono converse_refl[OF Colleq_refl] by auto then show ?thesis by auto qed moreover from calculation have "?rnf \ (\\<^bsub>1\<^esub>\<^bsup>M\<^esup> \\<^bsup>##M\<^esup> (nat \\<^bsup>M\<^esup> 2))" using subset_trans[OF image_subset[OF \f\_\,of \] Fn_rel_subset_PFun_rel] by simp moreover have "\ ?rnf \ (\\<^bsub>1\<^esub>\<^bsup>M\<^esup> \\<^bsup>##M\<^esup> (nat \\<^bsup>M\<^esup> 2))" using pfun_Un_filter_closed'[OF \?rnf\_\ 1] \?rnf\M\ by simp moreover from calculation have "\?rnf \\<^bsup>M\<^esup> \\<^bsub>1\<^esub>\<^bsup>M\<^esup>" using countable_fun_imp_countable_image[of f] mem_function_space_rel_abs[simplified,OF nat_in_M Coll_in_M \f\M\] countableI[OF lepoll_rel_refl] countable_iff_lesspoll_rel_Aleph_rel_one[of "\?rnf"] by auto moreover from calculation have "\?rnf\Coll" unfolding Fn_rel_def by simp moreover from calculation have "\?rnf \ f ` \ " if "\\\" for \ using that image_function[OF fun_is_function] domain_of_fun by auto ultimately show "\q\M. q \ Coll \ (\\\M. \ \ \ \ \q, f ` \\ \ Colleq)" using Fn_rel_is_function Fnle_relI by auto qed ultimately show ?thesis unfolding kappa_closed_rel_def by (auto elim!:leE dest:ltD) qed -end \ \\<^locale>\M_ctm3_AC\\ +end \ \\<^locale>\M_ctm2_AC\\ -sublocale M_ZFC3_trans \ M_library "##M" - by unfold_locales (simp_all add:repl_instances sep_instances del:setclass_iff - add: transrec_replacement_def wfrec_replacement_def) - -locale collapse_CH = G_generic4_AC_CH "Fn\<^bsup>M\<^esup>(\\<^bsub>1\<^esub>\<^bsup>##M\<^esup>, \\<^bsub>1\<^esub>\<^bsup>M\<^esup>, \ \\<^bsup>M\<^esup> 2)" "Fnle\<^bsup>M\<^esup>(\\<^bsub>1\<^esub>\<^bsup>##M\<^esup>, \\<^bsub>1\<^esub>\<^bsup>M\<^esup>, \ \\<^bsup>M\<^esup> 2)" 0 +locale collapse_CH = G_generic3_AC_CH "Fn\<^bsup>M\<^esup>(\\<^bsub>1\<^esub>\<^bsup>##M\<^esup>, \\<^bsub>1\<^esub>\<^bsup>M\<^esup>, \ \\<^bsup>M\<^esup> 2)" "Fnle\<^bsup>M\<^esup>(\\<^bsub>1\<^esub>\<^bsup>##M\<^esup>, \\<^bsub>1\<^esub>\<^bsup>M\<^esup>, \ \\<^bsup>M\<^esup> 2)" 0 sublocale collapse_CH \ forcing_notion "Coll" "Colleq" 0 using zero_lt_Aleph_rel1 by unfold_locales context collapse_CH begin notation Leq (infixl "\" 50) notation Incompatible (infixl "\" 50) abbreviation f_G :: "i" (\f\<^bsub>G\<^esub>\) where "f\<^bsub>G\<^esub> \ \G" lemma f_G_in_MG[simp]: shows "f\<^bsub>G\<^esub> \ M[G]" using G_in_MG by simp abbreviation dom_dense :: "i\i" where "dom_dense(x) \ { p\Coll . x \ domain(p) }" lemma dom_dense_closed[intro,simp]: "x\M \ dom_dense(x) \ M" using separation_in_domain[of x] by simp lemma domain_f_G: assumes "x \ \\<^bsub>1\<^esub>\<^bsup>M\<^esup>" shows "x \ domain(f\<^bsub>G\<^esub>)" proof - have "(\n\\. 0) \ \ \\<^bsup>M\<^esup> 2" using function_space_rel_nonempty[of 0 2 \] by auto with assms have "dense(dom_dense(x))" "x\M" using dense_dom_dense InfCard_rel_Aleph_rel[of 1] transitivity[OF _ Aleph_rel_closed[of 1,THEN setclass_iff[THEN iffD1]]] unfolding dense_def by auto with assms obtain p where "p\dom_dense(x)" "p\G" using M_generic_denseD[of "dom_dense(x)"] by auto then show "x \ domain(f\<^bsub>G\<^esub>)" by blast qed lemma Un_filter_is_function: assumes "filter(G)" shows "function(\G)" proof - have "Coll \ \\<^bsub>1\<^esub>\<^bsup>M\<^esup> \\<^bsup>##M\<^esup> (\ \\<^bsup>M\<^esup> 2)" using Fn_rel_subset_PFun_rel by simp moreover have "\ d \ Coll. d \ f \ d \ g" if "f\G" "g\G" for f g using filter_imp_compat[OF assms \f\G\ \g\G\] filterD[OF assms] unfolding compat_def compat_in_def by auto ultimately have "\d \ \\<^bsub>1\<^esub>\<^bsup>M\<^esup> \\<^bsup>##M\<^esup> (\ \\<^bsup>M\<^esup> 2). d \ f \ d \ g" if "f\G" "g\G" for f g using rex_mono[of Coll] that by simp moreover have "G\Coll" using assms unfolding filter_def by simp moreover from this have "G \ \\<^bsub>1\<^esub>\<^bsup>M\<^esup> \\<^bsup>##M\<^esup> (\ \\<^bsup>M\<^esup> 2)" using assms unfolding Fn_rel_def by auto ultimately show ?thesis using pfun_Un_filter_closed[of G] by simp qed lemma f_G_funtype: shows "f\<^bsub>G\<^esub> : \\<^bsub>1\<^esub>\<^bsup>M\<^esup> \ \ \\<^bsup>M[G]\<^esup> 2" proof - have "x \ B \ B \ G \ x \ \\<^bsub>1\<^esub>\<^bsup>M\<^esup> \ (\ \\<^bsup>M[G]\<^esup> 2)" for B x proof - assume "x\B" "B\G" moreover from this have "x \ M[G]" by (auto dest!: ext.transM simp add:G_in_MG) moreover from calculation have "x \ \\<^bsub>1\<^esub>\<^bsup>M\<^esup> \ (\ \ 2)" using Fn_rel_subset_Pow[of "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "\ \\<^bsup>M\<^esup> 2", OF _ _ function_space_rel_closed] function_space_rel_char by (auto dest!: M_genericD) moreover from this obtain z w where "x=\z,w\" "z\\\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "w:\ \ 2" by auto moreover from calculation have "w \ M[G]" by (auto dest:ext.transM) ultimately show ?thesis using ext.function_space_rel_char by auto qed moreover have "function(f\<^bsub>G\<^esub>)" using Un_filter_is_function generic by fast ultimately show ?thesis using generic domain_f_G Pi_iff by auto qed abbreviation surj_dense :: "i\i" where "surj_dense(x) \ { p\Coll . x \ range(p) }" lemma surj_dense_closed[intro,simp]: "x \ \ \\<^bsup>M\<^esup> 2 \ surj_dense(x) \ M" using separation_in_range transM[of x] by simp lemma reals_sub_image_f_G: assumes "x \ \ \\<^bsup>M\<^esup> 2" shows "\\\\\<^bsub>1\<^esub>\<^bsup>M\<^esup>. f\<^bsub>G\<^esub> ` \ = x" proof - from assms have "dense(surj_dense(x))" using dense_surj_dense lepoll_rel_refl InfCard_rel_Aleph_rel unfolding dense_def by auto with \x \ \ \\<^bsup>M\<^esup> 2\ obtain p where "p\surj_dense(x)" "p\G" using M_generic_denseD[of "surj_dense(x)"] by blast then show ?thesis using succ_omega_closed_Coll f_G_funtype function_apply_equality[of _ x f_G] succ_omega_closed_imp_no_new_reals[symmetric] by (auto, rule_tac bexI) (auto simp:Pi_def) qed lemma f_G_surj_Aleph_rel1_reals: "f\<^bsub>G\<^esub> \ surj\<^bsup>M[G]\<^esup>(\\<^bsub>1\<^esub>\<^bsup>M\<^esup>, \ \\<^bsup>M[G]\<^esup> 2)" using Aleph_rel_sub_closed proof (intro ext.mem_surj_abs[THEN iffD2],simp_all) show "f\<^bsub>G\<^esub> \ surj(\\<^bsub>1\<^esub>\<^bsup>M\<^esup>, \ \\<^bsup>M[G]\<^esup> 2)" using f_G_funtype G_in_MG ext.nat_into_M f_G_in_MG reals_sub_image_f_G succ_omega_closed_Coll succ_omega_closed_imp_no_new_reals unfolding surj_def by auto qed lemma continuum_rel_le_Aleph1_extension: includes G_generic1_lemmas shows "2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup> \ \\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup>" proof - have "\\<^bsub>1\<^esub>\<^bsup>M\<^esup> \ M[G]" "Ord(\\<^bsub>1\<^esub>\<^bsup>M\<^esup>)" using Card_rel_is_Ord by auto moreover from this have "\ \\<^bsup>M[G]\<^esup> 2 \\<^bsup>M[G]\<^esup> \\<^bsub>1\<^esub>\<^bsup>M\<^esup>" using ext.surj_rel_implies_inj_rel[OF f_G_surj_Aleph_rel1_reals] f_G_in_MG unfolding lepoll_rel_def by auto with \Ord(\\<^bsub>1\<^esub>\<^bsup>M\<^esup>)\ have "|\ \\<^bsup>M[G]\<^esup> 2|\<^bsup>M[G]\<^esup> \ |\\<^bsub>1\<^esub>\<^bsup>M\<^esup>|\<^bsup>M[G]\<^esup>" using M_subset_MG[OF one_in_G] Aleph_rel_closed[of 1] by (rule_tac ext.lepoll_rel_imp_cardinal_rel_le) simp_all ultimately have "2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup> \ |\\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup>|\<^bsup>M[G]\<^esup>" using ext.lepoll_rel_imp_cardinal_rel_le[of "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "\ \\<^bsup>M[G]\<^esup> 2"] ext.Aleph_rel_zero succ_omega_closed_Coll succ_omega_closed_imp_Aleph_1_preserved unfolding cexp_rel_def by simp then show "2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup> \ \\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup>" by simp qed theorem CH: "\\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup> = 2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup>" using continuum_rel_le_Aleph1_extension ext.Aleph_rel_succ[of 0] ext.Aleph_rel_zero ext.csucc_rel_le[of "2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup>" \] ext.Card_rel_cexp_rel ext.cantor_cexp_rel[of \] ext.Card_rel_nat le_anti_sym by auto end \ \\<^locale>\collapse_CH\\ subsection\Models of fragments of $\ZFC + \CH$\ theorem ctm_of_CH: assumes "M \ \" "Transset(M)" "M \ ZC \ {\Replacement(p)\ . p \ overhead_CH}" "\ \ formula" "M \ { \Replacement(ground_repl_fm(\))\ . \ \ \}" shows "\N. M \ N \ N \ \ \ Transset(N) \ N \ ZC \ {\CH\} \ { \Replacement(\)\ . \ \ \} \ (\\. Ord(\) \ (\ \ M \ \ \ N))" proof - from \M \ ZC \ {\Replacement(p)\ . p \ overhead_CH}\ - interpret M_ZFC4 M - using M_satT_overhead_imp_M_ZF4 unfolding overhead_CH_def overhead_notCH_def by auto + interpret M_ZFC3 M + using M_satT_overhead_imp_M_ZF3 unfolding overhead_CH_def overhead_notCH_def by auto from \M \ ZC \ {\Replacement(p)\ . p \ overhead_CH}\ \Transset(M)\ interpret M_ZF_ground_CH_trans M using M_satT_imp_M_ZF_ground_CH_trans unfolding ZC_def by auto from \M \ \\ obtain enum where "enum \ bij(\,M)" using eqpoll_sym unfolding eqpoll_def by blast then - interpret M_ctm3_AC_CH M enum by unfold_locales + interpret M_ctm2_AC_CH M enum by unfold_locales interpret forcing_data1 "Coll" "Colleq" 0 M enum using zero_in_Fn_rel[of "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "\ \\<^bsup>M\<^esup> 2"] zero_top_Fn_rel[of _ "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "\ \\<^bsup>M\<^esup> 2"] preorder_on_Fnle_rel[of "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "\ \\<^bsup>M\<^esup> 2"] zero_lt_Aleph_rel1 by unfold_locales simp_all obtain G where "M_generic(G)" using generic_filter_existence[OF one_in_P] by auto moreover from this interpret collapse_CH M enum G by unfold_locales have "\\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup> = 2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup>" using CH . then have "M[G], [] \ \CH\" using ext.is_ContHyp_iff by (simp add:ContHyp_rel_def) then have "M[G] \ ZC \ {\CH\}" using ext.M_satT_ZC by auto moreover have "Transset(M[G])" using Transset_MG . moreover have "M \ M[G]" using M_subset_MG[OF one_in_G] generic by simp moreover note \M \ { \Replacement(ground_repl_fm(\))\ . \ \ \}\ \\ \ formula\ ultimately show ?thesis using Ord_MG_iff MG_eqpoll_nat satT_ground_repl_fm_imp_satT_ZF_replacement_fm[of \] by (rule_tac x="M[G]" in exI,blast) qed corollary ctm_ZFC_imp_ctm_CH: assumes "M \ \" "Transset(M)" "M \ ZFC" shows "\N. M \ N \ N \ \ \ Transset(N) \ N \ ZFC \ {\CH\} \ (\\. Ord(\) \ (\ \ M \ \ \ N))" proof - from assms have "\N. M \ N \ N \ \ \ Transset(N) \ N \ ZC \ N \ {\CH\} \ N \ {\Replacement(x)\ . x \ formula} \ (\\. Ord(\) \ \ \ M \ \ \ N)" using ctm_of_CH[of M formula] satT_ZFC_imp_satT_ZC[of M] satT_mono[OF _ ground_repl_fm_sub_ZFC, of M] satT_mono[OF _ ZF_replacement_overhead_CH_sub_ZFC, of M] satT_mono[OF _ ZF_replacement_fms_sub_ZFC, of M] by (simp add: satT_Un_iff) then obtain N where "N \ ZC" "N \ {\CH\}" "N \ {\Replacement(x)\ . x \ formula}" "M \ N" "N \ \" "Transset(N)" "(\\. Ord(\) \ \ \ M \ \ \ N)" by auto moreover from this have "N \ ZFC" using satT_ZC_ZF_replacement_imp_satT_ZFC by auto moreover from this and \N \ {\CH\}\ have "N \ ZFC \ {\CH\}" using satT_ZC_ZF_replacement_imp_satT_ZFC by auto ultimately show ?thesis by auto qed end \ No newline at end of file diff --git a/thys/Independence_CH/Cardinal_Preservation.thy b/thys/Independence_CH/Cardinal_Preservation.thy --- a/thys/Independence_CH/Cardinal_Preservation.thy +++ b/thys/Independence_CH/Cardinal_Preservation.thy @@ -1,488 +1,488 @@ section\Preservation of cardinals in generic extensions\ theory Cardinal_Preservation imports Forcing_Main begin context forcing_data1 begin lemma antichain_abs' [absolut]: "\ A\M \ \ antichain\<^bsup>M\<^esup>(P,leq,A) \ antichain(P,leq,A)" unfolding antichain_rel_def antichain_def compat_def using transitivity[of _ A] by (auto simp add:absolut) lemma inconsistent_imp_incompatible: assumes "p \ \ env" "q \ Neg(\) env" "p\P" "q\P" "arity(\) \ length(env)" "\ \ formula" "env \ list(M)" shows "p \ q" proof assume "compat(p,q)" then obtain d where "d \ p" "d \ q" "d \ P" by blast moreover note assms moreover from calculation have "d \ \ env" "d \ Neg(\) env" using strengthening_lemma by simp_all ultimately show "False" using Forces_Neg[of d env \] refl_leq by (auto dest:transitivity; drule_tac bspec; auto dest:transitivity) qed notation check (\_\<^sup>v\ [101] 100) end \ \\<^locale>\forcing_data1\\ +locale G_generic2 = G_generic1 + forcing_data2 +locale G_generic2_AC = G_generic1_AC + G_generic2 + locale G_generic3 = G_generic2 + forcing_data3 locale G_generic3_AC = G_generic2_AC + G_generic3 -locale G_generic4 = G_generic3 + forcing_data4 -locale G_generic4_AC = G_generic3_AC + G_generic4 +locale G_generic3_AC_CH = G_generic3_AC + M_ZFC2_ground_CH_trans -locale G_generic4_AC_CH = G_generic4_AC + M_ZFC3_ground_CH_trans - -sublocale G_generic4_AC \ ext:M_ZFC3_trans "M[G]" - using ground_replacements4 replacement_assm_MG +sublocale G_generic3_AC \ ext:M_ZFC2_trans "M[G]" + using ground_replacements3 replacement_assm_MG by unfold_locales simp_all lemma (in forcing_data1) forces_neq_apply_imp_incompatible: assumes "p \ \0`1 is 2\ [f,a,b\<^sup>v]" "q \ \0`1 is 2\ [f,a,b'\<^sup>v]" "b \ b'" \ \More general version: taking general names \<^term>\b\<^sup>v\ and \<^term>\b'\<^sup>v\, satisfying \<^term>\p \ \\\0 = 1\\ [b\<^sup>v, b'\<^sup>v]\ and \<^term>\q \ \\\0 = 1\\ [b\<^sup>v, b'\<^sup>v]\.\ and types:"f\M" "a\M" "b\M" "b'\M" "p\P" "q\P" shows "p \ q" proof - { fix G assume "M_generic(G)" then interpret G_generic1 _ _ _ _ _ G by unfold_locales include G_generic1_lemmas assume "q\G" with assms \M_generic(G)\ have "M[G], map(val(G),[f,a,b'\<^sup>v]) \ \0`1 is 2\" using truth_lemma[of "\0`1 is 2\" "[f,a,b'\<^sup>v]"] by (auto simp add:ord_simp_union arity_fun_apply_fm fun_apply_type) with \b \ b'\ types have "M[G], map(val(G),[f,a,b\<^sup>v]) \ \\\0`1 is 2\\" using GenExtI by auto } with types have "q \ \\\0`1 is 2\\ [f,a,b\<^sup>v]" using definition_of_forcing[where \="\\\0`1 is 2\\" ] by (auto simp add:ord_simp_union arity_fun_apply_fm) with \p \ \0`1 is 2\ [f,a,b\<^sup>v]\ and types show "p \ q" using inconsistent_imp_incompatible by (simp add:ord_simp_union arity_fun_apply_fm fun_apply_type) qed -context M_ctm3_AC +context M_ctm2_AC begin \ \Simplifying simp rules (because of the occurrence of \<^term>\setclass\)\ lemmas sharp_simps = Card_rel_Union Card_rel_cardinal_rel Collect_abs Cons_abs Cons_in_M_iff Diff_closed Equal_abs Equal_in_M_iff Finite_abs Forall_abs Forall_in_M_iff Inl_abs Inl_in_M_iff Inr_abs Inr_in_M_iff Int_closed Inter_abs Inter_closed M_nat Member_abs Member_in_M_iff Memrel_closed Nand_abs Nand_in_M_iff Nil_abs Nil_in_M Ord_cardinal_rel Pow_rel_closed Un_closed Union_abs Union_closed and_abs and_closed apply_abs apply_closed bij_rel_closed bijection_abs bool_of_o_abs bool_of_o_closed cadd_rel_0 cadd_rel_closed cardinal_rel_0_iff_0 cardinal_rel_closed cardinal_rel_idem cartprod_abs cartprod_closed cmult_rel_0 cmult_rel_1 cmult_rel_closed comp_closed composition_abs cons_abs cons_closed converse_abs converse_closed csquare_lam_closed csquare_rel_closed depth_closed domain_abs domain_closed eclose_abs eclose_closed empty_abs field_abs field_closed finite_funspace_closed finite_ordinal_abs formula_N_abs formula_N_closed formula_abs formula_case_abs formula_case_closed formula_closed formula_functor_abs fst_closed function_abs function_space_rel_closed hd_abs image_abs image_closed inj_rel_closed injection_abs inter_abs irreflexive_abs is_depth_apply_abs is_eclose_n_abs is_funspace_abs iterates_closed length_abs length_closed lepoll_rel_refl limit_ordinal_abs linear_rel_abs list_N_abs list_N_closed list_abs list_case'_closed list_case_abs list_closed list_functor_abs mem_bij_abs mem_eclose_abs mem_inj_abs mem_list_abs membership_abs minimum_closed nat_case_abs nat_case_closed nonempty not_abs not_closed nth_abs number1_abs number2_abs number3_abs omega_abs or_abs or_closed order_isomorphism_abs ordermap_closed ordertype_closed ordinal_abs pair_abs pair_in_M_iff powerset_abs pred_closed pred_set_abs quasilist_abs quasinat_abs radd_closed rall_abs range_abs range_closed relation_abs restrict_closed restriction_abs rex_abs rmult_closed rtrancl_abs rtrancl_closed rvimage_closed separation_closed setdiff_abs singleton_abs singleton_in_M_iff snd_closed strong_replacement_closed subset_abs succ_in_M_iff successor_abs successor_ordinal_abs sum_abs sum_closed surj_rel_closed surjection_abs tl_abs trancl_abs trancl_closed transitive_rel_abs transitive_set_abs typed_function_abs union_abs upair_abs upair_in_M_iff vimage_abs vimage_closed well_ord_abs mem_formula_abs nth_closed Aleph_rel_closed csucc_rel_closed Card_rel_Aleph_rel declare sharp_simps[simp del, simplified setclass_iff, simp] lemmas sharp_intros = nat_into_M Aleph_rel_closed Card_rel_Aleph_rel declare sharp_intros[rule del, simplified setclass_iff, intro] -end \ \\<^locale>\M_ctm3_AC\\ +end \ \\<^locale>\M_ctm2_AC\\ -context G_generic4_AC begin +context G_generic3_AC begin context includes G_generic1_lemmas begin lemmas mg_sharp_simps = ext.Card_rel_Union ext.Card_rel_cardinal_rel ext.Collect_abs ext.Cons_abs ext.Cons_in_M_iff ext.Diff_closed ext.Equal_abs ext.Equal_in_M_iff ext.Finite_abs ext.Forall_abs ext.Forall_in_M_iff ext.Inl_abs ext.Inl_in_M_iff ext.Inr_abs ext.Inr_in_M_iff ext.Int_closed ext.Inter_abs ext.Inter_closed ext.M_nat ext.Member_abs ext.Member_in_M_iff ext.Memrel_closed ext.Nand_abs ext.Nand_in_M_iff ext.Nil_abs ext.Nil_in_M ext.Ord_cardinal_rel ext.Pow_rel_closed ext.Un_closed ext.Union_abs ext.Union_closed ext.and_abs ext.and_closed ext.apply_abs ext.apply_closed ext.bij_rel_closed ext.bijection_abs ext.bool_of_o_abs ext.bool_of_o_closed ext.cadd_rel_0 ext.cadd_rel_closed ext.cardinal_rel_0_iff_0 ext.cardinal_rel_closed ext.cardinal_rel_idem ext.cartprod_abs ext.cartprod_closed ext.cmult_rel_0 ext.cmult_rel_1 ext.cmult_rel_closed ext.comp_closed ext.composition_abs ext.cons_abs ext.cons_closed ext.converse_abs ext.converse_closed ext.csquare_lam_closed ext.csquare_rel_closed ext.depth_closed ext.domain_abs ext.domain_closed ext.eclose_abs ext.eclose_closed ext.empty_abs ext.field_abs ext.field_closed ext.finite_funspace_closed ext.finite_ordinal_abs ext.formula_N_abs ext.formula_N_closed ext.formula_abs ext.formula_case_abs ext.formula_case_closed ext.formula_closed ext.formula_functor_abs ext.fst_closed ext.function_abs ext.function_space_rel_closed ext.hd_abs ext.image_abs ext.image_closed ext.inj_rel_closed ext.injection_abs ext.inter_abs ext.irreflexive_abs ext.is_depth_apply_abs ext.is_eclose_n_abs ext.is_funspace_abs ext.iterates_closed ext.length_abs ext.length_closed ext.lepoll_rel_refl ext.limit_ordinal_abs ext.linear_rel_abs ext.list_N_abs ext.list_N_closed ext.list_abs ext.list_case'_closed ext.list_case_abs ext.list_closed ext.list_functor_abs ext.mem_bij_abs ext.mem_eclose_abs ext.mem_inj_abs ext.mem_list_abs ext.membership_abs ext.nat_case_abs ext.nat_case_closed ext.nonempty ext.not_abs ext.not_closed ext.nth_abs ext.number1_abs ext.number2_abs ext.number3_abs ext.omega_abs ext.or_abs ext.or_closed ext.order_isomorphism_abs ext.ordermap_closed ext.ordertype_closed ext.ordinal_abs ext.pair_abs ext.pair_in_M_iff ext.powerset_abs ext.pred_closed ext.pred_set_abs ext.quasilist_abs ext.quasinat_abs ext.radd_closed ext.rall_abs ext.range_abs ext.range_closed ext.relation_abs ext.restrict_closed ext.restriction_abs ext.rex_abs ext.rmult_closed ext.rtrancl_abs ext.rtrancl_closed ext.rvimage_closed ext.separation_closed ext.setdiff_abs ext.singleton_abs ext.singleton_in_M_iff ext.snd_closed ext.strong_replacement_closed ext.subset_abs ext.succ_in_M_iff ext.successor_abs ext.successor_ordinal_abs ext.sum_abs ext.sum_closed ext.surj_rel_closed ext.surjection_abs ext.tl_abs ext.trancl_abs ext.trancl_closed ext.transitive_rel_abs ext.transitive_set_abs ext.typed_function_abs ext.union_abs ext.upair_abs ext.upair_in_M_iff ext.vimage_abs ext.vimage_closed ext.well_ord_abs ext.mem_formula_abs ext.nth_closed ext.Aleph_rel_closed ext.csucc_rel_closed ext.Card_rel_Aleph_rel \ \The following was motivated by the fact that @{thm [source] ext.apply_closed} did not simplify appropriately.\ declare mg_sharp_simps[simp del, simplified setclass_iff, simp] lemmas mg_sharp_intros = ext.nat_into_M ext.Aleph_rel_closed ext.Card_rel_Aleph_rel declare mg_sharp_intros[rule del, simplified setclass_iff, intro] \ \Kunen IV.2.31\ lemma forces_below_filter: assumes "M[G], map(val(G),env) \ \" "p \ G" "arity(\) \ length(env)" "\ \ formula" "env \ list(M)" shows "\q\G. q \ p \ q \ \ env" proof - note assms moreover from this obtain r where "r \ \ env" "r\G" using generic truth_lemma[of \ env] by blast moreover from this and \p\G\ obtain q where "q \ p" "q \ r" "q \ G" by auto ultimately show ?thesis using strengthening_lemma[of r \ _ env] by blast qed subsection\Preservation by ccc forcing notions\ lemma ccc_fun_closed_lemma_aux: assumes "f_dot\M" "p\M" "a\M" "b\M" shows "{q \ P . q \ p \ (M, [q, P, leq, \, f_dot, a\<^sup>v, b\<^sup>v] \ forces(\0`1 is 2\ ))} \ M" using separation_forces[where env="[f_dot, a\<^sup>v, b\<^sup>v]" and \="\0`1 is 2\",simplified] assms G_subset_M[THEN subsetD] generic separation_in lam_replacement_constant lam_replacement_identity lam_replacement_product separation_conj arity_fun_apply_fm union_abs1 by simp_all lemma ccc_fun_closed_lemma_aux2: assumes "B\M" "f_dot\M" "p\M" "a\M" shows "(##M)(\b\B. {q \ P . q \ p \ (M, [q, P, leq, \, f_dot, a\<^sup>v, b\<^sup>v] \ forces(\0`1 is 2\ ))})" proof - have "separation(##M, \z. M, [snd(z), P, leq, \, f_dot, \, fst(z)\<^sup>v] \ forces(\0`1 is 2\ ))" if "\\M" for \ proof - let ?f_fm="snd_fm(1,0)" let ?g_fm="hcomp_fm(check_fm(6),fst_fm,2,0)" note assms moreover have "arity(forces(\0`1 is 2\ )) \ 7" using arity_fun_apply_fm union_abs1 arity_forces[of "\0`1 is 2\ "] by simp moreover have "?f_fm \ formula" "arity(?f_fm) \ 7" "?g_fm \ formula" "arity(?g_fm) \ 8" using ord_simp_union unfolding hcomp_fm_def by (simp_all add:arity) ultimately show ?thesis using separation_sat_after_function assms that sats_fst_fm snd_abs sats_snd_fm sats_check_fm check_abs fst_abs unfolding hcomp_fm_def by simp qed with assms show ?thesis using lam_replacement_imp_lam_closed separation_conj separation_in lam_replacement_product lam_replacement_constant transitivity[of _ B] lam_replacement_snd lam_replacement_Collect' ccc_fun_closed_lemma_aux by simp qed lemma ccc_fun_closed_lemma: assumes "A\M" "B\M" "f_dot\M" "p\M" shows "(\a\A. {b\B. \q\P. q \ p \ (q \ \0`1 is 2\ [f_dot, a\<^sup>v, b\<^sup>v])}) \ M" proof - have "separation(##M, \z. M, [snd(z), P, leq, \, f_dot, fst(fst(z))\<^sup>v, snd(fst(z))\<^sup>v] \ forces(\0`1 is 2\ ))" proof - let ?f_fm="snd_fm(1,0)" let ?g="\z . fst(fst(fst(z)))\<^sup>v" let ?g_fm="hcomp_fm(check_fm(6),hcomp_fm(fst_fm,fst_fm),2,0)" let ?h_fm="hcomp_fm(check_fm(7),hcomp_fm(snd_fm,fst_fm),3,0)" note assms moreover have "arity(forces(\0`1 is 2\ )) \ 7" using arity_fun_apply_fm union_abs1 arity_forces[of "\0`1 is 2\ "] by simp moreover have "?f_fm \ formula" "arity(?f_fm) \ 6" "?g_fm \ formula" "arity(?g_fm) \ 7" "?h_fm \ formula" "arity(?h_fm) \ 8" using ord_simp_union unfolding hcomp_fm_def by (simp_all add:arity) ultimately show ?thesis using separation_sat_after_function3 assms sats_check_fm check_abs fst_abs snd_abs unfolding hcomp_fm_def by simp qed moreover have 1:"separation(##M, \z. M, [snd(z), P, leq, \, f_dot, \, fst(z)\<^sup>v] \ forces(\0`1 is 2\ ))" if "\\M" for \ proof - let ?f_fm="snd_fm(1,0)" let ?g_fm="hcomp_fm(check_fm(6),fst_fm,2,0)" note assms moreover have "arity(forces(\0`1 is 2\ )) \ 7" using arity_forces[of "\0`1 is 2\ "] arity_fun_apply_fm union_abs1 by simp moreover have "?f_fm \ formula" "arity(?f_fm) \ 7" "?g_fm \ formula" "arity(?g_fm) \ 8" using ord_simp_union unfolding hcomp_fm_def by (simp_all add:arity) ultimately show ?thesis using separation_sat_after_function that fst_abs snd_abs sats_check_fm check_abs unfolding hcomp_fm_def by simp qed moreover note assms ultimately show ?thesis using lam_replacement_imp_lam_closed lam_replacement_Collect' transitivity[of _ A] lam_replacement_constant lam_replacement_identity lam_replacement_snd lam_replacement_product separation_conj separation_in separation_bex separation_iff' by simp qed \ \Kunen IV.3.5\ lemma ccc_fun_approximation_lemma: notes le_trans[trans] assumes "ccc\<^bsup>M\<^esup>(P,leq)" "A\M" "B\M" "f\M[G]" "f : A \ B" shows "\F\M. F : A \ Pow\<^bsup>M\<^esup>(B) \ (\a\A. f`a \ F`a \ |F`a|\<^bsup>M\<^esup> \ \)" proof - from \f\M[G]\ obtain f_dot where "f = val(G,f_dot)" "f_dot\M" using GenExtD by force with assms obtain p where "p \ \0:1\2\ [f_dot, A\<^sup>v, B\<^sup>v]" "p\G" "p\M" using G_subset_M truth_lemma[of "\0:1\2\" "[f_dot, A\<^sup>v, B\<^sup>v]"] by (auto simp add:ord_simp_union arity_typed_function_fm \ \NOTE: type-checking is not performed here by the Simplifier\ typed_function_type) define F where "F\\a\A. {b\B. \q\P. q \ p \ (q \ \0`1 is 2\ [f_dot, a\<^sup>v, b\<^sup>v])}" from assms \f_dot\_\ \p\M\ have "F \ M" unfolding F_def using ccc_fun_closed_lemma by simp moreover from calculation have "f`a \ F`a" if "a \ A" for a proof - note \f: A \ B\ \a \ A\ moreover from this have "f ` a \ B" by simp moreover note \f\M[G]\ \A\M\ moreover from calculation have "M[G], [f, a, f`a] \ \0`1 is 2\" by (auto dest:transitivity) moreover note \B\M\ \f = val(G,f_dot)\ moreover from calculation have "a\M" "val(G, f_dot)`a\M" by (auto dest:transitivity) moreover note \f_dot\M\ \p\G\ ultimately obtain q where "q \ p" "q \ \0`1 is 2\ [f_dot, a\<^sup>v, (f`a)\<^sup>v]" "q\G" using forces_below_filter[of "\0`1 is 2\" "[f_dot, a\<^sup>v, (f`a)\<^sup>v]" p] by (auto simp add: ord_simp_union arity_fun_apply_fm fun_apply_type) with \f`a \ B\ have "f`a \ {b\B . \q\P. q \ p \ q \ \0`1 is 2\ [f_dot, a\<^sup>v, b\<^sup>v]}" by blast with \a\A\ show ?thesis unfolding F_def by simp qed moreover have "|F`a|\<^bsup>M\<^esup> \ \ \ F`a\M" if "a \ A" for a proof - let ?Q="\b. {q\P. q \ p \ (q \ \0`1 is 2\ [f_dot, a\<^sup>v, b\<^sup>v])}" from \F \ M\ \a\A\ \A\M\ have "F`a \ M" "a\M" using transitivity[OF _ \A\M\] by simp_all moreover have 2:"\x. x\F`a \ x\M" using transitivity[OF _ \F`a\M\] by simp moreover have 3:"\x. x\F`a \ (##M)(?Q(x))" using ccc_fun_closed_lemma_aux[OF \f_dot\M\ \p\M\ \a\M\ 2] transitivity[of _ "F`a"] by simp moreover have 4:"lam_replacement(##M,\b. {q \ P . q \ p \ (M, [q, P, leq, \, f_dot, a\<^sup>v, b\<^sup>v] \ forces(\0`1 is 2\ ))})" using ccc_fun_closed_lemma_aux2[OF _ \f_dot\M\ \p\M\ \a\M\] lam_replacement_iff_lam_closed[THEN iffD2] ccc_fun_closed_lemma_aux[OF \f_dot\M\ \p\M\ \a\M\] by simp ultimately interpret M_Pi_assumptions_choice "##M" "F`a" ?Q using Pi_replacement1[OF _ 3] lam_replacement_Sigfun[OF 4] lam_replacement_imp_strong_replacement ccc_fun_closed_lemma_aux[OF \f_dot\M\ \p\M\ \a\M\] lam_replacement_hcomp2[OF lam_replacement_constant 4 _ _ lam_replacement_minimum,unfolded lam_replacement_def] by unfold_locales simp_all from \F`a \ M\ interpret M_Pi_assumptions2 "##M" "F`a" ?Q "\_ . P" using lam_replacement_imp_strong_replacement[OF lam_replacement_Sigfun[OF lam_replacement_constant]] Pi_replacement1 transitivity[of _ "F`a"] by unfold_locales simp_all from \p \ \0:1\2\ [f_dot, A\<^sup>v, B\<^sup>v]\ \a\A\ have "\y. y \ ?Q(b)" if "b \ F`a" for b using that unfolding F_def by auto then obtain q where "q \ Pi\<^bsup>M\<^esup>(F`a,?Q)" "q\M" using AC_Pi_rel by auto moreover note \F`a \ M\ moreover from calculation have "q : F`a \\<^bsup>M\<^esup> P" using Pi_rel_weaken_type def_function_space_rel by auto moreover from calculation have "q : F`a \ range(q)" "q : F`a \ P" "q : F`a \\<^bsup>M\<^esup> range(q)" using mem_function_space_rel_abs range_of_fun by simp_all moreover have "q`b \ q`c" if "b \ F`a" "c \ F`a" "b \ c" \ \For the next step, if the premise \<^term>\b \ c\ is first, the proof breaks down badly\ for b c proof - from \b \ F`a\ \c \ F`a\ \q \ Pi\<^bsup>M\<^esup>(F`a,?Q)\ \q\M\ have "q`b \ \0`1 is 2\ [f_dot, a\<^sup>v, b\<^sup>v]" "q`c \ \0`1 is 2\ [f_dot, a\<^sup>v, c\<^sup>v]" using mem_Pi_rel_abs[of q] apply_type[of _ _ ?Q] by simp_all with \b \ c\ \q : F`a \ P\ \a\A\ \b\_\ \c\_\ \A\M\ \f_dot\M\ \F`a\M\ show ?thesis using forces_neq_apply_imp_incompatible transitivity[of _ A] transitivity[of _ "F`a"] by auto qed moreover from calculation have "antichain(P,leq,range(q))" using Pi_range_eq[of _ _ "\_ . P"] unfolding antichain_def compat_in_def by auto moreover from this and \q\M\ have "antichain\<^bsup>M\<^esup>(P,leq,range(q))" by (simp add:absolut del:P_in_M) moreover from calculation have "q`b \ q`c" if "b \ c" "b \ F`a" "c \ F`a" for b c using that Incompatible_imp_not_eq apply_type mem_function_space_rel_abs by simp ultimately have "q \ inj\<^bsup>M\<^esup>(F`a,range(q))" using def_inj_rel by auto with \F`a \ M\ \q\M\ have "|F`a|\<^bsup>M\<^esup> \ |range(q)|\<^bsup>M\<^esup>" using def_lepoll_rel by (rule_tac lepoll_rel_imp_cardinal_rel_le) auto also from \antichain\<^bsup>M\<^esup>(P,leq,range(q))\ \ccc\<^bsup>M\<^esup>(P,leq)\ \q\M\ have "|range(q)|\<^bsup>M\<^esup> \ \" using def_ccc_rel by simp finally show ?thesis using \F`a\M\ by auto qed moreover from this have "F`a\M" if "a\A" for a using that by simp moreover from this \B\M\ have "F : A \ Pow\<^bsup>M\<^esup>(B)" using Pow_rel_char unfolding F_def by (rule_tac lam_type) auto ultimately show ?thesis by auto qed end \ \G\_generic1\_lemmas bundle\ -end \ \\<^locale>\G_generic4_AC\\ +end \ \\<^locale>\G_generic3_AC\\ end \ No newline at end of file diff --git a/thys/Independence_CH/Choice_Axiom.thy b/thys/Independence_CH/Choice_Axiom.thy --- a/thys/Independence_CH/Choice_Axiom.thy +++ b/thys/Independence_CH/Choice_Axiom.thy @@ -1,326 +1,322 @@ section\The Axiom of Choice in $M[G]$\ theory Choice_Axiom imports Powerset_Axiom Extensionality_Axiom Foundation_Axiom Replacement_Axiom Infinity_Axiom begin definition upair_name :: "i \ i \ i \ i" where "upair_name(\,\,on) \ Upair(\\,on\,\\,on\)" definition opair_name :: "i \ i \ i \ i" where "opair_name(\,\,on) \ upair_name(upair_name(\,\,on),upair_name(\,\,on),on)" definition induced_surj :: "i\i\i\i" where "induced_surj(f,a,e) \ f-``(range(f)-a)\{e} \ restrict(f,f-``a)" lemma domain_induced_surj: "domain(induced_surj(f,a,e)) = domain(f)" unfolding induced_surj_def using domain_restrict domain_of_prod by auto lemma range_restrict_vimage: assumes "function(f)" shows "range(restrict(f,f-``a)) \ a" proof from assms have "function(restrict(f,f-``a))" using function_restrictI by simp fix y assume "y \ range(restrict(f,f-``a))" then obtain x where "\x,y\ \ restrict(f,f-``a)" "x \ f-``a" "x\domain(f)" using domain_restrict domainI[of _ _ "restrict(f,f-``a)"] by auto moreover note \function(restrict(f,f-``a))\ ultimately have "y = restrict(f,f-``a)`x" using function_apply_equality by blast also from \x \ f-``a\ have "restrict(f,f-``a)`x = f`x" by simp finally have "y = f`x" . moreover from assms \x\domain(f)\ have "\x,f`x\ \ f" using function_apply_Pair by auto moreover note assms \x \ f-``a\ ultimately show "y\a" using function_image_vimage[of f a] by auto qed lemma induced_surj_type: assumes "function(f)" (* "relation(f)" (* a function can contain non-pairs *) *) shows "induced_surj(f,a,e): domain(f) \ {e} \ a" and "x \ f-``a \ induced_surj(f,a,e)`x = f`x" proof - let ?f1="f-``(range(f)-a) \ {e}" and ?f2="restrict(f, f-``a)" have "domain(?f2) = domain(f) \ f-``a" using domain_restrict by simp moreover from assms have "domain(?f1) = f-``(range(f))-f-``a" using domain_of_prod function_vimage_Diff by simp ultimately have "domain(?f1) \ domain(?f2) = 0" by auto moreover have "function(?f1)" "relation(?f1)" "range(?f1) \ {e}" unfolding function_def relation_def range_def by auto moreover from this and assms have "?f1: domain(?f1) \ range(?f1)" using function_imp_Pi by simp moreover from assms have "?f2: domain(?f2) \ range(?f2)" using function_imp_Pi[of "restrict(f, f -`` a)"] function_restrictI by simp moreover from assms have "range(?f2) \ a" using range_restrict_vimage by simp ultimately have "induced_surj(f,a,e): domain(?f1) \ domain(?f2) \ {e} \ a" unfolding induced_surj_def using fun_is_function fun_disjoint_Un fun_weaken_type by simp moreover have "domain(?f1) \ domain(?f2) = domain(f)" using domain_restrict domain_of_prod by auto ultimately show "induced_surj(f,a,e): domain(f) \ {e} \ a" by simp assume "x \ f-``a" then have "?f2`x = f`x" using restrict by simp moreover from \x \ f-``a\ \domain(?f1) = _\ have "x \ domain(?f1)" by simp ultimately show "induced_surj(f,a,e)`x = f`x" unfolding induced_surj_def using fun_disjoint_apply2[of x ?f1 ?f2] by simp qed lemma induced_surj_is_surj : assumes "e\a" "function(f)" "domain(f) = \" "\y. y \ a \ \x\\. f ` x = y" shows "induced_surj(f,a,e) \ surj(\,a)" unfolding surj_def proof (intro CollectI ballI) from assms show "induced_surj(f,a,e): \ \ a" using induced_surj_type[of f a e] cons_eq cons_absorb by simp fix y assume "y \ a" with assms have "\x\\. f ` x = y" by simp then obtain x where "x\\" "f ` x = y" by auto with \y\a\ assms have "x\f-``a" using vimage_iff function_apply_Pair[of f x] by auto with \f ` x = y\ assms have "induced_surj(f, a, e) ` x = y" using induced_surj_type by simp with \x\\\ show "\x\\. induced_surj(f, a, e) ` x = y" by auto qed lemma (in M_ZF1_trans) upair_name_closed : "\ x\M; y\M ; o\M\ \ upair_name(x,y,o)\M" unfolding upair_name_def using upair_in_M_iff pair_in_M_iff Upair_eq_cons by simp -locale G_generic2 = G_generic1 + forcing_data2 - -context G_generic2 +context G_generic1 begin lemma val_upair_name : "val(G,upair_name(\,\,\)) = {val(G,\),val(G,\)}" unfolding upair_name_def using val_Upair Upair_eq_cons generic one_in_G by simp lemma val_opair_name : "val(G,opair_name(\,\,\)) = \val(G,\),val(G,\)\" unfolding opair_name_def Pair_def using val_upair_name by simp lemma val_RepFun_one: "val(G,{\f(x),\\ . x\a}) = {val(G,f(x)) . x\a}" proof - let ?A = "{f(x) . x \ a}" let ?Q = "\\x,p\ . p = \" have "\ \ P\G" using generic one_in_G one_in_P by simp have "{\f(x),\\ . x \ a} = {t \ ?A \ P . ?Q(t)}" using one_in_P by force then have "val(G,{\f(x),\\ . x \ a}) = val(G,{t \ ?A \ P . ?Q(t)})" by simp also have "... = {z . t \ ?A , (\p\P\G . ?Q(\t,p\)) \ z= val(G,t)}" using val_of_name_alt by simp also from \\\P\G\ have "... = {val(G,t) . t \ ?A }" by force also have "... = {val(G,f(x)) . x \ a}" by auto finally show ?thesis by simp qed -end\ \\<^locale>\G_generic2\\ +end\ \\<^locale>\G_generic1\\ subsection\$M[G]$ is a transitive model of ZF\ sublocale G_generic1 \ ext:M_Z_trans "M[G]" using Transset_MG generic pairing_in_MG Union_MG extensionality_in_MG power_in_MG foundation_in_MG replacement_assm_MG separation_in_MG infinity_in_MG replacement_ax1 by unfold_locales lemma (in M_replacement) upair_name_lam_replacement : "M(z) \ lam_replacement(M,\x . upair_name(fst(x),snd(x),z))" using lam_replacement_Upair[THEN [5] lam_replacement_hcomp2] lam_replacement_product lam_replacement_fst lam_replacement_snd lam_replacement_constant unfolding upair_name_def by simp -lemma (in forcing_data2) repl_opname_check : +lemma (in forcing_data1) repl_opname_check : assumes "A\M" "f\M" shows "{opair_name(check(x),f`x,\). x\A}\M" using assms lam_replacement_constant check_lam_replacement lam_replacement_identity upair_name_lam_replacement[THEN [5] lam_replacement_hcomp2] lam_replacement_apply2[THEN [5] lam_replacement_hcomp2] lam_replacement_imp_strong_replacement_aux transitivity RepFun_closed upair_name_closed apply_closed unfolding opair_name_def by simp -theorem (in G_generic2) choice_in_MG: +theorem (in G_generic1) choice_in_MG: assumes "choice_ax(##M)" shows "choice_ax(##M[G])" proof - { fix a assume "a\M[G]" then obtain \ where "\\M" "val(G,\) = a" using GenExt_def by auto with \\\M\ have "domain(\)\M" using domain_closed by simp then obtain s \ where "s\surj(\,domain(\))" "Ord(\)" "s\M" "\\M" using assms choice_ax_abs by auto then have "\\M[G]" using M_subset_MG generic one_in_G subsetD by blast let ?A="domain(\)\P" let ?g = "{opair_name(check(\),s`\,\). \\\}" have "?g \ M" using \s\M\ \\\M\ repl_opname_check by simp let ?f_dot="{\opair_name(check(\),s`\,\),\\. \\\}" have "?f_dot = ?g \ {\}" by blast define f where "f \ val(G,?f_dot)" from \?g\M\ \?f_dot = ?g\{\}\ have "?f_dot\M" using cartprod_closed singleton_closed by simp then have "f \ M[G]" unfolding f_def by (blast intro:GenExtI) have "f = {val(G,opair_name(check(\),s`\,\)) . \\\}" unfolding f_def using val_RepFun_one by simp also have "... = {\\,val(G,s`\)\ . \\\}" using val_opair_name val_check generic one_in_G one_in_P by simp finally have "f = {\\,val(G,s`\)\ . \\\}" . then have 1: "domain(f) = \" "function(f)" unfolding function_def by auto have 2: "y \ a \ \x\\. f ` x = y" for y proof - fix y assume "y \ a" with \val(G,\) = a\ obtain \ where "\\domain(\)" "val(G,\) = y" using elem_of_val[of y _ \] by blast with \s\surj(\,domain(\))\ obtain \ where "\\\" "s`\ = \" unfolding surj_def by auto with \val(G,\) = y\ have "val(G,s`\) = y" by simp with \f = {\\,val(G,s`\)\ . \\\}\ \\\\\ have "\\,y\\f" by auto with \function(f)\ have "f`\ = y" using function_apply_equality by simp with \\\\\ show "\\\\. f ` \ = y" by auto qed then have "\\\(M[G]). \f'\(M[G]). Ord(\) \ f' \ surj(\,a)" proof (cases "a=0") case True then show ?thesis unfolding surj_def using zero_in_MG by auto next case False with \a\M[G]\ obtain e where "e\a" "e\M[G]" using transitivity_MG by blast with 1 and 2 have "induced_surj(f,a,e) \ surj(\,a)" using induced_surj_is_surj by simp moreover from \f\M[G]\ \a\M[G]\ \e\M[G]\ have "induced_surj(f,a,e) \ M[G]" unfolding induced_surj_def by (simp flip: setclass_iff) moreover note \\\M[G]\ \Ord(\)\ ultimately show ?thesis by auto qed } then show ?thesis using ext.choice_ax_abs by simp qed -locale G_generic2_AC = G_generic1_AC + G_generic2 + M_ctm2_AC - -sublocale G_generic2_AC \ ext:M_ZC_basic "M[G]" +sublocale G_generic1_AC \ ext:M_ZC_basic "M[G]" using choice_ax choice_in_MG by unfold_locales end \ No newline at end of file diff --git a/thys/Independence_CH/Definitions_Main.thy b/thys/Independence_CH/Definitions_Main.thy --- a/thys/Independence_CH/Definitions_Main.thy +++ b/thys/Independence_CH/Definitions_Main.thy @@ -1,630 +1,641 @@ section\Main definitions of the development\label{sec:main-definitions}\ theory Definitions_Main imports Absolute_Versions begin text\This theory gathers the main definitions of the \<^session>\Transitive_Models\ session and the present one. It might be considered as the bare minimum reading requisite to trust that our development indeed formalizes the theory of forcing. This should be mathematically clear since this is the only known method for obtaining proper extensions of ctms while preserving the ordinals. The main theorem of this session and all of its relevant definitions appear in Section~\ref{sec:def-main-forcing}. The reader trusting all the libraries on which our development is based, might jump directly to Section~\ref{sec:relative-arith}, which treats relative cardinal arithmetic as implemented in \<^session>\Transitive_Models\. But in case one wants to dive deeper, the following sections treat some basic concepts of the ZF logic (Section~\ref{sec:def-main-ZF}) and in the ZF-Constructible library (Section~\ref{sec:def-main-relative}) on which our definitions are built. \ declare [[show_question_marks=false]] subsection\ZF\label{sec:def-main-ZF}\ text\For the basic logic ZF we restrict ourselves to just a few concepts.\ thm bij_def[unfolded inj_def surj_def] text\@{thm [display] bij_def[unfolded inj_def surj_def]}\ (* bij(A, B) \ {f \ A \ B . \w\A. \x\A. f ` w = f ` x \ w = x} \ {f \ A \ B . \y\B. \x\A. f ` x = y} *) thm eqpoll_def text\@{thm [display] eqpoll_def}\ (* A \ B \ \f. f \ bij(A, B) *) thm Transset_def text\@{thm [display] Transset_def}\ (* Transset(i) \ \x\i. x \ i *) thm Ord_def text\@{thm [display] Ord_def}\ (* Ord(i) \ Transset(i) \ (\x\i. Transset(x)) *) thm lt_def le_iff text\@{thm [display] lt_def le_iff}\ (* i < j \ i \ j \ Ord(j) i \ j \ i < j \ i = j \ Ord(j) *) text\With the concepts of empty set and successor in place,\ lemma empty_def': "\x. x \ 0" by simp lemma succ_def': "succ(i) = i \ {i}" by blast text\we can define the set of natural numbers \<^term>\\\. In the sources, it is defined as a fixpoint, but here we just write its characterization as the first limit ordinal.\ thm Limit_nat[unfolded Limit_def] nat_le_Limit[unfolded Limit_def] text\@{thm [display] Limit_nat[unfolded Limit_def] nat_le_Limit[unfolded Limit_def]}\ (* Ord(\) \ 0 < \ \ (\y. y < \ \ succ(y) < \) Ord(i) \ 0 < i \ (\y. y < i \ succ(y) < i) \ \ \ i *) text\Then, addition and predecessor on \<^term>\\\ are inductively characterized as follows:\ thm add_0_right add_succ_right pred_0 pred_succ_eq text\@{thm [display] add_succ_right add_0_right pred_0 pred_succ_eq}\ (* m \ \ \ m +\<^sub>\ 0 = m m +\<^sub>\ succ(n) = succ(m +\<^sub>\ n) pred(0) = 0 pred(succ(y)) = y *) text\Lists on a set \<^term>\A\ can be characterized by being recursively generated from the empty list \<^term>\[]\ and the operation \<^term>\Cons\ that adds a new element to the left end; the induction theorem for them shows that the characterization is “complete”.\ thm Nil Cons list.induct text\@{thm [display] Nil Cons list.induct }\ (* [] \ list(A) a \ A \ l \ list(A) \ Cons(a, l) \ list(A) x \ list(A) \ P([]) \ (\a l. a \ A \ l \ list(A) \ P(l) \ P(Cons(a, l))) \ P(x) *) text\Length, concatenation, and \<^term>\n\th element of lists are recursively characterized as follows.\ thm length.simps app.simps nth_0 nth_Cons text\@{thm [display] length.simps app.simps nth_0 nth_Cons}\ (* length([]) = 0 length(Cons(a, l)) = succ(length(l)) [] @ ys = ys Cons(a, l) @ ys = Cons(a, l @ ys) nth(0, Cons(a, l)) = a n \ \ \ nth(succ(n), Cons(a, l)) = nth(n, l) *) text\We have the usual Haskell-like notation for iterated applications of \<^term>\Cons\:\ lemma Cons_app: "[a,b,c] = Cons(a,Cons(b,Cons(c,[])))" .. text\Relative quantifiers restrict the range of the bound variable to a class \<^term>\M\ of type \<^typ>\i\o\; that is, a truth-valued function with set arguments.\ lemma "\x[M]. P(x) \ \x. M(x) \ P(x)" "\x[M]. P(x) \ \x. M(x) \ P(x)" unfolding rall_def rex_def . text\Finally, a set can be viewed (“cast”) as a class using the following function of type \<^typ>\i\(i\o)\.\ thm setclass_iff text\@{thm [display] setclass_iff}\ (* (##A)(x) \ x \ A *) subsection\Relative concepts\label{sec:def-main-relative}\ text\A list of relative concepts (mostly from the ZF-Constructible library) follows next.\ thm big_union_def text\@{thm [display] big_union_def}\ (* big_union(M, A, z) \ \x[M]. x \ z \ (\y[M]. y \ A \ x \ y) *) thm upair_def text\@{thm [display] upair_def}\ (* upair(M, a, b, z) \ a \ z \ b \ z \ (\x[M]. x \ z \ x = a \ x = b) *) thm pair_def text\@{thm [display] pair_def}\ (* pair(M, a, b, z) \ \x[M]. upair(M, a, a, x) \ (\y[M]. upair(M, a, b, y) \ upair(M, x, y, z)) *) thm successor_def[unfolded is_cons_def union_def] text\@{thm [display] successor_def[unfolded is_cons_def union_def]}\ (* successor(M, a, z) \ \x[M]. upair(M, a, a, x) \ (\xa[M]. xa \ z \ xa \ x \ xa \ a) *) thm empty_def text\@{thm [display] empty_def}\ (* empty(M, z) \ \x[M]. x \ z *) thm transitive_set_def[unfolded subset_def] text\@{thm [display] transitive_set_def[unfolded subset_def]}\ (* transitive_set(M, a) \ \x[M]. x \ a \ (\xa[M]. xa \ x \ xa \ a) *) thm ordinal_def text\@{thm [display] ordinal_def}\ (* ordinal(M, a) \ transitive_set(M, a) \ (\x[M]. x \ a \ transitive_set(M, x)) *) thm image_def text\@{thm [display] image_def}\ (* image(M, r, A, z) \ \y[M]. y \ z \ (\w[M]. w \ r \ (\x[M]. x \ A \ pair(M, x, y, w))) *) thm fun_apply_def text\@{thm [display] fun_apply_def}\ (* fun_apply(M, f, x, y) \ \xs[M]. \fxs[M]. upair(M, x, x, xs) \ image(M, f, xs, fxs) \ big_union(M, fxs, y) *) thm is_function_def text\@{thm [display] is_function_def}\ (* is_function(M, r) \ \x[M]. \y[M]. \y'[M]. \p[M]. \p'[M]. pair(M, x, y, p) \ pair(M, x, y', p') \ p \ r \ p' \ r \ y = y' *) thm is_relation_def text\@{thm [display] is_relation_def}\ (* is_relation(M, r) \ \z[M]. z \ r \ (\x[M]. \y[M]. pair(M, x, y, z)) *) thm is_domain_def text\@{thm [display] is_domain_def}\ (* is_domain(M, r, z) \ \x[M]. x \ z \ (\w[M]. w \ r \ (\y[M]. pair(M, x, y, w))) *) thm typed_function_def text\@{thm [display] typed_function_def}\ (* typed_function(M, A, B, r) \ is_function(M, r) \ is_relation(M, r) \ is_domain(M, r, A) \ (\u[M]. u \ r \ (\x[M]. \y[M]. pair(M, x, y, u) \ y \ B)) *) thm is_function_space_def[unfolded is_funspace_def] function_space_rel_def surjection_def text\@{thm [display] is_function_space_def[unfolded is_funspace_def] function_space_rel_def surjection_def}\ (* is_function_space(M, A, B, fs) \ M(fs) \ (\f[M]. f \ fs \ typed_function(M, A, B, f)) A \\<^bsup>M\<^esup> B \ THE d. is_function_space(M, A, B, d) surjection(M, A, B, f) \ typed_function(M, A, B, f) \ (\y[M]. y \ B \ (\x[M]. x \ A \ is_apply(M, f, x, y))) *) text\Relative version of the $\ZFC$ axioms\ thm extensionality_def text\@{thm [display] extensionality_def}\ (* extensionality(M) \ \x[M]. \y[M]. (\z[M]. z \ x \ z \ y) \ x = y *) thm foundation_ax_def text\@{thm [display] foundation_ax_def}\ (* foundation_ax(M) \ \x[M]. (\y[M]. y \ x) \ (\y[M]. y \ x \ \ (\z[M]. z \ x \ z \ y)) *) thm upair_ax_def text\@{thm [display] upair_ax_def}\ (* upair_ax(M) \ \x[M]. \y[M]. \z[M]. upair(M, x, y, z) *) thm Union_ax_def text\@{thm [display] Union_ax_def}\ (* Union_ax(M) \ \x[M]. \z[M]. \xa[M]. xa \ z \ (\y[M]. y \ x \ xa \ y) *) thm power_ax_def[unfolded powerset_def subset_def] text\@{thm [display] power_ax_def[unfolded powerset_def subset_def]}\ (* power_ax(M) \ \x[M]. \z[M]. \xa[M]. xa \ z \ (\xb[M]. xb \ xa \ xb \ x) *) thm infinity_ax_def text\@{thm [display] infinity_ax_def}\ (* infinity_ax(M) \ \I[M]. (\z[M]. empty(M, z) \ z \ I) \ (\y[M]. y \ I \ (\sy[M]. successor(M, y, sy) \ sy \ I)) *) thm choice_ax_def text\@{thm [display] choice_ax_def}\ (* choice_ax(M) \ \x[M]. \a[M]. \f[M]. ordinal(M, a) \ surjection(M, a, x, f) *) thm separation_def text\@{thm [display] separation_def}\ (* separation(M, P) \ \z[M]. \y[M]. \x[M]. x \ y \ x \ z \ P(x) *) thm univalent_def text\@{thm [display] univalent_def}\ (* univalent(M, A, P) \ \x[M]. x \ A \ (\y[M]. \z[M]. P(x, y) \ P(x, z) \ y = z) *) thm strong_replacement_def text\@{thm [display] strong_replacement_def}\ (* strong_replacement(M, P) \ \A[M]. univalent(M, A, P) \ (\Y[M]. \b[M]. b \ Y \ (\x[M]. x \ A \ P(x, b))) *) text\Internalized formulas\ text\“Codes” for formulas (as sets) are constructed from natural numbers using \<^term>\Member\, \<^term>\Equal\, \<^term>\Nand\, and \<^term>\Forall\.\ thm Member Equal Nand Forall formula.induct text\@{thm [display] Member Equal Nand Forall formula.induct}\ (* x \ \ \ y \ \ \ \x \ y\ \ formula x \ \ \ y \ \ \ \x = y\ \ formula p \ formula \ q \ formula \ \\(p \ q)\ \ formula p \ formula \ (\p) \ formula x \ formula \ (\x y. x \ \ \ y \ \ \ P(\x \ y\)) \ (\x y. x \ \ \ y \ \ \ P(\x = y\)) \ (\p q. p \ formula \ P(p) \ q \ formula \ P(q) \ P(\\(p \ q)\)) \ (\p. p \ formula \ P(p) \ P((\p))) \ P(x) *) text\Definitions for the other connectives and the internal existential quantifier are also provided. For instance, negation:\ thm Neg_def text\@{thm [display] Neg_def}\ (* \\p\ \ \\(p \ p)\ *) thm arity.simps text\@{thm [display] arity.simps}\ (* arity(\x \ y\) = succ(x) \ succ(y) arity(\x = y\) = succ(x) \ succ(y) arity(\\(p \ q)\) = arity(p) \ arity(q) arity((\p)) = pred(arity(p)) *) text\We have the satisfaction relation between $\in$-models and first order formulas (given a “environment” list representing the assignment of free variables),\ thm mem_iff_sats equal_iff_sats sats_Nand_iff sats_Forall_iff text\@{thm [display] mem_iff_sats equal_iff_sats sats_Nand_iff sats_Forall_iff}\ (* nth(i, env) = x \ nth(j, env) = y \ env \ list(A) \ x \ y \ A, env \ \i \ j\ nth(i, env) = x \ nth(j, env) = y \ env \ list(A) \ x = y \ A, env \ \i = j\ env \ list(A) \ (A, env \ \\(p \ q)\) \ \ ((A, env \ p) \ (A, env \ q)) env \ list(A) \ (A, env \ (\\p\)) \ (\x\A. A, Cons(x, env) \ p)*) text\as well as the satisfaction of an arbitrary set of sentences.\ thm satT_def text\@{thm [display] satT_def}\ (* A \ \ \ \\\\. A, [] \ \ *) text\The internalized (viz. as elements of the set \<^term>\formula\) version of the axioms follow next.\ thm ZF_union_iff_sats ZF_power_iff_sats ZF_pairing_iff_sats ZF_foundation_iff_sats ZF_extensionality_iff_sats ZF_infinity_iff_sats sats_ZF_separation_fm_iff sats_ZF_replacement_fm_iff ZF_choice_iff_sats text\@{thm [display] ZF_union_iff_sats ZF_power_iff_sats ZF_pairing_iff_sats ZF_foundation_iff_sats ZF_extensionality_iff_sats ZF_infinity_iff_sats sats_ZF_separation_fm_iff sats_ZF_replacement_fm_iff ZF_choice_iff_sats}\ (* Union_ax(##A) \ A, [] \ \Union Ax\ power_ax(##A) \ A, [] \ \Powerset Ax\ upair_ax(##A) \ A, [] \ \Pairing\ foundation_ax(##A) \ A, [] \ \Foundation\ extensionality(##A) \ A, [] \ \Extensionality\ infinity_ax(##A) \ A, [] \ \Infinity\ \ \ formula \ (M, [] \ \Separation(\)\) \ (\env\list(M). arity(\) \ 1 +\<^sub>\ length(env) \ separation(##M, \x. M, [x] @ env \ \)) \ \ formula \ - (M, [] \ \Replacement(\)\) \ - (\env\list(M). - arity(\) \ 2 +\<^sub>\ length(env) \ - strong_replacement(##M, \x y. M, [x, y] @ env \ \)) + (M, [] \ \Replacement(\)\) \ (\env. replacement_assm(M, env, \)) choice_ax(##A) \ A, [] \ \AC\ *) +text\Above, we use the following:\ + +thm replacement_assm_def +text\@{thm [display] replacement_assm_def}\ +(* +replacement_assm(M, env, \) \ +\ \ formula \ +env \ list(M) \ +arity(\) \ 2 +\<^sub>\ length(env) \ +strong_replacement(##M, \x y. M, [x, y] @ env \ \ +*) + +text\Finally, the axiom sets are defined as follows.\ + thm ZF_fin_def ZF_schemes_def Zermelo_fms_def ZC_def ZF_def ZFC_def text\@{thm [display] ZF_fin_def ZF_schemes_def Zermelo_fms_def ZC_def ZF_def ZFC_def}\ (* ZF_fin \ {\Extensionality\, \Foundation\, \Pairing\, \Union Ax\, \Infinity\, \Powerset Ax\} ZF_schemes \ {\Separation(p)\ . p \ formula} \ {\Replacement(p)\ . p \ formula} \Z\ \ ZF_fin \ {\Separation(p)\ . p \ formula} ZC \ \Z\ \ {\AC\} ZF \ ZF_schemes \ ZF_fin ZFC \ ZF \ {\AC\} *) subsection\Relativization of infinitary arithmetic\label{sec:relative-arith}\ text\In order to state the defining property of the relative equipotence relation, we work under the assumptions of the locale \<^term>\M_cardinals\. They comprise a finite set of instances of Separation and Replacement to prove closure properties of the transitive class \<^term>\M\.\ lemma (in M_cardinals) eqpoll_def': assumes "M(A)" "M(B)" shows "A \\<^bsup>M\<^esup> B \ (\f[M]. f \ bij(A,B))" using assms unfolding eqpoll_rel_def by auto text\Below, $\mu$ denotes the minimum operator on the ordinals.\ lemma cardinalities_defs: fixes M::"i\o" shows "|A|\<^bsup>M\<^esup> \ \ i. M(i) \ i \\<^bsup>M\<^esup> A" "Card\<^bsup>M\<^esup>(\) \ \ = |\|\<^bsup>M\<^esup>" "\\<^bsup>\\,M\<^esup> \ |\ \\<^bsup>M\<^esup> \|\<^bsup>M\<^esup>" "(\\<^sup>+)\<^bsup>M\<^esup> \ \ x. M(x) \ Card\<^bsup>M\<^esup>(x) \ \ < x" unfolding cardinal_rel_def cexp_rel_def csucc_rel_def Card_rel_def . context M_aleph begin text\Analogous to the previous Lemma @{thm [source] eqpoll_def'}, we are now under the assumptions of the locale \<^term>\M_aleph\. The axiom instances included are sufficient to state and prove the defining properties of the relativized \<^term>\Aleph\ function (in particular, the required ability to perform transfinite recursions).\ thm Aleph_rel_zero Aleph_rel_succ Aleph_rel_limit text\@{thm [display] Aleph_rel_zero Aleph_rel_succ Aleph_rel_limit}\ (* \\<^bsub>0\<^esub>\<^bsup>M\<^esup> = \ Ord(\) \ M(\) \ \\<^bsub>succ(\)\<^esub>\<^bsup>M\<^esup> = (\\<^bsub>\\<^esub>\<^bsup>M\<^esup>\<^sup>+)\<^bsup>M\<^esup> Limit(\) \ M(\) \ \\<^bsub>\\<^esub>\<^bsup>M\<^esup> = (\j\\. \\<^bsub>j\<^esub>\<^bsup>M\<^esup>) *) end \ \\<^locale>\M_aleph\\ lemma ContHyp_rel_def': fixes N::"i\o" shows "CH\<^bsup>N\<^esup> \ \\<^bsub>1\<^esub>\<^bsup>N\<^esup> = 2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>N\<^esup>,N\<^esup>" unfolding ContHyp_rel_def . text\Under appropriate hypotheses (this time, from the locale \<^term>\M_ZF_library\), \<^term>\CH\<^bsup>M\<^esup>\ is equivalent to its fully relational version \<^term>\is_ContHyp\. As a sanity check, we see that if the transitive class is indeed \<^term>\\\, we recover the original $\CH$.\ thm M_ZF_library.is_ContHyp_iff is_ContHyp_iff_CH[unfolded ContHyp_def] text\@{thm [display] M_ZF_library.is_ContHyp_iff is_ContHyp_iff_CH[unfolded ContHyp_def]}\ (* M_ZF_library(M) \ is_ContHyp(M) \ CH\<^bsup>M\<^esup> is_ContHyp(\) \ \\<^bsub>1\<^esub> = 2\<^bsup>\\\<^bsub>0\<^esub>\<^esup> *) text\In turn, the fully relational version evaluated on a nonempty transitive \<^term>\A\ is equivalent to the satisfaction of the first-order formula \<^term>\\CH\\.\ thm is_ContHyp_iff_sats text\@{thm [display] is_ContHyp_iff_sats}\ (* env \ list(A) \ 0 \ A \ is_ContHyp(##A) \ A, env \ \CH\ *) subsection\Forcing \label{sec:def-main-forcing}\ text\Our first milestone was to obtain a proper extension using forcing. Its original proof didn't required the previous developments involving the relativization of material on cardinal arithmetic. Now it is derived from a stronger result, namely @{thm [source] extensions_of_ctms} below.\ thm extensions_of_ctms_ZF text\@{thm [display] extensions_of_ctms_ZF}\ (* M \ \ \ Transset(M) \ M \ ZF \ \N. M \ N \ N \ \ \ Transset(N) \ N \ ZF \ M \ N \ (\\. Ord(\) \ \ \ M \ \ \ N) \ ((M, [] \ \AC\) \ N \ ZFC) *) text\We can finally state our main results, namely, the existence of models for $\ZFC + \CH$ and $\ZFC + \neg\CH$ under the assumption of a ctm of $\ZFC$.\ thm ctm_ZFC_imp_ctm_not_CH text\@{thm [display] ctm_ZFC_imp_ctm_not_CH}\ (* M \ \ \ Transset(M) \ M \ ZFC \ \N. M \ N \ N \ \ \ Transset(N) \ N \ ZFC \ {\\\CH\\} \ (\\. Ord(\) \ \ \ M \ \ \ N) *) thm ctm_ZFC_imp_ctm_CH text\@{thm [display] ctm_ZFC_imp_ctm_CH}\ (* M \ \ \ Transset(M) \ M \ ZFC \ \N. M \ N \ N \ \ \ Transset(N) \ N \ ZFC \ {\CH\} \ (\\. Ord(\) \ \ \ M \ \ \ N) *) text\These results can be strengthened by enumerating six finite sets of replacement instances which are sufficient to develop forcing and for the construction of the aforementioned models: \<^term>\instances1_fms\ -through \<^term>\instances4_fms\, \<^term>\instances_ground_fms\, and +through \<^term>\instances3_fms\, \<^term>\instances_ground_fms\, and \<^term>\instances_ground_notCH_fms\, -which are then collected into the $33$-element set \<^term>\overhead_notCH\. +which are then collected into the $31$-element set \<^term>\overhead_notCH\. For example, we have:\ thm instances1_fms_def text\@{thm [display] instances1_fms_def}\ (* instances1_fms \ { list_repl1_intf_fm, list_repl2_intf_fm, formula_repl1_intf_fm, formula_repl2_intf_fm, eclose_repl1_intf_fm, eclose_repl2_intf_fm, wfrec_rank_fm, trans_repl_HVFrom_fm, tl_repl_intf_fm } *) thm overhead_def overhead_notCH_def text\@{thm [display] overhead_def overhead_notCH_def overhead_CH_def}\ (* - overhead \ instances1_fms \ instances2_fms \ instances_ground_fms + overhead \ instances1_fms \ instances_ground_fms overhead_notCH \ overhead \ - instances3_fms \ instances4_fms \ instances_ground_notCH_fms + instances2_fms \ instances3_fms \ instances_ground_notCH_fms *) text\One further instance is needed to force $\CH$, with a total count of $32$ instances:\ thm overhead_CH_def text\@{thm [display] overhead_CH_def}\ (* overhead_CH \ overhead_notCH \ {replacement_dcwit_repl_body_fm} *) thm extensions_of_ctms text\@{thm [display] extensions_of_ctms}\ (* M \ \ \ Transset(M) \ M \ \Z\ \ {\Replacement(p)\ . p \ overhead} \ \ \ formula \ M \ {\Replacement(ground_repl_fm(\))\ . \ \ \} \ \N. M \ N \ N \ \ \ Transset(N) \ M \ N \ (\\. Ord(\) \ \ \ M \ \ \ N) \ ((M, [] \ \AC\) \ N, [] \ \AC\) \ N \ \Z\ \ {\Replacement(\)\ . \ \ \} *) thm ctm_of_not_CH text\@{thm [display] ctm_of_not_CH}\ (* M \ \ \ Transset(M) \ M \ ZC \ {\Replacement(p)\ . p \ overhead_notCH} \ \ \ formula \ M \ {\Replacement(ground_repl_fm(\))\ . \ \ \} \ \N. M \ N \ N \ \ \ Transset(N) \ N \ ZC \ {\\\CH\\} \ {\Replacement(\)\ . \ \ \} \ (\\. Ord(\) \ \ \ M \ \ \ N) *) thm ctm_of_CH text\@{thm [display] ctm_of_CH}\ (* M \ \ \ Transset(M) \ M \ ZC \ {\Replacement(p)\ . p \ overhead_CH} \ \ \ formula \ M \ {\Replacement(ground_repl_fm(\))\ . \ \ \} \ \N. M \ N \ N \ \ \ Transset(N) \ N \ ZC \ {\CH\} \ {\Replacement(\)\ . \ \ \} \ (\\. Ord(\) \ \ \ M \ \ \ N) *) text\In the above three statements, the function \<^term>\ground_repl_fm\ takes an element \<^term>\\\ of \<^term>\formula\ and returns the replacement instance in the ground model that produces the \<^term>\\\-replacement instance in the generic extension. The next result is stated in the context \<^locale>\G_generic1\, which assumes the existence of a generic filter.\ context G_generic1 begin thm sats_ground_repl_fm_imp_sats_ZF_replacement_fm text\@{thm [display] sats_ground_repl_fm_imp_sats_ZF_replacement_fm}\ (* \ \ formula \ M, [] \ \Replacement(ground_repl_fm(\))\ \ M[G], [] \ \Replacement(\)\ *) end \ \\<^locale>\G_generic1\\ end \ No newline at end of file diff --git a/thys/Independence_CH/Demonstrations.thy b/thys/Independence_CH/Demonstrations.thy --- a/thys/Independence_CH/Demonstrations.thy +++ b/thys/Independence_CH/Demonstrations.thy @@ -1,168 +1,179 @@ section\Some demonstrations\ theory Demonstrations imports Definitions_Main begin text\The following theory is only intended to explore some details of the formalization and to show the appearance of relevant internalized formulas. It is \<^bold>\not\ intended as the entry point of the session. For that purpose, consult \<^theory>\Independence_CH.Definitions_Main\\ + +text\The snippet (by M. Pagano) commented out below outputs a directed +graph picturing the locale structure.\ +\ \ +ML\Locale.pretty_locale_deps @{theory} |> +map (fn n => let val nom = #name n + in map (writeln o (fn p => "\"" ^ p ^ "\" -> \"" ^ nom ^ "\";")) (#parents n) +end) +\ +\ + locale Demo = M_trivial + M_AC + fixes t\<^sub>1 t\<^sub>2 assumes ts_in_nat[simp]: "t\<^sub>1\\" "t\<^sub>2\\" and power_infty: "power_ax(M)" "M(\)" begin text\The next fake lemma is intended to explore the instances of the axiom schemes that are needed to build our forcing models. They are categorized as plain replacements (using \<^term>\strong_replacement\), “lambda-replacements” using a higher order function, replacements to perform transfinite and general well-founded recursion (using \<^term>\transrec_replacement\ and \<^term>\wfrec_replacement\ respectively) and for the construction of fixpoints (using \<^term>\iterates_replacement\). Lastly, separations instances.\ lemma assumes sorried_replacements: "\P. strong_replacement(M,P)" "\F. lam_replacement(M,F)" "\Q S. iterates_replacement(M,Q,S)" "\Q S. wfrec_replacement(M,Q,S)" "\Q S. transrec_replacement(M,Q,S)" and sorried_separations: "\Q. separation(M,Q)" shows "M_master(M)" apply unfold_locales apply (simp_all add: sorried_replacements(1-2) sorried_separations power_infty) oops \ \NOTE: Only for pretty-printing purposes, overrides previous fundamental notations\ no_notation mem (infixl \\\ 50) no_notation conj (infixr \\\ 35) no_notation disj (infixr \\\ 30) no_notation iff (infixr \\\ 25) no_notation imp (infixr \\\ 25) no_notation not (\\ _\ [40] 40) no_notation All (\'(\_')\) no_notation Ex (\'(\_')\) no_notation Member (\\_ \/ _\\) no_notation Equal (\\_ =/ _\\) no_notation Nand (\\\'(_ \/ _')\\) no_notation And (\\_ \/ _\\) no_notation Or (\\_ \/ _\\) no_notation Iff (\\_ \/ _\\) no_notation Implies (\\_ \/ _\\) no_notation Neg (\\\_\\) no_notation Forall (\'(\\(/_)\')\) no_notation Exists (\'(\\(/_)\')\) notation Member (infixl \\\ 50) notation Equal (infixl \\\ 50) notation Nand (\\'(_ \/ _')\) notation And (infixr \\\ 35) notation Or (infixr \\\ 30) notation Iff (infixr \\\ 25) notation Implies (infixr \\\ 25) notation Neg (\\ _\ [40] 40) notation Forall (\'(\_')\) notation Exists (\'(\_')\) lemma "forces(t\<^sub>1\t\<^sub>2) = (0 \ 1 \ forces_mem_fm(1, 2, 0, t\<^sub>1+\<^sub>\4, t\<^sub>2+\<^sub>\4))" unfolding forces_def by simp (* \ \Prefix abbreviated notation\ notation Member (\M\) notation Equal (\Eq\) notation Nand (\Na\) notation And (\A\) notation Or (\O\) notation Iff (\If\) notation Implies (\Im\) notation Neg (\Ne\) notation Forall (\Fo\) notation Exists (\Ex\) *) (* forces_mem_fm(1, 2, 0, t\<^sub>1+\<^sub>\4, t\<^sub>1+\<^sub>\4) = forces_mem_fm(1, 2, 0, succ(succ(succ(succ(t\<^sub>1)))), succ(succ(succ(succ(t\<^sub>2))))) = \ *) definition forces_0_mem_1 where "forces_0_mem_1\forces_mem_fm(1,2,0,t\<^sub>1+\<^sub>\4,t\<^sub>2+\<^sub>\4)" thm forces_0_mem_1_def[ unfolded frc_at_fm_def ftype_fm_def name1_fm_def name2_fm_def snd_snd_fm_def hcomp_fm_def ecloseN_fm_def eclose_n1_fm_def eclose_n2_fm_def is_eclose_fm_def mem_eclose_fm_def eclose_n_fm_def is_If_fm_def least_fm_def Replace_fm_def Collect_fm_def fm_definitions,simplified] (* NOTE: in view of the above, @{thm [source] fm_definitions} might be incomplete *) named_theorems incr_bv_new_simps schematic_goal incr_bv_Neg(* [incr_bv_new_simps] *): "mem(n,\) \ mem(\,formula) \ incr_bv(Neg(\))`n = ?x" unfolding Neg_def by simp schematic_goal incr_bv_Exists [incr_bv_new_simps]: "mem(n,\) \ mem(\,formula) \ incr_bv(Exists(\))`n = ?x" unfolding Exists_def by (simp add: incr_bv_Neg) (* schematic_goal incr_bv_And [incr_bv_new_simps]: "mem(n,\) \ mem(\,formula) \mem(\,formula)\ incr_bv(And(\,\))`n = ?x" unfolding And_def by (simp add: incr_bv_Neg) schematic_goal incr_bv_Or [incr_bv_new_simps]: "mem(n,\) \ mem(\,formula) \mem(\,formula)\ incr_bv(Or(\,\))`n = ?x" unfolding Or_def by (simp add: incr_bv_Neg) schematic_goal incr_bv_Implies [incr_bv_new_simps]: "mem(n,\) \ mem(\,formula) \mem(\,formula)\ incr_bv(Implies(\,\))`n = ?x" unfolding Implies_def by (simp add: incr_bv_Neg) *) \ \The two renamings involved in the definition of \<^term>\forces\ depend on the recursive function \<^term>\incr_bv\. Here we have an apparently exponential bottleneck, since all the propositional connectives (even \<^term>\Neg\) duplicate the appearances of \<^term>\incr_bv\. Not even the double negation of an atomic formula can be managed by the system (in version 2021-1).\ (* schematic_goal "forces(\\0\1) = ?x" unfolding forces_def Neg_def by (simp add:ren_forces_nand_def ren_forces_forall_def frc_at_fm_def ftype_fm_def name1_fm_def name2_fm_def snd_snd_fm_def hcomp_fm_def ecloseN_fm_def eclose_n1_fm_def eclose_n2_fm_def is_eclose_fm_def mem_eclose_fm_def eclose_n_fm_def is_If_fm_def least_fm_def Collect_fm_def fm_definitions incr_bv_Neg incr_bv_Exists) (* exception Size raised (line 183 of "./basis/LibrarySupport.sml") *) *) (* declare is_ContHyp_fm_def[fm_definitions del] thm is_ContHyp_fm_def[unfolded is_eclose_fm_def mem_eclose_fm_def eclose_n_fm_def is_If_fm_def least_fm_def Replace_fm_def Collect_fm_def fm_definitions, simplified] *) end \ \\<^locale>\Demo\\ end \ No newline at end of file diff --git a/thys/Independence_CH/Forcing_Data.thy b/thys/Independence_CH/Forcing_Data.thy --- a/thys/Independence_CH/Forcing_Data.thy +++ b/thys/Independence_CH/Forcing_Data.thy @@ -1,163 +1,161 @@ section\Transitive set models of ZF\ text\This theory defines locales for countable transitive models of $\ZF$, and on top of that, one that includes a forcing notion. Weakened versions of both locales are included, that only assume finitely many replacement instances.\ theory Forcing_Data imports Forcing_Notions Cohen_Posets_Relative ZF_Trans_Interpretations begin no_notation Aleph (\\_\ [90] 90) subsection\A forcing locale and generic filters\ text\Ideally, countability should be separated from the assumption of this locale. The fact is that our present proofs of the “definition of forces” (and many consequences) and of the lemma for “forcing a value” of function unnecessarily depend on the countability of the ground model. \ locale forcing_data1 = forcing_notion + M_ctm1 + M_ZF_ground_trans + assumes P_in_M: "P \ M" and leq_in_M: "leq \ M" -locale forcing_data2 = forcing_data1 + M_ctm2 +locale forcing_data2 = forcing_data1 + M_ctm2_AC locale forcing_data3 = forcing_data2 + M_ctm3_AC -locale forcing_data4 = forcing_data3 + M_ctm4_AC - context forcing_data1 begin lemma P_sub_M : "P \ M" using transitivity P_in_M by auto definition M_generic :: "i\o" where "M_generic(G) \ filter(G) \ (\D\M. D\P \ dense(D)\D\G\0)" declare iff_trans [trans] lemma M_generic_imp_filter[dest]: "M_generic(G) \ filter(G)" unfolding M_generic_def by blast lemma generic_filter_existence: "p\P \ \G. p\G \ M_generic(G)" proof - assume "p\P" let ?D="\n\nat. (if (enum`n\P \ dense(enum`n)) then enum`n else P)" have "\n\nat. ?D`n \ Pow(P)" by auto then have "?D:nat\Pow(P)" using lam_type by auto have "\n\nat. dense(?D`n)" proof(intro ballI) fix n assume "n\nat" then have "dense(?D`n) \ dense(if enum`n \ P \ dense(enum`n) then enum`n else P)" by simp also have "... \ (\(enum`n \ P \ dense(enum`n)) \ dense(P)) " using split_if by simp finally show "dense(?D`n)" using P_dense \n\nat\ by auto qed with \?D\_\ interpret cg: countable_generic P leq \ ?D by (unfold_locales, auto) from \p\P\ obtain G where 1: "p\G \ filter(G) \ (\n\nat.(?D`n)\G\0)" using cg.countable_rasiowa_sikorski[where M="\_. M"] P_sub_M M_countable[THEN bij_is_fun] M_countable[THEN bij_is_surj, THEN surj_range] unfolding cg.D_generic_def by blast then have "(\D\M. D\P \ dense(D)\D\G\0)" proof (intro ballI impI) fix D assume "D\M" and 2: "D \ P \ dense(D) " moreover have "\y\M. \x\nat. enum`x= y" using M_countable and bij_is_surj unfolding surj_def by (simp) moreover from calculation obtain n where Eq10: "n\nat \ enum`n = D" by auto moreover from calculation if_P have "?D`n = D" by simp moreover note 1 ultimately show "D\G\0" by auto qed with 1 show ?thesis unfolding M_generic_def by auto qed lemma one_in_M: "\ \ M" using one_in_P P_in_M transitivity by simp declare P_in_M [simp,intro] declare one_in_M [simp,intro] declare leq_in_M [simp,intro] declare one_in_P [intro] end \ \\<^locale>\forcing_data1\\ locale G_generic1 = forcing_data1 + fixes G :: "i" assumes generic : "M_generic(G)" begin lemma G_nonempty: "G\0" using generic subset_refl[of P] P_dense unfolding M_generic_def by auto lemma M_genericD [dest]: "x\G \ x\P" using generic by (blast dest:filterD) lemma M_generic_leqD [dest]: "p\G \ q\P \ p\q \ q\G" using generic by (blast dest:filter_leqD) lemma M_generic_compatD [dest]: "p\G \ r\G \ \q\G. q\p \ q\r" using generic by (blast dest:low_bound_filter) lemma M_generic_denseD [dest]: "dense(D) \ D\P \ D\M \ \q\G. q\D" using generic unfolding M_generic_def by blast lemma G_subset_P: "G\P" using generic by auto lemma one_in_G : "\ \ G" proof - have "increasing(G)" using generic unfolding M_generic_def filter_def by simp then show ?thesis using G_nonempty one_max unfolding increasing_def by blast qed lemma G_subset_M: "G \ M" using generic transitivity[OF _ P_in_M] by auto end \ \\<^locale>\G_generic1\\ locale G_generic1_AC = G_generic1 + M_ctm1_AC end \ No newline at end of file diff --git a/thys/Independence_CH/Forcing_Main.thy b/thys/Independence_CH/Forcing_Main.thy --- a/thys/Independence_CH/Forcing_Main.thy +++ b/thys/Independence_CH/Forcing_Main.thy @@ -1,170 +1,170 @@ section\The main theorem\ theory Forcing_Main imports Ordinals_In_MG Choice_Axiom Succession_Poset begin subsection\The generic extension is countable\ lemma (in forcing_data1) surj_nat_MG : "\f. f \ surj(\,M[G])" proof - let ?f="\n\\. val(G,enum`n)" have "x \ \ \ val(G, enum ` x)\ M[G]" for x using GenExtI bij_is_fun[OF M_countable] by simp then have "?f: \ \ M[G]" using lam_type[of \ "\n. val(G,enum`n)" "\_.M[G]"] by simp moreover have "\n\\. ?f`n = x" if "x\M[G]" for x using that GenExt_iff[of _ G] bij_is_surj[OF M_countable] unfolding surj_def by auto ultimately show ?thesis unfolding surj_def by blast qed lemma (in G_generic1) MG_eqpoll_nat: "M[G] \ \" proof - obtain f where "f \ surj(\,M[G])" using surj_nat_MG by blast then have "M[G] \ \" using well_ord_surj_imp_lepoll well_ord_Memrel[of \] by simp moreover have "\ \ M[G]" using ext.nat_into_M subset_imp_lepoll by (auto del:lepollI) ultimately show ?thesis using eqpollI by simp qed subsection\Extensions of ctms of fragments of $\ZFC$\ context G_generic1 begin lemma sats_ground_repl_fm_imp_sats_ZF_replacement_fm: assumes "\\formula" "M, [] \ \Replacement(ground_repl_fm(\))\" shows "M[G], [] \ \Replacement(\)\" using assms sats_ZF_replacement_fm_iff by (auto simp:replacement_assm_def ground_replacement_assm_def intro:strong_replacement_in_MG[simplified]) lemma satT_ground_repl_fm_imp_satT_ZF_replacement_fm: assumes "\ \ formula" "M \ { \Replacement(ground_repl_fm(\))\ . \ \ \}" shows "M[G] \ { \Replacement(\)\ . \ \ \}" using assms sats_ground_repl_fm_imp_sats_ZF_replacement_fm by auto end \ \\<^locale>\G_generic1\\ theorem extensions_of_ctms: assumes "M \ \" "Transset(M)" "M \ \Z\ \ {\Replacement(p)\ . p \ overhead}" "\ \ formula" "M \ { \Replacement(ground_repl_fm(\))\ . \ \ \}" shows "\N. M \ N \ N \ \ \ Transset(N) \ M\N \ (\\. Ord(\) \ (\ \ M \ \ \ N)) \ ((M, []\ \AC\) \ N, [] \ \AC\) \ N \ \Z\ \ { \Replacement(\)\ . \ \ \}" proof - from \M \ \Z\ \ _\ \Transset(M)\ interpret M_ZF_ground_trans M using M_satT_imp_M_ZF_ground_trans by simp from \M \ \\ obtain enum where "enum \ bij(\,M)" using eqpoll_sym unfolding eqpoll_def by blast then - interpret M_ctm2 M enum by unfold_locales + interpret M_ctm1 M enum by unfold_locales interpret forcing_data1 "2\<^bsup><\\<^esup>" seqle 0 M enum using nat_into_M seqspace_closed seqle_in_M by unfold_locales simp obtain G where "M_generic(G)" "M \ M[G]" using cohen_extension_is_proper by blast text\Recall that \<^term>\M[G]\ denotes the generic extension of \<^term>\M\ using the poset of sequences \<^term>\2\<^bsup><\\<^esup>\.\ then - interpret G_generic2 "2\<^bsup><\\<^esup>" seqle 0 _ enum G by unfold_locales + interpret G_generic1 "2\<^bsup><\\<^esup>" seqle 0 _ enum G by unfold_locales interpret MG: M_Z_basic "M[G]" using generic pairing_in_MG Union_MG extensionality_in_MG power_in_MG foundation_in_MG replacement_assm_MG separation_in_MG infinity_in_MG replacement_ax1 by unfold_locales simp have "M, []\ \AC\ \ M[G], [] \ \AC\" proof - assume "M, [] \ \AC\" then have "choice_ax(##M)" unfolding ZF_choice_fm_def using ZF_choice_auto by simp then have "choice_ax(##M[G])" using choice_in_MG by simp then show "M[G], [] \ \AC\" using ZF_choice_auto sats_ZFC_iff_sats_ZF_AC unfolding ZF_choice_fm_def by simp qed moreover note \M \ M[G]\ \M \ { \Replacement(ground_repl_fm(\))\ . \ \ \}\ \\ \ formula\ moreover have "Transset(M[G])" using Transset_MG . moreover have "M \ M[G]" using M_subset_MG[OF one_in_G] generic by simp ultimately show ?thesis using Ord_MG_iff MG_eqpoll_nat ext.M_satT_Zermelo_fms satT_ground_repl_fm_imp_satT_ZF_replacement_fm[of \] by (rule_tac x="M[G]" in exI, auto) qed -lemma ZF_replacement_instances12_sub_ZF: "{\Replacement(p)\ . p \ overhead} \ ZF" - using instances1_fms_type instances2_fms_type instances_ground_fms_type +lemma ZF_replacement_overhead_sub_ZF: "{\Replacement(p)\ . p \ overhead} \ ZF" + using instances1_fms_type instances_ground_fms_type unfolding overhead_def ZF_def ZF_schemes_def by auto theorem extensions_of_ctms_ZF: assumes "M \ \" "Transset(M)" "M \ ZF" shows "\N. M \ N \ N \ \ \ Transset(N) \ N \ ZF \ M\N \ (\\. Ord(\) \ (\ \ M \ \ \ N)) \ ((M, []\ \AC\) \ N \ ZFC)" proof - from assms have "\N. M \ N \ N \ \ \ Transset(N) \ M\N \ (\\. Ord(\) \ (\ \ M \ \ \ N)) \ ((M, []\ \AC\) \ N, [] \ \AC\) \ N \ \Z\ \ { \Replacement(\)\ . \ \ formula}" using extensions_of_ctms[of M formula] satT_ZF_imp_satT_Z[of M] satT_mono[OF _ ground_repl_fm_sub_ZF, of M] - satT_mono[OF _ ZF_replacement_instances12_sub_ZF, of M] + satT_mono[OF _ ZF_replacement_overhead_sub_ZF, of M] by (auto simp: satT_Un_iff) then obtain N where "N \ \Z\ \ { \Replacement(\)\ . \ \ formula}" "M \ N" "N \ \" "Transset(N)" "M \ N" "(\\. Ord(\) \ \ \ M \ \ \ N)" "(M, []\ \AC\) \ N, [] \ \AC\" by blast moreover from \N \ \Z\ \ { \Replacement(\)\ . \ \ formula}\ have "N \ ZF" using satT_Z_ZF_replacement_imp_satT_ZF by auto moreover from this and \(M, []\ \AC\) \ N, [] \ \AC\\ have "(M, []\ \AC\) \ N \ ZFC" using sats_ZFC_iff_sats_ZF_AC by simp ultimately show ?thesis by auto qed end \ No newline at end of file diff --git a/thys/Independence_CH/Infinity_Axiom.thy b/thys/Independence_CH/Infinity_Axiom.thy --- a/thys/Independence_CH/Infinity_Axiom.thy +++ b/thys/Independence_CH/Infinity_Axiom.thy @@ -1,30 +1,28 @@ section\The Axiom of Infinity in $M[G]$\ theory Infinity_Axiom imports Union_Axiom Pairing_Axiom begin -sublocale G_generic1 \ forcing_data1 - by unfold_locales context G_generic1 begin interpretation mg_triv: M_trivial"##M[G]" using transitivity_MG zero_in_MG[of G] generic Union_MG pairing_in_MG by unfold_locales auto lemma infinity_in_MG : "infinity_ax(##M[G])" proof - have "\ \ M[G]" using M_subset_MG one_in_G nat_in_M by auto moreover from this have "succ(y) \ \ \ M[G]" if "y \ \" for y using that transitivity_MG by blast ultimately show ?thesis using transitivity_MG[of 0 \] unfolding infinity_ax_def by auto qed end \ \\<^locale>\G_generic1\\ end \ No newline at end of file diff --git a/thys/Independence_CH/Internal_ZFC_Axioms.thy b/thys/Independence_CH/Internal_ZFC_Axioms.thy --- a/thys/Independence_CH/Internal_ZFC_Axioms.thy +++ b/thys/Independence_CH/Internal_ZFC_Axioms.thy @@ -1,520 +1,519 @@ section\The ZFC axioms, internalized\ theory Internal_ZFC_Axioms imports Fm_Definitions begin schematic_goal ZF_union_auto: "Union_ax(##A) \ (A, [] \ ?zfunion)" unfolding Union_ax_def by ((rule sep_rules | simp)+) synthesize "ZF_union" from_schematic ZF_union_auto notation ZF_union_fm (\\Union Ax\\) schematic_goal ZF_power_auto: "power_ax(##A) \ (A, [] \ ?zfpow)" unfolding power_ax_def powerset_def subset_def by ((rule sep_rules | simp)+) synthesize "ZF_power" from_schematic ZF_power_auto notation ZF_power_fm (\\Powerset Ax\\) schematic_goal ZF_pairing_auto: "upair_ax(##A) \ (A, [] \ ?zfpair)" unfolding upair_ax_def by ((rule sep_rules | simp)+) synthesize "ZF_pairing" from_schematic ZF_pairing_auto notation ZF_pairing_fm (\\Pairing\\) schematic_goal ZF_foundation_auto: "foundation_ax(##A) \ (A, [] \ ?zffound)" unfolding foundation_ax_def by ((rule sep_rules | simp)+) synthesize "ZF_foundation" from_schematic ZF_foundation_auto notation ZF_foundation_fm (\\Foundation\\) schematic_goal ZF_extensionality_auto: "extensionality(##A) \ (A, [] \ ?zfext)" unfolding extensionality_def by ((rule sep_rules | simp)+) synthesize "ZF_extensionality" from_schematic ZF_extensionality_auto notation ZF_extensionality_fm (\\Extensionality\\) schematic_goal ZF_infinity_auto: "infinity_ax(##A) \ (A, [] \ (?\(i,j,h)))" unfolding infinity_ax_def by ((rule sep_rules | simp)+) synthesize "ZF_infinity" from_schematic ZF_infinity_auto notation ZF_infinity_fm (\\Infinity\\) schematic_goal ZF_choice_auto: "choice_ax(##A) \ (A, [] \ (?\(i,j,h)))" unfolding choice_ax_def by ((rule sep_rules | simp)+) synthesize "ZF_choice" from_schematic ZF_choice_auto notation ZF_choice_fm (\\AC\\) lemmas ZFC_fm_defs = ZF_extensionality_fm_def ZF_foundation_fm_def ZF_pairing_fm_def ZF_union_fm_def ZF_infinity_fm_def ZF_power_fm_def ZF_choice_fm_def lemmas ZFC_fm_sats = ZF_extensionality_auto ZF_foundation_auto ZF_pairing_auto ZF_union_auto ZF_infinity_auto ZF_power_auto ZF_choice_auto definition ZF_fin :: "i" where "ZF_fin \ {\Extensionality\, \Foundation\, \Pairing\, \Union Ax\, \Infinity\, \Powerset Ax\}" subsection\The Axiom of Separation, internalized\ lemma iterates_Forall_type [TC]: "\ n \ nat; p \ formula \ \ Forall^n(p) \ formula" by (induct set:nat, auto) lemma last_init_eq : assumes "l \ list(A)" "length(l) = succ(n)" shows "\ a\A. \l'\list(A). l = l'@[a]" proof- from \l\_\ \length(_) = _\ have "rev(l) \ list(A)" "length(rev(l)) = succ(n)" by simp_all then obtain a l' where "a\A" "l'\list(A)" "rev(l) = Cons(a,l')" by (cases;simp) then have "l = rev(l') @ [a]" "rev(l') \ list(A)" using rev_rev_ident[OF \l\_\] by auto with \a\_\ show ?thesis by blast qed lemma take_drop_eq : assumes "l\list(M)" shows "\ n . n < succ(length(l)) \ l = take(n,l) @ drop(n,l)" using \l\list(M)\ proof induct case Nil then show ?case by auto next case (Cons a l) then show ?case proof - { fix i assume "il\list(M)\ consider (lt) "i = 0" | (eq) "\k\nat. i = succ(k) \ k < succ(length(l))" using \l\list(M)\ le_natI nat_imp_quasinat by (cases rule:nat_cases[of i];auto) then have "take(i,Cons(a,l)) @ drop(i,Cons(a,l)) = Cons(a,l)" using Cons by (cases;auto) } then show ?thesis using Cons by auto qed qed lemma list_split : assumes "n \ succ(length(rest))" "rest \ list(M)" shows "\re\list(M). \st\list(M). rest = re @ st \ length(re) = pred(n)" proof - from assms have "pred(n) \ length(rest)" using pred_mono[OF _ \n\_\] pred_succ_eq by auto with \rest\_\ have "pred(n)\nat" "rest = take(pred(n),rest) @ drop(pred(n),rest)" (is "_ = ?re @ ?st") using take_drop_eq[OF \rest\_\] le_natI by auto then have "length(?re) = pred(n)" "?re\list(M)" "?st\list(M)" using length_take[rule_format,OF _ \pred(n)\_\] \pred(n) \ _\ \rest\_\ unfolding min_def by auto then show ?thesis using rev_bexI[of _ _ "\ re. \st\list(M). rest = re @ st \ length(re) = pred(n)"] \length(?re) = _\ \rest = _\ by auto qed lemma sats_nForall: assumes "\ \ formula" shows "n\nat \ ms \ list(M) \ (M, ms \ (Forall^n(\))) \ (\rest \ list(M). length(rest) = n \ M, rest @ ms \ \)" proof (induct n arbitrary:ms set:nat) case 0 with assms show ?case by simp next case (succ n) have "(\rest\list(M). length(rest) = succ(n) \ P(rest,n)) \ (\t\M. \res\list(M). length(res) = n \ P(res @ [t],n))" if "n\nat" for n P using that last_init_eq by force from this[of _ "\rest _. (M, rest @ ms \ \)"] \n\nat\ have "(\rest\list(M). length(rest) = succ(n) \ M, rest @ ms \ \) \ (\t\M. \res\list(M). length(res) = n \ M, (res @ [t]) @ ms \ \)" by simp with assms succ(1,3) succ(2)[of "Cons(_,ms)"] show ?case using arity_sats_iff[of \ _ M "Cons(_, ms @ _)"] app_assoc by (simp) qed definition sep_body_fm :: "i \ i" where "sep_body_fm(p) \ (\\(\\(\\\\0 \ 1\ \ \\0 \ 2\ \ incr_bv1^2 (p) \\\)\)\)" lemma sep_body_fm_type [TC]: "p \ formula \ sep_body_fm(p) \ formula" by (simp add: sep_body_fm_def) lemma sats_sep_body_fm: assumes "\ \ formula" "ms\list(M)" "rest\list(M)" shows "(M, rest @ ms \ sep_body_fm(\)) \ separation(##M,\x. M, [x] @ rest @ ms \ \)" using assms formula_add_params1[of _ 2 _ _ "[_,_]" ] unfolding sep_body_fm_def separation_def by simp definition ZF_separation_fm :: "i \ i" (\\Separation'(_')\\) where "ZF_separation_fm(p) \ Forall^(pred(arity(p)))(sep_body_fm(p))" lemma ZF_separation_fm_type [TC]: "p \ formula \ ZF_separation_fm(p) \ formula" by (simp add: ZF_separation_fm_def) lemma sats_ZF_separation_fm_iff: assumes "\\formula" shows "(M, [] \ \Separation(\)\) \ (\env\list(M). arity(\) \ 1 +\<^sub>\ length(env) \ separation(##M,\x. M, [x] @ env \ \))" proof (intro iffI ballI impI) let ?n="pred(arity(\))" fix env assume "M, [] \ ZF_separation_fm(\)" assume "arity(\) \ 1 +\<^sub>\ length(env)" "env\list(M)" moreover from this have "arity(\) \ succ(length(env))" by simp then obtain some rest where "some\list(M)" "rest\list(M)" "env = some @ rest" "length(some) = pred(arity(\))" using list_split[OF \arity(\) \ succ(_)\ \env\_\] by force moreover from \\\_\ have "arity(\) \ succ(pred(arity(\)))" using succpred_leI by simp moreover note assms moreover assume "M, [] \ ZF_separation_fm(\)" moreover from calculation have "M, some \ sep_body_fm(\)" using sats_nForall[of "sep_body_fm(\)" ?n] unfolding ZF_separation_fm_def by simp ultimately show "separation(##M, \x. M, [x] @ env \ \)" unfolding ZF_separation_fm_def using sats_sep_body_fm[of \ "[]" M some] arity_sats_iff[of \ rest M "[_] @ some"] separation_cong[of "##M" "\x. M, Cons(x, some @ rest) \ \" _ ] by simp next \ \almost equal to the previous implication\ let ?n="pred(arity(\))" assume asm:"\env\list(M). arity(\) \ 1 +\<^sub>\ length(env) \ separation(##M, \x. M, [x] @ env \ \)" { fix some assume "some\list(M)" "length(some) = pred(arity(\))" moreover note \\\_\ moreover from calculation have "arity(\) \ 1 +\<^sub>\ length(some)" using le_trans[OF succpred_leI] succpred_leI by simp moreover from calculation and asm have "separation(##M, \x. M, [x] @ some \ \)" by blast ultimately have "M, some \ sep_body_fm(\)" using sats_sep_body_fm[of \ "[]" M some] arity_sats_iff[of \ _ M "[_,_] @ some"] strong_replacement_cong[of "##M" "\x y. M, Cons(x, Cons(y, some @ _)) \ \" _ ] by simp } with \\\_\ show "M, [] \ ZF_separation_fm(\)" using sats_nForall[of "sep_body_fm(\)" ?n] unfolding ZF_separation_fm_def by simp qed subsection\The Axiom of Replacement, internalized\ schematic_goal sats_univalent_fm_auto: assumes (* Q_iff_sats:"\a b z env aa bb. nth(a,Cons(z,env)) = aa \ nth(b,Cons(z,env)) = bb \ z\A \ aa \ A \ bb \ A \ env\ list(A) \ Q(aa,bb) \ (A, Cons(z,env) \ (Q_fm(a,b)))" \ \using only \ formula\ *) Q_iff_sats:"\x y z. x \ A \ y \ A \ z\A \ Q(x,z) \ (A,Cons(z,Cons(y,Cons(x,env))) \ Q1_fm)" "\x y z. x \ A \ y \ A \ z\A \ Q(x,y) \ (A,Cons(z,Cons(y,Cons(x,env))) \ Q2_fm)" and asms: "nth(i,env) = B" "i \ nat" "env \ list(A)" shows "univalent(##A,B,Q) \ A,env \ ?ufm(i)" unfolding univalent_def by (insert asms; (rule sep_rules Q_iff_sats | simp)+) synthesize_notc "univalent" from_schematic sats_univalent_fm_auto lemma univalent_fm_type [TC]: "q1\ formula \ q2\formula \ i\nat \ univalent_fm(q2,q1,i) \formula" by (simp add:univalent_fm_def) lemma sats_univalent_fm : assumes Q_iff_sats:"\x y z. x \ A \ y \ A \ z\A \ Q(x,z) \ (A,Cons(z,Cons(y,Cons(x,env))) \ Q1_fm)" "\x y z. x \ A \ y \ A \ z\A \ Q(x,y) \ (A,Cons(z,Cons(y,Cons(x,env))) \ Q2_fm)" and asms: "nth(i,env) = B" "i \ nat" "env \ list(A)" shows "(A,env \ univalent_fm(Q1_fm,Q2_fm,i)) \ univalent(##A,B,Q)" unfolding univalent_fm_def using asms sats_univalent_fm_auto[OF Q_iff_sats] by simp definition swap_vars :: "i\i" where "swap_vars(\) \ Exists(Exists(And(Equal(0,3),And(Equal(1,2),iterates(\p. incr_bv(p)`2 , 2, \)))))" lemma swap_vars_type[TC] : "\\formula \ swap_vars(\) \formula" unfolding swap_vars_def by simp lemma sats_swap_vars : "[x,y] @ env \ list(M) \ \\formula \ (M, [x,y] @ env \ swap_vars(\)) \ M,[y,x] @ env \ \" unfolding swap_vars_def using sats_incr_bv_iff [of _ _ M _ "[y,x]"] by simp definition univalent_Q1 :: "i \ i" where "univalent_Q1(\) \ incr_bv1(swap_vars(\))" definition univalent_Q2 :: "i \ i" where "univalent_Q2(\) \ incr_bv(swap_vars(\))`0" lemma univalent_Qs_type [TC]: assumes "\\formula" shows "univalent_Q1(\) \ formula" "univalent_Q2(\) \ formula" unfolding univalent_Q1_def univalent_Q2_def using assms by simp_all lemma sats_univalent_fm_assm: assumes "x \ A" "y \ A" "z\A" "env\ list(A)" "\ \ formula" shows "(A, ([x,z] @ env) \ \) \ (A, Cons(z,Cons(y,Cons(x,env))) \ (univalent_Q1(\)))" "(A, ([x,y] @ env) \ \) \ (A, Cons(z,Cons(y,Cons(x,env))) \ (univalent_Q2(\)))" unfolding univalent_Q1_def univalent_Q2_def using sats_incr_bv_iff[of _ _ A _ "[]"] \ \simplifies iterates of \<^term>\\x. incr_bv(x)`0\\ sats_incr_bv1_iff[of _ "Cons(x,env)" A z y] sats_swap_vars assms by simp_all definition rep_body_fm :: "i \ i" where "rep_body_fm(p) \ Forall(Implies( univalent_fm(univalent_Q1(incr_bv(p)`2),univalent_Q2(incr_bv(p)`2),0), Exists(Forall( Iff(Member(0,1),Exists(And(Member(0,3),incr_bv(incr_bv(p)`2)`2)))))))" lemma rep_body_fm_type [TC]: "p \ formula \ rep_body_fm(p) \ formula" by (simp add: rep_body_fm_def) lemmas ZF_replacement_simps = formula_add_params1[of \ 2 _ M "[_,_]" ] sats_incr_bv_iff[of _ _ M _ "[]"] \ \simplifies iterates of \<^term>\\x. incr_bv(x)`0\\ sats_incr_bv_iff[of _ _ M _ "[_,_]"]\ \simplifies \<^term>\\x. incr_bv(x)`2\\ sats_incr_bv1_iff[of _ _ M] sats_swap_vars for \ M lemma sats_rep_body_fm: assumes "\ \ formula" "ms\list(M)" "rest\list(M)" shows "(M, rest @ ms \ rep_body_fm(\)) \ strong_replacement(##M,\x y. M, [x,y] @ rest @ ms \ \)" using assms ZF_replacement_simps unfolding rep_body_fm_def strong_replacement_def univalent_def unfolding univalent_fm_def univalent_Q1_def univalent_Q2_def by simp definition ZF_replacement_fm :: "i \ i" (\\Replacement'(_')\\) where "ZF_replacement_fm(p) \ Forall^(pred(pred(arity(p))))(rep_body_fm(p))" lemma ZF_replacement_fm_type [TC]: "p \ formula \ ZF_replacement_fm(p) \ formula" by (simp add: ZF_replacement_fm_def) lemma sats_ZF_replacement_fm_iff: assumes "\\formula" shows - "(M, [] \ \Replacement(\)\) - \ - (\env\list(M). arity(\) \ 2 +\<^sub>\ length(env) \ - strong_replacement(##M,\x y. M,[x,y] @ env \ \))" -proof (intro iffI ballI impI) + "(M, [] \ \Replacement(\)\) \ (\env. replacement_assm(M,env,\))" + unfolding replacement_assm_def +proof (intro iffI allI impI) let ?n="pred(pred(arity(\)))" fix env assume "M, [] \ ZF_replacement_fm(\)" "arity(\) \ 2 +\<^sub>\ length(env)" "env\list(M)" moreover from this have "arity(\) \ succ(succ(length(env)))" by (simp) moreover from calculation have "pred(arity(\)) \ succ(length(env))" using pred_mono[OF _ \arity(\)\succ(_)\] pred_succ_eq by simp moreover from calculation obtain some rest where "some\list(M)" "rest\list(M)" "env = some @ rest" "length(some) = pred(pred(arity(\)))" using list_split[OF \pred(_) \ _\ \env\_\] by auto moreover note \\\_\ moreover from this have "arity(\) \ succ(succ(pred(pred(arity(\)))))" using le_trans[OF succpred_leI] succpred_leI by simp moreover from calculation have "M, some \ rep_body_fm(\)" using sats_nForall[of "rep_body_fm(\)" ?n] unfolding ZF_replacement_fm_def by simp ultimately show "strong_replacement(##M, \x y. M, [x, y] @ env \ \)" using sats_rep_body_fm[of \ "[]" M some] arity_sats_iff[of \ rest M "[_,_] @ some"] strong_replacement_cong[of "##M" "\x y. M, Cons(x, Cons(y, some @ rest)) \ \" _ ] by simp next \ \almost equal to the previous implication\ let ?n="pred(pred(arity(\)))" - assume asm:"\env\list(M). arity(\) \ 2 +\<^sub>\ length(env) \ + assume asm:"\env. \ \ formula \ + env \ list(M) \ arity(\) \ 2 +\<^sub>\ length(env) \ strong_replacement(##M, \x y. M, [x, y] @ env \ \)" { fix some assume "some\list(M)" "length(some) = pred(pred(arity(\)))" moreover note \\\_\ moreover from calculation have "arity(\) \ 2 +\<^sub>\ length(some)" using le_trans[OF succpred_leI] succpred_leI by simp moreover from calculation and asm have "strong_replacement(##M, \x y. M, [x, y] @ some \ \)" by blast ultimately have "M, some \ rep_body_fm(\)" using sats_rep_body_fm[of \ "[]" M some] arity_sats_iff[of \ _ M "[_,_] @ some"] strong_replacement_cong[of "##M" "\x y. M, Cons(x, Cons(y, some @ _)) \ \" _ ] by simp } with \\\_\ show "M, [] \ ZF_replacement_fm(\)" using sats_nForall[of "rep_body_fm(\)" ?n] unfolding ZF_replacement_fm_def by simp qed definition ZF_schemes :: "i" where "ZF_schemes \ {\Separation(p)\ . p \ formula } \ {\Replacement(p)\ . p \ formula }" lemma Un_subset_formula [TC]: "A\formula \ B\formula \ A\B \ formula" by auto lemma ZF_schemes_subset_formula [TC]: "ZF_schemes \ formula" unfolding ZF_schemes_def by auto lemma ZF_fin_subset_formula [TC]: "ZF_fin \ formula" unfolding ZF_fin_def by simp definition ZF :: "i" where "ZF \ ZF_schemes \ ZF_fin" lemma ZF_subset_formula [TC]: "ZF \ formula" unfolding ZF_def by auto definition ZFC :: "i" where "ZFC \ ZF \ {\AC\}" definition ZF_minus_P :: "i" where "ZF_minus_P \ ZF - { \Powerset Ax\ }" definition Zermelo_fms :: "i" (\\Z\\) where "Zermelo_fms \ ZF_fin \ {\Separation(p)\ . p \ formula }" definition ZC :: "i" where "ZC \ Zermelo_fms \ {\AC\}" lemma ZFC_subset_formula: "ZFC \ formula" by (simp add:ZFC_def Un_subset_formula) text\Satisfaction of a set of sentences\ definition satT :: "[i,i] \ o" ("_ \ _" [36,36] 60) where "A \ \ \ \\\\. (A,[] \ \)" lemma satTI [intro!]: assumes "\\. \\\ \ A,[] \ \" shows "A \ \" using assms unfolding satT_def by simp lemma satTD [dest] :"A \ \ \ \\\ \ A,[] \ \" unfolding satT_def by simp lemma satT_mono: "A \ \ \ \ \ \ \ A \ \" by blast lemma satT_Un_iff: "M \ \ \ \ \ M \ \ \ M \ \" by auto lemma sats_ZFC_iff_sats_ZF_AC: "(N \ ZFC) \ (N \ ZF) \ (N, [] \ \AC\)" unfolding ZFC_def ZF_def by auto lemma satT_ZF_imp_satT_Z: "M \ ZF \ M \ \Z\" unfolding ZF_def ZF_schemes_def Zermelo_fms_def ZF_fin_def by auto lemma satT_ZFC_imp_satT_ZC: "M \ ZFC \ M \ ZC" unfolding ZFC_def ZF_def ZF_schemes_def ZC_def Zermelo_fms_def by auto lemma satT_Z_ZF_replacement_imp_satT_ZF: "N \ \Z\ \ N \ {\Replacement(x)\ . x \ formula} \ N \ ZF" unfolding ZF_def ZF_schemes_def Zermelo_fms_def ZF_fin_def by auto lemma satT_ZC_ZF_replacement_imp_satT_ZFC: "N \ ZC \ N \ {\Replacement(x)\ . x \ formula} \ N \ ZFC" unfolding ZFC_def ZF_def ZF_schemes_def ZC_def Zermelo_fms_def by auto lemma ground_repl_fm_sub_ZF: "{\Replacement(ground_repl_fm(\))\ . \ \ formula} \ ZF" unfolding ZF_def ZF_schemes_def by auto lemma ZF_replacement_fms_sub_ZFC: "{\Replacement(\)\ . \ \ formula} \ ZFC" unfolding ZFC_def ZF_def ZF_schemes_def by auto lemma ground_repl_fm_sub_ZFC: "{\Replacement(ground_repl_fm(\))\ . \ \ formula} \ ZFC" unfolding ZFC_def ZF_def ZF_schemes_def by auto lemma ZF_replacement_ground_repl_fm_type: "{\Replacement(ground_repl_fm(\))\ . \ \ formula} \ formula" by auto end diff --git a/thys/Independence_CH/Kappa_Closed_Notions.thy b/thys/Independence_CH/Kappa_Closed_Notions.thy --- a/thys/Independence_CH/Kappa_Closed_Notions.thy +++ b/thys/Independence_CH/Kappa_Closed_Notions.thy @@ -1,723 +1,723 @@ section\Preservation results for $\kappa$-closed forcing notions\ theory Kappa_Closed_Notions imports Not_CH begin definition lerel :: "i\i" where "lerel(\) \ Memrel(\) \ id(\)" lemma lerelI[intro!]: "x\y \ y\\ \ Ord(\) \ \x,y\ \ lerel(\)" using Ord_trans[of x y \] ltD unfolding lerel_def by auto lemma lerelD[dest]: "\x,y\ \ lerel(\) \ Ord(\) \ x\y" using ltI[THEN leI] Ord_in_Ord unfolding lerel_def by auto definition mono_seqspace :: "[i,i,i] \ i" (\_ \<^sub><\ '(_,_')\ [61] 60) where "\ \<^sub><\ (P,leq) \ mono_map(\,Memrel(\),P,leq)" relativize functional "mono_seqspace" "mono_seqspace_rel" relationalize "mono_seqspace_rel" "is_mono_seqspace" synthesize "is_mono_seqspace" from_definition assuming "nonempty" context M_ZF_library begin rel_closed for "mono_seqspace" unfolding mono_seqspace_rel_def mono_map_rel_def using separation_closed separation_ball separation_imp separation_in lam_replacement_fst lam_replacement_snd lam_replacement_hcomp lam_replacement_constant lam_replacement_product lam_replacement_apply2[THEN[5] lam_replacement_hcomp2] by simp_all end \ \\<^locale>\M_ZF_library\\ abbreviation mono_seqspace_r (\_ \<^sub><\\<^bsup>_\<^esup> '(_,_')\ [61] 60) where "\ \<^sub><\\<^bsup>M\<^esup> (P,leq) \ mono_seqspace_rel(M,\,P,leq)" abbreviation mono_seqspace_r_set (\_ \<^sub><\\<^bsup>_\<^esup> '(_,_')\ [61] 60) where "\ \<^sub><\\<^bsup>M\<^esup> (P,leq) \ mono_seqspace_rel(##M,\,P,leq)" lemma mono_seqspaceI[intro!]: includes mono_map_rules assumes "f: A\P" "\x y. x\A \ y\A \ x \f`x, f`y\ \ leq" "Ord(A)" shows "f: A \<^sub><\ (P,leq)" using ltI[OF _ Ord_in_Ord[of A], THEN [3] assms(2)] assms(1,3) unfolding mono_seqspace_def by auto lemma (in M_ZF_library) mono_seqspace_rel_char: assumes "M(A)" "M(P)" "M(leq)" shows "A \<^sub><\\<^bsup>M\<^esup> (P,leq) = {f\A \<^sub><\ (P,leq). M(f)}" using assms mono_map_rel_char unfolding mono_seqspace_def mono_seqspace_rel_def by simp lemma (in M_ZF_library) mono_seqspace_relI[intro!]: assumes "f: A\\<^bsup>M\<^esup> P" "\x y. x\A \ y\A \ x \f`x, f`y\ \ leq" "Ord(A)" "M(A)" "M(P)" "M(leq)" shows "f: A \<^sub><\\<^bsup>M\<^esup> (P,leq)" using mono_seqspace_rel_char function_space_rel_char assms by auto lemma mono_seqspace_is_fun[dest]: includes mono_map_rules shows "j: A \<^sub><\ (P,leq) \ j: A\ P" unfolding mono_seqspace_def by auto lemma mono_map_lt_le_is_mono[dest]: includes mono_map_rules assumes "j: A \<^sub><\ (P,leq)" "a\A" "c\A" "a\c" "Ord(A)" "refl(P,leq)" shows "\j`a,j`c\ \ leq" using assms mono_map_increasing unfolding mono_seqspace_def refl_def by (cases "a=c") (auto dest:ltD) lemma (in M_ZF_library) mem_mono_seqspace_abs[absolut]: assumes "M(f)" "M(A)" "M(P)" "M(leq)" shows "f:A \<^sub><\\<^bsup>M\<^esup> (P,leq) \ f: A \<^sub><\ (P,leq)" using assms mono_map_rel_char unfolding mono_seqspace_def mono_seqspace_rel_def by (simp) definition mono_map_lt_le :: "[i,i] \ i" (infixr \\<^sub><\\<^sub>\\ 60) where "\ \<^sub><\\<^sub>\ \ \ \ \<^sub><\ (\,lerel(\))" lemma mono_map_lt_leI[intro!]: includes mono_map_rules assumes "f: A\B" "\x y. x\A \ y\A \ x f`x \ f`y" "Ord(A)" "Ord(B)" shows "f: A \<^sub><\\<^sub>\ B" using assms unfolding mono_map_lt_le_def by auto \ \Kunen IV.7.13, with “$\kappa$” in place of “$\lambda$”\ definition kappa_closed :: "[i,i,i] \ o" (\_-closed'(_,_')\) where "\-closed(P,leq) \ \\. \<\ \ (\f\\ \<^sub><\ (P,converse(leq)). \q\P. \\\\. \q,f`\\\leq)" relativize functional "kappa_closed" "kappa_closed_rel" relationalize "kappa_closed_rel" "is_kappa_closed" synthesize "is_kappa_closed" from_definition assuming "nonempty" abbreviation kappa_closed_r (\_-closed\<^bsup>_\<^esup>'(_,_')\ [61] 60) where "\-closed\<^bsup>M\<^esup>(P,leq) \ kappa_closed_rel(M,\,P,leq)" abbreviation kappa_closed_r_set (\_-closed\<^bsup>_\<^esup>'(_,_')\ [61] 60) where "\-closed\<^bsup>M\<^esup>(P,leq) \ kappa_closed_rel(##M,\,P,leq)" -lemma (in forcing_data4) forcing_a_value: +lemma (in forcing_data3) forcing_a_value: assumes "p \ \0:1\2\ [f_dot, A\<^sup>v, B\<^sup>v]" "a \ A" "q \ p" "q \ P" "p\P" "f_dot \ M" "A\M" "B\M" shows "\d\P. \b\B. d \ q \ d \ \0`1 is 2\ [f_dot, a\<^sup>v, b\<^sup>v]" (* \ \Old neater version, but harder to use (without the assumptions on \<^term>\q\):\ "dense_below({q \ P. \b\B. q \ \0`1 is 2\ [f_dot, a\<^sup>v, b\<^sup>v]}, p)" *) proof - from assms have "q \ \0:1\2\ [f_dot, A\<^sup>v, B\<^sup>v]" using strengthening_lemma[of p "\0:1\2\" q "[f_dot, A\<^sup>v, B\<^sup>v]"] typed_function_type arity_typed_function_fm by (auto simp: union_abs2 union_abs1) from \a\A\ \A\M\ have "a\M" by (auto dest:transitivity) from \q\P\ text\Here we're using countability (via the existence of generic filters) of \<^term>\M\ as a shortcut, to avoid a further density argument.\ obtain G where "M_generic(G)" "q\G" using generic_filter_existence by blast then - interpret G_generic4_AC _ _ _ _ _ G by unfold_locales + interpret G_generic3_AC _ _ _ _ _ G by unfold_locales include G_generic1_lemmas note \q\G\ moreover note \q \ \0:1\2\ [f_dot, A\<^sup>v, B\<^sup>v]\ \M_generic(G)\ moreover note \q\P\ \f_dot\M\ \B\M\ \A\M\ moreover from this have "map(val( G), [f_dot, A\<^sup>v, B\<^sup>v]) \ list(M[G])" by simp moreover from calculation have "val(G,f_dot) : A \\<^bsup>M[G]\<^esup> B" using truth_lemma[of "\0:1\2\" "[f_dot, A\<^sup>v, B\<^sup>v]", THEN iffD1] typed_function_type arity_typed_function_fm val_check[OF one_in_G one_in_P] by (auto simp: union_abs2 union_abs1 ext.mem_function_space_rel_abs) moreover note \a \ M\ moreover from calculation and \a\A\ have "val(G,f_dot) ` a \ B" (is "?b \ B") by (simp add: ext.mem_function_space_rel_abs) moreover from calculation have "?b \ M" by (auto dest:transitivity) moreover from calculation have "M[G], map(val(G), [f_dot, a\<^sup>v, ?b\<^sup>v]) \ \0`1 is 2\" by simp ultimately obtain r where "r \ \0`1 is 2\ [f_dot, a\<^sup>v, ?b\<^sup>v]" "r\G" "r\P" using truth_lemma[of "\0`1 is 2\" "[f_dot, a\<^sup>v, ?b\<^sup>v]", THEN iffD2] fun_apply_type arity_fun_apply_fm val_check[OF one_in_G one_in_P] G_subset_P by (auto simp: union_abs2 union_abs1 ext.mem_function_space_rel_abs) moreover from this and \q\G\ obtain d where "d\q" "d\r" "d\P" by force moreover note \f_dot\M\ \a\M\ \?b\B\ \B\M\ moreover from calculation have "d \ q \ d \ \0`1 is 2\ [f_dot, a\<^sup>v, ?b\<^sup>v]" using fun_apply_type arity_fun_apply_fm strengthening_lemma[of r "\0`1 is 2\" d "[f_dot, a\<^sup>v, ?b\<^sup>v]"] by (auto dest:transitivity simp add: union_abs2 union_abs1) ultimately show ?thesis by auto qed locale M_master_CH = M_master + M_library_DC -sublocale M_ZFC3_ground_CH_trans \ M_master_CH "##M" +sublocale M_ZFC2_ground_CH_trans \ M_master_CH "##M" using replacement_dcwit_repl_body by unfold_locales (simp_all add:sep_instances del:setclass_iff add: transrec_replacement_def wfrec_replacement_def dcwit_repl_body_def) -context G_generic4_AC_CH begin +context G_generic3_AC_CH begin context includes G_generic1_lemmas begin lemma separation_check_snd_aux: assumes "f_dot\M" "\\M" "\\formula" "arity(\) \ 7" shows "separation(##M, \r. M, [fst(r), P, leq, \, f_dot, \, snd(r)\<^sup>v] \ \)" proof - let ?f_fm="fst_fm(1,0)" let ?g_fm="hcomp_fm(check_fm(6),snd_fm,2,0)" note assms moreover have "?f_fm \ formula" "arity(?f_fm) \ 7" "?g_fm \ formula" "arity(?g_fm) \ 8" using ord_simp_union unfolding hcomp_fm_def by (simp_all add:arity) ultimately show ?thesis using separation_sat_after_function using fst_abs snd_abs sats_snd_fm sats_check_fm check_abs unfolding hcomp_fm_def by simp qed lemma separation_check_fst_snd_aux : assumes "f_dot\M" "r\M" "\\formula" "arity(\) \ 7" shows "separation(##M, \p. M, [r, P, leq, \, f_dot, fst(p)\<^sup>v, snd(p)\<^sup>v] \ \)" proof - let ?\="\z. [r, P, leq, \, f_dot, fst(z)\<^sup>v, snd(z)\<^sup>v]" let ?\'="\z. [fst(z)\<^sup>v, P, leq, \, f_dot, r, snd(z)\<^sup>v]" let ?\=" (\\(\\(\\(\\(\\(\\\\0 = 11\ \ \\1 = 7\ \ \\2 = 8\ \ \\3 = 9\ \ \\4 = 10\ \ \\5 = 6\ \ (\p. incr_bv(p)`6)^6 (\) \\\\\\\)\)\)\)\)\)" let ?f_fm="hcomp_fm(check_fm(5),fst_fm,1,0)" let ?g_fm="hcomp_fm(check_fm(6),snd_fm,2,0)" note assms moreover have "?f_fm \ formula" "arity(?f_fm) \ 7" "?g_fm \ formula" "arity(?g_fm) \ 8" using ord_simp_union unfolding hcomp_fm_def by (simp_all add:arity) moreover from assms have fm:"?\\formula" by simp moreover from \\ \ formula\ \arity(\) \ 7\ have "arity(\) = 0 \ arity(\) = 1 \ arity(\) = 2 \ arity(\) = 3 \ arity(\) = 4 \ arity(\) = 5 \ arity(\) = 6 \ arity(\) = 7" unfolding lt_def by auto with calculation and \\ \ formula\ have ar:"arity(?\) \ 7" using arity_incr_bv_lemma by safe (simp_all add: arity ord_simp_union) moreover from calculation have sep:"separation(##M,\z. M,?\'(z)\?\)" using separation_sat_after_function sats_check_fm check_abs fst_abs snd_abs unfolding hcomp_fm_def by simp moreover from assms have "?\(z) \ list(M)" if "(##M)(z)" for z using that by simp moreover from calculation and \r \ M\ \\ \ formula\ have "(M,?\(z) \ \) \ (M,?\'(z)\?\)" if "(##M)(z)" for z using that sats_incr_bv_iff[of _ _ M _ "[_,_,_,_,_,_]"] by simp ultimately show ?thesis using separation_cong[THEN iffD1,OF _ sep] by simp qed lemma separation_leq_and_forces_apply_aux: assumes "f_dot\M" "B\M" shows "\n\M. separation(##M, \x. snd(x) \ fst(x) \ (\b\B. M, [snd(x), P, leq, \, f_dot, (\(n))\<^sup>v, b\<^sup>v] \ forces(\0`1 is 2\ )))" proof - have pred_nat_closed: "pred(n)\M" if "n\M" for n using nat_case_closed that unfolding pred_def by auto have "separation(##M, \z. M, [snd(fst(z)), P, leq, \, f_dot, \, snd(z)\<^sup>v] \ \)" if "\\formula" "arity(\) \ 7" "\\M" for \ \ proof - let ?f_fm="hcomp_fm(snd_fm,fst_fm,1,0)" let ?g_fm="hcomp_fm(check_fm(6),snd_fm,2,0)" note assms moreover have "?f_fm \ formula" "arity(?f_fm) \ 7" "?g_fm \ formula" "arity(?g_fm) \ 8" using ord_simp_union unfolding hcomp_fm_def by (simp_all add:arity) ultimately show ?thesis using separation_sat_after_function sats_check_fm check_abs fst_abs snd_abs that unfolding hcomp_fm_def by simp qed with assms show ?thesis using separation_in lam_replacement_constant lam_replacement_snd lam_replacement_fst lam_replacement_product pred_nat_closed arity_forces[of " \0`1 is 2\"] arity_fun_apply_fm[of 0 1 2] ord_simp_union by(clarify,rule_tac separation_conj,simp_all,rule_tac separation_bex,simp_all) qed lemma separation_leq_and_forces_apply_aux': assumes "f_dot\M" "p\M" "B\M" shows "separation (##M, \p . snd(snd(p)) \ fst(snd(p)) \ (\b\B. M, [snd(snd(p)), P, leq, \, f_dot, (\fst(p))\<^sup>v, b\<^sup>v] \ forces(\0`1 is 2\ )))" proof - have "separation(##M, \z. M, [snd(snd(fst(z))), P, leq, \, f_dot, (\fst(fst(z)))\<^sup>v, snd(z)\<^sup>v] \ \)" if "\\formula" "arity(\) \ 7" for \ proof - let ?f_fm="hcomp_fm(snd_fm,hcomp_fm(snd_fm,fst_fm),1,0)" let ?g="\z . (\(fst(fst(z))))\<^sup>v" let ?g_fm="hcomp_fm(check_fm(6),hcomp_fm(big_union_fm,hcomp_fm(fst_fm,fst_fm)),2,0)" let ?h_fm="hcomp_fm(check_fm(7),snd_fm,3,0)" note assms moreover have f_fm_facts:"?f_fm \ formula" "arity(?f_fm) \ 6" using ord_simp_union unfolding hcomp_fm_def by (simp_all add:arity) moreover from assms have "?g_fm \ formula" "arity(?g_fm) \ 7" "?h_fm \ formula" "arity(?h_fm) \ 8" using ord_simp_union unfolding hcomp_fm_def by (simp_all add:arity) ultimately show ?thesis using separation_sat_after_function3[OF _ _ _ f_fm_facts] check_abs sats_check_fm that fst_abs snd_abs sats_fst_fm sats_snd_fm unfolding hcomp_fm_def by simp qed with assms show ?thesis using separation_conj separation_bex lam_replacement_constant lam_replacement_hcomp lam_replacement_fst lam_replacement_snd arity_forces[of " \0`1 is 2\"] arity_fun_apply_fm[of 0 1 2] ord_simp_union separation_in[OF _ lam_replacement_product] by simp qed lemma separation_closed_leq_and_forces_eq_check_aux : assumes "A\M" "r\G" "\ \ M" shows "(##M)({q\P. \h\A. q \ r \ q \ \0 = 1\ [\, h\<^sup>v]})" proof - have "separation(##M, \z. M, [fst(z), P, leq, \, \, snd(z)\<^sup>v] \ \)" if "\\formula" "arity(\) \ 6" for \ proof - let ?f_fm="fst_fm(1,0)" let ?g_fm="hcomp_fm(check_fm(6),snd_fm,2,0)" note assms moreover have "?f_fm \ formula" "arity(?f_fm) \ 6" "?g_fm \ formula" "arity(?g_fm) \ 7" using ord_simp_union unfolding hcomp_fm_def by (simp_all add:arity) ultimately show ?thesis using separation_sat_after_function_1 sats_fst_fm that fst_abs snd_abs sats_snd_fm sats_check_fm check_abs unfolding hcomp_fm_def by simp qed with assms show ?thesis using separation_conj separation_in G_subset_M[THEN subsetD] lam_replacement_constant lam_replacement_fst lam_replacement_product arity_forces[of "\0 = 1\",simplified] ord_simp_union by(rule_tac separation_closed[OF separation_bex],simp_all) qed lemma separation_closed_forces_apply_aux: assumes "B\M" "f_dot\M" "r\M" shows "(##M)({\n,b\ \ \ \ B. r \ \0`1 is 2\ [f_dot, n\<^sup>v, b\<^sup>v]})" using nat_in_M assms transitivity[OF _ \B\M\] nat_into_M separation_check_fst_snd_aux arity_forces[of " \0`1 is 2\"] arity_fun_apply_fm[of 0 1 2] ord_simp_union unfolding split_def by simp_all \ \Kunen IV.6.9 (3)$\Rightarrow$(2), with general domain.\ lemma kunen_IV_6_9_function_space_rel_eq: assumes "\p \. p \ \0:1\2\ [\, A\<^sup>v, B\<^sup>v] \ p\P \ \ \ M \ \q\P. \h\A \\<^bsup>M\<^esup> B. q \ p \ q \ \0 = 1\ [\, h\<^sup>v]" "A\M" "B\M" shows "A \\<^bsup>M\<^esup> B = A \\<^bsup>M[G]\<^esup> B" proof (intro equalityI; clarsimp simp add: assms function_space_rel_char ext.function_space_rel_char) fix f assume "f \ A \ B" "f \ M[G]" moreover from this obtain \ where "val(G,\) = f" "\ \ M" using GenExtD by force moreover from calculation and \A\M\ \B\M\ obtain r where "r \ \0:1\2\ [\, A\<^sup>v, B\<^sup>v]" "r\G" using truth_lemma[of "\0:1\2\" "[\, A\<^sup>v, B\<^sup>v]"] typed_function_type arity_typed_function_fm val_check[OF one_in_G one_in_P] by (auto simp: union_abs2 union_abs1) moreover from \A\M\ \B\M\ \r\G\ \\ \ M\ have "{q\P. \h\A \\<^bsup>M\<^esup> B. q \ r \ q \ \0 = 1\ [\, h\<^sup>v]} \ M" (is "?D \ M") using separation_closed_leq_and_forces_eq_check_aux by auto moreover from calculation and assms(2-) have "dense_below(?D, r)" using strengthening_lemma[of r "\0:1\2\" _ "[\, A\<^sup>v, B\<^sup>v]", THEN assms(1)[of _ \]] leq_transD generic_dests(1)[of r] by (auto simp: union_abs2 union_abs1 typed_function_type arity_typed_function_fm) blast moreover from calculation obtain q h where "h\A \\<^bsup>M\<^esup> B" "q \ \0 = 1\ [\, h\<^sup>v]" "q \ r" "q\P" "q\G" using generic_inter_dense_below[of ?D r] by blast note \q \ \0 = 1\ [\, h\<^sup>v]\ \\\M\ \h\A \\<^bsup>M\<^esup> B\ \A\M\ \B\M\ \q\G\ moreover from this have "map(val(G), [\, h\<^sup>v]) \ list(M[G])" "h\M" by (auto dest:transitivity) ultimately have "h = f" using truth_lemma[of "\0=1\" "[\, h\<^sup>v]"] val_check[OF one_in_G one_in_P] by (auto simp: ord_simp_union) with \h\M\ show "f \ M" by simp qed subsection\$(\omega+1)$-Closed notions preserve countable sequences\ \ \Kunen IV.7.15, only for countable sequences\ lemma succ_omega_closed_imp_no_new_nat_sequences: assumes "succ(\)-closed\<^bsup>M\<^esup>(P,leq)" "f : \ \ B" "f\M[G]" "B\M" shows "f\M" proof - (* Nice jEdit folding level to read this: 7 *) text\The next long block proves that the assumptions of Lemma @{thm [source] kunen_IV_6_9_function_space_rel_eq} are satisfied.\ { fix p f_dot assume "p \ \0:1\2\ [f_dot, \\<^sup>v, B\<^sup>v]" "p\P" "f_dot\M" let ?subp="{q\P. q \ p}" from \p\P\ have "?subp \ M" using first_section_closed[of P p "converse(leq)"] by (auto dest:transitivity) define S where "S \ \n\nat. {\q,r\ \ ?subp\?subp. r \ q \ (\b\B. r \ \0`1 is 2\ [f_dot, (\(n))\<^sup>v, b\<^sup>v])}" (is "S \ \n\nat. ?Y(n)") define S' where "S' \ \n\nat. {\q,r\ \ ?subp\?subp. r \ q \ (\b\B. r \ \0`1 is 2\ [f_dot, (pred(n))\<^sup>v, b\<^sup>v])}" \ \Towards proving \<^term>\S\M\.\ moreover have "S = S'" unfolding S_def S'_def using pred_nat_eq lam_cong by auto moreover from \B\M\ \?subp\M\ \f_dot\M\ have "{r \ ?subp. \b\B. r \ \0`1 is 2\ [f_dot, (\(n))\<^sup>v, b\<^sup>v]} \ M" (is "?X(n) \ M") if "n\\" for n using that separation_check_snd_aux nat_into_M ord_simp_union arity_forces[of " \0`1 is 2\"] arity_fun_apply_fm by(rule_tac separation_closed[OF separation_bex,simplified], simp_all) moreover have "?Y(n) = (?subp \ ?X(n)) \ converse(leq)" for n by (intro equalityI) auto moreover note \?subp \ M\ \B\M\ \p\P\ \f_dot\M\ moreover from calculation have "n \ \ \ ?Y(n) \ M" for n using nat_into_M by simp moreover from calculation have "S \ M" using separation_leq_and_forces_apply_aux separation_leq_and_forces_apply_aux' transitivity[OF \p\P\] unfolding S_def split_def by(rule_tac lam_replacement_Collect'[THEN lam_replacement_imp_lam_closed,simplified], simp_all) ultimately have "S' \ M" by simp from \p\P\ \f_dot\M\ \p \ \0:1\2\ [f_dot, \\<^sup>v, B\<^sup>v]\ \B\M\ have exr:"\r\P. r \ q \ (\b\B. r \ \0`1 is 2\ [f_dot, pred(n)\<^sup>v, b\<^sup>v])" if "q \ p" "q\P" "n\\" for q n using that forcing_a_value by (auto dest:transitivity) have "\q\?subp. \n\\. \r\?subp. \q,r\ \ S'`n" proof - { fix q n assume "q \ ?subp" "n\\" moreover from this have "q \ p" "q \ P" "pred(n) = \n" using pred_nat_eq by simp_all moreover from calculation and exr obtain r where MM:"r \ q" "\b\B. r \ \0`1 is 2\ [f_dot, pred(n)\<^sup>v, b\<^sup>v]" "r\P" by blast moreover from calculation \q \ p\ \p \ P\ have "r \ p" using leq_transD[of r q p] by auto ultimately have "\r\?subp. r \ q \ (\b\B. r \ \0`1 is 2\ [f_dot, (pred(n))\<^sup>v, b\<^sup>v])" by auto } then show ?thesis unfolding S'_def by simp qed with \p\P\ \?subp \ M\ \S' \ M\ obtain g where "g \ \ \\<^bsup>M\<^esup> ?subp" "g`0 = p" "\n \ nat. \g`n,g`succ(n)\\S'`succ(n)" using sequence_DC[simplified] refl_leq[of p] by blast moreover from this and \?subp \ M\ have "g : \ \ P" "g \ M" using fun_weaken_type[of g \ ?subp P] function_space_rel_char by auto ultimately have "g : \ \<^sub><\\<^bsup>M\<^esup> (P,converse(leq))" using decr_succ_decr[of g] leq_preord unfolding S'_def by (auto simp:absolut intro:leI) moreover from \succ(\)-closed\<^bsup>M\<^esup>(P,leq)\ and this have "\q\M. q \ P \ (\\\M. \ \ \ \ q \ g ` \)" using transitivity[simplified, of g] mono_seqspace_rel_closed[of \ _ "converse(leq)"] unfolding kappa_closed_rel_def by auto ultimately obtain r where "r\P" "r\M" "\n\\. r \ g`n" using nat_into_M by auto with \g`0 = p\ have "r \ p" by blast let ?h="{\n,b\ \ \ \ B. r \ \0`1 is 2\ [f_dot, n\<^sup>v, b\<^sup>v]}" have "function(?h)" proof (rule_tac functionI, rule_tac ccontr, auto simp del: app_Cons) fix n b b' assume "n \ \" "b \ b'" "b \ B" "b' \ B" moreover assume "r \ \0`1 is 2\ [f_dot, n\<^sup>v, b\<^sup>v]" "r \ \0`1 is 2\ [f_dot, n\<^sup>v, b'\<^sup>v]" moreover note \r \ P\ moreover from this have "\ r \ r" by (auto intro!:refl_leq) moreover note \f_dot\M\ \B\M\ ultimately show False using forces_neq_apply_imp_incompatible[of r f_dot "n\<^sup>v" b r b'] transitivity[of _ B] by (auto dest:transitivity) qed moreover have "range(?h) \ B" by auto moreover have "domain(?h) = \" proof - { fix n assume "n \ \" moreover from this have 1:"(\(n)) = pred(n)" using pred_nat_eq by simp moreover from calculation and \\n \ nat. \g`n,g`succ(n)\\S'`succ(n)\ obtain b where "g`(succ(n)) \ \0`1 is 2\ [f_dot, n\<^sup>v, b\<^sup>v]" "b\B" unfolding S'_def by auto moreover from \B\M\ and calculation have "b \ M" "n \ M" by (auto dest:transitivity) moreover note \g : \ \ P\ \\n\\. r \ g`n\ \r\P\ \f_dot\M\ moreover from calculation have "r \ \0`1 is 2\ [f_dot, n\<^sup>v, b\<^sup>v]" using fun_apply_type arity_fun_apply_fm strengthening_lemma[of "g`succ(n)" "\0`1 is 2\" r "[f_dot, n\<^sup>v, b\<^sup>v]"] by (simp add: union_abs2 union_abs1) ultimately have "\b\B. r \ \0`1 is 2\ [f_dot, n\<^sup>v, b\<^sup>v]" by auto } then show ?thesis by force qed moreover have "relation(?h)" unfolding relation_def by simp moreover from \f_dot\M\ \r\M\ \B\M\ have "?h \ M" using separation_closed_forces_apply_aux by simp moreover note \B \ M\ ultimately have "?h: \ \\<^bsup>M\<^esup> B" using function_imp_Pi[THEN fun_weaken_type[of ?h _ "range(?h)" B]] function_space_rel_char by simp moreover note \p \ \0:1\2\ [f_dot, \\<^sup>v, B\<^sup>v]\ \r \ p\ \r\P\ \p\P\ \f_dot\M\ \B\M\ moreover from this have "r \ \0:1\2\ [f_dot, \\<^sup>v, B\<^sup>v]" using strengthening_lemma[of p "\0:1\2\" r "[f_dot, \\<^sup>v, B\<^sup>v]"] typed_function_type arity_typed_function_fm by (auto simp: union_abs2 union_abs1) moreover note \?h\M\ moreover from calculation have "r \ \0 = 1\ [f_dot, ?h\<^sup>v]" proof (intro definition_of_forcing[THEN iffD2] allI impI, simp_all add:union_abs2 union_abs1 del:app_Cons) fix H let ?f="val(H,f_dot)" assume "M_generic(H) \ r \ H" moreover from this interpret g:G_generic1 _ _ _ _ _ H by unfold_locales simp note \r\P\ \f_dot\M\ \B\M\ moreover from calculation have "map(val(H), [f_dot, \\<^sup>v, B\<^sup>v]) \ list(M[H])" "r\H" by simp_all moreover from calculation and \r\H\ and \r \ \0:1\2\ [f_dot, \\<^sup>v, B\<^sup>v]\ have "?f : \ \ B" using g.truth_lemma[of "\0:1\2\" "[f_dot, \\<^sup>v, B\<^sup>v]",THEN iffD1] g.one_in_G one_in_P typed_function_type arity_typed_function_fm val_check by (auto simp: union_abs2 union_abs1) moreover have "?h`n = ?f`n" if "n \ \" for n proof - note \n \ \\ \domain(?h) = \\ moreover from this have "n\domain(?h)" by simp moreover from this obtain b where "r \ \0`1 is 2\ [f_dot, n\<^sup>v, b\<^sup>v]" "b\B" by force moreover note \function(?h)\ moreover from calculation have "b = ?h`n" using function_apply_equality by simp moreover note \B \ M\ moreover from calculation have "?h`n \ M" by (auto dest:transitivity) moreover note \f_dot \ M\ \r \ P\ \M_generic(H) \ r \ H\ \map(val(H), [f_dot, \\<^sup>v, B\<^sup>v]) \ list(M[H])\ moreover from calculation have "[?f, n, ?h`n] \ list(M[H])" using M_subset_MG nat_into_M[of n] g.one_in_G by (auto dest:transitivity) ultimately show ?thesis using definition_of_forcing[of r "\0`1 is 2\" "[f_dot, n\<^sup>v, b\<^sup>v]", THEN iffD1, rule_format, of H]\ \without this line is slower\ val_check g.one_in_G one_in_P nat_into_M by (auto dest:transitivity simp add:fun_apply_type arity_fun_apply_fm union_abs2 union_abs1) qed with calculation and \B\M\ \?h: \ \\<^bsup>M\<^esup> B\ have "?h = ?f" using function_space_rel_char by (rule_tac fun_extension[of ?h \ "\_.B" ?f]) auto ultimately show "?f = val(H, ?h\<^sup>v)" using val_check g.one_in_G one_in_P generic by simp qed ultimately have "\r\P. \h\\ \\<^bsup>M\<^esup> B. r \ p \ r \ \0 = 1\ [f_dot, h\<^sup>v]" by blast } moreover note \B \ M\ assms moreover from calculation have "f : \ \\<^bsup>M\<^esup> B" using kunen_IV_6_9_function_space_rel_eq function_space_rel_char ext.mem_function_space_rel_abs by auto ultimately show ?thesis by (auto dest:transitivity) qed declare mono_seqspace_rel_closed[rule del] \ \Mysteriously breaks the end of the next proof\ lemma succ_omega_closed_imp_no_new_reals: assumes "succ(\)-closed\<^bsup>M\<^esup>(P,leq)" shows "\ \\<^bsup>M\<^esup> 2 = \ \\<^bsup>M[G]\<^esup> 2" proof - from assms have "\ \\<^bsup>M[G]\<^esup> 2 \ \ \\<^bsup>M\<^esup> 2" using succ_omega_closed_imp_no_new_nat_sequences function_space_rel_char ext.function_space_rel_char Aleph_rel_succ Aleph_rel_zero by auto then show ?thesis using function_space_rel_transfer by (intro equalityI) auto qed lemma succ_omega_closed_imp_Aleph_1_preserved: assumes "succ(\)-closed\<^bsup>M\<^esup>(P,leq)" shows "\\<^bsub>1\<^esub>\<^bsup>M\<^esup> = \\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup>" proof - have "\\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup> \ \\<^bsub>1\<^esub>\<^bsup>M\<^esup>" proof (rule ccontr) assume "\ \\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup> \ \\<^bsub>1\<^esub>\<^bsup>M\<^esup>" then have "\\<^bsub>1\<^esub>\<^bsup>M\<^esup> < \\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup>" \ \Ridiculously complicated proof\ using Card_rel_is_Ord ext.Card_rel_is_Ord not_le_iff_lt[THEN iffD1] by auto then have "|\\<^bsub>1\<^esub>\<^bsup>M\<^esup>|\<^bsup>M[G]\<^esup> \ \" using ext.Card_rel_lt_csucc_rel_iff ext.Aleph_rel_zero ext.Aleph_rel_succ ext.Card_rel_nat by (auto intro!:ext.lt_csucc_rel_iff[THEN iffD1] intro:Card_rel_Aleph_rel[THEN Card_rel_is_Ord, of 1]) then obtain f where "f \ inj(\\<^bsub>1\<^esub>\<^bsup>M\<^esup>,\)" "f \ M[G]" using ext.countable_rel_iff_cardinal_rel_le_nat[of "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>", THEN iffD2] unfolding countable_rel_def lepoll_rel_def by auto then obtain g where "g \ surj\<^bsup>M[G]\<^esup>(\, \\<^bsub>1\<^esub>\<^bsup>M\<^esup>)" using ext.inj_rel_imp_surj_rel[of f _ \, OF _ zero_lt_Aleph_rel1[THEN ltD]] by auto moreover from this have "g : \ \ \\<^bsub>1\<^esub>\<^bsup>M\<^esup>" "g \ M[G]" using ext.surj_rel_char surj_is_fun by simp_all moreover note \succ(\)-closed\<^bsup>M\<^esup>(P,leq)\ ultimately have "g \ surj\<^bsup>M\<^esup>(\, \\<^bsub>1\<^esub>\<^bsup>M\<^esup>)" "g \ M" using succ_omega_closed_imp_no_new_nat_sequences mem_surj_abs ext.mem_surj_abs by simp_all then show False using surj_rel_implies_cardinal_rel_le[of g \ "\\<^bsub>1\<^esub>\<^bsup>M\<^esup>"] Card_rel_nat[THEN Card_rel_cardinal_rel_eq] Card_rel_is_Ord not_le_iff_lt[THEN iffD2, OF _ _ nat_lt_Aleph_rel1] by simp qed then show ?thesis using Aleph_rel_le_Aleph_rel by (rule_tac le_anti_sym) simp qed end \ \bundle G\_generic1\_lemmas\ -end \ \\<^locale>\G_generic4_AC\\ +end \ \\<^locale>\G_generic3_AC\\ end \ No newline at end of file diff --git a/thys/Independence_CH/Not_CH.thy b/thys/Independence_CH/Not_CH.thy --- a/thys/Independence_CH/Not_CH.thy +++ b/thys/Independence_CH/Not_CH.thy @@ -1,593 +1,593 @@ section\Model of the negation of the Continuum Hypothesis\ theory Not_CH imports Cardinal_Preservation begin text\We are taking advantage that the poset of finite functions is absolute, and thus we work with the unrelativized \<^term>\Fn\. But it would have been more appropriate to do the following using the relative \<^term>\Fn_rel\. As it turns out, the present theory was developed prior to having \<^term>\Fn\ relativized! We also note that \<^term>\Fn(\,\\\,2)\ is separative, i.e. each \<^term>\X \ Fn(\,\\\,2)\ has two incompatible extensions; therefore we may recover part of our previous theorem @{thm [source] extensions_of_ctms_ZF}. But that result also included the possibility of not having $\AC$ in the ground model, which would not be sensible in a context where the cardinality of the continuum is under discussion. It is also the case that @{thm [source] extensions_of_ctms_ZF} was historically our first formalized result (with a different proof) that showed the forcing machinery had all of its elements in place.\ abbreviation Add_subs :: "i \ i" where "Add_subs(\) \ Fn(\,\\\,2)" abbreviation Add_le :: "i \ i" where "Add_le(\) \ Fnle(\,\ \ \,2)" lemma (in M_aleph) Aleph_rel2_closed[intro,simp]: "M(\\<^bsub>2\<^esub>\<^bsup>M\<^esup>)" using nat_into_Ord by simp locale M_master = M_cohen + M_library + assumes UN_lepoll_assumptions: "M(A) \ M(b) \ M(f) \ M(A') \ separation(M, \y. \x\A'. y = \x, \ i. x\if_range_F_else_F((`)(A), b, f, i)\)" subsection\Non-absolute concepts between extensions\ sublocale M_master \ M_Pi_replacement by unfold_locales locale M_master_sub = M_master + N:M_aleph N for N + assumes M_imp_N: "M(x) \ N(x)" and Ord_iff: "Ord(x) \ M(x) \ N(x)" sublocale M_master_sub \ M_N_Perm using M_imp_N by unfold_locales context M_master_sub begin lemma cardinal_rel_le_cardinal_rel: "M(X) \ |X|\<^bsup>N\<^esup> \ |X|\<^bsup>M\<^esup>" using M_imp_N N.lepoll_rel_cardinal_rel_le[OF lepoll_rel_transfer Card_rel_is_Ord] cardinal_rel_eqpoll_rel[THEN eqpoll_rel_sym, THEN eqpoll_rel_imp_lepoll_rel] by simp lemma Aleph_rel_sub_closed: "Ord(\) \ M(\) \ N(\\<^bsub>\\<^esub>\<^bsup>M\<^esup>)" using Ord_iff[THEN iffD1, OF Card_rel_Aleph_rel[THEN Card_rel_is_Ord]] by simp lemma Card_rel_imp_Card_rel: "Card\<^bsup>N\<^esup>(\) \ M(\) \ Card\<^bsup>M\<^esup>(\)" using N.Card_rel_is_Ord[of \] M_imp_N Ord_cardinal_rel_le[of \] cardinal_rel_le_cardinal_rel[of \] le_anti_sym unfolding Card_rel_def by auto lemma csucc_rel_le_csucc_rel: assumes "Ord(\)" "M(\)" shows "(\\<^sup>+)\<^bsup>M\<^esup> \ (\\<^sup>+)\<^bsup>N\<^esup>" proof - note assms moreover from this have "N(L) \ Card\<^bsup>N\<^esup>(L) \ \ < L \ M(L) \ Card\<^bsup>M\<^esup>(L) \ \ < L" (is "?P(L) \ ?Q(L)") for L using M_imp_N Ord_iff[THEN iffD2, of L] N.Card_rel_is_Ord lt_Ord Card_rel_imp_Card_rel by auto moreover from assms have "N((\\<^sup>+)\<^bsup>N\<^esup>)" "Card\<^bsup>N\<^esup>((\\<^sup>+)\<^bsup>N\<^esup>)" "\ < (\\<^sup>+)\<^bsup>N\<^esup>" using N.lt_csucc_rel[of \] N.Card_rel_csucc_rel[of \] M_imp_N by simp_all ultimately show ?thesis using M_imp_N Least_antitone[of _ ?P ?Q] unfolding csucc_rel_def by blast qed lemma Aleph_rel_le_Aleph_rel: "Ord(\) \ M(\) \ \\<^bsub>\\<^esub>\<^bsup>M\<^esup> \ \\<^bsub>\\<^esub>\<^bsup>N\<^esup>" proof (induct rule:trans_induct3) case 0 then show ?case using Aleph_rel_zero N.Aleph_rel_zero by simp next case (succ x) then have "\\<^bsub>x\<^esub>\<^bsup>M\<^esup> \ \\<^bsub>x\<^esub>\<^bsup>N\<^esup>" "Ord(x)" "M(x)" by simp_all moreover from this have "(\\<^bsub>x\<^esub>\<^bsup>M\<^esup>\<^sup>+)\<^bsup>M\<^esup> \ (\\<^bsub>x\<^esub>\<^bsup>N\<^esup>\<^sup>+)\<^bsup>M\<^esup>" using M_imp_N Ord_iff[THEN iffD2, OF N.Card_rel_is_Ord] by (intro csucc_rel_le_mono) simp_all moreover from calculation have "(\\<^bsub>x\<^esub>\<^bsup>N\<^esup>\<^sup>+)\<^bsup>M\<^esup> \ (\\<^bsub>x\<^esub>\<^bsup>N\<^esup>\<^sup>+)\<^bsup>N\<^esup>" using M_imp_N N.Card_rel_is_Ord Ord_iff[THEN iffD2, OF N.Card_rel_is_Ord] by (intro csucc_rel_le_csucc_rel) auto ultimately show ?case using M_imp_N Aleph_rel_succ N.Aleph_rel_succ csucc_rel_le_csucc_rel le_trans by auto next case (limit x) then show ?case using M_imp_N Aleph_rel_limit N.Aleph_rel_limit by simp (blast dest: transM intro!:le_implies_UN_le_UN) qed end \ \\<^locale>\M_master_sub\\ -lemmas (in M_ZF3_trans) sep_instances = +lemmas (in M_ZF2_trans) sep_instances = separation_ifrangeF_body separation_ifrangeF_body2 separation_ifrangeF_body3 separation_ifrangeF_body4 separation_ifrangeF_body5 separation_ifrangeF_body6 separation_ifrangeF_body7 separation_cardinal_rel_lesspoll_rel separation_is_dcwit_body separation_cdltgamma separation_cdeqgamma -lemmas (in M_ZF3_trans) repl_instances = lam_replacement_inj_rel +lemmas (in M_ZF2_trans) repl_instances = lam_replacement_inj_rel -sublocale M_ZFC3_ground_notCH_trans \ M_master "##M" +sublocale M_ZFC2_ground_notCH_trans \ M_master "##M" using replacement_trans_apply_image by unfold_locales (simp_all add:repl_instances sep_instances del:setclass_iff add: transrec_replacement_def wfrec_replacement_def) -sublocale M_ZFC3_trans \ M_Pi_replacement "##M" +sublocale M_ZFC2_trans \ M_Pi_replacement "##M" by unfold_locales subsection\Cohen forcing is ccc\ -context M_ctm3_AC +context M_ctm2_AC begin lemma ccc_Add_subs_Aleph_2: "ccc\<^bsup>M\<^esup>(Add_subs(\\<^bsub>2\<^esub>\<^bsup>M\<^esup>),Add_le(\\<^bsub>2\<^esub>\<^bsup>M\<^esup>))" proof - interpret M_add_reals "##M" "\\<^bsub>2\<^esub>\<^bsup>M\<^esup> \ \" by unfold_locales blast show ?thesis using ccc_rel_Fn_nat by fast qed -end \ \\<^locale>\M_ctm3_AC\\ +end \ \\<^locale>\M_ctm2_AC\\ -sublocale G_generic4_AC \ M_master_sub "##M" "##(M[G])" +sublocale G_generic3_AC \ M_master_sub "##M" "##(M[G])" using M_subset_MG[OF one_in_G] generic Ord_MG_iff by unfold_locales auto lemma (in M_trans) mem_F_bound4: fixes F A defines "F \ (`)" shows "x\F(A,c) \ c \ (range(f) \ domain(A))" using apply_0 unfolding F_def by (cases "M(c)", auto simp:F_def) lemma (in M_trans) mem_F_bound5: fixes F A defines "F \ \_ x. A`x " shows "x\F(A,c) \ c \ (range(f) \ domain(A))" using apply_0 unfolding F_def by (cases "M(c)", auto simp:F_def drSR_Y_def dC_F_def) -sublocale M_ctm3_AC \ M_replacement_lepoll "##M" "(`)" +sublocale M_ctm2_AC \ M_replacement_lepoll "##M" "(`)" using UN_lepoll_assumptions lam_replacement_apply lam_replacement_inj_rel mem_F_bound4 apply_0 lam_replacement_minimum unfolding lepoll_assumptions_defs proof (unfold_locales, rule_tac [3] lam_Least_assumption_general[where U=domain, OF _ mem_F_bound4], simp_all) fix A i x assume "A \ M" "x \ M" "x \ A ` i" then show "i \ M" using apply_0[of i A] transM[of _ "domain(A)", simplified] by force qed -context G_generic4_AC begin +context G_generic3_AC begin context includes G_generic1_lemmas begin lemma G_in_MG: "G \ M[G]" using G_in_Gen_Ext by blast lemma ccc_preserves_Aleph_succ: assumes "ccc\<^bsup>M\<^esup>(P,leq)" "Ord(z)" "z \ M" shows "Card\<^bsup>M[G]\<^esup>(\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>)" proof (rule ccontr) assume "\ Card\<^bsup>M[G]\<^esup>(\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>)" moreover note \z \ M\ \Ord(z)\ moreover from this have "Ord(\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>)" using Card_rel_is_Ord by fastforce ultimately obtain \ f where "\ < \\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>" "f \ surj\<^bsup>M[G]\<^esup>(\, \\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>)" using ext.lt_surj_rel_empty_imp_Card_rel M_subset_MG[OF one_in_G] by force moreover from this and \z\M\ \Ord(z)\ have "\ \ M" "f \ M[G]" using ext.trans_surj_rel_closed by (auto dest:transM ext.transM dest!:ltD) moreover note \ccc\<^bsup>M\<^esup>(P,leq)\ \z\M\ ultimately obtain F where "F:\\Pow\<^bsup>M\<^esup>(\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>)" "\\\\. f`\ \ F`\" "\\\\. |F`\|\<^bsup>M\<^esup> \ \" "F \ M" using ccc_fun_approximation_lemma[of \ "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>" f] ext.mem_surj_abs[of f \ "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>"] \Ord(z)\ surj_is_fun[of f \ "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>"] by auto then have "\ \ \ \ |F`\|\<^bsup>M\<^esup> \ \\<^bsub>0\<^esub>\<^bsup>M\<^esup>" for \ using Aleph_rel_zero by simp have "w \ F ` x \ x \ M" for w x proof - fix w x assume "w \ F`x" then have "x \ domain(F)" using apply_0 by auto with \F:\\Pow\<^bsup>M\<^esup>(\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>)\ \\ \ M\ show "x \ M" using domain_of_fun by (auto dest:transM) qed with \\ \ M\ \F:\\Pow\<^bsup>M\<^esup>(\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>)\ \F\M\ interpret M_cardinal_UN_lepoll "##M" "\\. F`\" \ using UN_lepoll_assumptions lepoll_assumptions lam_replacement_apply lam_replacement_inj_rel lam_replacement_minimum proof (unfold_locales, auto dest:transM simp del:if_range_F_else_F_def) fix f b assume "b\M" "f\M" with \F\M\ show "lam_replacement(##M, \x. \ i. x \ if_range_F_else_F((`)(F), b, f, i))" using UN_lepoll_assumptions mem_F_bound5 by (rule_tac lam_Least_assumption_general[where U="domain", OF _ mem_F_bound5]) simp_all qed from \\ < \\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>\ \\ \ M\ \Ord(z)\ \z\M\ have "\ \\<^bsup>M\<^esup> \\<^bsub>z\<^esub>\<^bsup>M\<^esup>" using cardinal_rel_lt_csucc_rel_iff[of "\\<^bsub>z\<^esub>\<^bsup>M\<^esup>" \] le_Card_rel_iff[of "\\<^bsub>z\<^esub>\<^bsup>M\<^esup>" \] Aleph_rel_succ[of z] Card_rel_lt_iff[of \ "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>"] lt_Ord[of \ "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>"] Card_rel_csucc_rel[of "\\<^bsub>z\<^esub>\<^bsup>M\<^esup>"] Card_rel_Aleph_rel[THEN Card_rel_is_Ord] by simp with \\ < \\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>\ \\\\\. |F`\|\<^bsup>M\<^esup> \ \\ \\ \ M\ assms have "|\\\\. F`\|\<^bsup>M\<^esup> \ \\<^bsub>z\<^esub>\<^bsup>M\<^esup>" using InfCard_rel_Aleph_rel[of z] Aleph_rel_zero subset_imp_lepoll_rel[THEN lepoll_rel_imp_cardinal_rel_le, of "\\\\. F`\" "\\<^bsub>z\<^esub>\<^bsup>M\<^esup>"] Aleph_rel_succ Aleph_rel_increasing[THEN leI, THEN [2] le_trans, of _ 0 z] Ord_0_lt_iff[THEN iffD1, of z] by (cases "0z\M\ \Ord(z)\ moreover from \\\\\. f`\ \ F`\\ \f \ surj\<^bsup>M[G]\<^esup>(\, \\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>)\ \\ \ M\ \f \ M[G]\ and this have "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup> \ (\\\\. F`\)" using ext.mem_surj_abs by (force simp add:surj_def) moreover from \F \ M\ \\ \ M\ have "(\x\\. F ` x) \ M" using j.B_replacement by (intro Union_closed[simplified] RepFun_closed[simplified]) (auto dest:transM) ultimately have "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup> \ \\<^bsub>z\<^esub>\<^bsup>M\<^esup>" using subset_imp_le_cardinal_rel[of "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>" "\\\\. F`\"] le_trans by auto with assms show "False" using Aleph_rel_increasing not_le_iff_lt[of "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>" "\\<^bsub>z\<^esub>\<^bsup>M\<^esup>"] Card_rel_Aleph_rel[THEN Card_rel_is_Ord] by auto qed end \ \bundle G\_generic1\_lemmas\ -end \ \\<^locale>\G_generic4_AC\\ +end \ \\<^locale>\G_generic3_AC\\ context M_ctm1 begin abbreviation Add :: "i" where "Add \ Fn(\, \\<^bsub>2\<^esub>\<^bsup>M\<^esup> \ \, 2)" end \ \\<^locale>\M_ctm1\\ -locale add_generic4 = G_generic4_AC "Fn(\, \\<^bsub>2\<^esub>\<^bsup>##M\<^esup> \ \, 2)" "Fnle(\, \\<^bsub>2\<^esub>\<^bsup>##M\<^esup> \ \, 2)" 0 +locale add_generic3 = G_generic3_AC "Fn(\, \\<^bsub>2\<^esub>\<^bsup>##M\<^esup> \ \, 2)" "Fnle(\, \\<^bsub>2\<^esub>\<^bsup>##M\<^esup> \ \, 2)" 0 -sublocale add_generic4 \ cohen_data \ "\\<^bsub>2\<^esub>\<^bsup>M\<^esup> \ \" 2 by unfold_locales auto +sublocale add_generic3 \ cohen_data \ "\\<^bsub>2\<^esub>\<^bsup>M\<^esup> \ \" 2 by unfold_locales auto -context add_generic4 +context add_generic3 begin notation Leq (infixl "\" 50) notation Incompatible (infixl "\" 50) lemma Add_subs_preserves_Aleph_succ: "Ord(z) \ z\M \ Card\<^bsup>M[G]\<^esup>(\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>)" using ccc_preserves_Aleph_succ ccc_Add_subs_Aleph_2 by auto lemma Aleph_rel_nats_MG_eq_Aleph_rel_nats_M: includes G_generic1_lemmas assumes "z \ \" shows "\\<^bsub>z\<^esub>\<^bsup>M[G]\<^esup> = \\<^bsub>z\<^esub>\<^bsup>M\<^esup>" using assms proof (induct) case 0 show ?case by(rule trans[OF ext.Aleph_rel_zero Aleph_rel_zero[symmetric]]) next case (succ z) then have "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup> \ \\<^bsub>succ(z)\<^esub>\<^bsup>M[G]\<^esup>" using Aleph_rel_le_Aleph_rel nat_into_M by simp moreover from \z \ \\ have "\\<^bsub>z\<^esub>\<^bsup>M\<^esup> \ M[G]" "\\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup> \ M[G]" using nat_into_M by simp_all moreover from this and \\\<^bsub>z\<^esub>\<^bsup>M[G]\<^esup> = \\<^bsub>z\<^esub>\<^bsup>M\<^esup>\ \z \ \\ have "\\<^bsub>succ(z)\<^esub>\<^bsup>M[G]\<^esup> \ \\<^bsub>succ(z)\<^esub>\<^bsup>M\<^esup>" using ext.Aleph_rel_succ nat_into_M Add_subs_preserves_Aleph_succ[THEN ext.csucc_rel_le, of z] Aleph_rel_increasing[of z "succ(z)"] by simp ultimately show ?case using le_anti_sym by blast qed abbreviation f_G :: "i" (\f\<^bsub>G\<^esub>\) where "f\<^bsub>G\<^esub> \ \G" abbreviation dom_dense :: "i \ i" where "dom_dense(x) \ {p \ Add . x \ domain(p) }" -declare (in M_ctm3_AC) Fn_nat_closed[simplified setclass_iff, simp, intro] -declare (in M_ctm3_AC) Fnle_nat_closed[simp del, rule del, +declare (in M_ctm2_AC) Fn_nat_closed[simplified setclass_iff, simp, intro] +declare (in M_ctm2_AC) Fnle_nat_closed[simp del, rule del, simplified setclass_iff, simp, intro] -declare (in M_ctm3_AC) cexp_rel_closed[simplified setclass_iff, simp, intro] -declare (in G_generic4_AC) ext.cexp_rel_closed[simplified setclass_iff, simp, intro] +declare (in M_ctm2_AC) cexp_rel_closed[simplified setclass_iff, simp, intro] +declare (in G_generic3_AC) ext.cexp_rel_closed[simplified setclass_iff, simp, intro] lemma dom_dense_closed[intro,simp]: "x \ \\<^bsub>2\<^esub>\<^bsup>M\<^esup> \ \ \ dom_dense(x) \ M" using separation_in_domain[of x] nat_into_M by (rule_tac separation_closed[simplified], blast dest:transM) simp lemma domain_f_G: assumes "x \ \\<^bsub>2\<^esub>\<^bsup>M\<^esup>" "y \ \" shows "\x, y\ \ domain(f\<^bsub>G\<^esub>)" proof - from assms have "Add = Fn\<^bsup>M\<^esup>(\,\\<^bsub>2\<^esub>\<^bsup>M\<^esup>\\,2)" using Fn_nat_abs by auto moreover from this have "Fnle(\,\\<^bsub>2\<^esub>\<^bsup>M\<^esup>\\,2) = Fnle\<^bsup>M\<^esup>(\,\\<^bsub>2\<^esub>\<^bsup>M\<^esup>\\,2)" unfolding Fnle_rel_def Fnle_def by auto moreover from calculation assms have "dense(dom_dense(\x, y\))" using dense_dom_dense[of "\x,y\" "\\<^bsub>2\<^esub>\<^bsup>M\<^esup>\\" \ 2] InfCard_rel_nat unfolding dense_def by auto with assms obtain p where "p\dom_dense(\x, y\)" "p\G" using M_generic_denseD[of "dom_dense(\x, y\)"] by auto then show "\x, y\ \ domain(f\<^bsub>G\<^esub>)" by blast qed lemma f_G_funtype: includes G_generic1_lemmas shows "f\<^bsub>G\<^esub> : \\<^bsub>2\<^esub>\<^bsup>M\<^esup> \ \ \ 2" using generic domain_f_G Pi_iff Un_filter_is_function generic subset_trans[OF filter_subset_notion Fn_nat_subset_Pow] by force lemma inj_dense_closed[intro,simp]: "w \ \\<^bsub>2\<^esub>\<^bsup>M\<^esup> \ x \ \\<^bsub>2\<^esub>\<^bsup>M\<^esup> \ inj_dense(\\<^bsub>2\<^esub>\<^bsup>M\<^esup>,2,w,x) \ M" using transM[OF _ Aleph_rel2_closed] separation_conj separation_bex lam_replacement_product separation_in lam_replacement_fst lam_replacement_snd lam_replacement_constant lam_replacement_hcomp[OF lam_replacement_snd lam_replacement_restrict'] separation_bex separation_conj by simp lemma Aleph_rel2_new_reals: assumes "w \ \\<^bsub>2\<^esub>\<^bsup>M\<^esup>" "x \ \\<^bsub>2\<^esub>\<^bsup>M\<^esup>" "w \ x" shows "(\n\\. f\<^bsub>G\<^esub> ` \w, n\) \ (\n\\. f\<^bsub>G\<^esub> ` \x, n\)" proof - have "0\2" by auto with assms have "dense(inj_dense(\\<^bsub>2\<^esub>\<^bsup>M\<^esup>,2,w,x))" unfolding dense_def using dense_inj_dense by auto with assms obtain p where "p\inj_dense(\\<^bsub>2\<^esub>\<^bsup>M\<^esup>,2,w,x)" "p\G" using M_generic_denseD[of "inj_dense(\\<^bsub>2\<^esub>\<^bsup>M\<^esup>,2,w,x)"] by blast then obtain n where "n \ \" "\\w, n\, 1\ \ p" "\\x, n\, 0\ \ p" by blast moreover from this and \p\G\ have "\\w, n\, 1\ \ f\<^bsub>G\<^esub>" "\\x, n\, 0\ \ f\<^bsub>G\<^esub>" by auto moreover from calculation have "f\<^bsub>G\<^esub> ` \w, n\ = 1" "f\<^bsub>G\<^esub> ` \x, n\ = 0" using f_G_funtype apply_equality by auto ultimately have "(\n\\. f\<^bsub>G\<^esub> ` \w, n\) ` n \ (\n\\. f\<^bsub>G\<^esub> ` \x, n\) ` n" by simp then show ?thesis by fastforce qed definition h_G :: "i" (\h\<^bsub>G\<^esub>\) where "h\<^bsub>G\<^esub> \ \\\\\<^bsub>2\<^esub>\<^bsup>M\<^esup>. \n\\. f\<^bsub>G\<^esub>`\\,n\" lemma h_G_in_MG[simp]: includes G_generic1_lemmas shows "h\<^bsub>G\<^esub> \ M[G]" using ext.curry_closed[unfolded curry_def] G_in_MG unfolding h_G_def by simp lemma h_G_inj_Aleph_rel2_reals: "h\<^bsub>G\<^esub> \ inj\<^bsup>M[G]\<^esup>(\\<^bsub>2\<^esub>\<^bsup>M\<^esup>, \ \\<^bsup>M[G]\<^esup> 2)" using Aleph_rel_sub_closed f_G_funtype G_in_MG Aleph_rel_sub_closed ext.curry_rel_exp[unfolded curry_def] ext.curry_closed[unfolded curry_def] ext.mem_function_space_rel_abs by (intro ext.mem_inj_abs[THEN iffD2],simp_all) (auto simp: inj_def h_G_def dest:Aleph_rel2_new_reals) lemma Aleph2_extension_le_continuum_rel: includes G_generic1_lemmas shows "\\<^bsub>2\<^esub>\<^bsup>M[G]\<^esup> \ 2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup>" proof - have "\\<^bsub>2\<^esub>\<^bsup>M[G]\<^esup> \\<^bsup>M[G]\<^esup> \ \\<^bsup>M[G]\<^esup> 2" using ext.def_lepoll_rel[of "\\<^bsub>2\<^esub>\<^bsup>M\<^esup>" "\ \\<^bsup>M[G]\<^esup> 2"] h_G_inj_Aleph_rel2_reals Aleph_rel_nats_MG_eq_Aleph_rel_nats_M by auto moreover from calculation have "\\<^bsub>2\<^esub>\<^bsup>M[G]\<^esup> \\<^bsup>M[G]\<^esup> |\ \\<^bsup>M[G]\<^esup> 2|\<^bsup>M[G]\<^esup>" using ext.lepoll_rel_imp_lepoll_rel_cardinal_rel by simp ultimately have "|\\<^bsub>2\<^esub>\<^bsup>M[G]\<^esup>|\<^bsup>M[G]\<^esup> \ 2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup>" using ext.lepoll_rel_imp_cardinal_rel_le[of "\\<^bsub>2\<^esub>\<^bsup>M[G]\<^esup>" "\ \\<^bsup>M[G]\<^esup> 2", OF _ _ ext.function_space_rel_closed] ext.Aleph_rel_zero unfolding cexp_rel_def by simp then show "\\<^bsub>2\<^esub>\<^bsup>M[G]\<^esup> \ 2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup>" using ext.Card_rel_Aleph_rel[of 2, THEN ext.Card_rel_cardinal_rel_eq] by simp qed lemma Aleph_rel_lt_continuum_rel: "\\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup> < 2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup>" using Aleph2_extension_le_continuum_rel ext.Aleph_rel_increasing[of 1 2] le_trans by auto corollary not_CH: "\\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup> \ 2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup>" using Aleph_rel_lt_continuum_rel by auto -end \ \\<^locale>\add_generic4\\ +end \ \\<^locale>\add_generic3\\ subsection\Models of fragments of $\ZFC + \neg \CH$\ definition ContHyp :: "o" where "ContHyp \ \\<^bsub>1\<^esub> = 2\<^bsup>\\\<^bsub>0\<^esub>\<^esup>" relativize functional "ContHyp" "ContHyp_rel" notation ContHyp_rel (\CH\<^bsup>_\<^esup>\) relationalize "ContHyp_rel" "is_ContHyp" context M_ZF_library begin is_iff_rel for "ContHyp" using is_cexp_iff is_Aleph_iff[of 0] is_Aleph_iff[of 1] unfolding is_ContHyp_def ContHyp_rel_def by (auto simp del:setclass_iff) (rule rexI[of _ _ M, OF _ nonempty], auto) end \ \\<^locale>\M_ZF_library\\ synthesize "is_ContHyp" from_definition assuming "nonempty" arity_theorem for "is_ContHyp_fm" notation is_ContHyp_fm (\\CH\\) theorem ctm_of_not_CH: assumes "M \ \" "Transset(M)" "M \ ZC \ {\Replacement(p)\ . p \ overhead_notCH}" "\ \ formula" "M \ { \Replacement(ground_repl_fm(\))\ . \ \ \}" shows "\N. M \ N \ N \ \ \ Transset(N) \ N \ ZC \ {\\\CH\\} \ { \Replacement(\)\ . \ \ \} \ (\\. Ord(\) \ (\ \ M \ \ \ N))" proof - from \M \ ZC \ {\Replacement(p)\ . p \ overhead_notCH}\ - interpret M_ZFC4 M - using M_satT_overhead_imp_M_ZF4 unfolding overhead_notCH_def by force + interpret M_ZFC3 M + using M_satT_overhead_imp_M_ZF3 unfolding overhead_notCH_def by force from \M \ ZC \ {\Replacement(p)\ . p \ overhead_notCH}\ \Transset(M)\ interpret M_ZF_ground_notCH_trans M using M_satT_imp_M_ZF_ground_notCH_trans unfolding ZC_def by auto from \M \ \\ obtain enum where "enum \ bij(\,M)" using eqpoll_sym unfolding eqpoll_def by blast then - interpret M_ctm4_AC M enum by unfold_locales + interpret M_ctm3_AC M enum by unfold_locales interpret cohen_data \ "\\<^bsub>2\<^esub>\<^bsup>M\<^esup> \ \" 2 by unfold_locales auto have "Add \ M" "Add_le(\\<^bsub>2\<^esub>\<^bsup>M\<^esup>) \ M" using nat_into_M Aleph_rel_closed M_nat cartprod_closed Fn_nat_closed Fnle_nat_closed by simp_all then interpret forcing_data1 "Add" "Add_le(\\<^bsub>2\<^esub>\<^bsup>M\<^esup>)" 0 M enum by unfold_locales simp_all obtain G where "M_generic(G)" using generic_filter_existence[OF one_in_P] by auto moreover from this - interpret add_generic4 M enum G by unfold_locales + interpret add_generic3 M enum G by unfold_locales have "\ (\\<^bsub>1\<^esub>\<^bsup>M[G]\<^esup> = 2\<^bsup>\\\<^bsub>0\<^esub>\<^bsup>M[G]\<^esup>,M[G]\<^esup>)" using not_CH . then have "M[G], [] \ \\\CH\\" using ext.is_ContHyp_iff by (simp add:ContHyp_rel_def) then have "M[G] \ ZC \ {\\\CH\\}" using ext.M_satT_ZC by auto moreover have "Transset(M[G])" using Transset_MG . moreover have "M \ M[G]" using M_subset_MG[OF one_in_G] generic by simp moreover note \M \ { \Replacement(ground_repl_fm(\))\ . \ \ \}\ \\ \ formula\ ultimately show ?thesis using Ord_MG_iff MG_eqpoll_nat satT_ground_repl_fm_imp_satT_ZF_replacement_fm[of \] by (rule_tac x="M[G]" in exI, blast) qed lemma ZF_replacement_overhead_sub_ZFC: "{\Replacement(p)\ . p \ overhead} \ ZFC" using overhead_type unfolding ZFC_def ZF_def ZF_schemes_def by auto lemma ZF_replacement_overhead_notCH_sub_ZFC: "{\Replacement(p)\ . p \ overhead_notCH} \ ZFC" using overhead_notCH_type unfolding ZFC_def ZF_def ZF_schemes_def by auto lemma ZF_replacement_overhead_CH_sub_ZFC: "{\Replacement(p)\ . p \ overhead_CH} \ ZFC" using overhead_CH_type unfolding ZFC_def ZF_def ZF_schemes_def by auto corollary ctm_ZFC_imp_ctm_not_CH: assumes "M \ \" "Transset(M)" "M \ ZFC" shows "\N. M \ N \ N \ \ \ Transset(N) \ N \ ZFC \ {\\\CH\\} \ (\\. Ord(\) \ (\ \ M \ \ \ N))" proof- from assms have "\N. M \ N \ N \ \ \ Transset(N) \ N \ ZC \ N \ {\\\CH\\} \ N \ {\Replacement(x)\ . x \ formula} \ (\\. Ord(\) \ \ \ M \ \ \ N)" using ctm_of_not_CH[of M formula] satT_ZFC_imp_satT_ZC[of M] satT_mono[OF _ ground_repl_fm_sub_ZFC, of M] satT_mono[OF _ ZF_replacement_overhead_notCH_sub_ZFC, of M] satT_mono[OF _ ZF_replacement_fms_sub_ZFC, of M] by (simp add: satT_Un_iff) then obtain N where "N \ ZC" "N \ {\\\CH\\}" "N \ {\Replacement(x)\ . x \ formula}" "M \ N" "N \ \" "Transset(N)" "(\\. Ord(\) \ \ \ M \ \ \ N)" by auto moreover from this have "N \ ZFC" using satT_ZC_ZF_replacement_imp_satT_ZFC by auto moreover from this and \N \ {\\\CH\\}\ have "N \ ZFC \ {\\\CH\\}" by auto ultimately show ?thesis by auto qed end \ No newline at end of file diff --git a/thys/Independence_CH/Proper_Extension.thy b/thys/Independence_CH/Proper_Extension.thy --- a/thys/Independence_CH/Proper_Extension.thy +++ b/thys/Independence_CH/Proper_Extension.thy @@ -1,83 +1,84 @@ section\Separative notions and proper extensions\ theory Proper_Extension imports Names begin text\The key ingredient to obtain a proper extension is to have a \<^emph>\separative preorder\:\ locale separative_notion = forcing_notion + assumes separative: "p\P \ \q\P. \r\P. q \ p \ r \ p \ q \ r" begin text\For separative preorders, the complement of every filter is dense. Hence an $M$-generic filter cannot belong to the ground model.\ lemma filter_complement_dense: assumes "filter(G)" shows "dense(P - G)" proof fix p assume "p\P" show "\d\P - G. d \ p" proof (cases "p\G") case True note \p\P\ assms moreover obtain q r where "q \ p" "r \ p" "q \ r" "q\P" "r\P" using separative[OF \p\P\] by force with \filter(G)\ obtain s where "s \ p" "s \ G" "s \ P" using filter_imp_compat[of G q r] by auto then show ?thesis by blast next case False with \p\P\ show ?thesis using refl_leq unfolding Diff_def by auto qed qed end \ \\<^locale>\separative_notion\\ -locale ctm_separative = forcing_data2 + separative_notion + +locale ctm_separative = forcing_data1 + separative_notion begin context fixes G assumes generic: "M_generic(G)" begin interpretation G_generic1 P leq \ M enum G by unfold_locales (simp add:generic) lemma generic_not_in_M: shows "G \ M" proof assume "G\M" then have "P - G \ M" using Diff_closed by simp moreover have "\(\q\G. q \ P - G)" "(P - G) \ P" unfolding Diff_def by auto moreover note generic ultimately show "False" using filter_complement_dense[of G] M_generic_denseD[of "P-G"] by auto qed theorem proper_extension: "M \ M[G]" using generic G_in_Gen_Ext one_in_G generic_not_in_M by force end end \ \\<^locale>\ctm_separative\\ end \ No newline at end of file diff --git a/thys/Independence_CH/Replacement_Instances.thy b/thys/Independence_CH/Replacement_Instances.thy --- a/thys/Independence_CH/Replacement_Instances.thy +++ b/thys/Independence_CH/Replacement_Instances.thy @@ -1,1367 +1,1301 @@ section\More Instances of Replacement\ theory Replacement_Instances imports Separation_Instances Transitive_Models.Pointed_DC_Relative begin lemma composition_fm_type[TC]: "a0 \ \ \ a1 \ \ \ a2 \ \ \ composition_fm(a0,a1,a2) \ formula" unfolding composition_fm_def by simp arity_theorem for "composition_fm" definition is_omega_funspace :: "[i\o,i,i,i]\o" where "is_omega_funspace(N,B,n,z) \ \o[N]. omega(N,o) \ n\o \ is_funspace(N, n, B, z)" synthesize "omega_funspace" from_definition "is_omega_funspace" assuming "nonempty" arity_theorem for "omega_funspace_fm" definition HAleph_wfrec_repl_body where "HAleph_wfrec_repl_body(N,mesa,x,z) \ \y[N]. pair(N, x, y, z) \ (\g[N]. (\u[N]. u \ g \ (\a[N]. \y[N]. \ax[N]. \sx[N]. \r_sx[N]. \f_r_sx[N]. pair(N, a, y, u) \ pair(N, a, x, ax) \ upair(N, a, a, sx) \ pre_image(N, mesa, sx, r_sx) \ restriction(N, g, r_sx, f_r_sx) \ ax \ mesa \ is_HAleph(N, a, f_r_sx, y))) \ is_HAleph(N, x, g, y))" (* MOVE THIS to an appropriate place *) arity_theorem for "ordinal_fm" arity_theorem for "is_Limit_fm" arity_theorem for "empty_fm" arity_theorem for "fun_apply_fm" synthesize "HAleph_wfrec_repl_body" from_definition assuming "nonempty" arity_theorem for "HAleph_wfrec_repl_body_fm" definition dcwit_repl_body where "dcwit_repl_body(N,mesa,A,a,s,R) \ \x z. \y[N]. pair(N, x, y, z) \ is_wfrec (N, \n f. is_nat_case (N, a, \m bmfm. \fm[N]. \cp[N]. is_apply(N, f, m, fm) \ is_Collect(N, A, \x. \fmx[N]. (N(x) \ fmx \ R) \ pair(N, fm, x, fmx), cp) \ is_apply(N, s, cp, bmfm), n), mesa, x, y)" manual_schematic for "dcwit_repl_body" assuming "nonempty" unfolding dcwit_repl_body_def by (rule iff_sats is_nat_case_iff_sats is_eclose_iff_sats sep_rules | simp)+ synthesize "dcwit_repl_body" from_schematic definition dcwit_aux_fm where "dcwit_aux_fm(A,s,R) \ (\\\\4`2 is 0\ \ (\\\Collect_fm (succ(succ(succ(succ(succ(succ(succ(succ(succ(succ(A)))))))))), (\\\\0 \ succ(succ(succ(succ(succ(succ(succ(succ(succ(succ(succ(succ(R)))))))))))) \ \ pair_fm(3, 1, 0) \\), 0) \ \ succ(succ(succ(succ(succ(succ(succ(succ(succ(succ(s))))))))))`0 is 2\\\)\\)" arity_theorem for "dcwit_aux_fm" lemma dcwit_aux_fm_type[TC]: "A \ \ \ s \ \ \ R \ \ \ dcwit_aux_fm(A,s,R) \ formula" by (simp_all add: dcwit_aux_fm_def) definition is_nat_case_dcwit_aux_fm where "is_nat_case_dcwit_aux_fm(A,a,s,R) \ is_nat_case_fm (succ(succ(succ(succ(succ(succ(a)))))),dcwit_aux_fm(A,s,R), 2, 0)" lemma is_nat_case_dcwit_aux_fm_type[TC]: "A \ \ \ a \ \ \ s \ \ \ R \ \ \ is_nat_case_dcwit_aux_fm(A,a,s,R) \ formula" by (simp_all add: is_nat_case_dcwit_aux_fm_def) manual_arity for "is_nat_case_dcwit_aux_fm" unfolding is_nat_case_dcwit_aux_fm_def by (rule arity_dcwit_aux_fm[THEN [6] arity_is_nat_case_fm]) simp_all manual_arity for "dcwit_repl_body_fm" using arity_is_nat_case_dcwit_aux_fm[THEN [6] arity_is_wfrec_fm] unfolding dcwit_repl_body_fm_def is_nat_case_dcwit_aux_fm_def dcwit_aux_fm_def by (auto simp add: arity(1-33)) lemma arity_dcwit_repl_body: "arity(dcwit_repl_body_fm(6,5,4,3,2,0,1)) = 7" by (simp_all add: FOL_arities arity_dcwit_repl_body_fm ord_simp_union) definition fst2_snd2 where "fst2_snd2(x) \ \fst(fst(x)), snd(snd(x))\" relativize functional "fst2_snd2" "fst2_snd2_rel" relationalize "fst2_snd2_rel" "is_fst2_snd2" lemma (in M_trivial) fst2_snd2_abs: assumes "M(x)" "M(res)" shows "is_fst2_snd2(M, x, res) \ res = fst2_snd2(x)" unfolding is_fst2_snd2_def fst2_snd2_def using fst_rel_abs snd_rel_abs fst_abs snd_abs assms by simp synthesize "is_fst2_snd2" from_definition assuming "nonempty" arity_theorem for "is_fst2_snd2_fm" definition sndfst_fst2_snd2 where "sndfst_fst2_snd2(x) \ \snd(fst(x)), fst(fst(x)), snd(snd(x))\" relativize functional "sndfst_fst2_snd2" "sndfst_fst2_snd2_rel" relationalize "sndfst_fst2_snd2_rel" "is_sndfst_fst2_snd2" synthesize "is_sndfst_fst2_snd2" from_definition assuming "nonempty" arity_theorem for "is_sndfst_fst2_snd2_fm" definition order_eq_map where "order_eq_map(M,A,r,a,z) \ \x[M]. \g[M]. \mx[M]. \par[M]. ordinal(M,x) & pair(M,a,x,z) & membership(M,x,mx) & pred_set(M,A,a,r,par) & order_isomorphism(M,par,r,x,mx,g)" synthesize "order_eq_map" from_definition assuming "nonempty" arity_theorem for "is_ord_iso_fm" arity_theorem for "order_eq_map_fm" (* Banach *) synthesize "is_banach_functor" from_definition assuming "nonempty" arity_theorem for "is_banach_functor_fm" definition banach_body_iterates where "banach_body_iterates(M,X,Y,f,g,W,n,x,z) \ \y[M]. pair(M, x, y, z) \ (\fa[M]. (\z[M]. z \ fa \ (\xa[M]. \y[M]. \xaa[M]. \sx[M]. \r_sx[M]. \f_r_sx[M]. \sn[M]. \msn[M]. successor(M,n,sn) \ membership(M,sn,msn) \ pair(M, xa, y, z) \ pair(M, xa, x, xaa) \ upair(M, xa, xa, sx) \ pre_image(M, msn, sx, r_sx) \ restriction(M, fa, r_sx, f_r_sx) \ xaa \ msn \ (empty(M, xa) \ y = W) \ (\m[M]. successor(M, m, xa) \ (\gm[M]. is_apply(M, f_r_sx, m, gm) \ is_banach_functor(M, X, Y, f, g, gm, y))) \ (is_quasinat(M, xa) \ empty(M, y)))) \ (empty(M, x) \ y = W) \ (\m[M]. successor(M, m, x) \ (\gm[M]. is_apply(M, fa, m, gm) \ is_banach_functor(M, X, Y, f, g, gm, y))) \ (is_quasinat(M, x) \ empty(M, y)))" synthesize "is_quasinat" from_definition assuming "nonempty" arity_theorem for "is_quasinat_fm" synthesize "banach_body_iterates" from_definition assuming "nonempty" arity_theorem for "banach_body_iterates_fm" definition banach_is_iterates_body where "banach_is_iterates_body(M,X,Y,f,g,W,n,y) \ \om[M]. omega(M,om) \ n \ om \ (\sn[M]. \msn[M]. successor(M, n, sn) \ membership(M, sn, msn) \ (\fa[M]. (\z[M]. z \ fa \ (\x[M]. \y[M]. \xa[M]. \sx[M]. \r_sx[M]. \f_r_sx[M]. pair(M, x, y, z) \ pair(M, x, n, xa) \ upair(M, x, x, sx) \ pre_image(M, msn, sx, r_sx) \ restriction(M, fa, r_sx, f_r_sx) \ xa \ msn \ (empty(M, x) \ y = W) \ (\m[M]. successor(M, m, x) \ (\gm[M]. fun_apply(M, f_r_sx, m, gm) \ is_banach_functor(M, X, Y, f, g, gm, y))) \ (is_quasinat(M, x) \ empty(M, y)))) \ (empty(M, n) \ y = W) \ (\m[M]. successor(M, m, n) \ (\gm[M]. fun_apply(M, fa, m, gm) \ is_banach_functor(M, X, Y, f, g, gm, y))) \ (is_quasinat(M, n) \ empty(M, y))))" synthesize "banach_is_iterates_body" from_definition assuming "nonempty" arity_theorem for "banach_is_iterates_body_fm" (* (##M)(f) \ strong_replacement(##M, \x y. y = \x, transrec(x, \a g. f ` (g `` a))\) *) definition trans_apply_image where "trans_apply_image(f) \ \a g. f ` (g `` a)" relativize functional "trans_apply_image" "trans_apply_image_rel" relationalize "trans_apply_image" "is_trans_apply_image" (* MOVE THIS to an appropriate place *) schematic_goal arity_is_recfun_fm[arity]: "p \ formula \ a \ \ \ z \ \ \ r \ \ \ arity(is_recfun_fm(p, a, z ,r)) = ?ar" unfolding is_recfun_fm_def by (simp add:arity) (* clean simpset from arities, use correct attrib *) (* Don't know why it doesn't use the theorem at \<^file>\Arities\ *) schematic_goal arity_is_wfrec_fm[arity]: "p \ formula \ a \ \ \ z \ \ \ r \ \ \ arity(is_wfrec_fm(p, a, z ,r)) = ?ar" unfolding is_wfrec_fm_def by (simp add:arity) schematic_goal arity_is_transrec_fm[arity]: "p \ formula \ a \ \ \ z \ \ \ arity(is_transrec_fm(p, a, z)) = ?ar" unfolding is_transrec_fm_def by (simp add:arity) synthesize "is_trans_apply_image" from_definition assuming "nonempty" arity_theorem for "is_trans_apply_image_fm" definition transrec_apply_image_body where "transrec_apply_image_body(M,f,mesa,x,z) \ \y[M]. pair(M, x, y, z) \ (\fa[M]. (\z[M]. z \ fa \ (\xa[M]. \y[M]. \xaa[M]. \sx[M]. \r_sx[M]. \f_r_sx[M]. pair(M, xa, y, z) \ pair(M, xa, x, xaa) \ upair(M, xa, xa, sx) \ pre_image(M, mesa, sx, r_sx) \ restriction(M, fa, r_sx, f_r_sx) \ xaa \ mesa \ is_trans_apply_image(M, f, xa, f_r_sx, y))) \ is_trans_apply_image(M, f, x, fa, y))" synthesize "transrec_apply_image_body" from_definition assuming "nonempty" arity_theorem for "transrec_apply_image_body_fm" definition is_trans_apply_image_body where "is_trans_apply_image_body(M,f,\,a,w) \ \z[M]. pair(M,a,z,w) \ a\\ \ (\sa[M]. \esa[M]. \mesa[M]. upair(M, a, a, sa) \ is_eclose(M, sa, esa) \ membership(M, esa, mesa) \ (\fa[M]. (\z[M]. z \ fa \ (\x[M]. \y[M]. \xa[M]. \sx[M]. \r_sx[M]. \f_r_sx[M]. pair(M, x, y, z) \ pair(M, x, a, xa) \ upair(M, x, x, sx) \ pre_image(M, mesa, sx, r_sx) \ restriction(M, fa, r_sx, f_r_sx) \ xa \ mesa \ is_trans_apply_image(M, f, x, f_r_sx, y))) \ is_trans_apply_image(M, f, a, fa, z)))" synthesize "is_trans_apply_image_body" from_definition assuming "nonempty" arity_theorem for "is_trans_apply_image_body_fm" definition replacement_is_omega_funspace_fm where "replacement_is_omega_funspace_fm \ omega_funspace_fm(2,0,1)" definition replacement_HAleph_wfrec_repl_body_fm where "replacement_HAleph_wfrec_repl_body_fm \ HAleph_wfrec_repl_body_fm(2,0,1)" definition replacement_is_fst2_snd2_fm where "replacement_is_fst2_snd2_fm \ is_fst2_snd2_fm(0,1)" definition replacement_is_sndfst_fst2_snd2_fm where "replacement_is_sndfst_fst2_snd2_fm \ is_sndfst_fst2_snd2_fm(0,1)" definition replacement_is_order_eq_map_fm where "replacement_is_order_eq_map_fm \ order_eq_map_fm(2,3,0,1)" definition replacement_transrec_apply_image_body_fm where "replacement_transrec_apply_image_body_fm \ transrec_apply_image_body_fm(3,2,0,1)" definition banach_replacement_iterates_fm where "banach_replacement_iterates_fm \ banach_is_iterates_body_fm(6,5,4,3,2,0,1)" definition replacement_is_trans_apply_image_fm where "replacement_is_trans_apply_image_fm \ is_trans_apply_image_body_fm(3,2,0,1)" (* definition banach_iterates_fm where "banach_iterates_fm \ banach_body_iterates_fm(7,6,5,4,3,2,0,1)" *) definition replacement_dcwit_repl_body_fm where "replacement_dcwit_repl_body_fm \ dcwit_repl_body_fm(6,5,4,3,2,0,1)" -locale M_ZF2 = M_ZF1 + - assumes - replacement_ax2: - "replacement_assm(M,env,replacement_HAleph_wfrec_repl_body_fm)" - "replacement_assm(M,env,replacement_is_order_eq_map_fm)" - -definition instances2_fms where "instances2_fms \ - { replacement_HAleph_wfrec_repl_body_fm, - replacement_is_order_eq_map_fm }" - -text\This set has 12 internalized formulas.\ - -lemmas replacement_instances2_defs = - replacement_HAleph_wfrec_repl_body_fm_def - replacement_is_order_eq_map_fm_def - (* banach_iterates_fm_def *) - -declare (in M_ZF2) replacement_instances2_defs [simp] - -lemma instances2_fms_type[TC]: "instances2_fms \ formula" - unfolding replacement_instances2_defs instances2_fms_def - by (simp del:Lambda_in_M_fm_def) - -locale M_ZF2_trans = M_ZF1_trans + M_ZF2 - text\The following instances are needed only on the ground model. The first one corresponds to the recursive definition of forces for atomic formulas; the next two corresponds to \<^term>\PHcheck\; the following is used to get a generic filter using some form of choice.\ -locale M_ZF_ground = M_ZF2 + +locale M_ZF_ground = M_ZF1 + assumes ZF_ground_replacements: "replacement_assm(M,env,wfrec_Hfrc_at_fm)" "replacement_assm(M,env,wfrec_Hcheck_fm)" "replacement_assm(M,env,Lambda_in_M_fm(check_fm(2,0,1),1))" -locale M_ZF_ground_trans = M_ZF2_trans + M_ZF_ground +locale M_ZF_ground_trans = M_ZF1_trans + M_ZF_ground definition instances_ground_fms where "instances_ground_fms \ { wfrec_Hfrc_at_fm, wfrec_Hcheck_fm, Lambda_in_M_fm(check_fm(2,0,1),1) }" lemmas replacement_instances_ground_defs = wfrec_Hfrc_at_fm_def wfrec_Hcheck_fm_def declare (in M_ZF_ground) replacement_instances_ground_defs [simp] lemma instances_ground_fms_type[TC]: "instances_ground_fms \ formula" using Lambda_in_M_fm_type unfolding instances_ground_fms_def replacement_instances_ground_defs by simp locale M_ZF_ground_notCH = M_ZF_ground + assumes ZF_ground_notCH_replacements: "replacement_assm(M,env,replacement_transrec_apply_image_body_fm)" "replacement_assm(M,env,replacement_is_trans_apply_image_fm)" definition instances_ground_notCH_fms where "instances_ground_notCH_fms \ { replacement_transrec_apply_image_body_fm, replacement_is_trans_apply_image_fm }" lemma instances_ground_notCH_fms_type[TC]: "instances_ground_notCH_fms \ formula" unfolding instances_ground_notCH_fms_def replacement_transrec_apply_image_body_fm_def replacement_is_trans_apply_image_fm_def by simp declare (in M_ZF_ground_notCH) replacement_transrec_apply_image_body_fm_def[simp] replacement_is_trans_apply_image_fm_def[simp] locale M_ZF_ground_notCH_trans = M_ZF_ground_trans + M_ZF_ground_notCH locale M_ZF_ground_CH = M_ZF_ground_notCH + assumes dcwit_replacement: "replacement_assm(M,env,replacement_dcwit_repl_body_fm)" declare (in M_ZF_ground_CH) replacement_dcwit_repl_body_fm_def [simp] locale M_ZF_ground_CH_trans = M_ZF_ground_notCH_trans + M_ZF_ground_CH -locale M_ZFC2 = M_ZFC1 + M_ZF2 - -locale M_ZFC2_trans = M_ZFC1_trans + M_ZF2_trans + M_ZFC2 - -locale M_ctm1 = M_ZF1_trans + +locale M_ctm1 = M_ZF1_trans + M_ZF_ground_trans + fixes enum assumes M_countable: "enum\bij(nat,M)" locale M_ctm1_AC = M_ctm1 + M_ZFC1_trans -locale M_ctm2 = M_ctm1 + M_ZF_ground_trans - -locale M_ctm2_AC = M_ctm2 + M_ZFC2_trans - -context M_ZF2_trans +context M_ZF_ground_CH_trans begin -lemma replacement_HAleph_wfrec_repl_body: - "B\M \ strong_replacement(##M, HAleph_wfrec_repl_body(##M,B))" - using strong_replacement_rel_in_ctm[where \="HAleph_wfrec_repl_body_fm(2,0,1)" and env="[B]"] - zero_in_M arity_HAleph_wfrec_repl_body_fm replacement_ax2(1) ord_simp_union - by simp - -lemma HAleph_wfrec_repl: - "(##M)(sa) \ - (##M)(esa) \ - (##M)(mesa) \ - strong_replacement - (##M, - \x z. \y[##M]. - pair(##M, x, y, z) \ - (\f[##M]. - (\z[##M]. - z \ f \ - (\xa[##M]. - \y[##M]. - \xaa[##M]. - \sx[##M]. - \r_sx[##M]. - \f_r_sx[##M]. - pair(##M, xa, y, z) \ - pair(##M, xa, x, xaa) \ - upair(##M, xa, xa, sx) \ - pre_image(##M, mesa, sx, r_sx) \ restriction(##M, f, r_sx, f_r_sx) \ xaa \ mesa \ is_HAleph(##M, xa, f_r_sx, y))) \ - is_HAleph(##M, x, f, y)))" - using replacement_HAleph_wfrec_repl_body unfolding HAleph_wfrec_repl_body_def by simp - - -lemma (in M_ZF_ground_CH_trans) replacement_dcwit_repl_body: +lemma replacement_dcwit_repl_body: "(##M)(mesa) \ (##M)(A) \ (##M)(a) \ (##M)(s) \ (##M)(R) \ strong_replacement(##M, dcwit_repl_body(##M,mesa,A,a,s,R))" using strong_replacement_rel_in_ctm[where \="dcwit_repl_body_fm(6,5,4,3,2,0,1)" and env="[R,s,a,A,mesa]" and f="dcwit_repl_body(##M,mesa,A,a,s,R)"] zero_in_M arity_dcwit_repl_body dcwit_replacement unfolding replacement_dcwit_repl_body_fm_def by simp -lemma (in M_ZF_ground_CH_trans) dcwit_repl: +lemma dcwit_repl: "(##M)(sa) \ (##M)(esa) \ (##M)(mesa) \ (##M)(A) \ (##M)(a) \ (##M)(s) \ (##M)(R) \ strong_replacement ((##M), \x z. \y[(##M)]. pair((##M), x, y, z) \ is_wfrec ((##M), \n f. is_nat_case ((##M), a, \m bmfm. \fm[(##M)]. \cp[(##M)]. is_apply((##M), f, m, fm) \ is_Collect((##M), A, \x. \fmx[(##M)]. ((##M)(x) \ fmx \ R) \ pair((##M), fm, x, fmx), cp) \ is_apply((##M), s, cp, bmfm), n), mesa, x, y))" using replacement_dcwit_repl_body unfolding dcwit_repl_body_def by simp +end \ \\<^locale>\M_ZF_ground_CH_trans\\ + +context M_ZF1_trans +begin + lemmas M_replacement_ZF_instances = lam_replacement_fst lam_replacement_snd lam_replacement_Union lam_replacement_Image lam_replacement_middle_del lam_replacement_prodRepl lemmas M_separation_ZF_instances = separation_fstsnd_in_sndsnd separation_sndfst_eq_fstsnd -lemma (in M_ZF1_trans) separation_is_dcwit_body: +lemma separation_is_dcwit_body: assumes "(##M)(A)" "(##M)(a)" "(##M)(g)" "(##M)(R)" shows "separation(##M,is_dcwit_body(##M, A, a, g, R))" using assms separation_in_ctm[where env="[A,a,g,R]" and \="is_dcwit_body_fm(1,2,3,4,0)", OF _ _ _ is_dcwit_body_iff_sats[symmetric], of "\_.A" "\_.a" "\_.g" "\_.R" "\x. x"] nonempty arity_is_dcwit_body_fm is_dcwit_body_fm_type by (simp add:ord_simp_union) -end +end \ \\<^locale>\M_ZF1_trans\\ -sublocale M_ZF2_trans \ M_replacement "##M" +sublocale M_ZF1_trans \ M_replacement "##M" using M_replacement_ZF_instances M_separation_ZF_instances by unfold_locales simp -context M_ZF2_trans +context M_ZF1_trans begin lemma separation_Pow_rel: "A\M \ separation(##M, \y. \x \ M . x\A \ y = \x, Pow\<^bsup>##M\<^esup>(x)\)" using separation_assm_sats[of "is_Pow_fm(0,1)"] arity_is_Pow_fm ord_simp_union Pow_rel_closed nonempty Pow_rel_iff by simp lemma strong_replacement_Powapply_rel: "f\M \ strong_replacement(##M, \x y. y = Powapply\<^bsup>##M\<^esup>(f,x))" using Powapply_rel_replacement separation_Pow_rel transM by simp -end +end \ \\<^locale>\M_ZF1_trans\\ -sublocale M_ZF2_trans \ M_Vfrom "##M" +sublocale M_ZF1_trans \ M_Vfrom "##M" using power_ax strong_replacement_Powapply_rel phrank_repl trans_repl_HVFrom wfrec_rank by unfold_locales auto -sublocale M_ZF2_trans \ M_Perm "##M" +sublocale M_ZF1_trans \ M_Perm "##M" using separation_PiP_rel separation_injP_rel separation_surjP_rel lam_replacement_imp_strong_replacement[OF lam_replacement_Sigfun[OF lam_replacement_constant]] Pi_replacement1 unfolding Sigfun_def by unfold_locales simp_all -sublocale M_ZF2_trans \ M_pre_seqspace "##M" +sublocale M_ZF1_trans \ M_pre_seqspace "##M" by unfold_locales -context M_ZF2_trans +context M_ZF1_trans begin lemma separation_inj_rel: "A\M \ separation(##M, \y. \x\M. x \ A \ y = \x, inj_rel(##M,fst(x), snd(x))\)" using arity_is_inj_fm ord_simp_union nonempty inj_rel_closed[simplified] inj_rel_iff[simplified] by (rule_tac separation_assm_bin_sats[of "is_inj_fm(0,1,2)"]) (simp_all add:setclass_def) lemma lam_replacement_inj_rel: "lam_replacement(##M, \x . inj_rel(##M,fst(x),snd(x)))" using lam_replacement_inj_rel' separation_inj_rel by simp -lemma replacement_is_order_eq_map: - "A\M \ r\M \ strong_replacement(##M, order_eq_map(##M,A,r))" - using strong_replacement_rel_in_ctm[where \="order_eq_map_fm(2,3,0,1)" and env="[A,r]" and f="order_eq_map(##M,A,r)"] - order_eq_map_iff_sats[where env="[_,_,A,r]"] zero_in_M fst_snd_closed pair_in_M_iff - arity_order_eq_map_fm ord_simp_union replacement_ax2(2) - by simp - (* These lemmas were required for the original proof of Schröder-Bernstein. lemma banach_iterates: assumes "X\M" "Y\M" "f\M" "g\M" "W\M" shows "iterates_replacement(##M, is_banach_functor(##M,X,Y,f,g), W)" proof - have "strong_replacement(##M, \ x z . banach_body_iterates(##M,X,Y,f,g,W,n,x,z))" if "n\\" for n using assms that arity_banach_body_iterates_fm ord_simp_union nat_into_M strong_replacement_rel_in_ctm[where \="banach_body_iterates_fm(7,6,5,4,3,2,0,1)" and env="[n,W,g,f,Y,X]"] replacement_ax2(3) by simp then show ?thesis using assms nat_into_M Memrel_closed unfolding iterates_replacement_def wfrec_replacement_def is_wfrec_def M_is_recfun_def is_nat_case_def iterates_MH_def banach_body_iterates_def by simp qed lemma separation_banach_functor_iterates: assumes "X\M" "Y\M" "f\M" "g\M" "A\M" shows "separation(##M, \b. \x\A. x \ \ \ b = banach_functor(X, Y, f, g)^x (0))" proof - have " (\xa\M. xa \ A \ xa \ \ \ banach_is_iterates_body(##M, X, Y, f, g, 0, xa, x)) \ (\n\A. n \ \ \ banach_is_iterates_body(##M, X, Y, f, g, 0, n, x))" if "x\M" for x using assms nat_into_M nat_in_M transM[of _ A] transM[of _ \] that by auto then have "separation(##M, \ z . \n\A . n\\ \ banach_is_iterates_body(##M,X,Y,f,g,0,n,z))" using assms nat_into_M nat_in_M arity_banach_is_iterates_body_fm[of 6 5 4 3 2 0 1] ord_simp_union separation_in_ctm[where \="(\\ \\0\7\ \ \\0\8\ \ banach_is_iterates_body_fm(6,5,4,3,2,0,1) \\\)" and env="[0,g,f,Y,X,A,\]"] by (simp add:arity_Exists arity_And) moreover from assms have "(\x\A. x \ \ \ is_iterates(##M,is_banach_functor(##M,X, Y, f, g),0,x,z)) \ (\n\A . n\\ \ banach_is_iterates_body(##M,X,Y,f,g,0,n,z))" if "z\M" for z using nat_in_M nat_into_M transM[of _ A] transM[of _ \] unfolding is_iterates_def wfrec_replacement_def is_wfrec_def M_is_recfun_def is_nat_case_def iterates_MH_def banach_body_iterates_def banach_is_iterates_body_def by simp moreover from assms have "(\x\A. x \ \ \ is_iterates(##M,is_banach_functor(##M,X, Y, f, g),0,x,z)) \ (\x\A. x \ \ \ z = banach_functor(X, Y, f, g)^x (0))" if "z\M" for z using transM[of _ A] nat_in_M nat_into_M that iterates_abs[OF banach_iterates banach_functor_abs] banach_functor_closed by auto ultimately show ?thesis by(rule_tac separation_cong[THEN iffD2],auto) qed lemma banach_replacement: assumes "X\M" "Y\M" "f\M" "g\M" shows "strong_replacement(##M, \n y. n\nat \ y = banach_functor(X, Y, f, g)^n (0))" using assms banach_repl_iter' separation_banach_functor_iterates by simp *) +end \ \\<^locale>\M_ZF1_trans\\ + lemma (in M_basic) rel2_trans_apply: "M(f) \ relation2(M,is_trans_apply_image(M,f),trans_apply_image(f))" unfolding is_trans_apply_image_def trans_apply_image_def relation2_def by auto lemma (in M_basic) apply_image_closed: shows "M(f) \ \x[M]. \g[M]. M(trans_apply_image(f, x, g))" unfolding trans_apply_image_def by simp -end \ \\<^locale>\M_ZF2_trans\\ - context M_ZF_ground_notCH_trans begin lemma replacement_transrec_apply_image_body : "(##M)(f) \ (##M)(mesa) \ strong_replacement(##M,transrec_apply_image_body(##M,f,mesa))" using strong_replacement_rel_in_ctm[where \="transrec_apply_image_body_fm(3,2,0,1)" and env="[mesa,f]"] zero_in_M arity_transrec_apply_image_body_fm ord_simp_union ZF_ground_notCH_replacements(1) by simp lemma transrec_replacement_apply_image: assumes "(##M)(f)" "(##M)(\)" shows "transrec_replacement(##M, is_trans_apply_image(##M, f), \)" using replacement_transrec_apply_image_body[unfolded transrec_apply_image_body_def] assms Memrel_closed singleton_closed eclose_closed unfolding transrec_replacement_def wfrec_replacement_def is_wfrec_def M_is_recfun_def by simp lemma rec_trans_apply_image_abs: assumes "(##M)(f)" "(##M)(x)" "(##M)(y)" "Ord(x)" shows "is_transrec(##M,is_trans_apply_image(##M, f),x,y) \ y = transrec(x,trans_apply_image(f))" using transrec_abs[OF transrec_replacement_apply_image rel2_trans_apply] assms apply_image_closed by simp lemma replacement_is_trans_apply_image: "(##M)(f) \ (##M)(\) \ strong_replacement(##M, \ x z . \y[##M]. pair(##M,x,y,z) \ x\\ \ (is_transrec(##M,is_trans_apply_image(##M, f),x,y)))" unfolding is_transrec_def is_wfrec_def M_is_recfun_def apply(rule_tac strong_replacement_cong[ where P="\ x z. M,[x,z,\,f] \ is_trans_apply_image_body_fm(3,2,0,1)",THEN iffD1]) apply(rule_tac is_trans_apply_image_body_iff_sats[symmetric,unfolded is_trans_apply_image_body_def,where env="[_,_,\,f]"]) apply(simp_all add:zero_in_M) apply(rule_tac ZF_ground_notCH_replacements(2)[unfolded replacement_assm_def, rule_format, where env="[\,f]",simplified]) apply(simp_all add: arity_is_trans_apply_image_body_fm is_trans_apply_image_body_fm_type ord_simp_union) done lemma trans_apply_abs: "(##M)(f) \ (##M)(\) \ Ord(\) \ (##M)(x) \ (##M)(z) \ (x\\ \ z = \x, transrec(x, \a g. f ` (g `` a)) \) \ (\y[##M]. pair(##M,x,y,z) \ x\\ \ (is_transrec(##M,is_trans_apply_image(##M, f),x,y)))" using rec_trans_apply_image_abs Ord_in_Ord transrec_closed[OF transrec_replacement_apply_image rel2_trans_apply,of f,simplified] apply_image_closed unfolding trans_apply_image_def by auto lemma replacement_trans_apply_image: "(##M)(f) \ (##M)(\) \ Ord(\) \ strong_replacement(##M, \x y. x\\ \ y = \x, transrec(x, \a g. f ` (g `` a))\)" using strong_replacement_cong[THEN iffD1,OF _ replacement_is_trans_apply_image,simplified] trans_apply_abs Ord_in_Ord by simp end \ \\<^locale>\M_ZF_ground_notCH_trans\\ definition ifrFb_body where "ifrFb_body(M,b,f,x,i) \ x \ (if b = 0 then if i \ range(f) then if M(converse(f) ` i) then converse(f) ` i else 0 else 0 else if M(i) then i else 0)" relativize functional "ifrFb_body" "ifrFb_body_rel" relationalize "ifrFb_body_rel" "is_ifrFb_body" synthesize "is_ifrFb_body" from_definition assuming "nonempty" arity_theorem for "is_ifrFb_body_fm" definition ifrangeF_body :: "[i\o,i,i,i,i] \ o" where "ifrangeF_body(M,A,b,f) \ \y. \x\A. y = \x,\ i. ifrFb_body(M,b,f,x,i)\" relativize functional "ifrangeF_body" "ifrangeF_body_rel" relationalize "ifrangeF_body_rel" "is_ifrangeF_body" synthesize "is_ifrangeF_body" from_definition assuming "nonempty" arity_theorem for "is_ifrangeF_body_fm" lemma (in M_Z_trans) separation_is_ifrangeF_body: "(##M)(A) \ (##M)(r) \ (##M)(s) \ separation(##M, is_ifrangeF_body(##M,A,r,s))" using separation_in_ctm[where \="is_ifrangeF_body_fm(1,2,3,0)" and env="[A,r,s]"] zero_in_M arity_is_ifrangeF_body_fm ord_simp_union is_ifrangeF_body_fm_type by simp lemma (in M_basic) is_ifrFb_body_closed: "M(r) \ M(s) \ is_ifrFb_body(M, r, s, x, i) \ M(i)" unfolding ifrangeF_body_def is_ifrangeF_body_def is_ifrFb_body_def If_abs by (cases "i\range(s)"; cases "r=0"; auto dest:transM) lemma (in M_ZF1_trans) ifrangeF_body_abs: assumes "(##M)(A)" "(##M)(r)" "(##M)(s)" "(##M)(x)" shows "is_ifrangeF_body(##M,A,r,s,x) \ ifrangeF_body(##M,A,r,s,x)" proof - { fix a assume "a\M" with assms have "(\ i. i\ M \ is_ifrFb_body(##M, r, s, z, i))= (\ i. is_ifrFb_body(##M, r, s, z, i))" for z using is_ifrFb_body_closed[of r s z] by (rule_tac Least_cong[of "\i. i\M \ is_ifrFb_body(##M,r,s,z,i)"]) auto moreover have "(\ i. is_ifrFb_body(##M, r, s, z, i))= (\ i. ifrFb_body(##M, r, s, z, i))" for z proof (rule_tac Least_cong[of "\i. is_ifrFb_body(##M,r,s,z,i)" "\i. ifrFb_body(##M,r,s,z,i)"]) fix y from assms \a\M\ show "is_ifrFb_body(##M, r, s, z, y) \ ifrFb_body(##M, r, s, z, y)" using If_abs apply_0 unfolding ifrFb_body_def is_ifrFb_body_def by (cases "y\M"; cases "y\range(s)"; cases "converse(s)`y \ M"; auto dest:transM split del: split_if del:iffI) (auto simp flip:setclass_iff; (force simp only:setclass_iff))+ qed moreover from \a\M\ have "least(##M, \i. i \ M \ is_ifrFb_body(##M, r, s, z, i), a) \ a = (\ i. i\ M \ is_ifrFb_body(##M, r, s, z,i))" for z using If_abs least_abs'[of "\i. (##M)(i) \ is_ifrFb_body(##M,r,s,z,i)" a] by simp ultimately have "least(##M, \i. i \ M \ is_ifrFb_body(##M, r, s, z, i), a) \ a = (\ i. ifrFb_body(##M, r, s, z,i))" for z by simp } with assms show ?thesis using pair_in_M_iff apply_closed zero_in_M transitivity[of _ A] unfolding ifrangeF_body_def is_ifrangeF_body_def by (auto dest:transM) qed lemma (in M_ZF1_trans) separation_ifrangeF_body: "(##M)(A) \ (##M)(b) \ (##M)(f) \ separation (##M, \y. \x\A. y = \x, \ i. x \ if_range_F_else_F(\x. if (##M)(x) then x else 0, b, f, i)\)" using separation_is_ifrangeF_body ifrangeF_body_abs separation_cong[where P="is_ifrangeF_body(##M,A,b,f)" and M="##M",THEN iffD1] unfolding ifrangeF_body_def if_range_F_def if_range_F_else_F_def ifrFb_body_def by simp (* (##M)(A) \ (##M)(G) \ (##M)(b) \ (##M)(f) \ separation(##M, \y. \x\A. y = \x, \ i. x \ if_range_F_else_F(\a. if (##M)(a) then G`a else 0, b, f, i)\) *) definition ifrFb_body2 where "ifrFb_body2(M,G,b,f,x,i) \ x \ (if b = 0 then if i \ range(f) then if M(converse(f) ` i) then G`(converse(f) ` i) else 0 else 0 else if M(i) then G`i else 0)" relativize functional "ifrFb_body2" "ifrFb_body2_rel" relationalize "ifrFb_body2_rel" "is_ifrFb_body2" synthesize "is_ifrFb_body2" from_definition assuming "nonempty" arity_theorem for "is_ifrFb_body2_fm" definition ifrangeF_body2 :: "[i\o,i,i,i,i,i] \ o" where "ifrangeF_body2(M,A,G,b,f) \ \y. \x\A. y = \x,\ i. ifrFb_body2(M,G,b,f,x,i)\" relativize functional "ifrangeF_body2" "ifrangeF_body2_rel" relationalize "ifrangeF_body2_rel" "is_ifrangeF_body2" synthesize "is_ifrangeF_body2" from_definition assuming "nonempty" arity_theorem for "is_ifrangeF_body2_fm" lemma (in M_Z_trans) separation_is_ifrangeF_body2: "(##M)(A) \ (##M)(G) \ (##M)(r) \ (##M)(s) \ separation(##M, is_ifrangeF_body2(##M,A,G,r,s))" using separation_in_ctm[where \="is_ifrangeF_body2_fm(1,2,3,4,0)" and env="[A,G,r,s]"] zero_in_M arity_is_ifrangeF_body2_fm ord_simp_union is_ifrangeF_body2_fm_type by simp lemma (in M_basic) is_ifrFb_body2_closed: "M(G) \ M(r) \ M(s) \ is_ifrFb_body2(M, G, r, s, x, i) \ M(i)" unfolding ifrangeF_body2_def is_ifrangeF_body2_def is_ifrFb_body2_def If_abs by (cases "i\range(s)"; cases "r=0"; auto dest:transM) lemma (in M_ZF1_trans) ifrangeF_body2_abs: assumes "(##M)(A)" "(##M)(G)" "(##M)(r)" "(##M)(s)" "(##M)(x)" shows "is_ifrangeF_body2(##M,A,G,r,s,x) \ ifrangeF_body2(##M,A,G,r,s,x)" proof - { fix a assume "a\M" with assms have "(\ i. i\ M \ is_ifrFb_body2(##M, G, r, s, z, i))= (\ i. is_ifrFb_body2(##M, G, r, s, z, i))" for z using is_ifrFb_body2_closed[of G r s z] by (rule_tac Least_cong[of "\i. i\M \ is_ifrFb_body2(##M,G,r,s,z,i)"]) auto moreover have "(\ i. is_ifrFb_body2(##M, G, r, s, z, i))= (\ i. ifrFb_body2(##M, G, r, s, z, i))" for z proof (rule_tac Least_cong[of "\i. is_ifrFb_body2(##M,G,r,s,z,i)" "\i. ifrFb_body2(##M,G,r,s,z,i)"]) fix y from assms \a\M\ show "is_ifrFb_body2(##M, G, r, s, z, y) \ ifrFb_body2(##M, G, r, s, z, y)" using If_abs apply_0 unfolding ifrFb_body2_def is_ifrFb_body2_def by (cases "y\M"; cases "y\range(s)"; cases "converse(s)`y \ M"; auto dest:transM split del: split_if del:iffI) (auto simp flip:setclass_iff; (force simp only:setclass_iff))+ qed moreover from \a\M\ have "least(##M, \i. i \ M \ is_ifrFb_body2(##M, G, r, s, z, i), a) \ a = (\ i. i\ M \ is_ifrFb_body2(##M, G, r, s, z,i))" for z using If_abs least_abs'[of "\i. (##M)(i) \ is_ifrFb_body2(##M,G,r,s,z,i)" a] by simp ultimately have "least(##M, \i. i \ M \ is_ifrFb_body2(##M, G, r, s, z, i), a) \ a = (\ i. ifrFb_body2(##M, G, r, s, z,i))" for z by simp } with assms show ?thesis using pair_in_M_iff apply_closed zero_in_M transitivity[of _ A] unfolding ifrangeF_body2_def is_ifrangeF_body2_def by (auto dest:transM) qed lemma (in M_ZF1_trans) separation_ifrangeF_body2: "(##M)(A) \ (##M)(G) \ (##M)(b) \ (##M)(f) \ separation (##M, \y. \x\A. y = \x, \ i. x \ if_range_F_else_F(\a. if (##M)(a) then G ` a else 0, b, f, i)\)" using separation_is_ifrangeF_body2 ifrangeF_body2_abs separation_cong[where P="is_ifrangeF_body2(##M,A,G,b,f)" and M="##M",THEN iffD1] unfolding ifrangeF_body2_def if_range_F_def if_range_F_else_F_def ifrFb_body2_def by simp (* (##M)(A) \ (##M)(b) \ (##M)(f) \ (##M)(F) \ separation(##M, \y. \x\A. y = \x, \ i. x \ if_range_F_else_F(\a. if (##M)(a) then F -`` {a} else 0, b, f, i)\) *) definition ifrFb_body3 where "ifrFb_body3(M,G,b,f,x,i) \ x \ (if b = 0 then if i \ range(f) then if M(converse(f) ` i) then G-``{converse(f) ` i} else 0 else 0 else if M(i) then G-``{i} else 0)" relativize functional "ifrFb_body3" "ifrFb_body3_rel" relationalize "ifrFb_body3_rel" "is_ifrFb_body3" synthesize "is_ifrFb_body3" from_definition assuming "nonempty" arity_theorem for "is_ifrFb_body3_fm" definition ifrangeF_body3 :: "[i\o,i,i,i,i,i] \ o" where "ifrangeF_body3(M,A,G,b,f) \ \y. \x\A. y = \x,\ i. ifrFb_body3(M,G,b,f,x,i)\" relativize functional "ifrangeF_body3" "ifrangeF_body3_rel" relationalize "ifrangeF_body3_rel" "is_ifrangeF_body3" synthesize "is_ifrangeF_body3" from_definition assuming "nonempty" arity_theorem for "is_ifrangeF_body3_fm" lemma (in M_Z_trans) separation_is_ifrangeF_body3: "(##M)(A) \ (##M)(G) \ (##M)(r) \ (##M)(s) \ separation(##M, is_ifrangeF_body3(##M,A,G,r,s))" using separation_in_ctm[where \="is_ifrangeF_body3_fm(1,2,3,4,0)" and env="[A,G,r,s]"] zero_in_M arity_is_ifrangeF_body3_fm ord_simp_union is_ifrangeF_body3_fm_type by simp lemma (in M_basic) is_ifrFb_body3_closed: "M(G) \ M(r) \ M(s) \ is_ifrFb_body3(M, G, r, s, x, i) \ M(i)" unfolding ifrangeF_body3_def is_ifrangeF_body3_def is_ifrFb_body3_def If_abs by (cases "i\range(s)"; cases "r=0"; auto dest:transM) lemma (in M_ZF1_trans) ifrangeF_body3_abs: assumes "(##M)(A)" "(##M)(G)" "(##M)(r)" "(##M)(s)" "(##M)(x)" shows "is_ifrangeF_body3(##M,A,G,r,s,x) \ ifrangeF_body3(##M,A,G,r,s,x)" proof - { fix a assume "a\M" with assms have "(\ i. i\ M \ is_ifrFb_body3(##M, G, r, s, z, i))= (\ i. is_ifrFb_body3(##M, G, r, s, z, i))" for z using is_ifrFb_body3_closed[of G r s z] by (rule_tac Least_cong[of "\i. i\M \ is_ifrFb_body3(##M,G,r,s,z,i)"]) auto moreover have "(\ i. is_ifrFb_body3(##M, G, r, s, z, i))= (\ i. ifrFb_body3(##M, G, r, s, z, i))" for z proof (rule_tac Least_cong[of "\i. is_ifrFb_body3(##M,G,r,s,z,i)" "\i. ifrFb_body3(##M,G,r,s,z,i)"]) fix y from assms \a\M\ show "is_ifrFb_body3(##M, G, r, s, z, y) \ ifrFb_body3(##M, G, r, s, z, y)" using If_abs apply_0 unfolding ifrFb_body3_def is_ifrFb_body3_def by (cases "y\M"; cases "y\range(s)"; cases "converse(s)`y \ M"; auto dest:transM split del: split_if del:iffI) (auto simp flip:setclass_iff; (force simp only:setclass_iff))+ qed moreover from \a\M\ have "least(##M, \i. i \ M \ is_ifrFb_body3(##M, G, r, s, z, i), a) \ a = (\ i. i\ M \ is_ifrFb_body3(##M, G, r, s, z,i))" for z using If_abs least_abs'[of "\i. (##M)(i) \ is_ifrFb_body3(##M,G,r,s,z,i)" a] by simp ultimately have "least(##M, \i. i \ M \ is_ifrFb_body3(##M, G, r, s, z, i), a) \ a = (\ i. ifrFb_body3(##M, G, r, s, z,i))" for z by simp } with assms show ?thesis using pair_in_M_iff apply_closed zero_in_M transitivity[of _ A] unfolding ifrangeF_body3_def is_ifrangeF_body3_def by (auto dest:transM) qed lemma (in M_ZF1_trans) separation_ifrangeF_body3: "(##M)(A) \ (##M)(G) \ (##M)(b) \ (##M)(f) \ separation (##M, \y. \x\A. y = \x, \ i. x \ if_range_F_else_F(\a. if (##M)(a) then G-``{a} else 0, b, f, i)\)" using separation_is_ifrangeF_body3 ifrangeF_body3_abs separation_cong[where P="is_ifrangeF_body3(##M,A,G,b,f)" and M="##M",THEN iffD1] unfolding ifrangeF_body3_def if_range_F_def if_range_F_else_F_def ifrFb_body3_def by simp (* (##M)(A) \ (##M)(b) \ (##M)(f) \ (##M)(A') \ separation(##M, \y. \x\A'. y = \x, \ i. x \ if_range_F_else_F((`)(A), b, f, i)\) *) definition ifrFb_body4 where "ifrFb_body4(G,b,f,x,i) \ x \ (if b = 0 then if i \ range(f) then G`(converse(f) ` i) else 0 else G`i)" relativize functional "ifrFb_body4" "ifrFb_body4_rel" relationalize "ifrFb_body4_rel" "is_ifrFb_body4" synthesize "is_ifrFb_body4" from_definition assuming "nonempty" arity_theorem for "is_ifrFb_body4_fm" definition ifrangeF_body4 :: "[i\o,i,i,i,i,i] \ o" where "ifrangeF_body4(M,A,G,b,f) \ \y. \x\A. y = \x,\ i. ifrFb_body4(G,b,f,x,i)\" relativize functional "ifrangeF_body4" "ifrangeF_body4_rel" relationalize "ifrangeF_body4_rel" "is_ifrangeF_body4" synthesize "is_ifrangeF_body4" from_definition assuming "nonempty" arity_theorem for "is_ifrangeF_body4_fm" lemma (in M_Z_trans) separation_is_ifrangeF_body4: "(##M)(A) \ (##M)(G) \ (##M)(r) \ (##M)(s) \ separation(##M, is_ifrangeF_body4(##M,A,G,r,s))" using separation_in_ctm[where \="is_ifrangeF_body4_fm(1,2,3,4,0)" and env="[A,G,r,s]"] zero_in_M arity_is_ifrangeF_body4_fm ord_simp_union is_ifrangeF_body4_fm_type by simp lemma (in M_basic) is_ifrFb_body4_closed: "M(G) \ M(r) \ M(s) \ is_ifrFb_body4(M, G, r, s, x, i) \ M(i)" using If_abs unfolding ifrangeF_body4_def is_ifrangeF_body4_def is_ifrFb_body4_def fun_apply_def by (cases "i\range(s)"; cases "r=0"; auto dest:transM) lemma (in M_ZF1_trans) ifrangeF_body4_abs: assumes "(##M)(A)" "(##M)(G)" "(##M)(r)" "(##M)(s)" "(##M)(x)" shows "is_ifrangeF_body4(##M,A,G,r,s,x) \ ifrangeF_body4(##M,A,G,r,s,x)" proof - { fix a assume "a\M" with assms have "(\ i. i\ M \ is_ifrFb_body4(##M, G, r, s, z, i))= (\ i. is_ifrFb_body4(##M, G, r, s, z, i))" for z using is_ifrFb_body4_closed[of G r s z] by (rule_tac Least_cong[of "\i. i\M \ is_ifrFb_body4(##M,G,r,s,z,i)"]) auto moreover have "(\ i. is_ifrFb_body4(##M, G, r, s, z, i))= (\ i. ifrFb_body4(G, r, s, z, i))" if "z\M" for z proof (rule_tac Least_cong[of "\i. is_ifrFb_body4(##M,G,r,s,z,i)" "\i. ifrFb_body4(G,r,s,z,i)"]) fix y from assms \a\M\ \z\M\ show "is_ifrFb_body4(##M, G, r, s, z, y) \ ifrFb_body4(G, r, s, z, y)" using If_abs apply_0 unfolding ifrFb_body4_def is_ifrFb_body4_def apply (cases "y\M"; cases "y\range(s)"; cases "r=0"; cases "y\domain(G)"; auto dest:transM split del: split_if del:iffI) by (auto simp flip:setclass_iff; (force simp only: fun_apply_def setclass_iff)) (auto simp flip:setclass_iff simp: fun_apply_def ) qed moreover from \a\M\ have "least(##M, \i. i \ M \ is_ifrFb_body4(##M, G, r, s, z, i), a) \ a = (\ i. i\ M \ is_ifrFb_body4(##M, G, r, s, z,i))" for z using If_abs least_abs'[of "\i. (##M)(i) \ is_ifrFb_body4(##M,G,r,s,z,i)" a] by simp ultimately have "z\M \ least(##M, \i. i \ M \ is_ifrFb_body4(##M, G, r, s, z, i), a) \ a = (\ i. ifrFb_body4(G, r, s, z,i))" for z by simp } with assms show ?thesis using pair_in_M_iff apply_closed zero_in_M transitivity[of _ A] unfolding ifrangeF_body4_def is_ifrangeF_body4_def by (auto dest:transM) qed lemma (in M_ZF1_trans) separation_ifrangeF_body4: "(##M)(A) \ (##M)(G) \ (##M)(b) \ (##M)(f) \ separation(##M, \y. \x\A. y = \x, \ i. x \ if_range_F_else_F((`)(G), b, f, i)\)" using separation_is_ifrangeF_body4 ifrangeF_body4_abs separation_cong[where P="is_ifrangeF_body4(##M,A,G,b,f)" and M="##M",THEN iffD1] unfolding ifrangeF_body4_def if_range_F_def if_range_F_else_F_def ifrFb_body4_def by simp (* (##M)(G) \ (##M)(A) \ separation(##M, \y. \x\A. y = \x, \ i. x \ if_range_F_else_F(\x. {xa \ G . x \ xa}, b, f, i)\) *) definition ifrFb_body5 where "ifrFb_body5(G,b,f,x,i) \ x \ (if b = 0 then if i \ range(f) then {xa \ G . converse(f) ` i \ xa} else 0 else {xa \ G . i \ xa})" relativize functional "ifrFb_body5" "ifrFb_body5_rel" relationalize "ifrFb_body5_rel" "is_ifrFb_body5" synthesize "is_ifrFb_body5" from_definition assuming "nonempty" arity_theorem for "is_ifrFb_body5_fm" definition ifrangeF_body5 :: "[i\o,i,i,i,i,i] \ o" where "ifrangeF_body5(M,A,G,b,f) \ \y. \x\A. y = \x,\ i. ifrFb_body5(G,b,f,x,i)\" relativize functional "ifrangeF_body5" "ifrangeF_body5_rel" relationalize "ifrangeF_body5_rel" "is_ifrangeF_body5" synthesize "is_ifrangeF_body5" from_definition assuming "nonempty" arity_theorem for "is_ifrangeF_body5_fm" lemma (in M_Z_trans) separation_is_ifrangeF_body5: "(##M)(A) \ (##M)(G) \ (##M)(r) \ (##M)(s) \ separation(##M, is_ifrangeF_body5(##M,A,G,r,s))" using separation_in_ctm[where \="is_ifrangeF_body5_fm(1,2,3,4,0)" and env="[A,G,r,s]"] zero_in_M arity_is_ifrangeF_body5_fm ord_simp_union is_ifrangeF_body5_fm_type by simp lemma (in M_basic) is_ifrFb_body5_closed: "M(G) \ M(r) \ M(s) \ is_ifrFb_body5(M, G, r, s, x, i) \ M(i)" using If_abs unfolding ifrangeF_body5_def is_ifrangeF_body5_def is_ifrFb_body5_def fun_apply_def by (cases "i\range(s)"; cases "r=0"; auto dest:transM) lemma (in M_ZF1_trans) ifrangeF_body5_abs: assumes "(##M)(A)" "(##M)(G)" "(##M)(r)" "(##M)(s)" "(##M)(x)" shows "is_ifrangeF_body5(##M,A,G,r,s,x) \ ifrangeF_body5(##M,A,G,r,s,x)" proof - { fix a assume "a\M" with assms have "(\ i. i\ M \ is_ifrFb_body5(##M, G, r, s, z, i))= (\ i. is_ifrFb_body5(##M, G, r, s, z, i))" for z using is_ifrFb_body5_closed[of G r s z] by (rule_tac Least_cong[of "\i. i\M \ is_ifrFb_body5(##M,G,r,s,z,i)"]) auto moreover have "(\ i. is_ifrFb_body5(##M, G, r, s, z, i))= (\ i. ifrFb_body5(G, r, s, z, i))" if "z\M" for z proof (rule_tac Least_cong[of "\i. is_ifrFb_body5(##M,G,r,s,z,i)" "\i. ifrFb_body5(G,r,s,z,i)"]) fix y from assms \a\M\ \z\M\ show "is_ifrFb_body5(##M, G, r, s, z, y) \ ifrFb_body5(G, r, s, z, y)" using If_abs apply_0 separation_in_constant separation_in_rev unfolding ifrFb_body5_def is_ifrFb_body5_def apply (cases "y\M"; cases "y\range(s)"; cases "r=0"; cases "y\domain(G)"; auto dest:transM split del: split_if del:iffI) apply (auto simp flip:setclass_iff; (force simp only: fun_apply_def setclass_iff)) apply (auto simp flip:setclass_iff simp: fun_apply_def) apply (auto dest:transM) done qed moreover from \a\M\ have "least(##M, \i. i \ M \ is_ifrFb_body5(##M, G, r, s, z, i), a) \ a = (\ i. i\ M \ is_ifrFb_body5(##M, G, r, s, z,i))" for z using If_abs least_abs'[of "\i. (##M)(i) \ is_ifrFb_body5(##M,G,r,s,z,i)" a] by simp ultimately have "z\M \ least(##M, \i. i \ M \ is_ifrFb_body5(##M, G, r, s, z, i), a) \ a = (\ i. ifrFb_body5(G, r, s, z,i))" for z by simp } with assms show ?thesis using pair_in_M_iff apply_closed zero_in_M transitivity[of _ A] unfolding ifrangeF_body5_def is_ifrangeF_body5_def by (auto dest:transM) qed lemma (in M_ZF1_trans) separation_ifrangeF_body5: "(##M)(A) \ (##M)(G) \ (##M)(b) \ (##M)(f) \ separation(##M, \y. \x\A. y = \x, \ i. x \ if_range_F_else_F(\x. {xa \ G . x \ xa}, b, f, i)\)" using separation_is_ifrangeF_body5 ifrangeF_body5_abs separation_cong[where P="is_ifrangeF_body5(##M,A,G,b,f)" and M="##M",THEN iffD1] unfolding ifrangeF_body5_def if_range_F_def if_range_F_else_F_def ifrFb_body5_def by simp (* (##M)(A) \ (##M)(b) \ (##M)(f) \ separation(##M, \y. \x\A'. y = \x, \ i. x \ if_range_F_else_F(\a. {p \ A . domain(p) = a}, b, f, i)\) *) definition ifrFb_body6 where "ifrFb_body6(G,b,f,x,i) \ x \ (if b = 0 then if i \ range(f) then {p\G . domain(p) = converse(f) ` i} else 0 else {p\G . domain(p) = i})" relativize functional "ifrFb_body6" "ifrFb_body6_rel" relationalize "ifrFb_body6_rel" "is_ifrFb_body6" synthesize "is_ifrFb_body6" from_definition assuming "nonempty" arity_theorem for "is_ifrFb_body6_fm" definition ifrangeF_body6 :: "[i\o,i,i,i,i,i] \ o" where "ifrangeF_body6(M,A,G,b,f) \ \y. \x\A. y = \x,\ i. ifrFb_body6(G,b,f,x,i)\" relativize functional "ifrangeF_body6" "ifrangeF_body6_rel" relationalize "ifrangeF_body6_rel" "is_ifrangeF_body6" synthesize "is_ifrangeF_body6" from_definition assuming "nonempty" arity_theorem for "is_ifrangeF_body6_fm" lemma (in M_Z_trans) separation_is_ifrangeF_body6: "(##M)(A) \ (##M)(G) \ (##M)(r) \ (##M)(s) \ separation(##M, is_ifrangeF_body6(##M,A,G,r,s))" using separation_in_ctm[where \="is_ifrangeF_body6_fm(1,2,3,4,0)" and env="[A,G,r,s]"] zero_in_M arity_is_ifrangeF_body6_fm ord_simp_union is_ifrangeF_body6_fm_type by simp lemma (in M_basic) ifrFb_body6_closed: "M(G) \ M(r) \ M(s) \ ifrFb_body6(G, r, s, x, i) \ M(i) \ ifrFb_body6(G, r, s, x, i)" using If_abs unfolding ifrangeF_body6_def is_ifrangeF_body6_def ifrFb_body6_def fun_apply_def by (cases "i\range(s)"; cases "r=0"; auto dest:transM) lemma (in M_basic) is_ifrFb_body6_closed: "M(G) \ M(r) \ M(s) \ is_ifrFb_body6(M, G, r, s, x, i) \ M(i)" using If_abs unfolding ifrangeF_body6_def is_ifrangeF_body6_def is_ifrFb_body6_def fun_apply_def by (cases "i\range(s)"; cases "r=0"; auto dest:transM) -lemma (in M_ZF2_trans) ifrangeF_body6_abs: +lemma (in M_ZF1_trans) ifrangeF_body6_abs: assumes "(##M)(A)" "(##M)(G)" "(##M)(r)" "(##M)(s)" "(##M)(x)" shows "is_ifrangeF_body6(##M,A,G,r,s,x) \ ifrangeF_body6(##M,A,G,r,s,x)" proof - { fix a assume "a\M" with assms have "(\ i. i\ M \ is_ifrFb_body6(##M, G, r, s, z, i))= (\ i. is_ifrFb_body6(##M, G, r, s, z, i))" for z using is_ifrFb_body6_closed[of G r s z] by (rule_tac Least_cong[of "\i. i\M \ is_ifrFb_body6(##M,G,r,s,z,i)"]) auto moreover have "(\ i. i\M \ is_ifrFb_body6(##M, G, r, s, z, i))= (\ i. i\M \ ifrFb_body6(G, r, s, z, i))" if "z\M" for z proof (rule_tac Least_cong[of "\i. i\M \ is_ifrFb_body6(##M,G,r,s,z,i)" "\i. i\M \ ifrFb_body6(G,r,s,z,i)"]) fix y from assms \a\M\ \z\M\ show "y\M \ is_ifrFb_body6(##M, G, r, s, z, y) \ y\M \ ifrFb_body6(G, r, s, z, y)" using If_abs apply_0 separation_in_constant transitivity[of _ G] separation_closed converse_closed apply_closed range_closed zero_in_M separation_cong[OF eq_commute,THEN iffD1,OF domain_eq_separation] unfolding ifrFb_body6_def is_ifrFb_body6_def by auto qed moreover from \a\M\ have "least(##M, \i. i \ M \ is_ifrFb_body6(##M, G, r, s, z, i), a) \ a = (\ i. i\ M \ is_ifrFb_body6(##M, G, r, s, z,i))" for z using If_abs least_abs'[of "\i. (##M)(i) \ is_ifrFb_body6(##M,G,r,s,z,i)" a] by simp ultimately have "z\M \ least(##M, \i. i \ M \ is_ifrFb_body6(##M, G, r, s, z, i), a) \ a = (\ i. ifrFb_body6(G, r, s, z,i))" for z using Least_cong[OF ifrFb_body6_closed[of G r s]] assms by simp } with assms show ?thesis using pair_in_M_iff apply_closed zero_in_M transitivity[of _ A] unfolding ifrangeF_body6_def is_ifrangeF_body6_def by (auto dest:transM) qed -lemma (in M_ZF2_trans) separation_ifrangeF_body6: +lemma (in M_ZF1_trans) separation_ifrangeF_body6: "(##M)(A) \ (##M)(G) \ (##M)(b) \ (##M)(f) \ separation(##M, \y. \x\A. y = \x, \ i. x \ if_range_F_else_F(\a. {p \ G . domain(p) = a}, b, f, i)\)" using separation_is_ifrangeF_body6 ifrangeF_body6_abs separation_cong[where P="is_ifrangeF_body6(##M,A,G,b,f)" and M="##M",THEN iffD1] unfolding ifrangeF_body6_def if_range_F_def if_range_F_else_F_def ifrFb_body6_def by simp (* (##M)(A) \ (##M)(f) \ (##M)(b) \ (##M)(D) \ (##M)(r') \ (##M)(A') \ separation(##M, \y. \x\A'. y = \x, \ i. x \ if_range_F_else_F(drSR_Y(r', D, A), b, f, i)\) *) definition ifrFb_body7 where "ifrFb_body7(B,D,A,b,f,x,i) \ x \ (if b = 0 then if i \ range(f) then {d \ D . \r\A. restrict(r, B) = converse(f) ` i \ d = domain(r)} else 0 else {d \ D . \r\A. restrict(r, B) = i \ d = domain(r)})" relativize functional "ifrFb_body7" "ifrFb_body7_rel" relationalize "ifrFb_body7_rel" "is_ifrFb_body7" synthesize "is_ifrFb_body7" from_definition assuming "nonempty" arity_theorem for "is_ifrFb_body7_fm" definition ifrangeF_body7 :: "[i\o,i,i,i,i,i,i,i] \ o" where "ifrangeF_body7(M,A,B,D,G,b,f) \ \y. \x\A. y = \x,\ i. ifrFb_body7(B,D,G,b,f,x,i)\" relativize functional "ifrangeF_body7" "ifrangeF_body7_rel" relationalize "ifrangeF_body7_rel" "is_ifrangeF_body7" synthesize "is_ifrangeF_body7" from_definition assuming "nonempty" arity_theorem for "is_ifrangeF_body7_fm" lemma (in M_Z_trans) separation_is_ifrangeF_body7: "(##M)(A) \ (##M)(B) \ (##M)(D) \ (##M)(G) \ (##M)(r) \ (##M)(s) \ separation(##M, is_ifrangeF_body7(##M,A,B,D,G,r,s))" using separation_in_ctm[where \="is_ifrangeF_body7_fm(1,2,3,4,5,6,0)" and env="[A,B,D,G,r,s]"] zero_in_M arity_is_ifrangeF_body7_fm ord_simp_union is_ifrangeF_body7_fm_type by simp lemma (in M_basic) ifrFb_body7_closed: "M(B) \ M(D) \ M(G) \ M(r) \ M(s) \ ifrFb_body7(B,D,G, r, s, x, i) \ M(i) \ ifrFb_body7(B,D,G, r, s, x, i)" using If_abs unfolding ifrangeF_body7_def is_ifrangeF_body7_def ifrFb_body7_def fun_apply_def by (cases "i\range(s)"; cases "r=0"; auto dest:transM) lemma (in M_basic) is_ifrFb_body7_closed: "M(B) \ M(D) \ M(G) \ M(r) \ M(s) \ is_ifrFb_body7(M, B,D,G, r, s, x, i) \ M(i)" using If_abs unfolding ifrangeF_body7_def is_ifrangeF_body7_def is_ifrFb_body7_def fun_apply_def by (cases "i\range(s)"; cases "r=0"; auto dest:transM) -lemma (in M_ZF2_trans) ifrangeF_body7_abs: +lemma (in M_ZF1_trans) ifrangeF_body7_abs: assumes "(##M)(A)" "(##M)(B)" "(##M)(D)" "(##M)(G)" "(##M)(r)" "(##M)(s)" "(##M)(x)" shows "is_ifrangeF_body7(##M,A,B,D,G,r,s,x) \ ifrangeF_body7(##M,A,B,D,G,r,s,x)" proof - from assms have sep_dr: "y\M \ separation(##M, \d . \r\M . r\G \ y = restrict(r, B) \ d = domain(r))" for y by(rule_tac separation_cong[where P'="\d . \r\ M . r\G \ y = restrict(r, B) \ d = domain(r)",THEN iffD1,OF _ separation_restrict_eq_dom_eq[rule_format,of G B y]],auto simp:transitivity[of _ G]) from assms have sep_dr'': "y\M \ separation(##M, \d . \r\M. r \ G \ d = domain(r) \ converse(s) ` y = restrict(r, B))" for y by(rule_tac separation_cong[THEN iffD1,OF _ separation_restrict_eq_dom_eq[rule_format,of G B "converse(s) ` y "]], auto simp:transitivity[of _ G] apply_closed[simplified] converse_closed[simplified]) { fix a assume "a\M" with assms have "(\ i. i\ M \ is_ifrFb_body7(##M, B,D,G, r, s, z, i))= (\ i. is_ifrFb_body7(##M,B,D, G, r, s, z, i))" for z using is_ifrFb_body7_closed[of B D G r s z] by (rule_tac Least_cong[of "\i. i\M \ is_ifrFb_body7(##M,B,D,G,r,s,z,i)"]) auto moreover from this have "(\ i. i\M \ is_ifrFb_body7(##M, B,D,G, r, s, z, i))= (\ i. i\M \ ifrFb_body7(B,D,G, r, s, z, i))" if "z\M" for z proof (rule_tac Least_cong[of "\i. i\M \ is_ifrFb_body7(##M,B,D,G,r,s,z,i)" "\i. i\M \ ifrFb_body7(B,D,G,r,s,z,i)"]) from assms \a\M\ \z\M\ have "is_ifrFb_body7(##M, B,D,G, r, s, z, y) \ ifrFb_body7(B,D,G, r, s, z, y)" if "y\M" for y using If_abs apply_0 separation_closed converse_closed apply_closed range_closed zero_in_M transitivity[of _ D] transitivity[of _ G] that sep_dr sep_dr'' unfolding ifrFb_body7_def is_ifrFb_body7_def by auto then show " y \ M \ is_ifrFb_body7(##M, B, D, G, r, s, z, y) \ y \ M \ ifrFb_body7(B, D, G, r, s, z, y)" for y using conj_cong by simp qed moreover from \a\M\ have "least(##M, \i. i \ M \ is_ifrFb_body7(##M, B,D,G, r, s, z, i), a) \ a = (\ i. i\ M \ is_ifrFb_body7(##M,B,D,G, r, s, z,i))" for z using If_abs least_abs'[of "\i. (##M)(i) \ is_ifrFb_body7(##M,B,D,G,r,s,z,i)" a] by simp ultimately have "z\M \ least(##M, \i. i \ M \ is_ifrFb_body7(##M,B,D,G, r, s, z, i), a) \ a = (\ i. ifrFb_body7(B,D,G, r, s, z,i))" for z using Least_cong[OF ifrFb_body7_closed[of B D G r s]] assms by simp } with assms show ?thesis using pair_in_M_iff apply_closed zero_in_M transitivity[of _ A] unfolding ifrangeF_body7_def is_ifrangeF_body7_def by (auto dest:transM) qed -lemma (in M_ZF2_trans) separation_ifrangeF_body7: +lemma (in M_ZF1_trans) separation_ifrangeF_body7: "(##M)(A) \ (##M)(B) \ (##M)(D) \ (##M)(G) \ (##M)(b) \ (##M)(f) \ separation(##M, \y. \x\A. y = \x, \ i. x \ if_range_F_else_F(drSR_Y(B, D, G), b, f, i)\)" using separation_is_ifrangeF_body7 ifrangeF_body7_abs drSR_Y_equality separation_cong[where P="is_ifrangeF_body7(##M,A,B,D,G,b,f)" and M="##M",THEN iffD1] unfolding ifrangeF_body7_def if_range_F_def if_range_F_else_F_def ifrFb_body7_def by simp definition omfunspace :: "[i,i] \ o" where "omfunspace(B) \ \z. \x. \n\\. z\x \ x = n\B" relativize functional "omfunspace" "omfunspace_rel" relationalize "omfunspace_rel" "is_omfunspace" synthesize "is_omfunspace" from_definition assuming "nonempty" arity_theorem for "is_omfunspace_fm" context M_pre_seqspace begin is_iff_rel for "omfunspace" using is_function_space_iff unfolding omfunspace_rel_def is_omfunspace_def by (simp add:absolut) end \ \\<^locale>\M_pre_seqspace\\ -context M_ZF2_trans +context M_ZF1_trans begin lemma separation_omfunspace: assumes "(##M)(B)" shows "separation(##M, \z. \x[##M]. \n[##M]. n \ \ \ z \ x \ x = n \\<^bsup>M\<^esup> B)" using assms separation_in_ctm[where env="[B]" and \="is_omfunspace_fm(1,0)" and Q="is_omfunspace(##M,B)"] nonempty is_omfunspace_iff[of B, THEN separation_cong, of "##M"] arity_is_omfunspace_fm is_omfunspace_fm_type unfolding omfunspace_rel_def by (auto simp add:ord_simp_union) -end \ \\<^locale>\M_ZF2_trans\\ +end \ \\<^locale>\M_ZF1_trans\\ -sublocale M_ZF2_trans \ M_seqspace "##M" +sublocale M_ZF1_trans \ M_seqspace "##M" using separation_omfunspace by unfold_locales definition cdltgamma :: "[i,i] \ o" where "cdltgamma(\) \ \Z . |Z| < \" relativize functional "cdltgamma" "cdltgamma_rel" relationalize "cdltgamma_rel" "is_cdltgamma" synthesize "is_cdltgamma" from_definition assuming "nonempty" arity_theorem for "is_cdltgamma_fm" definition cdeqgamma :: "[i] \ o" where "cdeqgamma \ \Z . |fst(Z)| = snd(Z)" relativize functional "cdeqgamma" "cdeqgamma_rel" relationalize "cdeqgamma_rel" "is_cdeqgamma" synthesize "is_cdeqgamma" from_definition assuming "nonempty" arity_theorem for "is_cdeqgamma_fm" context M_Perm begin is_iff_rel for "cdltgamma" using is_cardinal_iff unfolding cdltgamma_rel_def is_cdltgamma_def by (simp add:absolut) is_iff_rel for "cdeqgamma" using is_cardinal_iff fst_rel_abs snd_rel_abs unfolding cdeqgamma_rel_def is_cdeqgamma_def by (auto simp add:absolut) lemma is_cdeqgamma_iff_split: "M(Z) \ cdeqgamma_rel(M, Z) \ (\\x,y\. |x|\<^bsup>M\<^esup> = y)(Z)" using fst_rel_abs snd_rel_abs unfolding cdeqgamma_rel_def split_def by simp end -context M_ZF2_trans +context M_ZF1_trans begin lemma separation_cdltgamma: assumes "(##M)(\)" shows "separation(##M, \Z . cardinal_rel(##M,Z) < \)" using assms separation_in_ctm[where env="[\]" and \="is_cdltgamma_fm(1,0)" and Q="cdltgamma_rel(##M,\)"] nonempty is_cdltgamma_iff[of \] arity_is_cdltgamma_fm is_cdltgamma_fm_type unfolding cdltgamma_rel_def by (auto simp add:ord_simp_union) lemma separation_cdeqgamma: shows "separation(##M, \Z. (\\x,y\ . cardinal_rel(##M,x) = y)(Z))" using separation_in_ctm[where env="[]" and \="is_cdeqgamma_fm(0)" and Q="cdeqgamma_rel(##M)"] is_cdeqgamma_iff_split nonempty is_cdeqgamma_iff arity_is_cdeqgamma_fm is_cdeqgamma_fm_type separation_cong[OF is_cdeqgamma_iff_split, of "##M"] unfolding cdeqgamma_rel_def by (simp add:ord_simp_union) -end \ \\<^locale>\M_ZF2_trans\\ +end \ \\<^locale>\M_ZF1_trans\\ end \ No newline at end of file diff --git a/thys/Independence_CH/Succession_Poset.thy b/thys/Independence_CH/Succession_Poset.thy --- a/thys/Independence_CH/Succession_Poset.thy +++ b/thys/Independence_CH/Succession_Poset.thy @@ -1,230 +1,230 @@ section\A poset of successions\ theory Succession_Poset imports ZF_Trans_Interpretations Proper_Extension begin text\In this theory we define a separative poset. Its underlying set is the set of finite binary sequences (that is, with codomain $2={0,1}$); of course, one can see that set as the set \<^term>\\-||>2\ or equivalently as the set of partial functions \<^term>\Fn(\,\,2)\, i.e. the set of partial functions bounded by \<^term>\\\. The order relation of the poset is that of being less defined as functions (cf. \<^term>\Fnlerel(A\<^bsup><\\<^esup>)\), so it could be surprising that we have not used \<^term>\Fn(\,\,2)\ for the set. The only reason why we keep this alternative definition is because we can prove \<^term>\A\<^bsup><\\<^esup> \ M\ (and therefore \<^term>\Fnlerel(A\<^bsup><\\<^esup>) \ M\) using only one instance of separation.\ definition seq_upd :: "i \ i \ i" where "seq_upd(f,a) \ \ j \ succ(domain(f)) . if j < domain(f) then f`j else a" lemma seq_upd_succ_type : assumes "n\nat" "f\n\A" "a\A" shows "seq_upd(f,a)\ succ(n) \ A" proof - from assms have equ: "domain(f) = n" using domain_of_fun by simp { fix j assume "j\succ(domain(f))" with equ \n\_\ have "j\n" using ltI by auto with \n\_\ consider (lt) "j A" proof cases case lt with \f\_\ show ?thesis using apply_type ltD[OF lt] by simp next case eq with \a\_\ show ?thesis by auto qed } with equ show ?thesis unfolding seq_upd_def using lam_type[of "succ(domain(f))"] by auto qed lemma seq_upd_type : assumes "f\A\<^bsup><\\<^esup>" "a\A" shows "seq_upd(f,a) \ A\<^bsup><\\<^esup>" proof - from \f\_\ obtain y where "y\nat" "f\y\A" unfolding seqspace_def by blast with \a\A\ have "seq_upd(f,a)\succ(y)\A" using seq_upd_succ_type by simp with \y\_\ show ?thesis unfolding seqspace_def by auto qed lemma seq_upd_apply_domain [simp]: assumes "f:n\A" "n\nat" shows "seq_upd(f,a)`n = a" unfolding seq_upd_def using assms domain_of_fun by auto lemma zero_in_seqspace : shows "0 \ A\<^bsup><\\<^esup>" unfolding seqspace_def by force definition seqlerel :: "i \ i" where "seqlerel(A) \ Fnlerel(A\<^bsup><\\<^esup>)" definition seqle :: "i" where "seqle \ seqlerel(2)" lemma seqleI[intro!]: "\f,g\ \ 2\<^bsup><\\<^esup>\2\<^bsup><\\<^esup> \ g \ f \ \f,g\ \ seqle" unfolding seqle_def seqlerel_def seqspace_def Rrel_def Fnlerel_def by blast lemma seqleD[dest!]: "z \ seqle \ \x y. \x,y\ \ 2\<^bsup><\\<^esup>\2\<^bsup><\\<^esup> \ y \ x \ z = \x,y\" unfolding Rrel_def seqle_def seqlerel_def Fnlerel_def by blast lemma upd_leI : assumes "f\2\<^bsup><\\<^esup>" "a\2" shows "\seq_upd(f,a),f\\seqle" (is "\?f,_\\_") proof show " \?f, f\ \ 2\<^bsup><\\<^esup> \ 2\<^bsup><\\<^esup>" using assms seq_upd_type by auto next show "f \ seq_upd(f,a)" proof fix x assume "x \ f" moreover from \f \ 2\<^bsup><\\<^esup>\ obtain n where "n\nat" "f : n \ 2" by blast moreover from calculation obtain y where "y\n" "x=\y,f`y\" using Pi_memberD[of f n "\_ . 2"] by blast moreover from \f:n\2\ have "domain(f) = n" using domain_of_fun by simp ultimately show "x \ seq_upd(f,a)" unfolding seq_upd_def lam_def by (auto intro:ltI) qed qed lemma preorder_on_seqle: "preorder_on(2\<^bsup><\\<^esup>,seqle)" unfolding preorder_on_def refl_def trans_on_def by blast lemma zero_seqle_max: "x\2\<^bsup><\\<^esup> \ \x,0\ \ seqle" using zero_in_seqspace by auto interpretation sp:forcing_notion "2\<^bsup><\\<^esup>" "seqle" "0" using preorder_on_seqle zero_seqle_max zero_in_seqspace by unfold_locales simp_all notation sp.Leq (infixl "\s" 50) notation sp.Incompatible (infixl "\s" 50) lemma seqspace_separative: assumes "f\2\<^bsup><\\<^esup>" shows "seq_upd(f,0) \s seq_upd(f,1)" (is "?f \s ?g") proof assume "sp.compat(?f, ?g)" then obtain h where "h \ 2\<^bsup><\\<^esup>" "?f \ h" "?g \ h" by blast moreover from \f\_\ obtain y where "y\nat" "f:y\2" by blast moreover from this have "?f: succ(y) \ 2" "?g: succ(y) \ 2" using seq_upd_succ_type by blast+ moreover from this have "\y,?f`y\ \ ?f" "\y,?g`y\ \ ?g" using apply_Pair by auto ultimately have "\y,0\ \ h" "\y,1\ \ h" by auto moreover from \h \ 2\<^bsup><\\<^esup>\ obtain n where "n\nat" "h:n\2" by blast ultimately show "False" using fun_is_function[of h n "\_. 2"] unfolding seqspace_def function_def by auto qed definition seqleR_fm :: "i \ i" where "seqleR_fm(fg) \ Exists(Exists(And(pair_fm(0,1,fg+\<^sub>\2),subset_fm(1,0))))" lemma type_seqleR_fm : "fg \ nat \ seqleR_fm(fg) \ formula" unfolding seqleR_fm_def by simp arity_theorem for "seqleR_fm" lemma (in M_ctm1) seqleR_fm_sats : assumes "fg\nat" "env\list(M)" shows "(M, env \ seqleR_fm(fg)) \ (\f[##M]. \g[##M]. pair(##M,f,g,nth(fg,env)) \ f \ g)" unfolding seqleR_fm_def using assms trans_M sats_subset_fm pair_iff_sats by auto -context M_ctm2 +context M_ctm1 begin lemma seqle_in_M: "seqle \ M" using arity_seqleR_fm seqleR_fm_sats type_seqleR_fm cartprod_closed seqspace_closed nat_into_M nat_in_M pair_in_M_iff unfolding seqle_def seqlerel_def Rrel_def Fnlerel_def by (rule_tac Collect_in_M[of "seqleR_fm(0)" "[]"],auto) subsection\Cohen extension is proper\ interpretation ctm_separative "2\<^bsup><\\<^esup>" seqle 0 proof (unfold_locales) fix f let ?q="seq_upd(f,0)" and ?r="seq_upd(f,1)" assume "f \ 2\<^bsup><\\<^esup>" then have "?q \s f \ ?r \s f \ ?q \s ?r" using upd_leI seqspace_separative by auto moreover from calculation have "?q \ 2\<^bsup><\\<^esup>" "?r \ 2\<^bsup><\\<^esup>" using seq_upd_type[of f 2] by auto ultimately show "\q\2\<^bsup><\\<^esup>. \r\2\<^bsup><\\<^esup>. q \s f \ r \s f \ q \s r" by (rule_tac bexI)+ \ \why the heck auto-tools don't solve this?\ next show "2\<^bsup><\\<^esup> \ M" using nat_into_M seqspace_closed by simp next show "seqle \ M" using seqle_in_M . qed lemma cohen_extension_is_proper: "\G. M_generic(G) \ M \ M[G]" using proper_extension generic_filter_existence zero_in_seqspace by force -end \ \\<^locale>\M_ctm2\\ +end \ \\<^locale>\M_ctm1\\ end \ No newline at end of file diff --git a/thys/Independence_CH/ZF_Trans_Interpretations.thy b/thys/Independence_CH/ZF_Trans_Interpretations.thy --- a/thys/Independence_CH/ZF_Trans_Interpretations.thy +++ b/thys/Independence_CH/ZF_Trans_Interpretations.thy @@ -1,647 +1,687 @@ section\Further instances of axiom-schemes\ theory ZF_Trans_Interpretations imports Internal_ZFC_Axioms Replacement_Instances begin -locale M_ZF3 = M_ZF2 + +locale M_ZF2 = M_ZF1 + assumes - replacement_ax3: + replacement_ax2: "replacement_assm(M,env,replacement_is_order_body_fm)" "replacement_assm(M,env,wfrec_replacement_order_pred_fm)" - -definition instances3_fms where "instances3_fms \ - { replacement_is_order_body_fm, - wfrec_replacement_order_pred_fm }" - -lemmas replacement_instances3_defs = - replacement_is_order_body_fm_def wfrec_replacement_order_pred_fm_def - replacement_is_aleph_fm_def - -declare (in M_ZF3) replacement_instances3_defs [simp] - -locale M_ZF3_trans = M_ZF2_trans + M_ZF3 - -locale M_ZFC3 = M_ZFC2 + M_ZF3 - -locale M_ZFC3_trans = M_ZFC2_trans + M_ZF3_trans + "replacement_assm(M,env,replacement_HAleph_wfrec_repl_body_fm)" + "replacement_assm(M,env,replacement_is_order_eq_map_fm)" -locale M_ZF3_ground_notCH = M_ZF3 + M_ZF_ground_notCH - -locale M_ZF3_ground_notCH_trans = M_ZF3_trans + M_ZF3_ground_notCH + M_ZF_ground_notCH_trans - -locale M_ZFC3_ground_notCH = M_ZFC3 + M_ZF3_ground_notCH - -locale M_ZFC3_ground_notCH_trans = M_ZFC3_trans + M_ZFC3_ground_notCH + M_ZF3_ground_notCH_trans +definition instances2_fms where "instances2_fms \ + { replacement_is_order_body_fm, + wfrec_replacement_order_pred_fm, + replacement_HAleph_wfrec_repl_body_fm, + replacement_is_order_eq_map_fm }" -locale M_ZFC3_ground_CH_trans = M_ZFC3_ground_notCH_trans + M_ZF_ground_CH_trans - -locale M_ctm3 = M_ctm2 + M_ZF3_ground_notCH_trans +lemmas replacement_instances2_defs = + replacement_is_order_body_fm_def wfrec_replacement_order_pred_fm_def + replacement_HAleph_wfrec_repl_body_fm_def replacement_is_order_eq_map_fm_def -locale M_ctm3_AC = M_ctm3 + M_ctm1_AC + M_ZFC3_ground_notCH_trans +declare (in M_ZF2) replacement_instances2_defs [simp] -locale M_ctm3_AC_CH = M_ctm3_AC + M_ZFC3_ground_CH_trans +locale M_ZF2_trans = M_ZF1_trans + M_ZF2 -lemmas (in M_ZF2_trans) separation_instances = +locale M_ZFC2 = M_ZFC1 + M_ZF2 + +locale M_ZFC2_trans = M_ZFC1_trans + M_ZF2_trans + M_ZFC2 + +locale M_ZF2_ground_notCH = M_ZF2 + M_ZF_ground_notCH + +locale M_ZF2_ground_notCH_trans = M_ZF2_trans + M_ZF2_ground_notCH + M_ZF_ground_notCH_trans + +locale M_ZFC2_ground_notCH = M_ZFC2 + M_ZF2_ground_notCH + +locale M_ZFC2_ground_notCH_trans = M_ZFC2_trans + M_ZFC2_ground_notCH + M_ZF2_ground_notCH_trans + +locale M_ZFC2_ground_CH_trans = M_ZFC2_ground_notCH_trans + M_ZF_ground_CH_trans + +locale M_ctm2 = M_ctm1 + M_ZF2_ground_notCH_trans + +locale M_ctm2_AC = M_ctm2 + M_ctm1_AC + M_ZFC2_ground_notCH_trans + +locale M_ctm2_AC_CH = M_ctm2_AC + M_ZFC2_ground_CH_trans + +lemmas (in M_ZF1_trans) separation_instances = separation_well_ord_iso separation_obase_equals separation_is_obase separation_PiP_rel separation_surjP_rel separation_radd_body separation_rmult_body +context M_ZF2_trans +begin + +lemma replacement_HAleph_wfrec_repl_body: + "B\M \ strong_replacement(##M, HAleph_wfrec_repl_body(##M,B))" + using strong_replacement_rel_in_ctm[where \="HAleph_wfrec_repl_body_fm(2,0,1)" and env="[B]"] + zero_in_M arity_HAleph_wfrec_repl_body_fm replacement_ax2(3) ord_simp_union + by simp + +lemma HAleph_wfrec_repl: + "(##M)(sa) \ + (##M)(esa) \ + (##M)(mesa) \ + strong_replacement + (##M, + \x z. \y[##M]. + pair(##M, x, y, z) \ + (\f[##M]. + (\z[##M]. + z \ f \ + (\xa[##M]. + \y[##M]. + \xaa[##M]. + \sx[##M]. + \r_sx[##M]. + \f_r_sx[##M]. + pair(##M, xa, y, z) \ + pair(##M, xa, x, xaa) \ + upair(##M, xa, xa, sx) \ + pre_image(##M, mesa, sx, r_sx) \ restriction(##M, f, r_sx, f_r_sx) \ xaa \ mesa \ is_HAleph(##M, xa, f_r_sx, y))) \ + is_HAleph(##M, x, f, y)))" + using replacement_HAleph_wfrec_repl_body unfolding HAleph_wfrec_repl_body_def by simp + +lemma replacement_is_order_eq_map: + "A\M \ r\M \ strong_replacement(##M, order_eq_map(##M,A,r))" + using strong_replacement_rel_in_ctm[where \="order_eq_map_fm(2,3,0,1)" and env="[A,r]" and f="order_eq_map(##M,A,r)"] + order_eq_map_iff_sats[where env="[_,_,A,r]"] zero_in_M fst_snd_closed pair_in_M_iff + arity_order_eq_map_fm ord_simp_union replacement_ax2(4) + by simp + +end \ \\<^locale>\M_ZF2_trans\\ + definition omap_wfrec_body where "omap_wfrec_body(A,r) \ (\\\image_fm(2, 0, 1) \ pred_set_fm(A #+ 9, 3, r #+ 9, 0) \\)" lemma type_omap_wfrec_body_fm :"A\nat \ r\nat \ omap_wfrec_body(A,r)\formula" unfolding omap_wfrec_body_def by simp lemma arity_aux : "A\nat \ r\nat \ arity(omap_wfrec_body(A,r)) = (9+\<^sub>\A) \ (9+\<^sub>\r)" unfolding omap_wfrec_body_def using arity_image_fm arity_pred_set_fm pred_Un_distrib union_abs2[of 3] union_abs1 by (simp add:FOL_arities, auto simp add:Un_assoc[symmetric] union_abs1) lemma arity_omap_wfrec: "A\nat \ r\nat \ arity(is_wfrec_fm(omap_wfrec_body(A,r),succ(succ(succ(r))), 1, 0)) = (4+\<^sub>\A) \ (4+\<^sub>\r)" using Arities.arity_is_wfrec_fm[OF _ _ _ _ _ arity_aux,of A r "3+\<^sub>\r" 1 0] pred_Un_distrib union_abs1 union_abs2 type_omap_wfrec_body_fm by auto lemma arity_isordermap: "A\nat \ r\nat \d\nat\ arity(is_ordermap_fm(A,r,d)) = succ(d) \ (succ(A) \ succ(r))" unfolding is_ordermap_fm_def using arity_lambda_fm[where i="(4+\<^sub>\A) \ (4+\<^sub>\r)",OF _ _ _ _ arity_omap_wfrec, unfolded omap_wfrec_body_def] pred_Un_distrib union_abs1 by auto lemma arity_is_ordertype: "A\nat \ r\nat \d\nat\ arity(is_ordertype_fm(A,r,d)) = succ(d) \ (succ(A) \ succ(r))" unfolding is_ordertype_fm_def using arity_isordermap arity_image_fm pred_Un_distrib FOL_arities by auto lemma arity_is_order_body: "arity(is_order_body_fm(1,0)) = 2" using arity_is_order_body_fm arity_is_ordertype ord_simp_union by (simp add:FOL_arities) -lemma (in M_ZF3_trans) replacement_is_order_body: +lemma (in M_ZF2_trans) replacement_is_order_body: "strong_replacement(##M, \x z . \y[##M]. is_order_body(##M,x,y) \ z = \x,y\)" apply(rule_tac strong_replacement_cong[ where P="\ x f. M,[x,f] \ (\\ \is_order_body_fm(1,0) \ pair_fm(1,0,2) \\)",THEN iffD1]) apply(simp add: is_order_body_iff_sats[where env="[_,_]",symmetric]) apply(simp_all add:zero_in_M ) - apply(rule_tac replacement_ax3(1)[unfolded replacement_assm_def, rule_format, where env="[]",simplified]) + apply(rule_tac replacement_ax2(1)[unfolded replacement_assm_def, rule_format, where env="[]",simplified]) apply(simp_all add:arity_is_order_body arity pred_Un_distrib ord_simp_union) done definition H_order_pred where "H_order_pred(A,r) \ \x f . f `` Order.pred(A, x, r)" relationalize "H_order_pred" "is_H_order_pred" lemma (in M_basic) H_order_pred_abs : "M(A) \ M(r) \ M(x) \ M(f) \ M(z) \ is_H_order_pred(M,A,r,x,f,z) \ z = H_order_pred(A,r,x,f)" unfolding is_H_order_pred_def H_order_pred_def by simp synthesize "is_H_order_pred" from_definition assuming "nonempty" -lemma (in M_ZF3_trans) wfrec_replacement_order_pred: +lemma (in M_ZF2_trans) wfrec_replacement_order_pred: "A\M \ r\M \ wfrec_replacement(##M, \x g z. is_H_order_pred(##M,A,r,x,g,z) , r)" unfolding wfrec_replacement_def is_wfrec_def M_is_recfun_def is_H_order_pred_def apply(rule_tac strong_replacement_cong[ where P="\ x f. M,[x,f,r,A] \ order_pred_wfrec_body_fm(3,2,1,0)",THEN iffD1]) apply(subst order_pred_wfrec_body_def[symmetric]) apply(rule_tac order_pred_wfrec_body_iff_sats[where env="[_,_,r,A]",symmetric]) apply(simp_all add:zero_in_M) - apply(rule_tac replacement_ax3(2)[unfolded replacement_assm_def, rule_format, where env="[r,A]",simplified]) + apply(rule_tac replacement_ax2(2)[unfolded replacement_assm_def, rule_format, where env="[r,A]",simplified]) apply(simp_all add: arity_order_pred_wfrec_body_fm ord_simp_union) done -lemma (in M_ZF3_trans) wfrec_replacement_order_pred': +lemma (in M_ZF2_trans) wfrec_replacement_order_pred': "A\M \ r\M \ wfrec_replacement(##M, \x g z. z = H_order_pred(A,r,x,g) , r)" using wfrec_replacement_cong[OF H_order_pred_abs[of A r,rule_format] refl,THEN iffD1, OF _ _ _ _ _ wfrec_replacement_order_pred[of A r]] by simp -sublocale M_ZF3_trans \ M_pre_cardinal_arith "##M" +sublocale M_ZF2_trans \ M_pre_cardinal_arith "##M" using separation_instances wfrec_replacement_order_pred'[unfolded H_order_pred_def] replacement_is_order_eq_map[unfolded order_eq_map_def] by unfold_locales simp_all definition is_well_ord_fst_snd where "is_well_ord_fst_snd(A,x) \ (\a[A]. \b[A]. is_well_ord(A,a,b) \ is_snd(A, x, b) \ is_fst(A, x, a))" synthesize "is_well_ord_fst_snd" from_definition assuming "nonempty" arity_theorem for "is_well_ord_fst_snd_fm" -lemma (in M_ZF3_trans) separation_well_ord: "separation(##M, \x. is_well_ord(##M,fst(x), snd(x)))" +lemma (in M_ZF2_trans) separation_well_ord: "separation(##M, \x. is_well_ord(##M,fst(x), snd(x)))" using arity_is_well_ord_fst_snd_fm is_well_ord_iff_sats[symmetric] nonempty fst_closed snd_closed fst_abs snd_abs separation_in_ctm[where env="[]" and \="is_well_ord_fst_snd_fm(0)"] by(simp_all add: is_well_ord_fst_snd_def) -sublocale M_ZF3_trans \ M_pre_aleph "##M" +sublocale M_ZF2_trans \ M_pre_aleph "##M" using HAleph_wfrec_repl replacement_is_order_body separation_well_ord separation_Pow_rel by unfold_locales (simp_all add: transrec_replacement_def wfrec_replacement_def is_wfrec_def M_is_recfun_def flip:setclass_iff) arity_theorem intermediate for "is_HAleph_fm" lemma arity_is_HAleph_fm: "arity(is_HAleph_fm(2, 1, 0)) = 3" using arity_fun_apply_fm[of "11" 0 1,simplified] arity_is_HAleph_fm' arity_ordinal_fm arity_is_If_fm arity_empty_fm arity_is_Limit_fm arity_is_If_fm arity_is_Limit_fm arity_empty_fm arity_Replace_fm[where i="12" and v=10 and n=3] pred_Un_distrib ord_simp_union by (simp add:FOL_arities) lemma arity_is_Aleph[arity]: "arity(is_Aleph_fm(0, 1)) = 2" unfolding is_Aleph_fm_def using arity_transrec_fm[OF _ _ _ _ arity_is_HAleph_fm] ord_simp_union by simp definition bex_Aleph_rel :: "[i\o,i,i] \ o" where "bex_Aleph_rel(M,x) \ \y. \z\x. y = \\<^bsub>z\<^esub>\<^bsup>M\<^esup>" relationalize "bex_Aleph_rel" "is_bex_Aleph" schematic_goal sats_is_bex_Aleph_fm_auto: "a \ nat \ c \ nat \ env \ list(A) \ a < length(env) \ c < length(env) \ 0 \ A \ is_bex_Aleph(##A, nth(a, env), nth(c, env)) \ A, env \ ?fm(a, c)" unfolding is_bex_Aleph_def by (rule iff_sats | simp)+ synthesize_notc "is_bex_Aleph" from_schematic lemma is_bex_Aleph_fm_type [TC]: "x \ \ \ z \ \ \ is_bex_Aleph_fm(x, z) \ formula" unfolding is_bex_Aleph_fm_def by simp lemma sats_is_bex_Aleph_fm: "x \ \ \ z \ \ \ x < length(env) \ z < length(env) \ env \ list(Aa) \ 0 \ Aa \ (Aa, env \ is_bex_Aleph_fm(x, z)) \ is_bex_Aleph(##Aa,nth(x, env), nth(z, env))" using sats_is_bex_Aleph_fm_auto unfolding is_bex_Aleph_def is_bex_Aleph_fm_def by simp lemma is_bex_Aleph_iff_sats [iff_sats]: "nth(x, env) = xa \ nth(z, env) = za \ x \ \ \ z \ \ \ x < length(env) \ z < length(env) \ env \ list(Aa) \ 0 \ Aa \ is_bex_Aleph(##Aa, xa, za) \ Aa, env \ is_bex_Aleph_fm(x, z)" using sats_is_bex_Aleph_fm by simp arity_theorem for "is_bex_Aleph_fm" lemma (in M_ZF1_trans) separation_is_bex_Aleph: assumes "(##M)(A)" shows "separation(##M,is_bex_Aleph(##M, A))" using assms separation_in_ctm[where env="[A]" and \="is_bex_Aleph_fm(1,0)", OF _ _ _ is_bex_Aleph_iff_sats[symmetric], of "\_.A"] nonempty arity_is_bex_Aleph_fm is_bex_Aleph_fm_type by (simp add:ord_simp_union) lemma (in M_pre_aleph) bex_Aleph_rel_abs: assumes "Ord(u)" "M(u)" "M(v)" shows "is_bex_Aleph(M, u, v) \ bex_Aleph_rel(M,u,v)" unfolding is_bex_Aleph_def bex_Aleph_rel_def using assms is_Aleph_iff transM[of _ u] Ord_in_Ord by simp -lemma (in M_ZF3_trans) separation_bex_Aleph_rel: +lemma (in M_ZF2_trans) separation_bex_Aleph_rel: "Ord(x) \ (##M)(x) \ separation(##M, bex_Aleph_rel(##M,x))" using separation_is_bex_Aleph bex_Aleph_rel_abs separation_cong[where P="is_bex_Aleph(##M,x)" and M="##M",THEN iffD1] unfolding bex_Aleph_rel_def by simp -sublocale M_ZF3_trans \ M_aleph "##M" +sublocale M_ZF2_trans \ M_aleph "##M" using separation_bex_Aleph_rel[unfolded bex_Aleph_rel_def] by unfold_locales -sublocale M_ZF2_trans \ M_FiniteFun "##M" +sublocale M_ZF1_trans \ M_FiniteFun "##M" using separation_is_function separation_omfunspace by unfold_locales simp -sublocale M_ZFC1_trans \ M_AC "##M" - using choice_ax by (unfold_locales, simp_all) - -sublocale M_ZFC3_trans \ M_cardinal_AC "##M" +sublocale M_ZFC2_trans \ M_cardinal_AC "##M" using lam_replacement_minimum by unfold_locales simp (* TopLevel *) -lemma (in M_ZF2_trans) separation_cardinal_rel_lesspoll_rel: +lemma (in M_ZF1_trans) separation_cardinal_rel_lesspoll_rel: "(##M)(\) \ separation(##M, \x. x \\<^bsup>M\<^esup> \)" using separation_in_ctm[where \="( \0 \ 1\ )" and env="[\]"] is_lesspoll_iff nonempty arity_is_cardinal_fm arity_is_lesspoll_fm arity_is_bij_fm ord_simp_union by (simp add:FOL_arities) -sublocale M_ZFC3_trans \ M_library "##M" +sublocale M_ZFC2_trans \ M_library "##M" using separation_cardinal_rel_lesspoll_rel lam_replacement_minimum by unfold_locales simp_all -locale M_ZF4 = M_ZF3 + +locale M_ZF3 = M_ZF2 + assumes - ground_replacements4: + ground_replacements3: "ground_replacement_assm(M,env,replacement_is_order_body_fm)" "ground_replacement_assm(M,env,wfrec_replacement_order_pred_fm)" "ground_replacement_assm(M,env,list_repl1_intf_fm)" "ground_replacement_assm(M,env,list_repl2_intf_fm)" "ground_replacement_assm(M,env,formula_repl2_intf_fm)" "ground_replacement_assm(M,env,eclose_repl2_intf_fm)" "ground_replacement_assm(M,env,wfrec_rank_fm)" "ground_replacement_assm(M,env,trans_repl_HVFrom_fm)" "ground_replacement_assm(M,env,tl_repl_intf_fm)" "ground_replacement_assm(M,env,formula_repl1_intf_fm)" "ground_replacement_assm(M,env,eclose_repl1_intf_fm)" "ground_replacement_assm(M,env,replacement_HAleph_wfrec_repl_body_fm)" "ground_replacement_assm(M,env,replacement_is_order_eq_map_fm)" -definition instances4_fms where "instances4_fms \ +definition instances3_fms where "instances3_fms \ { ground_repl_fm(replacement_is_order_body_fm), ground_repl_fm(wfrec_replacement_order_pred_fm), ground_repl_fm(list_repl1_intf_fm), ground_repl_fm(list_repl2_intf_fm), ground_repl_fm(formula_repl2_intf_fm), ground_repl_fm(eclose_repl2_intf_fm), ground_repl_fm(wfrec_rank_fm), ground_repl_fm(trans_repl_HVFrom_fm), ground_repl_fm(tl_repl_intf_fm), ground_repl_fm(formula_repl1_intf_fm), ground_repl_fm(eclose_repl1_intf_fm), ground_repl_fm(replacement_HAleph_wfrec_repl_body_fm), ground_repl_fm(replacement_is_order_eq_map_fm) }" text\This set has $13$ internalized formulas, corresponding to the total count of previous replacement instances (apart from those $5$ in \<^term>\instances_ground_fms\ and \<^term>\instances_ground_notCH_fms\, and \<^term>\replacement_dcwit_repl_body_fm\).\ definition overhead where - "overhead \ instances1_fms \ instances2_fms \ instances_ground_fms" + "overhead \ instances1_fms \ instances_ground_fms" definition overhead_notCH where - "overhead_notCH \ overhead \ instances3_fms \ - instances4_fms \ instances_ground_notCH_fms" + "overhead_notCH \ overhead \ instances2_fms \ + instances3_fms \ instances_ground_notCH_fms" definition overhead_CH where "overhead_CH \ overhead_notCH \ { replacement_dcwit_repl_body_fm }" text\Hence, the “overhead” to create a proper extension of a ctm by forcing consists of $16$ replacement instances. To force $\neg\CH$, 31 instances are need, and one further instance is required to force $\CH$.\ -lemma instances3_fms_type[TC] : "instances3_fms \ formula" - unfolding instances3_fms_def replacement_is_order_body_fm_def - wfrec_replacement_order_pred_fm_def replacement_is_aleph_fm_def +lemma instances2_fms_type[TC] : "instances2_fms \ formula" + unfolding instances2_fms_def replacement_instances2_defs by (auto simp del: Lambda_in_M_fm_def) lemma overhead_type: "overhead \ formula" - using instances1_fms_type instances2_fms_type instances_ground_fms_type - unfolding overhead_def replacement_instances1_defs replacement_instances2_defs + using instances1_fms_type instances_ground_fms_type + unfolding overhead_def replacement_instances1_defs by simp lemma overhead_notCH_type: "overhead_notCH \ formula" using overhead_type unfolding overhead_notCH_def replacement_transrec_apply_image_body_fm_def replacement_is_trans_apply_image_fm_def instances_ground_notCH_fms_def - instances3_fms_def instances4_fms_def - by (auto simp: replacement_instances1_defs replacement_instances2_defs - replacement_instances3_defs simp del: Lambda_in_M_fm_def) + instances2_fms_def instances3_fms_def + by (auto simp: replacement_instances1_defs + replacement_instances2_defs simp del: Lambda_in_M_fm_def) lemma overhead_CH_type: "overhead_CH \ formula" using overhead_notCH_type unfolding overhead_CH_def replacement_dcwit_repl_body_fm_def by auto -locale M_ZF4_trans = M_ZF3_trans + M_ZF4 - -locale M_ZFC4 = M_ZFC3 + M_ZF4 +locale M_ZF3_trans = M_ZF2_trans + M_ZF3 -locale M_ZFC4_trans = M_ZFC3_trans + M_ZF4_trans +locale M_ZFC3 = M_ZFC2 + M_ZF3 -locale M_ctm4 = M_ctm3 + M_ZF4_trans +locale M_ZFC3_trans = M_ZFC2_trans + M_ZF3_trans + M_ZFC3 -locale M_ctm4_AC = M_ctm4 + M_ctm1_AC + M_ZFC4_trans +locale M_ctm3 = M_ctm2 + M_ZF3_trans -lemma M_satT_imp_M_ZF2: "(M \ ZF) \ M_ZF2(M)" +locale M_ctm3_AC = M_ctm3 + M_ctm1_AC + M_ZFC3_trans + +lemma M_satT_imp_M_ZF2: "(M \ ZF) \ M_ZF1(M)" proof - assume "M \ ZF" then have fin: "upair_ax(##M)" "Union_ax(##M)" "power_ax(##M)" "extensionality(##M)" "foundation_ax(##M)" "infinity_ax(##M)" unfolding ZF_def ZF_fin_def ZFC_fm_defs satT_def using ZFC_fm_sats[of M] by simp_all { fix \ env assume "\ \ formula" "env\list(M)" moreover from \M \ ZF\ have "\p\formula. (M, [] \ (ZF_separation_fm(p)))" "\p\formula. (M, [] \ (ZF_replacement_fm(p)))" unfolding ZF_def ZF_schemes_def by auto moreover from calculation have "arity(\) \ succ(length(env)) \ separation(##M, \x. (M, Cons(x, env) \ \))" "arity(\) \ succ(succ(length(env))) \ strong_replacement(##M,\x y. sats(M,\,Cons(x,Cons(y, env))))" - using sats_ZF_separation_fm_iff sats_ZF_replacement_fm_iff by simp_all + using sats_ZF_separation_fm_iff sats_ZF_replacement_fm_iff + unfolding replacement_assm_def by simp_all } with fin - show "M_ZF2(M)" + show "M_ZF1(M)" by unfold_locales (simp_all add:replacement_assm_def ground_replacement_assm_def) qed -lemma M_satT_imp_M_ZFC2: - shows "(M \ ZFC) \ M_ZFC2(M)" +lemma M_satT_imp_M_ZFC1: + shows "(M \ ZFC) \ M_ZFC1(M)" proof - - have "(M \ ZF) \ choice_ax(##M) \ M_ZFC2(M)" + have "(M \ ZF) \ choice_ax(##M) \ M_ZFC1(M)" using M_satT_imp_M_ZF2[of M] - unfolding M_ZF2_def M_ZFC1_def M_ZFC2_def M_ZC_basic_def M_ZF1_def M_AC_def + unfolding M_ZFC1_def M_ZC_basic_def M_ZF1_def M_AC_def by auto then show ?thesis unfolding ZFC_def by auto qed -lemma M_satT_instances12_imp_M_ZF2: - assumes "(M \ \Z\ \ {\Replacement(p)\ . p \ instances1_fms \ instances2_fms})" - shows "M_ZF2(M)" +lemma M_satT_instances1_imp_M_ZF1: + assumes "(M \ \Z\ \ {\Replacement(p)\ . p \ instances1_fms })" + shows "M_ZF1(M)" proof - from assms have fin: "upair_ax(##M)" "Union_ax(##M)" "power_ax(##M)" "extensionality(##M)" "foundation_ax(##M)" "infinity_ax(##M)" unfolding ZF_fin_def Zermelo_fms_def ZFC_fm_defs satT_def using ZFC_fm_sats[of M] by simp_all moreover { fix \ env - from \M \ \Z\ \ {\Replacement(p)\ . p \ instances1_fms \ instances2_fms}\ + from \M \ \Z\ \ {\Replacement(p)\ . p \ instances1_fms }\ have "\p\formula. (M, [] \ (ZF_separation_fm(p)))" unfolding Zermelo_fms_def ZF_def instances1_fms_def - instances2_fms_def by auto + by auto moreover assume "\ \ formula" "env\list(M)" ultimately have "arity(\) \ succ(length(env)) \ separation(##M, \x. (M, Cons(x, env) \ \))" using sats_ZF_separation_fm_iff by simp_all } moreover { fix \ env - assume "\ \ instances1_fms \ instances2_fms" "env\list(M)" - moreover from this and \M \ \Z\ \ {\Replacement(p)\ . p \ instances1_fms \ instances2_fms}\ + assume "\ \ instances1_fms" "env\list(M)" + moreover from this and \M \ \Z\ \ {\Replacement(p)\ . p \ instances1_fms }\ have "M, [] \ \Replacement(\)\" by auto ultimately have "arity(\) \ succ(succ(length(env))) \ strong_replacement(##M,\x y. sats(M,\,Cons(x,Cons(y, env))))" - using sats_ZF_replacement_fm_iff[of \] instances1_fms_type instances2_fms_type by auto + using sats_ZF_replacement_fm_iff[of \] instances1_fms_type + unfolding replacement_assm_def by auto } ultimately show ?thesis - unfolding instances1_fms_def instances2_fms_def + unfolding instances1_fms_def by unfold_locales (simp_all add:replacement_assm_def ground_replacement_assm_def) qed theorem M_satT_imp_M_ZF_ground_trans: assumes "Transset(M)" "M \ \Z\ \ {\Replacement(p)\ . p \ overhead}" shows "M_ZF_ground_trans(M)" proof - from \M \ \Z\ \ _\ - have "M \ \Z\ \ {\Replacement(p)\ . p \ instances1_fms \ instances2_fms}" + have "M \ \Z\ \ {\Replacement(p)\ . p \ instances1_fms }" "M \ {\Replacement(p)\ . p \ instances_ground_fms }" unfolding overhead_def by auto then - interpret M_ZF2 M - using M_satT_instances12_imp_M_ZF2 + interpret M_ZF1 M + using M_satT_instances1_imp_M_ZF1 by simp from \Transset(M)\ interpret M_ZF1_trans M using M_satT_imp_M_ZF2 by unfold_locales { fix \ env assume "\ \ instances_ground_fms" "env\list(M)" moreover from this and \M \ {\Replacement(p)\ . p \ instances_ground_fms}\ have "M, [] \ \Replacement(\)\" by auto ultimately have "arity(\) \ succ(succ(length(env))) \ strong_replacement(##M,\x y. sats(M,\,Cons(x,Cons(y, env))))" - using sats_ZF_replacement_fm_iff[of \] instances_ground_fms_type by auto + using sats_ZF_replacement_fm_iff[of \] instances_ground_fms_type + unfolding replacement_assm_def by auto } then show ?thesis unfolding instances_ground_fms_def by unfold_locales (simp_all add:replacement_assm_def) qed theorem M_satT_imp_M_ZF_ground_notCH_trans: assumes "Transset(M)" "M \ \Z\ \ {\Replacement(p)\ . p \ overhead_notCH}" shows "M_ZF_ground_notCH_trans(M)" proof - from assms interpret M_ZF_ground_trans M using M_satT_imp_M_ZF_ground_trans unfolding overhead_notCH_def by force { fix \ env assume "\ \ instances_ground_notCH_fms" "env\list(M)" moreover from this and assms have "M, [] \ \Replacement(\)\" unfolding overhead_notCH_def by auto ultimately have "arity(\) \ succ(succ(length(env))) \ strong_replacement(##M,\x y. sats(M,\,Cons(x,Cons(y, env))))" - using sats_ZF_replacement_fm_iff[of \] instances_ground_notCH_fms_type by auto + using sats_ZF_replacement_fm_iff[of \] instances_ground_notCH_fms_type + unfolding replacement_assm_def by auto } then show ?thesis by unfold_locales (simp_all add:replacement_assm_def instances_ground_notCH_fms_def) qed theorem M_satT_imp_M_ZF_ground_CH_trans: assumes "Transset(M)" "M \ \Z\ \ {\Replacement(p)\ . p \ overhead_CH }" shows "M_ZF_ground_CH_trans(M)" proof - from assms interpret M_ZF_ground_notCH_trans M using M_satT_imp_M_ZF_ground_notCH_trans unfolding overhead_CH_def by auto { fix env assume "env \ list(M)" moreover from assms have "M, [] \ \Replacement(replacement_dcwit_repl_body_fm)\" unfolding overhead_CH_def by auto ultimately have "arity(replacement_dcwit_repl_body_fm) \ succ(succ(length(env))) \ strong_replacement(##M,\x y. sats(M,replacement_dcwit_repl_body_fm,Cons(x,Cons(y, env))))" using sats_ZF_replacement_fm_iff[of replacement_dcwit_repl_body_fm] + unfolding replacement_assm_def by (auto simp:replacement_dcwit_repl_body_fm_def) } then show ?thesis by unfold_locales (simp_all add:replacement_assm_def) qed lemma (in M_Z_basic) M_satT_Zermelo_fms: "M \ \Z\" using upair_ax Union_ax power_ax extensionality foundation_ax infinity_ax separation_ax sats_ZF_separation_fm_iff unfolding Zermelo_fms_def ZF_fin_def by auto lemma (in M_ZFC1) M_satT_ZC: "M \ ZC" using upair_ax Union_ax power_ax extensionality foundation_ax infinity_ax separation_ax sats_ZF_separation_fm_iff choice_ax unfolding ZC_def Zermelo_fms_def ZF_fin_def by auto locale M_ZF = M_Z_basic + assumes replacement_ax:"replacement_assm(M,env,\)" +sublocale M_ZF \ M_ZF3 + using replacement_ax + by unfold_locales (simp_all add:ground_replacement_assm_def) + lemma M_satT_imp_M_ZF: " M \ ZF \ M_ZF(M)" proof - assume "M \ ZF" then have fin: "upair_ax(##M)" "Union_ax(##M)" "power_ax(##M)" "extensionality(##M)" "foundation_ax(##M)" "infinity_ax(##M)" unfolding ZF_def ZF_fin_def ZFC_fm_defs satT_def using ZFC_fm_sats[of M] by simp_all { fix \ env assume "\ \ formula" "env\list(M)" moreover from \M \ ZF\ have "\p\formula. (M, [] \ (ZF_separation_fm(p)))" "\p\formula. (M, [] \ (ZF_replacement_fm(p)))" unfolding ZF_def ZF_schemes_def by auto moreover from calculation have "arity(\) \ succ(length(env)) \ separation(##M, \x. (M, Cons(x, env) \ \))" "arity(\) \ succ(succ(length(env))) \ strong_replacement(##M,\x y. sats(M,\,Cons(x,Cons(y, env))))" - using sats_ZF_separation_fm_iff sats_ZF_replacement_fm_iff by simp_all + using sats_ZF_separation_fm_iff sats_ZF_replacement_fm_iff + unfolding replacement_assm_def by simp_all } with fin show "M_ZF(M)" unfolding M_ZF_def M_Z_basic_def M_ZF_axioms_def replacement_assm_def by simp qed lemma (in M_ZF) M_satT_ZF: "M \ ZF" using upair_ax Union_ax power_ax extensionality foundation_ax infinity_ax separation_ax sats_ZF_separation_fm_iff replacement_ax sats_ZF_replacement_fm_iff unfolding ZF_def ZF_schemes_def ZF_fin_def replacement_assm_def by auto lemma M_ZF_iff_M_satT: "M_ZF(M) \ (M \ ZF)" using M_ZF.M_satT_ZF M_satT_imp_M_ZF by auto locale M_ZFC = M_ZF + M_ZC_basic +sublocale M_ZFC \ M_ZFC3 + by unfold_locales + lemma M_ZFC_iff_M_satT: notes iff_trans[trans] shows "M_ZFC(M) \ (M \ ZFC)" proof - have "M_ZFC(M) \ (M \ ZF) \ choice_ax(##M)" using M_ZF_iff_M_satT unfolding M_ZFC_def M_ZC_basic_def M_AC_def M_ZF_def by auto also have " \ \ M \ ZFC" unfolding ZFC_def by auto ultimately show ?thesis by simp qed -lemma M_satT_imp_M_ZF4: "(M \ ZF) \ M_ZF4(M)" +lemma M_satT_imp_M_ZF3: "(M \ ZF) \ M_ZF3(M)" proof assume "M \ ZF" then - have fin: "upair_ax(##M)" "Union_ax(##M)" "power_ax(##M)" - "extensionality(##M)" "foundation_ax(##M)" "infinity_ax(##M)" - unfolding ZF_def ZF_fin_def ZFC_fm_defs satT_def - using ZFC_fm_sats[of M] by simp_all - { - fix \ env - assume "\ \ formula" "env\list(M)" - moreover from \M \ ZF\ - have "\p\formula. (M, [] \ (ZF_separation_fm(p)))" - "\p\formula. (M, [] \ (ZF_replacement_fm(p)))" - unfolding ZF_def ZF_schemes_def by auto - moreover from calculation - have "arity(\) \ succ(length(env)) \ separation(##M, \x. (M, Cons(x, env) \ \))" - "arity(\) \ succ(succ(length(env))) \ strong_replacement(##M,\x y. sats(M,\,Cons(x,Cons(y, env))))" - using sats_ZF_separation_fm_iff sats_ZF_replacement_fm_iff by simp_all - } - with fin - show "M_ZF4(M)" - by unfold_locales (simp_all add:replacement_assm_def ground_replacement_assm_def) + interpret M_ZF M + using M_satT_imp_M_ZF by simp + show "M_ZF3(M)" + by unfold_locales qed -lemma M_satT_imp_M_ZFC4: - shows "(M \ ZFC) \ M_ZFC4(M)" -proof - - have "(M \ ZF) \ choice_ax(##M) \ M_ZFC4(M)" - using M_satT_imp_M_ZF4[of M] unfolding M_ZF4_def M_ZFC1_def M_ZFC4_def - M_ZF3_def M_ZFC3_def M_ZF2_def M_ZFC2_def - M_ZC_basic_def M_ZF1_def M_AC_def by auto +lemma M_satT_imp_M_ZFC3: + shows "(M \ ZFC) \ M_ZFC3(M)" +proof + assume "M \ ZFC" then - show ?thesis - unfolding ZFC_def by auto + interpret M_ZFC M + using M_ZFC_iff_M_satT by simp + show "M_ZFC3(M)" + by unfold_locales qed -lemma M_satT_overhead_imp_M_ZF4: - "(M \ ZC \ {\Replacement(p)\ . p \ overhead_notCH}) \ M_ZFC4(M)" +lemma M_satT_overhead_imp_M_ZF3: + "(M \ ZC \ {\Replacement(p)\ . p \ overhead_notCH}) \ M_ZFC3(M)" proof assume "M \ ZC \ {\Replacement(p)\ . p \ overhead_notCH}" then have fin: "upair_ax(##M)" "Union_ax(##M)" "power_ax(##M)" "choice_ax(##M)" "extensionality(##M)" "foundation_ax(##M)" "infinity_ax(##M)" unfolding ZC_def ZF_fin_def Zermelo_fms_def ZFC_fm_defs satT_def using ZFC_fm_sats[of M] by simp_all moreover { fix \ env from \M \ ZC \ {\Replacement(p)\ . p \ overhead_notCH}\ have "\p\formula. (M, [] \ (ZF_separation_fm(p)))" unfolding ZC_def Zermelo_fms_def ZF_def by auto moreover assume "\ \ formula" "env\list(M)" ultimately have "arity(\) \ succ(length(env)) \ separation(##M, \x. (M, Cons(x, env) \ \))" using sats_ZF_separation_fm_iff by simp_all } moreover { fix \ env assume "\ \ overhead_notCH" "env\list(M)" moreover from this and \M \ ZC \ {\Replacement(p)\ . p \ overhead_notCH}\ have "M, [] \ \Replacement(\)\" by auto ultimately have "arity(\) \ succ(succ(length(env))) \ strong_replacement(##M,\x y. sats(M,\,Cons(x,Cons(y, env))))" - using sats_ZF_replacement_fm_iff[of \] overhead_notCH_type by auto + using sats_ZF_replacement_fm_iff[of \] overhead_notCH_type + unfolding replacement_assm_def by auto } ultimately - show "M_ZFC4(M)" + show "M_ZFC3(M)" unfolding overhead_def overhead_notCH_def instances1_fms_def - instances2_fms_def instances3_fms_def instances4_fms_def + instances2_fms_def instances3_fms_def by unfold_locales (simp_all add:replacement_assm_def ground_replacement_assm_def) qed end \ No newline at end of file