src/ZF/Constructible/Reflection.thy
author wenzelm
Tue, 16 Jan 2018 09:30:00 +0100
changeset 67443 3abf6a722518
parent 61980 6b780867d426
child 69593 3dda49e08b9d
permissions -rw-r--r--
standardized towards new-style formal comments: isabelle update_comments;
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
13505
52a16cb7fefb Relativized right up to L satisfies V=L!
paulson
parents: 13434
diff changeset
     1
(*  Title:      ZF/Constructible/Reflection.thy
52a16cb7fefb Relativized right up to L satisfies V=L!
paulson
parents: 13434
diff changeset
     2
    Author:     Lawrence C Paulson, Cambridge University Computer Laboratory
52a16cb7fefb Relativized right up to L satisfies V=L!
paulson
parents: 13434
diff changeset
     3
*)
52a16cb7fefb Relativized right up to L satisfies V=L!
paulson
parents: 13434
diff changeset
     4
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
     5
section \<open>The Reflection Theorem\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
     6
16417
9bc16273c2d4 migrated theory headers to new format
haftmann
parents: 14171
diff changeset
     7
theory Reflection imports Normal begin
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
     8
58860
fee7cfa69c50 eliminated spurious semicolons;
wenzelm
parents: 46823
diff changeset
     9
lemma all_iff_not_ex_not: "(\<forall>x. P(x)) \<longleftrightarrow> (~ (\<exists>x. ~ P(x)))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    10
by blast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    11
58860
fee7cfa69c50 eliminated spurious semicolons;
wenzelm
parents: 46823
diff changeset
    12
lemma ball_iff_not_bex_not: "(\<forall>x\<in>A. P(x)) \<longleftrightarrow> (~ (\<exists>x\<in>A. ~ P(x)))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    13
by blast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    14
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
    15
text\<open>From the notes of A. S. Kechris, page 6, and from
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    16
      Andrzej Mostowski, \emph{Constructible Sets with Applications},
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
    17
      North-Holland, 1969, page 23.\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    18
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    19
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
    20
subsection\<open>Basic Definitions\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    21
61798
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
    22
text\<open>First part: the cumulative hierarchy defining the class \<open>M\<close>.
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
    23
To avoid handling multiple arguments, we assume that \<open>Mset(l)\<close> is
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
    24
closed under ordered pairing provided \<open>l\<close> is limit.  Possibly this
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    25
could be avoided: the induction hypothesis @{term Cl_reflects}
61798
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
    26
(in locale \<open>ex_reflection\<close>) could be weakened to
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    27
@{term "\<forall>y\<in>Mset(a). \<forall>z\<in>Mset(a). P(<y,z>) \<longleftrightarrow> Q(a,<y,z>)"}, removing most
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    28
uses of @{term Pair_in_Mset}.  But there isn't much point in doing so, since
61798
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
    29
ultimately the \<open>ex_reflection\<close> proof is packaged up using the
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
    30
predicate \<open>Reflects\<close>.
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
    31
\<close>
13428
99e52e78eb65 eliminate open locales and special ML code;
wenzelm
parents: 13382
diff changeset
    32
locale reflection =
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    33
  fixes Mset and M and Reflects
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    34
  assumes Mset_mono_le : "mono_le_subset(Mset)"
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    35
      and Mset_cont    : "cont_Ord(Mset)"
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    36
      and Pair_in_Mset : "[| x \<in> Mset(a); y \<in> Mset(a); Limit(a) |]
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    37
                          ==> <x,y> \<in> Mset(a)"
13563
paulson
parents: 13505
diff changeset
    38
  defines "M(x) == \<exists>a. Ord(a) & x \<in> Mset(a)"
paulson
parents: 13505
diff changeset
    39
      and "Reflects(Cl,P,Q) == Closed_Unbounded(Cl) &
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    40
                              (\<forall>a. Cl(a) \<longrightarrow> (\<forall>x\<in>Mset(a). P(x) \<longleftrightarrow> Q(a,x)))"
67443
3abf6a722518 standardized towards new-style formal comments: isabelle update_comments;
wenzelm
parents: 61980
diff changeset
    41
  fixes F0 \<comment> \<open>ordinal for a specific value @{term y}\<close>
3abf6a722518 standardized towards new-style formal comments: isabelle update_comments;
wenzelm
parents: 61980
diff changeset
    42
  fixes FF \<comment> \<open>sup over the whole level, @{term "y\<in>Mset(a)"}\<close>
