src/ZF/Constructible/MetaExists.thy
author wenzelm
Tue, 07 Nov 2006 19:40:13 +0100
changeset 21233 5a5c8ea5f66a
parent 16417 9bc16273c2d4
child 21404 eb85850d3eb7
permissions -rw-r--r--
tuned specifications;
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
13505
52a16cb7fefb Relativized right up to L satisfies V=L!
paulson
parents: 13315
diff changeset
     1
(*  Title:      ZF/Constructible/MetaExists.thy
52a16cb7fefb Relativized right up to L satisfies V=L!
paulson
parents: 13315
diff changeset
     2
    ID:         $Id$
52a16cb7fefb Relativized right up to L satisfies V=L!
paulson
parents: 13315
diff changeset
     3
    Author:     Lawrence C Paulson, Cambridge University Computer Laboratory
52a16cb7fefb Relativized right up to L satisfies V=L!
paulson
parents: 13315
diff changeset
     4
*)
52a16cb7fefb Relativized right up to L satisfies V=L!
paulson
parents: 13315
diff changeset
     5
13314
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
     6
header{*The meta-existential quantifier*}
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
     7
16417
9bc16273c2d4 migrated theory headers to new format
haftmann
parents: 14854
diff changeset
     8
theory MetaExists imports Main begin
13314
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
     9
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    10
text{*Allows quantification over any term having sort @{text logic}.  Used to
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    11
quantify over classes.  Yields a proposition rather than a FOL formula.*}
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    12
21233
5a5c8ea5f66a tuned specifications;
wenzelm
parents: 16417
diff changeset
    13
definition
14854
61bdf2ae4dc5 removed obsolete sort 'logic';
wenzelm
parents: 13634
diff changeset
    14
  ex :: "(('a::{}) => prop) => prop"            (binder "?? " 0)
13314
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    15
  "ex(P) == (!!Q. (!!x. PROP P(x) ==> PROP Q) ==> PROP Q)"
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    16
21233
5a5c8ea5f66a tuned specifications;
wenzelm
parents: 16417
diff changeset
    17
notation (xsymbols)
5a5c8ea5f66a tuned specifications;
wenzelm
parents: 16417
diff changeset
    18
  ex  (binder "\<Or>" 0)
13314
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    19
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    20
lemma meta_exI: "PROP P(x) ==> (?? x. PROP P(x))"
13315
wenzelm
parents: 13314
diff changeset
    21
proof (unfold ex_def)
13314
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    22
  assume P: "PROP P(x)"
13315
wenzelm
parents: 13314
diff changeset
    23
  fix Q
wenzelm
parents: 13314
diff changeset
    24
  assume PQ: "\<And>x. PROP P(x) \<Longrightarrow> PROP Q"
wenzelm
parents: 13314
diff changeset
    25
  from P show "PROP Q" by (rule PQ)
13314
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    26
qed 
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    27
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    28
lemma meta_exE: "[| ?? x. PROP P(x);  !!x. PROP P(x) ==> PROP R |] ==> PROP R"
13315
wenzelm
parents: 13314
diff changeset
    29
proof (unfold ex_def)
13314
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    30
  assume QPQ: "\<And>Q. (\<And>x. PROP P(x) \<Longrightarrow> PROP Q) \<Longrightarrow> PROP Q"
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    31
  assume PR: "\<And>x. PROP P(x) \<Longrightarrow> PROP R"
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    32
  from PR show "PROP R" by (rule QPQ)
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    33
qed
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    34
84b9de3cbc91 Defining a meta-existential quantifier.
paulson
parents:
diff changeset
    35
end