src/ZF/OrderArith.thy
 author lcp Tue, 29 Nov 1994 00:31:31 +0100 changeset 753 ec86863e87c8 parent 437 435875e4b21d child 1155 928a16e02f9f permissions -rw-r--r--
replaced "rules" by "defs"
```
(*  Title: 	ZF/OrderArith.thy
ID:         \$Id\$
Author: 	Lawrence C Paulson, Cambridge University Computer Laboratory

Towards ordinal arithmetic
*)

OrderArith = Order + Sum +
consts
rvimage          :: "[i,i,i]=>i"

defs
(*disjoint sum of two relations; underlies ordinal addition*)
\                {z: (A+B) * (A+B).  \
\                    (EX x y. z = <Inl(x), Inr(y)>)   | 	 \
\                    (EX x' x. z = <Inl(x'), Inl(x)> & <x',x>:r)   | 	 \
\                    (EX y' y. z = <Inr(y'), Inr(y)> & <y',y>:s)}"

(*lexicographic product of two relations; underlies ordinal multiplication*)
rmult_def "rmult(A,r,B,s) == \
\                {z: (A*B) * (A*B).  \
\                    EX x' y' x y. z = <<x',y'>, <x,y>> &	 \
\                       (<x',x>: r | (x'=x & <y',y>: s))}"

(*inverse image of a relation*)
rvimage_def "rvimage(A,f,r) == {z: A*A. EX x y. z = <x,y> & <f`x,f`y>: r}"

end
```