3abf6a722518 standardized towards new-style formal comments: isabelle update_comments;
wenzelm
parents: 61980
diff changeset
    43
  fixes ClEx \<comment> \<open>Reflecting ordinals for the formula @{term "\<exists>z. P"}\<close>
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    44
  defines "F0(P,y) == \<mu> b. (\<exists>z. M(z) & P(<y,z>)) \<longrightarrow>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    45
                               (\<exists>z\<in>Mset(b). P(<y,z>))"
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    46
      and "FF(P)   == \<lambda>a. \<Union>y\<in>Mset(a). F0(P,y)"
13563
paulson
parents: 13505
diff changeset
    47
      and "ClEx(P,a) == Limit(a) & normalize(FF(P),a) = a"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    48
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    49
lemma (in reflection) Mset_mono: "i\<le>j ==> Mset(i) \<subseteq> Mset(j)"
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    50
apply (insert Mset_mono_le)
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    51
apply (simp add: mono_le_subset_def leI)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    52
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    53
61798
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
    54
text\<open>Awkward: we need a version of \<open>ClEx_def\<close> as an equality
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
    55
      at the level of classes, which do not really exist\<close>
13434
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
    56
lemma (in reflection) ClEx_eq:
13563
paulson
parents: 13505
diff changeset
    57
     "ClEx(P) == \<lambda>a. Limit(a) & normalize(FF(P),a) = a"
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    58
by (simp add: ClEx_def [symmetric])
13434
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
    59
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
    60
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
    61
