src/FOL/IFOL.thy
author clasohm
Fri, 13 Oct 1995 11:48:40 +0100
changeset 1280 909079af97b7
parent 1268 f6ef556b3ede
child 1322 9b3d3362a048
permissions -rw-r--r--
corrected spelling of title
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1268
f6ef556b3ede corrected title
clasohm
parents: 928
diff changeset
     1
(*  Title:      FOL/IFOL.thy
35
d71f96f1780e ifol.thy: added ~= for "not equals"
lcp
parents: 0
diff changeset
     2
    ID:         $Id$
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
     3
    Author:     Lawrence C Paulson, Cambridge University Computer Laboratory
35
d71f96f1780e ifol.thy: added ~= for "not equals"
lcp
parents: 0
diff changeset
     4
    Copyright   1993  University of Cambridge
d71f96f1780e ifol.thy: added ~= for "not equals"
lcp
parents: 0
diff changeset
     5
d71f96f1780e ifol.thy: added ~= for "not equals"
lcp
parents: 0
diff changeset
     6
Intuitionistic first-order logic
d71f96f1780e ifol.thy: added ~= for "not equals"
lcp
parents: 0
diff changeset
     7
*)
d71f96f1780e ifol.thy: added ~= for "not equals"
lcp
parents: 0
diff changeset
     8
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
     9
IFOL = Pure +
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    10
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    11
classes
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    12
  term < logic
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    13
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    14
default
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    15
  term
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    16
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    17
types
278
523518f44286 adapted type definition to new syntax
clasohm
parents: 79
diff changeset
    18
  o
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    19
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    20
arities
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    21
  o :: logic
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    22
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    23
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    24
consts
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    25
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    26
  Trueprop      :: "o => prop"                  ("(_)" 5)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    27
  True, False   :: "o"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    28
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    29
  (* Connectives *)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    30
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    31
  "="           :: "['a, 'a] => o"              (infixl 50)
35
d71f96f1780e ifol.thy: added ~= for "not equals"
lcp
parents: 0
diff changeset
    32
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    33
  Not           :: "o => o"                     ("~ _" [40] 40)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    34
  "&"           :: "[o, o] => o"                (infixr 35)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    35
  "|"           :: "[o, o] => o"                (infixr 30)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    36
  "-->"         :: "[o, o] => o"                (infixr 25)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    37
  "<->"         :: "[o, o] => o"                (infixr 25)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    38
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    39
  (* Quantifiers *)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    40
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    41
  All           :: "('a => o) => o"             (binder "ALL " 10)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    42
  Ex            :: "('a => o) => o"             (binder "EX " 10)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    43
  Ex1           :: "('a => o) => o"             (binder "EX! " 10)
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    44
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    45
928
cb31a4e97f75 Moved declaration of ~= to a syntax section
lcp
parents: 278
diff changeset
    46
syntax
cb31a4e97f75 Moved declaration of ~= to a syntax section
lcp
parents: 278
diff changeset
    47
  "~="          :: "['a, 'a] => o"              (infixl 50)
cb31a4e97f75 Moved declaration of ~= to a syntax section
lcp
parents: 278
diff changeset
    48
35
d71f96f1780e ifol.thy: added ~= for "not equals"
lcp
parents: 0
diff changeset
    49
translations
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    50
  "x ~= y"      == "~ (x = y)"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    51
35
d71f96f1780e ifol.thy: added ~= for "not equals"
lcp
parents: 0
diff changeset
    52
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    53
rules
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    54
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    55
  (* Equality *)
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    56
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    57
  refl          "a=a"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    58
  subst         "[| a=b;  P(a) |] ==> P(b)"
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    59
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    60
  (* Propositional logic *)
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    61
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    62
  conjI         "[| P;  Q |] ==> P&Q"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    63
  conjunct1     "P&Q ==> P"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    64
  conjunct2     "P&Q ==> Q"
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    65
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    66
  disjI1        "P ==> P|Q"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    67
  disjI2        "Q ==> P|Q"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    68
  disjE         "[| P|Q;  P ==> R;  Q ==> R |] ==> R"
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    69
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    70
  impI          "(P ==> Q) ==> P-->Q"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    71
  mp            "[| P-->Q;  P |] ==> Q"
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    72
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    73
  FalseE        "False ==> P"
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    74
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    75
  (* Definitions *)
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    76
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    77
  True_def      "True  == False-->False"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    78
  not_def       "~P    == P-->False"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    79
  iff_def       "P<->Q == (P-->Q) & (Q-->P)"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    80
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    81
  (* Unique existence *)
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    82
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    83
  ex1_def       "EX! x. P(x) == EX x. P(x) & (ALL y. P(y) --> y=x)"
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    84
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    85
  (* Quantifiers *)
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    86
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    87
  allI          "(!!x. P(x)) ==> (ALL x.P(x))"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    88
  spec          "(ALL x.P(x)) ==> P(x)"
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    89
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    90
  exI           "P(x) ==> (EX x.P(x))"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    91
  exE           "[| EX x.P(x);  !!x. P(x) ==> R |] ==> R"
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    92
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    93
  (* Reflection *)
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    94
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    95
  eq_reflection   "(x=y)   ==> (x==y)"
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    96
  iff_reflection  "(P<->Q) ==> (P==Q)"
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    97
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    98
end
79
74e68ed3b4fd added white-space;
wenzelm
parents: 35
diff changeset
    99