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