subsection\<open>Easy Cases of the Reflection Theorem\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    62
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    63
theorem (in reflection) Triv_reflection [intro]:
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    64
     "Reflects(Ord, P, \<lambda>a x. P(x))"
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    65
by (simp add: Reflects_def)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    66
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    67
theorem (in reflection) Not_reflection [intro]:
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    68
     "Reflects(Cl,P,Q) ==> Reflects(Cl, \<lambda>x. ~P(x), \<lambda>a x. ~Q(a,x))"
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    69
by (simp add: Reflects_def)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    70
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    71
theorem (in reflection) And_reflection [intro]:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    72
     "[| Reflects(Cl,P,Q); Reflects(C',P',Q') |]
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    73
      ==> Reflects(\<lambda>a. Cl(a) & C'(a), \<lambda>x. P(x) & P'(x),
13563
paulson
parents: 13505
diff changeset
    74
                                      \<lambda>a x. Q(a,x) & Q'(a,x))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    75
by (simp add: Reflects_def Closed_Unbounded_Int, blast)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    76
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    77
theorem (in reflection) Or_reflection [intro]:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    78
     "[| Reflects(Cl,P,Q); Reflects(C',P',Q') |]
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    79
      ==> Reflects(\<lambda>a. Cl(a) & C'(a), \<lambda>x. P(x) | P'(x),
13563
paulson
parents: 13505
diff changeset
    80
                                      \<lambda>a x. Q(a,x) | Q'(a,x))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    81
by (simp add: Reflects_def Closed_Unbounded_Int, blast)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    82
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    83
theorem (in reflection) Imp_reflection [intro]:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    84
     "[| Reflects(Cl,P,Q); Reflects(C',P',Q') |]
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    85
      ==> Reflects(\<lambda>a. Cl(a) & C'(a),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    86
                   \<lambda>x. P(x) \<longrightarrow> P'(x),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    87
                   \<lambda>a x. Q(a,x) \<longrightarrow> Q'(a,x))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    88
by (simp add: Reflects_def Closed_Unbounded_Int, blast)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    89
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    90
theorem (in reflection) Iff_reflection [intro]:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    91
     "[| Reflects(Cl,P,Q); Reflects(C',P',Q') |]
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    92
      ==> Reflects(\<lambda>a. Cl(a) & C'(a),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    93
                   \<lambda>x. P(x) \<longleftrightarrow> P'(x),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    94
                   \<lambda>a x. Q(a,x) \<longleftrightarrow> Q'(a,x))"
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
    95
by (simp add: Reflects_def Closed_Unbounded_Int, blast)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    96
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
    97
subsection\<open>Reflection for Existential Quantifiers\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    98
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
    99
lemma (in reflection) F0_works:
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   100
     "[| y\<in>Mset(a); Ord(a); M(z); P(<y,z>) |] ==> \<exists>z\<in>Mset(F0(P,y)). P(<y,z>)"
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   101
apply (unfold F0_def M_def, clarify)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   102
apply (rule LeastI2)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   103
  apply (blast intro: Mset_mono [THEN subsetD])
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   104
 apply (blast intro: lt_Ord2, blast)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   105
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   106
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   107
lemma (in reflection) Ord_F0 [intro,simp]: "Ord(F0(P,y))"
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   108
by (simp add: F0_def)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   109
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   110
lemma (in reflection) Ord_FF [intro,simp]: "Ord(FF(P,y))"
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   111
by (simp add: FF_def)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   112
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   113
lemma (in reflection) cont_Ord_FF: "cont_Ord(FF(P))"
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   114
apply (insert Mset_cont)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   115
apply (simp add: cont_Ord_def FF_def, blast)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   116
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   117
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   118
text\<open>Recall that @{term F0} depends upon @{term "y\<in>Mset(a)"},
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   119
while @{term FF} depends only upon @{term a}.\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   120
lemma (in reflection) FF_works:
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   121
     "[| M(z); y\<in>Mset(a); P(<y,z>); Ord(a) |] ==> \<exists>z\<in>Mset(FF(P,a)). P(<y,z>)"
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   122
apply (simp add: FF_def)
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   123
apply (simp_all add: cont_Ord_Union [of concl: Mset]
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   124
                     Mset_cont Mset_mono_le not_emptyI Ord_F0)
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   125
apply (blast intro: F0_works)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   126
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   127
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   128
lemma (in reflection) FFN_works:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   129
     "[| M(z); y\<in>Mset(a); P(<y,z>); Ord(a) |]
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   130
      ==> \<exists>z\<in>Mset(normalize(FF(P),a)). P(<y,z>)"
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   131
apply (drule FF_works [of concl: P], assumption+)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   132
apply (blast intro: cont_Ord_FF le_normalize [THEN Mset_mono, THEN subsetD])
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   133
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   134
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   135
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   136
text\<open>Locale for the induction hypothesis\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   137
13428
99e52e78eb65 eliminate open locales and special ML code;
wenzelm
parents: 13382
diff changeset
   138
locale ex_reflection = reflection +
67443
3abf6a722518 standardized towards new-style formal comments: isabelle update_comments;
wenzelm
parents: 61980
diff changeset
   139
  fixes P  \<comment> \<open>the original formula\<close>
3abf6a722518 standardized towards new-style formal comments: isabelle update_comments;
wenzelm
parents: 61980
diff changeset
   140
  fixes Q  \<comment> \<open>the reflected formula\<close>
3abf6a722518 standardized towards new-style formal comments: isabelle update_comments;
wenzelm
parents: 61980
diff changeset
   141
  fixes Cl \<comment> \<open>the class of reflecting ordinals\<close>
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   142
  assumes Cl_reflects: "[| Cl(a); Ord(a) |] ==> \<forall>x\<in>Mset(a). P(x) \<longleftrightarrow> Q(a,x)"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   143
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   144
lemma (in ex_reflection) ClEx_downward:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   145
     "[| M(z); y\<in>Mset(a); P(<y,z>); Cl(a); ClEx(P,a) |]
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   146
      ==> \<exists>z\<in>Mset(a). Q(a,<y,z>)"
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   147
apply (simp add: ClEx_def, clarify)
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   148
apply (frule Limit_is_Ord)
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   149
apply (frule FFN_works [of concl: P], assumption+)
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   150
apply (drule Cl_reflects, assumption+)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   151
apply (auto simp add: Limit_is_Ord Pair_in_Mset)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   152
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   153
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   154
lemma (in ex_reflection) ClEx_upward:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   155
     "[| z\<in>Mset(a); y\<in>Mset(a); Q(a,<y,z>); Cl(a); ClEx(P,a) |]
13563
paulson
parents: 13505
diff changeset
   156
      ==> \<exists>z. M(z) & P(<y,z>)"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   157
apply (simp add: ClEx_def M_def)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   158
apply (blast dest: Cl_reflects
32960
69916a850301 eliminated hard tabulators, guessing at each author's individual tab-width;
wenzelm
parents: 23464
diff changeset
   159
             intro: Limit_is_Ord Pair_in_Mset)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   160
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   161
61798
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
   162
text\<open>Class \<open>ClEx\<close> indeed consists of reflecting ordinals...\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   163
lemma (in ex_reflection) ZF_ClEx_iff:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   164
     "[| y\<in>Mset(a); Cl(a); ClEx(P,a) |]
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   165
      ==> (\<exists>z. M(z) & P(<y,z>)) \<longleftrightarrow> (\<exists>z\<in>Mset(a). Q(a,<y,z>))"
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   166
by (blast intro: dest: ClEx_downward ClEx_upward)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   167
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   168
text\<open>...and it is closed and unbounded\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   169
lemma (in ex_reflection) ZF_Closed_Unbounded_ClEx:
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   170
     "Closed_Unbounded(ClEx(P))"
13434
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
   171
apply (simp add: ClEx_eq)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   172
apply (fast intro: Closed_Unbounded_Int Normal_imp_fp_Closed_Unbounded
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   173
                   Closed_Unbounded_Limit Normal_normalize)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   174
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   175
61798
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
   176
text\<open>The same two theorems, exported to locale \<open>reflection\<close>.\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   177
61798
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
   178
text\<open>Class \<open>ClEx\<close> indeed consists of reflecting ordinals...\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   179
lemma (in reflection) ClEx_iff:
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   180
     "[| y\<in>Mset(a); Cl(a); ClEx(P,a);
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   181
        !!a. [| Cl(a); Ord(a) |] ==> \<forall>x\<in>Mset(a). P(x) \<longleftrightarrow> Q(a,x) |]
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   182
      ==> (\<exists>z. M(z) & P(<y,z>)) \<longleftrightarrow> (\<exists>z\<in>Mset(a). Q(a,<y,z>))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   183
apply (unfold ClEx_def FF_def F0_def M_def)
13428
99e52e78eb65 eliminate open locales and special ML code;
wenzelm
parents: 13382
diff changeset
   184
apply (rule ex_reflection.ZF_ClEx_iff
99e52e78eb65 eliminate open locales and special ML code;
wenzelm
parents: 13382
diff changeset
   185
  [OF ex_reflection.intro, OF reflection.intro ex_reflection_axioms.intro,
99e52e78eb65 eliminate open locales and special ML code;
wenzelm
parents: 13382
diff changeset
   186
    of Mset Cl])
99e52e78eb65 eliminate open locales and special ML code;
wenzelm
parents: 13382
diff changeset
   187
apply (simp_all add: Mset_mono_le Mset_cont Pair_in_Mset)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   188
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   189
13434
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
   190
(*Alternative proof, less unfolding:
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
   191
apply (rule Reflection.ZF_ClEx_iff [of Mset _ _ Cl, folded M_def])
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
   192
apply (fold ClEx_def FF_def F0_def)
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
   193
apply (rule ex_reflection.intro, assumption)
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
   194
apply (simp add: ex_reflection_axioms.intro, assumption+)
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
   195
*)
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
   196
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   197
lemma (in reflection) Closed_Unbounded_ClEx:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   198
     "(!!a. [| Cl(a); Ord(a) |] ==> \<forall>x\<in>Mset(a). P(x) \<longleftrightarrow> Q(a,x))
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   199
      ==> Closed_Unbounded(ClEx(P))"
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   200
apply (unfold ClEx_eq FF_def F0_def M_def)
21232
faacfd4392b5 fixed locale fact references;
wenzelm
parents: 16417
diff changeset
   201
apply (rule ex_reflection.ZF_Closed_Unbounded_ClEx [of Mset _ _ Cl])
23464
bc2563c37b1a tuned proofs -- avoid implicit prems;
wenzelm
parents: 21232
diff changeset
   202
apply (rule ex_reflection.intro, rule reflection_axioms)
13434
78b93a667c01 better sats rules for higher-order operators
paulson
parents: 13428
diff changeset
   203
apply (blast intro: ex_reflection_axioms.intro)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   204
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   205
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   206
subsection\<open>Packaging the Quantifier Reflection Rules\<close>
13292
f504f5d284d3 reflection for rall and rex
paulson
parents: 13268
diff changeset
   207
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   208
lemma (in reflection) Ex_reflection_0:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   209
     "Reflects(Cl,P0,Q0)
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   210
      ==> Reflects(\<lambda>a. Cl(a) & ClEx(P0,a),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   211
                   \<lambda>x. \<exists>z. M(z) & P0(<x,z>),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   212
                   \<lambda>a x. \<exists>z\<in>Mset(a). Q0(a,<x,z>))"
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   213
apply (simp add: Reflects_def)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   214
apply (intro conjI Closed_Unbounded_Int)
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   215
  apply blast
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   216
 apply (rule Closed_Unbounded_ClEx [of Cl P0 Q0], blast, clarify)
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   217
apply (rule_tac Cl=Cl in  ClEx_iff, assumption+, blast)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   218
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   219
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   220
lemma (in reflection) All_reflection_0:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   221
     "Reflects(Cl,P0,Q0)
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   222
      ==> Reflects(\<lambda>a. Cl(a) & ClEx(\<lambda>x.~P0(x), a),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   223
                   \<lambda>x. \<forall>z. M(z) \<longrightarrow> P0(<x,z>),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   224
                   \<lambda>a x. \<forall>z\<in>Mset(a). Q0(a,<x,z>))"
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   225
apply (simp only: all_iff_not_ex_not ball_iff_not_bex_not)
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   226
apply (rule Not_reflection, drule Not_reflection, simp)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   227
apply (erule Ex_reflection_0)
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   228
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   229
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   230
theorem (in reflection) Ex_reflection [intro]:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   231
     "Reflects(Cl, \<lambda>x. P(fst(x),snd(x)), \<lambda>a x. Q(a,fst(x),snd(x)))
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   232
      ==> Reflects(\<lambda>a. Cl(a) & ClEx(\<lambda>x. P(fst(x),snd(x)), a),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   233
                   \<lambda>x. \<exists>z. M(z) & P(x,z),
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   234
                   \<lambda>a x. \<exists>z\<in>Mset(a). Q(a,x,z))"
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   235
by (rule Ex_reflection_0 [of _ " \<lambda>x. P(fst(x),snd(x))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   236
                               "\<lambda>a x. Q(a,fst(x),snd(x))", simplified])
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   237
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   238
theorem (in reflection) All_reflection [intro]:
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   239
     "Reflects(Cl,  \<lambda>x. P(fst(x),snd(x)), \<lambda>a x. Q(a,fst(x),snd(x)))
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   240
      ==> Reflects(\<lambda>a. Cl(a) & ClEx(\<lambda>x. ~P(fst(x),snd(x)), a),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   241
                   \<lambda>x. \<forall>z. M(z) \<longrightarrow> P(x,z),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   242
                   \<lambda>a x. \<forall>z\<in>Mset(a). Q(a,x,z))"
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   243
by (rule All_reflection_0 [of _ "\<lambda>x. P(fst(x),snd(x))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   244
                                "\<lambda>a x. Q(a,fst(x),snd(x))", simplified])
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   245
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   246
text\<open>And again, this time using class-bounded quantifiers\<close>
13292
f504f5d284d3 reflection for rall and rex
paulson
parents: 13268
diff changeset
   247
f504f5d284d3 reflection for rall and rex
paulson
parents: 13268
diff changeset
   248
theorem (in reflection) Rex_reflection [intro]:
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   249
     "Reflects(Cl, \<lambda>x. P(fst(x),snd(x)), \<lambda>a x. Q(a,fst(x),snd(x)))
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   250
      ==> Reflects(\<lambda>a. Cl(a) & ClEx(\<lambda>x. P(fst(x),snd(x)), a),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   251
                   \<lambda>x. \<exists>z[M]. P(x,z),
13292
f504f5d284d3 reflection for rall and rex
paulson
parents: 13268
diff changeset
   252
                   \<lambda>a x. \<exists>z\<in>Mset(a). Q(a,x,z))"
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   253
by (unfold rex_def, blast)
13292
f504f5d284d3 reflection for rall and rex
paulson
parents: 13268
diff changeset
   254
f504f5d284d3 reflection for rall and rex
paulson
parents: 13268
diff changeset
   255
theorem (in reflection) Rall_reflection [intro]:
f504f5d284d3 reflection for rall and rex
paulson
parents: 13268
diff changeset
   256
     "Reflects(Cl,  \<lambda>x. P(fst(x),snd(x)), \<lambda>a x. Q(a,fst(x),snd(x)))
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   257
      ==> Reflects(\<lambda>a. Cl(a) & ClEx(\<lambda>x. ~P(fst(x),snd(x)), a),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   258
                   \<lambda>x. \<forall>z[M]. P(x,z),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   259
                   \<lambda>a x. \<forall>z\<in>Mset(a). Q(a,x,z))"
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   260
by (unfold rall_def, blast)
13292
f504f5d284d3 reflection for rall and rex
paulson
parents: 13268
diff changeset
   261
f504f5d284d3 reflection for rall and rex
paulson
parents: 13268
diff changeset
   262
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   263
text\<open>No point considering bounded quantifiers, where reflection is trivial.\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   264
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   265
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   266
subsection\<open>Simple Examples of Reflection\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   267
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   268
text\<open>Example 1: reflecting a simple formula.  The reflecting class is first
61798
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
   269
given as the variable \<open>?Cl\<close> and later retrieved from the final
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   270
proof state.\<close>
61337
4645502c3c64 fewer aliases for toplevel theorem statements;
wenzelm
parents: 60770
diff changeset
   271
schematic_goal (in reflection)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   272
     "Reflects(?Cl,
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   273
               \<lambda>x. \<exists>y. M(y) & x \<in> y,
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   274
               \<lambda>a x. \<exists>y\<in>Mset(a). x \<in> y)"
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   275
by fast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   276
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   277
text\<open>Problem here: there needs to be a conjunction (class intersection)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   278
in the class of reflecting ordinals.  The @{term "Ord(a)"} is redundant,
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   279
though harmless.\<close>
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   280
lemma (in reflection)
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   281
     "Reflects(\<lambda>a. Ord(a) & ClEx(\<lambda>x. fst(x) \<in> snd(x), a),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   282
               \<lambda>x. \<exists>y. M(y) & x \<in> y,
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   283
               \<lambda>a x. \<exists>y\<in>Mset(a). x \<in> y)"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   284
by fast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   285
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   286
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   287
text\<open>Example 2\<close>
61337
4645502c3c64 fewer aliases for toplevel theorem statements;
wenzelm
parents: 60770
diff changeset
   288
schematic_goal (in reflection)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   289
     "Reflects(?Cl,
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   290
               \<lambda>x. \<exists>y. M(y) & (\<forall>z. M(z) \<longrightarrow> z \<subseteq> x \<longrightarrow> z \<in> y),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   291
               \<lambda>a x. \<exists>y\<in>Mset(a). \<forall>z\<in>Mset(a). z \<subseteq> x \<longrightarrow> z \<in> y)"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   292
