| Some definitions of interest. |
|
hanoi_seq | Def s is a Hanoi(n disk) seq on a..z
Def == x,x':{a...z}.
Def == x+1 = x'  ( k:{1...n}. Moving disk k of n takes s(x) to s(x')) |
| | Thm* n: , a,z: , s:({a...z} {1...n} Peg).
Thm* s is a Hanoi(n disk) seq on a..z Prop |
|
hanoi_PEG | Def Peg == {1...3} |
| | Thm* Peg Type |
|
hanoi_peg_perm | Def permute(p to r ; q to s)(u) == if u= p r ; u= q s else otherPeg(r; s) fi |
| | Thm* p,r,q,s:Peg. p q  r s  permute(p to r ; q to s) Peg Peg |
|
hanoi_otherpeg | Def otherPeg(x; y) == 6-(x+y) |
| | Thm* x,y:Peg. x y  otherPeg(x; y) Peg |
|
hanoi_seq_join | Def (s1 @(m) s2)(x) == if x m s1(x) else s2(x) fi |
| | Thm* n: , m,a,z: , s1:({a...m} {1...n} Peg), s2:({m+1...z} {1...n} Peg).
Thm* (s1 @(m) s2) {a...z} {1...n} Peg |
|
inject | Def Inj(A; B; f) == a1,a2:A. f(a1) = f(a2) B  a1 = a2 |
| | Thm* A,B:Type, f:(A B). Inj(A; B; f) Prop |
|
int_iseg | Def {i...j} == {k: | i k & k j } |
| | Thm* i,j: . {i...j} Type |
|
int_upper | Def {i...} == {j: | i j } |
| | Thm* n: . {n...} Type |
|
nat | Def == {i: | 0 i } |
| | Thm* Type |
|
nat_plus | Def  == {i: | 0<i } |
| | Thm*  Type |
|
nequal | Def a b T == a = b T |
| | Thm* A:Type, x,y:A. (x y) Prop |