src/ZF/Nat.thy
author clasohm
Thu, 16 Sep 1993 12:20:38 +0200
changeset 0 a5a9c433f639
child 6 8ce8c4d13d4d
permissions -rw-r--r--
Initial revision
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     1
(*  Title: 	ZF/nat.thy
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     2
    ID:         $Id$
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     3
    Author: 	Lawrence C Paulson, Cambridge University Computer Laboratory
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     4
    Copyright   1992  University of Cambridge
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     5
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     6
Natural numbers in Zermelo-Fraenkel Set Theory 
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     7
*)
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     8
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
     9
Nat = Ord + Bool + 
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    10
consts
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    11
    nat 	::      "i"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    12
    nat_case    ::      "[i, i, i=>i]=>i"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    13
    nat_rec     ::      "[i, i, [i,i]=>i]=>i"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    14
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    15
rules
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    16
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    17
    nat_def     "nat == lfp(Inf, %X. {0} Un {succ(i). i:X})"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    18
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    19
    nat_case_def
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    20
	"nat_case(k,a,b) == THE y. k=0 & y=a | (EX x. k=succ(x) & y=b(x))"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    21
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    22
    nat_rec_def
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    23
	"nat_rec(k,a,b) ==   \
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    24
\   	  wfrec(Memrel(nat), k, %n f. nat_case(n, a, %m. b(m, f`m)))"
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    25
a5a9c433f639 Initial revision
clasohm
parents:
diff changeset
    26
end