by fast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   293
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   294
text\<open>Example 2'.  We give the reflecting class explicitly.\<close>
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   295
lemma (in reflection)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   296
  "Reflects
13563
paulson
parents: 13505
diff changeset
   297
    (\<lambda>a. (Ord(a) &
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   298
          ClEx(\<lambda>x. ~ (snd(x) \<subseteq> fst(fst(x)) \<longrightarrow> snd(x) \<in> snd(fst(x))), a)) &
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   299
          ClEx(\<lambda>x. \<forall>z. M(z) \<longrightarrow> z \<subseteq> fst(x) \<longrightarrow> z \<in> snd(x), a),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   300
            \<lambda>x. \<exists>y. M(y) & (\<forall>z. M(z) \<longrightarrow> z \<subseteq> x \<longrightarrow> z \<in> y),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   301
            \<lambda>a x. \<exists>y\<in>Mset(a). \<forall>z\<in>Mset(a). z \<subseteq> x \<longrightarrow> z \<in> y)"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   302
by fast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   303
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   304
text\<open>Example 2''.  We expand the subset relation.\<close>
61337
4645502c3c64 fewer aliases for toplevel theorem statements;
wenzelm
parents: 60770
diff changeset
   305
schematic_goal (in reflection)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   306
  "Reflects(?Cl,
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   307
        \<lambda>x. \<exists>y. M(y) & (\<forall>z. M(z) \<longrightarrow> (\<forall>w. M(w) \<longrightarrow> w\<in>z \<longrightarrow> w\<in>x) \<longrightarrow> z\<in>y),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   308
        \<lambda>a x. \<exists>y\<in>Mset(a). \<forall>z\<in>Mset(a). (\<forall>w\<in>Mset(a). w\<in>z \<longrightarrow> w\<in>x) \<longrightarrow> z\<in>y)"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   309
