http://www.cs.ru.nl/~freek/notes/lambda.ml
ページの内容を lambda.ml として保存し、
$ ocaml
# #use "lambda.ml";;
で読み込まれるので、あとは下記の様に試すだけ。
# nf "(^x.fx)a";;
- : term = term "fa"
# nf "(KISS)(KISS)";;
- : term = term "^yzz'.zz'(yzz')"
# red_gk all "SKK";;
- : term list =
[term "SKK"; term "(^yz.Kz(yz))K"; term "^z.(^y.z)(Kz)"; term "^z.z"]
# red 7 "(^x.xx)(^x.xx)";;
- : term list =
[term "(^x.xx)^x.xx"; term "(^x.xx)^x.xx"; term "(^x.xx)^x.xx";
term "(^x.xx)^x.xx"; term "(^x.xx)^x.xx"; term "(^x.xx)^x.xx";
term "(^x.xx)^x.xx"; term "..."]
#
手計算に自信が無い時に使うといいかなー。
No comments:
Post a Comment