src/ZF/Constructible/Normal.thy
author paulson
Wed Aug 21 15:57:24 2002 +0200 (2002-08-21)
changeset 13513 b9e14471629c
parent 13505 52a16cb7fefb
child 13634 99a593b49b04
permissions -rw-r--r--
tweaks
     1 (*  Title:      ZF/Constructible/Normal.thy
     2     ID:         $Id$
     3     Author:     Lawrence C Paulson, Cambridge University Computer Laboratory
     4     Copyright   2002  University of Cambridge
     5 *)
     6 
     7 header {*Closed Unbounded Classes and Normal Functions*}
     8 
     9 theory Normal = Main:
    10 
    11 text{*
    12 One source is the book
    13 
    14 Frank R. Drake.
    15 \emph{Set Theory: An Introduction to Large Cardinals}.
    16 North-Holland, 1974.
    17 *}
    18 
    19 
    20 subsection {*Closed and Unbounded (c.u.) Classes of Ordinals*}
    21 
    22 constdefs
    23   Closed :: "(i=>o) => o"
    24     "Closed(P) == \<forall>I. I \<noteq> 0 --> (\<forall>i\<in>I. Ord(i) \<and> P(i)) --> P(\<Union>(I))"
    25 
    26   Unbounded :: "(i=>o) => o"
    27     "Unbounded(P) == \<forall>i. Ord(i) --> (\<exists>j. i<j \<and> P(j))"
    28 
    29   Closed_Unbounded :: "(i=>o) => o"
    30     "Closed_Unbounded(P) == Closed(P) \<and> Unbounded(P)"
    31 
    32 
    33 subsubsection{*Simple facts about c.u. classes*}
    34 
    35 lemma ClosedI:
    36      "[| !!I. [| I \<noteq> 0; \<forall>i\<in>I. Ord(i) \<and> P(i) |] ==> P(\<Union>(I)) |] 
    37       ==> Closed(P)"
    38 by (simp add: Closed_def)
    39 
    40 lemma ClosedD:
    41      "[| Closed(P); I \<noteq> 0; !!i. i\<in>I ==> Ord(i); !!i. i\<in>I ==> P(i) |] 
    42       ==> P(\<Union>(I))"
    43 by (simp add: Closed_def)
    44 
    45 lemma UnboundedD:
    46      "[| Unbounded(P);  Ord(i) |] ==> \<exists>j. i<j \<and> P(j)"
    47 by (simp add: Unbounded_def)
    48 
    49 lemma Closed_Unbounded_imp_Unbounded: "Closed_Unbounded(C) ==> Unbounded(C)"
    50 by (simp add: Closed_Unbounded_def) 
    51 
    52 
    53 text{*The universal class, V, is closed and unbounded.
    54       A bit odd, since C. U. concerns only ordinals, but it's used below!*}
    55 theorem Closed_Unbounded_V [simp]: "Closed_Unbounded(\<lambda>x. True)"
    56 by (unfold Closed_Unbounded_def Closed_def Unbounded_def, blast)
    57 
    58 text{*The class of ordinals, @{term Ord}, is closed and unbounded.*}
    59 theorem Closed_Unbounded_Ord   [simp]: "Closed_Unbounded(Ord)"
    60 by (unfold Closed_Unbounded_def Closed_def Unbounded_def, blast)
    61 
    62 text{*The class of limit ordinals, @{term Limit}, is closed and unbounded.*}
    63 theorem Closed_Unbounded_Limit [simp]: "Closed_Unbounded(Limit)"
    64 apply (simp add: Closed_Unbounded_def Closed_def Unbounded_def Limit_Union, 
    65        clarify)
    66 apply (rule_tac x="i++nat" in exI)  
    67 apply (blast intro: oadd_lt_self oadd_LimitI Limit_nat Limit_has_0) 
    68 done
    69 
    70 text{*The class of cardinals, @{term Card}, is closed and unbounded.*}
    71 theorem Closed_Unbounded_Card  [simp]: "Closed_Unbounded(Card)"
    72 apply (simp add: Closed_Unbounded_def Closed_def Unbounded_def Card_Union)
    73 apply (blast intro: lt_csucc Card_csucc)
    74 done
    75 
    76 
    77 subsubsection{*The intersection of any set-indexed family of c.u. classes is
    78       c.u.*}
    79 
    80 text{*The constructions below come from Kunen, \emph{Set Theory}, page 78.*}
    81 locale cub_family =
    82   fixes P and A
    83   fixes next_greater -- "the next ordinal satisfying class @{term A}"
    84   fixes sup_greater  -- "sup of those ordinals over all @{term A}"
    85   assumes closed:    "a\<in>A ==> Closed(P(a))"
    86       and unbounded: "a\<in>A ==> Unbounded(P(a))"
    87       and A_non0: "A\<noteq>0"
    88   defines "next_greater(a,x) == \<mu>y. x<y \<and> P(a,y)"
    89       and "sup_greater(x) == \<Union>a\<in>A. next_greater(a,x)"
    90  
    91 
    92 text{*Trivial that the intersection is closed.*}
    93 lemma (in cub_family) Closed_INT: "Closed(\<lambda>x. \<forall>i\<in>A. P(i,x))"
    94 by (blast intro: ClosedI ClosedD [OF closed])
    95 
    96 text{*All remaining effort goes to show that the intersection is unbounded.*}
    97 
    98 lemma (in cub_family) Ord_sup_greater:
    99      "Ord(sup_greater(x))"
   100 by (simp add: sup_greater_def next_greater_def)
   101 
   102 lemma (in cub_family) Ord_next_greater:
   103      "Ord(next_greater(a,x))"
   104 by (simp add: next_greater_def Ord_Least)
   105 
   106 text{*@{term next_greater} works as expected: it returns a larger value
   107 and one that belongs to class @{term "P(a)"}. *}
   108 lemma (in cub_family) next_greater_lemma:
   109      "[| Ord(x); a\<in>A |] ==> P(a, next_greater(a,x)) \<and> x < next_greater(a,x)"
   110 apply (simp add: next_greater_def)
   111 apply (rule exE [OF UnboundedD [OF unbounded]])
   112   apply assumption+
   113 apply (blast intro: LeastI2 lt_Ord2) 
   114 done
   115 
   116 lemma (in cub_family) next_greater_in_P:
   117      "[| Ord(x); a\<in>A |] ==> P(a, next_greater(a,x))"
   118 by (blast dest: next_greater_lemma)
   119 
   120 lemma (in cub_family) next_greater_gt:
   121      "[| Ord(x); a\<in>A |] ==> x < next_greater(a,x)"
   122 by (blast dest: next_greater_lemma)
   123 
   124 lemma (in cub_family) sup_greater_gt:
   125      "Ord(x) ==> x < sup_greater(x)"
   126 apply (simp add: sup_greater_def)
   127 apply (insert A_non0)
   128 apply (blast intro: UN_upper_lt next_greater_gt Ord_next_greater)
   129 done
   130 
   131 lemma (in cub_family) next_greater_le_sup_greater:
   132      "a\<in>A ==> next_greater(a,x) \<le> sup_greater(x)"
   133 apply (simp add: sup_greater_def) 
   134 apply (blast intro: UN_upper_le Ord_next_greater)
   135 done
   136 
   137 lemma (in cub_family) omega_sup_greater_eq_UN:
   138      "[| Ord(x); a\<in>A |] 
   139       ==> sup_greater^\<omega> (x) = 
   140           (\<Union>n\<in>nat. next_greater(a, sup_greater^n (x)))"
   141 apply (simp add: iterates_omega_def)
   142 apply (rule le_anti_sym)
   143 apply (rule le_implies_UN_le_UN) 
   144 apply (blast intro: leI next_greater_gt Ord_iterates Ord_sup_greater)  
   145 txt{*Opposite bound:
   146 @{subgoals[display,indent=0,margin=65]}
   147 *}
   148 apply (rule UN_least_le) 
   149 apply (blast intro: Ord_UN Ord_iterates Ord_sup_greater)  
   150 apply (rule_tac a="succ(n)" in UN_upper_le)
   151 apply (simp_all add: next_greater_le_sup_greater) 
   152 apply (blast intro: Ord_UN Ord_iterates Ord_sup_greater)  
   153 done
   154 
   155 lemma (in cub_family) P_omega_sup_greater:
   156      "[| Ord(x); a\<in>A |] ==> P(a, sup_greater^\<omega> (x))"
   157 apply (simp add: omega_sup_greater_eq_UN)
   158 apply (rule ClosedD [OF closed]) 
   159 apply (blast intro: ltD, auto)
   160 apply (blast intro: Ord_iterates Ord_next_greater Ord_sup_greater)
   161 apply (blast intro: next_greater_in_P Ord_iterates Ord_sup_greater)
   162 done
   163 
   164 lemma (in cub_family) omega_sup_greater_gt:
   165      "Ord(x) ==> x < sup_greater^\<omega> (x)"
   166 apply (simp add: iterates_omega_def)
   167 apply (rule UN_upper_lt [of 1], simp_all) 
   168  apply (blast intro: sup_greater_gt) 
   169 apply (blast intro: Ord_UN Ord_iterates Ord_sup_greater)
   170 done
   171 
   172 lemma (in cub_family) Unbounded_INT: "Unbounded(\<lambda>x. \<forall>a\<in>A. P(a,x))"
   173 apply (unfold Unbounded_def)  
   174 apply (blast intro!: omega_sup_greater_gt P_omega_sup_greater) 
   175 done
   176 
   177 lemma (in cub_family) Closed_Unbounded_INT: 
   178      "Closed_Unbounded(\<lambda>x. \<forall>a\<in>A. P(a,x))"
   179 by (simp add: Closed_Unbounded_def Closed_INT Unbounded_INT)
   180 
   181 
   182 theorem Closed_Unbounded_INT:
   183     "(!!a. a\<in>A ==> Closed_Unbounded(P(a)))
   184      ==> Closed_Unbounded(\<lambda>x. \<forall>a\<in>A. P(a, x))"
   185 apply (case_tac "A=0", simp)
   186 apply (rule cub_family.Closed_Unbounded_INT [OF cub_family.intro])
   187 apply (simp_all add: Closed_Unbounded_def)
   188 done
   189 
   190 lemma Int_iff_INT2:
   191      "P(x) \<and> Q(x)  <->  (\<forall>i\<in>2. (i=0 --> P(x)) \<and> (i=1 --> Q(x)))"
   192 by auto
   193 
   194 theorem Closed_Unbounded_Int:
   195      "[| Closed_Unbounded(P); Closed_Unbounded(Q) |] 
   196       ==> Closed_Unbounded(\<lambda>x. P(x) \<and> Q(x))"
   197 apply (simp only: Int_iff_INT2)
   198 apply (rule Closed_Unbounded_INT, auto) 
   199 done
   200 
   201 
   202 subsection {*Normal Functions*} 
   203 
   204 constdefs
   205   mono_le_subset :: "(i=>i) => o"
   206     "mono_le_subset(M) == \<forall>i j. i\<le>j --> M(i) \<subseteq> M(j)"
   207 
   208   mono_Ord :: "(i=>i) => o"
   209     "mono_Ord(F) == \<forall>i j. i<j --> F(i) < F(j)"
   210 
   211   cont_Ord :: "(i=>i) => o"
   212     "cont_Ord(F) == \<forall>l. Limit(l) --> F(l) = (\<Union>i<l. F(i))"
   213 
   214   Normal :: "(i=>i) => o"
   215     "Normal(F) == mono_Ord(F) \<and> cont_Ord(F)"
   216 
   217 
   218 subsubsection{*Immediate properties of the definitions*}
   219 
   220 lemma NormalI:
   221      "[|!!i j. i<j ==> F(i) < F(j);  !!l. Limit(l) ==> F(l) = (\<Union>i<l. F(i))|]
   222       ==> Normal(F)"
   223 by (simp add: Normal_def mono_Ord_def cont_Ord_def)
   224 
   225 lemma mono_Ord_imp_Ord: "[| Ord(i); mono_Ord(F) |] ==> Ord(F(i))"
   226 apply (simp add: mono_Ord_def) 
   227 apply (blast intro: lt_Ord) 
   228 done
   229 
   230 lemma mono_Ord_imp_mono: "[| i<j; mono_Ord(F) |] ==> F(i) < F(j)"
   231 by (simp add: mono_Ord_def)
   232 
   233 lemma Normal_imp_Ord [simp]: "[| Normal(F); Ord(i) |] ==> Ord(F(i))"
   234 by (simp add: Normal_def mono_Ord_imp_Ord) 
   235 
   236 lemma Normal_imp_cont: "[| Normal(F); Limit(l) |] ==> F(l) = (\<Union>i<l. F(i))"
   237 by (simp add: Normal_def cont_Ord_def)
   238 
   239 lemma Normal_imp_mono: "[| i<j; Normal(F) |] ==> F(i) < F(j)"
   240 by (simp add: Normal_def mono_Ord_def)
   241 
   242 lemma Normal_increasing: "[| Ord(i); Normal(F) |] ==> i\<le>F(i)"
   243 apply (induct i rule: trans_induct3_rule)
   244   apply (simp add: subset_imp_le)
   245  apply (subgoal_tac "F(x) < F(succ(x))")
   246   apply (force intro: lt_trans1)
   247  apply (simp add: Normal_def mono_Ord_def)
   248 apply (subgoal_tac "(\<Union>y<x. y) \<le> (\<Union>y<x. F(y))")
   249  apply (simp add: Normal_imp_cont Limit_OUN_eq) 
   250 apply (blast intro: ltD le_implies_OUN_le_OUN)
   251 done
   252 
   253 
   254 subsubsection{*The class of fixedpoints is closed and unbounded*}
   255 
   256 text{*The proof is from Drake, pages 113--114.*}
   257 
   258 lemma mono_Ord_imp_le_subset: "mono_Ord(F) ==> mono_le_subset(F)"
   259 apply (simp add: mono_le_subset_def, clarify)
   260 apply (subgoal_tac "F(i)\<le>F(j)", blast dest: le_imp_subset) 
   261 apply (simp add: le_iff) 
   262 apply (blast intro: lt_Ord2 mono_Ord_imp_Ord mono_Ord_imp_mono) 
   263 done
   264 
   265 text{*The following equation is taken for granted in any set theory text.*}
   266 lemma cont_Ord_Union:
   267      "[| cont_Ord(F); mono_le_subset(F); X=0 --> F(0)=0; \<forall>x\<in>X. Ord(x) |] 
   268       ==> F(Union(X)) = (\<Union>y\<in>X. F(y))"
   269 apply (frule Ord_set_cases)
   270 apply (erule disjE, force) 
   271 apply (thin_tac "X=0 --> ?Q", auto)
   272  txt{*The trival case of @{term "\<Union>X \<in> X"}*}
   273  apply (rule equalityI, blast intro: Ord_Union_eq_succD) 
   274  apply (simp add: mono_le_subset_def UN_subset_iff le_subset_iff) 
   275  apply (blast elim: equalityE)
   276 txt{*The limit case, @{term "Limit(\<Union>X)"}:
   277 @{subgoals[display,indent=0,margin=65]}
   278 *}
   279 apply (simp add: OUN_Union_eq cont_Ord_def)
   280 apply (rule equalityI) 
   281 txt{*First inclusion:*}
   282  apply (rule UN_least [OF OUN_least])
   283  apply (simp add: mono_le_subset_def, blast intro: leI) 
   284 txt{*Second inclusion:*}
   285 apply (rule UN_least) 
   286 apply (frule Union_upper_le, blast, blast intro: Ord_Union)
   287 apply (erule leE, drule ltD, elim UnionE)
   288  apply (simp add: OUnion_def)
   289  apply blast+
   290 done
   291 
   292 lemma Normal_Union:
   293      "[| X\<noteq>0; \<forall>x\<in>X. Ord(x); Normal(F) |] ==> F(Union(X)) = (\<Union>y\<in>X. F(y))"
   294 apply (simp add: Normal_def) 
   295 apply (blast intro: mono_Ord_imp_le_subset cont_Ord_Union) 
   296 done
   297 
   298 lemma Normal_imp_fp_Closed: "Normal(F) ==> Closed(\<lambda>i. F(i) = i)"
   299 apply (simp add: Closed_def ball_conj_distrib, clarify)
   300 apply (frule Ord_set_cases)
   301 apply (auto simp add: Normal_Union)
   302 done
   303 
   304 
   305 lemma iterates_Normal_increasing:
   306      "[| n\<in>nat;  x < F(x);  Normal(F) |] 
   307       ==> F^n (x) < F^(succ(n)) (x)"  
   308 apply (induct n rule: nat_induct)
   309 apply (simp_all add: Normal_imp_mono)
   310 done
   311 
   312 lemma Ord_iterates_Normal:
   313      "[| n\<in>nat;  Normal(F);  Ord(x) |] ==> Ord(F^n (x))"  
   314 by (simp add: Ord_iterates) 
   315 
   316 text{*THIS RESULT IS UNUSED*}
   317 lemma iterates_omega_Limit:
   318      "[| Normal(F);  x < F(x) |] ==> Limit(F^\<omega> (x))"  
   319 apply (frule lt_Ord) 
   320 apply (simp add: iterates_omega_def)
   321 apply (rule increasing_LimitI) 
   322    --"this lemma is @{thm increasing_LimitI [no_vars]}"
   323  apply (blast intro: UN_upper_lt [of "1"]   Normal_imp_Ord
   324                      Ord_UN Ord_iterates lt_imp_0_lt
   325                      iterates_Normal_increasing, clarify)
   326 apply (rule bexI) 
   327  apply (blast intro: Ord_in_Ord [OF Ord_iterates_Normal]) 
   328 apply (rule UN_I, erule nat_succI) 
   329 apply (blast intro:  iterates_Normal_increasing Ord_iterates_Normal
   330                      ltD [OF lt_trans1, OF succ_leI, OF ltI]) 
   331 done
   332 
   333 lemma iterates_omega_fixedpoint:
   334      "[| Normal(F); Ord(a) |] ==> F(F^\<omega> (a)) = F^\<omega> (a)" 
   335 apply (frule Normal_increasing, assumption)
   336 apply (erule leE) 
   337  apply (simp_all add: iterates_omega_triv [OF sym])  (*for subgoal 2*)
   338 apply (simp add:  iterates_omega_def Normal_Union) 
   339 apply (rule equalityI, force simp add: nat_succI) 
   340 txt{*Opposite inclusion:
   341 @{subgoals[display,indent=0,margin=65]}
   342 *}
   343 apply clarify
   344 apply (rule UN_I, assumption) 
   345 apply (frule iterates_Normal_increasing, assumption, assumption, simp)
   346 apply (blast intro: Ord_trans ltD Ord_iterates_Normal Normal_imp_Ord [of F]) 
   347 done
   348 
   349 lemma iterates_omega_increasing:
   350      "[| Normal(F); Ord(a) |] ==> a \<le> F^\<omega> (a)"   
   351 apply (unfold iterates_omega_def)
   352 apply (rule UN_upper_le [of 0], simp_all)
   353 done
   354 
   355 lemma Normal_imp_fp_Unbounded: "Normal(F) ==> Unbounded(\<lambda>i. F(i) = i)"
   356 apply (unfold Unbounded_def, clarify)
   357 apply (rule_tac x="F^\<omega> (succ(i))" in exI)
   358 apply (simp add: iterates_omega_fixedpoint) 
   359 apply (blast intro: lt_trans2 [OF _ iterates_omega_increasing])
   360 done
   361 
   362 
   363 theorem Normal_imp_fp_Closed_Unbounded: 
   364      "Normal(F) ==> Closed_Unbounded(\<lambda>i. F(i) = i)"
   365 by (simp add: Closed_Unbounded_def Normal_imp_fp_Closed
   366               Normal_imp_fp_Unbounded)
   367 
   368 
   369 subsubsection{*Function @{text normalize}*}
   370 
   371 text{*Function @{text normalize} maps a function @{text F} to a 
   372       normal function that bounds it above.  The result is normal if and
   373       only if @{text F} is continuous: succ is not bounded above by any 
   374       normal function, by @{thm [source] Normal_imp_fp_Unbounded}.
   375 *}
   376 constdefs
   377   normalize :: "[i=>i, i] => i"
   378     "normalize(F,a) == transrec2(a, F(0), \<lambda>x r. F(succ(x)) Un succ(r))"
   379 
   380 
   381 lemma Ord_normalize [simp, intro]:
   382      "[| Ord(a); !!x. Ord(x) ==> Ord(F(x)) |] ==> Ord(normalize(F, a))"
   383 apply (induct a rule: trans_induct3_rule)
   384 apply (simp_all add: ltD def_transrec2 [OF normalize_def])
   385 done
   386 
   387 lemma normalize_lemma [rule_format]:
   388      "[| Ord(b); !!x. Ord(x) ==> Ord(F(x)) |] 
   389       ==> \<forall>a. a < b --> normalize(F, a) < normalize(F, b)"
   390 apply (erule trans_induct3)
   391   apply (simp_all add: le_iff def_transrec2 [OF normalize_def])
   392  apply clarify
   393 apply (rule Un_upper2_lt) 
   394   apply auto
   395  apply (drule spec, drule mp, assumption) 
   396  apply (erule leI) 
   397 apply (drule Limit_has_succ, assumption)
   398 apply (blast intro!: Ord_normalize intro: OUN_upper_lt ltD lt_Ord)
   399 done  
   400 
   401 lemma normalize_increasing:
   402      "[| a < b;  !!x. Ord(x) ==> Ord(F(x)) |] 
   403       ==> normalize(F, a) < normalize(F, b)"
   404 by (blast intro!: normalize_lemma intro: lt_Ord2) 
   405 
   406 theorem Normal_normalize:
   407      "(!!x. Ord(x) ==> Ord(F(x))) ==> Normal(normalize(F))"
   408 apply (rule NormalI) 
   409 apply (blast intro!: normalize_increasing)
   410 apply (simp add: def_transrec2 [OF normalize_def])
   411 done
   412 
   413 theorem le_normalize:
   414      "[| Ord(a); cont_Ord(F); !!x. Ord(x) ==> Ord(F(x)) |] 
   415       ==> F(a) \<le> normalize(F,a)"
   416 apply (erule trans_induct3) 
   417 apply (simp_all add: def_transrec2 [OF normalize_def])
   418 apply (simp add: Un_upper1_le) 
   419 apply (simp add: cont_Ord_def) 
   420 apply (blast intro: ltD le_implies_OUN_le_OUN)
   421 done
   422 
   423 
   424 subsection {*The Alephs*}
   425 text {*This is the well-known transfinite enumeration of the cardinal 
   426 numbers.*}
   427 
   428 constdefs
   429   Aleph :: "i => i"
   430     "Aleph(a) == transrec2(a, nat, \<lambda>x r. csucc(r))"
   431 
   432 syntax (xsymbols)
   433   Aleph :: "i => i"   ("\<aleph>_" [90] 90)
   434 
   435 lemma Card_Aleph [simp, intro]:
   436      "Ord(a) ==> Card(Aleph(a))"
   437 apply (erule trans_induct3) 
   438 apply (simp_all add: Card_csucc Card_nat Card_is_Ord
   439                      def_transrec2 [OF Aleph_def])
   440 done
   441 
   442 lemma Aleph_lemma [rule_format]:
   443      "Ord(b) ==> \<forall>a. a < b --> Aleph(a) < Aleph(b)"
   444 apply (erule trans_induct3) 
   445 apply (simp_all add: le_iff def_transrec2 [OF Aleph_def])  
   446 apply (blast intro: lt_trans lt_csucc Card_is_Ord, clarify)
   447 apply (drule Limit_has_succ, assumption)
   448 apply (blast intro: Card_is_Ord Card_Aleph OUN_upper_lt ltD lt_Ord)
   449 done  
   450 
   451 lemma Aleph_increasing:
   452      "a < b ==> Aleph(a) < Aleph(b)"
   453 by (blast intro!: Aleph_lemma intro: lt_Ord2) 
   454 
   455 theorem Normal_Aleph: "Normal(Aleph)"
   456 apply (rule NormalI) 
   457 apply (blast intro!: Aleph_increasing)
   458 apply (simp add: def_transrec2 [OF Aleph_def])
   459 done
   460 
   461 end
   462