by fast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   310
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   311
text\<open>Example 2'''.  Single-step version, to reveal the reflecting class.\<close>
61337
4645502c3c64 fewer aliases for toplevel theorem statements;
wenzelm
parents: 60770
diff changeset
   312
schematic_goal (in reflection)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   313
     "Reflects(?Cl,
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   314
               \<lambda>x. \<exists>y. M(y) & (\<forall>z. M(z) \<longrightarrow> z \<subseteq> x \<longrightarrow> z \<in> y),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   315
               \<lambda>a x. \<exists>y\<in>Mset(a). \<forall>z\<in>Mset(a). z \<subseteq> x \<longrightarrow> z \<in> y)"
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   316
apply (rule Ex_reflection)
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   317
txt\<open>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   318
@{goals[display,indent=0,margin=60]}
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   319
\<close>
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   320
apply (rule All_reflection)
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   321
txt\<open>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   322
@{goals[display,indent=0,margin=60]}
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   323
\<close>
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   324
apply (rule Triv_reflection)
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   325
txt\<open>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   326
@{goals[display,indent=0,margin=60]}
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   327
\<close>
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   328
done
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   329
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   330
text\<open>Example 3.  Warning: the following examples make sense only
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   331
if @{term P} is quantifier-free, since it is not being relativized.\<close>
61337
4645502c3c64 fewer aliases for toplevel theorem statements;
wenzelm
parents: 60770
diff changeset
   332
schematic_goal (in reflection)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   333
     "Reflects(?Cl,
46823
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   334
               \<lambda>x. \<exists>y. M(y) & (\<forall>z. M(z) \<longrightarrow> z \<in> y \<longleftrightarrow> z \<in> x & P(z)),
57bf0cecb366 More mathematical symbols for ZF examples
paulson
parents: 36319
diff changeset
   335
               \<lambda>a x. \<exists>y\<in>Mset(a). \<forall>z\<in>Mset(a). z \<in> y \<longleftrightarrow> z \<in> x & P(z))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   336
by fast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   337
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   338
text\<open>Example 3'\<close>
61337
4645502c3c64 fewer aliases for toplevel theorem statements;
wenzelm
parents: 60770
diff changeset
   339
schematic_goal (in reflection)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   340
     "Reflects(?Cl,
13563
paulson
parents: 13505
diff changeset
   341
               \<lambda>x. \<exists>y. M(y) & y = Collect(x,P),
58860
fee7cfa69c50 eliminated spurious semicolons;
wenzelm
parents: 46823
diff changeset
   342
               \<lambda>a x. \<exists>y\<in>Mset(a). y = Collect(x,P))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   343
by fast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   344
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   345
text\<open>Example 3''\<close>
61337
4645502c3c64 fewer aliases for toplevel theorem statements;
wenzelm
parents: 60770
diff changeset
   346
schematic_goal (in reflection)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   347
     "Reflects(?Cl,
13563
paulson
parents: 13505
diff changeset
   348
               \<lambda>x. \<exists>y. M(y) & y = Replace(x,P),
58860
fee7cfa69c50 eliminated spurious semicolons;
wenzelm
parents: 46823
diff changeset
   349
               \<lambda>a x. \<exists>y\<in>Mset(a). y = Replace(x,P))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   350
by fast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   351
61798
27f3c10b0b50 isabelle update_cartouches -c -t;
wenzelm
parents: 61337
diff changeset
   352
text\<open>Example 4: Axiom of Choice.  Possibly wrong, since \<open>\<Pi>\<close> needs
60770
240563fbf41d isabelle update_cartouches;
wenzelm
parents: 58871
diff changeset
   353
to be relativized.\<close>
61337
4645502c3c64 fewer aliases for toplevel theorem statements;
wenzelm
parents: 60770
diff changeset
   354
schematic_goal (in reflection)
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   355
     "Reflects(?Cl,
61980
6b780867d426 clarified syntax;
wenzelm
parents: 61798
diff changeset
   356
               \<lambda>A. 0\<notin>A \<longrightarrow> (\<exists>f. M(f) & f \<in> (\<Prod>X \<in> A. X)),
6b780867d426 clarified syntax;
wenzelm
parents: 61798
diff changeset
   357
               \<lambda>a A. 0\<notin>A \<longrightarrow> (\<exists>f\<in>Mset(a). f \<in> (\<Prod>X \<in> A. X)))"
13223
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   358
by fast
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   359
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   360
end
45be08fbdcff new theory of inner models
paulson
parents:
diff changeset
   361