changeset 2:1c57a78f1d98

Initial revision
author kono
date Thu, 18 Jan 2001 23:27:24 +0900
parents 683efd6f9a81
children c1e5614545ff 029b5a5ac494
files Makefile bddcomp.pl bddi bdditl.pl bdtstd.pl cad.pl call chop.pl cp.pl cppl.c demo.pl demoi demoim diag.pl disp.pl ex.pl example/cad.pl example/elevator.pl example/gi_ex.pl example/keyb.kiss2 example/s1a.kiss2 example/s208.kiss2 example/s298.kiss2 example/s420.kiss2 example/tbk.kiss2 exdev.pl gm/demoi gm/demoim gm/display.pl init initgm initm initr initv itl.pl itlstd.pl kiss.pl kiss_ex.pl lite.pl ndcomp.pl op.pl problems read.me test tk/basic tk/bou.lite tk/bou.tcl tk/bou.tokio tk/demo.pl tk/disp.pl tk/disp.pl.pro tk/disp.ql tk/disp.tcl tk/dummy_tcl.pl tk/elevator.pl tk/exdev.tokio tk/gi.lite tk/gi.tokio tk/gi0.lite tk/gi1.lite tk/gi10.lite tk/gi2.lite tk/gi3.lite tk/gi4.lite tk/protcl.tgz tk/tmp tk/tmp.out tk/tmp.tokio tk/xf-disp tk/xf-disp.pro tmp.pl xf-disp
diffstat 72 files changed, 18380 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Makefile	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,110 @@
+#
+# Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+#                                  The University, Newcastle upton Tyne
+#
+# Everyone is permitted to copy and distribute verbatim copies
+# of this license, but changing it is not allowed.  You can also
+# use this wording to make the terms for other programs.
+#
+# send your comments to kono@csl.sony.co.jp
+
+PROLOG = sicstus
+PROLOG_TYPE = SICSTUS
+
+# PROLOG = sbprolog
+# PROLOG_TYPE = SBPROLOG
+
+# PROLOG = cprolog
+# PROLOG_TYPE = CPROLOG
+
+# PROLOG = xsb
+# PROLOG_TYPE = XSB
+
+# last resort
+# PROLOG = prolog
+# PROLOG_TYPE = PROLOG
+
+
+#  SICSTUS                      for SICStus Prolog
+#    SICSTUS218                     patch for v2.1 #8
+#  SBPROLOG                     for SB Prolog
+#  QUINTUS                      for Quintus Prolog
+#  CPROLOG                      for CPROLOG ver 1.2
+#    CPROLOG15                  for CPROLOG15 ver 1.5
+#  see cp.pl.c
+
+all:    $(PROLOG_TYPE)
+
+SICSTUS: cp.pl
+	echo '[initm],save(lite).' | $(PROLOG)
+CPROLOG: cp.pl
+	echo '[init],save(lite).' | $(PROLOG)
+
+PROLOG: cp.pl
+	echo 'start ' $(PROLOG) ' and run [init]'
+
+SB_START_FILE = /usr/local/lib/sbprolog/modlib/\$$readloop 
+SBPROLOG:  cp.pl
+	echo "['op.pl']." > .tmpb
+	make M=$(M) $(OBJ)
+	cat .tmpb | $(PROLOG)
+	cat $(SB_START_FILE) $(OBJ) > lite
+
+XSB:  cp.pl
+	echo '[init].' | $(PROLOG)
+	echo 'start ' $(PROLOG) ' and run [init]'
+	
+
+cp.pl : cppl.c
+	cc -E -D$(PROLOG_TYPE) cppl.c | sed -e '/^#/d' > cp.pl
+
+.SUFFIXES: .pl .ql
+.SILENT:
+OBJ = op.ql ndcomp.ql dvcomp.ql bdtstd.ql rstd.ql chop.ql diag.ql kiss.ql ex.ql cp.ql
+# kiss_ex.ql
+WORK = .tmpl .tmpc .tmpa .tmpb
+# M = lite:
+
+tmpa:
+	rm -f $(WORK)
+	touch $(WORK)
+	make  M=$(M) $(OBJ)
+	echo '?-load($(M)['$(OBJ)']).' | \
+		sed -e 's/\.ql//g' -e 's/ *$$//' -e 's/ /,/g' > .tmpa
+
+.pl.ql:
+	echo '?-fcompile('$(M)$*').' >> .tmpc
+	echo '?-load('$(M)$*').' >> .tmpl
+	echo "compile('$<','$@')." >> .tmpb
+
+cp.ql : cp.pl
+
+clean:
+	rm -f lite *.ql $(WORK) cp.pl *.O *.P
+
+pack:
+	tar cvf -  read.me \
+	`echo $(OBJ) $(BDD) display.pl | sed -e 's/\.ql/\.pl/g' ` \
+	Makefile init* bddi | compress |\
+	uuencode itlve.tar.Z > itlve.tar.Z.uu
+
+lharc:
+	lharc u itl.lhz  read.me \
+	`echo $(OBJ) display.pl | sed -e 's/\.ql/\.pl/g' ` \
+	Makefile init demoi 
+
+BDD = chop.ql diag.ql bdditl.ql bddcomp.ql ex.ql cp.ql
+bdd:	
+	rm -f $(WORK)
+	touch $(WORK)
+	make M=$(M) $(BDD)
+	echo '?-load($(M)['$(BDD)']).' | \
+	sed -e 's/\.ql//g' -e 's/ *$$//' -e 's/ /,/g' > .tmpa
+
+DISPLAY = display.ql
+display:	
+	rm -f $(WORK)
+	touch $(WORK)
+	make M=$(M) $(DISPLAY)
+	echo '?-load($(M)['$(DISPLAY)']).' | \
+	sed -e 's/\.ql//g' -e 's/ *$$//' -e 's/ /,/g' > .tmpa
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/bddcomp.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,319 @@
+/*
+ Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+                                  The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+ $Id$
+*/
+
+% itl decomposition for DST
+
+:- use_module('~/ITL/bdd/sicstus/bdd').
+
+% requires [chop]
+% itl(Predicate,Next,Empty,ConditionLists)
+
+itl(P) :- expand(P,P0),
+	moref(Ev),itl(P0,Next,Ev,[],C),
+	write(([Ev|C]->Next)),nl,fail.
+itl(_).
+itl(P,Next,[Ev|C]) :- moref(Ev),itl(P,Next,Ev,[],C).
+
+moref(empty).
+moref(more).
+
+itl(N,F,E,C,C1):-integer(N),!,
+	bdd2itl1(N,Term),!,itl(Term,F,E,C,C1).
+itl(true,true,_,C,C):-!.
+itl(false,false,_,C,C):-!.
+itl(more,false,empty,C,C).
+itl(more,true,E,C,C):-!,E = more.
+% next two rule determines descrete time
+itl(empty,true,empty,C,C).      
+itl(empty,false,E,C,C):-!,E = more.  % no succeeding more interval
+itl(P,FF,_,C,C1) :- atomic(P),!, local(FF,P,C,C1).
+    local(true,P,C,C1):- true(C,P,C,C1).
+       true([],P,C,[P|C]):-!.
+       true([P|_],P,C,C):-!.
+       true([not(P)|_],P,_,_):-!,fail.
+       true([_|T],P,C,C1):-true(T,P,C,C1).
+    local(false,P,C,C1):- false(C,P,C,C1).
+       false([],P,C,[not(P)|C]):-!.
+       false([P|_],P,_,_):-!,fail.
+       false([not(P)|_],P,C,C):-!.
+       false([_|T],P,C,C1):-false(T,P,C,C1).
+itl(@(P),P,more,C,C).		   % strong next
+itl(@(_),false,E,C,C):-!,E=empty.
+
+itl(?(Cond,T,F),N,E,C,C1):-!,
+	itl(Cond,CN,E,C,C0),itl_cond(CN,T,F,N,E,C0,C1).
+itl_cond(true,T,_,N,E,C,C1) :-!,
+	itl(T,N,E,C,C1).
+itl_cond(false,_,F,N,E,C,C1) :-!,
+	itl(F,N,E,C,C1).
+itl_cond(CN,T,F,N,E,C,C1) :-!,
+	itl(T,TN,E,C,C0),
+	itl(F,FN,E,C0,C1), negate(CN,NCN),
+	and(TN,CN,N1),and(FN,NCN,N2), or(N1,N2,N).
+
+% Quantifier
+itl(exists(P,Q),F,E,C,C0) :-!,
+	itl(Q,QT,E,[P|C],C1),itl_ex(QT,Q,E,P,F,C1,C0).
+    itl_ex(true,_,_,P,true,C,C1):-!,remove_p(C,P,C1).
+    itl_ex(false,Q,E,P,F,C,C0):-  !,remove_p(C,P,C1),
+    	itl(Q,QF,E,[not(P)|C1],C2),remove_p(C2,P,C0), exists(QF,P,F).
+    itl_ex(QT,Q,E,P,F,C,C0):- remove_p(C,P,C1),
+    	itl(Q,QF,E,[not(P)|C1],C2), remove_p(C2,P,C0),
+        or(QT,QF,TF),exists(TF,P,F).
+    % constant order optimzation for quantifier
+    exists(P,P,true):-!.
+    exists(P,_,P):-atomic(P),!.
+    exists(Q,P,exists(P,Q)).
+    remove_p([],_,[]):-!.
+    remove_p([not(P)|T],P,T):-!.
+    remove_p([P|T],P,T):-!.
+    remove_p([H|T],P,[H|T1]):-!,remove_p(T,P,T1).
+itl(*(P),F,empty,C,C1):-!,itl(P,F,empty,C,C1).
+itl(*(P),F,E,C,C1):-!,E=more,
+	itl(P,PX,more,C,C1),
+	closure(PX,P,F).
+    closure(false,_,false):-!.
+    closure(PX,P,(PX & *(P))).              %% infinite clousre (strong)
+%%    closure(PX,P,(PX & (*(P);empty))).    %% finite closure (weak)
+%% external state diagram
+itl(st(N),F,E,C,C1):-!,
+        setof((Cond=>X),st(N,Cond,X),L),itl_transition(L,F,E,C,C1).
+    itl_transition([],false,_,C,C):-!.
+    itl_transition([(Cond=>empty)|T],F,E,C,C1):-!,
+        itl((empty,Cond),F0,E,C,C0),
+        itl_transition(T,F1,E,C0,C1),or(F0,F1,F).
+    itl_transition([(Cond=>X)|T],F,E,C,C1):-
+        itl((more,Cond),F0,E,C,C0),
+        itl_transition1(F0,X,T,F,E,C0,C1).
+    itl_transition1(false,_,T,F,E,C,C1):-
+        itl_transition(T,F,E,C,C1).
+    itl_transition1(true,X,T,(st(X);F),E,C,C1):-
+        itl_transition(T,F,E,C,C1).
+%% shared resources or state
+itl(share(L),F,empty,C,C1):-!,
+	exclusive(L,C,C1,true,F).
+itl(share(L),F,more,C,C1):-!,
+	exclusive(L,C,C1,share(L),F).
+    exclusive([],C,C,F,F):-!.
+    exclusive([A|L],C,C1,F,F1):-
+	true(C,A,C,C0),exclusive1(L,C0,C1,F,F1).
+    exclusive([N|L],C,C1,F,F1):-
+	false(C,N,C,C0), !,exclusive(L,C0,C1,F,F1).
+%    exclusive(_,C,C,_,false).   % eliminate this brach
+    exclusive1([],C,C,F,F):-!.
+    exclusive1([H|L],C,C1,F,F1):-
+	false(C,H,C,C0), !,exclusive1(L,C0,C1,F,F1).
+%    exclusive1(_,C,C,_,false).
+%%
+itl((P,Q),N,E,C,C1) :-!,
+	itl(P,PN,E,C,C0),itland(PN,Q,N,E,C0,C1).
+itland(false,_,false,_,C0,C0):-!.
+itland(true,Q,QN,E,C0,C1):-!,itl(Q,QN,E,C0,C1).
+itland(PN,Q,N,E,C0,C1):-
+	itl(Q,QN,E,C0,C1),and(PN,QN,N).		%% and/3 in chop.pl
+itl((P;Q),N,E,C,C1) :-!,
+	itl(P,PN,E,C,C0),itlor(PN,Q,N,E,C0,C1).
+itlor(true,_,true,_,C0,C0):-!.
+itlor(false,Q,QN,E,C0,C1):-!,itl(Q,QN,E,C0,C1).
+itlor(PN,Q,N,E,C0,C1):-
+	itl(Q,QN,E,C0,C1),or(PN,QN,N).		%% or/3 in chop.pl
+itl(not(P),NN,E,X,X1) :- !,
+	itl(P,N,E,X,X1),
+	negate(N,NN).				%% negate/2 in chop.pl
+% F = empty?(P,Q):(empty(P)*more(Q)+more(PM)&Q)
+itl((P&Q),F,empty,C,C1) :-!,
+	itl((P,Q),F,empty,C,C1).
+itl((P&Q),F,more,C,C2) :-!,
+	itl(P,PE,empty,C,C0),
+	itl(P,PM,more,C0,C1),
+	chop(PM,PE,F,Q,C1,C2).
+
+chop(false,false,false,_,C,C):-!.
+chop(PM,false,(PM & Q),Q,C,C):-!.
+chop(PM,true,F,Q,C,C1):-!,
+    itl(Q,QF,more,C,C1),
+    chop1(PM,QF,Q,F).
+chop(PM,PE,F,Q,C,C):-!,
+	write('next empty conflict:'),write((PM,PE,F,Q,C)),nl,!,
+	fail.
+
+chop1(false,QF,_,QF):-!.
+chop1(false,false,_,false):-!.
+chop1(PM,false,Q,(PM&Q)):-!.
+chop1(_,true,_,true):-!.
+chop1(PM,QF,Q,(QF;(PM&Q))):-!.
+
+itl(proj(_,Q),F,empty,C,C1) :-!,
+	itl(Q,F,empty,C,C1).
+itl(proj(P,Q),F,more,C,C1) :-!,
+	itl(P,PM,more,C,C0),
+	itl(Q,QM,more,C0,C1),
+	prj(PM,QM,P,F).
+prj(false,_,_,false):-!.
+prj(_,false,_,false):-!.
+prj(PM,QM,P,(PM&proj(P,QM))).
+
+itl(prefix(P),F,empty,C,C1) :-!,
+	itl(P,PE,empty,C,C0),
+	itl(P,PM,more,C0,C1),
+	prefix(PM,PE,F).
+itl(prefix(P),F,more,C,C1) :-!,
+	itl(P,PM,more,C,C1),
+	prefix(PM,F).
+
+prefix(true,true):-!.
+prefix(false,false):-!.
+prefix(PM,prefix(PM)):-!.
+
+prefix(true,_,true):-!.
+prefix(_,true,true):-!.
+prefix(false,false,false):-!.
+prefix(_,false,true):-!.
+
+itl(Def,_,_,_,_) :-
+    write('error: '),write(Def),nl,!,fail.
+
+% develop Local ITL formula into state diagram
+%
+% Mon May 20 17:24:23 BST 1991
+% require([chop]).
+
+:-dynamic verbose/0,state/2,links/2.
+:-dynamic stay/3,lazy/0.
+
+:-assert(verbose).
+verbose(off) :- retract(verbose),fail;true.
+verbose(on) :- asserta(verbose).
+
+lazy(off) :- retract(lazy),fail;true.
+lazy(on) :- asserta(lazy).
+
+% A \= A :-!,fail.
+% _ \= _.
+
+deve(ITL) :-
+	init,!,
+	expand(ITL,ITL0),		% chop standard form
+	itl2bdd(ITL0,StdNOW),		% BDD
+	assert(itl_state(StdNOW,1)),!,  % Initial State
+	deve0((1,StdNOW)).
+
+deve0((S,ITL)) :-
+        show_state(S,ITL),
+	setof(Next,itldecomp(ITL,Next,S),
+	    Nexts),!,
+	deve1(Nexts).
+deve0(_).
+
+deve1([]).
+deve1([H|T]) :- deve0(H),deve1(T).
+
+itldecomp(ITL,(NextS,StdNext),From) :-
+	init_var(current,From),
+	itl(ITL,Next,Cond),
+	%% showing
+	itlshow(Next,NextS,Cond,From,StdNext).
+
+itlshow(Next,S,Cond,From,StdNext):-
+	itl2bdd(Next,StdNext),
+	check_state(StdNext,Cond,New,S),
+	(lazy,!;assertz(state(From,Cond,S))),
+	(links(S,From),!;assertz(links(S,From))),
+	!,
+	itlshow0(S,Cond,StdNext,New).
+
+itlshow0(S,Cond,Next,New) :- verbose,!,
+	itlshow1(S,Cond,Next,New),nl,!,New=1.
+itlshow0(0,_,_,0):- !,put("e"),!,fail.
+itlshow0(false,_,_,0):- !,put("f"),!,fail.
+itlshow0(true,_,_,0):- !,put("t"),!,fail.
+itlshow0(_,_,_,0):- !,put("."),!,fail.
+itlshow0(S,_,_,1):- !,write(S),put("."),ttyflush,!.
+
+itlshow1(0,Cond,_,_):-!,
+	write(Cond),write('->'),write(empty).
+itlshow1(true,Cond,_,_):-!,
+	write(Cond),write('->'),write(true).
+itlshow1(false,Cond,_,_):-!,
+	write(Cond),write('->'),write(false).
+itlshow1(S,Cond,_,0):-!,
+	write(Cond),write('->'),write(S).
+itlshow1(S,Cond,Org,1):-
+	write(Cond),write('->'),write(S),
+	bdd2itl(Org,S1),put(9),write(S1),!.
+
+lazy_state(From,Cond,S) :-
+	links(S,From),
+	itl_state(ITL,From),
+	itl(ITL,Next,Cond),
+	itl2bdd(Next,StdNext),
+	check_state(StdNext,Cond,_,S).
+
+init :-
+	subterm_init,
+	abolish(state,3),
+	asserta((state(true,[more],true):-!)),
+	asserta((state(true,[empty],0):-!)),
+	(lazy,assertz((state(A,B,C) :- lazy_state(A,B,C))),!;true),
+        abolish(itl_state,2),
+        abolish(stay,3),asserta(stay(0,0,0)),
+	bdd:zero(F), bdd:one(T),
+        asserta(itl_state(F,false)),
+        asserta(itl_state(empty,0)),
+        asserta(itl_state(T,true)),
+	abolish(links,2),asserta(links(true,true)),
+	init_var(itl_state_number,1),!.
+
+show_state(S,ITL) :-
+	bdd2itl(ITL,ITL0),
+	nl,write('state('),write(S),  % (
+	(verbose,write(' , '), write(ITL0),write(')'),nl;write(')')),!.
+
+check_state(true,[more |_],0,true):-!.
+check_state(true,[empty|_],0,0):-!.
+check_state(false,_,0,-2):-!.
+check_state(STD,_,0,S):-
+	itl_state(STD,S),!.
+check_state(STD,_,1,S):-
+	inc_var(itl_state_number,S),
+	assert(itl_state(STD,S)),!.
+
+init_var(X,_) :- functor(F,X,1),assert(F),fail.
+init_var(X,_) :- functor(F,X,1),retract(F),fail.
+init_var(X,V) :- functor(F,X,1),arg(1,F,V),assert(F),!.
+inc_var(Name,X1) :- 
+	functor(F,Name,1),retract(F),arg(1,F,X),
+	X1 is X+1,functor(F1,Name,1),arg(1,F1,X1),
+	asserta(F1),!.
+
+increment_state(stay(P,now),stay(P,S),S) :- !,
+      (stay(P,F,S);assertz(stay(P,F,S))),!.
+increment_state(N,N,_) :- atomic(N),!.
+increment_state(P,R,S) :- functor(P,H,N),functor(R,H,N),
+      increment_state_arg(N,P,R,S).
+increment_state_arg(0,_P,_R,_):-!.
+increment_state_arg(N,P,R,S):-arg(N,P,PA),arg(N,R,RA),
+      N1 is N-1,increment_state(PA,RA,S),
+      increment_state_arg(N1,P,R,S).
+
+itl_statistics :- nl,
+	itl_state_number(X),write(X),write(' states'),nl,fail.
+itl_statistics :- 
+        sbn(X),write(X),write(' subterms'),nl,fail.
+itl_statistics :- 
+        init_var(tmp,0),
+        ((links(_,_),inc_var(tmp,_),fail);true),
+        tmp(N),
+        write(N),write(' state transitions'),nl,fail.
+itl_statistics.
+
+%% end %%
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/bddi	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,47 @@
+% Sat May 22 11:43:11 JST 1993
+
+:- use_module('~/ITL/bdd/sicstus/bdd').
+
+:-  module(lite,[
+	ex/1,  			% ex(ITL)   verification predicate
+	ex/2,			% ex(No,Example)
+	diag/1,diag/0, 		% find counter example
+	exe/1, exe/0,		% find sample execution
+	verbose/1, 		% verbose mode
+	lazy/1,			% lazy mode (dvcomp only)
+	kiss/0, 		% kiss format geneartion
+	read_kiss/1,		% read KISS2 format
+	read_kiss/4,		% read KISS2 format
+	read_kiss/3,		% read KISS2 format
+	tgen/0, 		% tokio clause geneartion
+	itl/1,			% one step tableau expansion
+	itl/3,			%     " in detail
+	itl_statistics/0,  	% show number of state etc. 
+	st/3,			% external state machine
+	st_variables/2,		%     its variables
+	sbterm/0,		% show sub term/ state database
+	display/0, large/0, small/0, 	% show state database
+	start/0, display_diag/1, display_exe/1,
+	state/0 		% show state database
+]).
+
+:- [op].
+
+:-
+  unix(system('make tmpa M=lite:')),
+  ['.tmpc'],
+  unix(system('make bdd M=lite:')),
+  ['.tmpc'].
+
+make :- unix(system('make M=lite: bdd')),consult(lite:['.tmpc','.tmpl']).
+
+:- ensure_loaded([chop,diag,kiss,ex,cp]).
+:- ensure_loaded([bdditl,bddcomp]).
+
+% :-start.
+% :-display.
+% display(Host) :- start(Host),display.
+
+% end
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/bdditl.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,143 @@
+%
+/*
+ Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+                                  The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+ $Id$
+*/
+% ITL subterm standarization with BDT
+%
+% a standard form of ITL, based on subterm classification
+%
+%
+
+% :- use_module('~/ITL/tableau/lite').
+:- use_module('~/ITL/bdd/sicstus/bdd').
+% :-op(900,xfy,(&)).
+
+eitl2bdd(X,Y) :-
+	lite:expand(X,X1),itl2bdd(X1,Y).
+eb(X,Y) :- ex(X,X1),eitl2bdd(X1,Y).
+
+subterm_init :- 
+	(bdd:manager(0);bdd:quit),!,bdd:init,
+	abolish(sb,2),
+	abolish(sbn,1),assertz(sbn(2)),
+	bdd:zero(F),assertz(sb(false,F)), % this is wrong...
+	bdd:one(T),assertz(sb(true,T)).
+
+subterm_check(I,J) :-
+	sb(I,Jid),bdd:var_with_id(Jid,J),!.
+subterm_check(I,N1) :-
+	bdd:new_var_first(N1),bdd:if_id(N1,N1id),
+	retract(sbn(M)),M1 is M+1,asserta(sbn(M1)),
+	assertz(sb(I,N1id)),!.
+
+% BDD classification of subterm
+
+itl2bdd(true,T):-!,bdd:one(T).
+itl2bdd(false,F):-!,bdd:zero(F).
+itl2bdd(P,F) :- integer(P),!,bdd:unfree(P),P=F.  % bdd
+itl2bdd(P,F) :- atom(P),!,subterm_check(P,F).
+itl2bdd(?(C,T,F),N) :- !,
+	itl2bdd(C,C1),itl2bdd(T,T1),itl2bdd(F,F1),
+	bdd:ite(C1,T1,F1,N),bdd:free(C1),bdd:free(T1),bdd:free(F1).
+itl2bdd(not(P),F) :- !,itl2bdd(P,F0),bdd:not(F0,F),bdd:free(F0).
+itl2bdd((P,Q),F) :- !,
+	itl2bdd(P,P0),itl2bdd(Q,Q0),
+	bdd:and(P0,Q0,F),bdd:free(P0),bdd:free(Q0),!.
+itl2bdd((P;Q),F) :- !,
+	itl2bdd(P,P0),itl2bdd(Q,Q0),
+	bdd:or(P0,Q0,F),bdd:free(P0),bdd:free(Q0),!.
+itl2bdd((P&Q), N) :-!,
+	itl2bdd(P,P1),itl2bdd(Q,Q1),
+	subterm_check((P1&Q1),N).
+itl2bdd(exists(P,Q), N) :-!,
+	itl2bdd(Q,QF), itl2bdd(P,PF),
+	subterm_check(exists(PF,QF),N).
+itl2bdd(proj(P,Q), N) :-!,
+	itl2bdd(Q,QF),itl2bdd(P,PF),
+	subterm_check(proj(PF,QF),N).
+itl2bdd(prefix(P), N) :-!,
+	itl2bdd(P,PF),
+	subterm_check(prefix(PF),N).
+% Simple Functor including Regular variable and state
+itl2bdd(Func,N) :- functor(Func,H,1),!,functor(F0,H,1),
+	arg(1,Func,A),itl2bdd(A,A0),arg(1,F0,A0),
+	subterm_check(F0,N).
+itl2bdd(Func,N) :- functor(Func,H,2),!,functor(F0,H,2),
+	arg(1,Func,A),itl2bdd(A,A0),arg(1,F0,A0),
+	arg(2,Func,B),itl2bdd(B,B0),arg(2,F0,B0),
+	subterm_check(F0,N).
+itl2bdd(Def,true) :-
+    write('bdditl error: '),write(Def),nl.
+
+subterm :-
+	listing(sb/2).
+
+bdd2itl(B,F) :- integer(B),!,
+	bdd:type(B,I),bdd2itl(I,B,F).
+bdd2itl(B,F) :- atom(B),!,F=B.
+bdd2itl(B,F) :- 
+	functor(B,H,N),functor(F,H,N),bdd2itl_subterm(N,N,B,F).
+
+bdd2itl_subterm(F,B) :- bdd:if_id(B,Bid),sb(F0,Bid),
+	functor(F0,H,N),functor(F,H,N),
+	bdd2itl_subterm(N,N,F0,F).
+bdd2itl_subterm(0,_,_,_) :- !.
+bdd2itl_subterm(N,N1,F,F0) :-
+	N0 is N-1,
+	arg(N,F,A),arg(N,F0,A0),
+	bdd2itl(A,A0),bdd2itl_subterm(N0,N1,F,F0).
+
+% BDD Type analysis 
+bdd2itl(0,B,OPT) :- !, % nonterminal
+	bdd:if(B,IF0),bdd2itl_subterm(IF,IF0),
+	bdd:then(B,THEN0),bdd2itl(THEN0,THEN),
+	bdd:else(B,ELSE0),bdd2itl(ELSE0,ELSE),
+	bdd2itl_opt(IF,THEN,ELSE,OPT).
+% little more readable representation
+    bdd2itl_opt(IF,true,false,IF) :- !.
+    bdd2itl_opt(IF,false,true,not(IF)) :- !.
+    bdd2itl_opt(IF,true,ELSE,(IF;ELSE)) :- !.
+    bdd2itl_opt(IF,THEN,false,(IF,THEN)) :- !.
+    bdd2itl_opt(IF,false,ELSE,(not(IF);ELSE)) :- !.
+    bdd2itl_opt(IF,THEN,true,(not(IF),THEN)) :- !.
+    bdd2itl_opt(IF,THEN,ELSE,?(IF,THEN,ELSE)) :- !.
+bdd2itl(1,_,false) :- !. % zero
+bdd2itl(2,_,true) :- !. % one
+bdd2itl(3,B,F) :- !, % posvar
+	bdd2itl_subterm(F,B).
+bdd2itl(4,B,not(F)) :- !, % negvar
+	bdd:not(B,B1),bdd2itl_subterm(F,B1).
+bdd2itl(5,_,overflow) :- !. % overflow
+bdd2itl(6,_,constant) :- !. % constant (mtbdd)
+
+% Depth One Expansion
+
+bdd2itl1(B,F) :- integer(B),!,
+	bdd:type(B,I),bdd2itl1(I,B,F).
+bdd2itl1(B,F) :- atom(B),!,F=B.
+bdd2itl1(B,B).
+
+% BDD Type analysis 
+bdd2itl1(0,B,?(IF,THEN,ELSE)) :- !, 	% nonterminal
+	bdd:if_id(B,IF0id),sb(IF,IF0id),
+	bdd:then(B,THEN),
+	bdd:else(B,ELSE).    		% no use of opt
+bdd2itl1(1,_,false) :- !. 		% zero
+bdd2itl1(2,_,true) :- !. 		% one
+bdd2itl1(3,B,F) :- !, 			% posvar
+	bdd:if_id(B,Bid),sb(F,Bid).
+bdd2itl1(4,B,not(F)) :- !, % negvar
+	bdd:not(B,B1),bdd:if_id(B1,B1id),sb(F,B1id).
+bdd2itl1(5,_,overflow) :- !. % overflow
+bdd2itl1(6,_,constant) :- !. % constant (mtbdd)
+
+	
+% BDD end %
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/bdtstd.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,142 @@
+%
+/*
+ Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+                                  The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+ $Id$
+*/
+% ITL subterm standarization with BDT
+%
+% Fri Jun 21 10:32:58 BST 1991
+%
+% a standard form of ITL, based on subterm classification
+%
+%
+subterm_init :- 
+	abolish(sb,2),
+	asserta((sb([],-1))),
+	abolish(sbn,1),
+	asserta(sbn(0)).
+
+std_check(I,J) :-
+	sb(I,J),!.
+std_check(I,N1) :-
+	retract(sbn(N)),N1 is N+1,asserta(sbn(N1)),
+	assertz(sb(I,N1)),!.
+
+itlstd(P,List) :- 
+	sbdt(P,List).
+
+% BDT classification of subterm
+
+sbdt(true,true):-!.
+sbdt(false,false):-!.
+sbdt(P,F) :- atomic(P),!,F= ?(P,true,false).
+sbdt(?(C,T,F),?(C,T,F)) :- !.
+sbdt(not(P),F) :- !,sbdt(P,F0),sbdt_not(F0,F),!.
+   sbdt_not(true,false).
+   sbdt_not(false,true).
+   sbdt_not(F,?(H,A1,B1)):-
+   	arg(1,F,H),arg(2,F,A),arg(3,F,B),
+   	sbdt_not(A,A1),sbdt_not(B,B1).
+sbdt((P,Q),F) :- !,
+	sbdt(P,P0),sbdt(Q,Q0),
+	sbdt_and(P0,Q0,F),!.
+   sbdt_and(false,_,false):-!.
+   sbdt_and(_,false,false):-!.
+   sbdt_and(true,T,T):-!.
+   sbdt_and(T,true,T):-!.
+   sbdt_and(P,Q,R) :-!,
+   	arg(1,P,PF),arg(1,Q,QF),
+   	sbdt_and(PF,QF,P,Q,R).
+   sbdt_and(PF,QF,P,Q,R):-PF @< QF,!,
+   	sbdt_and(QF,PF,Q,P,R).
+   sbdt_and(PF,QF,P,Q,?(QF,R0,R1)):-PF @> QF,!,
+   	arg(2,Q,Q0),arg(3,Q,Q1),
+   	sbdt_and(Q0,P,R0),
+   	sbdt_and(Q1,P,R1).
+   sbdt_and(PF,PF,P,Q,?(PF,R0,R1)):-
+   	arg(2,P,P0),arg(3,P,P1),
+   	arg(2,Q,Q0),arg(3,Q,Q1),
+   	sbdt_and(P0,Q0,R0),
+   	sbdt_and(P1,Q1,R1).
+sbdt((P;Q),F) :- !,
+	sbdt(P,P0),sbdt(Q,Q0),
+	sbdt_or(P0,Q0,F),!.
+   sbdt_or(true,_,true):-!.
+   sbdt_or(_,true,true):-!.
+   sbdt_or(false,T,T):-!.
+   sbdt_or(T,false,T):-!.
+   sbdt_or(P,Q,R) :-!,
+   	arg(1,P,PF),arg(1,Q,QF),
+   	sbdt_or(PF,QF,P,Q,R).
+   sbdt_or(PF,QF,P,Q,R):-PF @< QF,!,
+   	sbdt_or(QF,PF,Q,P,R).
+   sbdt_or(PF,QF,P,Q,?(QF,R0,R1)):-PF @> QF,!,
+   	arg(2,Q,Q0),arg(3,Q,Q1),
+   	sbdt_or(Q0,P,R0),
+   	sbdt_or(Q1,P,R1).
+   sbdt_or(PF,PF,P,Q,?(PF,R0,R1)):-
+   	arg(2,P,P0),arg(3,P,P1),
+   	arg(2,Q,Q0),arg(3,Q,Q1),
+   	sbdt_or(P0,Q0,R0),
+   	sbdt_or(P1,Q1,R1).
+sbdt((P&Q), ?(N,true,false)) :-!,
+	sbdt(P,P1),sbdt(Q,Q1), % projection touch later part of chop
+	std_check((P1&Q1),N).
+%sbdt(@(Q), ?(N,true,false)) :-!,   % Don't check next part now
+%	std_check(@(Q),N).          %   this makes everything very slow
+%sbdt(*(Q), ?(N,true,false)) :-!,   % Don't check next part now
+%	std_check(*(Q),N).          %   this makes everything very slow
+%sbdt(free_fin(Q), ?(N,true,false)) :-!,
+%	std_check(free_fin(Q),N).
+% bottom up development is effective for quantifier
+sbdt(exists(P,Q), ?(N,true,false)) :-!,
+	sbdt(Q,QF),
+	std_check(exists(P,QF),N).
+sbdt(proj(P,Q), ?(N,true,false)) :-!,
+	sbdt(Q,QF),     % P part is fixed
+	std_check(proj(P,QF),N).
+sbdt(prefix(P), ?(N,true,false)) :-!,
+	sbdt(P,PF),     % P part is fixed
+	std_check(prefix(PF),N).
+% Simple Functor including Regular variable and state
+sbdt(Func,F) :- functor(Func,_,1),!,F= ?(N,true,false),
+	std_check(Func,N).
+sbdt(Func,F) :- functor(Func,_,2),!,F= ?(N,true,false),
+	std_check(Func,N).
+sbdt(Def,true) :-
+    write('bdtstd error: '),write(Def),nl.
+
+sbterm :-
+	listing(sb/2),listing(itl_state/2).
+
+
+bdt2itl(B,F) :- number(B),!,sb(F0,B),
+	bdt2itl(F0,F).
+bdt2itl(?(IF,THEN,ELSE),F) :-
+	bdt2itl(IF,IF0),bdt2itl(THEN,THEN0),bdt2itl(ELSE,ELSE0),
+	bdt2itl_opt(IF0,THEN0,ELSE0,F).
+% little more readable representation
+    bdt2itl_opt(IF,true,false,IF) :- !.
+    bdt2itl_opt(IF,false,true,not(IF)) :- !.
+    bdt2itl_opt(IF,true,ELSE,(IF;ELSE)) :- !.
+    bdt2itl_opt(IF,THEN,false,(IF,THEN)) :- !.
+    bdt2itl_opt(IF,false,ELSE,(not(IF);ELSE)) :- !.
+    bdt2itl_opt(IF,THEN,true,(not(IF),THEN)) :- !.
+    bdt2itl_opt(IF,THEN,ELSE,?(IF,THEN,ELSE)) :- !.
+bdt2itl(B,F) :- atom(B),!,F=B.
+bdt2itl(B,F) :- 
+	functor(B,H,N),functor(F,H,N),bdt2itl_subterm(N,N,B,F).
+    bdt2itl_subterm(0,_,_,_) :- !.
+    bdt2itl_subterm(N,N1,F,F0) :-
+	N0 is N-1,
+	arg(N,F,A),arg(N,F0,A0),
+	bdt2itl(A,A0),bdt2itl_subterm(N0,N1,F,F0).
+
+% BDT end %
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/cad.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,31 @@
+specification(Z=f(X),
+   while(more,((
+     Z=X,
+     (
+	 (X->(
+	     repeat((skip&(Z=X,empty)),until,not(X)) &
+	     repeat((skip&(Z=not(X),empty)),until,not(X))))
+         ,
+         (not(X)->(
+	     repeat((skip&(Z=not(X),empty)),until,not(X))))
+     )
+    & skip
+    )))
+).
+
+implementation(Z=f(X),
+    exists(y,(
+    not(y),
+    [](
+           (
+	   next(y) = ((not(X),not(y));(X,y)),
+	   Z = ((X,not(y);(not(X),y)))
+           )
+      )
+    ))
+).
+
+?- specification(z=f(x),Y),ex((trace(x,[1,1,0,1,1,1,0,0,1,0,1]),Y)).
+
+?- speficication(z=f(x),S),implementation(z=f(x),I),
+   ex(I->fin_free(S)).
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/call	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,13 @@
+:-[lite:op].
+:-fcompile(lite:'bdtstd.pl').
+:-fcompile(lite:'chop.pl').
+:-fcompile(lite:'cp.pl').
+:-fcompile(lite:'diag.pl').
+:-fcompile(lite:'dvcomp.pl').
+:-fcompile(lite:'ex.pl').
+:-fcompile(lite:'exdev.pl').
+:-fcompile(lite:'gi_ex.pl').
+:-fcompile(lite:'kiss.pl').
+:-fcompile(lite:'kiss_ex.pl').
+:-fcompile(lite:'op.pl').
+:-fcompile(lite:'rstd.pl').
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/chop.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,172 @@
+/*
+ Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+                                  The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+ $Header$
+*/
+:-dynamic define/2.
+% ITL chop standard form
+% requires ndcomp
+
+def(~(P),not(P)).				% not
+def((P->Q),(not(P);Q)).				% imply
+def(P<->Q,((not(P);Q),(P; not(Q)))).		% equiv
+def(P=Q,((not(P);Q),(P; not(Q)))).		% equiv 
+def((P && Q),((not(empty),P) & Q)).		% strong chop
+def('<>'(Q),(true & Q)).			% sometime
+def('#'(Q), not(true & not(Q))).		% always
+def('[]'(Q), not(true & not(Q))).		% always
+def('[a]'(Q), not(true & not(Q) & true)).	% always with arbitary fin
+def('<a>'(Q), (true & Q & true)).	% sometime with arbitary fin
+def(fin(Q),(true & (empty,Q))).			% final state in the interval
+def(keep(Q), not(true & not((empty ; Q)))).	% except final state
+def(halt(Q), '[]'(empty=Q)).	
+def(more, not(empty)).				% non empty interval
+% discrete stuff
+def(skip, @(empty)).				% 1 length interval
+def(infinite, (true & false)).			% 
+def(finite, ~((true & false))).			% 
+def(length(I), X):- I>=0 ,def_length(I,X).	% length operator
+    def_length(I,empty):-I=<0,!.
+    def_length(I,@ X):-I1 is I-1,def_length(I1,X).
+def(less(I), X):- I>=0 ,def_less(I,X).		% less than N length
+    def_less(I,false):-I=<0,!.
+    def_less(I,next(X)):-I1 is I-1,def_less(I1,X).
+def(next(P),(empty; @(P))).
+% temporal assignments
+def(gets(A,B),keep(@A<->B)).
+def(stable(A),keep(@A<->A)).
+def(state(A),(share(A),'[]'(L))):- def_state(A,L).
+    def_state([H],H):-!.
+    def_state([H|L],(H;L1)):-def_state(L,L1).
+% def(Q=>P,exists(R,(Q = R,stable(R),fin(P = R)))).
+%   easier one
+% def(Q=>P,(Q & (empty,P); ~Q & (empty, ~P))).
+% def(P<=Q,Q=>P).
+% loop stuff and quantifiers
+def(+A ,(A & *((empty;A)))).  % weak closure
+def(while(Cond,Do), *(((Cond->Do) , (~Cond->empty)))).
+def(repeat(Do,until,Cond), (*((Do;empty)) ,@ halt(Cond))).
+def(all(P,Q),not(exists(P,not(Q)))):-!,
+	atomic(P).  % more check is necessary
+def(local(P), (P = (P&true))):- !.
+% test predicates
+def(trace(X,List),L) :- !,make_trace(List,X,L).
+    make_trace([],_,true):-!.
+    make_trace([1|T],X,(X,@L)):-!, make_trace(T,X,L).
+    make_trace([true|T],X,(X,@L)):-!, make_trace(T,X,L).
+    make_trace([0|T],X,(not(X),@L)):-!, make_trace(T,X,L).
+    make_trace([_|T],X,(not(X),@L)):-!, make_trace(T,X,L).
+def(even(P),
+	exists(Q,(Q, keep( @Q = ~Q),'[]'((Q->P))))).
+def(evenp(P),(
+	*(((P,skip) & skip;empty,P)) & (empty;skip)
+)). 
+def(phil(L,R),
+       +('[]'((~L, ~R)) & @ (L, ~R,@ (L,R, @ (R,'[]'( ~L)))) )).
+def(X,Y) :- define(X,Y).
+
+:-dynamic variable/1.
+
+expand(X,Y) :- init_variable,expand1(X,Y).
+
+expand1(V,V) :- var(V),!.
+expand1((P,Q),R) :- !,expand1(P,P1),expand1(Q,Q1),and(P1,Q1,R).
+expand1(st(R),st(R)) :- !,
+	st_variables(In,Out),add_variable(In),add_variable(Out).
+% expand1([P|Q],R) :- !,expand1(P,P1),expand1(Q,Q1),and(P1,Q1,R).
+expand1((P;Q),R) :- !,expand1(P,P1),expand1(Q,Q1),or(P1,Q1,R).
+expand1((P&Q),R) :- !,expand1(P,P1),expand1(Q,Q1),chop_expand1(P1,Q1,R).
+   chop_expand1(false,_,false):-!.
+%   chop_expand1(_,false,false):-!.
+   chop_expand1(true,true,true):-!.
+   chop_expand1(P,Q,(P&Q)):-!.
+expand1(not(Q),NQ):-!,expand1(Q,Q1),negate(Q1,NQ).
+expand1(exists(P,Q),exists(P,Q1)):-
+	nonvar(P),name(P,[X|_]),X = 95,!, % "_"  % reuse it...
+	expand1(Q,Q1).
+expand1(exists(P,Q),exists(P,Q1)):-var(P),!,
+	new_var(P), 
+	expand1(Q,Q1).
+expand1(exists(P,Q),exists(P,Q1)):-!,
+	expand1(Q,Q1).
+expand1([],[]):-!.
+expand1([H|L],?(And,true,?(NAnd,false,true_false))):-!, 
+        % non-deterministic selection
+	expand_list([H|L],L1),
+	all_and(L1,And),
+	all_not(L1,NAnd).
+    expand_list([],[]) :-!.
+    expand_list([H|L],[H1|L1]) :-
+	expand1(H,H1), expand_list(L,L1).
+    all_and([],true):-!.
+    all_and([H|L],F):- all_and(L,F1),and(H,F1,F).
+    all_not([],true):-!.
+    all_not([H|L],F):- all_not(L,F1),negate(H,H1),and(H1,F1,F).
+expand1(^(R),^(R)):-!,           % 2nd order variable
+	add_2var(R).
+expand1(P,R) :- def(P,Q),!,expand1(Q,R).
+expand1(P,P) :- atomic(P),!,     % for empty or skip
+	check_atomic(P).
+  check_atomic(empty):-!.
+  check_atomic(more):-!.
+  check_atomic(true):-!.
+  check_atomic(false):-!.
+  check_atomic(true_false):-!.
+  check_atomic(P) :- name(P,PL),PL=[95|_],!.
+  check_atomic(P) :- add_variable(P). % "_"
+expand1(P,R) :- functor(P,H,N),functor(R,H,N),
+	expand_arg(N,P,R).
+expand_arg(0,_P,_R):-!.
+expand_arg(N,P,R):-arg(N,P,PA),arg(N,R,RA),
+	N1 is N-1,expand1(PA,RA),expand_arg(N1,P,R).
+
+% do not use abolish here to avoid erase dynamic property of variable/1
+init_variable :- retract(variable(_)),fail;true.
+add_variable([]):-!.
+add_variable([X|T]) :- !,add_variable(X),add_variable(T).
+add_variable(X) :- variable(X),!.
+add_variable(X) :- assertz(variable(X)),!.
+variable_list(L) :- setof(X,variable(X),L).
+
+new_var(P) :-
+	(retract(sbn(N));N=1),N1 is N+1,asserta(sbn(N1)),!,
+	name(N1,X),S = 95,name(P,[S|X]). % "_"
+
+add_2var(R) :- length_limit(N),!,
+	add_variable(over(R,N)),
+	add_2var(N,R).
+add_2var(R) :-
+	add_variable(^(R)).
+add_2var(0,R):-!,
+	add_variable(^(R,0)).
+add_2var(N,R):- N1 is N-1,
+	add_variable(^(R,N)),
+	add_2var(N1,R).
+
+and(false,_,false):-!.
+and(_,false,false):-!.
+and(true,T,T):-!.
+and(T,true,T):-!.
+and(T,T,T):-!.
+and(A,B,(A,B)):-!.
+
+or(true,_,true):-!.
+or(_,true,true):-!.
+or(false,T,T):-!.
+or(T,false,T):-!.
+or(T,T,T):-!.
+or(A,B,(A;B)):-!. 
+
+negate(true,false):-!.
+negate(false,true):-!.
+negate(true_false,true_false):-!.
+negate(not(N),N):-!.
+negate(N,not(N)):-!.
+
+/* */
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/cp.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,52 @@
+ 
+
+
+
+
+
+
+
+ 
+
+
+
+
+
+
+
+
+
+
+
+
+
+% A '\=' A :-!,fail.
+% _ '\=' _.
+
+
+
+
+
+
+
+
+
+
+
+
+
+r_cputime(X) :- statistics(runtime,[X1,_]),X is X1/1000.
+
+
+
+
+
+
+
+
+
+append([],X,X).
+append([H|X],Y,[H|Z]) :- append(X,Y,Z).
+
+
+ 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/cppl.c	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,76 @@
+/*
+ Copyright (C) 1988, Shinji Kono 
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+*/
+/* 
+   support routine for compatibilities
+   */
+
+#if defined(SBPROLOG) || defined(XSB)
+lite_start :- ['op.pl'],
+	assert((define(_,_):-fail)),
+	assert((verbose:-fail)),
+	assert((variable(_):-fail)).
+
+start :- lite_start,
+	load('../Tokio/tokio'),
+	['../Tokio/ts.pl'],
+	com('../Tokio/tm.pl',user),
+	r_header.
+
+
+r_cputime(X) :- cputime(X0),X is X0/1000.
+ttyflush.
+#endif
+
+#if defined(SBPROLOG)
+
+'\+'(X) :- call(X),!,fail.
+'\+'(_).
+
+#endif
+
+#if ! defined(XSB)
+A '\=' A :-!,fail.
+_ '\=' _.
+#endif
+
+#if defined (XSB)
+':-'(X) :- call(X),!;true.
+
+#endif
+
+#if defined(CPROLOG) 
+:-abolish(r_cputime,1).
+r_cputime(X) :- X is cputime.
+#endif
+
+#if defined(SICSTUS) 
+r_cputime(X) :- statistics(runtime,[X1,_]),X is X1/1000.
+#if defined(SICSTUSV3) 
+A '\=' A :-!,fail.
+_ '\=' _.
+#endif
+
+#endif
+
+#if defined(CPROLOG) 
+
+
+#if CPROLOG15
+term_expansion(X,X).
+:-unknown(X,trace).
+#endif
+
+:- (ttyflush;assert((ttyflush))).
+#endif
+
+append([],X,X).
+append([H|X],Y,[H|Z]) :- append(X,Y,Z).
+
+
+/* end  */
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/demo.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,18 @@
+:-ensure_loaded('../tableau/liter').
+% :-ensure_loaded('../Tokio/initm').
+% :-fcompile(lite:disp).
+:-ensure_loaded(lite:disp).
+
+% :-com([bou,gi],'tmp.out').
+% :-prolog_flag(single_var_warnings, _, off).
+
+% :-com([bou],'tmp.out').
+
+:-write('To do demonstration,
+Start Lite verifier
+     ?- display.
+Load file gi?.lite.
+Verify it.
+Generate it.
+Run Tokio command toy0.
+').
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/demoi	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,7 @@
+:- use_module(library(gmlib)).
+
+:-[init],compile(display).
+% :-start.
+% :-display.
+
+display(Host) :- start(Host),display.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/demoim	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,25 @@
+% Sat May 22 11:43:11 JST 1993
+
+:- use_module(library(gmlib)).
+
+?-op(900,xfy,[(&),('&&')]).
+?-op(700,xfy,['<->','\=',proj]).
+?-op(60,fy,['~','#','<>', '@',^]).
+?-op(60,fy,[*]).
+
+:-
+  unix(system('make tmpa M=lite:')),
+  ['.tmpc'],
+  unix(system('make display M=lite:')),
+  ['.tmpc'].
+
+make :- unix(system('make M=lite:')),consult(lite:['.tmpc','.tmpl']).
+
+:- use_module(lite).
+:- load(lite:[ex,kiss_ex,display]).
+
+% :-start.
+% :-display.
+% display(Host) :- start(Host),display.
+
+% end
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/diag.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,207 @@
+/*
+ Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+                                  The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+ $Id$
+*/
+
+% develop Local ITL formula into state diagram
+%
+% Mon May 20 17:24:23 BST 1991
+% require([chop]).
+
+ex :- ex1(_).
+
+ex(N) :- number(N),!,ex1(N).
+ex(demo(N)) :- number(N),!,ex1(N).
+ex(X) :- verbose,!,time(deve(X)),itl_statistics,diag,!.
+ex(X) :- time(deve(X)),itl_statistics.
+
+ex1(N) :- ex(N,P),nl,write(P),write('.'),nl,ex(P),fail.
+ex1(_) :- told.
+
+exex :- verbose(off),tell(ex),(
+	ex(_,P),nl,write(P),write('.'),nl,ex(P),itl_statistics,fail;
+	told
+	).
+
+% cputime(X):-statistics(runtime,[X1,_]),!,X is X1/1000.
+% cputime(X):-X is cputime. % for cprolog
+time(X):- r_cputime(T0),call(X),r_cputime(T1),
+	T is T1-T0,
+	nl,write(T),write(' sec.').
+
+state :- listing(state/3),lising(state/4).
+
+% diagnosis
+diag :- diag(X),
+	(X = counter_example(_), write('counter example:'),nl; true),!,
+	write_diag(X).
+
+diag(X) :- number(X),   % at most X length solution
+	links(false,_),    % search false
+	diag_l(false,[],H,X),
+	make_hist(H,Hist),
+	write_diag(counter_example(Hist)).
+diag(valid) :- \+(links(false,_)),!.
+diag(counter_example(Hist)) :-
+	diag_l(false,[],H,0),
+	make_hist(H,Hist).
+
+% execution exapmle.
+exe :- exe(Z),
+	(Z=unsatisfiable, nl,write('unsatisfiable'),nl,!,fail; 
+	nl,write('execution:'),nl,write_diag(Z)).
+
+exe(X) :- number(X),   % at most X length solution
+	possible_root(R),
+	diag_l(R,[],H,X),
+	make_hist(H,Hist),
+	write_diag(execution(Hist)).
+exe(unsatisfiable) :- \+(possible_root(_)),!.
+exe(execution(Hist)) :-
+	possible_root(R),
+	diag_l(R,[],H,0),
+	make_hist(H,Hist).
+
+% possible root is non looping true or 0 node.
+possible_root(true) :-
+	possible_root1(true).
+possible_root(0) :-
+	possible_root1(0).
+
+possible_root1(R) :- links(R,N),\+(N = true),!.
+
+% Log order search
+
+make_hist(S,C) :- detailed,!,
+	S = [P|L],itl_state(P1,P),
+	make_hist1(L,P,P1,[],_,C).
+make_hist(S,C) :- 
+	S = [P|L],
+	make_hist0(L,P,C).
+
+make_hist0([],_,[]):-!.
+make_hist0([D|L],S,[(D->Cond)|L1]):-!,  % step by step
+	state(S,Cond,D),
+	!,  				% 
+	make_hist0(L,D,L1).
+
+% trace 2variable renamings
+
+make_hist1([],_,_,R,R,[]):-!.
+make_hist1([SN|L],S,P,R,R1,[(SN->Cond)|L1]):-!,  % step by step
+	state(S,Cond,SN,P,P1,R,R0),
+	!,
+	make_hist1(L,SN,P1,R0,R1,L1).
+
+
+diag(Hist,P) :-
+	diag_l(P,[],Hist,0).
+
+% try to find interesting example
+% reverse order back track
+diag_ls(Ps,L,L1,D):-member(P,Ps),diag_l(P,L,L1,D).
+
+% one minimum solution
+diag_l(1,L,[1|L],D):-!,D=<0.    % Initial State? Enough depth?
+diag_l(E,L,L1,D) :-
+	setof(P,links(E,P),P1),  % must be minimum first order
+	D1 is D-1,
+	member(P0,P1),
+	diag_l(P0,[E|L],L1,D1).
+
+
+write_diag(counter_example(Hist)) :-!,write_ce(Hist,0).
+write_diag(execution(Hist)) :-!,write_ce(Hist,0).
+	write_ce([],_):-!.
+	write_ce([(S->[E|L])|T],I) :- (E=more,L=L1;E=empty,L=L1;[E|L]=L1),!,
+		write(I),write(:),write_cond(L1),put(9),write(S),nl,
+		J is I+1,
+		write_ce(T,J).
+write_diag(R):-!,write(R),nl.
+
+% condition print
+
+write_cond(X) :- sortC(X,Y),write_cond1(Y).
+write_cond1([]):-!.
+write_cond1([H|T]):-!,write_cond1(H),write_cond1(T).
+write_cond1(not(P)):-!,put(45),  % "-"
+	write(P).
+write_cond1(P):-     !,put(43),  % "+"
+	write(P).
+
+% bubble sort
+sortC([],[]).
+sortC([H|T],[Min|Y]):-
+    min(T,H,Min,Rest),
+    sortC(Rest,Y).
+
+min([],X,X,[]).
+min([H|T],X,Y,[H|S]) :- ord(H,X),!,min(T,X,Y,S).
+min([H|T],X,Y,[X|S]) :- min(T,H,Y,S).
+
+ord(not(X),not(Y)) :- !,X @> Y.
+ord(X,not(Y))  :- !,X @> Y.
+ord(not(X),Y)  :- !,X @> Y.
+ord(X,Y)   :- !,X @> Y.
+
+rev([],X,X).
+rev([H|T],X,Y) :- rev(T,[H|X],Y).
+
+member(H,[H|_]).
+member(H,[_|T]):-member(H,T).
+
+not_member(_,[]):-!.
+not_member(H,[H|_]):-!,fail.
+not_member(H,[_|T]):-not_member(H,T).
+
+count(A) :- count(A,X),write(X),nl.
+count(A, _) :-
+        init_var(tmp, 0),
+        call(A),
+        inc_var(tmp, _),
+        fail.
+count(_, A) :-
+	retract(tmp(A)).
+
+user_help :- write('?-ex(2).'),nl,
+write('?-ex( [](p) -> <> p ).'),nl,
+write('    Verify numbered examples or ITL formula.'),nl,
+write('?-diag.'),nl,
+write('    shows a counter example.'),nl,
+write('?-exe.'),nl,
+write('    This shows an execution of ITL formula.'),nl,
+write('?-diag(N) or ?-exe(N) '),nl,
+write('    shows at least N length examples.  '),nl,
+write('         1: +p-q   means "at clock 1, p is true and q is false". '),nl,
+write('?-verbose(off). '),nl,
+write('    generates one character per state transition condition.'),nl,
+write('     e   empty / t   true / f   false'),nl,
+write('     123. newly genrated state number'),nl,
+write('     .   transition to a registerd state'),nl,
+write('?-verbose(on).'),nl,
+write('    show ITL formula for each state. (Can be Very large)'),nl,
+write('?-start, display.'),nl,
+write('    starts X-Window Interface.'),nl,
+write('?-ex. runs all examples in diag.pl. But it takes several hours.'),nl,
+write('      Some of the examples are quite large.'),nl,
+write('?-kiss.'),nl,
+write('    generates KISS2 format for SIS.'),nl,
+write('?-tgen.'),nl,
+write('    generates Tokio language.'),nl,
+write('?-read_kiss(File,In,Out,Empty).'),nl,
+write('    reads KISS2 format. In and Out are list of variables in the order'),nl,
+write('    of the KISS2 file. '),nl,
+write('?-read_kiss(File).'),nl,
+write('    =>  read_kiss(File,_,_,empty)'),nl,
+write('?-read_kiss(File,Empty).'),nl,
+write('    =>  read_kiss(File,_,_,Empty) '),nl,
+true.
+
+/* end */
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/disp.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,427 @@
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%%
+%% LITE Tcl/Tk interface
+%%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% :- ensure_loaded('../tableau/lite').
+:- module(lite).
+:- use_module(library(tcltk)).
+:- verbose(off).
+
+:- dynamic r_event/2.
+
+:- abolish(show_state,2).
+% Next command keep check event during verification
+show_state(S,ITL) :-!,
+        (tcl_eval(update);true),!,
+	bdt2itl(ITL,ITL1),
+        nl,write('state('),write(S),  % (
+        (verbose,write(' , '), write(ITL1),write(')'),nl;write(')')),!.
+
+event(verbose,'1') :- verbose(on).
+event(verbose,'0') :- verbose(off).
+event(X,Y) :- assertz(r_event(X,Y)).   % ,write((X,Y)),nl.
+event(X) :-   assertz(r_event(X,[])).  % ,write((X)),nl.
+
+next(X,Y) :- r_event(_,_),retract(r_event(X,Y)),!.
+next(X,Y) :- tk_do_one_event(0),!,
+	next(X,Y).
+
+display :-
+	init_display,!,
+	event_loop(run).
+
+init_display :-
+	(retract(r_event(_,_)),fail;true),
+	tk_init('lite',[]),
+%	tcl_eval('source disp.tcl'),
+	tcl_eval('source xf-disp'),
+        all_disable.
+canvas_origin(20,20).
+
+event_loop(quit):-!.
+event_loop(_) :-
+	next(X,Y),execute(X,Y),!,event_loop(X).
+
+execute(verify,X) :- !,
+	verify(X).
+
+% !,X=1 -> verbose(on); verbose(off). causes error
+execute(verbose,X) :- X='1' -> verbose(on); verbose(off).
+execute(map,X) :- !,name(X,L),name(X1,L),view_state(a,X1).
+execute(execute,_) :- !,do_execute,!.
+execute(generate,_) :- !,
+	generate.
+execute(counter,_) :- !,do_diagnosis,!.
+execute(quit,_) :- !. % ,tcl_eval('destroy .').
+execute(prolog_call,X) :- !,prolog_call(X).
+execute(tokio_call,X) :- !,tokio_call(X).
+execute(X,_) :- !,write(event(X)),nl,ttyflush.
+
+generate :-
+	TOKIO = 'tmp.tokio',
+	tell(TOKIO),tgen,told,
+        user:com(TOKIO,'tmp.out').
+gen(X) :- consult(X),specification(Y),ex(Y),generate.
+gen(X) :- 
+	name(X,XL),append(XL,".lite",YL),name(X1,YL),
+	consult(X1),specification(Y),ex(Y),generate.
+
+verify(X) :-
+        all_disable,
+	abolish(st,3),abolish(specification,1),abolish(st_variables,2),
+	t2string(X,X0),s2terms(X0,X1),command(X1,X2,X3),
+	display_contents(X3),
+	ex(X2),!,
+	ttyflush, display_statistics,
+        all_enable.
+verify(_) :-
+        all_disable.
+display_contents(X) :-
+	ttyflush,t2strings(X,XS0),easy_pp(XS0,XS),
+	tcl_eval('$symbolicName(entry) delete 0.0 end'),
+	tcl_eval(['$symbolicName(entry) insert 0.0 {',XS,'}']),
+        display_update.
+
+all_disable :-
+	tcl_eval('$symbolicName(map) configure -state disabled'),
+	tcl_eval('$symbolicName(execute) configure -state disabled'),
+	tcl_eval('$symbolicName(diag) configure -state disabled'),
+	display_update.
+all_enable :-
+	tcl_eval('$symbolicName(map) configure -state normal'),
+	tcl_eval('$symbolicName(execute) configure -state normal'),
+	tcl_eval('$symbolicName(diag) configure -state normal'),
+	display_update.
+
+% Backtrack Control of example/counter example
+
+do_execute :- display_exe('.'),next(X,Y),do_execute(X,Y),!.
+do_execute.
+
+do_execute(execute,_) :-!,
+	fail.
+do_execute(X,Y) :- execute(X,Y),!.
+
+do_diagnosis :- display_diag(','),next(X,Y),do_diagnosis(X,Y),!.
+do_diagnosis.
+
+do_diagnosis(diag,_) :-!,
+	fail.
+do_diagnosis(X,Y) :- execute(X,Y),!.
+
+% :- dynamic specification/1.
+
+% Text Based Commnad
+
+command([st(X,Y,Z)|T],Term,[st(X,Y,Z)|T1]):-!,
+	assertz(st(X,Y,Z)),!,
+	command(T,Term,T1).
+command([specification(X)|T],X,[specification(X)|T1]):-!,
+	command(T,X,T1).
+command([st_variables(X,Y)|T],Term,[st_variables(X,Y)|T1]):-!,
+	assertz(st_variables(X,Y)),
+	command(T,Term,T1).
+command([],true,[]) :-!.
+command([],_,[]) :-!.
+command([H],Term,[Term1]) :-!,
+	command(H,Term),!,Term=Term1.
+command([H|T],(Term1,Terms),[Term1|T1]) :-
+	command(H,Term1),!,command(T,Terms,T1).
+
+command(demo(X),Term):-!,lite:demo(X,Term).   % predefined examples
+command(ex(X),Term):-!,ex(X,Term).
+command(prolog(X,P),X):-!,safe_call(P).
+command(prolog(P),true):-!,safe_call(P).
+command(tokio(P),true):-!,safe_call(tokio(P)).
+command(consult(P),Term):-!,
+	command(file(P),Term).
+command(file(P),Term):-
+	on_exception(Er,(consult(P),specification(Term)),
+           read_error(Term,Er,user,user)).
+command(A,A) :- atomic(A),!.
+command(P,R) :- functor(P,H,N),functor(R,H,N),
+        command_arg(N,P,R).
+command_arg(0,_P,_R):-!.
+command_arg(N,P,R):-arg(N,P,PA),arg(N,R,RA),
+        N1 is N-1,command(PA,RA),command_arg(N1,P,R).
+
+prolog_call(X) :- 
+	t2string(X,X0),s2terms(X0,[X1|_]),safe_call(X1).
+tokio_call(X) :- 
+	t2string(X,X0),s2terms(X0,[X1|_]),safe_call(tokio(X1)).
+
+safe_call(X) :-
+	on_exception(Er,user:call(X),
+           read_error(X,Er,user,user)),!.
+safe_call(_).
+
+:-dynamic font/2.
+
+small :- (retract(font(_,_));true),assert(font("7x14",14)).
+large :- (retract(font(_,_));true),assert(font("12x24",24)).
+
+:-small.
+% font("7x14",14).
+
+width(W,H):-
+   font(_,Fs),
+   W is integer(1000/24*Fs), H is integer(500/24*Fs).
+
+display_statistics :-
+        itl_state_number(S), % number of state
+        itl_transition(L),   % number of transition
+        name(S,Ss),name(L,Ls),
+        append("State: ",Ss,S0),append(S0," Edge:",S1),append(S1,Ls,S2),
+        tcl_eval(["$symbolicName(states) configure -text {",S2,"}"]),!.
+
+%%---------------------------------------------------------------------
+% display_diagnosis
+display_diag(View) :- diag(X),
+	write_display_diag(X,View).
+
+% display_execution exapmle.
+display_exe(View) :- exe(Z),
+	write_display_diag(Z,View).
+
+write_display_diag(counter_example(Hist),View) :-!,display_ce(Hist,View).
+write_display_diag(execution(Hist),View) :-!,display_ce(Hist,View).
+write_display_diag(R,_View):-!,
+	atomic(R),name(R,Text),
+	clear_display,
+	tcl_eval(['$symbolicName(canvas) create text 0 0 -text "',Text,'"']).
+
+% append([],X,X):-!.
+% append([H|X],Y,[H|Z]) :- append(X,Y,Z).
+
+clear_display :-
+	tcl_eval('$symbolicName(canvas) delete all').
+display_ce(Hist,View) :-
+	canvas_origin(OX,OY),
+	font(_,Fs),
+	clear_display,
+	X is OX+Fs/2,Y=OY,W is integer(60/24*Fs),H is integer(60/24*Fs),
+	(variable_list(L);L=[]),append(L,['Time'],L1),!,
+	display_var(['State'|L1],View,X,Y,H,X,X1),
+	X2 is X1+X,
+	display_ce(Hist,L,View,X2,Y,W,H,0). % ,View=>batchmodeoff.
+display_var([],_,_,_,_,X,X):-!.
+display_var([Var|L],View,X,Y,H,X1,X2):- atomic(Var),!,
+	Y1 is Y+H, font(_Fn,Fs),
+	name(Var,VarText),length(VarText,Len0),Len is Len0*Fs,
+	% View=>stringlength(VarText,Len),
+	(X1>X+Len,X3=X1;X3 is X+Len),!,
+	display_string(X,Y,VarText),
+	display_var(L,View,X,Y1,H,X3,X2).
+display_var([Var|L],View,X,Y,H,X1,X2):- 
+	functor(Var,VarH,2),member(VarH,[(^)]),!,
+	arg(1,Var,VarA),arg(2,Var,VarB),
+	% infix operator
+	Y1 is Y+H, font(_Fn,Fs),
+	name(VarH,VarTextH),name(VarA,VarTextA),name(VarB,VarTextB),
+	append(VarTextA,VarTextH,VarText0),
+	append(VarText0,VarTextB,VarText),
+	length(VarText,Len0),Len is Len0*Fs,
+	% View=>stringlength(VarText,Len),
+	(X1>X+Len,X3=X1;X3 is X+Len),!,
+	display_string(X,Y,VarText),
+	display_var(L,View,X,Y1,H,X3,X2).
+display_var([Var|L],View,X,Y,H,X1,X2):- 
+	functor(Var,VarH,2),
+	arg(1,Var,VarA),arg(2,Var,VarB),
+	Y1 is Y+H, font(_Fn,Fs),
+	name(VarH,VarTextH),name(VarA,VarTextA),name(VarB,VarTextB),
+	CB is "(",CE is ")",CC is ",",
+	append(VarTextH,[CB|VarTextA],VarText0),
+	append(VarText0,[CC|VarTextB],VarText1),
+	append(VarText1,[CE],VarText),
+	length(VarText,Len0),Len is Len0*Fs,
+	% View=>stringlength(VarText,Len),
+	(X1>X+Len,X3=X1;X3 is X+Len),!,
+	display_string(X,Y,VarText),
+	display_var(L,View,X,Y1,H,X3,X2).
+
+display_string(X,Y,Text) :-
+	font(Fn,_),
+        name(X,XL),name(Y,YL),
+        tcl_eval(['$symbolicName(canvas) create text ',XL,' ',YL,' -font ',Fn,
+                  ' -text "', Text,'"'
+        ]).
+display_ce([],_,_,_,_,_,_,_):-!.
+display_ce([(S->[_|Cond])|Hist],L,View,X,Y,W,H,T) :-
+	X1 is X+W,Y1 is Y+H,T1 is T+1,
+	name(S,SText),display_string(X1,Y,SText),
+	display_now(L,Cond,View,X1,Y1,W,H,T),
+	display_ce(Hist,L,View,X1,Y,W,H,T1).
+
+display_now([],_,_View,X,Y,_,_,T):-!,
+	name(T,SText),display_string(X,Y,SText).
+display_now([V|Vr],Cond,View,X,Y,W,H,T):-
+	XS is X-H/2,YS is Y-H/2,
+	display_state(Cond,V,View,XS,YS,W,H),
+	Y1 is Y+H,
+	display_now(Vr,Cond,View,X,Y1,W,H,T).
+
+rectangle(1,X,Y,X2,Y2) :-!,
+        name(X,XL),name(Y,YL), name(X2,XL2),name(Y2,YL2),
+        tcl_eval(['$symbolicName(canvas) create rectangle ',
+                  XL,' ',YL,' ', XL2,' ',YL2,' ',
+                 '-stipple gray50 -fill black'
+        ]).
+rectangle(0,X,Y,X2,Y2) :-
+        name(X,XL),name(Y,YL), name(X2,XL2),name(Y2,YL2),
+        tcl_eval(['$symbolicName(canvas) create rectangle ',
+                  XL,' ',YL,' ', XL2,' ',YL2
+        ]).
+display_state([V|_],V,_View,X,Y,W,H) :-!, % true
+	X2 is X+W,Y2 is Y+H,
+	rectangle(1,X,Y,X2,Y2).
+display_state([not(V)|_],V,_View,X,Y,W,H) :-!, % false
+	X2 is X+W,Y2 is Y+H,
+	rectangle(0,X,Y,X2,Y2).
+display_state([_|T],V,View,X,Y,W,H) :-!,
+	display_state(T,V,View,X,Y,W,H).
+display_state([],_,_View,X,Y,W,H) :-!,    % unknown
+	X2 is X+W,Y2 is Y+H/2,Y3 is Y2+3,
+	rectangle(0,X,Y2,X2,Y3).
+
+display_update :- tcl_eval('update').
+
+view_state(View,W) :-
+   itl_state_number(S),
+   clear_display,
+   canvas_origin(OX,OY),
+   calc_view_size(W,S,D,W0),
+%   write(calc_view_size(W,S,D,W0)),nl,
+   W1 is OX + W0 + D, H1 is OY + W0 + D,
+   rectangle(0,OX,OY,W1,H1),
+   view_state_write(View,W0,S,D).
+
+calc_view_size(W,S,D,W1) :-
+   D0 is integer(W/(S+1)),(D0<2,D=2;D=D0),!,
+   W0 is D*(S+1),(W0=<W,!,W1 = W0; W1 is integer(W)),!.
+
+view_state_write(_View,W,S,D) :- 
+   canvas_origin(OX,OY),
+   links(X,Y), link_translate(X,Y,X1,Y1,W,S),
+   X2 is OX+X1+D,Y2 is OY+Y1+D,
+   X11 is OX+X1,Y11 is OY+Y1,
+   rectangle(1,X11,Y11,X2,Y2),
+   display_update,
+   fail.
+view_state_write(_View,_,_,_):-true. 
+
+link_translate(false,Y,X1,Y1,W,S) :- !,
+    link_translate(S,Y,X1,Y1,W,S).
+link_translate(X,false,X1,Y1,W,S) :- !,
+    link_translate(X,S,X1,Y1,W,S).
+link_translate(X,Y,X1,Y1,W,S) :- number(X),number(Y),!,
+    X1 is integer(X*W/(S+1))+1, Y1 is integer(Y*W/(S+1)).
+link_translate(X,_,X1,0,W,S) :- number(X),!,
+    X1 is integer(X*W/(S+1)).
+link_translate(_,Y,0,Y1,W,S) :- number(Y),!,
+    Y1 is integer(Y*W/(S+1)).
+link_translate(_,_,0,0,_,_).
+
+%%
+
+s2term("",true):-!.
+s2term(Text,Term) :-
+	telling(O),
+	tell(tmp),format("~s.~n",[Text]),told,tell(O),
+	seeing(I),
+	see(tmp),on_exception(Er,read(Term),read_error(Term,Er,I,O)),
+	see(tmp),seen,see(I),!.
+s2term(_,true):-tell(tmp),told,see(tmp),seen.
+
+s2terms("",true):-!.
+s2terms(Text,Terms) :-
+	check_period(Text,0,Text1),
+	telling(O),
+	tell(tmp),format("~s~n",[Text1]),told,tell(O),
+	seeing(I),
+	see(tmp),on_exception(Er,s2terms0(Terms),read_error(Terms,Er,I,O)),
+	see(tmp),seen,see(I),!.
+s2terms(_,true):-tell(tmp),told,see(tmp),seen.
+
+s2terms0(Terms) :-read(X),s2terms0(X,Terms).
+s2terms0(end_of_file,[]):-!.
+s2terms0(H,[H|T]):-read(X),s2terms0(X,T).
+
+read_error(true,Er,I,O) :- 
+	tell(tmp),told,see(tmp),seen,
+	see(I),tell(O),    %   unix(system('rm tmp')),
+	write('read error:'),write(Er),nl.
+
+t2string(Term,Text) :-
+	telling(O),
+	tell(tmp),write(Term),told,tell(O),
+	seeing(I),
+	see(tmp),get0(C),read_string(C,Text),see(tmp),seen,see(I),!.
+t2string(_,true):-tell(tmp),told,see(tmp),seen.
+
+t2strings(Terms,Text):-!,
+	telling(O),
+        t2strings(Terms),
+        told,tell(O),
+	seeing(I),
+	see(tmp),get0(C),read_string(C,Text),see(tmp),seen,see(I),!.
+t2strings(_,true):-tell(tmp),told,see(tmp),seen.
+
+t2strings([]):-!.
+t2strings([Term|T]):-!,
+	tell(tmp),write(Term),put("."),put(10),t2strings(T).
+
+read_string(-1,[]) :- !.
+read_string(C,[C|T]) :- 
+	get0(C1),read_string(C1,T).
+
+check_period([],0,[32,46]):-!.
+check_period([],1,[]):-!.
+check_period([46],_,[46]):-!.
+check_period([46,X|T],_,[46,X|T1]):-(X=32;X=10;X=37),!,
+	check_period(T,1,T1).
+check_period([37|T],X,[37|T1]):-
+	skip_line(T,X,T1).
+check_period([X|T],P,[X|T1]):-(X=32;X=10),!,
+	check_period(T,P,T1).
+check_period([X|T],_,[X|T1]):-
+	check_period(T,0,T1).
+
+skip_line([],X,[]):-!,
+	check_period([],X,_).
+skip_line([10|T],X,[10|T1]):-!,
+	check_period(T,X,T1).
+skip_line([_|T],X,T1):-skip_line(T,X,T1).
+
+% sicstus dependent 
+easy_pp(X,X1) :- easy_pp(X,X1,0).
+easy_pp([],[10],_) :- !.
+easy_pp([C|T],[C1,10|T0],_) :- C is ".",!,C1 = C,
+	easy_pp(T,T0,0).
+easy_pp([C|T],[C1,10|T0],N) :- C is ",",!,C1 = C,
+	easy_tab(N,T0,T1),easy_pp(T,T1,N).
+easy_pp([C|T],[C1,10|T0],N) :- C is ";",!,C1 = C,
+	easy_tab(N,T0,T1),easy_pp(T,T1,N).
+easy_pp([C,C|T],[C1,C1,10|T0],N) :- C is "&",!,C1 = C, % &&
+	easy_tab(N,T0,T1),easy_pp(T,T1,N).
+easy_pp([C|T],[C1,10|T0],N) :- C is "&",!,C1 = C,      % &
+	easy_tab(N,T0,T1),easy_pp(T,T1,N).
+easy_pp([C,C1,C2,CB|T],C3,N) :- [C,_,C2,CB]="[a](",!,  % quote '[a]'
+	CQ is "'", C3 = [CQ,C,C1,C2,CQ,CB|T1],
+	easy_pp(T,T1,N).
+easy_pp([10|T],[10|T0],N) :- !,
+	easy_tab(N,T0,T1),easy_pp(T,T1,N).
+easy_pp([Par|T],[Par1|T0],N) :- Par is "(",!,Par1 = Par,
+	N1 is N+1,easy_pp(T,T0,N1).
+easy_pp([Par|T],[Par1|T0],N) :- Par is ")",!,Par1 = Par,
+	N1 is N-1,easy_pp(T,T0,N1).
+easy_pp([H|T],[H|T0],N) :- 
+	easy_pp(T,T0,N).
+
+easy_tab(N,T,T1):-N =< 0,!,T=T1.
+easy_tab(N,[32,32|T],T1) :-
+	N1 is N-1,easy_tab(N1,T,T1).
+
+% end %
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/ex.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,256 @@
+/*
+ Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+                                  The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+ $Id$
+
+ Examples
+*/
+
+ex(0,(p)).
+ex(1,((p&q))).
+ex(2,( (fin(p)&true) <-> '<>'p)).
+ex(3,( fin(p) <-> '[]'( '<>' p) )).
+ex(4,(~(true&q))).
+ex(5,(~(true& ~q))).
+ex(6,(((true& p),(true& q)))).
+ex(7,('[]'((p -> '<>' q)))).
+ex(8,( '<>' '[]'(p))).
+ex(9,( '[]'( '<>'(p)))).
+ex(10,((p && p && p && p && p && ~p && p)-> '[]'('<>'(p)))).
+% weak closure (or finite closure)
+ex(11,+ (a,@ (b,@ (c,@empty)))).
+% quantifier
+ex(12,exists(R,(R,keep(@R = ~R),'[]'((R->p))))).
+% temporal assignment
+ex(13,exists(R,(R = p,keep(@R = R),fin(R = p)))).
+%
+ex(14,
+	exists(Q,(Q, 
+	  '[]'((Q -> 
+	          (((((a,skip) & (b,skip)), @ keep(~Q)) & Q)
+	          ;empty))
+	  )))
+   <->  *(((a,skip) & (b,skip) ; empty))
+).
+ex(15,
+        while(q,((a,skip) & (b,skip)))
+   <->  exists(C,(C, 
+          '[]'(
+             (C -> 
+                  (((q -> ((a,skip) & (b,skip)), @ keep(~C)) & C),
+                    (~q -> empty))
+             ))))
+).
+ex(16,even(p)<->evenp(p)).
+% wrong example, but hard to solve
+% ex(17,(p=>(q=>r)) <-> ((p=>q)=>r)).
+% ex(18,exists(Q,(p=>Q & Q=>r)) <-> (p=>r)).
+% dining philosopher
+%   note: unspecified resource increase states
+%   ex ((true & al,skip & al,ar,skip & ar,~al,skip) ;empty) * 
+ex(19,(more,
+% three philosophers 
+        *( ('[]'((~al, ~ar)) & @ (al, ~ar,@ (al,ar, @ (ar,'[]'( ~al)))) ;empty) ) ,
+        *( ('[]'((~bl, ~br)) & @ (bl, ~br,@ (bl,br, @ (br,'[]'( ~bl)))) ;empty) ) ,
+        *( ('[]'((~cl, ~cr)) & @ (cl, ~cr,@ (cl,cr, @ (cr,'[]'( ~cl)))) ;empty) ) ,
+% shared resources
+	'[]'( ~ ( ar, bl)),
+	'[]'( ~ ( br, cl)),
+	'[]'( ~ ( cr, al))
+)).
+ex(20,(more,
+% five philosophers 
+        *( ('[]'((~al, ~ar)) & @ (al, ~ar,@ (al,ar, @ (ar,'[]'( ~al)))) ;empty) ) ,
+        *( ('[]'((~bl, ~br)) & @ (bl, ~br,@ (bl,br, @ (br,'[]'( ~bl)))) ;empty) ) ,
+        *( ('[]'((~cl, ~cr)) & @ (cl, ~cr,@ (cl,cr, @ (cr,'[]'( ~cl)))) ;empty) ) ,
+        *( ('[]'((~dl, ~dr)) & @ (dl, ~dr,@ (dl,dr, @ (dr,'[]'( ~dl)))) ;empty) ) ,
+        *( ('[]'((~el, ~er)) & @ (el, ~er,@ (el,er, @ (er,'[]'( ~el)))) ;empty) ) ,
+% shared resources
+	'[]'( ~ ( ar, bl)), '[]'( ~ ( br, cl)), '[]'( ~ ( cr, dl)),
+	'[]'( ~ ( dr, el)), '[]'( ~ ( er, al))
+)):-fail.  % too big to verify (sigh...)
+
+ex(21,(more,
+	share([ar,bl]),share([br,cl]),share([cr,dl]),
+	share([dr,el]),share([er,al]),
+        *( ((true && '[]'(al) && '[]'((al,ar)) && '[]'(ar));empty) ) ,
+        *( ((true && '[]'(bl) && '[]'((bl,br)) && '[]'(br));empty) ) ,
+        *( ((true && '[]'(cl) && '[]'((cl,cr)) && '[]'(cr));empty) ) ,
+        *( ((true && '[]'(dl) && '[]'((dl,dr)) && '[]'(dr));empty) ) ,
+        *( ((true && '[]'(el) && '[]'((el,er)) && '[]'(er));empty) ) ,
+true)):-fail.  % too big to verify (sigh...)
+
+ex(22,(more,
+% three philosophers  with no iteration
+        ( ('[]'((~al, ~ar)) & @ (al, ~ar,@ (al,ar, @ (ar,'[]'( ~al)))) ;empty) ) ,
+        ( ('[]'((~bl, ~br)) & @ (bl, ~br,@ (bl,br, @ (br,'[]'( ~bl)))) ;empty) ) ,
+        ( ('[]'((~cl, ~cr)) & @ (cl, ~cr,@ (cl,cr, @ (cr,'[]'( ~cl)))) ;empty) ) ,
+% shared resources
+	'[]'( ~ ( ar, bl)),
+	'[]'( ~ ( br, cl)),
+	'[]'( ~ ( cr, al))
+)).
+% These are not schema. Just check
+% Linear Time Axioms, valid in ITL
+ex(100,('[]'((a->b)) -> ('[]'(a) -> '[]'(b)))).  		%   K
+ex(101,('[]'(((a , '[]'(a))->b));'[]'(((b , '[]'(b))->a)))).    %   4
+ex(102,('[]'(a)-> '<>'(a))).                           	%   D
+ex(103,('[]'(a)-> '[]'('[]'(a)))).                      	%   L
+ex(104,(('[]'(a)) -> a)).                              	%   T
+ex(105,('[]'('[]'((((a-> '[]'(a)))->a))) -> ((('<>'('[]'(a)))-> '[]'(a))))). %   Diodorean discreteness
+% Linear Time Axioms, not valid in ITL
+ex(106,('[]'(('[]'(a)->a))-> ((('<>'('[]'(a)))-> '[]'(a))))).   	%   Z discreteness
+ex(107,('[]'(('[]'(a)->a))-> ('[]'(a)))).                	%   W weak density
+% Other Axioms, not valid in ITL
+ex(108,(a-> '[]'('<>'(a)))).                          	%   B
+ex(109,(('<>'a)-> '[]'('<>'(a)))).                    	%   5
+
+ex(110,(more-> (more&more))).                   	%   our dense time
+
+ex(demo(X),Y) :- demo(X,Y).
+demo(X) :- number(X),demo(X,ITL),nl,ex(ITL),nl,write(ITL).
+
+% length 5 interval
+demo(1, length(5)).
+
+% p is trun at the top of a interval
+demo(2, (length(5),p)).
+
+% @ meas next time.
+demo(3, (length(5),@p,@ @q,@ @ @r)).
+
+% &(chop) devides an interval into to parts
+demo(4, ((length(2),p)) & (length(3),q)).
+
+%  there are several ways of division.
+demo(5, (length(5),(p&q))).
+
+% sometime usinng chop
+demo(6, (length(5),(true & p))).
+
+% always: dual of sometime
+demo(7, (length(5),not(true & not(p)))).
+
+% counter intutive theorem
+demo(8, '<>' '[]'(p) = '[]'('<>'(p))).
+
+% shared resource / exclusive condition
+demo(9, (length(5),
+        '[]'(((    ac ,not(bc),not(cc),not(dc));
+            (not(ac),    bc ,not(cc),not(dc));
+            (not(ac),not(bc),    cc ,not(dc));
+            (not(ac),not(bc),not(cc),    dc ))))).
+
+% periodical task by Projection
+demo(10, (more,
+	proj((@ '<>'(q),length(2)),true))).
+
+% time sharing taks by Projection
+demo(11, (more,length(7),
+	proj(true,('[]'(p),length(4))))).
+
+% combination of periodical task
+demo(12, (more,
+	proj(length(2),'[]'(ac)),
+	proj(length(3),'[]'(bc)),
+	proj(length(5),'[]'(cc)))).
+
+% periodical task with shared resources
+demo(13, (more,
+	proj((length(3),@ '<>'(ac)),true),
+	proj((length(5),@ '<>'(bc)),true),
+	proj((length(5),@ '<>'(cc)),true),
+	'[]'((not((ac,bc)),not((bc,cc)),not((cc,ac)))),
+	true)).
+
+% combination of periodical taks and aperiodical task with shared resource
+demo(14, (
+	((proj(true,(length(5),'[]'(dc))),length(15) )&true),
+	proj((length(3),@ '<>'(ac)),true),
+	proj((length(5),@ '<>'(bc)),true),
+	proj((length(5),@ '<>'(cc)),true),
+	'[]'(((    ac ,not(bc),not(cc),not(dc));
+	    (not(ac),    bc ,not(cc),not(dc));
+	    (not(ac),not(bc),    cc ,not(dc));
+	    (not(ac),not(bc),not(cc),    dc ))),
+	true)).
+% combination of periodical taks and aperiodical task with shared resource
+%  schedulable case
+demo(15, (
+	((proj(true,(length(4),'[]'(dc))),length(15) )&true),
+	proj((length(3),@ '<>'(ac)),true),
+	proj((length(5),@ '<>'(bc)),true),
+	proj((length(5),@ '<>'(cc)),true),
+	'[]'(((    ac ,not(bc),not(cc),not(dc));
+	    (not(ac),    bc ,not(cc),not(dc));
+	    (not(ac),not(bc),    cc ,not(dc));
+	    (not(ac),not(bc),not(cc),    dc ))),
+	true)).
+
+
+% model restriction by share predicate ( a little smaller.... :-)
+demo(16, (
+	share([ac,bc,cc,dc]),
+	((proj(true,(length(4),'[]'(dc))),length(15) )&true),
+	proj((length(3),@ '<>'(ac)),true),
+	proj((length(5),@ '<>'(bc)),true),
+	proj((length(5),@ '<>'(cc)),true),
+	true)).
+demo(17, (
+((proj(true,(length(5),'[]'(c))),length(15))&true),
+(proj((length(3),@ '<>'(a)),true)&less(3)),
+(proj((length(5),@ '<>'(b)),true)&less(5)),
+'[]'(not((a,b))),
+'[]'(not((b,c))),
+'[]'(not((c,a)))
+)).
+
+% Regular variable examples ( doesnot work now....)
+
+ex(200,^r).
+ex(201,true & ^r).   		% will terminate?
+ex(202,((^r & ^r),not(^r))).	% is non-local?
+ex(203,(^r,length(4))).		% distinguish different state?
+ex(204,('[a]'(^r))).		% non-deterministic?
+ex(205,('[a]'(^r = length(2)))). 		% imitate length?
+ex(206,('[a]'(^r = length(4)),(^r& ^r))).
+ex(207,('[a]'(^r = (length(4);empty)),* ^r)).
+ex(208,('[]'(^r = (
+         a,@ ^r;
+         not(a),c,@ @ ^r;
+         not(a),not(c),b,empty)),^r)).        % RE
+ex(209,('[a]'(^r = (
+         a,@((^r & @((b,empty)))) ;
+         not(a),b,empty)),
+      ^r)).                                   % CFG
+
+% Linear Time Axioms, valid in ITL
+ex(210,('[]'((^a-> ^b)) -> ('[]'(^a) -> '[]'(^b)))).            	%   K
+ex(211,('[]'(((^a , '[]'(^a))-> ^b));'[]'(((^b , '[]'(^b))-> ^a)))).   	%   4
+ex(212,('[]'(^a)-> '<>'(^a))).                             		%   D
+ex(213,('[]'(^a)-> '[]'('[]'(^a)))).                         		%   L
+ex(214,(('[]'(^a))-> ^a)).                                	%   T
+%   Diodorean discreteness
+ex(215,('[]'('[]'((((^a-> '[]'(^a)))-> ^a))) -> ((('<>'('[]'(^a)))-> '[]'(^a))))). 
+% Linear Time Axioms, not valid in ITL
+%   Z discreteness
+ex(216,('[]'(('[]'(^a)-> ^a))-> ((('<>'('[]'(^a)))-> '[]'(^a))))).
+%   W weak density
+ex(217,('[]'(('[]'(^a)-> ^a))-> ('[]'(^a)))).
+% Other Axioms, not v^alid in ITL
+ex(218,(^a-> '[]'('<>'(^a)))).                              %   B
+ex(219,(('<>' ^a)-> '[]'('<>'(^a)))).                         %   5
+
+% State Diagram Support
+
+ex(300,(((length(2), @ '<>'(q)) proj true),
+      st(ns0)
+      )) :- ensure_loaded(kiss_ex).
+
+/* end */
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/example/cad.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,31 @@
+specification(Z=f(X),
+   while(more,((
+     Z=X,
+     (
+	 (X->(
+	     repeat((skip&(Z=X,empty)),until,not(X)) &
+	     repeat((skip&(Z=not(X),empty)),until,not(X))))
+         ,
+         (not(X)->(
+	     repeat((skip&(Z=not(X),empty)),until,not(X))))
+     )
+    & skip
+    )))
+).
+
+implementation(Z=f(X),
+    exists(y,(
+    not(y),
+    [](
+           (
+	   next(y) = ((not(X),not(y));(X,y)),
+	   Z = ((X,not(y);(not(X),y)))
+           )
+      )
+    ))
+).
+
+?- specification(z=f(x),Y),ex((trace(x,[1,1,0,1,1,1,0,0,1,0,1]),Y)).
+
+?- speficication(z=f(x),S),implementation(z=f(x),I),
+   ex(I->fin_free(S).
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/example/elevator.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,30 @@
+
+
+elevator((
+
+[]((upButton1 -> <>location1)),
+[]((upButton2 -> <>location2)),
+[]((downButton2 -> <>location2)),
+[]((downButton3 -> <>location3)),
+[]((destButton1 -> <>location1)),
+[]((destButton2 -> <>location2)),
+[]((destButton3 -> <>location3)),
+[](((location1,<>location3) -> ( [](location2) & @ location3))),
+[](((location3,<>location1) -> ( [](location2) & @ location1))),
+[](( 
+	(location1,~ location2,~ location3);
+	(~ location1,location2,~ location3);
+	(~ location1,~ location2,location3))),
+[](((upButton1,location1) -> (~ move , open))),
+[](((upButton2,location2) -> (~ move , open))),
+[](((downButton1,location1) -> (~ move , open))),
+[](((downButton2,location2) -> (~ move , open))),
+[](((destButton1,location1) -> (~ move , open))),
+[](((destButton2,location2) -> (~ move , open))),
+[](((destButton3,location3) -> (~ move , open))),
+[]((move -> ~ open)),
+[](((openButton, ~ move) ->  open)),
+[](((closeButton, ~ openButton) ->  ~ open))
+
+)).
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/example/gi_ex.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,16 @@
+%
+% specification for simple graphics interaction
+%
+
+gi_ex((
++(((stop,keep((red,not(start)));start,keep((green,not(stop)))))),
+[]((red,not(green);not(red),green)),
+[]((green->move)),
+[]((red->not(move))),
+halt(quit)
+)) :-
+      asserta(lite:st_variables([stop,start,quit],[red,gree,move])).
+
+gi:-gi_ex(X),write(X),nl,lite:ex(X),nl,lite:tgen.
+
+giout :- gi_ex(X),lite:ex(X),tell('gi.tokio'),lite:tgen,told.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/example/keyb.kiss2	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,175 @@
+
+.i 7 
+.o 8 
+.p 170 
+.s 19
+---0000 st0 st1 1-000000
+---0100 st0 st2 1-000001
+---0010 st0 st2 1-000001
+---0001 st0 st2 1-000001
+---1100 st0 st3 1-000001
+---1000 st0 st3 1-000001
+---011- st0 st0 -0000001
+---01-1 st0 st0 -0000001
+---101- st0 st0 -0000001
+---10-1 st0 st0 -0000001
+---111- st0 st0 -0000001
+---11-1 st0 st0 -0000001
+-----11 st0 st0 -0000001
+0000000 st1 st4 1-000010
+1000000 st1 st5 0-000010
+0100000 st1 st5 0-000010
+0010000 st1 st5 0-000010
+0001000 st1 st5 0-000010
+0000100 st1 st5 0-000010
+0000010 st1 st5 0-000010
+0000001 st1 st5 0-000010
+11----- st1 st0 -0000010
+1-1---- st1 st0 -0000010
+1--1--- st1 st0 -0000010
+1---1-- st1 st0 -0000010
+1----1- st1 st0 -0000010
+1-----1 st1 st0 -0000010
+-11---- st1 st0 -0000010
+-1-1--- st1 st0 -0000010
+-1--1-- st1 st0 -0000010
+-1---1- st1 st0 -0000010
+-1----1 st1 st0 -0000010
+--11--- st1 st0 -0000010
+--1-1-- st1 st0 -0000010
+--1--1- st1 st0 -0000010
+--1---1 st1 st0 -0000010
+---11-- st1 st0 -0000010
+---1-1- st1 st0 -0000010
+---1--1 st1 st0 -0000010
+----11- st1 st0 -0000010
+----1-1 st1 st0 -0000010
+-----11 st1 st0 -0000010
+0000000 st2 st5 --000011
+1------ st2 st0 -0000011
+-1----- st2 st0 -0000011
+--1---- st2 st0 -0000011
+---1--- st2 st0 -0000011
+----1-- st2 st0 -0000011
+-----1- st2 st0 -0000011
+------1 st2 st0 -0000011
+0000000 st3 st6 1-000100
+0011000 st3 st5 0-000100
+0000100 st3 st5 0-000100
+0000010 st3 st5 0-000100
+0000001 st3 st5 0-000100
+1------ st3 st0 -0000100
+-1----- st3 st0 -0000100
+--01--- st3 st0 -0000100
+--10--- st3 st0 -0000100
+--111-- st3 st0 -0000100
+--11-1- st3 st0 -0000100
+--11--1 st3 st0 -0000100
+----11- st3 st0 -0000100
+----1-1 st3 st0 -0000100
+-----11 st3 st0 -0000100
+-000000 st4 st7 1-000101
+-100000 st4 st8 0-000101
+-010000 st4 st8 0-000101
+-001000 st4 st8 0-000101
+-000100 st4 st8 0-000101
+-000010 st4 st8 0-000101
+-000001 st4 st8 0-000101
+-11---- st4 st0 -0000101
+-1-1--- st4 st0 -0000101
+-1--1-- st4 st0 -0000101
+-1---1- st4 st0 -0000101
+-1----1 st4 st0 -0000101
+--11--- st4 st0 -0000101
+--1-1-- st4 st0 -0000101
+--1--1- st4 st0 -0000101
+--1---1 st4 st0 -0000101
+---11-- st4 st0 -0000101
+---1-1- st4 st0 -0000101
+---1--1 st4 st0 -0000101
+----11- st4 st0 -0000101
+----1-1 st4 st0 -0000101
+-----11 st4 st0 -0000101
+-000000 st5 st8 0-000110
+-1----- st5 st0 -0000110
+--1---- st5 st0 -0000110
+---1--- st5 st0 -0000110
+----1-- st5 st0 -0000110
+-----1- st5 st0 -0000110
+------1 st5 st0 -0000110
+-011000 st6 st8 0-000111
+-000100 st6 st8 0-000111
+-000010 st6 st8 0-000111
+-000001 st6 st8 0-000111
+-000000 st6 st9 1-000111
+-1----- st6 st0 -0000111
+--01--- st6 st0 -0000111
+--10--- st6 st0 -0000111
+--111-- st6 st0 -0000111
+--11-1- st6 st0 -0000111
+--11--1 st6 st0 -0000111
+----11- st6 st0 -0000111
+----1-1 st6 st0 -0000111
+-----11 st6 st0 -0000111
+--00000 st7 st10 1-001000
+--10000 st7 st11 0-001000
+--01000 st7 st11 0-001000
+--00100 st7 st11 0-001000
+--00010 st7 st11 0-001000
+--00001 st7 st11 0-001000
+--11--- st7 st0 -0001000
+--1-1-- st7 st0 -0001000
+--1--1- st7 st0 -0001000
+--1---1 st7 st0 -0001000
+---11-- st7 st0 -0001000
+---1-1- st7 st0 -0001000
+---1--1 st7 st0 -0001000
+----11- st7 st0 -0001000
+----1-1 st7 st0 -0001000
+-----11 st7 st0 -0001000
+--00000 st8 st11 0-001001
+--1---- st8 st0 -0001001
+---1--- st8 st0 -0001001
+----1-- st8 st0 -0001001
+-----1- st8 st0 -0001001
+------1 st8 st0 -0001001
+--00000 st9 st12 --001010
+--11000 st9 st11 0-001010
+--00100 st9 st11 0-001010
+--00010 st9 st11 0-001010
+--00001 st9 st11 0-001010
+--01--- st9 st0 -0001010
+--10--- st9 st0 -0001010
+--111-- st9 st0 -0001010
+--11-1- st9 st0 -0001010
+--11--1 st9 st0 -0001010
+----11- st9 st0 -0001010
+----1-1 st9 st0 -0001010
+-----11 st9 st0 -0001010
+----000 st10 st13 1-001011
+----100 st10 st14 0-001011
+----010 st10 st14 0-001011
+----001 st10 st14 0-001011
+----11- st10 st0 -0001011
+----1-1 st10 st0 -0001011
+-----11 st10 st0 -0001011
+----000 st11 st14 0-001100
+----1-- st11 st0 -0001100
+-----1- st11 st0 -0001100
+------1 st11 st0 -0001100
+-----00 st12 st14 --001101
+-----1- st12 st0 -0001101
+------1 st12 st0 -0001101
+-----00 st13 st15 1-001110
+-----10 st13 st16 0-001110
+-----01 st13 st16 0-001110
+-----11 st13 st0 -0001110
+-----00 st14 st16 0-001111
+-----1- st14 st0 -0001111
+------1 st14 st0 -0001111
+------0 st15 st17 --010000
+------1 st15 st18 0-010000
+------0 st16 st18 0-010001
+------1 st16 st0 -0010001
+------- st17 st0 -0010010
+------- st18 st0 -1010011
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/example/s1a.kiss2	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,112 @@
+
+.i 8 
+.o 12 
+.p 107 
+.s 20
+-1-00--- st0 st0 000000000000
+00--0--- st0 st0 000000000001
+-0--1--- st0 st1 000000000001
+-1-01--- st0 st1 000000000001
+01-10--- st0 st2 000000000001
+11-10--- st0 st5 000000000001
+-1-11--- st0 st3 000000000001
+10--0--- st0 st4 000000000001
+-0------ st1 st6 000000000010
+-1-0---- st1 st6 000000000010
+-1-1---- st1 st7 000000000010
+0---0--- st2 st2 000000000011
+----1--- st2 st3 000000000011
+1---0--- st2 st5 000000000011
+-------- st3 st7 000000000100
+--0----- st4 st12 000000000101
+--1----- st4 st13 000000000101
+-------- st5 st13 000000000110
+-0--1--- st6 st6 000000000111
+-1-01--- st6 st6 000000000111
+-1-11--- st6 st7 000000000111
+00--0--- st6 st8 000000000111
+-1-00--- st6 st8 000000000111
+11-10--- st6 st11 000000000111
+10--0--- st6 st15 000000000111
+01-10--- st6 st9 000000000111
+----1--- st7 st7 000000001000
+0---0--- st7 st9 000000001000
+1---0--- st7 st11 000000001000
+00--00-- st8 st8 000000001001
+00---1-0 st8 st8 000000001001
+-1-000-- st8 st8 000000001001
+-1-0-1-0 st8 st8 000000001001
+00--01-1 st8 st0 000000001001
+-1-001-1 st8 st0 000000001001
+-0--11-1 st8 st1 000000001001
+-1-011-1 st8 st1 000000001001
+10--01-1 st8 st4 000000001001
+01-100-- st8 st9 000000001001
+01-1-1-- st8 st9 000000001001
+01-110-- st8 st10 000000001001
+11-1---- st8 st11 000000001001
+100-10-- st8 st14 000000001001
+-1-010-- st8 st14 000000001001
+101-101- st8 st14 000000001001
+00--10-- st8 st14 000000001001
+10--00-- st8 st15 000000001001
+10---1-0 st8 st15 000000001001
+101-100- st8 st15 000000001001
+0---00-- st9 st9 000000001010
+0----1-0 st9 st9 000000001010
+0---01-1 st9 st2 000000001010
+0---10-- st9 st10 000000001010
+0---11-1 st9 st3 000000001010
+1----0-- st9 st11 000000001010
+1----1-0 st9 st11 000000001010
+1----1-1 st9 st5 000000001010
+------0- st10 st16 000000001011
+------1- st10 st7 000000001011
+-----1-1 st11 st13 000000001100
+-----0-- st11 st17 000000001100
+-----1-0 st11 st17 000000001100
+1-0----- st12 st12 000000001101
+1-1----- st12 st13 000000001101
+0---1--- st12 st1 000000001101
+0---0--- st12 st0 000000001101
+1------- st13 st13 000000001110
+0---0--- st13 st0 000000001110
+0---1--- st13 st1 000000001110
+---0--1- st14 st6 000000001111
+---0--0- st14 st18 000000001111
+-0-1---- st14 st18 000000001111
+-1-1---- st14 st16 000000001111
+--0--0-- st15 st19 000000010000
+--0--1-0 st15 st19 000000010000
+--0--1-1 st15 st12 000000010000
+--1----- st15 st17 000000010000
+----1-0- st16 st16 000000010001
+----1-1- st16 st7 000000010001
+1---0--- st16 st11 000000010001
+0---0--- st16 st9 000000010001
+1----0-- st17 st17 000000010010
+1----1-0 st17 st17 000000010010
+0---00-- st17 st8 000000010010
+0----1-0 st17 st8 000000010010
+0---01-1 st17 st0 000000010010
+0---11-1 st17 st1 000000010010
+1----1-1 st17 st13 000000010010
+0---10-- st17 st14 000000010010
+----1-1- st18 st6 000000010011
+00--0--- st18 st8 000000010011
+-1-00--- st18 st8 000000010011
+01-10--- st18 st9 000000010011
+11-10--- st18 st11 000000010011
+10--0--- st18 st15 000000010011
+-1-11-0- st18 st16 000000010011
+-0--1-0- st18 st18 000000010011
+-1-01-0- st18 st18 000000010011
+1-0--0-- st19 st19 000000010100
+1-0--1-0 st19 st19 000000010100
+0---00-- st19 st8 000000010100
+0----1-0 st19 st8 000000010100
+0---01-1 st19 st0 000000010100
+0---10-- st19 st14 000000010100
+0---11-1 st19 st1 000000010100
+1-0--1-1 st19 st12 000000010100
+1-1----- st19 st17 000000010100
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/example/s208.kiss2	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,158 @@
+.i 11
+.o 8
+.p 153
+.s 18
+.r 11111111
+0--------01 11111111 00000000 10000000
+1--------01 11111111 00000000 11000001
+0--------11 11111111 00000000 10000001
+1--------11 11111111 00000000 11000001
+1--------10 11111111 00000000 11000001
+1--------00 11111111 00000000 10000001
+0---------0 11111111 00000000 10000001
+0---------- 00000000 00000000 00000010
+11--------0 00000000 00000000 00000010
+11--------1 00000000 00000000 01000010
+10--------1 00000000 00010000 01000010
+10--------0 00000000 00010000 00000010
+10-------00 00010000 00100000 00000011
+10-------01 00010000 00100000 01000011
+10-------1- 00010000 00100000 01000011
+00--------- 00010000 00000000 00000011
+01-------0- 00010000 00000000 00000011
+11-------00 00010000 00000000 00000011
+11-------01 00010000 00000000 01000011
+11-------11 00010000 00000000 01000011
+01-------11 00010000 00000000 00000011
+01-------10 00010000 00000000 00000011
+11-------10 00010000 00000000 01000011
+00--------- 00100000 00000000 00000100
+10------1-- 00100000 00110000 01000100
+10------0-0 00100000 00110000 00000100
+10------0-1 00100000 00110000 01000100
+01--------- 00100000 00000000 00000100
+11------1-0 00100000 00000000 01000100
+11------0-0 00100000 00000000 00000100
+11--------1 00100000 00000000 01000100
+00--------- 00110000 00000000 00000101
+10-------01 00110000 01000000 01000101
+10-------00 00110000 01000000 00000101
+10-------1- 00110000 01000000 01000101
+01-------01 00110000 00000000 00000101
+11-------01 00110000 00000000 01000101
+11-------11 00110000 00000000 01000101
+01-------11 00110000 00000000 00000101
+-1-------00 00110000 00000000 00000101
+11-------10 00110000 00000000 01000101
+01-------10 00110000 00000000 00000101
+0---------- 01000000 00000000 00000110
+11-----1--0 01000000 00000000 01000110
+11-----0--0 01000000 00000000 00000110
+11--------1 01000000 00000000 01000110
+10-----1--0 01000000 01010000 01000110
+10-----0--0 01000000 01010000 00000110
+10--------1 01000000 01010000 01000110
+0---------- 01010000 00000000 00000111
+11-------01 01010000 00000000 01000111
+11-------00 01010000 00000000 00000111
+11-------1- 01010000 00000000 01000111
+10-------01 01010000 01100000 01000111
+10-------00 01010000 01100000 00000111
+10-------1- 01010000 01100000 01000111
+0---------- 01100000 00000000 00001000
+10------1-0 01100000 01110000 01001000
+10------0-0 01100000 01110000 00001000
+10--------1 01100000 01110000 01001000
+11------0-0 01100000 00000000 00001000
+11------1-0 01100000 00000000 01001000
+11--------1 01100000 00000000 01001000
+00--------- 01110000 00000000 00001001
+10--------1 01110000 10000000 01001001
+10-------10 01110000 10000000 01001001
+10-------00 01110000 10000000 00001001
+01-------0- 01110000 00000000 00001001
+11-------01 01110000 00000000 01001001
+11-------00 01110000 00000000 00001001
+01-------1- 01110000 00000000 00001001
+11-------1- 01110000 00000000 01001001
+0---------- 10000000 00000000 00001010
+10----0---0 10000000 10010000 00001010
+10----1---0 10000000 10010000 01001010
+10--------1 10000000 10010000 01001010
+11----1---0 10000000 00000000 01001010
+11----0---0 10000000 00000000 00001010
+11--------1 10000000 00000000 01001010
+10--------1 10010000 10100000 01001011
+10-------10 10010000 10100000 01001011
+10-------00 10010000 10100000 00001011
+00--------- 10010000 00000000 00001011
+11-------01 10010000 00000000 01001011
+01-------01 10010000 00000000 00001011
+01-------11 10010000 00000000 00001011
+11-------11 10010000 00000000 01001011
+-1-------00 10010000 00000000 00001011
+11-------10 10010000 00000000 01001011
+01-------10 10010000 00000000 00001011
+00--------- 10100000 00000000 00001100
+10------1-- 10100000 10110000 01001100
+10------0-0 10100000 10110000 00001100
+10------0-1 10100000 10110000 01001100
+11------1-0 10100000 00000000 01001100
+11------0-0 10100000 00000000 00001100
+11--------1 10100000 00000000 01001100
+01--------- 10100000 00000000 00001100
+10--------1 10110000 11000000 01001101
+10-------00 10110000 11000000 00001101
+10-------10 10110000 11000000 01001101
+00--------- 10110000 00000000 00001101
+01-------0- 10110000 00000000 00001101
+11-------01 10110000 00000000 01001101
+11-------00 10110000 00000000 00001101
+01-------1- 10110000 00000000 00001101
+11-------1- 10110000 00000000 01001101
+10-----0--0 11000000 11010000 00001110
+10-----1--0 11000000 11010000 01001110
+10--------1 11000000 11010000 01001110
+00--------- 11000000 00000000 00001110
+01--------- 11000000 00000000 00001110
+11-----1--0 11000000 00000000 01001110
+11-----0--0 11000000 00000000 00001110
+11--------1 11000000 00000000 01001110
+00--------- 11010000 00000000 00001111
+10-------01 11010000 11100000 01001111
+10-------00 11010000 11100000 00001111
+10-------1- 11010000 11100000 01001111
+11--------1 11010000 00000000 01001111
+01--------1 11010000 00000000 00001111
+-1-------00 11010000 00000000 00001111
+11-------10 11010000 00000000 01001111
+01-------10 11010000 00000000 00001111
+0---------- 11100000 00000000 00010000
+11------0-0 11100000 00000000 00010000
+11------1-0 11100000 00000000 01010000
+11--------1 11100000 00000000 01010000
+10------1-- 11100000 11110000 01010000
+10------0-1 11100000 11110000 01010000
+10------0-0 11100000 11110000 00010000
+01-------01 11110000 00000000 00010001
+11-------01 11110000 00000000 01010001
+01-------11 11110000 00000000 00010001
+11-------11 11110000 00000000 01010001
+-1-------00 11110000 00000000 00010001
+01-------10 11110000 00000000 00010001
+11-------10 11110000 00000000 01010001
+10-------01 11110000 00000001 01010001
+00-------01 11110000 00000001 00010001
+-0-------00 11110000 00000001 00010001
+10-------11 11110000 00000001 01010001
+00-------11 11110000 00000001 00010001
+00-------10 11110000 00000001 00010001
+10-------10 11110000 00000001 01010001
+00--------- 00000001 00000000 00010010
+10---1----0 00000001 00010000 01010010
+10---0----0 00000001 00010000 00010010
+10--------1 00000001 00010000 01010010
+11---0----0 00000001 00000000 00010010
+11---1----0 00000001 00000000 01010010
+11--------1 00000001 00000000 01010010
+01--------- 00000001 00000000 00010010
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/example/s298.kiss2	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,1101 @@
+.i 3
+.o 14
+.p 1096
+.s 218
+.r 00000000000000
+1-- 00000000000000 00000001100000 00000000000000
+001 00000000000000 10000001100010 00000000000001
+011 00000000000000 10000001100011 00000000000001
+010 00000000000000 10000001100001 00000000000001
+000 00000000000000 10000001100000 00000000000001
+000 00000001100000 10000001100000 10000100000010
+010 00000001100000 10000001100001 10000100000010
+001 00000001100000 10000001100010 10000100000010
+011 00000001100000 10000001100011 10000100000010
+1-- 00000001100000 00000001100000 10000100000010
+010 10000001100000 01000001100001 10000100000011
+000 10000001100000 01000001100000 10000100000011
+011 10000001100000 01000001100011 10000100000011
+001 10000001100000 01000001100010 10000100000011
+1-- 10000001100000 00000001100000 10000100000011
+001 01000001100001 11001001100011 10000100000100
+011 01000001100001 11001001100010 10000100000100
+010 01000001100001 11001001100000 10000100000100
+000 01000001100001 11001001100001 10000100000100
+1-- 01000001100001 00000001100000 10000100000100
+000 11001001100011 00100001100011 10000100000101
+010 11001001100011 00100001100010 10000100000101
+001 11001001100011 00100001100001 10000100000101
+011 11001001100011 00100001100000 10000100000101
+1-- 11001001100011 00000001100000 10000100000101
+010 00100001100011 10101001100010 10000100000110
+000 00100001100011 10101001100011 10000100000110
+011 00100001100011 10101001100000 10000100000110
+001 00100001100011 10101001100001 10000100000110
+1-- 00100001100011 00000001100000 10000100000110
+000 10101001100010 01101001100010 10000100000111
+010 10101001100010 01101001100011 10000100000111
+011 10101001100010 01101001100001 10000100000111
+001 10101001100010 01101001100000 10000100000111
+1-- 10101001100010 00000001100000 10000100000111
+1-- 01101001100010 00000001100000 10000100001000
+010 01101001100010 11101001100011 10000100001000
+000 01101001100010 11101001100010 10000100001000
+001 01101001100010 11101001100000 10000100001000
+011 01101001100010 11101001100001 10000100001000
+1-- 11101001100011 00000001100000 10000100001001
+010 11101001100011 00010001100010 10000100001001
+000 11101001100011 00010001100011 10000100001001
+011 11101001100011 00010001100000 10000100001001
+001 11101001100011 00010001100001 10000100001001
+000 00010001100010 10010100011010 10000100001010
+010 00010001100010 10010100011011 10000100001010
+001 00010001100010 10010100011000 10000100001010
+011 00010001100010 10010100011001 10000100001010
+1-- 00010001100010 00000000011000 10000100001010
+011 10010100011010 00001100000001 01010000001011
+001 10010100011010 00001100000000 01010000001011
+000 10010100011010 00001100000010 01010000001011
+010 10010100011010 00001100000011 01010000001011
+1-- 10010100011010 00000000000000 01010000001011
+1-- 00001100000001 00000000011000 00000000001100
+000 00001100000001 10000100011001 00000000001100
+010 00001100000001 10000100011000 00000000001100
+011 00001100000001 10000100011010 00000000001100
+001 00001100000001 10000100011011 00000000001100
+1-- 00000000011000 00000001100000 01010000001101
+001 00000000011000 10000001100010 01010000001101
+011 00000000011000 10000001100011 01010000001101
+000 00000000011000 10000001100000 01010000001101
+010 00000000011000 10000001100001 01010000001101
+010 10000001100010 01000001100011 10000100001110
+000 10000001100010 01000001100010 10000100001110
+011 10000001100010 01000001100001 10000100001110
+001 10000001100010 01000001100000 10000100001110
+1-- 10000001100010 00000001100000 10000100001110
+1-- 01000001100011 00000001100000 10000100001111
+001 01000001100011 11001001100001 10000100001111
+011 01000001100011 11001001100000 10000100001111
+000 01000001100011 11001001100011 10000100001111
+010 01000001100011 11001001100010 10000100001111
+1-- 11001001100001 00000001100000 10000100010000
+010 11001001100001 00100001100000 10000100010000
+000 11001001100001 00100001100001 10000100010000
+001 11001001100001 00100001100011 10000100010000
+011 11001001100001 00100001100010 10000100010000
+001 00100001100000 10100001100010 10000100010001
+011 00100001100000 10100001100011 10000100010001
+010 00100001100000 10100001100001 10000100010001
+000 00100001100000 10100001100000 10000100010001
+1-- 00100001100000 00000001100000 10000100010001
+011 10100001100010 01100001100001 10000100010010
+001 10100001100010 01100001100000 10000100010010
+010 10100001100010 01100001100011 10000100010010
+000 10100001100010 01100001100010 10000100010010
+1-- 10100001100010 00000001100000 10000100010010
+011 01100001100001 11101000100110 10000100010011
+001 01100001100001 11101000100111 10000100010011
+000 01100001100001 11101000100101 10000100010011
+010 01100001100001 11101000100100 10000100010011
+1-- 01100001100001 00000000100100 10000100010011
+000 11101000100110 00011000100110 10001000010100
+010 11101000100110 00011000100111 10001000010100
+011 11101000100110 00011000100101 10001000010100
+001 11101000100110 00011000100100 10001000010100
+1-- 11101000100110 00000000100100 10001000010100
+001 00011000100110 10011000100100 10001000010101
+011 00011000100110 10011000100101 10001000010101
+010 00011000100110 10011000100111 10001000010101
+000 00011000100110 10011000100110 10001000010101
+1-- 00011000100110 00000000100100 10001000010101
+1-- 10011000100100 00000000100100 10001000010110
+011 10011000100100 00000000100111 10001000010110
+001 10011000100100 00000000100110 10001000010110
+010 10011000100100 00000000100101 10001000010110
+000 10011000100100 00000000100100 10001000010110
+1-- 00000000100100 00000001100000 10001000010111
+001 00000000100100 10000001100010 10001000010111
+011 00000000100100 10000001100011 10001000010111
+000 00000000100100 10000001100000 10001000010111
+010 00000000100100 10000001100001 10001000010111
+1-- 10000001100011 00000001100000 10000100011000
+000 10000001100011 01001001100011 10000100011000
+010 10000001100011 01001001100010 10000100011000
+011 10000001100011 01001001100000 10000100011000
+001 10000001100011 01001001100001 10000100011000
+011 01001001100011 11000001100000 10000100011001
+001 01001001100011 11000001100001 10000100011001
+000 01001001100011 11000001100011 10000100011001
+010 01001001100011 11000001100010 10000100011001
+1-- 01001001100011 00000001100000 10000100011001
+1-- 11000001100000 00000001100000 10000100011010
+011 11000001100000 00100001100011 10000100011010
+001 11000001100000 00100001100010 10000100011010
+010 11000001100000 00100001100001 10000100011010
+000 11000001100000 00100001100000 10000100011010
+1-- 00100001100010 00000001100000 10000100011011
+010 00100001100010 10100001100011 10000100011011
+000 00100001100010 10100001100010 10000100011011
+001 00100001100010 10100001100000 10000100011011
+011 00100001100010 10100001100001 10000100011011
+011 10100001100011 01101001100000 10000100011100
+001 10100001100011 01101001100001 10000100011100
+000 10100001100011 01101001100011 10000100011100
+010 10100001100011 01101001100010 10000100011100
+1-- 10100001100011 00000001100000 10000100011100
+1-- 01101001100000 00000001100000 10000100011101
+011 01101001100000 11101001100011 10000100011101
+001 01101001100000 11101001100010 10000100011101
+010 01101001100000 11101001100001 10000100011101
+000 01101001100000 11101001100000 10000100011101
+011 11101001100010 00011001100001 10000100011110
+001 11101001100010 00011001100000 10000100011110
+010 11101001100010 00011001100011 10000100011110
+000 11101001100010 00011001100010 10000100011110
+1-- 11101001100010 00000001100000 10000100011110
+011 00011001100001 10010001100010 10000100011111
+001 00011001100001 10010001100011 10000100011111
+000 00011001100001 10010001100001 10000100011111
+010 00011001100001 10010001100000 10000100011111
+1-- 00011001100001 00000001100000 10000100011111
+1-- 10010001100010 00000000000000 10000100100000
+000 10010001100010 00001100000010 10000100100000
+010 10010001100010 00001100000011 10000100100000
+011 10010001100010 00001100000001 10000100100000
+001 10010001100010 00001100000000 10000100100000
+1-- 00001100000010 00000000011000 00000000100001
+001 00001100000010 10001100011000 00000000100001
+011 00001100000010 10001100011001 00000000100001
+010 00001100000010 10001100011011 00000000100001
+000 00001100000010 10001100011010 00000000100001
+010 10001100011000 01001100000001 01010000100010
+000 10001100011000 01001100000000 01010000100010
+001 10001100011000 01001100000010 01010000100010
+011 10001100011000 01001100000011 01010000100010
+1-- 10001100011000 00000000000000 01010000100010
+1-- 01001100000001 00000000011000 00000000100011
+000 01001100000001 11000100011001 00000000100011
+010 01001100000001 11000100011000 00000000100011
+011 01001100000001 11000100011010 00000000100011
+001 01001100000001 11000100011011 00000000100011
+1-- 11000100011001 00000000000000 01010000100100
+010 11000100011001 00101100000000 01010000100100
+000 11000100011001 00101100000001 01010000100100
+011 11000100011001 00101100000010 01010000100100
+001 11000100011001 00101100000011 01010000100100
+1-- 00101100000000 00000000011000 00000000100101
+010 00101100000000 10101100011001 00000000100101
+000 00101100000000 10101100011000 00000000100101
+001 00101100000000 10101100011010 00000000100101
+011 00101100000000 10101100011011 00000000100101
+001 00101100000001 10100100011011 00000000100110
+011 00101100000001 10100100011010 00000000100110
+000 00101100000001 10100100011001 00000000100110
+010 00101100000001 10100100011000 00000000100110
+1-- 00101100000001 00000000011000 00000000100110
+1-- 00101100000010 00000000011000 00000000100111
+011 00101100000010 10101100011001 00000000100111
+001 00101100000010 10101100011000 00000000100111
+000 00101100000010 10101100011010 00000000100111
+010 00101100000010 10101100011011 00000000100111
+1-- 00101100000011 00000000011000 00000000101000
+011 00101100000011 10100100011000 00000000101000
+001 00101100000011 10100100011001 00000000101000
+000 00101100000011 10100100011011 00000000101000
+010 00101100000011 10100100011010 00000000101000
+1-- 11000100011000 00000000000000 01010000101001
+011 11000100011000 00100100000011 01010000101001
+001 11000100011000 00100100000010 01010000101001
+010 11000100011000 00100100000001 01010000101001
+000 11000100011000 00100100000000 01010000101001
+011 00100100000011 10101100011000 00000000101010
+001 00100100000011 10101100011001 00000000101010
+010 00100100000011 10101100011010 00000000101010
+000 00100100000011 10101100011011 00000000101010
+1-- 00100100000011 00000000011000 00000000101010
+1-- 00100100000010 00000000011000 00000000101011
+001 00100100000010 10100100011000 00000000101011
+011 00100100000010 10100100011001 00000000101011
+010 00100100000010 10100100011011 00000000101011
+000 00100100000010 10100100011010 00000000101011
+1-- 00100100000001 00000000011000 00000000101100
+010 00100100000001 10101100011000 00000000101100
+000 00100100000001 10101100011001 00000000101100
+011 00100100000001 10101100011010 00000000101100
+001 00100100000001 10101100011011 00000000101100
+000 00100100000000 10100100011000 00000000101101
+010 00100100000000 10100100011001 00000000101101
+011 00100100000000 10100100011011 00000000101101
+001 00100100000000 10100100011010 00000000101101
+1-- 00100100000000 00000000011000 00000000101101
+011 11000100011010 00100100000001 01010000101110
+001 11000100011010 00100100000000 01010000101110
+000 11000100011010 00100100000010 01010000101110
+010 11000100011010 00100100000011 01010000101110
+1-- 11000100011010 00000000000000 01010000101110
+010 11000100011011 00101100000010 01010000101111
+000 11000100011011 00101100000011 01010000101111
+011 11000100011011 00101100000000 01010000101111
+001 11000100011011 00101100000001 01010000101111
+1-- 11000100011011 00000000000000 01010000101111
+000 01001100000000 11001100011000 00000000110000
+010 01001100000000 11001100011001 00000000110000
+001 01001100000000 11001100011010 00000000110000
+011 01001100000000 11001100011011 00000000110000
+1-- 01001100000000 00000000011000 00000000110000
+1-- 11001100011000 00000000000000 01010000110001
+010 11001100011000 00101100000001 01010000110001
+000 11001100011000 00101100000000 01010000110001
+001 11001100011000 00101100000010 01010000110001
+011 11001100011000 00101100000011 01010000110001
+1-- 11001100011001 00000000000000 01010000110010
+000 11001100011001 00100100000001 01010000110010
+010 11001100011001 00100100000000 01010000110010
+001 11001100011001 00100100000011 01010000110010
+011 11001100011001 00100100000010 01010000110010
+000 11001100011010 00101100000010 01010000110011
+010 11001100011010 00101100000011 01010000110011
+011 11001100011010 00101100000001 01010000110011
+001 11001100011010 00101100000000 01010000110011
+1-- 11001100011010 00000000000000 01010000110011
+001 11001100011011 00100100000001 01010000110100
+011 11001100011011 00100100000000 01010000110100
+000 11001100011011 00100100000011 01010000110100
+010 11001100011011 00100100000010 01010000110100
+1-- 11001100011011 00000000000000 01010000110100
+1-- 01001100000010 00000000011000 00000000110101
+010 01001100000010 11001100011011 00000000110101
+000 01001100000010 11001100011010 00000000110101
+001 01001100000010 11001100011000 00000000110101
+011 01001100000010 11001100011001 00000000110101
+1-- 01001100000011 00000000011000 00000000110110
+011 01001100000011 11000100011000 00000000110110
+001 01001100000011 11000100011001 00000000110110
+000 01001100000011 11000100011011 00000000110110
+010 01001100000011 11000100011010 00000000110110
+1-- 10001100011001 00000000000000 01010000110111
+010 10001100011001 01000100000000 01010000110111
+000 10001100011001 01000100000001 01010000110111
+011 10001100011001 01000100000010 01010000110111
+001 10001100011001 01000100000011 01010000110111
+1-- 01000100000000 00000000011000 00000000111000
+011 01000100000000 11000100011011 00000000111000
+001 01000100000000 11000100011010 00000000111000
+000 01000100000000 11000100011000 00000000111000
+010 01000100000000 11000100011001 00000000111000
+1-- 01000100000001 00000000011000 00000000111001
+001 01000100000001 11001100011011 00000000111001
+011 01000100000001 11001100011010 00000000111001
+010 01000100000001 11001100011000 00000000111001
+000 01000100000001 11001100011001 00000000111001
+1-- 01000100000010 00000000011000 00000000111010
+011 01000100000010 11000100011001 00000000111010
+001 01000100000010 11000100011000 00000000111010
+010 01000100000010 11000100011011 00000000111010
+000 01000100000010 11000100011010 00000000111010
+1-- 01000100000011 00000000011000 00000000111011
+001 01000100000011 11001100011001 00000000111011
+011 01000100000011 11001100011000 00000000111011
+000 01000100000011 11001100011011 00000000111011
+010 01000100000011 11001100011010 00000000111011
+1-- 10001100011011 00000000000000 01010000111100
+010 10001100011011 01000100000010 01010000111100
+000 10001100011011 01000100000011 01010000111100
+001 10001100011011 01000100000001 01010000111100
+011 10001100011011 01000100000000 01010000111100
+1-- 10001100011010 00000000000000 01010000111101
+011 10001100011010 01001100000001 01010000111101
+001 10001100011010 01001100000000 01010000111101
+000 10001100011010 01001100000010 01010000111101
+010 10001100011010 01001100000011 01010000111101
+1-- 00001100000011 00000000011000 00000000111110
+011 00001100000011 10000100011000 00000000111110
+001 00001100000011 10000100011001 00000000111110
+010 00001100000011 10000100011010 00000000111110
+000 00001100000011 10000100011011 00000000111110
+001 10000100011000 01000100000010 01010000111111
+011 10000100011000 01000100000011 01010000111111
+000 10000100011000 01000100000000 01010000111111
+010 10000100011000 01000100000001 01010000111111
+1-- 10000100011000 00000000000000 01010000111111
+1-- 10000100011001 00000000000000 01010001000000
+011 10000100011001 01001100000010 01010001000000
+001 10000100011001 01001100000011 01010001000000
+000 10000100011001 01001100000001 01010001000000
+010 10000100011001 01001100000000 01010001000000
+1-- 10000100011010 00000000000000 01010001000001
+001 10000100011010 01000100000000 01010001000001
+011 10000100011010 01000100000001 01010001000001
+000 10000100011010 01000100000010 01010001000001
+010 10000100011010 01000100000011 01010001000001
+011 10000100011011 01001100000000 01010001000010
+001 10000100011011 01001100000001 01010001000010
+010 10000100011011 01001100000010 01010001000010
+000 10000100011011 01001100000011 01010001000010
+1-- 10000100011011 00000000000000 01010001000010
+011 00001100000000 10001100011011 00000001000011
+001 00001100000000 10001100011010 00000001000011
+000 00001100000000 10001100011000 00000001000011
+010 00001100000000 10001100011001 00000001000011
+1-- 00001100000000 00000000011000 00000001000011
+001 10010001100011 00001100000001 10000101000100
+011 10010001100011 00001100000000 10000101000100
+010 10010001100011 00001100000010 10000101000100
+000 10010001100011 00001100000011 10000101000100
+1-- 10010001100011 00000000000000 10000101000100
+000 10010001100001 00001010010001 10000101000101
+010 10010001100001 00001010010000 10000101000101
+001 10010001100001 00001010010011 10000101000101
+011 10010001100001 00001010010010 10000101000101
+1-- 10010001100001 00000010010000 10000101000101
+1-- 00001010010001 00000000011000 00110001000110
+011 00001010010001 10000000011010 00110001000110
+001 00001010010001 10000000011011 00110001000110
+000 00001010010001 10000000011001 00110001000110
+010 00001010010001 10000000011000 00110001000110
+1-- 10000000011010 00000001100000 01010001000111
+000 10000000011010 01000001100010 01010001000111
+010 10000000011010 01000001100011 01010001000111
+001 10000000011010 01000001100000 01010001000111
+011 10000000011010 01000001100001 01010001000111
+000 01000001100010 11000001100010 10000101001000
+010 01000001100010 11000001100011 10000101001000
+011 01000001100010 11000001100001 10000101001000
+001 01000001100010 11000001100000 10000101001000
+1-- 01000001100010 00000001100000 10000101001000
+000 11000001100010 00100001100010 10000101001001
+010 11000001100010 00100001100011 10000101001001
+001 11000001100010 00100001100000 10000101001001
+011 11000001100010 00100001100001 10000101001001
+1-- 11000001100010 00000001100000 10000101001001
+1-- 00100001100001 00000001100000 10000101001010
+011 00100001100001 10101001100010 10000101001010
+001 00100001100001 10101001100011 10000101001010
+000 00100001100001 10101001100001 10000101001010
+010 00100001100001 10101001100000 10000101001010
+010 11000001100011 00101001100010 10000101001011
+000 11000001100011 00101001100011 10000101001011
+011 11000001100011 00101001100000 10000101001011
+001 11000001100011 00101001100001 10000101001011
+1-- 11000001100011 00000001100000 10000101001011
+001 00101001100010 10101001100000 10000101001100
+011 00101001100010 10101001100001 10000101001100
+010 00101001100010 10101001100011 10000101001100
+000 00101001100010 10101001100010 10000101001100
+1-- 00101001100010 00000001100000 10000101001100
+011 00101001100011 10100001100000 10000101001101
+001 00101001100011 10100001100001 10000101001101
+000 00101001100011 10100001100011 10000101001101
+010 00101001100011 10100001100010 10000101001101
+1-- 00101001100011 00000001100000 10000101001101
+001 00101001100000 10101001100010 10000101001110
+011 00101001100000 10101001100011 10000101001110
+010 00101001100000 10101001100001 10000101001110
+000 00101001100000 10101001100000 10000101001110
+1-- 00101001100000 00000001100000 10000101001110
+1-- 00101001100001 00000001100000 10000101001111
+001 00101001100001 10100001100011 10000101001111
+011 00101001100001 10100001100010 10000101001111
+010 00101001100001 10100001100000 10000101001111
+000 00101001100001 10100001100001 10000101001111
+001 11000001100001 00101001100011 10000101010000
+011 11000001100001 00101001100010 10000101010000
+010 11000001100001 00101001100000 10000101010000
+000 11000001100001 00101001100001 10000101010000
+1-- 11000001100001 00000001100000 10000101010000
+1-- 01000001100000 00000001100000 10000101010001
+010 01000001100000 11000001100001 10000101010001
+000 01000001100000 11000001100000 10000101010001
+001 01000001100000 11000001100010 10000101010001
+011 01000001100000 11000001100011 10000101010001
+001 10000000011011 01001001100001 01010001010010
+011 10000000011011 01001001100000 01010001010010
+010 10000000011011 01001001100010 01010001010010
+000 10000000011011 01001001100011 01010001010010
+1-- 10000000011011 00000001100000 01010001010010
+1-- 01001001100001 00000001100000 10000101010011
+010 01001001100001 11000001100000 10000101010011
+000 01001001100001 11000001100001 10000101010011
+001 01001001100001 11000001100011 10000101010011
+011 01001001100001 11000001100010 10000101010011
+010 01001001100000 11001001100001 10000101010100
+000 01001001100000 11001001100000 10000101010100
+011 01001001100000 11001001100011 10000101010100
+001 01001001100000 11001001100010 10000101010100
+1-- 01001001100000 00000001100000 10000101010100
+1-- 11001001100000 00000001100000 10000101010101
+011 11001001100000 00101001100011 10000101010101
+001 11001001100000 00101001100010 10000101010101
+000 11001001100000 00101001100000 10000101010101
+010 11001001100000 00101001100001 10000101010101
+001 11001001100010 00101001100000 10000101010110
+011 11001001100010 00101001100001 10000101010110
+010 11001001100010 00101001100011 10000101010110
+000 11001001100010 00101001100010 10000101010110
+1-- 11001001100010 00000001100000 10000101010110
+1-- 01001001100010 00000001100000 10000101010111
+011 01001001100010 11001001100001 10000101010111
+001 01001001100010 11001001100000 10000101010111
+000 01001001100010 11001001100010 10000101010111
+010 01001001100010 11001001100011 10000101010111
+010 10000000011001 01001001100000 01010001011000
+000 10000000011001 01001001100001 01010001011000
+001 10000000011001 01001001100011 01010001011000
+011 10000000011001 01001001100010 01010001011000
+1-- 10000000011001 00000001100000 01010001011000
+000 10000000011000 01000001100000 01010001011001
+010 10000000011000 01000001100001 01010001011001
+011 10000000011000 01000001100011 01010001011001
+001 10000000011000 01000001100010 01010001011001
+1-- 10000000011000 00000001100000 01010001011001
+000 00001010010000 10001000011000 00110001011010
+010 00001010010000 10001000011001 00110001011010
+011 00001010010000 10001000011011 00110001011010
+001 00001010010000 10001000011010 00110001011010
+1-- 00001010010000 00000000011000 00110001011010
+1-- 10001000011000 00000000011000 01010001011011
+011 10001000011000 01001000011011 01010001011011
+001 10001000011000 01001000011010 01010001011011
+010 10001000011000 01001000011001 01010001011011
+000 10001000011000 01001000011000 01010001011011
+1-- 01001000011011 00000001100000 01010001011100
+000 01001000011011 11000001100011 01010001011100
+010 01001000011011 11000001100010 01010001011100
+001 01001000011011 11000001100001 01010001011100
+011 01001000011011 11000001100000 01010001011100
+1-- 01001000011010 00000001100000 01010001011101
+000 01001000011010 11001001100010 01010001011101
+010 01001000011010 11001001100011 01010001011101
+001 01001000011010 11001001100000 01010001011101
+011 01001000011010 11001001100001 01010001011101
+001 01001000011001 11000001100011 01010001011110
+011 01001000011001 11000001100010 01010001011110
+000 01001000011001 11000001100001 01010001011110
+010 01001000011001 11000001100000 01010001011110
+1-- 01001000011001 00000001100000 01010001011110
+010 01001000011000 11001001100001 01010001011111
+000 01001000011000 11001001100000 01010001011111
+011 01001000011000 11001001100011 01010001011111
+001 01001000011000 11001001100010 01010001011111
+1-- 01001000011000 00000001100000 01010001011111
+001 10001000011001 01000000011011 01010001100000
+011 10001000011001 01000000011010 01010001100000
+000 10001000011001 01000000011001 01010001100000
+010 10001000011001 01000000011000 01010001100000
+1-- 10001000011001 00000000011000 01010001100000
+1-- 01000000011011 00000001100000 01010001100001
+001 01000000011011 11001001100001 01010001100001
+011 01000000011011 11001001100000 01010001100001
+010 01000000011011 11001001100010 01010001100001
+000 01000000011011 11001001100011 01010001100001
+1-- 01000000011010 00000001100000 01010001100010
+010 01000000011010 11000001100011 01010001100010
+000 01000000011010 11000001100010 01010001100010
+001 01000000011010 11000001100000 01010001100010
+011 01000000011010 11000001100001 01010001100010
+1-- 01000000011001 00000001100000 01010001100011
+001 01000000011001 11001001100011 01010001100011
+011 01000000011001 11001001100010 01010001100011
+000 01000000011001 11001001100001 01010001100011
+010 01000000011001 11001001100000 01010001100011
+1-- 01000000011000 00000001100000 01010001100100
+000 01000000011000 11000001100000 01010001100100
+010 01000000011000 11000001100001 01010001100100
+001 01000000011000 11000001100010 01010001100100
+011 01000000011000 11000001100011 01010001100100
+1-- 10001000011011 00000000011000 01010001100101
+010 10001000011011 01000000011010 01010001100101
+000 10001000011011 01000000011011 01010001100101
+001 10001000011011 01000000011001 01010001100101
+011 10001000011011 01000000011000 01010001100101
+000 10001000011010 01001000011010 01010001100110
+010 10001000011010 01001000011011 01010001100110
+011 10001000011010 01001000011001 01010001100110
+001 10001000011010 01001000011000 01010001100110
+1-- 10001000011010 00000000011000 01010001100110
+010 00001010010011 10000000011010 00110001100111
+000 00001010010011 10000000011011 00110001100111
+011 00001010010011 10000000011000 00110001100111
+001 00001010010011 10000000011001 00110001100111
+1-- 00001010010011 00000000011000 00110001100111
+000 00001010010010 10001000011010 00110001101000
+010 00001010010010 10001000011011 00110001101000
+001 00001010010010 10001000011000 00110001101000
+011 00001010010010 10001000011001 00110001101000
+1-- 00001010010010 00000000011000 00110001101000
+011 00000010010000 10000001100011 00110001101001
+001 00000010010000 10000001100010 00110001101001
+010 00000010010000 10000001100001 00110001101001
+000 00000010010000 10000001100000 00110001101001
+1-- 00000010010000 00000001100000 00110001101001
+1-- 10000001100001 00000001100000 10000101101010
+011 10000001100001 01001001100010 10000101101010
+001 10000001100001 01001001100011 10000101101010
+000 10000001100001 01001001100001 10000101101010
+010 10000001100001 01001001100000 10000101101010
+010 10010001100000 00001010010001 10000101101011
+000 10010001100000 00001010010000 10000101101011
+011 10010001100000 00001010010011 10000101101011
+001 10010001100000 00001010010010 10000101101011
+1-- 10010001100000 00000010010000 10000101101011
+1-- 00011001100000 00000001100000 10000101101100
+010 00011001100000 10011001100001 10000101101100
+000 00011001100000 10011001100000 10000101101100
+011 00011001100000 10011001100011 10000101101100
+001 00011001100000 10011001100010 10000101101100
+1-- 10011001100001 00000001100000 10000101101101
+010 10011001100001 00000001100000 10000101101101
+000 10011001100001 00000001100001 10000101101101
+011 10011001100001 00000001100010 10000101101101
+001 10011001100001 00000001100011 10000101101101
+010 00000001100001 10001001100000 10000101101110
+000 00000001100001 10001001100001 10000101101110
+011 00000001100001 10001001100010 10000101101110
+001 00000001100001 10001001100011 10000101101110
+1-- 00000001100001 00000001100000 10000101101110
+1-- 10001001100000 00000000011000 10000101101111
+001 10001001100000 01001000011010 10000101101111
+011 10001001100000 01001000011011 10000101101111
+010 10001001100000 01001000011001 10000101101111
+000 10001001100000 01001000011000 10000101101111
+000 10001001100001 01000000011001 10000101110000
+010 10001001100001 01000000011000 10000101110000
+011 10001001100001 01000000011010 10000101110000
+001 10001001100001 01000000011011 10000101110000
+1-- 10001001100001 00000000011000 10000101110000
+010 10001001100010 01001000011011 10000101110001
+000 10001001100010 01001000011010 10000101110001
+001 10001001100010 01001000011000 10000101110001
+011 10001001100010 01001000011001 10000101110001
+1-- 10001001100010 00000000011000 10000101110001
+1-- 10001001100011 00000000011000 10000101110010
+000 10001001100011 01000000011011 10000101110010
+010 10001001100011 01000000011010 10000101110010
+011 10001001100011 01000000011000 10000101110010
+001 10001001100011 01000000011001 10000101110010
+1-- 00000001100010 00000001100000 10000101110011
+000 00000001100010 10000001100010 10000101110011
+010 00000001100010 10000001100011 10000101110011
+011 00000001100010 10000001100001 10000101110011
+001 00000001100010 10000001100000 10000101110011
+011 00000001100011 10001001100000 10000101110100
+001 00000001100011 10001001100001 10000101110100
+000 00000001100011 10001001100011 10000101110100
+010 00000001100011 10001001100010 10000101110100
+1-- 00000001100011 00000001100000 10000101110100
+1-1 10011001100000 00000001100000 10000101110101
+001 10011001100000 00000001100010 10000101110101
+011 10011001100000 00000001100011 10000101110101
+010 10011001100000 00000001100001 10000101110101
+110 10011001100000 00000001100000 10000101110101
+-00 10011001100000 00000001100000 10000101110101
+1-- 10011001100011 00000001100000 10000101110110
+010 10011001100011 00000001100010 10000101110110
+000 10011001100011 00000001100011 10000101110110
+001 10011001100011 00000001100001 10000101110110
+011 10011001100011 00000001100000 10000101110110
+000 10011001100010 00000001100010 10000101110111
+010 10011001100010 00000001100011 10000101110111
+1-0 10011001100010 00000001100000 10000101110111
+1-1 10011001100010 00000001100000 10000101110111
+001 10011001100010 00000001100000 10000101110111
+011 10011001100010 00000001100001 10000101110111
+011 00011001100011 10010001100000 10000101111000
+001 00011001100011 10010001100001 10000101111000
+000 00011001100011 10010001100011 10000101111000
+010 00011001100011 10010001100010 10000101111000
+1-- 00011001100011 00000001100000 10000101111000
+1-- 00011001100010 00000001100000 10000101111001
+011 00011001100010 10011001100001 10000101111001
+001 00011001100010 10011001100000 10000101111001
+000 00011001100010 10011001100010 10000101111001
+010 00011001100010 10011001100011 10000101111001
+000 11101001100001 00010001100001 10000101111010
+010 11101001100001 00010001100000 10000101111010
+001 11101001100001 00010001100011 10000101111010
+011 11101001100001 00010001100010 10000101111010
+1-- 11101001100001 00000001100000 10000101111010
+1-- 00010001100001 00000010010000 10000101111011
+010 00010001100001 10011010010000 10000101111011
+000 00010001100001 10011010010001 10000101111011
+011 00010001100001 10011010010010 10000101111011
+001 00010001100001 10011010010011 10000101111011
+011 10011010010000 00000010010011 00110001111100
+001 10011010010000 00000010010010 00110001111100
+1-1 10011010010000 00000010010000 00110001111100
+1-0 10011010010000 00000010010000 00110001111100
+010 10011010010000 00000010010001 00110001111100
+000 10011010010000 00000010010000 00110001111100
+1-- 00000010010011 00000001100000 00110001111101
+011 00000010010011 10001001100000 00110001111101
+001 00000010010011 10001001100001 00110001111101
+010 00000010010011 10001001100010 00110001111101
+000 00000010010011 10001001100011 00110001111101
+011 00000010010010 10000001100001 00110001111110
+001 00000010010010 10000001100000 00110001111110
+000 00000010010010 10000001100010 00110001111110
+010 00000010010010 10000001100011 00110001111110
+1-- 00000010010010 00000001100000 00110001111110
+1-- 00000010010001 00000001100000 00110001111111
+000 00000010010001 10001001100001 00110001111111
+010 00000010010001 10001001100000 00110001111111
+011 00000010010001 10001001100010 00110001111111
+001 00000010010001 10001001100011 00110001111111
+001 10011010010001 00000010010011 00110010000000
+011 10011010010001 00000010010010 00110010000000
+1-1 10011010010001 00000010010000 00110010000000
+000 10011010010001 00000010010001 00110010000000
+100 10011010010001 00000010010000 00110010000000
+-10 10011010010001 00000010010000 00110010000000
+000 10011010010010 00000010010010 00110010000001
+010 10011010010010 00000010010011 00110010000001
+1-0 10011010010010 00000010010000 00110010000001
+111 10011010010010 00000010010000 00110010000001
+011 10011010010010 00000010010001 00110010000001
+-01 10011010010010 00000010010000 00110010000001
+1-- 10011010010011 00000010010000 00110010000010
+011 10011010010011 00000010010000 00110010000010
+001 10011010010011 00000010010001 00110010000010
+000 10011010010011 00000010010011 00110010000010
+010 10011010010011 00000010010010 00110010000010
+011 00010001100000 10010010010011 10000110000011
+001 00010001100000 10010010010010 10000110000011
+000 00010001100000 10010010010000 10000110000011
+010 00010001100000 10010010010001 10000110000011
+1-- 00010001100000 00000010010000 10000110000011
+000 10010010010011 00001100000011 00110010000100
+010 10010010010011 00001100000010 00110010000100
+011 10010010010011 00001100000000 00110010000100
+001 10010010010011 00001100000001 00110010000100
+1-- 10010010010011 00000000000000 00110010000100
+1-- 10010010010010 00000000000000 00110010000101
+001 10010010010010 00001100000000 00110010000101
+011 10010010010010 00001100000001 00110010000101
+000 10010010010010 00001100000010 00110010000101
+010 10010010010010 00001100000011 00110010000101
+010 10010010010000 00001010010001 00110010000110
+000 10010010010000 00001010010000 00110010000110
+011 10010010010000 00001010010011 00110010000110
+001 10010010010000 00001010010010 00110010000110
+1-- 10010010010000 00000010010000 00110010000110
+010 10010010010001 00001010010000 00110010000111
+000 10010010010001 00001010010001 00110010000111
+011 10010010010001 00001010010010 00110010000111
+001 10010010010001 00001010010011 00110010000111
+1-- 10010010010001 00000010010000 00110010000111
+1-- 00010001100011 00000000011000 10000110001000
+011 00010001100011 10011100011000 10000110001000
+001 00010001100011 10011100011001 10000110001000
+000 00010001100011 10011100011011 10000110001000
+010 00010001100011 10011100011010 10000110001000
+1-- 10011100011000 00000000000000 01010010001001
+001 10011100011000 00000100000010 01010010001001
+011 10011100011000 00000100000011 01010010001001
+000 10011100011000 00000100000000 01010010001001
+010 10011100011000 00000100000001 01010010001001
+1-- 00000100000010 00000000011000 00000010001010
+010 00000100000010 10000100011011 00000010001010
+000 00000100000010 10000100011010 00000010001010
+011 00000100000010 10000100011001 00000010001010
+001 00000100000010 10000100011000 00000010001010
+1-- 00000100000011 00000000011000 00000010001011
+011 00000100000011 10001100011000 00000010001011
+001 00000100000011 10001100011001 00000010001011
+000 00000100000011 10001100011011 00000010001011
+010 00000100000011 10001100011010 00000010001011
+001 00000100000000 10000100011010 00000010001100
+011 00000100000000 10000100011011 00000010001100
+000 00000100000000 10000100011000 00000010001100
+010 00000100000000 10000100011001 00000010001100
+1-- 00000100000000 00000000011000 00000010001100
+1-- 00000100000001 00000000011000 00000010001101
+010 00000100000001 10001100011000 00000010001101
+000 00000100000001 10001100011001 00000010001101
+001 00000100000001 10001100011011 00000010001101
+011 00000100000001 10001100011010 00000010001101
+1-- 10011100011001 00000000000000 01010010001110
+011 10011100011001 00000100000010 01010010001110
+001 10011100011001 00000100000011 01010010001110
+010 10011100011001 00000100000000 01010010001110
+000 10011100011001 00000100000001 01010010001110
+1-- 10011100011011 00000000000000 01010010001111
+011 10011100011011 00000100000000 01010010001111
+001 10011100011011 00000100000001 01010010001111
+010 10011100011011 00000100000010 01010010001111
+000 10011100011011 00000100000011 01010010001111
+1-- 10011100011010 00000000000000 01010010010000
+010 10011100011010 00000100000011 01010010010000
+000 10011100011010 00000100000010 01010010010000
+001 10011100011010 00000100000000 01010010010000
+011 10011100011010 00000100000001 01010010010000
+011 11101001100000 00011001100011 10000110010001
+001 11101001100000 00011001100010 10000110010001
+000 11101001100000 00011001100000 10000110010001
+010 11101001100000 00011001100001 10000110010001
+1-- 11101001100000 00000001100000 10000110010001
+000 01101001100001 11100001100001 10000110010010
+010 01101001100001 11100001100000 10000110010010
+011 01101001100001 11100001100010 10000110010010
+001 01101001100001 11100001100011 10000110010010
+1-- 01101001100001 00000001100000 10000110010010
+001 11100001100001 00011000100111 10000110010011
+011 11100001100001 00011000100110 10000110010011
+010 11100001100001 00011000100100 10000110010011
+000 11100001100001 00011000100101 10000110010011
+1-- 11100001100001 00000000100100 10000110010011
+000 00011000100111 10010000100111 10001010010100
+010 00011000100111 10010000100110 10001010010100
+001 00011000100111 10010000100101 10001010010100
+011 00011000100111 10010000100100 10001010010100
+1-- 00011000100111 00000000100100 10001010010100
+000 10010000100111 00001100000011 10001010010101
+010 10010000100111 00001100000010 10001010010101
+001 10010000100111 00001100000001 10001010010101
+011 10010000100111 00001100000000 10001010010101
+1-- 10010000100111 00000000000000 10001010010101
+1-- 10010000100110 00000000000000 10001010010110
+000 10010000100110 00001100000010 10001010010110
+010 10010000100110 00001100000011 10001010010110
+001 10010000100110 00001100000000 10001010010110
+011 10010000100110 00001100000001 10001010010110
+010 10010000100101 00001010010000 10001010010111
+000 10010000100101 00001010010001 10001010010111
+001 10010000100101 00001010010011 10001010010111
+011 10010000100101 00001010010010 10001010010111
+1-- 10010000100101 00000010010000 10001010010111
+1-- 10010000100100 00000010010000 10001010011000
+000 10010000100100 00001010010000 10001010011000
+010 10010000100100 00001010010001 10001010011000
+011 10010000100100 00001010010011 10001010011000
+001 10010000100100 00001010010010 10001010011000
+1-- 00011000100100 00000000100100 10001010011001
+001 00011000100100 10011000100110 10001010011001
+011 00011000100100 10011000100111 10001010011001
+010 00011000100100 10011000100101 10001010011001
+000 00011000100100 10011000100100 10001010011001
+1-- 10011000100110 00000000100100 10001010011010
+001 10011000100110 00000000100100 10001010011010
+011 10011000100110 00000000100101 10001010011010
+000 10011000100110 00000000100110 10001010011010
+010 10011000100110 00000000100111 10001010011010
+001 00000000100101 10001001100011 10001010011011
+011 00000000100101 10001001100010 10001010011011
+010 00000000100101 10001001100000 10001010011011
+000 00000000100101 10001001100001 10001010011011
+1-- 00000000100101 00000001100000 10001010011011
+1-- 00000000100110 00000001100000 10001010011100
+010 00000000100110 10000001100011 10001010011100
+000 00000000100110 10000001100010 10001010011100
+011 00000000100110 10000001100001 10001010011100
+001 00000000100110 10000001100000 10001010011100
+1-- 00000000100111 00000001100000 10001010011101
+001 00000000100111 10001001100001 10001010011101
+011 00000000100111 10001001100000 10001010011101
+010 00000000100111 10001001100010 10001010011101
+000 00000000100111 10001001100011 10001010011101
+1-- 10011000100111 00000000100100 10001010011110
+000 10011000100111 00000000100111 10001010011110
+010 10011000100111 00000000100110 10001010011110
+001 10011000100111 00000000100101 10001010011110
+011 10011000100111 00000000100100 10001010011110
+011 10011000100101 00000000100110 10001010011111
+001 10011000100101 00000000100111 10001010011111
+1-1 10011000100101 00000000100100 10001010011111
+1-0 10011000100101 00000000100100 10001010011111
+000 10011000100101 00000000100101 10001010011111
+010 10011000100101 00000000100100 10001010011111
+000 00011000100101 10010000100101 10001010100000
+010 00011000100101 10010000100100 10001010100000
+011 00011000100101 10010000100110 10001010100000
+001 00011000100101 10010000100111 10001010100000
+1-- 00011000100101 00000000100100 10001010100000
+1-- 11100001100000 00000000100100 10000110100001
+000 11100001100000 00010000100100 10000110100001
+010 11100001100000 00010000100101 10000110100001
+001 11100001100000 00010000100110 10000110100001
+011 11100001100000 00010000100111 10000110100001
+1-- 00010000100100 00000010010000 10001010100010
+001 00010000100100 10010010010010 10001010100010
+011 00010000100100 10010010010011 10001010100010
+000 00010000100100 10010010010000 10001010100010
+010 00010000100100 10010010010001 10001010100010
+1-- 00010000100101 00000010010000 10001010100011
+010 00010000100101 10011010010000 10001010100011
+000 00010000100101 10011010010001 10001010100011
+001 00010000100101 10011010010011 10001010100011
+011 00010000100101 10011010010010 10001010100011
+1-- 00010000100110 00000000011000 10001010100100
+001 00010000100110 10010100011000 10001010100100
+011 00010000100110 10010100011001 10001010100100
+010 00010000100110 10010100011011 10001010100100
+000 00010000100110 10010100011010 10001010100100
+010 10010100011000 00001100000001 01010010100101
+000 10010100011000 00001100000000 01010010100101
+011 10010100011000 00001100000011 01010010100101
+001 10010100011000 00001100000010 01010010100101
+1-- 10010100011000 00000000000000 01010010100101
+010 10010100011001 00001100000000 01010010100110
+000 10010100011001 00001100000001 01010010100110
+001 10010100011001 00001100000011 01010010100110
+011 10010100011001 00001100000010 01010010100110
+1-- 10010100011001 00000000000000 01010010100110
+1-- 10010100011011 00000000000000 01010010100111
+000 10010100011011 00001100000011 01010010100111
+010 10010100011011 00001100000010 01010010100111
+011 10010100011011 00001100000000 01010010100111
+001 10010100011011 00001100000001 01010010100111
+011 00010000100111 10011100011000 10001010101000
+001 00010000100111 10011100011001 10001010101000
+010 00010000100111 10011100011010 10001010101000
+000 00010000100111 10011100011011 10001010101000
+1-- 00010000100111 00000000011000 10001010101000
+001 11100001100010 00010000100100 10000110101001
+011 11100001100010 00010000100101 10000110101001
+010 11100001100010 00010000100111 10000110101001
+000 11100001100010 00010000100110 10000110101001
+1-- 11100001100010 00000000100100 10000110101001
+1-- 11100001100011 00000000100100 10000110101010
+001 11100001100011 00011000100101 10000110101010
+011 11100001100011 00011000100100 10000110101010
+000 11100001100011 00011000100111 10000110101010
+010 11100001100011 00011000100110 10000110101010
+000 01101001100011 11100001100011 10000110101011
+010 01101001100011 11100001100010 10000110101011
+011 01101001100011 11100001100000 10000110101011
+001 01101001100011 11100001100001 10000110101011
+1-- 01101001100011 00000001100000 10000110101011
+011 10100001100000 01100001100011 10000110101100
+001 10100001100000 01100001100010 10000110101100
+000 10100001100000 01100001100000 10000110101100
+010 10100001100000 01100001100001 10000110101100
+1-- 10100001100000 00000001100000 10000110101100
+010 01100001100011 11101000100110 10000110101101
+000 01100001100011 11101000100111 10000110101101
+011 01100001100011 11101000100100 10000110101101
+001 01100001100011 11101000100101 10000110101101
+1-- 01100001100011 00000000100100 10000110101101
+1-- 11101000100111 00000000100100 10001010101110
+010 11101000100111 00010000100110 10001010101110
+000 11101000100111 00010000100111 10001010101110
+001 11101000100111 00010000100101 10001010101110
+011 11101000100111 00010000100100 10001010101110
+1-- 11101000100100 00000000100100 10001010101111
+000 11101000100100 00011000100100 10001010101111
+010 11101000100100 00011000100101 10001010101111
+011 11101000100100 00011000100111 10001010101111
+001 11101000100100 00011000100110 10001010101111
+1-- 11101000100101 00000000100100 10001010110000
+011 11101000100101 00010000100110 10001010110000
+001 11101000100101 00010000100111 10001010110000
+000 11101000100101 00010000100101 10001010110000
+010 11101000100101 00010000100100 10001010110000
+010 01100001100010 11100000100111 10000110110001
+000 01100001100010 11100000100110 10000110110001
+001 01100001100010 11100000100100 10000110110001
+011 01100001100010 11100000100101 10000110110001
+1-- 01100001100010 00000000100100 10000110110001
+011 11100000100111 00011000100100 10001010110010
+001 11100000100111 00011000100101 10001010110010
+010 11100000100111 00011000100110 10001010110010
+000 11100000100111 00011000100111 10001010110010
+1-- 11100000100111 00000000100100 10001010110010
+1-- 11100000100110 00000000100100 10001010110011
+000 11100000100110 00010000100110 10001010110011
+010 11100000100110 00010000100111 10001010110011
+001 11100000100110 00010000100100 10001010110011
+011 11100000100110 00010000100101 10001010110011
+011 11100000100100 00010000100111 10001010110100
+001 11100000100100 00010000100110 10001010110100
+000 11100000100100 00010000100100 10001010110100
+010 11100000100100 00010000100101 10001010110100
+1-- 11100000100100 00000000100100 10001010110100
+1-- 11100000100101 00000000100100 10001010110101
+011 11100000100101 00011000100110 10001010110101
+001 11100000100101 00011000100111 10001010110101
+000 11100000100101 00011000100101 10001010110101
+010 11100000100101 00011000100100 10001010110101
+001 01100001100000 11100000100110 10000110110110
+011 01100001100000 11100000100111 10000110110110
+000 01100001100000 11100000100100 10000110110110
+010 01100001100000 11100000100101 10000110110110
+1-- 01100001100000 00000000100100 10000110110110
+1-- 10100001100001 00000001100000 10000110110111
+011 10100001100001 01101001100010 10000110110111
+001 10100001100001 01101001100011 10000110110111
+000 10100001100001 01101001100001 10000110110111
+010 10100001100001 01101001100000 10000110110111
+001 10101001100011 01100001100001 10000110111000
+011 10101001100011 01100001100000 10000110111000
+000 10101001100011 01100001100011 10000110111000
+010 10101001100011 01100001100010 10000110111000
+1-- 10101001100011 00000001100000 10000110111000
+1-- 10101001100000 00000001100000 10000110111001
+010 10101001100000 01101001100001 10000110111001
+000 10101001100000 01101001100000 10000110111001
+011 10101001100000 01101001100011 10000110111001
+001 10101001100000 01101001100010 10000110111001
+1-- 10101001100001 00000001100000 10000110111010
+010 10101001100001 01100001100000 10000110111010
+000 10101001100001 01100001100001 10000110111010
+001 10101001100001 01100001100011 10000110111010
+011 10101001100001 01100001100010 10000110111010
+001 10100100011000 01100100000010 01010010111011
+011 10100100011000 01100100000011 01010010111011
+010 10100100011000 01100100000001 01010010111011
+000 10100100011000 01100100000000 01010010111011
+1-- 10100100011000 00000000000000 01010010111011
+1-- 01100100000010 00000000011000 00000010111100
+010 01100100000010 11100100011011 00000010111100
+000 01100100000010 11100100011010 00000010111100
+011 01100100000010 11100100011001 00000010111100
+001 01100100000010 11100100011000 00000010111100
+1-- 11100100011011 00000000000000 01010010111101
+001 11100100011011 00011100000001 01010010111101
+011 11100100011011 00011100000000 01010010111101
+010 11100100011011 00011100000010 01010010111101
+000 11100100011011 00011100000011 01010010111101
+1-- 00011100000001 00000000011000 00000010111110
+001 00011100000001 10010100011011 00000010111110
+011 00011100000001 10010100011010 00000010111110
+000 00011100000001 10010100011001 00000010111110
+010 00011100000001 10010100011000 00000010111110
+000 00011100000000 10011100011000 00000010111111
+010 00011100000000 10011100011001 00000010111111
+001 00011100000000 10011100011010 00000010111111
+011 00011100000000 10011100011011 00000010111111
+1-- 00011100000000 00000000011000 00000010111111
+1-- 00011100000010 00000000011000 00000011000000
+010 00011100000010 10011100011011 00000011000000
+000 00011100000010 10011100011010 00000011000000
+001 00011100000010 10011100011000 00000011000000
+011 00011100000010 10011100011001 00000011000000
+1-- 00011100000011 00000000011000 00000011000001
+011 00011100000011 10010100011000 00000011000001
+001 00011100000011 10010100011001 00000011000001
+000 00011100000011 10010100011011 00000011000001
+010 00011100000011 10010100011010 00000011000001
+001 11100100011010 00010100000000 01010011000010
+011 11100100011010 00010100000001 01010011000010
+000 11100100011010 00010100000010 01010011000010
+010 11100100011010 00010100000011 01010011000010
+1-- 11100100011010 00000000000000 01010011000010
+010 00010100000000 10010100011001 00000011000011
+000 00010100000000 10010100011000 00000011000011
+011 00010100000000 10010100011011 00000011000011
+001 00010100000000 10010100011010 00000011000011
+1-- 00010100000000 00000000011000 00000011000011
+1-- 00010100000001 00000000011000 00000011000100
+011 00010100000001 10011100011010 00000011000100
+001 00010100000001 10011100011011 00000011000100
+000 00010100000001 10011100011001 00000011000100
+010 00010100000001 10011100011000 00000011000100
+001 00010100000010 10010100011000 00000011000101
+011 00010100000010 10010100011001 00000011000101
+000 00010100000010 10010100011010 00000011000101
+010 00010100000010 10010100011011 00000011000101
+1-- 00010100000010 00000000011000 00000011000101
+000 00010100000011 10011100011011 00000011000110
+010 00010100000011 10011100011010 00000011000110
+001 00010100000011 10011100011001 00000011000110
+011 00010100000011 10011100011000 00000011000110
+1-- 00010100000011 00000000011000 00000011000110
+1-- 11100100011001 00000000000000 01010011000111
+000 11100100011001 00011100000001 01010011000111
+010 11100100011001 00011100000000 01010011000111
+001 11100100011001 00011100000011 01010011000111
+011 11100100011001 00011100000010 01010011000111
+010 11100100011000 00010100000001 01010011001000
+000 11100100011000 00010100000000 01010011001000
+001 11100100011000 00010100000010 01010011001000
+011 11100100011000 00010100000011 01010011001000
+1-- 11100100011000 00000000000000 01010011001000
+1-- 01100100000011 00000000011000 00000011001001
+001 01100100000011 11101100011001 00000011001001
+011 01100100000011 11101100011000 00000011001001
+010 01100100000011 11101100011010 00000011001001
+000 01100100000011 11101100011011 00000011001001
+1-- 11101100011001 00000000000000 01010011001010
+011 11101100011001 00010100000010 01010011001010
+001 11101100011001 00010100000011 01010011001010
+010 11101100011001 00010100000000 01010011001010
+000 11101100011001 00010100000001 01010011001010
+1-- 11101100011000 00000000000000 01010011001011
+001 11101100011000 00011100000010 01010011001011
+011 11101100011000 00011100000011 01010011001011
+000 11101100011000 00011100000000 01010011001011
+010 11101100011000 00011100000001 01010011001011
+011 11101100011010 00011100000001 01010011001100
+001 11101100011010 00011100000000 01010011001100
+010 11101100011010 00011100000011 01010011001100
+000 11101100011010 00011100000010 01010011001100
+1-- 11101100011010 00000000000000 01010011001100
+1-- 11101100011011 00000000000000 01010011001101
+000 11101100011011 00010100000011 01010011001101
+010 11101100011011 00010100000010 01010011001101
+001 11101100011011 00010100000001 01010011001101
+011 11101100011011 00010100000000 01010011001101
+1-- 01100100000001 00000000011000 00000011001110
+000 01100100000001 11101100011001 00000011001110
+010 01100100000001 11101100011000 00000011001110
+011 01100100000001 11101100011010 00000011001110
+001 01100100000001 11101100011011 00000011001110
+000 01100100000000 11100100011000 00000011001111
+010 01100100000000 11100100011001 00000011001111
+011 01100100000000 11100100011011 00000011001111
+001 01100100000000 11100100011010 00000011001111
+1-- 01100100000000 00000000011000 00000011001111
+1-- 10100100011001 00000000000000 01010011010000
+010 10100100011001 01101100000000 01010011010000
+000 10100100011001 01101100000001 01010011010000
+001 10100100011001 01101100000011 01010011010000
+011 10100100011001 01101100000010 01010011010000
+1-- 01101100000000 00000000011000 00000011010001
+001 01101100000000 11101100011010 00000011010001
+011 01101100000000 11101100011011 00000011010001
+010 01101100000000 11101100011001 00000011010001
+000 01101100000000 11101100011000 00000011010001
+011 01101100000001 11100100011010 00000011010010
+001 01101100000001 11100100011011 00000011010010
+000 01101100000001 11100100011001 00000011010010
+010 01101100000001 11100100011000 00000011010010
+1-- 01101100000001 00000000011000 00000011010010
+1-- 01101100000011 00000000011000 00000011010011
+000 01101100000011 11100100011011 00000011010011
+010 01101100000011 11100100011010 00000011010011
+011 01101100000011 11100100011000 00000011010011
+001 01101100000011 11100100011001 00000011010011
+1-- 01101100000010 00000000011000 00000011010100
+001 01101100000010 11101100011000 00000011010100
+011 01101100000010 11101100011001 00000011010100
+010 01101100000010 11101100011011 00000011010100
+000 01101100000010 11101100011010 00000011010100
+011 10100100011011 01101100000000 01010011010101
+001 10100100011011 01101100000001 01010011010101
+000 10100100011011 01101100000011 01010011010101
+010 10100100011011 01101100000010 01010011010101
+1-- 10100100011011 00000000000000 01010011010101
+001 10100100011010 01100100000000 01010011010110
+011 10100100011010 01100100000001 01010011010110
+000 10100100011010 01100100000010 01010011010110
+010 10100100011010 01100100000011 01010011010110
+1-- 10100100011010 00000000000000 01010011010110
+1-- 10101100011000 00000000000000 01010011010111
+000 10101100011000 01101100000000 01010011010111
+010 10101100011000 01101100000001 01010011010111
+011 10101100011000 01101100000011 01010011010111
+001 10101100011000 01101100000010 01010011010111
+1-- 10101100011001 00000000000000 01010011011000
+000 10101100011001 01100100000001 01010011011000
+010 10101100011001 01100100000000 01010011011000
+001 10101100011001 01100100000011 01010011011000
+011 10101100011001 01100100000010 01010011011000
+1-- 10101100011010 00000000000000 01010011011001
+000 10101100011010 01101100000010 01010011011001
+010 10101100011010 01101100000011 01010011011001
+011 10101100011010 01101100000001 01010011011001
+001 10101100011010 01101100000000 01010011011001
+1-- 10101100011011 00000000000000 01010011011010
+001 10101100011011 01100100000001 01010011011010
+011 10101100011011 01100100000000 01010011011010
+010 10101100011011 01100100000010 01010011011010
+000 10101100011011 01100100000011 01010011011010
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/example/s420.kiss2	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,142 @@
+.i 19
+.o 2
+.p 137
+.s 18
+.r 1111111111111111
+1----------------1- 1111111111111111 0000000000000000 1100000
+1----------------00 1111111111111111 0000000000000000 1000001
+1----------------01 1111111111111111 0000000000000000 1100001
+0------------------ 1111111111111111 0000000000000000 1000001
+10----------------1 0000000000000000 0001000000000000 0100010
+10----------------0 0000000000000000 0001000000000000 0000010
+00----------------- 0000000000000000 0000000000000000 0000010
+01----------------1 0000000000000000 0000000000000000 0000010
+11----------------1 0000000000000000 0000000000000000 0100010
+-1----------------0 0000000000000000 0000000000000000 0000010
+0------------------ 0001000000000000 0000000000000000 0000011
+11---------------1- 0001000000000000 0000000000000000 0100011
+11---------------00 0001000000000000 0000000000000000 0000011
+11---------------01 0001000000000000 0000000000000000 0100011
+10---------------00 0001000000000000 0010000000000000 0000011
+10---------------10 0001000000000000 0010000000000000 0100011
+10----------------1 0001000000000000 0010000000000000 0100011
+00----------------- 0010000000000000 0000000000000000 0000100
+10--------------0-0 0010000000000000 0011000000000000 0000100
+10--------------1-0 0010000000000000 0011000000000000 0100100
+10----------------1 0010000000000000 0011000000000000 0100100
+01----------------- 0010000000000000 0000000000000000 0000100
+11--------------0-0 0010000000000000 0000000000000000 0000100
+11--------------1-0 0010000000000000 0000000000000000 0100100
+11----------------1 0010000000000000 0000000000000000 0100100
+0------------------ 0011000000000000 0000000000000000 0000101
+11---------------10 0011000000000000 0000000000000000 0100101
+11---------------00 0011000000000000 0000000000000000 0000101
+11----------------1 0011000000000000 0000000000000000 0100101
+10---------------1- 0011000000000000 0100000000000000 0100101
+10---------------01 0011000000000000 0100000000000000 0100101
+10---------------00 0011000000000000 0100000000000000 0000101
+10----------------1 0100000000000000 0101000000000000 0100110
+10-------------0--0 0100000000000000 0101000000000000 0000110
+10-------------1--0 0100000000000000 0101000000000000 0100110
+00----------------- 0100000000000000 0000000000000000 0000110
+01-------------0--1 0100000000000000 0000000000000000 0000110
+11-------------0--1 0100000000000000 0000000000000000 0100110
+-1-------------0--0 0100000000000000 0000000000000000 0000110
+01-------------1--- 0100000000000000 0000000000000000 0000110
+11-------------1--- 0100000000000000 0000000000000000 0100110
+0------------------ 0101000000000000 0000000000000000 0000111
+11---------------10 0101000000000000 0000000000000000 0100111
+11---------------00 0101000000000000 0000000000000000 0000111
+11----------------1 0101000000000000 0000000000000000 0100111
+10---------------10 0101000000000000 0110000000000000 0100111
+10---------------00 0101000000000000 0110000000000000 0000111
+10----------------1 0101000000000000 0110000000000000 0100111
+0------------------ 0110000000000000 0000000000000000 0001000
+11--------------1-0 0110000000000000 0000000000000000 0101000
+11--------------0-0 0110000000000000 0000000000000000 0001000
+11----------------1 0110000000000000 0000000000000000 0101000
+10--------------1-- 0110000000000000 0111000000000000 0101000
+10--------------0-0 0110000000000000 0111000000000000 0001000
+10--------------0-1 0110000000000000 0111000000000000 0101000
+0------------------ 0111000000000000 0000000000000000 0001001
+11---------------1- 0111000000000000 0000000000000000 0101001
+11---------------00 0111000000000000 0000000000000000 0001001
+11---------------01 0111000000000000 0000000000000000 0101001
+10---------------1- 0111000000000000 1000000000000000 0101001
+10---------------01 0111000000000000 1000000000000000 0101001
+10---------------00 0111000000000000 1000000000000000 0001001
+00----------------- 1000000000000000 0000000000000000 0001010
+10----------------1 1000000000000000 1001000000000000 0101010
+10------------1---0 1000000000000000 1001000000000000 0101010
+10------------0---0 1000000000000000 1001000000000000 0001010
+01------------0---1 1000000000000000 0000000000000000 0001010
+11------------0---1 1000000000000000 0000000000000000 0101010
+11------------1---1 1000000000000000 0000000000000000 0101010
+01------------1---1 1000000000000000 0000000000000000 0001010
+11------------1---0 1000000000000000 0000000000000000 0101010
+11------------0---0 1000000000000000 0000000000000000 0001010
+01----------------0 1000000000000000 0000000000000000 0001010
+00----------------- 1001000000000000 0000000000000000 0001011
+10---------------1- 1001000000000000 1010000000000000 0101011
+10---------------00 1001000000000000 1010000000000000 0001011
+10---------------01 1001000000000000 1010000000000000 0101011
+01----------------- 1001000000000000 0000000000000000 0001011
+11---------------1- 1001000000000000 0000000000000000 0101011
+11---------------01 1001000000000000 0000000000000000 0101011
+11---------------00 1001000000000000 0000000000000000 0001011
+00----------------- 1010000000000000 0000000000000000 0001100
+10--------------1-- 1010000000000000 1011000000000000 0101100
+10--------------0-1 1010000000000000 1011000000000000 0101100
+10--------------0-0 1010000000000000 1011000000000000 0001100
+01----------------- 1010000000000000 0000000000000000 0001100
+11--------------1-0 1010000000000000 0000000000000000 0101100
+11--------------0-0 1010000000000000 0000000000000000 0001100
+11----------------1 1010000000000000 0000000000000000 0101100
+00----------------- 1011000000000000 0000000000000000 0001101
+10---------------00 1011000000000000 1100000000000000 0001101
+10---------------10 1011000000000000 1100000000000000 0101101
+10----------------1 1011000000000000 1100000000000000 0101101
+01----------------- 1011000000000000 0000000000000000 0001101
+11---------------10 1011000000000000 0000000000000000 0101101
+11---------------00 1011000000000000 0000000000000000 0001101
+11----------------1 1011000000000000 0000000000000000 0101101
+00----------------- 1100000000000000 0000000000000000 0001110
+10-------------0--1 1100000000000000 1101000000000000 0101110
+10-------------0--0 1100000000000000 1101000000000000 0001110
+10-------------1--- 1100000000000000 1101000000000000 0101110
+11----------------1 1100000000000000 0000000000000000 0101110
+01----------------1 1100000000000000 0000000000000000 0001110
+11-------------0--0 1100000000000000 0000000000000000 0001110
+11-------------1--0 1100000000000000 0000000000000000 0101110
+01----------------0 1100000000000000 0000000000000000 0001110
+0------------------ 1101000000000000 0000000000000000 0001111
+10---------------1- 1101000000000000 1110000000000000 0101111
+10---------------00 1101000000000000 1110000000000000 0001111
+10---------------01 1101000000000000 1110000000000000 0101111
+11---------------1- 1101000000000000 0000000000000000 0101111
+11---------------00 1101000000000000 0000000000000000 0001111
+11---------------01 1101000000000000 0000000000000000 0101111
+10--------------1-- 1110000000000000 1111000000000000 0110000
+10--------------0-0 1110000000000000 1111000000000000 0010000
+10--------------0-1 1110000000000000 1111000000000000 0110000
+00----------------- 1110000000000000 0000000000000000 0010000
+01----------------- 1110000000000000 0000000000000000 0010000
+11--------------1-- 1110000000000000 0000000000000000 0110000
+11--------------0-0 1110000000000000 0000000000000000 0010000
+11--------------0-1 1110000000000000 0000000000000000 0110000
+01----------------- 1111000000000000 0000000000000000 0010001
+11---------------00 1111000000000000 0000000000000000 0010001
+11---------------10 1111000000000000 0000000000000000 0110001
+11----------------1 1111000000000000 0000000000000000 0110001
+00----------------- 1111000000000000 0000000100000000 0010001
+10---------------10 1111000000000000 0000000100000000 0110001
+10---------------00 1111000000000000 0000000100000000 0010001
+10----------------1 1111000000000000 0000000100000000 0110001
+00----------------- 0000000100000000 0000000000000000 0010010
+10-----------1----- 0000000100000000 0001000000000000 0110010
+10-----------0----0 0000000100000000 0001000000000000 0010010
+10-----------0----1 0000000100000000 0001000000000000 0110010
+01----------------- 0000000100000000 0000000000000000 0010010
+11-----------1----0 0000000100000000 0000000000000000 0110010
+11-----------0----0 0000000100000000 0000000000000000 0010010
+11----------------1 0000000100000000 0000000000000000 0110010
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/example/tbk.kiss2	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,1574 @@
+
+.i 6 
+.o 9 
+.p 1569 
+.s 32
+000000 st0 st0 000000000
+000001 st0 st0 000000001
+000010 st0 st0 000000001
+000011 st0 st0 000000001
+100011 st0 st16 000000001
+11--00 st0 st0 000000001
+1-1-00 st0 st0 000000001
+1--100 st0 st0 000000001
+-11-00 st0 st0 000000001
+-1-100 st0 st0 000000001
+--1100 st0 st0 000000001
+11--01 st0 st0 000000001
+1-1-01 st0 st0 000000001
+1--101 st0 st0 000000001
+-11-01 st0 st0 000000001
+-1-101 st0 st0 000000001
+--1101 st0 st0 000000001
+11--10 st0 st0 000000001
+1-1-10 st0 st0 000000001
+1--110 st0 st0 000000001
+-11-10 st0 st0 000000001
+-1-110 st0 st0 000000001
+--1110 st0 st0 000000001
+000100 st0 st1 000000001
+001000 st0 st2 000000001
+010000 st0 st3 000000001
+100000 st0 st4 000000001
+000101 st0 st5 000000001
+001001 st0 st6 000000001
+010001 st0 st7 000000001
+100001 st0 st8 000000001
+000110 st0 st9 000000001
+001010 st0 st10 000000001
+010010 st0 st11 000000001
+100010 st0 st12 000000001
+000111 st0 st13 100000001
+001011 st0 st15 000000001
+001111 st0 st13 100000001
+010011 st0 st14 000000001
+010111 st0 st13 100000001
+011011 st0 st0 000000001
+011111 st0 st13 100000001
+100111 st0 st29 100000001
+101011 st0 st31 000000001
+101111 st0 st29 100000001
+110011 st0 st30 000000001
+110111 st0 st29 100000001
+111011 st0 st16 000000001
+111111 st0 st29 100000001
+000000 st16 st16 000000010
+000001 st16 st16 000000010
+000010 st16 st16 000000010
+000011 st16 st0 000000010
+100011 st16 st16 000000010
+11--00 st16 st16 000000010
+1-1-00 st16 st16 000000010
+1--100 st16 st16 000000010
+-11-00 st16 st16 000000010
+-1-100 st16 st16 000000010
+--1100 st16 st16 000000010
+11--01 st16 st16 000000010
+1-1-01 st16 st16 000000010
+1--101 st16 st16 000000010
+-11-01 st16 st16 000000010
+-1-101 st16 st16 000000010
+--1101 st16 st16 000000010
+11--10 st16 st16 000000010
+1-1-10 st16 st16 000000010
+1--110 st16 st16 000000010
+-11-10 st16 st16 000000010
+-1-110 st16 st16 000000010
+--1110 st16 st16 000000010
+000100 st16 st17 000000010
+001000 st16 st18 000000010
+010000 st16 st19 000000010
+100000 st16 st20 000000010
+000101 st16 st21 000000010
+001001 st16 st22 000000010
+010001 st16 st23 000000010
+100001 st16 st24 000000010
+000110 st16 st25 000000010
+001010 st16 st26 000000010
+010010 st16 st27 000000010
+100010 st16 st28 000000010
+000111 st16 st13 100000010
+001011 st16 st15 000000010
+001111 st16 st13 100000010
+010011 st16 st14 000000010
+010111 st16 st13 100000010
+011011 st16 st0 000000010
+011111 st16 st13 100000010
+100111 st16 st29 100000010
+101011 st16 st31 000000010
+101111 st16 st29 100000010
+110011 st16 st30 000000010
+110111 st16 st29 100000010
+111011 st16 st16 000000010
+111111 st16 st29 100000010
+000000 st1 st0 000000011
+000001 st1 st1 000000011
+000010 st1 st1 000000011
+000011 st1 st1 000000011
+100011 st1 st17 000000011
+11--00 st1 st0 000000011
+1-1-00 st1 st0 000000011
+1--100 st1 st0 000000011
+-11-00 st1 st0 000000011
+-1-100 st1 st0 000000011
+--1100 st1 st0 000000011
+11--01 st1 st0 000000011
+1-1-01 st1 st0 000000011
+1--101 st1 st0 000000011
+-11-01 st1 st0 000000011
+-1-101 st1 st0 000000011
+--1101 st1 st0 000000011
+11--10 st1 st0 000000011
+1-1-10 st1 st0 000000011
+1--110 st1 st0 000000011
+-11-10 st1 st0 000000011
+-1-110 st1 st0 000000011
+--1110 st1 st0 000000011
+000100 st1 st1 010000011
+001000 st1 st0 000000011
+010000 st1 st0 000000011
+100000 st1 st0 000000011
+000101 st1 st0 000000011
+001001 st1 st0 000000011
+010001 st1 st0 000000011
+100001 st1 st0 000000011
+000110 st1 st0 000000011
+001010 st1 st0 000000011
+010010 st1 st0 000000011
+100010 st1 st0 000000011
+000111 st1 st13 100000011
+001011 st1 st0 000000011
+001111 st1 st13 100000011
+010011 st1 st0 000000011
+010111 st1 st13 100000011
+011011 st1 st0 000000011
+011111 st1 st13 100000011
+100111 st1 st29 100000011
+101011 st1 st16 000000011
+101111 st1 st29 100000011
+110011 st1 st16 000000011
+110111 st1 st29 100000011
+111011 st1 st16 000000011
+111111 st1 st29 100000011
+000000 st17 st16 000000100
+000001 st17 st17 000000100
+000010 st17 st17 000000100
+000011 st17 st1 000000100
+100011 st17 st17 000000100
+11--00 st17 st16 000000100
+1-1-00 st17 st16 000000100
+1--100 st17 st16 000000100
+-11-00 st17 st16 000000100
+-1-100 st17 st16 000000100
+--1100 st17 st16 000000100
+11--01 st17 st16 000000100
+1-1-01 st17 st16 000000100
+1--101 st17 st16 000000100
+-11-01 st17 st16 000000100
+-1-101 st17 st16 000000100
+--1101 st17 st16 000000100
+11--10 st17 st16 000000100
+1-1-10 st17 st16 000000100
+1--110 st17 st16 000000100
+-11-10 st17 st16 000000100
+-1-110 st17 st16 000000100
+--1110 st17 st16 000000100
+000100 st17 st17 010000100
+001000 st17 st16 000000100
+010000 st17 st16 000000100
+100000 st17 st16 000000100
+000101 st17 st16 000000100
+001001 st17 st16 000000100
+010001 st17 st16 000000100
+100001 st17 st16 000000100
+000110 st17 st16 000000100
+001010 st17 st16 000000100
+010010 st17 st16 000000100
+100010 st17 st16 000000100
+000111 st17 st13 100000100
+001011 st17 st0 000000100
+001111 st17 st13 100000100
+010011 st17 st0 000000100
+010111 st17 st13 100000100
+011011 st17 st0 000000100
+011111 st17 st13 100000100
+100111 st17 st29 100000100
+101011 st17 st16 000000100
+101111 st17 st29 100000100
+110011 st17 st16 000000100
+110111 st17 st29 100000100
+111011 st17 st16 000000100
+111111 st17 st29 100000100
+000000 st2 st0 000000101
+000001 st2 st2 000000101
+000010 st2 st2 000000101
+000011 st2 st2 000000101
+100011 st2 st18 000000101
+11--00 st2 st0 000000101
+1-1-00 st2 st0 000000101
+1--100 st2 st0 000000101
+-11-00 st2 st0 000000101
+-1-100 st2 st0 000000101
+--1100 st2 st0 000000101
+11--01 st2 st0 000000101
+1-1-01 st2 st0 000000101
+1--101 st2 st0 000000101
+-11-01 st2 st0 000000101
+-1-101 st2 st0 000000101
+--1101 st2 st0 000000101
+11--10 st2 st0 000000101
+1-1-10 st2 st0 000000101
+1--110 st2 st0 000000101
+-11-10 st2 st0 000000101
+-1-110 st2 st0 000000101
+--1110 st2 st0 000000101
+000100 st2 st0 000000101
+001000 st2 st2 010000101
+010000 st2 st0 000000101
+100000 st2 st0 000000101
+000101 st2 st0 000000101
+001001 st2 st0 000000101
+010001 st2 st0 000000101
+100001 st2 st0 000000101
+000110 st2 st0 000000101
+001010 st2 st0 000000101
+010010 st2 st0 000000101
+100010 st2 st0 000000101
+000111 st2 st13 100000101
+001011 st2 st0 000000101
+001111 st2 st13 100000101
+010011 st2 st0 000000101
+010111 st2 st13 100000101
+011011 st2 st0 000000101
+011111 st2 st13 100000101
+100111 st2 st29 100000101
+101011 st2 st16 000000101
+101111 st2 st29 100000101
+110011 st2 st16 000000101
+110111 st2 st29 100000101
+110111 st2 st29 100000101
+111011 st2 st16 000000101
+111111 st2 st29 100000101
+000000 st18 st16 000000110
+000001 st18 st18 000000110
+000010 st18 st18 000000110
+000011 st18 st2 000000110
+100011 st18 st18 000000110
+11--00 st18 st16 000000110
+1-1-00 st18 st16 000000110
+1--100 st18 st16 000000110
+-11-00 st18 st16 000000110
+-1-100 st18 st16 000000110
+--1100 st18 st16 000000110
+11--01 st18 st16 000000110
+1-1-01 st18 st16 000000110
+1--101 st18 st16 000000110
+-11-01 st18 st16 000000110
+-1-101 st18 st16 000000110
+--1101 st18 st16 000000110
+11--10 st18 st16 000000110
+1-1-10 st18 st16 000000110
+1--110 st18 st16 000000110
+-11-10 st18 st16 000000110
+-1-110 st18 st16 000000110
+--1110 st18 st16 000000110
+000100 st18 st16 000000110
+001000 st18 st18 010000110
+010000 st18 st16 000000110
+100000 st18 st16 000000110
+000101 st18 st16 000000110
+001001 st18 st16 000000110
+010001 st18 st16 000000110
+100001 st18 st16 000000110
+000110 st18 st16 000000110
+001010 st18 st16 000000110
+010010 st18 st16 000000110
+100010 st18 st16 000000110
+000111 st18 st13 100000110
+001011 st18 st0 000000110
+001111 st18 st13 100000110
+010011 st18 st0 000000110
+010111 st18 st13 100000110
+011011 st18 st0 000000110
+011111 st18 st13 100000110
+100111 st18 st29 100000110
+101011 st18 st16 000000110
+101111 st18 st29 100000110
+110011 st18 st16 000000110
+110111 st18 st29 100000110
+111011 st18 st16 000000110
+111111 st18 st29 100000110
+000000 st3 st0 000000111
+000001 st3 st3 000000111
+000010 st3 st3 000000111
+000011 st3 st3 000000111
+100011 st3 st19 000000111
+11--00 st3 st0 000000111
+1-1-00 st3 st0 000000111
+1--100 st3 st0 000000111
+-11-00 st3 st0 000000111
+-1-100 st3 st0 000000111
+--1100 st3 st0 000000111
+11--01 st3 st0 000000111
+1-1-01 st3 st0 000000111
+1--101 st3 st0 000000111
+-11-01 st3 st0 000000111
+-1-101 st3 st0 000000111
+--1101 st3 st0 000000111
+11--10 st3 st0 000000111
+1-1-10 st3 st0 000000111
+1--110 st3 st0 000000111
+-11-10 st3 st0 000000111
+-1-110 st3 st0 000000111
+--1110 st3 st0 000000111
+000100 st3 st0 000000111
+001000 st3 st0 000000111
+010000 st3 st3 010000111
+100000 st3 st0 000000111
+000101 st3 st0 000000111
+001001 st3 st0 000000111
+010001 st3 st0 000000111
+100001 st3 st0 000000111
+000110 st3 st0 000000111
+001010 st3 st0 000000111
+010010 st3 st0 000000111
+100010 st3 st0 000000111
+000111 st3 st13 100000111
+001011 st3 st0 000000111
+001111 st3 st13 100000111
+010011 st3 st0 000000111
+010111 st3 st13 100000111
+011011 st3 st0 000000111
+011111 st3 st13 100000111
+100111 st3 st29 100000111
+101011 st3 st16 000000111
+101111 st3 st29 100000111
+110011 st3 st16 000000111
+110111 st3 st29 100000111
+111011 st3 st16 000000111
+111111 st3 st29 100000111
+000000 st19 st16 000001000
+000001 st19 st19 000001000
+000010 st19 st19 000001000
+000011 st19 st3 000001000
+100011 st19 st19 000001000
+11--00 st19 st16 000001000
+1-1-00 st19 st16 000001000
+1--100 st19 st16 000001000
+-11-00 st19 st16 000001000
+-1-100 st19 st16 000001000
+--1100 st19 st16 000001000
+11--01 st19 st16 000001000
+1-1-01 st19 st16 000001000
+1--101 st19 st16 000001000
+-11-01 st19 st16 000001000
+-1-101 st19 st16 000001000
+--1101 st19 st16 000001000
+11--10 st19 st16 000001000
+1-1-10 st19 st16 000001000
+1--110 st19 st16 000001000
+-11-10 st19 st16 000001000
+-1-110 st19 st16 000001000
+--1110 st19 st16 000001000
+000100 st19 st16 000001000
+001000 st19 st16 000001000
+010000 st19 st19 010001000
+100000 st19 st16 000001000
+000101 st19 st16 000001000
+001001 st19 st16 000001000
+010001 st19 st16 000001000
+100001 st19 st16 000001000
+000110 st19 st16 000001000
+001010 st19 st16 000001000
+010010 st19 st16 000001000
+100010 st19 st16 000001000
+000111 st19 st13 100001000
+001011 st19 st0 000001000
+001111 st19 st13 100001000
+010011 st19 st0 000001000
+010111 st19 st13 100001000
+011011 st19 st0 000001000
+011111 st19 st13 100001000
+100111 st19 st29 100001000
+101011 st19 st16 000001000
+101111 st19 st29 100001000
+110011 st19 st16 000001000
+110111 st19 st29 100001000
+111011 st19 st16 000001000
+111111 st19 st29 100001000
+000000 st4 st0 000001001
+000001 st4 st4 000001001
+000010 st4 st4 000001001
+000011 st4 st4 000001001
+100011 st4 st20 000001001
+11--00 st4 st0 000001001
+1-1-00 st4 st0 000001001
+1--100 st4 st0 000001001
+-11-00 st4 st0 000001001
+-1-100 st4 st0 000001001
+--1100 st4 st0 000001001
+11--01 st4 st0 000001001
+1-1-01 st4 st0 000001001
+1--101 st4 st0 000001001
+-11-01 st4 st0 000001001
+-1-101 st4 st0 000001001
+--1101 st4 st0 000001001
+11--10 st4 st0 000001001
+1-1-10 st4 st0 000001001
+1--110 st4 st0 000001001
+-11-10 st4 st0 000001001
+-1-110 st4 st0 000001001
+--1110 st4 st0 000001001
+000100 st4 st0 000001001
+001000 st4 st0 000001001
+010000 st4 st0 000001001
+100000 st4 st4 010001001
+000101 st4 st0 000001001
+001001 st4 st0 000001001
+010001 st4 st0 000001001
+100001 st4 st0 000001001
+000110 st4 st0 000001001
+001010 st4 st0 000001001
+010010 st4 st0 000001001
+100010 st4 st0 000001001
+000111 st4 st13 100001001
+001011 st4 st0 000001001
+001111 st4 st13 100001001
+010011 st4 st0 000001001
+010111 st4 st13 100001001
+011011 st4 st0 000001001
+011111 st4 st13 100001001
+100111 st4 st29 100001001
+101011 st4 st16 000001001
+101111 st4 st29 100001001
+110011 st4 st16 000001001
+110111 st4 st29 100001001
+111011 st4 st16 000001001
+111111 st4 st29 100001001
+000000 st20 st16 000001010
+000001 st20 st20 000001010
+000010 st20 st20 000001010
+000011 st20 st4 000001010
+100011 st20 st20 000001010
+11--00 st20 st16 000001010
+1-1-00 st20 st16 000001010
+1--100 st20 st16 000001010
+-11-00 st20 st16 000001010
+-1-100 st20 st16 000001010
+--1100 st20 st16 000001010
+11--01 st20 st16 000001010
+1-1-01 st20 st16 000001010
+1--101 st20 st16 000001010
+-11-01 st20 st16 000001010
+-1-101 st20 st16 000001010
+--1101 st20 st16 000001010
+11--10 st20 st16 000001010
+1-1-10 st20 st16 000001010
+1--110 st20 st16 000001010
+-11-10 st20 st16 000001010
+-1-110 st20 st16 000001010
+--1110 st20 st16 000001010
+000100 st20 st16 000001010
+001000 st20 st16 000001010
+010000 st20 st16 000001010
+100000 st20 st20 010001010
+000101 st20 st16 000001010
+001001 st20 st16 000001010
+010001 st20 st16 000001010
+100001 st20 st16 000001010
+000110 st20 st16 000001010
+001010 st20 st16 000001010
+010010 st20 st16 000001010
+100010 st20 st16 000001010
+000111 st20 st13 100001010
+001011 st20 st0 000001010
+001111 st20 st13 100001010
+010011 st20 st0 000001010
+010111 st20 st13 100001010
+011011 st20 st0 000001010
+011111 st20 st13 100001010
+100111 st20 st29 100001010
+101011 st20 st16 000001010
+101111 st20 st29 100001010
+110011 st20 st16 000001010
+110111 st20 st29 100001010
+111011 st20 st16 000001010
+111111 st20 st29 100001010
+000001 st5 st0 000001011
+000000 st5 st5 000001011
+000010 st5 st5 000001011
+000011 st5 st5 000001011
+100011 st5 st21 000001011
+11--00 st5 st0 000001011
+1-1-00 st5 st0 000001011
+1--100 st5 st0 000001011
+-11-00 st5 st0 000001011
+-1-100 st5 st0 000001011
+--1100 st5 st0 000001011
+11--01 st5 st0 000001011
+1-1-01 st5 st0 000001011
+1--101 st5 st0 000001011
+-11-01 st5 st0 000001011
+-1-101 st5 st0 000001011
+--1101 st5 st0 000001011
+11--10 st5 st0 000001011
+1-1-10 st5 st0 000001011
+1--110 st5 st0 000001011
+-11-10 st5 st0 000001011
+-1-110 st5 st0 000001011
+--1110 st5 st0 000001011
+000100 st5 st0 000001011
+001000 st5 st0 000001011
+010000 st5 st0 000001011
+100000 st5 st0 000001011
+000101 st5 st5 010001011
+001001 st5 st0 000001011
+010001 st5 st0 000001011
+100001 st5 st0 000001011
+000110 st5 st0 000001011
+001010 st5 st0 000001011
+010010 st5 st0 000001011
+100010 st5 st0 000001011
+000111 st5 st13 100001011
+001011 st5 st0 000001011
+001111 st5 st13 100001011
+010011 st5 st0 000001011
+010111 st5 st13 100001011
+011011 st5 st0 000001011
+011111 st5 st13 100001011
+100111 st5 st29 100001011
+101011 st5 st16 000001011
+101111 st5 st29 100001011
+110011 st5 st16 000001011
+110111 st5 st29 100001011
+111011 st5 st16 000001011
+111111 st5 st29 100001011
+000001 st21 st16 000001100
+000000 st21 st21 000001100
+000010 st21 st21 000001100
+000011 st21 st5 000001100
+100011 st21 st21 000001100
+11--00 st21 st16 000001100
+1-1-00 st21 st16 000001100
+1--100 st21 st16 000001100
+-11-00 st21 st16 000001100
+-1-100 st21 st16 000001100
+--1100 st21 st16 000001100
+11--01 st21 st16 000001100
+1-1-01 st21 st16 000001100
+1--101 st21 st16 000001100
+-11-01 st21 st16 000001100
+-1-101 st21 st16 000001100
+--1101 st21 st16 000001100
+11--10 st21 st16 000001100
+1-1-10 st21 st16 000001100
+1--110 st21 st16 000001100
+-11-10 st21 st16 000001100
+-1-110 st21 st16 000001100
+--1110 st21 st16 000001100
+000100 st21 st16 000001100
+001000 st21 st16 000001100
+010000 st21 st16 000001100
+100000 st21 st16 000001100
+000101 st21 st21 010001100
+001001 st21 st16 000001100
+010001 st21 st16 000001100
+100001 st21 st16 000001100
+000110 st21 st16 000001100
+001010 st21 st16 000001100
+010010 st21 st16 000001100
+100010 st21 st16 000001100
+000111 st21 st13 100001100
+001011 st21 st0 000001100
+001111 st21 st13 100001100
+010011 st21 st0 000001100
+010111 st21 st13 100001100
+011011 st21 st0 000001100
+011111 st21 st13 100001100
+100111 st21 st29 100001100
+101011 st21 st16 000001100
+101111 st21 st29 100001100
+110011 st21 st16 000001100
+110111 st21 st29 100001100
+111011 st21 st16 000001100
+111111 st21 st29 100001100
+000001 st6 st0 000001101
+000000 st6 st6 000001101
+000010 st6 st6 000001101
+000011 st6 st6 000001101
+100011 st6 st22 000001101
+11--00 st6 st0 000001101
+1-1-00 st6 st0 000001101
+1--100 st6 st0 000001101
+-11-00 st6 st0 000001101
+-1-100 st6 st0 000001101
+--1100 st6 st0 000001101
+11--01 st6 st0 000001101
+1-1-01 st6 st0 000001101
+1--101 st6 st0 000001101
+-11-01 st6 st0 000001101
+-1-101 st6 st0 000001101
+--1101 st6 st0 000001101
+11--10 st6 st0 000001101
+1-1-10 st6 st0 000001101
+1--110 st6 st0 000001101
+-11-10 st6 st0 000001101
+-1-110 st6 st0 000001101
+--1110 st6 st0 000001101
+000100 st6 st0 000001101
+001000 st6 st0 000001101
+010000 st6 st0 000001101
+100000 st6 st0 000001101
+000101 st6 st0 000001101
+001001 st6 st6 010001101
+010001 st6 st0 000001101
+100001 st6 st0 000001101
+000110 st6 st0 000001101
+001010 st6 st0 000001101
+010010 st6 st0 000001101
+100010 st6 st0 000001101
+000111 st6 st13 100001101
+001011 st6 st0 000001101
+001111 st6 st13 100001101
+010011 st6 st0 000001101
+010111 st6 st13 100001101
+011011 st6 st0 000001101
+011111 st6 st13 100001101
+100111 st6 st29 100001101
+101011 st6 st16 000001101
+101111 st6 st29 100001101
+110011 st6 st16 000001101
+110111 st6 st29 100001101
+111011 st6 st16 000001101
+111111 st6 st29 100001101
+000001 st22 st16 000001110
+000000 st22 st22 000001110
+000010 st22 st22 000001110
+000011 st22 st6 000001110
+100011 st22 st22 000001110
+11--00 st22 st16 000001110
+1-1-00 st22 st16 000001110
+1--100 st22 st16 000001110
+-11-00 st22 st16 000001110
+-1-100 st22 st16 000001110
+--1100 st22 st16 000001110
+11--01 st22 st16 000001110
+1-1-01 st22 st16 000001110
+1--101 st22 st16 000001110
+-11-01 st22 st16 000001110
+-1-101 st22 st16 000001110
+--1101 st22 st16 000001110
+11--10 st22 st16 000001110
+1-1-10 st22 st16 000001110
+1--110 st22 st16 000001110
+-11-10 st22 st16 000001110
+-1-110 st22 st16 000001110
+--1110 st22 st16 000001110
+000100 st22 st16 000001110
+001000 st22 st16 000001110
+010000 st22 st16 000001110
+100000 st22 st16 000001110
+000101 st22 st16 000001110
+001001 st22 st22 010001110
+010001 st22 st16 000001110
+100001 st22 st16 000001110
+000110 st22 st16 000001110
+001010 st22 st16 000001110
+010010 st22 st16 000001110
+100010 st22 st16 000001110
+000111 st22 st13 100001110
+001011 st22 st0 000001110
+001111 st22 st13 100001110
+010011 st22 st0 000001110
+010111 st22 st13 100001110
+011011 st22 st0 000001110
+011111 st22 st13 100001110
+100111 st22 st29 100001110
+101011 st22 st16 000001110
+101111 st22 st29 100001110
+110011 st22 st16 000001110
+110111 st22 st29 100001110
+111011 st22 st16 000001110
+111111 st22 st29 100001110
+000001 st7 st0 000001111
+000000 st7 st7 000001111
+000010 st7 st7 000001111
+000011 st7 st7 000001111
+100011 st7 st23 000001111
+11--00 st7 st0 000001111
+1-1-00 st7 st0 000001111
+1--100 st7 st0 000001111
+-11-00 st7 st0 000001111
+-1-100 st7 st0 000001111
+--1100 st7 st0 000001111
+11--01 st7 st0 000001111
+1-1-01 st7 st0 000001111
+1--101 st7 st0 000001111
+-11-01 st7 st0 000001111
+-1-101 st7 st0 000001111
+--1101 st7 st0 000001111
+11--10 st7 st0 000001111
+1-1-10 st7 st0 000001111
+1--110 st7 st0 000001111
+-11-10 st7 st0 000001111
+-1-110 st7 st0 000001111
+--1110 st7 st0 000001111
+000100 st7 st0 000001111
+001000 st7 st0 000001111
+010000 st7 st0 000001111
+100000 st7 st0 000001111
+000101 st7 st0 000001111
+001001 st7 st0 000001111
+010001 st7 st7 010001111
+100001 st7 st0 000001111
+000110 st7 st0 000001111
+001010 st7 st0 000001111
+010010 st7 st0 000001111
+100010 st7 st0 000001111
+000111 st7 st13 100001111
+001011 st7 st0 000001111
+001111 st7 st13 100001111
+010011 st7 st0 000001111
+010111 st7 st13 100001111
+011011 st7 st0 000001111
+011111 st7 st13 100001111
+100111 st7 st29 100001111
+101011 st7 st16 000001111
+101111 st7 st29 100001111
+110011 st7 st16 000001111
+110111 st7 st29 100001111
+111011 st7 st16 000001111
+111111 st7 st29 100001111
+000001 st23 st16 000010000
+000000 st23 st23 000010000
+000010 st23 st23 000010000
+000011 st23 st7 000010000
+100011 st23 st23 000010000
+11--00 st23 st16 000010000
+1-1-00 st23 st16 000010000
+1--100 st23 st16 000010000
+-11-00 st23 st16 000010000
+-1-100 st23 st16 000010000
+--1100 st23 st16 000010000
+11--01 st23 st16 000010000
+1-1-01 st23 st16 000010000
+1--101 st23 st16 000010000
+-11-01 st23 st16 000010000
+-1-101 st23 st16 000010000
+--1101 st23 st16 000010000
+11--10 st23 st16 000010000
+1-1-10 st23 st16 000010000
+1--110 st23 st16 000010000
+-11-10 st23 st16 000010000
+-1-110 st23 st16 000010000
+--1110 st23 st16 000010000
+000100 st23 st16 000010000
+001000 st23 st16 000010000
+010000 st23 st16 000010000
+100000 st23 st16 000010000
+000101 st23 st16 000010000
+001001 st23 st16 000010000
+010001 st23 st23 010010000
+100001 st23 st16 000010000
+000110 st23 st16 000010000
+001010 st23 st16 000010000
+010010 st23 st16 000010000
+100010 st23 st16 000010000
+000111 st23 st13 100010000
+001011 st23 st0 000010000
+001111 st23 st13 100010000
+010011 st23 st0 000010000
+010111 st23 st13 100010000
+011011 st23 st0 000010000
+011111 st23 st13 100010000
+100111 st23 st29 100010000
+101011 st23 st16 000010000
+101111 st23 st29 100010000
+110011 st23 st16 000010000
+110111 st23 st29 100010000
+111011 st23 st16 000010000
+111111 st23 st29 100010000
+000001 st8 st0 000010001
+000000 st8 st8 000010001
+000010 st8 st8 000010001
+000011 st8 st8 000010001
+100011 st8 st24 000010001
+11--00 st8 st0 000010001
+1-1-00 st8 st0 000010001
+1--100 st8 st0 000010001
+-11-00 st8 st0 000010001
+-1-100 st8 st0 000010001
+--1100 st8 st0 000010001
+11--01 st8 st0 000010001
+1-1-01 st8 st0 000010001
+1--101 st8 st0 000010001
+-11-01 st8 st0 000010001
+-1-101 st8 st0 000010001
+--1101 st8 st0 000010001
+11--10 st8 st0 000010001
+1-1-10 st8 st0 000010001
+1--110 st8 st0 000010001
+-11-10 st8 st0 000010001
+-1-110 st8 st0 000010001
+--1110 st8 st0 000010001
+000100 st8 st0 000010001
+001000 st8 st0 000010001
+010000 st8 st0 000010001
+100000 st8 st0 000010001
+000101 st8 st0 000010001
+001001 st8 st0 000010001
+010001 st8 st0 000010001
+100001 st8 st8 010010001
+000110 st8 st0 000010001
+001010 st8 st0 000010001
+010010 st8 st0 000010001
+100010 st8 st0 000010001
+000111 st8 st13 100010001
+001011 st8 st0 000010001
+001111 st8 st13 100010001
+010011 st8 st0 000010001
+010111 st8 st13 100010001
+011011 st8 st0 000010001
+011111 st8 st13 100010001
+100111 st8 st29 100010001
+101011 st8 st16 000010001
+101111 st8 st29 100010001
+110011 st8 st16 000010001
+110111 st8 st29 100010001
+111011 st8 st16 000010001
+111111 st8 st29 100010001
+000001 st24 st16 000010010
+000000 st24 st24 000010010
+000010 st24 st24 000010010
+000011 st24 st8 000010010
+100011 st24 st24 000010010
+11--00 st24 st16 000010010
+1-1-00 st24 st16 000010010
+1--100 st24 st16 000010010
+-11-00 st24 st16 000010010
+-1-100 st24 st16 000010010
+--1100 st24 st16 000010010
+11--01 st24 st16 000010010
+1-1-01 st24 st16 000010010
+1--101 st24 st16 000010010
+-11-01 st24 st16 000010010
+-1-101 st24 st16 000010010
+--1101 st24 st16 000010010
+11--10 st24 st16 000010010
+1-1-10 st24 st16 000010010
+1--110 st24 st16 000010010
+-11-10 st24 st16 000010010
+-1-110 st24 st16 000010010
+--1110 st24 st16 000010010
+000100 st24 st16 000010010
+001000 st24 st16 000010010
+010000 st24 st16 000010010
+100000 st24 st16 000010010
+000101 st24 st16 000010010
+001001 st24 st16 000010010
+010001 st24 st16 000010010
+100001 st24 st24 010010010
+000110 st24 st16 000010010
+001010 st24 st16 000010010
+010010 st24 st16 000010010
+100010 st24 st16 000010010
+000111 st24 st13 100010010
+001011 st24 st0 000010010
+001111 st24 st13 100010010
+010011 st24 st0 000010010
+010111 st24 st13 100010010
+011011 st24 st0 000010010
+011111 st24 st13 100010010
+100111 st24 st29 100010010
+101011 st24 st16 000010010
+101111 st24 st29 100010010
+110011 st24 st16 000010010
+110111 st24 st29 100010010
+111011 st24 st16 000010010
+111111 st24 st29 100010010
+000010 st9 st0 000010011
+000001 st9 st9 000010011
+000000 st9 st9 000010011
+000011 st9 st9 000010011
+100011 st9 st25 000010011
+11--00 st9 st0 000010011
+1-1-00 st9 st0 000010011
+1--100 st9 st0 000010011
+-11-00 st9 st0 000010011
+-1-100 st9 st0 000010011
+--1100 st9 st0 000010011
+11--01 st9 st0 000010011
+1-1-01 st9 st0 000010011
+1--101 st9 st0 000010011
+-11-01 st9 st0 000010011
+-1-101 st9 st0 000010011
+--1101 st9 st0 000010011
+11--10 st9 st0 000010011
+1-1-10 st9 st0 000010011
+1--110 st9 st0 000010011
+-11-10 st9 st0 000010011
+-1-110 st9 st0 000010011
+--1110 st9 st0 000010011
+000100 st9 st0 000010011
+001000 st9 st0 000010011
+010000 st9 st0 000010011
+100000 st9 st0 000010011
+000101 st9 st0 000010011
+001001 st9 st0 000010011
+010001 st9 st0 000010011
+100001 st9 st0 000010011
+000110 st9 st9 010010011
+001010 st9 st0 000010011
+010010 st9 st0 000010011
+100010 st9 st0 000010011
+000111 st9 st13 100010011
+001011 st9 st0 000010011
+001111 st9 st13 100010011
+010011 st9 st0 000010011
+010111 st9 st13 100010011
+011011 st9 st0 000010011
+011111 st9 st13 100010011
+100111 st9 st29 100010011
+101011 st9 st16 000010011
+101111 st9 st29 100010011
+110011 st9 st16 000010011
+110111 st9 st29 100010011
+111011 st9 st16 000010011
+111111 st9 st29 100010011
+000010 st25 st16 000010100
+000001 st25 st25 000010100
+000000 st25 st25 000010100
+000011 st25 st9 000010100
+100011 st25 st25 000010100
+11--00 st25 st16 000010100
+1-1-00 st25 st16 000010100
+1--100 st25 st16 000010100
+-11-00 st25 st16 000010100
+-1-100 st25 st16 000010100
+--1100 st25 st16 000010100
+11--01 st25 st16 000010100
+1-1-01 st25 st16 000010100
+1--101 st25 st16 000010100
+-11-01 st25 st16 000010100
+-1-101 st25 st16 000010100
+--1101 st25 st16 000010100
+11--10 st25 st16 000010100
+1-1-10 st25 st16 000010100
+1--110 st25 st16 000010100
+-11-10 st25 st16 000010100
+-1-110 st25 st16 000010100
+--1110 st25 st16 000010100
+000100 st25 st16 000010100
+001000 st25 st16 000010100
+010000 st25 st16 000010100
+100000 st25 st16 000010100
+000101 st25 st16 000010100
+001001 st25 st16 000010100
+010001 st25 st16 000010100
+100001 st25 st16 000010100
+000110 st25 st25 010010100
+001010 st25 st16 000010100
+010010 st25 st16 000010100
+100010 st25 st16 000010100
+000111 st25 st13 100010100
+001011 st25 st0 000010100
+001111 st25 st13 100010100
+010011 st25 st0 000010100
+010111 st25 st13 100010100
+011011 st25 st0 000010100
+011111 st25 st13 100010100
+100111 st25 st29 100010100
+101011 st25 st16 000010100
+101111 st25 st29 100010100
+110011 st25 st16 000010100
+110111 st25 st29 100010100
+111011 st25 st16 000010100
+111111 st25 st29 100010100
+000010 st10 st0 000010101
+000001 st10 st10 000010101
+000000 st10 st10 000010101
+000011 st10 st10 000010101
+100011 st10 st26 000010101
+11--00 st10 st0 000010101
+1-1-00 st10 st0 000010101
+1--100 st10 st0 000010101
+-11-00 st10 st0 000010101
+-1-100 st10 st0 000010101
+--1100 st10 st0 000010101
+11--01 st10 st0 000010101
+1-1-01 st10 st0 000010101
+1--101 st10 st0 000010101
+-11-01 st10 st0 000010101
+-1-101 st10 st0 000010101
+--1101 st10 st0 000010101
+11--10 st10 st0 000010101
+1-1-10 st10 st0 000010101
+1--110 st10 st0 000010101
+-11-10 st10 st0 000010101
+-1-110 st10 st0 000010101
+--1110 st10 st0 000010101
+000100 st10 st0 000010101
+001000 st10 st0 000010101
+010000 st10 st0 000010101
+100000 st10 st0 000010101
+000101 st10 st0 000010101
+001001 st10 st0 000010101
+010001 st10 st0 000010101
+100001 st10 st0 000010101
+000110 st10 st0 000010101
+001010 st10 st10 010010101
+010010 st10 st0 000010101
+100010 st10 st0 000010101
+000111 st10 st13 100010101
+001011 st10 st0 000010101
+001111 st10 st13 100010101
+010011 st10 st0 000010101
+010111 st10 st13 100010101
+011011 st10 st0 000010101
+011111 st10 st13 100010101
+100111 st10 st29 100010101
+101011 st10 st16 000010101
+101111 st10 st29 100010101
+110011 st10 st16 000010101
+110111 st10 st29 100010101
+111011 st10 st16 000010101
+111111 st10 st29 100010101
+000010 st26 st16 000010110
+000001 st26 st26 000010110
+000000 st26 st26 000010110
+000011 st26 st10 000010110
+100011 st26 st26 000010110
+11--00 st26 st16 000010110
+1-1-00 st26 st16 000010110
+1--100 st26 st16 000010110
+-11-00 st26 st16 000010110
+-1-100 st26 st16 000010110
+--1100 st26 st16 000010110
+11--01 st26 st16 000010110
+1-1-01 st26 st16 000010110
+1--101 st26 st16 000010110
+-11-01 st26 st16 000010110
+-1-101 st26 st16 000010110
+--1101 st26 st16 000010110
+11--10 st26 st16 000010110
+1-1-10 st26 st16 000010110
+1--110 st26 st16 000010110
+-11-10 st26 st16 000010110
+-1-110 st26 st16 000010110
+--1110 st26 st16 000010110
+000100 st26 st16 000010110
+001000 st26 st16 000010110
+010000 st26 st16 000010110
+100000 st26 st16 000010110
+000101 st26 st16 000010110
+001001 st26 st16 000010110
+010001 st26 st16 000010110
+100001 st26 st16 000010110
+000110 st26 st16 000010110
+001010 st26 st26 010010110
+010010 st26 st16 000010110
+100010 st26 st16 000010110
+000111 st26 st13 100010110
+001011 st26 st0 000010110
+001111 st26 st13 100010110
+010011 st26 st0 000010110
+010111 st26 st13 100010110
+011011 st26 st0 000010110
+011111 st26 st13 100010110
+100111 st26 st29 100010110
+101011 st26 st16 000010110
+101111 st26 st29 100010110
+110011 st26 st16 000010110
+110111 st26 st29 100010110
+111011 st26 st16 000010110
+111111 st26 st29 100010110
+000010 st11 st0 000010111
+000001 st11 st11 000010111
+000000 st11 st11 000010111
+000011 st11 st11 000010111
+100011 st11 st27 000010111
+11--00 st11 st0 000010111
+1-1-00 st11 st0 000010111
+1--100 st11 st0 000010111
+-11-00 st11 st0 000010111
+-1-100 st11 st0 000010111
+--1100 st11 st0 000010111
+11--01 st11 st0 000010111
+1-1-01 st11 st0 000010111
+1--101 st11 st0 000010111
+-11-01 st11 st0 000010111
+-1-101 st11 st0 000010111
+--1101 st11 st0 000010111
+11--10 st11 st0 000010111
+1-1-10 st11 st0 000010111
+1--110 st11 st0 000010111
+-11-10 st11 st0 000010111
+-1-110 st11 st0 000010111
+--1110 st11 st0 000010111
+000100 st11 st0 000010111
+001000 st11 st0 000010111
+010000 st11 st0 000010111
+100000 st11 st0 000010111
+000101 st11 st0 000010111
+001001 st11 st0 000010111
+010001 st11 st0 000010111
+100001 st11 st0 000010111
+000110 st11 st0 000010111
+001010 st11 st0 000010111
+010010 st11 st11 010010111
+100010 st11 st0 000010111
+000111 st11 st13 100010111
+001011 st11 st0 000010111
+001111 st11 st13 100010111
+010011 st11 st0 000010111
+010111 st11 st13 100010111
+011011 st11 st0 000010111
+011111 st11 st13 100010111
+100111 st11 st29 100010111
+101011 st11 st16 000010111
+101111 st11 st29 100010111
+110011 st11 st16 000010111
+110111 st11 st29 100010111
+111011 st11 st16 000010111
+111111 st11 st29 100010111
+000010 st27 st16 000011000
+000001 st27 st27 000011000
+000000 st27 st27 000011000
+000011 st27 st11 000011000
+100011 st27 st27 000011000
+11--00 st27 st16 000011000
+1-1-00 st27 st16 000011000
+1--100 st27 st16 000011000
+-11-00 st27 st16 000011000
+-1-100 st27 st16 000011000
+--1100 st27 st16 000011000
+11--01 st27 st16 000011000
+1-1-01 st27 st16 000011000
+1--101 st27 st16 000011000
+-11-01 st27 st16 000011000
+-1-101 st27 st16 000011000
+--1101 st27 st16 000011000
+11--10 st27 st16 000011000
+1-1-10 st27 st16 000011000
+1--110 st27 st16 000011000
+-11-10 st27 st16 000011000
+-1-110 st27 st16 000011000
+--1110 st27 st16 000011000
+000100 st27 st16 000011000
+001000 st27 st16 000011000
+010000 st27 st16 000011000
+100000 st27 st16 000011000
+000101 st27 st16 000011000
+001001 st27 st16 000011000
+010001 st27 st16 000011000
+100001 st27 st16 000011000
+000110 st27 st16 000011000
+001010 st27 st16 000011000
+010010 st27 st27 010011000
+100010 st27 st16 000011000
+000111 st27 st13 100011000
+001011 st27 st0 000011000
+001111 st27 st13 100011000
+010011 st27 st0 000011000
+010111 st27 st13 100011000
+011011 st27 st0 000011000
+011111 st27 st13 100011000
+100111 st27 st29 100011000
+101011 st27 st16 000011000
+101111 st27 st29 100011000
+110011 st27 st16 000011000
+110111 st27 st29 100011000
+111011 st27 st16 000011000
+111111 st27 st29 100011000
+000010 st12 st0 000011001
+000001 st12 st12 000011001
+000000 st12 st12 000011001
+000011 st12 st12 000011001
+100011 st12 st28 000011001
+11--00 st12 st0 000011001
+1-1-00 st12 st0 000011001
+1--100 st12 st0 000011001
+-11-00 st12 st0 000011001
+-1-100 st12 st0 000011001
+--1100 st12 st0 000011001
+11--01 st12 st0 000011001
+1-1-01 st12 st0 000011001
+1--101 st12 st0 000011001
+-11-01 st12 st0 000011001
+-1-101 st12 st0 000011001
+--1101 st12 st0 000011001
+11--10 st12 st0 000011001
+1-1-10 st12 st0 000011001
+1--110 st12 st0 000011001
+-11-10 st12 st0 000011001
+-1-110 st12 st0 000011001
+--1110 st12 st0 000011001
+000100 st12 st0 000011001
+001000 st12 st0 000011001
+010000 st12 st0 000011001
+100000 st12 st0 000011001
+000101 st12 st0 000011001
+001001 st12 st0 000011001
+010001 st12 st0 000011001
+100001 st12 st0 000011001
+000110 st12 st0 000011001
+001010 st12 st0 000011001
+010010 st12 st0 000011001
+100010 st12 st12 010011001
+000111 st12 st13 100011001
+001011 st12 st0 000011001
+001111 st12 st13 100011001
+010011 st12 st0 000011001
+010111 st12 st13 100011001
+011011 st12 st0 000011001
+011111 st12 st13 100011001
+100111 st12 st29 100011001
+101011 st12 st16 000011001
+101111 st12 st29 100011001
+110011 st12 st16 000011001
+110111 st12 st29 100011001
+111011 st12 st16 000011001
+111111 st12 st29 100011001
+000010 st28 st16 000011010
+000001 st28 st28 000011010
+000000 st28 st28 000011010
+000011 st28 st12 000011010
+100011 st28 st28 000011010
+11--00 st28 st16 000011010
+1-1-00 st28 st16 000011010
+1--100 st28 st16 000011010
+-11-00 st28 st16 000011010
+-1-100 st28 st16 000011010
+--1100 st28 st16 000011010
+11--01 st28 st16 000011010
+1-1-01 st28 st16 000011010
+1--101 st28 st16 000011010
+-11-01 st28 st16 000011010
+-1-101 st28 st16 000011010
+--1101 st28 st16 000011010
+11--10 st28 st16 000011010
+1-1-10 st28 st16 000011010
+1--110 st28 st16 000011010
+-11-10 st28 st16 000011010
+-1-110 st28 st16 000011010
+--1110 st28 st16 000011010
+000100 st28 st16 000011010
+001000 st28 st16 000011010
+010000 st28 st16 000011010
+100000 st28 st16 000011010
+000101 st28 st16 000011010
+001001 st28 st16 000011010
+010001 st28 st16 000011010
+100001 st28 st16 000011010
+000110 st28 st16 000011010
+001010 st28 st16 000011010
+010010 st28 st16 000011010
+100010 st28 st28 010011010
+000111 st28 st13 100011010
+001011 st28 st0 000011010
+001111 st28 st13 100011010
+010011 st28 st0 000011010
+010111 st28 st13 100011010
+011011 st28 st0 000011010
+011111 st28 st13 100011010
+100111 st28 st29 100011010
+101011 st28 st16 000011010
+101111 st28 st29 100011010
+110011 st28 st16 000011010
+110111 st28 st29 100011010
+111011 st28 st16 000011010
+111111 st28 st29 100011010
+000011 st13 st0 000011011
+100011 st13 st16 000011011
+000001 st13 st13 100011011
+000010 st13 st13 100011011
+000000 st13 st13 100011011
+11--00 st13 st0 000011011
+1-1-00 st13 st0 000011011
+1--100 st13 st0 000011011
+-11-00 st13 st0 000011011
+-1-100 st13 st0 000011011
+--1100 st13 st0 000011011
+11--01 st13 st0 000011011
+1-1-01 st13 st0 000011011
+1--101 st13 st0 000011011
+-11-01 st13 st0 000011011
+-1-101 st13 st0 000011011
+--1101 st13 st0 000011011
+11--10 st13 st0 000011011
+1-1-10 st13 st0 000011011
+1--110 st13 st0 000011011
+-11-10 st13 st0 000011011
+-1-110 st13 st0 000011011
+--1110 st13 st0 000011011
+000100 st13 st0 000011011
+001000 st13 st0 000011011
+010000 st13 st0 000011011
+100000 st13 st0 000011011
+000101 st13 st0 000011011
+001001 st13 st0 000011011
+010001 st13 st0 000011011
+100001 st13 st0 000011011
+000110 st13 st0 000011011
+001010 st13 st0 000011011
+010010 st13 st0 000011011
+100010 st13 st0 000011011
+000111 st13 st13 100011011
+001011 st13 st0 000011011
+001111 st13 st13 100011011
+010011 st13 st0 000011011
+010111 st13 st13 100011011
+011011 st13 st0 000011011
+011111 st13 st13 100011011
+100111 st13 st29 100011011
+101011 st13 st16 000011011
+101111 st13 st29 100011011
+110011 st13 st16 000011011
+110111 st13 st29 100011011
+111011 st13 st16 000011011
+111111 st13 st29 100011011
+000011 st29 st0 000011100
+100011 st29 st16 000011100
+000001 st29 st29 100011100
+000010 st29 st29 100011100
+000000 st29 st29 100011100
+11--00 st29 st16 000011100
+1-1-00 st29 st16 000011100
+1--100 st29 st16 000011100
+-11-00 st29 st16 000011100
+-1-100 st29 st16 000011100
+--1100 st29 st16 000011100
+11--01 st29 st16 000011100
+1-1-01 st29 st16 000011100
+1--101 st29 st16 000011100
+-11-01 st29 st16 000011100
+-1-101 st29 st16 000011100
+--1101 st29 st16 000011100
+11--10 st29 st16 000011100
+1-1-10 st29 st16 000011100
+1--110 st29 st16 000011100
+-11-10 st29 st16 000011100
+-1-110 st29 st16 000011100
+--1110 st29 st16 000011100
+000100 st29 st16 000011100
+001000 st29 st16 000011100
+010000 st29 st16 000011100
+100000 st29 st16 000011100
+000101 st29 st16 000011100
+001001 st29 st16 000011100
+010001 st29 st16 000011100
+100001 st29 st16 000011100
+000110 st29 st16 000011100
+001010 st29 st16 000011100
+010010 st29 st16 000011100
+100010 st29 st16 000011100
+000111 st29 st13 100011100
+001011 st29 st0 000011100
+001111 st29 st13 100011100
+010011 st29 st0 000011100
+010111 st29 st13 100011100
+011011 st29 st0 000011100
+011111 st29 st13 100011100
+100111 st29 st29 100011100
+101011 st29 st16 000011100
+101111 st29 st29 100011100
+110011 st29 st16 000011100
+110111 st29 st29 100011100
+111011 st29 st16 000011100
+111111 st29 st29 100011100
+000011 st15 st0 000011101
+100011 st15 st16 000011101
+000001 st15 st15 000011101
+000010 st15 st15 000011101
+000000 st15 st15 000011101
+11--00 st15 st0 000011101
+1-1-00 st15 st0 000011101
+1--100 st15 st0 000011101
+-11-00 st15 st0 000011101
+-1-100 st15 st0 000011101
+--1100 st15 st0 000011101
+11--01 st15 st0 000011101
+1-1-01 st15 st0 000011101
+1--101 st15 st0 000011101
+-11-01 st15 st0 000011101
+-1-101 st15 st0 000011101
+--1101 st15 st0 000011101
+11--10 st15 st0 000011101
+1-1-10 st15 st0 000011101
+1--110 st15 st0 000011101
+-11-10 st15 st0 000011101
+-1-110 st15 st0 000011101
+--1110 st15 st0 000011101
+000100 st15 st0 000011101
+001000 st15 st0 000011101
+010000 st15 st0 000011101
+100000 st15 st0 000011101
+000101 st15 st0 000011101
+001001 st15 st0 000011101
+010001 st15 st0 000011101
+100001 st15 st0 000011101
+000110 st15 st0 000011101
+001010 st15 st0 000011101
+010010 st15 st0 000011101
+100010 st15 st0 000011101
+000111 st15 st13 100011101
+001011 st15 st15 011011101
+001111 st15 st13 100011101
+010011 st15 st0 000011101
+010111 st15 st13 100011101
+011011 st15 st0 000011101
+011111 st15 st13 100011101
+100111 st15 st29 100011101
+101011 st15 st31 011011101
+101111 st15 st29 100011101
+110011 st15 st16 000011101
+110111 st15 st29 100011101
+111011 st15 st16 000011101
+111111 st15 st29 100011101
+000011 st31 st0 000011110
+100011 st31 st16 000011110
+000001 st31 st31 000011110
+000010 st31 st31 000011110
+000000 st31 st31 000011110
+11--00 st31 st16 000011110
+1-1-00 st31 st16 000011110
+1--100 st31 st16 000011110
+-11-00 st31 st16 000011110
+-1-100 st31 st16 000011110
+--1100 st31 st16 000011110
+11--01 st31 st16 000011110
+1-1-01 st31 st16 000011110
+1--101 st31 st16 000011110
+-11-01 st31 st16 000011110
+-1-101 st31 st16 000011110
+--1101 st31 st16 000011110
+11--10 st31 st16 000011110
+1-1-10 st31 st16 000011110
+1--110 st31 st16 000011110
+-11-10 st31 st16 000011110
+-1-110 st31 st16 000011110
+--1110 st31 st16 000011110
+000100 st31 st16 000011110
+001000 st31 st16 000011110
+010000 st31 st16 000011110
+100000 st31 st16 000011110
+000101 st31 st16 000011110
+001001 st31 st16 000011110
+010001 st31 st16 000011110
+100001 st31 st16 000011110
+000110 st31 st16 000011110
+001010 st31 st16 000011110
+010010 st31 st16 000011110
+100010 st31 st16 000011110
+000111 st31 st13 100011110
+001011 st31 st15 011011110
+001111 st31 st13 100011110
+010011 st31 st0 000011110
+010111 st31 st13 100011110
+011011 st31 st0 000011110
+011111 st31 st13 100011110
+100111 st31 st29 100011110
+101011 st31 st31 011011110
+101111 st31 st29 100011110
+110011 st31 st16 000011110
+110111 st31 st29 100011110
+111011 st31 st16 000011110
+111111 st31 st29 100011110
+000011 st14 st0 000011111
+100011 st14 st16 000011111
+000001 st14 st14 000011111
+000010 st14 st14 000011111
+000000 st14 st14 000011111
+11--00 st14 st0 000011111
+1-1-00 st14 st0 000011111
+1--100 st14 st0 000011111
+-11-00 st14 st0 000011111
+-1-100 st14 st0 000011111
+--1100 st14 st0 000011111
+11--01 st14 st0 000011111
+1-1-01 st14 st0 000011111
+1--101 st14 st0 000011111
+-11-01 st14 st0 000011111
+-1-101 st14 st0 000011111
+--1101 st14 st0 000011111
+11--10 st14 st0 000011111
+1-1-10 st14 st0 000011111
+1--110 st14 st0 000011111
+-11-10 st14 st0 000011111
+-1-110 st14 st0 000011111
+--1110 st14 st0 000011111
+000100 st14 st0 000011111
+001000 st14 st0 000011111
+010000 st14 st0 000011111
+100000 st14 st0 000011111
+000101 st14 st0 000011111
+001001 st14 st0 000011111
+010001 st14 st0 000011111
+100001 st14 st0 000011111
+000110 st14 st0 000011111
+001010 st14 st0 000011111
+010010 st14 st0 000011111
+100010 st14 st0 000011111
+000111 st14 st13 100011111
+001011 st14 st0 000011111
+001111 st14 st13 100011111
+010011 st14 st14 001011111
+010111 st14 st13 100011111
+011011 st14 st0 000011111
+011111 st14 st13 100011111
+100111 st14 st29 100011111
+101011 st14 st16 000011111
+101111 st14 st29 100011111
+110011 st14 st30 001011111
+110111 st14 st29 100011111
+111011 st14 st16 000011111
+111111 st14 st29 100011111
+000011 st30 st0 000100000
+100011 st30 st16 000100000
+000001 st30 st30 000100000
+000010 st30 st30 000100000
+000000 st30 st30 000100000
+11--00 st30 st16 000100000
+1-1-00 st30 st16 000100000
+1--100 st30 st16 000100000
+-11-00 st30 st16 000100000
+-1-100 st30 st16 000100000
+--1100 st30 st16 000100000
+11--01 st30 st16 000100000
+1-1-01 st30 st16 000100000
+1--101 st30 st16 000100000
+-11-01 st30 st16 000100000
+-1-101 st30 st16 000100000
+--1101 st30 st16 000100000
+11--10 st30 st16 000100000
+1-1-10 st30 st16 000100000
+1--110 st30 st16 000100000
+-11-10 st30 st16 000100000
+-1-110 st30 st16 000100000
+--1110 st30 st16 000100000
+000100 st30 st16 000100000
+001000 st30 st16 000100000
+010000 st30 st16 000100000
+100000 st30 st16 000100000
+000101 st30 st16 000100000
+001001 st30 st16 000100000
+010001 st30 st16 000100000
+100001 st30 st16 000100000
+000110 st30 st16 000100000
+001010 st30 st16 000100000
+010010 st30 st16 000100000
+100010 st30 st16 000100000
+000111 st30 st13 100100000
+001011 st30 st0 000100000
+001111 st30 st13 100100000
+010011 st30 st14 001100000
+010111 st30 st13 100100000
+011011 st30 st0 000100000
+011111 st30 st13 100100000
+100111 st30 st29 100100000
+101011 st30 st16 000100000
+101111 st30 st29 100100000
+110011 st30 st30 001100000
+110111 st30 st29 100100000
+111011 st30 st16 000100000
+111111 st30 st29 100100000
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/exdev.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,130 @@
+/*
+ Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+                                  The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+ $Id$
+*/
+
+% develop Local ITL formula into state diagram
+%
+% Mon May 20 17:24:23 BST 1991
+% require([chop]).
+
+:-dynamic verbose/0,state/2,links/2.
+:-dynamic stay/3.
+
+:-assert(verbose).
+verbose(off) :- retract(verbose),fail;true.
+verbose(on) :- asserta(verbose).
+
+deve(ITL) :-
+	init,!,
+	expand(ITL,ITL0),		% chop standard form
+	itlstd(ITL0,StdNOW),		% BDT
+	assert(itl_state(StdNOW,1)),!,  % Initial State
+	deve0((1,ITL0)).
+
+deve0((S,ITL)) :-
+%        increment_state(ITL,ITL_1,S),
+        show_state(S,ITL),
+%	setof(Next,itldecomp(ITL,Next,S),
+	bagof(Next,itldecomp(ITL,Next,S),
+	    Nexts),!,
+	deve1(Nexts).
+deve0(_).
+
+deve1([]).
+deve1([H|T]) :- deve0(H),deve1(T).
+
+itldecomp(ITL,(NextS,Next),From) :-
+	init_var(current,From),
+	itl(ITL,Next,Cond),
+	%% showing
+	itlshow(Next,NextS,Cond,From).
+
+itlshow(Next,S,Cond,From):-
+	itlstd(Next,StdNext),
+	check_state(StdNext,Cond,New,S),
+	inc_var(itl_transition,_),
+	assertz(state(From,Cond,S)),
+	(links(S,From),!;assertz(links(S,From))),
+	!,
+	itlshow0(S,Cond,Next,New).
+
+itlshow0(S,Cond,Next,New) :- verbose,!,
+	itlshow1(S,Cond,Next,New),nl,!,New=1.
+itlshow0(0,_,_,0):- !,put(101),!,fail.   % "e"
+itlshow0(false,_,_,0):- !,put(102),!,fail.  % "f"
+itlshow0(true,_,_,0):- !,put(116),!,fail.  % "t"
+itlshow0(_,_,_,0):- !,put(46),!,fail.    % "."
+itlshow0(S,_,_,1):- !,write(S),put(46),ttyflush,!.  % "."
+
+itlshow1(0,Cond,_,_):-!,
+	write(Cond),write('->'),write(empty).
+itlshow1(true,Cond,_,_):-!,
+	write(Cond),write('->'),write(true).
+itlshow1(false,Cond,_,_):-!,
+	write(Cond),write('->'),write(false).
+itlshow1(S,Cond,_,0):-!,
+	write(Cond),write('->'),write(S).
+itlshow1(S,Cond,Org,1):-
+	write(Cond),write('->'),write(S),
+	put(9),write(Org),!.
+
+init :-
+	subterm_init,
+	abolish(state,3),
+	asserta(state(true,[more],true)),
+	asserta(state(true,[empty],0)),
+        abolish(itl_state,2),
+        abolish(stay,3),asserta(stay(0,0,0)),
+        asserta(itl_state(false,false)),
+        asserta(itl_state(empty,0)),
+        asserta(itl_state(true,true)),
+	abolish(links,2),asserta(links(true,true)),
+	init_var(itl_transition,1),
+	init_var(itl_state_number,1),!.
+
+show_state(S,ITL) :-
+	nl,write('state('),write(S),  % (
+	(verbose,write(' , '), write(ITL),write(')'),nl;write(')')),!.
+
+check_state(true,[more |_],0,true):-!.
+check_state(true,[empty|_],0,0):-!.
+check_state(false,_,0,false):-!.
+check_state(STD,_,0,S):-
+	itl_state(STD,S),!.
+check_state(STD,_,1,S):-
+	inc_var(itl_state_number,S),
+	assert(itl_state(STD,S)),!.
+
+init_var(X,_) :- functor(F,X,1),assert(F),fail.
+init_var(X,_) :- functor(F,X,1),retract(F),fail.
+init_var(X,V) :- functor(F,X,1),arg(1,F,V),assert(F),!.
+inc_var(Name,X1) :- 
+        functor(F,Name,1),retract(F),arg(1,F,X),
+        X1 is X+1,functor(F1,Name,1),arg(1,F1,X1),
+        asserta(F1),!.
+
+%init_var(X,_) :- recorded(X,_,Ref),erase(Ref),fail.
+%init_var(X,V) :- recorda(X,V,_).
+%inc_var(Name,X1) :- 
+%	recorded(Name,X,Ref),X1 is X+1,
+%	erase(Ref),recorda(Name,X1,_).
+
+increment_state(stay(P,now),stay(P,S),S) :- !,
+      (stay(P,F,S);assertz(stay(P,F,S))),!.
+increment_state(N,N,_) :- atomic(N),!.
+increment_state(P,R,S) :- functor(P,H,N),functor(R,H,N),
+      increment_state_arg(N,P,R,S).
+increment_state_arg(0,_P,_R,_):-!.
+increment_state_arg(N,P,R,S):-arg(N,P,PA),arg(N,R,RA),
+      N1 is N-1,increment_state(PA,RA,S),
+      increment_state_arg(N1,P,R,S).
+
+/* end */
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gm/demoi	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,7 @@
+:- use_module(library(gmlib)).
+
+:-[init],compile(display).
+% :-start.
+% :-display.
+
+display(Host) :- start(Host),display.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gm/demoim	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,25 @@
+% Sat May 22 11:43:11 JST 1993
+
+:- use_module(library(gmlib)).
+
+?-op(900,xfy,[(&),('&&')]).
+?-op(700,xfy,['<->','\=',proj]).
+?-op(60,fy,['~','#','<>', '@',^]).
+?-op(60,fy,[*]).
+
+:-
+  unix(system('make tmpa M=lite:')),
+  ['.tmpc'],
+  unix(system('make display M=lite:')),
+  ['.tmpc'].
+
+make :- unix(system('make M=lite:')),consult(lite:['.tmpc','.tmpl']).
+
+:- use_module(lite).
+:- load(lite:[ex,kiss_ex,display]).
+
+% :-start.
+% :-display.
+% display(Host) :- start(Host),display.
+
+% end
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/gm/display.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,269 @@
+%
+% Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+%                                  The University, Newcastle upton Tyne
+%
+% Everyone is permitted to copy and distribute verbatim copies
+% of this license, but changing it is not allowed.  You can also
+% use this wording to make the terms for other programs.
+%
+% Please, send your comments to kono@csl.sony.co.jp
+% $Id$
+%
+% Display Interface for ITL Verifier
+%    Using SICStus Prolog's Graphic Manager ( InterViews Package)
+%
+
+:- use_module(library(gmlib)).
+
+:-dynamic font/2.
+
+small :- (retract(font(_,_));true),assert(font("7x14",14)).
+large :- (retract(font(_,_));true),assert(font("12x24",24)).
+
+:-small.
+% font("7x14",14).
+
+width(W,H):-
+   font(_,Fs),
+   W is integer(1000/24*Fs), H is integer(500/24*Fs).
+
+display:-
+   tell(tmp),told,see(tmp),seen,
+   font(Font,_),width(W,H),
+   View <= view(W,H),
+   View=>setfont(Font),
+   In <= input("",Font),In => enable,
+   Execute <= button("Execute",exe,font(Font)),Execute=>disable,
+   Counter <= button("Counter Example",diag,font(Font)), Counter=>disable,
+   Map     <= button("Map",map,font(Font)), Map=>disable,
+   ST      <= output("State: Edge:",Font),
+   K <= window("ITL Verifier",vbox([scroller(View),
+	    space(
+	    hbox([output("Enter temporal logic formula:",Font),space,ST])),
+	    space(frame(In)),
+	    border,
+	    space(
+	    hbox([space,
+		  button("Verify",verify,font(Font)),
+		  space,Execute, space,Counter, space,
+		  vbox([
+		  button("Verbose on",verbose(on),
+		    [style(radio),font(Font)]),
+		  button("        off",verbose(off),
+		    [style(radio),font(Font)])
+		  ]),
+		  Map,
+		  space,
+		  button("Quit",quit,font(Font)),
+		  space]))
+	    ])),
+     verbose(off),
+   _ <= buttonstate(verbose(_),off),
+   K => open,
+   handle(In,View,K,[Execute,Counter,Map,ST]).
+
+handle(In,View,K,N):-
+   K => waitevent(E),
+   handle(E,In,View,K,N).
+handle(E,In,View,K,N):-
+   (E=button(_,verify);E=menu(_,verify);E=return(_,_)) ->
+	handle_verify(In,View,K,N), !,handle(In,View,K,N)
+	;
+   E=button(_,map) -> 
+        clear_event(K), View=>update, width(_,H),
+        view_state(View,H),!,handle(In,View,K,N)
+	;
+   E=button(_,exe) ->
+	[Mb,Eb|_]=N, (Mb=>enable,Eb=>enable,
+	display_exe(View),
+	K=>waitevent(E1), handle_more(E1,In,View,K,N,exe),!;
+	Mb=>disable,Eb=>enable,
+	!, handle(In,View,K,N))
+	;
+   E=button(_,diag) ->
+	[Mb,Eb|_]=N, (Mb=>enable,Eb=>enable,
+	display_diag(View),
+	K=>waitevent(E1),handle_more(E1,In,View,K,N,diag),!;
+	Mb=>enable,Eb=>disable,
+	!, handle(In,View,K,N))
+	;
+   E=button(_,verbose(on)) -> verbose(on),!, handle(In,View,K,N)
+	;
+   E=button(_,verbose(off)) -> verbose(off),!, handle(In,View,K,N)
+	;
+   E=button(_,noevent) ->!, handle(In,View,K,N) 
+	;
+   K => close.           % all end
+
+clear_event(W) :- repeat,W=>nextevent(E),E=noevent.
+
+handle_verify(In,_,_,N) :-
+	[Mb,Eb,Map,ST|_]=N,Mb=>disable,Eb=>disable,Map=>disable,
+	In => in(Text),s2term(Text,Term),
+	command(Term,Term1),!,
+	t2string(Term1,Text0), In => out(Text0),
+	(Term1=prolog(_); ex(Term1)),!,
+	Mb=>enable,Eb=>enable,Map=>enable,
+	(verbose ; display_statistics(ST)),!.
+
+display_statistics(ST) :-
+	itl_state_number(S), % number of state
+        itl_transition(L),   % number of transition
+        name(S,Ss),name(L,Ls),
+        append("State: ",Ss,S0),append(S0," Edge:",S1),append(S1,Ls,S2),
+        ST=>out(S2),!.
+
+% 
+handle_more(Ev,_,_,_,_,E) :-
+   Ev=button(_,E),
+   !,fail.        % find another solution
+handle_more(Ev,In,View,K,N,_) :-
+   Ev=button(_,Label),button_event(Label),!,
+   handle(Ev,In,View,K,N).
+handle_more(Ev,In,View,K,N,_) :-
+   Ev=return(_,_),!,
+   handle(Ev,In,View,K,N).
+handle_more(_,In,View,K,N,E) :-!,
+   View=>getevent(Ev),
+   handle_more(Ev,In,View,K,N,E).
+
+button_event(verify).
+button_event(diag).
+button_event(exe).
+button_event(quit).
+button_event(map).
+button_event(verbose(on)).
+button_event(verbose(off)).
+%%---------------------------------------------------------------------
+% display_diagnosis
+display_diag(View) :- diag(X),
+	write_display_diag(X,View).
+
+% display_execution exapmle.
+display_exe(View) :- exe(Z),
+	write_display_diag(Z,View).
+
+write_display_diag(counter_example(Hist),View) :-!,display_ce(Hist,View).
+write_display_diag(execution(Hist),View) :-!,display_ce(Hist,View).
+write_display_diag(R,View):-!,
+	atomic(R),name(R,Text),
+	View=>clear,View=>string(0,0,Text).
+
+display_ce(Hist,View) :-
+	font(_,Fs),
+	View=>clear,  % View=>batchmode,
+        View=>setpattern(4),
+	X is Fs/2,Y=0,W is integer(60/24*Fs),H is integer(60/24*Fs),
+	(variable_list(L);L=[]),append(L,['Time'],L1),!,
+	display_var(['State'|L1],View,X,Y,H,X,X1),
+	X2 is X1+X,
+	display_ce(Hist,L,View,X2,Y,W,H,0). % ,View=>batchmodeoff.
+display_var([],_,_,_,_,X,X):-!.
+display_var([Var|L],View,X,Y,H,X1,X2):-
+	Y1 is Y+H,
+	name(Var,VarText),
+	View=>stringlength(VarText,Len),
+	(X1>X+Len,X3=X1;X3 is X+Len),!,
+	View=>string(X,Y,VarText),
+	display_var(L,View,X,Y1,H,X3,X2).
+
+display_ce([],_,_,_,_,_,_,_):-!.
+display_ce([(S->[_|Cond])|Hist],L,View,X,Y,W,H,T) :-
+	X1 is X+W,Y1 is Y+H,T1 is T+1,
+	name(S,SText),View=>string(X1,Y,SText),
+	display_now(L,Cond,View,X1,Y1,W,H,T),
+	display_ce(Hist,L,View,X1,Y,W,H,T1).
+
+display_now([],_,View,X,Y,_,_,T):-!,
+	name(T,SText),View=>string(X,Y,SText).
+display_now([V|Vr],Cond,View,X,Y,W,H,T):-
+	display_state(Cond,V,View,X,Y,W,H),
+	Y1 is Y+H,
+	display_now(Vr,Cond,View,X,Y1,W,H,T).
+
+display_state([V|_],V,View,X,Y,W,H) :-!, % true
+	X2 is X+W,Y2 is Y+H,
+	View=>fillrect(X,Y,X2,Y2).
+display_state([not(V)|_],V,View,X,Y,W,H) :-!, % false
+	X2 is X+W,Y2 is Y+H,
+	View=>rect(X,Y,X2,Y2).
+display_state([_|T],V,View,X,Y,W,H) :-!,
+	display_state(T,V,View,X,Y,W,H).
+display_state([],_,View,X,Y,W,H) :-!,    % unknown
+	X2 is X+W,Y2 is Y+H/2,Y3 is Y2+3,
+	View=>rect(X,Y2,X2,Y3).
+
+s2term("",true):-!.
+s2term(Text,Term) :-
+	telling(O),
+	tell(tmp),format("~s.~n",[Text]),told,tell(O),
+	seeing(I),
+	see(tmp),on_exception(Er,read(Term),read_error(Term,Er,I,O)),
+	see(tmp),seen,see(I),!.
+s2term(_,true):-tell(tmp),told,see(tmp),seen.
+
+read_error(true,Er,I,O) :- 
+	tell(tmp),told,see(tmp),seen,
+	see(I),tell(O),unix(system('rm tmp')),
+	write('read error:'),write(Er),nl.
+
+t2string(Term,Text) :-
+	telling(O),
+	tell(tmp),write(Term),told,tell(O),
+	seeing(I),
+	see(tmp),get0(C),read_string(C,Text),see(tmp),seen,see(I),!.
+t2string(_,true):-tell(tmp),told,see(tmp),seen.
+
+read_string(-1,[]) :- !.
+read_string(C,[C|T]) :- 
+	get0(C1),read_string(C1,T).
+
+
+command(demo(X),Term):-!,demo(X,Term).   % predefined examples
+command(ex(X),Term):-!,ex(X,Term).
+command(prolog(X,P),X):-!,call(P).
+command(prolog(P),prolog(P)):-!,call(P).
+command(X,X).
+
+view_state :-
+   make_state_view(View,W,K),
+   view_state(View,W),View=>enable,
+   repeat,
+       K=>waitevent(E),E=down(_,_,_,_),K=>close.
+
+make_state_view(View,W,K) :-
+   width(W,_),font(Font,_),
+   View <= view(W,W),
+   View=>setfont(Font),
+   K <= window("State Pattern",vbox([scroller(View) ])),
+   K => open.
+
+view_state(View,W) :-
+   View=>setpattern(0),
+   itl_state_number(S),
+   View=>clear,View=>disable,View=>update, % View=>batchmode,
+   View=>string(0,W,"T"),                  % This prevents core dump
+   D0 is integer(W/(S+1)),(D0=0,D=1;D=D0),!,
+   view_state_write(View,W,S,D).
+view_state_write(View,W,S,D) :- 
+   links(X,Y), link_translate(X,Y,X1,Y1,W,S),
+%   View=>fillcircle(X1,Y1,2),fail.
+%   View=>circle(X1,Y1,2),
+    X2 is X1+D,Y2 is Y1+D,View=>fillrect(X1,Y1,X2,Y2),
+    View=>update,
+    fail.
+view_state_write(_View,_,_,_):-true. % View=>batchmodeoff.
+
+link_translate(false,Y,X1,Y1,W,S) :- !,
+    link_translate(S,Y,X1,Y1,W,S).
+link_translate(X,false,X1,Y1,W,S) :- !,
+    link_translate(X,S,X1,Y1,W,S).
+link_translate(X,Y,X1,Y1,W,S) :- number(X),number(Y),!,
+    X1 is integer(X*W/(S+1))+1, Y1 is integer(Y*W/(S+1)).
+link_translate(X,_,X1,0,W,S) :- number(X),!,
+    X1 is integer(X*W/(S+1)).
+link_translate(_,Y,0,Y1,W,S) :- number(Y),!,
+    Y1 is integer(Y*W/(S+1)).
+link_translate(_,_,0,0,_,_).
+
+%%
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/init	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,14 @@
+%?-op(900,xfy,[(&),('&&')]).
+%?-op(700,xfy,['<->','\=',proj]).
+%?-op(600,xfy,['=>','<=']).
+%?-op(60,fy,['~','#','<>', '@',^]).
+%?-op(60,fy,[*]).
+%?-op(1200,fy,[dynamic]).
+
+:-[op].
+make :- unix(system('make tmpa')),['.tmpc','.tmpl'].
+?- unix(system('make tmpa')),['.tmpc','.tmpa'] ;
+
+  ['ndcomp.pl','bdtstd.pl','chop.pl','diag.pl','ex.pl','cp.pl'].
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/initgm	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,25 @@
+% Sat May 22 11:43:11 JST 1993
+
+:- use_module(library(gmlib)).
+
+?-op(900,xfy,[(&),('&&')]).
+?-op(700,xfy,['<->','\=',proj]).
+?-op(60,fy,['~','#','<>', '@',^]).
+?-op(60,fy,[*]).
+
+:-
+  unix(system('make all M=lite:')),
+  ['.tmpc'],
+  unix(system('make display M=lite:')),
+  ['.tmpc'].
+
+make :- unix(system('make M=lite:')),consult(lite:['.tmpc','.tmpl']).
+
+:- use_module(lite).
+:- load(lite:[ex,kiss_ex,display]).
+
+% :-start.
+% :-display.
+% display(Host) :- start(Host),display.
+
+% end
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/initm	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,26 @@
+
+% Sat May 22 11:43:11 JST 1993
+
+% ?-op(900,xfy,[(&),('&&')]).
+% ?-op(700,xfy,['<->','\=',proj]).
+% ?-op(700,xfy,['=>','<=']).
+% ?-op(60,fy,['~','#','<>', '@',^]).
+% ?-op(60,fy,[*]).
+
+:-lite:[op].
+
+:-
+  unix(system('make tmpa M=lite:')),
+  ['.tmpc'].
+
+make :- unix(system('make tmpa M=lite:')),
+   consult(lite:['.tmpc','.tmpl']).
+
+:- use_module(lite).
+:- ensure_loaded(lite:[ex,kiss_ex]).
+
+% :-start.
+% :-display.
+% display(Host) :- start(Host),display.
+
+% end
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/initr	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,29 @@
+
+% Sat May 22 11:43:11 JST 1993
+
+% ?-op(900,xfy,[(&),('&&')]).
+% ?-op(700,xfy,['<->','\=',proj]).
+% ?-op(700,xfy,['=>','<=']).
+% ?-op(60,fy,['~','#','<>', '@',^]).
+% ?-op(60,fy,[*]).
+
+:-use_module(library(system)).
+:-lite:[op].
+
+:-
+  system('make tmpa M=lite:'),
+  ['.tmpc'].
+
+make :- system('make tmpa M=lite:'),
+   consult(lite:['.tmpc','.tmpl']).
+
+:- use_module(lite).
+:- ensure_loaded(lite:[ex,kiss_ex]).
+:- ensure_loaded(lite:[dvcomp]).
+:- ensure_loaded(lite:[rstd]).
+
+% :-start.
+% :-display.
+% display(Host) :- start(Host),display.
+
+% end
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/initv	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,49 @@
+
+% Sat May 22 11:43:11 JST 1993
+
+:-  module(lite,[
+	ex/1,  			% ex(ITL)   verification predicate
+	ex/2,			% ex(No,Example)
+	diag/1,diag/0, 		% find counter example
+	exe/1, exe/0,		% find sample execution
+	verbose/1, 		% verbose mode
+	lazy/1,			% lazy mode (dvcomp only)
+	kiss/0, 		% kiss format geneartion
+	read_kiss/1,		% read KISS2 format
+	read_kiss/4,		% read KISS2 format
+	read_kiss/3,		% read KISS2 format
+	tgen/0, 		% tokio clause geneartion
+	itl/1,			% one step tableau expansion
+	itl/3,			%     " in detail
+	itl_statistics/0,  	% show number of state etc. 
+	st/3,			% external state machine
+	st_variables/2,		%     its variables
+	sbterm/0,		% show sub term/ state database
+	display/0, large/0, small/0, 	% show state database
+	start/0, display_diag/1, display_exe/1,
+	state/0 		% show state database
+]).
+
+% ?-op(900,xfy,[(&),('&&')]).
+% ?-op(700,xfy,['<->','\=',proj]).
+% ?-op(700,xfy,['=>','<=']).
+% ?-op(60,fy,['~','#','<>', '@',^]).
+% ?-op(60,fy,[*]).
+
+:-[op].
+
+:-
+  unix(system('make tmpa M=lite:')),
+  ['.tmpc'].
+
+make :- unix(system('make tmpa M=lite:')),
+   consult(['.tmpc','.tmpl']).
+
+:- ensure_loaded([dvcomp,bdtstd,chop,diag,kiss,ex,cp]).
+:- ensure_loaded([ex,kiss_ex]).
+
+% :-start.
+% :-display.
+% display(Host) :- start(Host),display.
+
+% end
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/itl.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,30 @@
+
+gather(A,X,X1) :- atomic(A),!,
+	X = [A|X1].
+gather(F,X,X1) :- functor(F,_,N),!,
+	gather_args(0,N,F,X,X1).
+gather_args(N,N1,_,X,X) :- N =:= N1,!.
+gather_args(N,N1,F,X,X1) :- 
+	N0 is N+1,arg(N0,F,A), 
+	gather(A,X,X0),gather_args(N0,N1,F,X0,X1).
+
+
+itl(A,C,T,X,X) :- atomic(A),!,
+	itl_variable(C,A,T).
+itl_variable(C,A,T) :-
+	true(C,A,C,C1),!,
+
+	itl_false(C,A,F,X0,X1).
+itl_true(C,A,T,X,X) :-
+itl_true(_,_,X,X) :-
+
+true([],A,C,[A|C]):-!.
+true([A|_],A,C,C):-!.
+true([not(A)|_],A,C,C):-!,fail.
+true([_|T],A,C,C1):-!,true(T,A,C,C1).
+
+false([],A,C,[A|C]):-!.
+false([not(A)|_],A,C,C):-!.
+false([A|_],A,C,C):-!,fail.
+false([_|T],A,C,C1):-!,false(T,A,C,C1).
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/itlstd.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,82 @@
+/*
+ Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+                                  The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+ $Header$
+*/
+
+% ITL standarization
+%
+% Wed Jun 19 12:11:29 BST 1991
+%
+% a standard form of ITL, based on subterm classification
+%
+%   P = \Sum Pn & Px
+%   Q = \Sum Qn & Qx
+%   P & Q =  	empty,Pn,Qn ;        	( Px = Qx = true)
+%		more,Pn,Qn & Qx; 	( Px = true )
+%		more,Pn,(Px & Q)
+%
+subterm_init :- 
+	abolish(sb,3),
+	asserta((sb(-1,[],[]))),
+	abolish(sbn,1),
+	asserta(sbn(0)),
+        abolish(itl_state,2),
+        assertz(itl_state(([[]->false]),false)),
+        assertz(itl_state(([[]->true]),0)),!.
+
+
+std_check(I,J,N) :-
+	sb(N,I,J),!.
+std_check(I,J,N1) :-
+	retract(sbn(N)),N1 is N+1,asserta(sbn(N1)),
+	assertz(sb(N1,I,J)),!.
+
+itlstd(P,List) :- 
+	setof(N,subterm(P,N),List),!.
+
+subterm(P,C->T) :-
+	subterm(P,T,[],C0),
+	sortC(C0,C).
+	
+% bubble sort
+sortC([],[]).
+sortC([H|T],[Min|Y]):-
+    min(T,H,Min,Rest),
+    sortC(Rest,Y).
+
+min([],X,X,[]).
+min([H|T],X,Y,[H|S]) :- ord(H,X),!,min(T,X,Y,S).
+min([H|T],X,Y,[X|S]) :- min(T,H,Y,S).
+
+ord(not(X),not(Y)) :- !,X @> Y.
+ord(X,not(Y))  :- !,X @> Y.
+ord(not(X),Y)  :- !,X @> Y.
+ord(X,Y)   :- !,X @> Y.
+
+subterm(true,true,C,C):-!.
+subterm(false,false,C,C):-!.
+subterm(P,V,C,C1) :- atomic(P),!, local(V,P,C,C1).
+subterm(up(P),V,C,C1) :- !, local(V,up(P),C,C1).
+subterm(down(P),V,C,C1) :- !, local(V,down(P),C,C1).
+subterm((false&_),false,C,C) :-!.
+subterm((_&false),false,C,C) :-!.
+subterm((P&Q),V,C,C1) :-!,
+	std_check(P,Q,N),local(V,N,C,C1).
+subterm(@(Q),V,C,C1) :-!,
+	std_check(@(Q),'$$$',N),local(V,N,C,C1).
+subterm(^(Q),V,C,C1) :-!,
+	std_check(^(Q),'$$$',N),local(V,N,C,C1).
+subterm((P,Q),V,C,C1) :-!,
+	subterm(P,PV,C,C0),subterm(Q,QV,C0,C1), and(PV,QV,V).
+subterm((P;Q),V,C,C1) :-!,
+	subterm(P,PV,C,C0),subterm(Q,QV,C0,C1), or(PV,QV,V).
+subterm(not(P),V,C,C1) :-!,
+	subterm(P,PV,C,C1),negate(PV,V).
+% end %
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/kiss.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,274 @@
+/*
+ Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+                                  The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+ $Id$
+*/
+
+% :- dynamic st_variables/2.
+
+set_input_var(L) :- abolish(input_variable_list,1),
+	asserta(input_variable_list(L)).
+
+kiss :-
+	(variable_list(L);L=[]),
+	(st_variables(In,_);In=[]),
+	delete(L,In,Out),
+	write('# '),write_kiss_var_list(In),write((->)),
+		write_kiss_var_list(Out),nl,
+%	write('.v '),length(L,Ll),write(Ll),nl,
+	write('.p '),itl_transition(X),write(X),nl,
+	write('.s '),itl_state_number(Y),write(Y),nl,
+	write('.i '),length(In,Inl),write(Inl),nl,
+	write('.o '),length(Out,Outl),write(Outl),nl,
+	kiss(In,Out).
+
+kiss(In,Out) :-
+	state(S,Cond,D),
+	write_kiss(S,Cond,D,In,Out),fail.
+kiss(_,_) :- write('.e'),nl.
+
+write_kiss_var_list([]):-!.
+write_kiss_var_list([H|L]):-!,write(H),put(32),   % " "
+	write_kiss_var_list(L).
+
+write_kiss(S,Cond,D,In,Out) :-
+       write_kiss_var(In,Cond),put(32),   % " "
+       write_kiss_state(S),
+       write_kiss_state(D),
+       write_kiss_var(Out,Cond),nl,!.
+
+write_kiss_state(0) :-	!,
+       write(se),put(9).
+write_kiss_state(true) :-!,
+       write(st),put(9).
+write_kiss_state(false) :-	!,
+       write(sf),put(9).   
+write_kiss_state(S) :-	!,
+       write(s),write(S),put(9).
+
+delete([],_,[]) :-!.
+delete([H|X],L,Y) :- member(H,L),!,delete(X,L,Y).
+delete([H|X],L,[H|Y]) :- delete(X,L,Y).
+
+write_kiss_var([],_):-!.
+write_kiss_var([H|L],Cond) :- member(H,Cond),!,write(1),
+	write_kiss_var(L,Cond).
+write_kiss_var([H|L],Cond) :- member(not(H),Cond),!,write(0),
+	write_kiss_var(L,Cond).
+write_kiss_var([_|L],Cond) :- write(-),
+	write_kiss_var(L,Cond).
+
+tgen :-
+	(variable_list(L);L=[]),
+	(st_variables(In,_);In=[]),
+	delete(L,In,Out),
+	write(('?-'(static(L)))),put(46),nl,  % "."
+	make_print_state(L,L1,LL),
+	write((print_state :- L1,write(LL))),put(46),nl,
+	tgen(In,Out).
+tgen(In,Out) :-
+	state(S,Cond,D),
+	write_tclause(S,Cond,D,In,Out),fail.
+tgen(_,_).
+
+make_print_state([H],(H1= *(H)),((H) = H1)):-!.
+make_print_state([H|L],((H1= *(H)),L1),(((H) = H1),LL1)):-
+	make_print_state(L,L1,LL1).
+
+write_tclause(S,[empty|Cond],true,In,Out) :-!,
+	write_tstate(S), write(' :- '), % write(empty),put(44), % ","
+	write_tcondition(In,Out,Cond),
+	write(true), put(46),nl.  % true, empty or false  "."
+write_tclause(_S,[empty|_Cond],false,_In,_Out) :-!.
+%write_tclause(S,[empty|Cond],false,In,_Out) :-!,
+%	write_tstate(S), write(' :- '),write(empty),put(44),
+%	write_tcondition(In,[],Cond), % don't touch output
+%	write(fail),put(46),nl.  % true, empty or false
+write_tclause(S,[empty|Cond],D,In,Out) :-!,
+	write_tstate(S), write(' :- '), % write(empty),put(44), % ","
+	write_tcondition(In,Out,Cond),
+	write_tstate(D),put(46),nl.  % true, empty or false  "."
+write_tclause(_S,[more|_Cond],false,_In,_Out) :-!.
+%write_tclause(S,[more|Cond],false,In,_Out) :-!,
+%	write_tstate(S), write(' :- '),write(more),put(44),  % ","
+%	write_tcondition(In,[],Cond),  % don't touch output
+%	write(fail), put(46),nl.
+write_tclause(S,[more|Cond],true,In,Out) :-!,
+	write_tstate(S), write(' :- '),write(more),put(44),
+	write_tcondition(In,Out,Cond),
+	write(true), put(46),nl.
+write_tclause(S,[more|Cond],D,In,Out) :-!,
+	write_tstate(S), write(' :- '),write(more),put(44),
+	write_tcondition(In,Out,Cond),
+	write((@)),write_tstate(D),
+	put(46),nl.
+
+write_tcondition(In,Out,Cond) :-
+	write_tvar(In,Cond,'= '),
+	write_tvar(Out,Cond,':= ').
+write_tvar([],_,_):-!.
+write_tvar([H|L],Cond,Eq) :- member(H,Cond),!,
+	write(*(H)),write(Eq),write(1),put(44),
+	write_tvar(L,Cond,Eq).
+write_tvar([H|L],Cond,Eq) :- member(not(H),Cond),!,
+	write(*(H)),write(Eq),write(0),put(44),
+	write_tvar(L,Cond,Eq).
+write_tvar([_|L],Cond,Eq) :- 
+	write_tvar(L,Cond,Eq).
+
+write_tstate(0) :-	!,
+       write(empty).
+write_tstate(true) :-!,
+       write(true).
+write_tstate(false) :-	!,
+       write(fail).
+write_tstate(S) :-	!,
+       write(s),write(S).
+
+/*
+
+KISS2 format
+
+.i 4 
+.o 2 
+.p 60 
+.s 10
+--01 st0 st0 00
+
+*/
+
+read_kiss(File) :-
+	read_kiss(File,empty).
+
+read_kiss(File,Emode) :-
+	see(File),
+	get0(C), read_kiss_header(C,C1,IL,OL),
+	nonvar(IL),nonvar(OL),
+	make_vars(IL,"i",0,In),
+	make_vars(OL,"o",0,Out),
+	init_read_kiss(In,Out,IL,OL),
+	read_kiss_body(C1,In,Out,Emode),
+	seen.
+read_kiss(_,_) :- write('Error'),nl,seen.
+
+make_vars(N,_,_,[]) :- N =< 0,!.
+make_vars(N,V,M,[H|L]) :-!,
+	name(M,LM),append(V,LM,LH), name(H,LH),
+	N1 is N-1,M1 is M+1,
+	make_vars(N1,V,M1,L).
+
+read_kiss(File,In,Out,Emode) :-
+	see(File),
+	read_kiss(In,Out,Emode),!,
+	seen.
+read_kiss(_,_,_,_) :- write('Error'),nl,seen.
+
+read_kiss(In,Out,Emode) :-
+	get0(C), read_kiss_header(C,C1,IL1,OL1),
+	((var(In),make_vars(IL1,"i",0,In));true),
+	((var(Out),make_vars(OL1,"o",0,Out));true),
+	init_read_kiss(In,Out,IL,OL),
+	check_vars(IL,OL,IL1,OL1),
+	read_kiss_body(C1,In,Out,Emode).
+
+init_read_kiss(In,Out,IL,OL) :-
+	abolish(st_variables,2),
+	abolish(st,3),
+	assert(st_variables(In,Out)),
+	assert(st(true,true,true)),
+	length(In,IL),length(Out,OL).
+
+check_vars(IL,0,IL,_) :-!.  % ignore output
+check_vars(IL,OL,IL,OL) :-!.
+check_vars(IL,_OL,IL1,_OL1) :-IL=\=IL1,
+	write('Input variable number is wrong'),nl,fail.
+check_vars(_IL,OL,_IL1,OL1) :-OL=\=OL1,
+	write('Output variable number is wrong'),nl,fail.
+
+read_kiss_header(C,C2,IL,OL) :-[C]=".",!, get(C0),
+	read_kiss_header1(C0,C1,IL,OL),
+	read_kiss_header(C1,C2,IL,OL).
+    read_kiss_header1(C,C2,IL,_OL):-[C]="i",!,get(C0),
+	read_number(C0,C1,IL),skip_line(C1,C2).
+    read_kiss_header1(C,C2,_IL,OL):-[C]="o",!,get(C0),
+	read_number(C0,C1,OL),skip_line(C1,C2).
+    read_kiss_header1(C,C1,_,_):-[C]="p",!,
+	skip_line(C,C1).
+    read_kiss_header1(C,C1,_,_):-[C]="s",!,
+	skip_line(C,C1).
+    read_kiss_header1(C,C1,_,_):-
+	skip_line(C,C1).
+read_kiss_header(C,C,_,_) :-([C]="0";[C]="1";[C]="-"),!.
+read_kiss_header(C,C1,IL,OL) :- 
+	skip_line(C,C0),
+	read_kiss_header(C0,C1,IL,OL).
+
+read_kiss_body(-1,_,_,_) :-!.
+read_kiss_body(C,In,Out,Emode) :-
+	([C]="0";[C]="1";[C]="-"),!,
+	read_kiss_var(In ,C, _, In1),get(C1),
+	read_kiss_state(C1,C2,S),
+	read_kiss_state(C2,C3,D),
+	read_kiss_var(Out,C3,C4,Out1),
+	assert_state(Emode,S,In1,Out1,D),
+	skip_line(C4,C5),
+	read_kiss_body(C5,In,Out,Emode).
+read_kiss_body(C,In,Out,Emode) :-
+	skip_line(C,C1),
+	read_kiss_body(C1,In,Out,Emode).
+
+assert_state(_,S,In1,Out1,D) :-
+	st(S,_,_),!,
+	assertz(st(S,(In1,Out1),D)).
+assert_state(empty,S,In1,Out1,D) :-!,
+	assertz(st(S,empty,empty)),
+	assertz(st(S,(In1,Out1),D)).
+assert_state(_,S,In1,Out1,D) :-
+	assertz(st(S,(In1,Out1),D)).
+
+read_kiss_var([],C, C, true):-!.
+read_kiss_var([_],C, C1, true):- [C]="-",!,get0(C1).
+read_kiss_var([H],C, C1, not(H)):- [C]="0",!,get0(C1).
+read_kiss_var([H],C, C1, H):- [C]="1",!,get0(C1).
+read_kiss_var([H|L],C, C1, O):-
+	kiss_var([C],H,O,O1),!,get0(C0),
+	read_kiss_var(L,C0,C1,O1).
+read_kiss_var(L,_, C1, O):- get0(C),
+	read_kiss_var(L,C, C1, O).
+
+kiss_var("-",_,O,O).
+kiss_var("0",H,(not(H),O),O).
+kiss_var("1",H,(H,O),O).
+
+read_number(C,C1,N) :- read_number1(C,C1,NL),name(N,NL).
+read_number(_,_,0) :- write('A number is expected.'),nl.
+read_number1(C,C1,[C|L]) :- 
+	([C]="0"; [C]="1"; [C]="2"; [C]="3"; [C]="4"; [C]="5";
+	 [C]="6"; [C]="7"; [C]="8"; [C]="9"),!,get0(C2),
+	 read_number1(C2,C1,L).
+read_number1(C,C,[]).
+
+read_kiss_state(C,C1,N) :- read_kiss_state1(C,C1,NL),name(N,NL).
+read_kiss_state(_,_,0) :- write('A kiss_state is expected.'),nl.
+read_kiss_state1(C,C1,[C|L]) :- 
+	 [Z]="0",C>=Z, !,
+	 get0(C2),
+	 read_kiss_state1(C2,C1,L).
+read_kiss_state1(C,C1,[]) :-
+	skip_space(C,C1),!.
+
+skip_space(C,C1):- ([C]=" ";[C]="	"),!,
+	get(C0),skip_space(C0,C1).
+skip_space(C,C).
+
+skip_line(10,C) :- !,get0(C).
+skip_line(-1,C) :- !,C= -1.
+skip_line(_,C) :- get0(C0),skip_line(C0,C).
+
+/* end */
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/kiss_ex.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,28 @@
+:-asserta(st_variables([a,b],[q])).
+
+st(s0,((not(a);not(b)),q),s0). 
+st(s0, (a,b,not(p)),s1).
+st(s0, empty,empty).
+st(s1,(not(c),q),s1).
+st(s1,(c,not(q)),s2).
+st(s1, empty,empty).
+st(s2,(a,not(b),q),s2).
+st(s2,((not(a);b),not(q)),s3).
+st(s2, empty,empty).
+st(s3,(c,not(q)),s0).
+st(s3,(not(c),not(q)),s3).
+st(s3, empty,empty).
+
+st(ns0,((not(a);not(b))),ns0). 
+st(ns0, (a,b,not(p)),ns1).
+st(ns0, empty,empty).
+st(ns1,(not(c)),ns1).
+st(ns1,(c,not(q)),ns2).
+st(ns1, empty,empty).
+st(ns2,(a,not(b)),ns2).
+st(ns2,((not(a);b)),ns3).
+st(ns2, empty,empty).
+st(ns3,(c,not(q)),ns0).
+st(ns3,(not(c)),ns3).
+st(ns3, empty,empty).
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/lite.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,39 @@
+% Sat May 22 11:43:11 JST 1993
+
+:-  module(lite,[
+	ex/1,  			% ex(ITL)   verification predicate
+	ex/2,			% ex(No,Example)
+	diag/1,diag/0, 		% find counter example
+	exe/1, exe/0,		% find sample execution
+	verbose/1, 		% verbose mode (default on)
+	renaming/1, 		% 2var renaming mode (default on)
+	singleton/1, 		% singleton removal mode (default on)
+	detailed/1, 		% detailed trace of 2var
+	set_limit/1, 		% 2var state limit
+	lazy/1,			% lazy mode (dvcomp only)
+	kiss/0, 		% kiss format geneartion
+	read_kiss/1,		% read KISS2 format
+	read_kiss/4,		% read KISS2 format
+	read_kiss/3,		% read KISS2 format
+	tgen/0, 		% tokio clause geneartion
+	itl/1,			% one step tableau expansion
+	itl/3,			%     " in detail
+	itl_statistics/0,  	% show number of state etc. 
+	st/3,			% external state machine
+	st_variables/2,		%     its variables
+	sbterm/0,		% show sub term/ state database
+	display/0, large/0, small/0, 	% show state database
+	start/0, display_diag/1, display_exe/1,
+	state/0 		% show state database
+]).
+
+%?-op(900,xfy,[(&),('&&')]).
+%?-op(700,xfy,['<->','\=',proj]).
+%?-op(60,fy,['~','#','<>', '@',^]).
+%?-op(60,fy,[*]).
+?-[op].
+% :- use_module(library(gmlib)).
+:- ensure_loaded([dvcomp,rstd,chop,diag,kiss,ex,cp]).
+% ,display]).
+
+% end
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/ndcomp.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,323 @@
+/*
+ Copyright (C) 1991, Shinji Kono, Sony Computer Science Laboratory, Inc.
+                                  The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+ $Id$
+*/
+
+:-dynamic verbose/0,state/2,links/2.
+:-dynamic stay/3.
+:-dynamic regular_limit/1.
+
+% itl decomposition for DST
+
+% requires [chop]
+% itl(Predicate,Next,Empty,ConditionLists)
+
+itl(P) :- expand(P,P0),
+	moref(Ev),itl(P0,Next,Ev,[],C),
+	write(([Ev|C]->Next)),nl,fail.
+itl(_).
+itl(P,Next,[Ev|C]) :- moref(Ev),itl(P,Next,Ev,[],C).
+
+moref(empty).
+moref(more).
+
+itl(true,true,_,C,C):-!.
+itl(false,false,_,C,C):-!.
+itl(more,false,empty,C,C).
+itl(more,true,E,C,C):-!,E = more.
+% next two rule determines descrete time
+itl(empty,true,empty,C,C).      
+itl(empty,false,E,C,C):-!,E = more.  % no succeeding more interval
+itl(N,F,E,C,C1):-number(N),!,
+        sb(Subterm,N),!,itl(Subterm,F,E,C,C1).
+itl(?(Cond,T,F),N,E,C,C1):-!,
+        itl(Cond,CN,E,C,C0),itl_cond(CN,T,F,N,E,C0,C1).
+itl_cond(true,T,_,N,E,C,C1) :-!,
+        itl(T,N,E,C,C1).
+itl_cond(false,_,F,N,E,C,C1) :-!,
+        itl(F,N,E,C,C1).
+itl_cond(CN,T,F,N,E,C,C1) :-!,
+        itl(T,TN,E,C,C0),
+        itl(F,FN,E,C0,C1), negate(CN,NCN),
+        and(TN,CN,N1),and(FN,NCN,N2), or(N1,N2,N).
+
+itl(P,FF,_,C,C1) :- atomic(P),!, local(FF,P,C,C1).
+    local(true,P,C,C1):- true(C,P,C,C1).
+       true([],P,C,[P|C]):-!.
+       true([P|_],P,C,C):-!.
+       true([not(P)|_],P,_,_):-!,fail.
+       true([_|T],P,C,C1):-true(T,P,C,C1).
+    local(false,P,C,C1):- false(C,P,C,C1).
+       false([],P,C,[not(P)|C]):-!.
+       false([P|_],P,_,_):-!,fail.
+       false([not(P)|_],P,C,C):-!.
+       false([_|T],P,C,C1):-false(T,P,C,C1).
+itl(@(P),P,more,C,C).		   % strong next
+itl(@(_),false,E,C,C):-!,E=empty.
+
+% Regular Variable
+itl(^(R),F,empty,C,C1):-
+    local(F0,up(R),C,C0),
+    local(F1,down(R,0),C0,C1),and(F0,F1,F).
+itl(^(R),F1,E,C,C1):-!, E=more,
+    local(F,up(R),C,C1),and(F,^(R,0),F1).
+
+itl(^(_R,S),false,_,C,C):-
+	regular_limit(X),S>X,!.
+itl(^(R,S),F,empty,C,C1):-
+    local(F,down(R,S),C,C1).
+itl(^(R,S),^(R,S1),E,C,C):-!, E=more, S1 is S+1.
+
+% Quantifier
+itl(exists(P,Q),F,E,C,C0) :-!,
+	itl(Q,QT,E,[P|C],C1),itl_ex(QT,Q,E,P,F,C1,C0).
+    itl_ex(true,_,_,P,true,C,C1):-!,remove_p(C,P,C1).
+    itl_ex(false,Q,E,P,F,C,C0):-  !,remove_p(C,P,C1),
+    	itl(Q,QF,E,[not(P)|C1],C2),remove_p(C2,P,C0), exists(QF,P,F).
+    itl_ex(QT,Q,E,P,F,C,C0):- remove_p(C,P,C1),
+    	itl(Q,QF,E,[not(P)|C1],C2), remove_p(C2,P,C0),
+        or(QT,QF,TF),exists(TF,P,F).
+    % constant order optimzation for quantifier
+    exists(P,P,true):-!.
+    exists(P,_,P):-atomic(P),!.
+    exists(Q,P,exists(P,Q)).
+    remove_p([],_,[]):-!.
+    remove_p([not(P)|T],P,T):-!.
+    remove_p([P|T],P,T):-!.
+    remove_p([H|T],P,[H|T1]):-!,remove_p(T,P,T1).
+itl(*(P),F,empty,C,C1):-!,itl(P,F,empty,C,C1).
+itl(*(P),F,E,C,C1):-!,E=more,
+	itl(P,PX,more,C,C1),
+	closure(PX,P,F).
+    closure(false,_,false):-!.
+    closure(PX,P,(PX & *(P))).              %% infinite clousre (strong)
+%%    closure(PX,P,(PX & (*(P);empty))).    %% finite closure (weak)
+%% external state diagram (determinization)
+itl(st(N),F,E,C,C1):-!,
+	setof((Cond=>X),st(N,Cond,X),L),
+	itl_transition(L,F,E,C,C1).
+    itl_transition([],false,_,C,C):-!.
+    itl_transition([(Cond=>true)|T],F,E,C,C1):-!,
+    	itl((Cond),F0,E,C,C0),
+        itl_transition(T,F1,E,C0,C1),or(F0,F1,F).
+    itl_transition([(Cond=>empty)|T],F,E,C,C1):-!,
+    	itl((empty,Cond),F0,E,C,C0),
+        itl_transition(T,F1,E,C0,C1),or(F0,F1,F).
+    itl_transition([(Cond=>X)|T],F,E,C,C1):-
+    	itl((more,Cond),F0,E,C,C0),
+        itl_transition1(F0,X,T,F,E,C0,C1).
+    itl_transition1(false,_,T,F,E,C,C1):-!,
+        itl_transition(T,F,E,C,C1).
+    itl_transition1(true,X,T,F1,E,C,C1):-!,
+        itl_transition(T,F,E,C,C1),or(F,st(X),F1).
+%% ignore last state to check non stop predicate
+itl(free_fin(_),F,empty,C,C):-!,F=true.
+itl(free_fin(L),F1,more,C,C1):-!,
+    itl(L,F,more,C,C1),free_fin(F,F1).
+    free_fin(true,true):-!.
+    free_fin(false,false):-!.
+    free_fin(X,free_fin(X)):-!.
+%%
+itl((P,Q),N,E,C,C1) :-!,
+	itl(P,PN,E,C,C0),itland(PN,Q,N,E,C0,C1).
+itland(false,_,false,_,C0,C0):-!.
+itland(true,Q,QN,E,C0,C1):-!,itl(Q,QN,E,C0,C1).
+itland(PN,Q,N,E,C0,C1):-
+	itl(Q,QN,E,C0,C1),and(PN,QN,N).		%% and/3 in chop.pl
+itl((P;Q),N,E,C,C1) :-!,
+	itl(P,PN,E,C,C0),itlor(PN,Q,N,E,C0,C1).
+itlor(true,_,true,_,C0,C0):-!.
+itlor(false,Q,QN,E,C0,C1):-!,itl(Q,QN,E,C0,C1).
+itlor(PN,Q,N,E,C0,C1):-
+	itl(Q,QN,E,C0,C1),or(PN,QN,N).		%% or/3 in chop.pl
+itl(not(P),NN,E,X,X1) :- !,
+	itl(P,N,E,X,X1),
+	negate(N,NN).				%% negate/2 in chop.pl
+% F = empty?(P,Q):(empty(P)*more(Q)+more(PM)&Q)
+itl((P&Q),F,empty,C,C1) :-!,
+	itl((P,Q),F,empty,C,C1).
+itl((P&Q),F,more,C,C2) :-!,
+	itl(P,PE,empty,C,C0),
+	C0 = C0R,
+	itl(P,PM,more,C0R,C1),
+	chop(PM,PE,F,Q,C1,C2).
+
+chop(false,false,false,_,C,C):-!.
+chop(PM,false,(PM & Q),Q,C,C):-!.
+chop(PM,true,F,Q,C,C1):-!,
+    itl(Q,QF,more,C,C1),
+    chop1(PM,QF,Q,F).
+chop(PM,PE,F,Q,C,C):-!,
+	write('next empty conflict:'),write((PM,PE,F,Q,C)),nl,!,
+	fail.
+
+chop1(false,QF,_,QF):-!.
+chop1(false,false,_,false):-!.
+chop1(PM,false,Q,(PM&Q)):-!.
+chop1(_,true,_,true):-!.
+chop1(PM,QF,Q,(QF;(PM&Q))):-!.
+
+itl(proj(_,Q),F,empty,C,C1) :-!,
+	itl(Q,F,empty,C,C1).
+itl(proj(P,Q),F,more,C,C1) :-!,
+	itl(P,PM,more,C,C0),
+	itl(Q,QM,more,C0,C1),
+	prj(PM,QM,P,F).
+prj(false,_,_,false):-!.
+prj(_,false,_,false):-!.
+prj(PM,QM,P,(PM&proj(P,QM))).
+
+itl(prefix(P),F,empty,C,C1) :-!,
+	itl(P,PE,empty,C,C0),
+	itl(P,PM,more,C0,C1),    % this must be satistifiable
+	prefix(PM,PE,F).
+itl(prefix(P),F,more,C,C1) :-!,
+	itl(P,PM,more,C,C1),
+	prefix(PM,F).
+
+prefix(true,true):-!.
+prefix(false,false):-!.
+prefix(PM,prefix(PM)):-!.
+
+prefix(true,_,true):-!.
+prefix(_,true,true):-!.
+prefix(false,false,false):-!.
+prefix(_,false,true):-!.
+
+itl(Def,_,_,_,_) :-
+    write('error: '),write(Def),nl,!,fail.
+
+itl_statistics :- nl,
+        itl_state_number(X),write(X),write(' states'),nl,fail.
+itl_statistics :- 
+        sbn(X),write(X),write(' subterms'),nl,fail.
+itl_statistics :- 
+        init_var(tmp,0),
+        ((links(_,_),inc_var(tmp,_),fail);true),
+        tmp(N),
+%       init_var(tmp,0),
+%       ((state(_,_,_),inc_var(tmp,_),fail);true),
+%       recorded(tmp,L,_),
+        itl_transition(L),
+        write(N),put(47),  % "/"
+        write(L),write(' state transitions'),nl,fail.
+itl_statistics.
+
+
+:-assert(verbose).
+verbose(off) :- retract(verbose),fail;true.
+verbose(on) :- asserta(verbose).
+
+deve(ITL) :-
+	init,!,
+	expand(ITL,ITL0),		% chop standard form
+	itlstd(ITL0,StdNOW),		% BDT
+	assert(itl_state(StdNOW,1)),!,  % Initial State
+	deve0((1,ITL0)).
+
+deve0((S,ITL)) :-
+%        increment_state(ITL,ITL_1,S),
+        show_state(S,ITL),
+%	setof(Next,itldecomp(ITL,Next,S),
+	bagof(Next,itldecomp(ITL,Next,S),
+	    Nexts),!,
+	deve1(Nexts).
+deve0(_).
+
+deve1([]).
+deve1([H|T]) :- deve0(H),deve1(T).
+
+itldecomp(ITL,(NextS,Next),From) :-
+	init_var(current,From),
+	itl(ITL,Next,Cond),
+	%% showing
+	itlshow(Next,NextS,Cond,From).
+
+itlshow(Next,S,Cond,From):-
+	itlstd(Next,StdNext),
+	check_state(StdNext,Cond,New,S),
+	inc_var(itl_transition,_),
+	assertz(state(From,Cond,S)),
+	(links(S,From),!;assertz(links(S,From))),
+	!,
+	itlshow0(S,Cond,Next,New).
+
+itlshow0(S,Cond,Next,New) :- verbose,!,
+	itlshow1(S,Cond,Next,New),nl,!,New=1.
+itlshow0(0,_,_,0):- !,put(101),!,fail.   % "e"
+itlshow0(false,_,_,0):- !,put(102),!,fail.  % "f"
+itlshow0(true,_,_,0):- !,put(116),!,fail.  % "t"
+itlshow0(_,_,_,0):- !,put(46),!,fail.    % "."
+itlshow0(S,_,_,1):- !,write(S),put(46),ttyflush,!.  % "."
+
+itlshow1(0,Cond,_,_):-!,
+	write(Cond),write('->'),write(empty).
+itlshow1(true,Cond,_,_):-!,
+	write(Cond),write('->'),write(true).
+itlshow1(false,Cond,_,_):-!,
+	write(Cond),write('->'),write(false).
+itlshow1(S,Cond,_,0):-!,
+	write(Cond),write('->'),write(S).
+itlshow1(S,Cond,Org,1):-
+	write(Cond),write('->'),write(S),
+	put(9),write(Org),!.
+
+init :-
+	subterm_init,
+	abolish(state,3),
+	asserta(state(true,[more],true)),
+	asserta(state(true,[empty],0)),
+        abolish(itl_state,2),
+        abolish(stay,3),asserta(stay(0,0,0)),
+        asserta(itl_state(false,false)),
+        asserta(itl_state(empty,0)),
+        asserta(itl_state(true,true)),
+        init_var(regular_limit,5),
+	abolish(links,2),asserta(links(true,true)),
+	init_var(current,0),
+	init_var(itl_transition,1),
+	init_var(itl_state_number,1),!.
+
+show_state(S,ITL) :-
+	nl,write('state('),write(S),  % (
+	(verbose,write(' , '), write(ITL),write(')'),nl;write(')')),!.
+
+check_state(true,[more |_],0,true):-!.
+check_state(true,[empty|_],0,0):-!.
+check_state(false,_,0,false):-!.
+check_state(STD,_,0,S):-
+	itl_state(STD,S),!.
+check_state(STD,_,1,S):-
+	inc_var(itl_state_number,S),
+	assert(itl_state(STD,S)),!.
+
+init_var(X,_) :- functor(F,X,1),assert(F),fail.
+init_var(X,_) :- functor(F,X,1),retract(F),fail.
+init_var(X,V) :- functor(F,X,1),arg(1,F,V),assert(F),!.
+inc_var(Name,X1) :- 
+        functor(F,Name,1),retract(F),arg(1,F,X),
+        X1 is X+1,functor(F1,Name,1),arg(1,F1,X1),
+        asserta(F1),!.
+set_var(Name,X,X1) :-
+        functor(F,Name,1),retract(F),!,arg(1,F,X),
+        functor(F1,Name,1),arg(1,F1,X1),asserta(F1),!.
+set_var(Name,X,_) :- init_var(Name,X).
+
+increment_state(stay(P,now),stay(P,S),S) :- !,
+      (stay(P,F,S);assertz(stay(P,F,S))),!.
+increment_state(N,N,_) :- atomic(N),!.
+increment_state(P,R,S) :- functor(P,H,N),functor(R,H,N),
+      increment_state_arg(N,P,R,S).
+increment_state_arg(0,_P,_R,_):-!.
+increment_state_arg(N,P,R,S):-arg(N,P,PA),arg(N,R,RA),
+      N1 is N-1,increment_state(PA,RA,S),
+      increment_state_arg(N1,P,R,S).
+
+%% end %%
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/op.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,5 @@
+:-op(900,xfy,[(&),('&&')]).
+:-op(600,xfy,['<->','\=',proj]).
+:-op(600,xfy,['=>','<=']).
+:-op(60,fy,['~','#','<>', '@',^]).
+:-op(60,fy,[*]).
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/problems	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,1880 @@
+Thu Jan 18 22:42:24 JST 2001
+
+| ?- ex(((true&false)->(<>(empty)))).
+ 
+は、valid になってしまう。実際には、infinite->not(<>(empty)).
+
+Thu Jan 18 21:04:13 JST 2001
+
+まず、chop.pl の中の、X & false をfalseに変換しているのを
+抜く必要がある。
+
+Thu Jan 18 19:59:33 JST 2001
+
+in POPL01
+
+LICS00 の infinite を入れるように Lite を拡張することが
+できるのか?
+
+単純な拡張にはならない。
+    infinite =def (true & false )
+だから。これは、今の実装では unsatisfiable。
+
+P&Q で、Q が単純にfalseだからといって、諦められない。今は、node は、
+	empty,false
+	empty,true
+	more,false
+	more,some_other
+というように特徴付けられている。これで足りるのか?
+
+Eventurality check が必要無いと良いんだけど。
+
+Rabin automaton ってなんだ? Buchi と同じなんじゃないの?
+
+true & false は、
+	empy -> false
+	more -> true & false
+に展開される。今は、empty だけを見て、validity/satisfiability を
+調べている。しかし、これを、
+    「ある特定のfalse exit ループをsatisfiableだとみなす」
+ことにより、infinite interval を導入することができる。
+
+問題は、どのような false exit ループが satisfiable だという
+こと? というよりは、これで unsatisfiable になる formulaって
+何?
+	more -> false
+のたぐいだけか?
+    finite
+	empy -> true
+	more -> true & true
+は、どうなる?
+    ~infinite
+	empy -> true
+	more -> ~(true & false)
+となる。なので、これは finite に等しい。
+
+infinite は、false loop を表していると考える。
+
+全ての式Pを、finite -> P で、チェックすれば、finite LITL になる。
+(ならなければいけない)
+
+って、ことは、false loop をdetectすれば良いだけか? これは、
+結構易しいが、計算量的には、ちょっと大変かな。
+    finitely
+	valid, satisfiable, unsatisfiable...
+    inifinitly
+	valid, satisfiable...
+infinitely satisfiable とは、
+    flase loop が存在すること
+valid は、
+    false loop 以外は、empty false であること(?)
+
+えーと、それだと、inifinitly satisiable な式は、finitly unsatisfiable
+だけど、それでいいの? だとすると、valid な式はなくなってしまうね。
+
+これは、ちょっとうれしくないであろう。ということは、
+    infinitely valid は、
+    false loop 以外は、empty ture であること(?)
+を含むと考えるのが正しい。だとすると、
+    |= finitie /\ finite
+ってことになるね。それは、ちょっとうれしくないか。
+
+うーむ、Moszkowski は、どういう選択をしたんだろう?
+
+
+Wed Nov 22 16:27:45 JST 1995
+
+rstd 側で limit を扱うことにする。
+rename_list でlimitを指定することになる。singleton のlimit
+をはずさないといけないだろう。over(r,N)が外にでないのが
+ちょっと情報不足だな。
+
+itlstd が idempotent になってなーい!!! しくしく。
+itlstd(X,Y,_),bdt2itl(Y,Z),itlstd(Z,Y1,_) でY=Y1になる
+はずなのだが...
+
+itlstd2 では、singleton remove, renaming は行なわないで、limit over
+だけを取り扱う。これによってdetailed trace が可能となる。これに、
+従来のitlstdをかければ、もとに戻るはずだ。が、どうも失敗している
+らしい。
+
+Tue Nov 21 18:33:19 JST 1995
+
+renaming の trace は original limit で行なう。
+detailed trace は no limit で行なう。
+itl/5 は2度呼ばれるが、まあ、良とするか。
+
+rstd 側でlimitの置き換えをすればだいぶましなんだが...
+
+renmaing で、over limit を取り扱う方が統一的か。
+
+Wed Nov 15 12:58:28 JST 1995
+
+over(r,N) が true/false に置き換わっていて、unifyするか? 
+
+いずれにせよ、ちょっと気まずい。どの変数が置き換わるかは、
+renaming を trace すれば分かるが...
+
+この置き換えをrstd側で行なって、original/restrictedの両方を
+とっておく。そして、どの変数が置き換わったか分かるようにする。
+(renaming informationに入れておく) でも、この情報もどうせ
+lazyに生成するんだよね? なんか変だ。
+
+あるいは、detailed traceの方では置換えしない? true/false に
+置き換えても同じstateで実現できるはず。だが、unify はしないと
+いけない。
+
+いずれにせよ、lazy state generation では、
+   full trace, restricted trace
+の両方をおこなう。このためには、over の置き換えをrstd で行なった
+方が良いだろう。
+
+うーむ、でも、そうすると、itlstd がnon-deterministic になって
+しまう。それは、いまいちだ。
+
+Tue Nov 14 19:56:26 JST 1995
+
+Detailed trace の時は Fromula と state number と両方持ち歩かないと
+だめだ。
+
+ということは、diag routine を書き直さないとダメか。ndcomp は
+あきらめるか?
+
+Mon Nov 13 22:33:34 JST 1995
+
+trace するときにrenaming は、いらないんじゃない?
+detailed traceをどうせ使うとすれば... そうすれば、
+choice も考えなくても良い。
+
+Sun Nov 12 23:37:36 JST 1995
+
+^r のtrace
+
+stateは決まっている
+duplicated は rename inforamtion を使ってtrace できる。
+
+detailed expansion して、unify する。具体的には、
+BDDにそって分解する。これによって、true_false がr^nの
+treeに展開されるはず。されなければ、別のものを探す。
+
+true_falseのchoiceによって値が異なるわけだけど...?
+choice は、一つのBDDに関して一つしかでない。(leafにしかない
+から) ということは、複数のchoice は、
+    異なる & の empty
+でしか起きない。なんらかのidentityを残した方がいいんだけど。
+ま、結果的に同じstateにいって、すべての条件が尽くされるなら、
+構わないか。detailed expansion はすべてを含んでいるのだから、
+構わないはず。
+
+まずは、renaming のカタをつけよう。
+
+もっと選択的に^rをトレースした方が良くない? singleton ^r
+をなんらかのtermにマップできなものか?
+
+Sat Nov 11 09:55:41 JST 1995
+
+2path singleton removal がようやっとできた。
+ただし、どうも、order sensitive なんだよな。over が@<,@>に
+よってでる時とでない時がある。
+
+sbdt_split, sbdt_ife によってremoval/renameによるorderを修正しない
+といけなかった。やむをえないところか?
+
+しかしsingleton removalを書いたら、もとの方も良くなってしまった。
+どうも、bdt routineには問題があったみたい。true & true を除く
+ようにしたのが効いたとも思えないんだが.... sbdt_opt のせいか?
+
+state numberがでなくなるbugを直した
+
+あとは、trace の問題だな。r^nの実行がちゃんとトレースできると
+いいんだけど。
+
+Thu Nov  9 12:03:32 JST 1995
+
+P & Q を、sb(P_BDD & Q_BDD) という形で持っているけど..
+sb(P_BDD,PN)
+sb(Q_BDD,QN)
+PN & QN という方が良くない? ほとんど同じだとは思うけど....
+?(PN & QN,true,false) となるのか.... うーん。
+
+Qの展開を一回に抑えられない? ? を未展開のマークに
+使えないか?
+
+Wed Nov  8 20:31:23 JST 1995
+
+はやり一旦BDDに落して2pathで処理することとする。
+
+first path:  singleton varble の detect
+  (regular variableがない場合は、そのままstd_check
+   singleton removal で消えることはない)
+regular variable が無ければ、これで終了
+rename list を計算
+second path path:  
+  singleton variable があった場合、
+  t/fのtree を parallel traverse
+  t/f または、[tf]/tf の組合せをtfに置き換える
+  複数のsingleton variableを順不同に処理して良い
+
+regular variable があるかどうかは、singleton removval の
+結果に依存するので、1path で厳密に取り除くことはできない。
+が、2nd path では確実に取り除くことが出来る。
+
+ぶぶ、2nd pathは全然処理が違う!! sbdt と共用はできない
+
+Tue Nov  7 15:45:07 JST 1995
+
+chop のレベルで分ければ、まあ、良い。問題は、そのあと。と、
+考えると、BDDに変換するレベルで対応する方が望ましいかも知れない。
+もちろん、今のままでもsafeなんだけど、落ちているものが多い。
+それは結果的に状態を増やしていることになる。
+
+一つの方法は、
+   p(^r)  =>   ?(^r,pt,pf)
+とする。
+   (pt,pf; tf), (pt;pf)
+と変形する。と、こんな具合。これは重いなぁ。
+
+(~ ^r), ^r がボトムアップではfにならない。ま、そういうことなんだよな。
+
+Tue Nov  7 10:38:59 JST 1995
+
+どうも、singleton removal だと、[a](^r = length(2)), f(^r)
+のようなものは完璧にトレースできるらしい。
+[a](^r = length(2)), *(^r) もOk だった。
+
+でも、さすがに文法記述は発散する。
+
+結局、どういう制限なのかなぁ? diag 時に、full trace できたかどうかを
+チェックするか...
+
+どうも、シングルトンチェックが甘いな。もっと、ちゃんとチェックする
+ためには?
+
+Mon Nov  6 15:57:46 JST 1995
+
+[p_0,p_1,...,p_n] は、
+p_0,p_1,...,p_n        -> true
+~ p_0,~ p_1,...,~ p_n  -> false
+else                   -> true_false
+という形でBDD(MTBDD)になる。3値論理
+
+^r -> true_false
+
+true_false -> empty? choice ? true : fals
+                   : true_false
+
+t,tf  -> tf
+t;tf  -> t
+tt;tf -> tf
+f,tf  -> f
+f;tf  -> tf
+tt,tf -> tf
+
+(あれ、cross termは?)
+確かにこれでうまくいきます。はい。* ^r も完璧。
+
+問題は、実行をtraceできるかどうかだな。
+
+Mon Nov  6 08:50:01 JST 1995
+
+singleton の効果は有限か?
+
+BDDの中でsingleton duplicate を許すとすると、これは止まるのか?
+   selection(uniq set of subterm)
+という形になるはず。だから、とまるはず。subtermは有限。singleton には、
+R名による区別さえ必要無い。
+   ^r -> ^([false,true])
+   ^([p_0,p_1...p_n]) -> ^([px_0,px_1...px_n])
+という展開になる? 再sortは必要。
+
+一般的に、^(r,[p_0,p_1...p_n]) という形で収束しないの? r が一つだったら...
+ネストしたらout。でもnestはあっても固定だから。
+
+が、これでcomputationをトレースできるのか? いや、特別な展開が必要。
+
+あと、determinization しないとね。(どうやって?)
+   ^([p_0,p_1...p_n]) -> ^([px_0,px_1...px_n])
+の際に、px_0 には next のみが入る。そうすれば良い。
+    itl(p_0,more,..)
+での出力はnext,true,false。Ok。
+
+Sun Nov  5 21:34:33 JST 1995
+
+しかし、なんと * ^R は非常に大きな状態を生成する。
+^R と true & ^R の干渉が大きな状態を生成してしまう。(らしい)
+これを抑えるには? 一つはlength で頭を抑えることだな。
+ああ、でも、やっぱり大きいか。あんまり、うまくない。
+length(10) でも結構巨大か..
+
+proj でも同じような問題はあったのだけど...
+
+^r の permuation の対称性を何とかしない限りだめだね。
+しかし、順序は変えちゃダメなんでしょう? うーむ。
+でもさ、モデル自身は小さいんだが.... うーむ。
+
+いや、この場合は singleton removal が効くみたい。そうか。
+
+これはsingleton の処理が正しくないからじゃない?
+
+singleton の効果は有限か?
+      f(r^1,....r^n) -> exists
+だとすれば有限。だけど、固定してはだめ。
+      r^s ? length(1) : r^s ? length(2) : ....
+となりうる?
+
+Wed Nov  1 21:12:04 JST 1995
+
+例題ねー... しかし、<>^R が使えないとなると....
+あ、でも、* ^R は使える。
+
+Mon Oct 16 16:05:31 JST 1995
+
+LITL で、closure, proj 抜きだとpolynominal orderの方法がある!?
+    ~(....&....(...&... ~(...&....)))
+という形で、これにvariable patternを埋め込んでいけば良い。これだと
+marking だから state space database はいらない。
+
+tableau expansion でも、生成される状態は同じ数だから結果的にpolynominal
+になっていたのかも....  たしかに、quantifier, closure, proj を入れると
+verification は難しくなっていた。
+
+いや、でも、empty interval があると、そうもいかないか?
+     ~(....&....(...&... ~(...&....)))
+の任意のchopをand,emptyに変える操作がいる。これは exponential。
+     p & p & p & p        & p
+     p & p & p & p,empty  , p
+chomp (non-empty interval chop) だったら、大丈夫。
+
+でも、closure, proj をいれるならおんなじか。
+
+Mon Oct  9 19:51:27 BST 1995
+
+proj では、r^n の n を階層化する。r^0 は、すべての階層で共有される。
+他のlengthは共有されないとみるのが正しいのだろう。length(1) proj Q
+だと、r^1^1 = r^0^1 だよね?
+
+P proj Q で、Q part のnext part は、
+proj の中にencupsulated されているので、term はいじる必要はない。が、
+condition はいじる必要がある。ただし、renaming を original clock
+level と同じにすると limit が効きすぎるだろう。しかし、ここを複雑に
+するのは、どうかなぁ。term level も階層化すれば、問題はない。
+(r^n)^n とか...
+
+結局、singleton removal は、うまくいかないね。これがうまくいけば、だい
+ぶ範囲が広まるのだが.... せめて、eventuality と同じぐらいまでにできな
+いの? あ、そうか、r^s をmarking と見ればいいわけね。しかし、結構、めん
+どくさいといえばめんどくさい。
+
+Time constant regular variable
+
+renaming なしならば、割と自明。
+  r^0 ... r^limit
+をunifyすれば良い。renaming ありだと、もう少し複雑になる。r^n を state
+と見るのが簡単。いずれにせよ、かなり制限された感じだね。
+
+renaming の、もっと気の聞いたalgorithmがあれば...
+
+Mon Oct  9 05:48:38 BST 1995
+
+^r -> true/false では、[a](^r=length(2)) が unsatisfiable.
+over(r) では、true/false に置き換えている。^r -> +r/-r でも、
+[a](^r=length(2))はだめ。これにさらに工夫がいる。
+でも、それはこっちの方がましだということだろう。でも、どれくらい
+ましなの? local でないぐらいか?
+
+singleton を ^(r,s) で置き換えても、[a](^r=lenth(2)) は、> length(4)
+でfail する。なんで?
+
+Sat Oct  7 17:20:17 BST 1995
+
+singleton removal を r^s で行なうと、limit を一つ伸ばす効果が
+あるらしい。したがってlimitまでいくような場合は状態が増える。
+r^s の選択を独立に行なうような方法で、ちゃんとできるのか?
+できないような気もする。
+
+Sat Oct  7 10:08:57 BST 1995
+
+(1) 番号を詰める (番号limitあり)
+
+は、やってみたけど、^r には効果があるんだけど、他のはほとんど
+関係ないなぁ。[a](^r...) みたいなものにはきかないのだろう。
+
+Fri Oct  6 09:46:45 JST 1995
+
+(1) 番号を詰める (番号limitあり)
+(2) singleton removal
+
+この二つでかなりいくはず。(2)どうにかなんないの?
+
+(3) 番号を構造化する low resolution?
+
+Edge driven な logic にできるか?
+
+Thu Oct  5 18:27:29 JST 1995
+
+うーむ。length limit は、うまくいくが、それ以外の制限がいまいち
+うまくいかないね。
+
+rename して ^r の数を制限する方法だと、over に変換されるものが
+あまりにアドホックに決まってしまう。
+    r^n
+の  n  に、何か term を持って来れないの?
+
+total order を持って来るか... 効果あるの?  さぁ...
+
+Sun Sep 24 01:14:36 JST 1995
+
+だから、
+
+^r = false にすると、
+
+[a](^r=legth(2)) -> [a](false=legth(2))
+[a](false=legth(1))
+[a](false=legth(0)) = unsatisfiable
+
+になるからだめなの。うんうん。
+true = length(2) も false = length(2)
+も、両方ともunsatisfiable。どちらかというと、
+    (length(2);not(length(2)))  & true
+となるのが正しい。
+    (length(2) & true) ; (not(length(2))  & true)
+は? これは Ok なはず。
+
+だったら、expansion する前にsingletonをチェックして、singleton
+に対しては quantifiy してしまうってのは? うーむ...
+
+じゃあ、なんで ^r -> ^r;not(^r) ではだめなのか?
+これは、終りを共有するものをいっしょにしているから。
+
+^r on n+1
+   |--|   T
+   |-|    F
+   ||     F
+    |-|   T
+    ||    F
+     ||   F
+
+とする
+
+^r on n
+  |---|
+  |--|    
+  |-|    
+  ||
+
+が新しいもの。これらは、独立。ふんふん。
+
+Tue Sep 19 23:53:19 JST 1995
+
+どうも変だな。
+down(r^0)  と    true;false とはどこが違うんだ?
+state(1 , not(true& ?(^r,not(@ @empty),@ @empty)&true))
+                      [a](^r = length(2))
+[empty,down(r,0),up(r)]->false
+[empty,not(down(r,0)),up(r)]->empty
+[empty,down(r,0),not(up(r))]->empty
+[empty,not(down(r,0)),not(up(r))]->empty
+[more,down(r,0),up(r),ev(r^0)]->false
+[more,not(down(r,0)),up(r),ev(r^0)]->2
+not(true& ?(^r,not(@ @empty),@ @empty)&true);
+                      [a](^r = length(2));
+not(not(@empty)&true),not(@empty&true)
+                      [i](length(1)),not(length(1)&true)
+[more,down(r,0),not(up(r)),ev(r^0)]->3
+not(true& ?(^r,not(@ @empty),@ @empty)&true);
+                      [a](^r = length(2));
+not(@empty&true)
+                      not(length(1)&true)
+[more,not(down(r,0)),not(up(r)),ev(r^0)]->3
+
+やっぱり違う。true だと、length(1)でtrue length(2)でfalseという
+技が出来ない。この選択はこの場所で独立に選択しなくてはならない。
+(ええ?だけど、true;false なんだから... だったらtrueか?)
++r, -r の方がましか?
+
+Sat Sep 16 11:44:25 JST 1995
+
+singleton ^r を true, false に置き換えると、[]true,[]false の意味に
+なってしまう。実際は、true/false なのに。だから、singleton removal
+はうまくない。
+
+t0:   ^r  = length(2)
+t1:   r^0 = length(1)    empty/not(r^0)
+t2:   r^0 = mpty(1)      empty/r^0
+
+Quantifierに置き換える? だったら残しておいた方がまし?
+何かoperatorを作る?
+  some -> true/false
+quantified true? <>false かな? not([](true)) = not(not(true & not true))). 
+でも、これだといつかはfalseになってしまう。operatorにすると、deterministic
+でなくなるか。それはまずい。negationが。
+
+Fri Sep 15 11:26:13 JST 1995
+
+singleton check をitl時にすることはできない?
+
+Wed Sep 13 18:24:24 JST 1995
+
+結局、RITLは CFG を含んでいるのだから、Regular Subset を決めることは
+できない。
+
+^r のdepthを制限すれば、ある程度はできる。しかし、これでは
+fairnessにはならないね。
+
+depth 以外の制限は? 状態数の制限が望ましい。
+
+singleton の remove でかなりのことが出来ると言えば、そうなのだが。
+
+singleton remove のタイミング?
+   itlの時に detect?
+   itlstd の時に detect?
+remove の仕方
+   eventually(^r,N)
+   eventually(not(^r,N))
+を挿入する。ということは、itldecomp の show の直前で
+行えば良い。
+
+しかし、これだと正確な状態出力ではない。ではないが原理的にトレース
+できる部分をはしょっているだけ。mark を付けるのでは同じになってしまう。
+やはりremoveしたい。
+
+^rの出現頻度を押さえることで、logicになるか? 例えば2つとか?
+
+*  consistent にならない==safeでない(標準形を工夫すれば...)
+*  でなくても良いという考え方もある。characterriseできる?
+
+いずれにせよ、singleton removal でどこまでいくかだな。
+
+Sun Jul 23 10:16:02 JST 1995
+
+* ^r ->  +r, -r   depth によって独立に選択
+* +r も r^depth により選択
+
+これだと、[a](^r),<>(not(^r))がsatisfiable
+
+* ^r ->  +r, -r   depth によって独立に選択しない
+
+と、[a](^r=length(2))がunsatisfiable
+
+うーむ、うまくいかん。
+
+Sat Jul 22 12:52:11 JST 1995
+
+* depthの違いはchopの処理で行なう
+* ^rのemptyと、+r, -rのemptyは独立
+* ^rのmoreと、+r, -rの関係
+
+  +r, -r は、異なるdepthでT/Fの時に生じる
+既に +r がある時は、それに合流して良い
++r/\-r となることはない。それはfalse。
+
+|-------|       +r
+|---------|     -r
+   ^r  +r とする
+   not(^r)があったら-rとする
+
+これでいいか?
+   tailを共有するrである not(^r),と^rの扱いは対称
+   ^r/-rの組合せは?
+
++r, -r が解消される場合
+
+* +r or -r がempryになるとき
+      -r はemptyにならない
+
++rが残って害があるか? -rがなければ関係ない
+状態は増えるけど。
+
+Fri Jul 14 18:31:19 JST 1995
+
+異なる chop で、異なるrの番号を付ける。
+その番号毎に up(^r), down(r,n) を行なう
+
+これによって、すべての組合せが一応得られる。
+
+番号は状態には付加しない。(いいのか?)
+同じinterval上では、
+    r, not(r)
+があり得る... これは... 気まずいか。
+    ^r ->   +^r, -^r
+とする? すると... +up, -up がある?
+
+まあ、試してみよう。(やっぱりだめだった...)
+
+Thu Jul 13 14:05:06 JST 1995
+
+r^n の数を減らす
+  => 等価でユニークな表現
+
+singleton r^n は消せる
+
+doubleton r^nどうしを融合したい。
+
+新しいrをr^nに相対的に定義する (それはできるのだが... +r/-r)
+のは、うまくいったのだが、足りないものがある。状態数が
+足りない。
+
+* 必要な状態数のみを区別する
+* 同じ結果を生じる変数は区別しない
+
+自分自身と同じかどうか / 違うということを覚えないといけない
+   同じだったら関係ない
+
+What happen in next case? ([a](^r))
+
+   not(r^5) & true, r^5 & true, ^r  & true, not(^r) & true
+
+    ---|-----| r^5
+    ---|----| r
+
+r^5が落ちれば一つ減る。減らなければr^6で一つ増える。しかし、
+この場合は増えてはいけない。r^5 と ^r 自身は関係が無い。
+が、結果は同じという関係がある。( うがー、わからないよう.... )
+
+st6:
+not(r^5) & true, r^5 & true, ^r  & true, not(^r) & true
+
+up(^r),down(r^5),down(^r)	@not(r^5)&t, t, t,  @not(r^6)&t
+up(^r),down(r^5),not(down(^r))	@not(r^5)&t, t, @(r^6)&t,  t
+up(^r),not(down(r^5)),down(^r)	t, @not(r^5)&t, t,  @not(r^6)&t
+up(^r),not(down(r^5)),not(down(^r))	
+				t, @not(r^5)&t, @(r^6)&t,  t
+
+
+Mon Jul 10 20:01:46 JST 1995
+
+f(^r) =>   contratint_1(^r) & continuation_1(^r)
+g(^r) =>   contratint_2(^r) & continuation_2(^r)
+
+r(r^n)&c(r^n) がnを除いて等しい時、
+r^n => r^n' がいえる。
+けど、別に等しい必然性もない。(たしかに...)
+
+r^nはquantifyして良い。ということは、同じなら消して良いということ?
+ということか。cross term は?
+   exists(^r, empty(^r)? ...)
+
+r0: {    +r(const, continu), 
+         -r(const, continu)  }
+r1: {    +r(const, continu), 
+         -r(const, continu)  }
+
+いつかは
+	+r(empty,continu)
+	+r(true,continu)
+のどちらかにいく。いや、いかない。emptyなら問題無い。trueが問題(?)
+     +r(fixpoint,contiu)
+という形になる。これがたくさん存在するということになる。
+     +/-r^n(fixpoint_k,continu_k_i)
+というわけだ。この場合のr^nの重なりが解消できれば問題は解決。
+うまくいかないね...
+    
+
+で、同じものは消して良い。順序をそろえないと消しにくい。
+違うrでも同じカッコなら消して良い。(reular variableは、実質は
+一つ, ^r =>  r,^common にするか? それはちょっと違う)
+この場合は消しても干渉のパターンが変わらない。干渉パターン
+ごとにマッチングをとるから。(有限の組合せなのか?)
+
+消すのはterm levelでおこなう?
+      c(r^n, i_n...) & ...
+      c(r^n, i_n...)
+というtermしかr^nに関してはでてこない。消せるんだったら、他の
+方法はいい加減でも大丈夫。
+
+f(r^n)とf(r^n'1)の関係
+  |------|-|
+    |----|-|
+r^n, r^n' 自身は独立
+
+r^1(r,c)
+r^2(r,c)
+  empty(r^1),empty(r^2),empty(r) => c
+    cross term
+  empty(r^1),more(r^2), empty(r) => c,(more(r),r^1(@(r),c))
+  more(r^1),more(r^2), more(r) => 
+    more(r),r^1(@(r),c),r^2(@(r),c)
+==
+  r^1(c);c,more(r),r^1(@(r),c);more(r),r^1(@(r),c),r^2(@(r),c)
+他のr^nと干渉する方法が変わってしまう...
+
+
+Sun Jul  9 15:32:43 JST 1995
+
+  r^1 & true;
+  r^2 & true;
+  r^3 & true
+
+一つにまとめられない?
+
+   f(+/- r^n)                    (必ずtopにある/一度展開されているから)
+   |-------------|-----------|
+               down(r^n) => true/false
+
+性質
+   f(+/- r^n)
+       down(r^n)      =>  f((+/-true ,empty))
+       not(down(r^n)) =>  f(+/- r^n)
+         parallel termがある時は無くなるまで展開する
+	     r^n, *length(3) などは? これは無視して良い
+	     r^n, *length(3) & true が問題
+                => evenrually true + *length(3)
+
+だから、nが複数あっても、f((+/-true ,empty))が同じなら同じでよい(?)
+
+   f(+/- r^n)  => true & down(r^n),f(+/-true,empty)
+      => down(r^n) =  eventually(f(+/-true,empty))
+
+ということは、やっぱりdown(r^n)を外に出せるということ?  
+r^n & true なら         eventually(true)
+not(r^n) & true なら?
+
+ふむ。そして eventually(f) の f にはr^nは入らない。これは
+いけるかも知れない。
+
+chopの処理の時に、eventuality listをbdtの形で外に出せば良い。
+eventuality が満たされた時がr^nが成立した時。(これも
+前考えたな...)
+  ^r & ....
+という形だけ?
+
+   (^r, g) & f  => ev(f),(g & f)   ちょっと違う...
+   (^r & f),(g & f)
+
+とは少し異なるよ。not がうまくないはず。
+    not(ev(f)); not(g & f)  (?)
+
+そうか... ev(f)が満たされれば、^rは落ちて良い。(落ちれる)
+落ちなくてもいい。
+
+前もってevenruality formにITLを書き換えるのは?
+    f(r) => g(eventualy(h))
+
+本当にdiceidableなのか? 整数方程式が書けるとすれば...  
+
+Fri Jul  7 18:51:32 JST 1995
+
+true & ^r & true =>
+  r^1 & true;
+  r^2 & true;
+  r^3 & true
+となる。ということは、ひとつのintervalだけを見て吸収することは出来ない。 
+
+            t1  t2
+            up(r)         down(r^1)
+    r&true   |-------------|--------------------
+not(r&true)  |----------------|not(down(r^1)----
+             |---|up(r)----|not(down(r^2)-------
+
+r^1 は競合するr^1がある時しか関係しない。したがって単独に
+出てくるr^1は現在時点で
+  fin(r^1)      => true
+  fin(not(r^1)) => false
+を決めて良い。これだけで、true & ^r & true は収束する。
+が、それだけで収束するか? たぶん、しない。
+
+(1)
+複数の始点を持つ状態を一つにまとめられればできる。+r, -r はそういう
+方法だった。が一つにはならない。有限な組合せになる。
+
+(2)
+収束するとすれば、共有されたr^nの組が有限な場合である。これは、finiteness
+の条件に相当する。前もって共有される可能性のあるtermを生成できるか? (
+たぶんできる) 
+
+前もって複数出て来た(違うsytactical interval上の)^rに番号を付けて
+識別しておく。競合は、異なる番号上でしか起きない? 
+   [](<>(^r))  = not(ture & not(true & ^r))
+のような場合は? そうか。同じ番号上の共有は+r, -rで構わない。
+(true or false だから)
+   [](<>(^r))  <-> [](<>(^r)) 
+のような場合は?
+
+Fri Jun 30 20:08:47 JST 1995
+
+f(r^1,r^2,r^3) & true, 
+g(r^1,r^2,r^3) & true
+
+f(r^1,r^2,r^3)とg(r^1,r^2,r^3)を見ながらr^nの数を減らさないといけない。 
+
+r^n は、emptyの時しか影響しない。moreの時はtrueと同じ。
+
+^r のみが新しいr^nを増やす。これをいかに吸収するかを調べれば良い?
+
+f(r^cur,r^1,r^2,r^3) & true, 
+  =>   r^cur ? +f(r^1,r^2,r^3) : -f(r^1,r^2,r^3)  & true
+g(r^cur,r^1,r^2,r^3) & true
+  =>   r^cur ? +g(r^1,r^2,r^3) : -g(r^1,r^2,r^3)  & true
+
+
+Fri Jun 30 10:48:46 JST 1995
+
+各stateに、regular variableのmapを割り当てる。方法がいまいち
+わからない。^rの生成された状態を識別することが必要。
+
+^r(s)  をやってみる。昔もやった。
+   true & ^r 
+が爆発する
+   r^1 ; r^2; r^3;  ...  ; true & ^r 
+これが
+   r^1 true & ^r 
+となれば良い。
+   r^1 .... r^2
+は新しいr^nになる。(相互関係は?) ^r どうしの制約を保持した
+もっとも少ないr^nを選択すれば良い。(この変換はsafe & compete?)
+相互関係を保存しないなら^rをすべて共通にすれば良い。が、
+それはうまくいかない。
+   r^1 , not(r^2)  -> r^1, not(r^1) -> false
+のような場合があるから。
+   r^1 , not(r^2)  -> r^1
+か? 
+
+他の変数が入る場合は? r^1 .. r^n に依存するtermの変換を
+計算する。= BDT の leaf の数。それを表現できる最小のr^nを
+作る。
+
+そうすれば、temporal operatorのネストは変わらないのだから、
+全体は有限になるはず。
+
+これでなんでfullでなくてregularになるの? ^r がcontext dependent
+でないから。 r^1 , not(r^2)  -> r^1 は、context dependent では
+できない。(なるほど...)
+
+Wed May 24 20:32:34 JST 1995
+
+^rは、やはり、
+    ^r -> +r, -r
+の変換でなんとかするべき。こうして生成したモデルは、正しいRITLを
+含んでいる。あとは整合性のチェックをすれば良い。
+
+(1) local consstency check   => regular variable
+(2) global consistency check => regular constant
+
+どういうようにcheckするの? ん....
+
+
+昔のbdcomp.pl をbddlibで書き換える。
+
+characteristic function f(q)
+   f(q) = more,fx_q(sbn,sbx,P);empty,fn_q(P)
+
+      f(p&q) =  f(q) & q
+
+
+Tue May  2 17:49:35 JST 1995
+
+BDDLIBを組み合わせたが、やっぱり Prolog <-> BDD の変換が入るだけ
+遅くなるだけだった。bdtstd.pl は綺麗になるのだが。
+
+前作ったBDDの方式も遅くなるだけだった。(BDT/*) それは、
+    BDD の leaf をnext leafに展開
+    BDDの再構成
+    next leafを2-3 treeに登録
+    新しいnext leaf をさらに展開
+というのがすごく遅かったから。
+
+Charcteristic Function を作り上げる方法は、今一だ。でもBDDLIBなら
+うまくいくかもしれない。
+
+Subtermを前もって、すべて、
+    condition, next
+というBDDに展開しておいたら?
+
+Quantifierなどは、Subtermの中に状態が現れてしまう。だから、
+前もって、中を展開しておく。
+
+そうすれば、あとの処理は、BDDのみでできるはずだ。(しかし、CF法と
+結果は同じ?)
+
+Wed Mar 29 17:22:43 JST 1995
+
+regular(r,....r....)
+という形を使う ( QPTL <-> RITL だから... )
+
+Quantifierを直接使うのは?
+   st(0) = exists(c, c->st(1),not(c)->st(2))
+さぁ...
+
+begin(r,formuala) -> T/F
+end(r,formula)    -> T/F
+
+異なるうformulaが実は同じだった。-> いつか regular(r, f)
+という同じ形になる。
+
+regular(r,f(r))
+    empty(f(r))      ->  r=true,empty
+    not(empty(f(r))) ->  r=false,empty
+regular(r,f(r))
+    more(f(r))      ->   r=true,regular(r,fx(r))
+    not(more(f(r))) ->   r=false,regular(r,fx(r))
+
+したがって生成されるモデルは冗長。
+
+chop が来た時に r をreset しないといけない。
+(だよね...)  だったら、regular(r,f(r))はいらない?
+どうやって? r を前もって宣言するってのは?
+
+PDA との関係は?
+
+Thu Dec 15 20:21:58 JST 1994
+
+Modelとの対応
+
+     t0 -[+-]-> t1 -[+-]-> t2 -[+-]-> t3 
+
+      |---------|-----------|
+     r0         r1          r2
+                |-----------|-----------|
+                r0'        r1'         r2'
+
+r0 は常に要素0から始める。
+から始める。
+r0 -[-]-> r1 で集合の要素にシフトする。
+r0 -[+]-> r1 で次の時間のものと違うFAであることを表す。
+
+Mon Nov 28 19:27:37 JST 1994
+
+RITLステートをITL formulaのbool代数で表す。bool代数はBDDで表現する。
+
+もともとITL formula自身がsubtermの集合だから、二重のbool代数になる。
+したがって、double exponential algorithmとなる。
+
+r/not(r) flip では、すべての組合せは生じるが、すべての組合せの
+連結は表現できない。したがって、生じたすべての組合せをとって
+おけば良い。
+
+集合の作り方
+   r/not(r) flip で生じたLITLを集合として持つ (implementationは?)
+
+   r の例
+       [1]    r -(+r)->     r, r -(-r)-> not(r)    {r,not(r)}
+       [2]    r -> {r,not(r)} -> {r,not(r)}   (終り)
+
+   t & r の例 (detailは異なる。emptyの場合があるから)
+       [1]    t & r -(+r)-> r\/t & r, t & r -(-r)-> not(r)\/t & r
+              {r\/t&r, not(r)\/t&r}
+       [2]    {r\/t&r, not(r)\/t&r} -> {r;t&r, not(r);t&r} (終り)
+   [a](r=length(2))の例
+       [1]     [a](r=length(2)) -(+r)- >     r =length(1)/\[a](r=length(2))
+                                -(-r)- > not(r)=length(1)/\[a](r=length(2))
+               {r =length(1)/\[a](r=length(2)),
+                not(r)=length(1)/\[a](r=length(2))}
+       [2]     {r =length(1)/\[a](r=length(2)),
+                not(r)=length(1)/\[a](r=length(2))} =>
+               { r =length(0)/\  r =length(1)/\[a](r=length(2)),   F
+                 r =length(0)/\ ~r =length(1)/\[a](r=length(2)),
+                ~r =length(0)/\  r =length(1)/\[a](r=length(2)),
+                ~r =length(0)/\ ~r =length(1)/\[a](r=length(2))}   F
+       [3]      =>    [2] へ
+                   or [1]'へ (r=length(1)がtrueの場合)
+
+もっとコンパクトになるんじゃない? (これだとfinitenessは明解だけど)
+ITL(r)は、rをr/not(r)に任意に置換したもののsubset。どれとどれが一致するかを
+覚えれば良いのでは? => 開始時点が等しいものが一致。
+Indexを付けるのはダメ。=> モデルが有限にならない。(うーむ、わからない)
+
+    ITL(r) => 展開 => subset
+
+
+モデルの解釈
+
+   bool代数は、rのassignmentが与えられると解決する。しかし、一つの
+   ノードが別な解釈を共有することもあり得る。
+
+   Term間は任意に遷移するのか?
+   そうではなくて、同時に遷移する。
+
+   異なる開始時点を持つrは、同時に異なる遷移を廻る
+   すべて可能な遷移があるわけではなく、いくつかはFとなり禁止となる
+       => r に対する制約
+
+実行できる?
+
+   bool節の一つのinstanceを適当に実行すれば良い
+
+Rに単一のautomatonを割り振ることは可能か?
+   [a](R = r)  where r is automaton constant
+
+時間を遡ってモデルを作る
+
+   これによって、state minimizationも同時に走らせることができる
+   Minimizationのテストプログラムを作って見ること
+
+Thu Nov 24 14:54:00 JST 1994
+
+LTTL = LITL < RE
+    LITL* = RE
+    RITL  = RE    RITL(= 2nd order LITL)
+    RITL is decidable
+
+LTTL = LITL on compact time
+
+Even(p)は、LITLでもだめ。
+    (p.)* ができない
+    (abac)* -> (a[bc])*
+
+LITL -> LTTL converter
+
+LITL/LTTLは、やっぱり群を構成する
+
+[]a & []b & []a
+a...ab...ba...a ->  a until (b until []a)
+    だからconversionできる?
+a & b & aは
+     a, <>(b, <>a)
+か... うう、できそうな気がする...
+
+P & Q ->   start(P),(run(P) until lttl(Q)) に変形する
+           run(P)にはquantifierが入るのか? 入らない?
+
+events      continue
+|----------|..........|
+|-> <>(events)
+           |-> [](continue)
+<>events,  <>(continue until Q))
+というようにcompileする。ふむ。
+
+l(P) & Q    l(P) = LTTL formula of P
+   <>(P) ->  <>(P,<>(l(Q)))
+   [](P) ->  P until l(Q)
+   
+
+RITL decidability
+
+    Reverse Specification
+
+    R -> +(R) -(R) on Start Time
+
+    empty(R) は hidden だけど、+R/-R に関しては同期する
+    ここがまだ良く分からない。
+
+    Modelを直接構成しない。filtrationの意味でも...大きすぎるから。
+    その代わり、Model constraintを構成する。
+
+Generating C / In-kernel implementation
+
+Wed Oct  5 15:30:19 JST 1994
+
+Regular variable.
+
+^r ->     more(^r), @(    ^r) 
+      not(more(^r)),@(not(^r)) 
+^r ->     empty(^r),     empty
+      not(empty(^r), not(empty)
+
+This gives ^r constraints, and produce finite state.
+
+Meaning of regular variable.
+
+Mij(^r) = f(Mi(more(^r),empty(^r)),Mi+1j(^r))
+
+^r's automaton is depend on clock, and fin time is controled
+in finite state machine's way. Mij(^r) is f(Mi(p)...Mj(p)).
+^r = lenght(3) & ^r = length(2) is statisfiable.
+Is this different from interval variable? Yes. But How?
+
+If we need all regular variable act the same automaton,
+  exists(^c) [a](^r= ^c),...
+where ^c is a time stable automaton.
+
+It is ok to show:, 
+   M |= not(^r),(^r & true)
+
+Problem.
+
+   [a](^r=lenth(2)) , lenth(4)  is unsatisfiable
+
+   empty(^r),(empty =^r) => ^r      (true)
+   empty(^r),(len(1)=^r) => not(^r) (false)
+
+((empty = ^r)&true), ((length(1) = ^r)&true)
+but this is satisfiable.... ?-?
+
+
+Let's think about,
+   exists_automatic(R)     f(R) = g
+automatic unification = boolean unification?
+
+Sat Jun 12 10:41:24 JST 1993
+
+dvcomp uses subterm tree for decomposition and
+ndcomp uses chop normal form. Since development
+result is not the same, lazy generation of
+state is not allowed.
+
+sb's and itl_state's hash and sharing is important.
+Time to write C version?
+
+Sun Jun  6 14:15:42 JST 1993
+
+Now module system is supported.
+tgen/0 generates Tokio program and
+kiss/0 generates KISS format for SIS.
+
+ex(300,X),ex(true proj ~X) becomes very large. Terminates?
+ex(300,(X,Y)),ex(true proj (X;Y)) is still very large, but
+ex(300,(X,Y)),ex(true proj X) is Ok.
+
+old/bdcomp does not check sbterm early. This is the reason why this
+method is slow.
+     expansion ; subterm check   is bad
+     expansion with subterm check will be ok.
+
+How about permutation?
+    Declare permutation from the begining.
+
+    |- permute V on F <-> F
+
+How about anti-symmetry?
+    
+    |- odd-permute  V on F <-> ~ F
+    |- even-permute V on F <-> ~ F
+
+Mon Nov  9 15:18:49 JST 1992
+
+prefix operator is wrong.
+     length(2),prefix((length(3),fin(false)))
+must be false.
+
+Mon Sep 21 20:16:39 JST 1992
+
+
+I'm very sorry to send you rather large example. But it is 
+a little dificult to extract simple example.
+
+To compile and load,
+
+| ?- [bddi].
+
+
+In next example, fixpoint predicates find a subtle counter example of ITL
+formula.
+  (p&&p&&p&&p&&p&& ~p&&p)->[](<>p)
+
+is tested by
+
+| ?- ex(10,X),fixpoint(X).
+
+First, this formula is translated into a finite state automaton.
+Like this.
+
+                 +----------+
+     E,PL -------| Logic    |--->   E,PL
+                 |          |
+     Sn   +------|          |--->+  Sx
+          |      |          |    |
+          |      +----------+    |
+          |      +----------+    |
+	  +-<----| Latch    |----+
+                 +----------+     
+
+In this case, Sn/Sx pairs are vector of ITL subterm. "Logic" is
+defined in boolean constraint on Sn/Sx.
+
+In fixpoint/10, fixpoint(F,Fix,Fix1,E,P,PL,Sn,Sx,S,N),
+   F    current possible state (boolean constraint of Sn)
+   Fix	disjunction of visit state
+   Fix1	previous visit state, if it is eqaul to Fix, everything is done.
+   E,P,PL	Input/Output value of variable in state diagram
+   Sn	state variable
+   Sx	next state variable
+   S	for display subterm state.
+   N	depth count
+
+fixpoint(_,Fix,Fix1,_E,_P,_PL,_Sn,_Sx,_S,_N):-
+	bool:taut(Fix=:=Fix1,1),!,write('end'),nl.
+fixpoint(F0,_,Fix,E,P,PL,Sn,Sx,S,N):-
+	quantify(Sn,F0,F0S),bool:sat(F00=:=F0S),  % take all possible state 
+	display_state(E,E*F00,P,PL,S,_,Sn),     % find counter example
+	quantify([E|PL], ~E*F00,F0P),           % for all possible I/O
+	bool:sat(F0Q=:=F0P),           
+	copy_term([E,Sx,F0Q],[0,Sn,F1]),        % replace Sn/Sx
+	bool:sat(Fix1=:=Fix+F1),                % for termination
+	write_state_number(N,N1,'depth:'),!,
+	fixpoint(F1,Fix,Fix1,E,P,PL,Sn,Sx,S,N1).
+
+So this traces all possible execution in finite state automaton.
+
+| ?- ex(10,X),fixpoint(X).
+depth:0                       % it becomes slower and slower...
+depth:1
+depth:2
+depth:3
+depth:4
+depth:5
+depth:6
+depth:7
+empty,[t(p,0)],[...]          % find one counter example
+|:                            % a return is required
+depth:8
+end
+
+X = ((p&&p&&p&&p&&p&& ~p&&p)->[](<>p)) ?
+
+yes
+| ?-
+
+I think I need something like setarg in boolean constraint.
+Sun Sep 20 18:10:30 JST 1992
+
+Why not add exclusive status as a primitive?
+    states([a,b,c,d,e,f]) -> [](( ~(( a,b)), ... )
+	2^n ... Wow!
+It generates
+    status(a)->  ... ; status(b)-> ...  status(f)-> .. ; status([])-> ...
+	generate n+1.
+
+Tue Sep 15 13:04:43 JST 1992
+
+結局、Regular variable state を共有しないと収束しないし、
+共有できるかどうかの判断は大域的だから、この方法では
+できないらしい。
+
+Tue Sep 15 11:36:36 JST 1992
+
+Regular variable must be non-deterministic.
+^r
+[more,up(r),down(r)] is not false
+
+If we don't care about down, we cannot distinguish
+    ^r& ^r ,not( ^r )
+
+    up(r)      down(1)    ~down(1)
+    |                |       |
+    |----------------|-------|
+               up(r)       down(2)
+
+Mon Sep 14 14:07:52 JST 1992
+
+(^r & ^r),not(^r)
+itl:0 [empty,up(r),down(r,0)] -> false
+itl:0 [more,up(r),down(r,0)]  ->  false
+itl:0 [more,up(r),~down(r,0)] ->  (stay(r,now)&^r),not(stay(r,now))  now=1
+stay(^r,0)
+
+(stay(r,now)&^r),not(stay(r,now)) 
+itl:1 [empty]->false
+itl:1 [more,down(r,1),up(r),down(r)]->false
+itl:1 [more,~down(r,1)]-> (stay(r,now)&^r),not(stay(r,now)) now = 1 2
+itl:1 [more,down(r,1),~down(r,0)]]-> 
+    stay(r,1);(stay(r,now)&^r),not(stay(r,now)) 3
+stay(2,1)
+
+stay(r,1);(stay(r,3)&^r),not(stay(r,3)) 
+itl:3 [empty,down(1)]->empty
+itl:3 [empty,~down(1)]->false
+itl:3 [more,down(r,1)]->true
+itl:3 [more,~down(r,1)]-> stay(r,2);(stay(r,4)&^r),not(stay(r,4)) = 3
+itl:3 [more,down(r,1),~down(r,0)]]-> stay(r,1);(stay(r,3)&^r),not(stay(r,3)) 3
+stay(2,1),stay(4,3)
+
+Mon Sep 14 00:25:08 JST 1992
+
+^r で生成されるautomatonは、^rを普通の変数と見て生成するtableauの
+subsetである。従って、tableauのnodeを指し示すことで ^r のモデルを
+作ることが出来る。しかし、うまくいかない...
+
+(^r & true),not(^r) のモデルはないから
+
+そこで、stay(r,N)を使う  (up(r),emtpy & true & down(r),empty) ではだめ。
+^r & ^r -> ^r になってしまうから。
+
+するとモデル構築が収束しない  --> これは Full ITL だから
+
+しかしRITLのモデルは有限だから stay(r,N)のかなりの部分は
+相互に等しい。等しいかどうかをどう判断するかが問題。
+
+Deterministic Pathが等しければ同じstateと判断するのでは足りない
+Loopが作れないから。
+
+むしろすべて等しいのがDefaultで、必要な時だけ分離するのが望ましい
+
+Mon Jan  1 11:05:38 JST 1990
+
+^r & ^r
+itl:0 [empty,up(r),down(r)] -> empty
+itl:0 [more,up(r),down(r)]  ->  false
+itl:0 [more,up(r),~down(r)] ->  stay(r,[true])&^r  1
+stay(r,[]) -> down,empty
+stay(r,[]) -> ~down,more
+
+stay(r,[])&^r
+itl:1 [empty,down(r,[]),down(r,[true]),up(r)]
+itl:1 [more,down(r,[true]),up(r),down(r,[])]->false
+itl:1 [more,~down(r,[true])]-> stay(r,[true,true])&^r 2
+itl:1 [more,down(r,[true]),up(r),down(r,[])]->false
+itl:1 [more,down(r,[true]),up(r),~down(r,[])]->stay(r,[true]) 3 -> false
+itl:1 [more,down(r,[true]),~up(r)])]->false
+stay(r,[]) -> down,empty
+stay(r,[true]) -> down,up(r),empty
+stay(r,[true]) -> more, ~down, stay(r,[true,true])
+                                    stay(r,[true])  ?why not
+stay(r,[true]) -> more, down, up(r), stay(r,[true])  -> false
+
+stay(r,[true,true]) -> down,up(r),empty
+itl:2 [empty,down(r,[]),down(r,[true,true]),up(r)]
+itl:2 [more,down(r,[true,true]),up(r),down(r,[])]->false
+itl:2 [more,~down(r,[true,true])]-> stay(r,[true,true,true])&^r 4
+itl:2 [more,down(r,[true,true]),up(r),down(r,[])]->false
+itl:2 [more,down(r,[true,true]),up(r),~down(r,[])]->stay(r,[true]) 3 -> false
+itl:2 [more,down(r,[true,true]),~up(r)])]->false
+stay(r,[true,true]) -> down,up(r),empty
+stay(r,[true,true]) -> more, ~down, stay(r,[true,true,true])
+                                    stay(r,[true,true])  ?why
+stay(r,[true,true]) -> more, down.
+
+Sat Sep 12 18:05:26 JST 1992
+
+How about contiion-history list?
+
+    (p->^r),@((q->^r),@empty)
+    itl:0  [more,p,up(r),~down(r,[])]	-> stay(r,[p]),(q->^r,@empty)	1
+    itl:0  [more,~p]-> true
+    stay(r,[])    p ->stay([p]),~down
+                 ~p->true
+
+    stay(r,[p]),q->^r,@empty
+    itl:1  [more,p,q,up(r),~down(r,[p]),~down(r,[])]	
+         -> empty,stay(r,[(p,q),p]),stay(r,[p]),stay(r,[q]) 2
+    itl:1  [more,~p,q,up(r),~down(r,[p]),~down(r,[])]	
+         -> empty,stay(r,[(~p,q),p]),stay(r,[q]) 3
+    itl:1  [more,~q]	-> empty,stay(r,[~q,p]) 4
+    stay(r,[])    q ->stay(r,[q]),~down
+                 ~q ->true
+    stay(r,[p])   q ->stay(r,[(p,q),p]),~down
+                  q ->stay(r,[(~p,q),p]),~down
+                 ~q->true
+
+    empty,stay(r,[(p,q),p]),stay(r,[p]),stay(r,[q]) 
+    itl:2  [empty,q]	-> false
+    itl:2  [empty,~q,down(r,1),down(r,0)]	-> true 
+    stay(r,[(p,q),p])    ->down
+    stay(r,[p])    ~q->down
+    stay(r,[q])    ~q->down
+    stay(r,[(p,q),p])  ~q->down
+
+    empty,stay(r,[(~p,q),p]),stay(r,[q]) 
+    itl:3  [empty,down(r,1),down(r,0)]	-> true 
+    stay(r,[(p,q),p])  ->down
+    stay(r,[q])  ->down
+
+    empty,stay(r,[~q,p])
+    itl:3  [empty,down(r,1)]	-> true 
+    stay(r,[~q,p]) ->: down
+
+Fri Sep 11 16:13:48 JST 1992
+
+Parallel Regular variable construction
+
+    itl:0  [up(r),~down(r,0)] -> ... stay(r,0).... 1   -> stay(r,N1)
+           [up(r),~down(r,0)] -> ... stay(r,0).... 2   -> stay(r,N2)
+
+    ^r:0   [up(r),~down(r,0)] -> ... stay(r,N1).... 1
+           [up(r),~down(r,0)] -> ... stay(r,N2).... 2
+
+    equivalence list
+           stay(r,i) = stay(r,j) 
+    if     stay(r,4) -f-> stay(r,i)
+           stay(r,4) -g-> stay(r,j),   f->g
+
+    stay(r,n) .... itl:n -> [x0,x1,x2...xk]
+
+Tue Sep  8 22:13:51 JST 1992
+
+true & ^r
+[empty,up(r),down(r)]->true
+[more,up(r),down(r)]->(stay(r,1);true & ^r)
+[more,up(r),~down(r)]->(stay(r,1);true & ^r) = 3 
+[more,~up(r)]->(true & ^r)
+
+How to prevent stay(r,N) multiplier?
+
+state(3) = (stay(r,1);true & ^r) 
+[empty,down(r,1)]->empty
+[empty,down(r,3),up(r),not(down(r,1))]->empty
+[empty,not(down(r,3)),up(r),not(down(r,1))]->false
+[empty,down(r,3),not(up(r)),not(down(r,1))]->false
+[empty,not(down(r,3)),not(up(r)),not(down(r,1))]->false
+[more,up(r)]->(stay(r,1);stay(r,3);true & ^r)
+[more,not(up(r))]->3
+
+Why stay(3) = stay(1)?   .... Finitarity?
+
+state(1 , ^r& ^r,not(^r))
+[empty,down(r,1),up(r)]->false
+[empty,not(down(r,1)),up(r)]->false
+[empty,down(r,1),not(up(r))]->false
+[empty,not(down(r,1)),not(up(r))]->false
+[more,down(r,1),up(r)]->3       (stay(r,1);stay(r,1)& ^r),not(stay(r,1))
+[more,not(down(r,1)),up(r)]->4  stay(r,1)& ^r,not(stay(r,1))
+[more,down(r,1),not(up(r))]->false
+[more,not(down(r,1)),not(up(r))]->false
+
+state(3 , (stay(r,1);stay(r,1)& ^r),not(stay(r,1)))
+[empty,down(r,1)]->false
+[empty,not(down(r,1))]->false
+[more,up(r),down(r,1)]->3
+[more,not(up(r)),down(r,1)]->3
+[more,not(down(r,1))]->3
+
+state(4 , stay(r,1)& ^r,not(stay(r,1)))
+[empty,down(r,4),up(r),down(r,1)]->false
+[empty,not(down(r,4)),up(r),down(r,1)]->false
+[empty,down(r,4),not(up(r)),down(r,1)]->false
+[empty,not(down(r,4)),not(up(r)),down(r,1)]->false
+[empty,not(down(r,1))]->false
+[more,up(r),down(r,1)]->3
+[more,not(up(r)),down(r,1)]->4
+[more,not(down(r,1))]->4
+
+1.4510000000000002 sec.
+
+
+Tue Jun 30 17:01:37 JST 1992
+
+Quantifier does not works well.
+?-fixpoint(even(p)=evenp(p)).
+Projection looks like difficult.
+
+Tue Jun 30 08:58:27 JST 1992
+
+fixpoint((a,(more = (more & more)))) terminates. why?
+fixpoint(more = (more & more)) causes loop. why?
+
+It looks like SICSuts's bug. Some how I avoid that.
+
+Sun Mar 01 01:01:57 1992 BST
+
+Yes, I almost finish BDD version.
+
+Quantification is very subtle in SICStus.
+
+?-bool:sat(_A=:= B*C),bool:sat(_A=:=A),bool:sat(E =:= ~B*A^A).
+?-bool:sat(_A=:= B*C),bool:sat(A=:=_A),bool:sat(E =:= ~B*A^A).
+give us different result.
+
+?-fixpoint(p-> [](<>(p))  causes quantifier failure.
+
+exists(p,..) is now working, but closure is not.
+
+Mon Feb 10 20:06:36 1992 BST
+
+?-fixpoint(p,X).
+    subterm(p,N,_,[p(N)],[])              p =:= N
+    ?-tableau(N,F1,[],[])
+        F1 = exists(p,F*R)/replace(S,S')
+                      N=p,   F1=nil?
+      	copy_term([],[],N],[[],[],F]),    no constrain on N/F
+	?-bool:sat(F1=:=(N+F)).
+ ?-bool:taut(N=:=F1,1)     N=:=(N+F)  x
+
+
+Wed Nov 06 21:56:57 1991 BST
+
+Dense time modification.
+
+more <-> more & more
+ discrete time:
+      more      -> empty->false;more->true
+      true      -> empty->true; more->true
+      more&more -> empty->false;more->true&more
+      true&more -> empty->false;   <---- This makes difference
+                   more->true
+ dense time:
+      more&more* > empty->false;more->more*
+      more*     -> empty->true ;more->more*
+
+      more      -> empty->false;more->true
+      true      -> empty->true; more->true
+      more&more -> empty->false;more->true
+      true      -> empty->true; more->true
+
+
+Tue Jun 25 07:21:11 1991 BST
+
+2nd order local variable is also easily implemented. Notation?
+regurlar
+
+Tue Jun 25 07:06:28 1991 BST
+
+For verification,
+Information hiding is bad. Necessary information muse be accessed by
+everyone for reliability. Only useless information is allow to hide.
+If some information does not change world, it is useless. Higer
+abstraction makes many information useless, which can be hide.
+
+Tue Jun 25 06:52:32 1991 BST
+
+Closure is easily implemented.
+Single varible quantifier is also easy. These are effectively
+equivalent in expressiveness.
+
+But nested quantifier is very different. Its decomposition is
+same as sigle variable case,  but to make a standard form, it
+requires P-space. Quantifier impelentation of bdtstd/itlstd
+will be difficult.
+
+Derivation tree generation method is much suitable for quantifier.
+But is it worth implement? It is better to find out another
+abstraction mechanism, such as multi-linear projection.
+
+The important this is not what IS existing, but how it DOES exists.
+Quantifier lacks synchronization type.
+
+Tue Jun 21 21:08:31  BST 1991
+
+Problem on Theorem prover
+
+1) it does not handle eventuality
+      |= true & empty  ( compact interval )
+      |= finite -> (true &  empty)  <- eventuality axiom
+       ( open interval ) introducing topology? and differencial?
+       d/dt f(x,t)  is related to scheduling? very close to ....
+2) dense time
+      what's wrong?
+3) 3-stages: itlstd, decomposition, checking are redundant each other.
+      -> derivation tree construction ( do this first )
+      (bdcomp.pl must work faster)
+4) extensions
+       infinite interval
+       interval variable
+       projection
+       framing
+       multi-linear
+       scheduler
+       other standard form
+       interactive proof/protocol design
+       rational length operator
+5) overupping interval (minus length)
+
+Tue Jun 18 16:45:35 BST 1991
+
+true & q ->
+  NDST
+   e0, e1   q->true
+   m0, e1   q->@true
+   m0, m1   ->@(true & q)
+   else false
+  DST
+  [e0,q]  -> true 
+  [m0,q]  -> @true ;@(true & q)
+  [e0,~q] -> false
+  [m0,~q] -> @false;@(true & q)
+
+~(true & q) ->
+  NDST
+   e0, e1   q->false
+   m0, e1   q->@false
+   m0, m1   ->@~(true & q)
+   else true
+  DST
+  [e0,q]  -> false 
+  [m0,q]  -> ~(@true ;@(true & q))
+  [e0,~q] -> true
+  [m0,~q] -> ~(@false;@(true & q))
+
+Tue Jun 18 15:49:21 BST 1991
+
+
+%
+% London 23:38 36.52 	Newyork 18:38 	Tokyo 07:38 
+%
+p & q
+  ->  |-----|-----|
+           1   0
+
+ifEmpty(p)      1->p 
+ifNotEmpty(p)  ~1->p
+
+
+P & Q ->
+   0         P,Q
+  ~0, 1    beg(P),Q
+  ~0,~1    Pn, @(Px,Q)
+
+p & q ->
+  NDST
+   0       p,q->true
+  ~0, 1    p,q->@true
+  ~0,~1    p->@(true & q)
+           else false
+  DST
+  [p,q]  -> [0]true +[~0,1]@true +[~0,~1]@(true & q) <- sometime?
+  [p,~q] -> [0]false+[~0,1]@false+[~0,~1]@(true & q)
+  [~p]   -> []false
+      a path must contain true eventuality
+
+~(p & q) ->
+  NDST
+   0       p,q->false
+  ~0, 1    p,q->@false
+  ~0,~1    p->@~(true & q)
+           else true
+  DST
+  [p,q]  -> [0]false+[~0,1]@false+[~0,~1]@~(true & q) <- never?
+  [p,~q] -> [0]true +[~0,1]@true +[~0,~1]@~(true & q)
+  [~p]   -> []true
+      a path must not contain false eventuality
+
+
+iのは式の中の&の数に等しい
+
+empty
+   0  true
+  ~0  false
+~empty
+   0  false
+  ~0  true
+fin(p)
+   [p]   -> [0]true +[~0]@fin(p)
+   [~p]  -> [0]false+[~0]@fin(p)
+keep(p)
+   [p]   -> [0]true+[~0]@keep(p)
+   [~p]  -> [0]true+[~0]false
+p & q & r ->
+  NDST
+   2, 1, 0    p,q,r->true
+   2, 1,~0    p,q,r->@true
+   2,~1,~0    p,q->@(true & r)
+  ~2,~1,~0    p->@(true & q & r)
+  DST
+  [~p]      -> []false
+  [p,~q]    -> [        0]false 
+              +[ 2, 1,~0]@false 
+              +[ 2,~1,~0]@(true & r)
+              +[~2,~1,~0]@(true & q & r)
+  [p,q,~r]  -> [        0]false 
+              +[ 2, 1,~0]@false 
+              +[ 2,~1,~0]@(true & r)
+              +[~2,~1,~0]@(true & q & r)
+  [p,q,r]   -> [        0]true 
+              +[ 2, 1,~0]@true 
+              +[ 2,~1,~0]@(true & r)
+              +[~2,~1,~0]@(true & q & r)
+
+~(p & q & r) ->
+  NDST
+   2, 1, 0    p,q,r->false
+   2, 1,~0    p,q,r->@false
+   2,~1,~0    p,q->@~(true & r)
+  ~2,~1,~0    p->@~(true & q & r)
+  DST
+  [~p]      -> []true
+  [p,~q]    -> [       0]true 
+              +[ 2, 1,~0]@true 
+              +[ 2,~1,~0]@~(true & r)
+              +[~2,~1,~0]@~(true & q & r)
+  [p,q,~r]  -> [       0]true 
+              +[ 2, 1,~0]@true 
+              +[ 2,~1,~0]@~(true & r)
+              +[~2,~1,~0]@~(true & q & r)
+  [p,q,r]   -> [        0]false 
+              +[ 2, 1,~0]@false 
+              +[ 2,~1,~0]@~(true & r)
+              +[~2,~1,~0]@~(true & q & r)
+
+
+Thu Jun 13 12:00:39 BST 1991
+
+Empty Queue should be incoporated into Cond part.
+Only true/false remains in Em_j part.
+
+ S = \Sum_j Cond_j -> ( \Sum_i empty_i->Em_{i,j} ->  More_j )
+~S = \Sum_j Cond_j -> ( \Sum_i empty_i->Em_{i,j} -> ~More_j )
+
+Thu Jun 13 11:32:44 BST 1991
+
+ S = \Sum Cond_j -> ( empty->Em_j  ; ~empty->More_j )
+~S = \Sum Cond_j -> ( empty->~Em_j ; ~empty->~More_j )
+  since empty is invisible, ; means non deterministic choice
+More_j  = Keep \and @ More   => troubled on negation
+
+Cond_j -> ( empty->Em_j + (Keep_j \and @ More_j) )
+  =>
+Cond_j +  Keep_j -> ( empty->Em_j + ~empty->@ More_j )
+Cond_j + ~Keep_j -> ( empty->Em_j + ~empty->false )
+
+Example
+
+ empty ->  true -> (empty->true + ~empty->false)
+~empty ->  true -> (empty->false+ ~empty->true)
+fin(p) ->  true -> (empty->p+ ~empty->@fin(p))
+keep(p) ->   p -> (empty->true + ~empty->@keep(p))
+          + ~p -> (empty->true + ~empty->false)
+
+Wed Jun 12 16:05:31 BST 1991
+
+ITL->DST converter using BDT
+
+varialbe order
+p & q
+   ~p -> []
+    p,q  -> [e0, (t & q)]     e0 = (t & q)
+    p,~q -> [~e0,(t & q)]
+t & q   (contains both ~e0, e0)
+   ~q -> [~e0,(t & q)]
+   q ->  [e0,t,(t & q)]
+t  -> [e1,(~e1,t)]            e1 = (t)
+
+ITL model checker
+
+Wed May 22 15:37:30 BST 1991
+
+The problem is negation of state digram is time consuming task.
+To make a symmetrical treatment of negation on state digram,
+exclusion normal form is good. 
+
+P  == (ab -> empty) + ((~a)b -> false) + (a(~b)+~a~b -> @next)
+~P == (ab -> false) + ((~a)b -> empty) + (a(~b)+~a~b -> @~next)
+
+True-Set + False-Set + Next-Set
+
+It requires 2^numver(variables on expression) terms. (Sad..)
+
+P,Q -> PQ
+P;Q -> PQ + ~PQ + P~Q
+
+Tue May 21 19:16:12 BST 1991
+
+Extenstion of state diagram is necessary.
+
+  true & p     = <>p
+      s0 -empty->    p
+      s0 -e(true)->  s0
+      s0 -e(p)->     true
+  ~(true & ~p) = #p
+      s0 -empty->    p
+      s0 -a(~p)->    false
+      s0 -e(true)->  s1(~true & ~p)
+  ~(p & ~q) = #p
+      s0 -empty->    ~p;q
+      s0 -a(p)->     s1(~(true & ~q))
+      s1 -a(~q)->    false
+    p & q 
+      s0 -empty->    p,q
+      s0 -p->        s1(true&q)
+      s1 -e(true)->  s1
+      s1 -e(q)->     true        = s1 -a(~q)-> false
+
+Tue May 21 15:08:51 BST 1991
+
+The point is the concurrent development of negation form.
+	|- ~(On Some interval, P)  <->
+	|- For all interval, ~P  <->
+	|\- On Some interval, P
+	|- ~~P <-> |-P
+
+	|-P,|\-Q => |-P0,@Pnext , |\-Q0,@Qnext
+	=> |\-Q0,@Qnext
+	   |-(P0,~Q0),@Pnext
+	   |-(P0,Q0),@(Pnext,~Qnext)
+   example
+	|- ~(q & ~p) => 
+	   |\- q,~p,empty
+	       |- empty,~(q,~p)
+	   |\- empty(q),~p,~empty =>
+	       |- q,p
+	       |- ~q
+	   |\- q,@(q & ~p) => 
+	       |- ~q
+	       |- q, @~(true & ~p)
+Anther problem is Empty/More state.
+	An interval can be empty/~empty
+	~(empty,P) -> ~empty;~P    this is funny
+	|- ~(empty,P) <-> |\- empty,P
+	   ~P,~(empty,P),empty is Ok
+	   This means false transision has separate Empty flag
+	empty,(P&Q) -> empty,P,Q
+Global variables maps 
+	local variable state diagram -> {true, false}
+	How to calculate it comformity?
+
+Thu May 16 12:54:27 BST 1991
+
+Decomposition Rule for Model Checking
+    ~ , ; & @
+Failure Set
+Success Set
+    ?-de(Proposition,Now,Next).
+
+    de((P,Q),(NP,NQ),(XP,XQ),F) :- de(P,NP,XP,F),de(Q,NQ,XQ,F).
+    de((P;Q),Now,Next,F) :- de(P,Now,Next,F).
+    de((P;Q),Now,Next,F) :- de(Q,Now,Next,F).
+    de(~P,Now,Next,(FN,FX)) :- de(P,FN,FX,(Now,Next)).
+    de(@P,true,P,(FN,FX)) :- de(P,FN,FX,(Now,Next)). % weak?
+    de((P&Q),(PN,Now),Next,F) :- % empty case
+	de(P,PN,true,PF),de(Q,Now,Next).
+    de((P&Q),Now,Next,F) :- % non empty case
+	de(P,PN,true,PF),de(Q,Now,Next).
+
+Now is allways classical/local.
+
+Using Binary Decision Tree on Interval Variable
+
+    <t>P = true & P
+    [t]P = ~<t>~P = ~(true & ~P)
+    while i do j = i-> j&(while i do j) ; empty
+
+so everything is & and ~ and ; and ,.
+
+Formula = { Interval Variable, Local Variable, connectives }
+
+P = set of BDT on Interval Variables
+        P
+       /\
+      P  ~P
+There is only a finite number of interval variables.
+
+Clausal Form:
+     P :- x ; y ; P.
+     P :- empty.
+
+      P
+      x
+     /\
+
+it is better to make BDT primitives...
+
+variablesBDT
+compBDT
+andBDT
+orBDT
+negBDT
+hashBDT
+
+Mon May 20 14:24:59 BST 1991
+
+ITL decomposition Rule for Model Checker
+
+choices
+
+interval is  finite / infinite
+interval is  open   / close
+interval is  empty  / non-empty
+
+ITL   finite/close and has empty
+
+p,q
+p;q
+~p
+p&q
+
+local variable
+non local variable
+
+~(true & ~p)
+
+s0 
+Success: nil 
+Failure: true & ~p
+
+decompositon( Formula , Local State, Next Intervals )
+Formula -> (Local-0,  empty);
+	   (Local-1, ~empty) & Next Intervals ( with eventuality )
+~empty contains eventuality (OK?)
+
+local variable
+p -> p,empty ; (p,~empty & true)
+P & Q -> (empty,P,Q); ( empty,P & ~empty,Q ); ( ~empty, P & Q )
+
+local part should have standard form
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/read.me	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,337 @@
+LITE: A little LITL Verifier
+
+ Copyright (C) 1994,1991, 
+ Shinji Kono (kono@csl.sony.co.jp)
+   Sony Computer Science Laboratory, Inc.
+   The University, Newcastle upton Tyne
+
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license, but changing it is not allowed.  You can also
+ use this wording to make the terms for other programs.
+
+ send your comments to kono@csl.sony.co.jp
+
+Files
+    Makefile		Makefile for *.ql/*.pl, "make" is called from Prolog
+    bdtstd.pl		Binary Tree Database of Temporal Logic Formula
+    chop.pl		Chop normal form expander
+    demoi		Install Script for X-Window Interface
+    demoim		    "  with module
+    diag.pl		Diagnosis and Execution
+    display.pl		X-Window Interface (GM and InterViews)
+    dvcomp.pl		Lazy expansion version of ITL tableau
+    ex.pl		Built-in Examples
+    exdev.pl		Expansion Loop
+    init		Install Script 
+    initm		Install Script with module
+    kiss.pl		KISS2 format for UCB SIS
+    lite.pl		Install Script 
+    ndcomp.pl		ITL tableau expansion
+    read.me		This file
+
+0. Installation
+
+    Edit Makefile and change
+          PROLOG               your prolog path name, such as sicstus
+          PROLOG_TYPE          SICSTUS, XSB, SBPROLOG, CPROLOG, CPROLOG15
+    see cp.pl.c for portbaliity information.
+
+    Run your Prolog. I use SICStus Prolog but Quintus Prolog or C-Prolog 
+    will work.  In case of SBPROLOG, you also need SB_START_FILE.
+
+    Then consult a file init. 
+
+?-[init].
+
+    It runs unix make and compile and load necessary Prolog programs.
+    If you need a moduled version use ?-[initm].
+
+    In case of SB-Prolog, type
+	make
+    by hand. This create file named "lite". Then start SB-Prolog like this.
+        sbprolog lite
+    or you can use load(lite). Then you need to initialize by
+        ?- lite_start.
+
+0.1 How to run
+
+    Try numbered examples in ex.pl.
+
+?-ex(2).
+
+    It generates state machine. It also accepts an ITL formula.
+
+?-ex( [](p) -> <> p ).
+
+    Please be careful about funny Prolog operator grammar.
+    Someday I will make a parser for Ben's notation. But not now...
+    After the state machine expansion, there are two diagnosis predicates.
+
+?-diag.
+
+    This shows ``valid'' if it is a theorem, otherwise it shows you a counter
+    example.
+
+?-exe.
+
+    This shows an execution of ITL formula, if it is possible. It is
+    a counter example of negation of the original formula. ?-diag(N) or 
+    ?-exe(N) shows at least N length examples.  
+   	1: +p-q   means "at clock 1, p is true and q is false". 
+    Please note exe(N)/diag(N) generate all possible state transition,
+    but it only shows one possible state transition conditon for a
+    state transition.
+
+    In case of a large formula, you may want to make output tarse.
+
+?-verbose(off). 
+    generates one character per state transition condition.
+     e   empty
+     t   true
+     f   false
+     123. newly genrated state number
+     .   transition to a registerd state
+?-verbose(on).
+
+?-ex. runs all examples in diag.pl. But it takes several hours.
+      Some of the examples are quite large.
+?-exex. runs all examples and save state machine in file ``ex''.
+
+0.1. X-Window Interace
+
+    If you want to run X-window version, you have to install InterViews
+    interface for SICSTUS. It requires ispgm binary and library/gmlib.
+    ?-[demoim].    % This loads and runs X-window interface.
+    Type-in a formula. 
+       ex(1) or demo(1) for the example number in ex.pl.
+    Push verify buttom and execute buttom in order.
+    Execute and Counter Example buttons show an example in a graphical way.
+    Map button shows bitmap of the characteristic function.
+
+0.1.1 Tcl/Tk Interface
+
+
+0.2. KISS format interface
+
+    To generate KISS2 format for SIS, try run
+
+?-kiss.
+
+    right after verification. To specify input variables and
+    output variables assert this predicate:
+	st_variables(In,Out).
+    State machine description is also supported
+    in this system. You can read a KISS2 format state machine.
+    Only one state machine is accepted because of variable 
+    declaration.
+
+?- read_kiss(File,In,Out,Empty).
+
+    reads KISS2 format. In and Out are list of variables in the order
+    of the KISS2 file. If Out is [], output variales are omitted.
+    If In or Out are uninstantiated variables, name 'i0' or 'o2'
+    are used.  Empty is usually set to empty and it generates 
+    empty condition for each state, for example:
+	st(st0,empty,empty).
+    To modify or to generate KISS format again, you have to
+    verify it.
+	?- ex(st(st0)).
+    `st0' is the start state of automaton. The state machine can
+    be used in arbitrary temporal logic expression. But if you 
+    generate very non-deterministic modification, the output
+    can be very large. For examle:
+	 ?- ex(exists(i0,st(st0))).
+
+?- read_kiss(File).
+    =>  read_kiss(File,_,_,empty)
+?- read_kiss(File,Empty).
+    =>  read_kiss(File,_,_,Empty)
+
+0.3
+    dvcomp.pl contains lazy state transition clause generation and binary
+    tree representation of ITL term.  Reconsult it after [init].  It 
+    reduces memory usage drastically. To control lazy generation, use:
+       ?-lazy(on).
+       ?-lazy(off).
+    kiss format generation is not supported for lazy generation.
+
+1. Syntax of ITL Formula
+
+Comma for conjunction, and semi-coron for disjunction as in Prolog.
+& for chop operator. @ for strong next. next(P) for weak next. 
+Postfix * means weak closure, that is, it allows 0 times execution.
+To use existential quantifier, a form exists(R,f(R)) is used,
+here R have to be Prolog variable.
+
+Other definitions are found in chop.pl. If you want to see the expanding
+results ( chop normal form, cannot be readable...) use ?-expand(X,Y).
+
+    ~(P) 	=   not(P)
+    P->Q 	=   (not(P);Q)
+    P<->Q 	=   ((not(P);Q),(P; not(Q)))
+    P=Q 	=   ((not(P);Q),(P; not(Q)))
+    (P && Q) 	=   ((not(empty),P) & Q)               strong chop
+    <>(Q) 	=   (true & Q)
+    #(Q) 	=   not(true & not(Q))
+    [](Q) 	=   not(true & not(Q))
+    '[a]'(Q) 	=   not(true & not(Q) & true)
+    fin(Q) 	=   (true & (empty,Q))
+    halt(Q) 	=   [](empty=Q)
+    keep(Q) 	=   not(true & not((empty ; Q)))
+    more 	=   not(empty)
+    skip 	=   @(empty)
+    length(I)            expanded into series of strong next.
+    less(I)              expanded into series of weak next.
+    next(P) 	=   (empty; @(P))
+    gets(A,B)	=   keep(@A<->B)
+    stable(A) 	=   keep(@A<->A)
+
+    P proj Q  	=   Q is true using P as a clock period
+    *P          =   P&P&..&P.. chop infinite closure 
+
+    Q=>P 	=   exists(R,(Q = R,stable(R),fin(P = R)))
+    P<=Q 	=   Q=>P
+    +A  	=   (A & (empty;A) *)                  strong closure
+    while(Cond,Do)	=   ((Cond->Do) , (~Cond->empty)) * 
+    exists(P,Q) =   Exsistential Quantifier
+    all(P,Q)   	=   not(exists(P,not(Q)))
+
+    even(P) 	=   exists(Q,(Q, keep( @Q = ~Q),[](Q->P)))
+    evenp(P) 	=   ((P,skip) & skip;empty,P)* & (empty;skip)
+    phil(L,R)  	=   ([]((~L  =    ~R)) & @ (L, ~R,@ (L,R, @ (R,[]( ~L)))) )
+
+For user define predicate use define/2. Ex.
+	define(yeilds(A,B), not(not(A) & B)).
+
+
+1.1 Finte State Automaton support
+
+1.1.1 Output.
+
+This version supports Finite State Automaton I/O. The output of
+our verifier is finite automaton.
+
+?-tgen.
+
+generates automaton as Tokio Temporal Logic Programming Language.
+KISS2 format output is also supported, see 0.2.
+
+1.1.2 Input
+
+It is possible to use automaton as a part of ITL formula.
+Finite automaton is stored in Prolog clauses.
+
+st(s0) starts Finite State Automaton (FSA) from s0 states.
+This is a temporal logic term, so you can use this anywhere
+in ITL formula, for example: st(s0) & not(st(s0)), <>(st(s0)).
+FSA is defined as Prolog clauses in this way:
+
+st_variables([q],[s]).   
+%   st_varaibles(Input_variables,Output_variables)
+%   This is important only for KISS format generation
+	    
+st(s0,((not(a);not(b)),q),s0). 
+%    st(Current_State, Condition, Next_State)
+st(s1,(not(c),q),s1).
+st(s1, empty,empty).
+
+Conditions can be non-deterministic. Actually it allows
+arbitrary ITL formula, but if you use temporal condtions,
+it is not a state machine any more. The automaton is
+determinized during verfication, since generated state
+machine is determinisc. Be careful, the output can be very large.
+
+If a state machine contains no empty conditions, it is
+not satisfiable in ITL, because our ITL only have finite
+interval. But it may contains infinite clock periods. 
+
+2. Basic Algorithm of the Verifier
+
+This program uses classic tableau method. So hold your breath, it is
+exponential to the number of the variables in the formula and  also
+combinatorial to the nesting of temporal logic operator. I think it is
+possible to reduce complexity for the nesting, but not for the
+variables.
+
+Major contribution (I think) is in the classification of ITL formula,
+which is found in bdtstd.pl. I use binary decision tree (not diagram)
+standard form among subterms in original formula. Since this program
+always keep state machine deterministic, determinization of state
+machine is done by outer-most loop.
+
+The algorithm is quite simple. There are three stages. In the first
+stage, an ITL formula is decomposed into three  parts: empty, now and
+next. In the second stage, next parts is classifyed using subterm bdt
+and stored into database.  In the third stage, decomposition is
+repeatedly applied until no more new next parts are generated.
+
+Since ITL assumes any interval is finite, no eventuality checking is
+necessary.  Diagnosis algorithm is linear to the number of the state.
+
+3. Wish lists
+
+It is possible to reduce complexity in somehow.
+
+4. Brief description of this program.
+
+File exdev.pl contains main driver of tableau based interval temporal 
+logic verifier. A developer deve(X) does tableau development.
+
+deve(ITL) :-
+	init,!,
+	expand(ITL,ITL0),
+	itlstd(ITL0,StdNext),
+	check_state(StdNext,ITL0,_,S),!,
+	deve0((S,ITL0)).
+
+In init, formula databases are initialized. 
+Usually ITL formula contains several macro definitions, expand(X,Y) 
+expands these macros form X to Y.
+The formula is translated into standard form in itlstd(X,Y), where X is original
+formula and Y is binary decision tree standard form (not diagram).
+The formula databases are maintained in check_state(Stdoriginal,NewFlag,No).
+Std is the standard form. We need original formula here for display.
+Whether Std is already in database or not is shown in NewFlag and when
+database sequence number (i.e. state number) is returned in No.
+
+deve0((S,ITL)) :-
+        show_state(S,ITL),
+	setof(Next,itldecomp(ITL,Next,S),
+	    Nexts),!,
+	deve1(Nexts).
+deve0(_).
+
+We are now in deve0(X) predicates. After displaying current states, it
+gathers possible tableau expansion using setof predicates. Since not so
+many formula is generated from one state, setof is not a bottle neck of
+this program. The real bottle neck is total number of state/condition pair and
+it's database looking up.  Setof predicates returns only new candidates and 
+theses are stored in a list, in LIFO way.
+
+deve1([]).
+deve1([H|T]) :- deve0(H),deve1(T).
+
+Here is a repetition part. 
+
+itldecomp(ITL,(NextS,Next),From) :-
+	itl(ITL,Next,Cond),
+	%% showing
+	itlshow(Next,NextS,Cond,From).
+
+Actual tableau expansion is done by itl(ITL,Next,Cond). It generate
+Sumof( Cond -> @(Next) ), where Cond is exclusive, that is, it generates
+deterministic automaton. You can test itl predicates by hands, for example,
+?-itl(p & q,Next,Cond).
+
+itlshow(Next,S,Cond,From):-
+	itlstd(Next,StdNext),
+	check_state(StdNext,Next,New,S),
+	assertz(state(From,Cond,S)),
+	!,itlshow1(S,Cond,Next,New).
+
+In itlshow, standard form conversion and database checking is performed.
+Rest of parts are related to state database and displaying.
+
+That's all. There are more stories about itlstd and itl predicates, but it is
+better to look source code rather than vague English...
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/test	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,5 @@
+test of fax
+test of fax
+test of fax
+test of fax
+test of fax
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tk/basic	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,42 @@
+:- multifile tclause/2.
+
+% Basic Composite
+%    fact is not allowed. use a:-true form.
+%    commented out one is defined internally for efficiency
+% @(A)	:- more,next(A).
+% #(A)	:- A,next(#(A)).
+% [](A)	:- A,next([](A)).
+% (A && B)	:- (A,more) & B.
+% (A &@ B)	:- A & @B.
+% keep(A)	:- next(keep(A)),ifMore(A).
+% fin(A)	:- next(fin(A)),ifEmpty(A).
+% gets(A,B)	:- keep(@A = B).
+% (A<-B)	:- A=B,stable(C),fin(A=C).
+(A<-B)		:- C<--B,fin(A=C).
+skip		:- @empty.
+<>(A)		:- true & A.
+halt(A)		:- A,!,empty.
+halt(A)		:- @(halt(A)).
+stable(A)	:- gets(A,A).
+% Framing
+% A <= B		:- more, <>(A:=B).
+A // B		:- process(A),process(B).
+frame(A,B)	:- frame(A), B.
+frames([H|T],B)	:- frame(H),frames(T,B).
+frames([],B)	:- B.
+readonlys([H|T],B)	:- readonly(H),readonlys(T,B).
+readonlys([],B)	:- B.
+% A:=B		:- forall_parent(flag(A,assign)),@A=B.
+% readonly(A)	:- flag(A,stay).
+% Closures
+*(_)		:- empty.
+*(A)		:- more,A & *(A).
+% These are very slow in interpreter
+while(A,B)	:- (A,!,more,B) & while(A,B).
+while(_,_)	:- empty.
+(if A then B else _)	:- A,!,B.
+(if _ then _ else C)	:- C.
+(_ else _)	:- fail.
+(if A then B)	:- A,!,B.
+(if _ then _)	:- true.
+% end
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tk/bou.lite	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,14 @@
+%
+% specification for simple graphics interaction
+%
+
+specification((
++(((stop,keep((red,not(start)));start,keep((green,not(stop)))))),
+[]((red,not(green);not(red),green)),
+[]((green->move)),
+[]((red->not(move))),
+halt(quit)
+)).
+
+st_variables([stop,start,quit],[red,green,move]).
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tk/bou.tcl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,794 @@
+#!/usr/local/bin/wish -f
+# Program: bou
+# Tcl version: 7.3 (Tcl/Tk/XF)
+# Tk version: 3.6
+# XF version: 2.2
+#
+
+# module inclusion
+global env
+global xfLoadPath
+global xfLoadInfo
+set xfLoadInfo 0
+if {[info exists env(XF_LOAD_PATH)]} {
+  if {[string first $env(XF_LOAD_PATH) /usr/local/lib/] == -1} {
+    set xfLoadPath $env(XF_LOAD_PATH):/usr/local/lib/
+  } {
+    set xfLoadPath /usr/local/lib/
+  }
+} {
+  set xfLoadPath /usr/local/lib/
+}
+
+global argc
+global argv
+global tkVersion
+set tmpArgv ""
+for {set counter 0} {$counter < $argc} {incr counter 1} {
+  case [string tolower [lindex $argv $counter]] in {
+    {-xfloadpath} {
+      incr counter 1
+      set xfLoadPath "[lindex $argv $counter]:$xfLoadPath"
+    }
+    {-xfstartup} {
+      incr counter 1
+      source [lindex $argv $counter]
+    }
+    {-xfbindfile} {
+      incr counter 1
+      set env(XF_BIND_FILE) "[lindex $argv $counter]"
+    }
+    {-xfcolorfile} {
+      incr counter 1
+      set env(XF_COLOR_FILE) "[lindex $argv $counter]"
+    }
+    {-xfcursorfile} {
+      incr counter 1
+      set env(XF_CURSOR_FILE) "[lindex $argv $counter]"
+    }
+    {-xffontfile} {
+      incr counter 1
+      set env(XF_FONT_FILE) "[lindex $argv $counter]"
+    }
+    {-xfmodelmono} {
+      if {$tkVersion >= 3.0} {
+        tk colormodel . monochrome
+      }
+    }
+    {-xfmodelcolor} {
+      if {$tkVersion >= 3.0} {
+        tk colormodel . color
+      }
+    }
+    {-xfloading} {
+      set xfLoadInfo 1
+    }
+    {-xfnoloading} {
+      set xfLoadInfo 0
+    }
+    {default} {
+      lappend tmpArgv [lindex $argv $counter]
+    }
+  }
+}
+set argv $tmpArgv
+set argc [llength $tmpArgv]
+unset counter
+unset tmpArgv
+
+
+# procedure to show window .toy
+proc ShowWindow.toy {args} {# xf ignore me 7
+
+  # build widget .toy
+  if {"[info procs XFEdit]" != ""} {
+    catch "XFDestroy .toy"
+  } {
+    catch "destroy .toy"
+  }
+  toplevel .toy  \
+    -background {Cornsilk2} \
+    -relief {raised}
+
+  # Window manager configurations
+  global tkVersion
+  wm positionfrom .toy program
+  wm sizefrom .toy program
+  wm maxsize .toy 1000 1000
+  wm title .toy {Toy}
+
+
+  # build widget .toy.frame1
+  frame .toy.frame1 \
+    -background {Cornsilk2} \
+    -borderwidth {2} \
+    -height {293} \
+    -relief {raised} \
+    -width {141}
+
+  # build widget .toy.frame1.label2
+  label .toy.frame1.label2 \
+    -background {Cornsilk2} \
+    -font {8x16} \
+    -relief {raised} \
+    -text {Green}
+
+  # build widget .toy.frame1.label3
+  label .toy.frame1.label3 \
+    -background {Cornsilk2} \
+    -font {8x16} \
+    -relief {raised} \
+    -text {Red}
+
+  # build widget .toy.frame1.button4
+  button .toy.frame1.button4 \
+    -activebackground {#eed5b7} \
+    -background {Cornsilk2} \
+    -command {event quit} \
+    -disabledforeground {#b0b0b0} \
+    -font {8x16} \
+    -relief {flat} \
+    -text {   Quit   }
+
+  # build widget .toy.frame1.button5
+  button .toy.frame1.button5 \
+    -activebackground {#eed5b7} \
+    -background {Cornsilk2} \
+    -command {event stop} \
+    -disabledforeground {#b0b0b0} \
+    -font {8x16} \
+    -text {Stop}
+
+  # build widget .toy.frame1.button6
+  button .toy.frame1.button6 \
+    -activebackground {#eed5b7} \
+    -background {Cornsilk2} \
+    -command {event start} \
+    -disabledforeground {#b0b0b0} \
+    -font {8x16} \
+    -text {Run}
+
+  # pack widget .toy.frame1
+  pack append .toy.frame1 \
+    .toy.frame1.label2 {top frame center fillx} \
+    .toy.frame1.label3 {top frame center fillx} \
+    .toy.frame1.button4 {bottom frame center fillx} \
+    .toy.frame1.button5 {bottom frame center fillx} \
+    .toy.frame1.button6 {bottom frame center fillx}
+
+  # build widget .toy.canvas0
+  canvas .toy.canvas0 \
+    -background {Cornsilk2} \
+    -height {207} \
+    -insertofftime {600} \
+    -relief {raised} \
+    -selectbackground {#b2dfee} \
+    -selectborderwidth {1} \
+    -selectforeground {CornSilk2} \
+    -width {295}
+
+  # pack widget .toy
+  pack append .toy \
+    .toy.frame1 {right frame e filly} \
+    .toy.canvas0 {left frame center expand fill}
+
+  # build canvas items .toy.canvas0
+
+
+
+  if {"[info procs XFEdit]" != ""} {
+    catch "XFMiscBindWidgetTree .toy"
+    after 2 "catch {XFEditSetShowWindows}"
+  }
+}
+
+proc DestroyWindow.toy {} {# xf ignore me 7
+  if {"[info procs XFEdit]" != ""} {
+    if {"[info commands .toy]" != ""} {
+      global xfShowWindow.toy
+      set xfShowWindow.toy 0
+      XFEditSetPath .
+      after 2 "XFSaveAsProc .toy; XFEditSetShowWindows"
+    }
+  } {
+    catch "destroy .toy"
+    update
+  }
+}
+
+
+# procedure to show window .
+proc ShowWindow. {args} {# xf ignore me 7
+
+  # Window manager configurations
+  global tkVersion
+  wm positionfrom . user
+  wm sizefrom . ""
+  wm maxsize . 1280 1024
+  wm title . {xf}
+
+
+  if {"[info procs XFEdit]" != ""} {
+    catch "XFMiscBindWidgetTree ."
+    after 2 "catch {XFEditSetShowWindows}"
+  }
+}
+
+
+# User defined procedures
+
+
+# Procedure: event
+proc event { args} {
+	prolog "tokio:tokio_event($args)" 
+# tokio
+}
+
+
+# Internal procedures
+
+
+# Procedure: Alias
+if {"[info procs Alias]" == ""} {
+proc Alias { args} {
+# xf ignore me 7
+##########
+# Procedure: Alias
+# Description: establish an alias for a procedure
+# Arguments: args - no argument means that a list of all aliases
+#                   is returned. Otherwise the first parameter is
+#                   the alias name, and the second parameter is
+#                   the procedure that is aliased.
+# Returns: nothing, the command that is bound to the alias or a
+#          list of all aliases - command pairs. 
+# Sideeffects: internalAliasList is updated, and the alias
+#              proc is inserted
+##########
+  global internalAliasList
+
+  if {[llength $args] == 0} {
+    return $internalAliasList
+  } {
+    if {[llength $args] == 1} {
+      set xfTmpIndex [lsearch $internalAliasList "[lindex $args 0] *"]
+      if {$xfTmpIndex != -1} {
+        return [lindex [lindex $internalAliasList $xfTmpIndex] 1]
+      }
+    } {
+      if {[llength $args] == 2} {
+        eval "proc [lindex $args 0] {args} {#xf ignore me 4
+return \[eval \"[lindex $args 1] \$args\"\]}"
+        set xfTmpIndex [lsearch $internalAliasList "[lindex $args 0] *"]
+        if {$xfTmpIndex != -1} {
+          set internalAliasList [lreplace $internalAliasList $xfTmpIndex $xfTmpIndex "[lindex $args 0] [lindex $args 1]"]
+        } {
+          lappend internalAliasList "[lindex $args 0] [lindex $args 1]"
+        }
+      } {
+        error "Alias: wrong number or args: $args"
+      }
+    }
+  }
+}
+}
+
+
+# Procedure: GetSelection
+if {"[info procs GetSelection]" == ""} {
+proc GetSelection {} {
+# xf ignore me 7
+##########
+# Procedure: GetSelection
+# Description: get current selection
+# Arguments: none
+# Returns: none
+# Sideeffects: none
+##########
+
+  # the save way
+  set xfSelection ""
+  catch "selection get" xfSelection
+  if {"$xfSelection" == "selection doesn't exist or form \"STRING\" not defined"} {
+    return ""
+  } {
+    return $xfSelection
+  }
+}
+}
+
+
+# Procedure: MenuPopupAdd
+if {"[info procs MenuPopupAdd]" == ""} {
+proc MenuPopupAdd { xfW xfButton xfMenu {xfModifier ""} {xfCanvasTag ""}} {
+# xf ignore me 7
+# the popup menu handling is from (I already gave up with popup handling :-):
+#
+# Copyright 1991,1992 by James Noble.
+# Everyone is granted permission to copy, modify and redistribute.
+# This notice must be preserved on all copies or derivates.
+#
+##########
+# Procedure: MenuPopupAdd
+# Description: attach a popup menu to widget
+# Arguments: xfW - the widget
+#            xfButton - the button we use
+#            xfMenu - the menu to attach
+#            {xfModifier} - a optional modifier
+#            {xfCanvasTag} - a canvas tagOrId
+# Returns: none
+# Sideeffects: none
+##########
+  global tk_popupPriv
+
+  set tk_popupPriv($xfMenu,focus) ""
+  set tk_popupPriv($xfMenu,grab) ""
+  if {"$xfModifier" != ""} {
+    set press "$xfModifier-"
+    set motion "$xfModifier-"
+    set release "Any-"
+  } {
+    set press ""
+    set motion ""
+    set release ""
+  }
+
+  bind $xfMenu "<${motion}B${xfButton}-Motion>"  "MenuPopupMotion $xfMenu %W %X %Y"
+  bind $xfMenu "<${release}ButtonRelease-${xfButton}>"  "MenuPopupRelease $xfMenu %W"
+  if {"$xfCanvasTag" == ""} {
+    bind $xfW "<${press}ButtonPress-${xfButton}>"  "MenuPopupPost $xfMenu %X %Y"
+    bind $xfW "<${release}ButtonRelease-${xfButton}>"  "MenuPopupRelease $xfMenu %W"
+  } {
+    $xfW bind $xfCanvasTag "<${press}ButtonPress-${xfButton}>"  "MenuPopupPost $xfMenu %X %Y"
+    $xfW bind $xfCanvasTag "<${release}ButtonRelease-${xfButton}>"  "MenuPopupRelease $xfMenu %W"
+  }
+}
+}
+
+
+# Procedure: MenuPopupMotion
+if {"[info procs MenuPopupMotion]" == ""} {
+proc MenuPopupMotion { xfMenu xfW xfX xfY} {
+# xf ignore me 7
+##########
+# Procedure: MenuPopupMotion
+# Description: handle the popup menu motion
+# Arguments: xfMenu - the topmost menu
+#            xfW - the menu
+#            xfX - the root x coordinate
+#            xfY - the root x coordinate
+# Returns: none
+# Sideeffects: none
+##########
+  global tk_popupPriv
+
+  if {"[info commands $xfW]" != "" && [winfo ismapped $xfW] &&
+      "[winfo class $xfW]" == "Menu" &&
+      [info exists tk_popupPriv($xfMenu,focus)] &&
+      "$tk_popupPriv($xfMenu,focus)" != "" &&
+      [info exists tk_popupPriv($xfMenu,grab)] &&
+      "$tk_popupPriv($xfMenu,grab)" != ""} {
+    set xfPopMinX [winfo rootx $xfW]
+    set xfPopMaxX [expr $xfPopMinX+[winfo width $xfW]]
+    if {$xfX >= $xfPopMinX && $xfX <= $xfPopMaxX} {
+      $xfW activate @[expr $xfY-[winfo rooty $xfW]]
+      if {![catch "$xfW entryconfig @[expr $xfY-[winfo rooty $xfW]] -menu" result]} {
+        if {"[lindex $result 4]" != ""} {
+          foreach binding [bind $xfMenu] {
+            bind [lindex $result 4] $binding [bind $xfMenu $binding]
+          }
+        }
+      }
+    } {
+      $xfW activate none
+    }
+  }
+}
+}
+
+
+# Procedure: MenuPopupPost
+if {"[info procs MenuPopupPost]" == ""} {
+proc MenuPopupPost { xfMenu xfX xfY} {
+# xf ignore me 7
+##########
+# Procedure: MenuPopupPost
+# Description: post the popup menu
+# Arguments: xfMenu - the menu
+#            xfX - the root x coordinate
+#            xfY - the root x coordinate
+# Returns: none
+# Sideeffects: none
+##########
+  global tk_popupPriv
+
+  if {"[info commands $xfMenu]" != ""} {
+    if {![info exists tk_popupPriv($xfMenu,focus)]} {
+      set tk_popupPriv($xfMenu,focus) [focus]
+    } {
+      if {"$tk_popupPriv($xfMenu,focus)" == ""} {
+        set tk_popupPriv($xfMenu,focus) [focus]
+      }
+    }
+    set tk_popupPriv($xfMenu,grab) $xfMenu
+
+    catch "$xfMenu activate none"
+    catch "$xfMenu post $xfX $xfY"
+    catch "focus $xfMenu"
+    catch "grab -global $xfMenu"
+  }
+}
+}
+
+
+# Procedure: MenuPopupRelease
+if {"[info procs MenuPopupRelease]" == ""} {
+proc MenuPopupRelease { xfMenu xfW} {
+# xf ignore me 7
+##########
+# Procedure: MenuPopupRelease
+# Description: remove the popup menu
+# Arguments: xfMenu - the topmost menu widget
+#            xfW - the menu widget
+# Returns: none
+# Sideeffects: none
+##########
+  global tk_popupPriv
+  global tkVersion
+
+  if {"[info commands $xfW]" != "" && [winfo ismapped $xfW] &&
+      "[winfo class $xfW]" == "Menu" &&
+      [info exists tk_popupPriv($xfMenu,focus)] &&
+      "$tk_popupPriv($xfMenu,focus)" != "" &&
+      [info exists tk_popupPriv($xfMenu,grab)] &&
+      "$tk_popupPriv($xfMenu,grab)" != ""} {
+    if {$tkVersion >= 3.0} {
+      catch "grab release $tk_popupPriv($xfMenu,grab)"
+    } {
+      catch "grab none"
+    }
+    catch "focus $tk_popupPriv($xfMenu,focus)"
+    set tk_popupPriv($xfMenu,focus) ""
+    set tk_popupPriv($xfMenu,grab) ""
+    if {"[$xfW index active]" != "none"} {
+      $xfW invoke active; catch "$xfMenu unpost"
+    }
+  }
+  catch "$xfMenu unpost"
+}
+}
+
+
+# Procedure: NoFunction
+if {"[info procs NoFunction]" == ""} {
+proc NoFunction { args} {
+# xf ignore me 7
+##########
+# Procedure: NoFunction
+# Description: do nothing (especially with scales and scrollbars)
+# Arguments: args - a number of ignored parameters
+# Returns: none
+# Sideeffects: none
+##########
+}
+}
+
+
+# Procedure: SN
+if {"[info procs SN]" == ""} {
+proc SN { {xfName ""}} {
+# xf ignore me 7
+##########
+# Procedure: SN
+# Description: map a symbolic name to the widget path
+# Arguments: xfName
+# Returns: the symbolic name
+# Sideeffects: none
+##########
+
+  SymbolicName $xfName
+}
+}
+
+
+# Procedure: SymbolicName
+if {"[info procs SymbolicName]" == ""} {
+proc SymbolicName { {xfName ""}} {
+# xf ignore me 7
+##########
+# Procedure: SymbolicName
+# Description: map a symbolic name to the widget path
+# Arguments: xfName
+# Returns: the symbolic name
+# Sideeffects: none
+##########
+
+  global symbolicName
+
+  if {"$xfName" != ""} {
+    set xfArrayName ""
+    append xfArrayName symbolicName ( $xfName )
+    if {![catch "set \"$xfArrayName\"" xfValue]} {
+      return $xfValue
+    } {
+      if {"[info commands XFProcError]" != ""} {
+        XFProcError "Unknown symbolic name:\n$xfName"
+      } {
+        puts stderr "XF error: unknown symbolic name:\n$xfName"
+      }
+    }
+  }
+  return ""
+}
+}
+
+
+# Procedure: Unalias
+if {"[info procs Unalias]" == ""} {
+proc Unalias { aliasName} {
+# xf ignore me 7
+##########
+# Procedure: Unalias
+# Description: remove an alias for a procedure
+# Arguments: aliasName - the alias name to remove
+# Returns: none
+# Sideeffects: internalAliasList is updated, and the alias
+#              proc is removed
+##########
+  global internalAliasList
+
+  set xfIndex [lsearch $internalAliasList "$aliasName *"]
+  if {$xfIndex != -1} {
+    rename $aliasName ""
+    set internalAliasList [lreplace $internalAliasList $xfIndex $xfIndex]
+  }
+}
+}
+
+
+
+# application parsing procedure
+proc XFLocalParseAppDefs {xfAppDefFile} {
+  global xfAppDefaults
+
+  # basically from: Michael Moore
+  if {[file exists $xfAppDefFile] &&
+      [file readable $xfAppDefFile] &&
+      "[file type $xfAppDefFile]" == "link"} {
+    catch "file type $xfAppDefFile" xfType
+    while {"$xfType" == "link"} {
+      if {[catch "file readlink $xfAppDefFile" xfAppDefFile]} {
+        return
+      }
+      catch "file type $xfAppDefFile" xfType
+    }
+  }
+  if {!("$xfAppDefFile" != "" &&
+        [file exists $xfAppDefFile] &&
+        [file readable $xfAppDefFile] &&
+        "[file type $xfAppDefFile]" == "file")} {
+    return
+  }
+  if {![catch "open $xfAppDefFile r" xfResult]} {
+    set xfAppFileContents [read $xfResult]
+    close $xfResult
+    foreach line [split $xfAppFileContents "\n"] {
+      # backup indicates how far to backup.  It applies to the
+      # situation where a resource name ends in . and when it
+      # ends in *.  In the second case you want to keep the *
+      # in the widget name for pattern matching, but you want
+      # to get rid of the . if it is the end of the name. 
+      set backup -2  
+      set line [string trim $line]
+      if {[string index $line 0] == "#" || "$line" == ""} {
+        # skip comments and empty lines
+        continue
+      }
+      set list [split $line ":"]
+      set resource [string trim [lindex $list 0]]
+      set i [string last "." $resource]
+      set j [string last "*" $resource]
+      if {$j > $i} { 
+        set i $j
+        set backup -1
+      }
+      incr i
+      set name [string range $resource $i end]
+      incr i $backup
+      set widname [string range $resource 0 $i]
+      set value [string trim [lindex $list 1]]
+      if {"$widname" != "" && "$widname" != "*"} {
+        # insert the widget and resourcename to the application
+        # defaults list.
+        if {![info exists xfAppDefaults]} {
+          set xfAppDefaults ""
+        }
+        lappend xfAppDefaults [list $widname [string tolower $name] $value]
+      }
+    }
+  }
+}
+
+# application loading procedure
+proc XFLocalLoadAppDefs {{xfClasses ""} {xfPriority "startupFile"} {xfAppDefFile ""}} {
+  global env
+
+  if {"$xfAppDefFile" == ""} {
+    set xfFileList ""
+    if {[info exists env(XUSERFILESEARCHPATH)]} {
+      append xfFileList [split $env(XUSERFILESEARCHPATH) :]
+    }
+    if {[info exists env(XAPPLRESDIR)]} {
+      append xfFileList [split $env(XAPPLRESDIR) :]
+    }
+    if {[info exists env(XFILESEARCHPATH)]} {
+      append xfFileList [split $env(XFILESEARCHPATH) :]
+    }
+    append xfFileList " /usr/lib/X11/app-defaults"
+    append xfFileList " /usr/X11/lib/X11/app-defaults"
+
+    foreach xfCounter1 $xfClasses {
+      foreach xfCounter2 $xfFileList {
+        set xfPathName $xfCounter2
+        if {[regsub -all "%N" "$xfPathName" "$xfCounter1" xfResult]} {
+          set xfPathName $xfResult
+        }
+        if {[regsub -all "%T" "$xfPathName" "app-defaults" xfResult]} {
+          set xfPathName $xfResult
+        }
+        if {[regsub -all "%S" "$xfPathName" "" xfResult]} {
+          set xfPathName $xfResult
+        }
+        if {[regsub -all "%C" "$xfPathName" "" xfResult]} {
+          set xfPathName $xfResult
+        }
+        if {[file exists $xfPathName] &&
+            [file readable $xfPathName] &&
+            ("[file type $xfPathName]" == "file" ||
+             "[file type $xfPathName]" == "link")} {
+          catch "option readfile $xfPathName $xfPriority"
+          if {"[info commands XFParseAppDefs]" != ""} {
+            XFParseAppDefs $xfPathName
+          } {
+            if {"[info commands XFLocalParseAppDefs]" != ""} {
+              XFLocalParseAppDefs $xfPathName
+            }
+          }
+        } {
+          if {[file exists $xfCounter2/$xfCounter1] &&
+              [file readable $xfCounter2/$xfCounter1] &&
+              ("[file type $xfCounter2/$xfCounter1]" == "file" ||
+               "[file type $xfCounter2/$xfCounter1]" == "link")} {
+            catch "option readfile $xfCounter2/$xfCounter1 $xfPriority"
+            if {"[info commands XFParseAppDefs]" != ""} {
+              XFParseAppDefs $xfCounter2/$xfCounter1
+            } {
+              if {"[info commands XFLocalParseAppDefs]" != ""} {
+                XFLocalParseAppDefs $xfCounter2/$xfCounter1
+              }
+            }
+          }
+        }
+      }
+    }
+  } {
+    # load a specific application defaults file
+    if {[file exists $xfAppDefFile] &&
+        [file readable $xfAppDefFile] &&
+        ("[file type $xfAppDefFile]" == "file" ||
+         "[file type $xfAppDefFile]" == "link")} {
+      catch "option readfile $xfAppDefFile $xfPriority"
+      if {"[info commands XFParseAppDefs]" != ""} {
+        XFParseAppDefs $xfAppDefFile
+      } {
+        if {"[info commands XFLocalParseAppDefs]" != ""} {
+          XFLocalParseAppDefs $xfAppDefFile
+        }
+      }
+    }
+  }
+}
+
+# application setting procedure
+proc XFLocalSetAppDefs {{xfWidgetPath "."}} {
+  global xfAppDefaults
+
+  if {![info exists xfAppDefaults]} {
+    return
+  }
+  foreach xfCounter $xfAppDefaults {
+    if {"$xfCounter" == ""} {
+      break
+    }
+    set widname [lindex $xfCounter 0]
+    if {[string match $widname ${xfWidgetPath}] ||
+        [string match "${xfWidgetPath}*" $widname]} {
+      set name [string tolower [lindex $xfCounter 1]]
+      set value [lindex $xfCounter 2]
+      # Now lets see how many tcl commands match the name
+      # pattern specified.
+      set widlist [info command $widname]
+      if {"$widlist" != ""} {
+        foreach widget $widlist {
+          # make sure this command is a widget.
+          if {![catch "winfo id $widget"] &&
+              [string match "${xfWidgetPath}*" $widget]} {
+            catch "$widget configure -$name $value" 
+          }
+        }
+      }
+    }
+  }
+}
+
+
+# prepare auto loading
+global auto_path
+global tk_library
+global xfLoadPath
+foreach xfElement [eval list [split $xfLoadPath :] $auto_path] {
+  if {[file exists $xfElement/tclIndex]} {
+    lappend auto_path $xfElement
+  }
+}
+catch "unset auto_index"
+
+catch "unset auto_oldpath"
+
+catch "unset auto_execs"
+
+
+# initialize global variables
+proc InitGlobals {} {
+  global {now}
+  set {now} {}
+
+  # please don't modify the following
+  # variables. They are needed by xf.
+  global {autoLoadList}
+  set {autoLoadList(bou.tcl)} {0}
+  set {autoLoadList(main.tcl)} {0}
+  global {internalAliasList}
+  set {internalAliasList} {}
+  global {moduleList}
+  set {moduleList(bou.tcl)} {}
+  global {preloadList}
+  set {preloadList(xfInternal)} {}
+  global {symbolicName}
+  set {symbolicName(c)} {.canvas0}
+  set {symbolicName(green)} {.frame1.label2}
+  set {symbolicName(quit)} {.frame1.button4}
+  set {symbolicName(red)} {.frame1.label3}
+  set {symbolicName(root)} {.}
+  set {symbolicName(run)} {.frame1.button6}
+  set {symbolicName(stop)} {.frame1.button5}
+  global {xfWmSetPosition}
+  set {xfWmSetPosition} {}
+  global {xfWmSetSize}
+  set {xfWmSetSize} {}
+  global {xfAppDefToplevels}
+  set {xfAppDefToplevels} {}
+}
+
+# initialize global variables
+InitGlobals
+
+# display/remove toplevel windows.
+ShowWindow.
+
+global xfShowWindow.toy
+set xfShowWindow.toy 1
+ShowWindow.toy
+
+# load default bindings.
+if {[info exists env(XF_BIND_FILE)] &&
+    "[info procs XFShowHelp]" == ""} {
+  source $env(XF_BIND_FILE)
+}
+
+# parse and apply application defaults.
+XFLocalLoadAppDefs Bou
+XFLocalSetAppDefs
+
+# eof
+#
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tk/bou.tokio	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,139 @@
+%% ------------------------------------------------- BOUNCE
+
+:-use_module(library(tcltk)).
+
+toy :-  static([green, red, move, stop, start,quit]),
+	tk([name(toy)]),
+	*move:=0,*quit:=0,*stop:=0,*start:=0,*red:=1,*green:=0,
+	toy_init,
+	fin(tcl_command('destroy .')),
+	keep(tcl_command(update)).
+
+toy0 :-  static([green, red, move, stop, start,quit]),
+	% tk([name(toy)]),
+	*move:=0,*quit:=0,*stop:=0,*start:=0,*red:=1,*green:=0,
+	toy_init,
+	fin(tcl_command('destroy .')),
+	keep(tcl_command(update)).
+
+toy_init :-
+	[](check_event),		% Synchronize event
+        bounce_init([W|T],R,G),
+	@toy1([W|T],R,G).
+
+toy1(W,R,G) :- 
+	s1,						% automaton
+	[]((button_red(R),button_green(G),bounce(W))).  % output
+
+% ?- compile(['../tableau/gi.out']).
+
+% tokio / tcl event link
+start :- *start := 1,@((*start:=0;true)).
+stop :-  *stop  := 1,@((*stop:=0;true)).
+quit :-  *quit := 1.
+
+button_red(Out) :-
+        *red =0, out(Out,'""',red).
+button_red(Out) :-
+        *red =1, out(Out,'Red',red).
+button_green(Out) :-
+        *green =0, out(Out,'""',green).
+button_green(Out) :-
+        *green =1, out(Out,'Green',green).
+
+% size(400,400,10,fixed) :- true.
+size(200,200,5,'7x14') :- true.
+
+bounce_init( [Window0, View0, Circ0, Xout0, X, Yout0, 
+        Y, Xd, Yd, Ydd, Xlim, Ylim],Xout0,Yout0) :-
+%       Tcl/Tk link part
+
+	Window = '.toy',View = '$w.canvas0',
+	Xout = '$w.frame1.label3',  	% red
+	Yout = '$w.frame1.label2',  	% green
+%	Start = '$w.frame1.button6', 	% run
+%	Stop = '$w.frame1.button5',  	% stop
+%	Quit = '$w.frame1.button4',  	% quit
+
+        size(Hight,Width,R,_Font),
+	H0 = Hight-2, W0 = Width-2,
+	H1 = Hight/2, W1 = Width/2,
+	view(Hight,Width,Window,View),
+%	Box <= hbox([vbox([Xout,Yout,space,Start,Stop,Quit]),View]),
+	rectangle(0,0,0,H0,W0,View),
+        Circ = 'circle',circle(1,Circ,H1,W1,R,View),	
+	Window0<--Window, View0<--View, Circ0<--Circ, 
+	Xout0<--Xout,  Yout0<--Yout,
+	Ylim = Hight-10, Xlim = Width-10, Ydd = -R/2,
+	#((@Ylim=Ylim,@Xlim=Xlim,@Ydd=Ydd)),
+	@X = H1, @Y = W1, @Xd = R/2, @Yd = R*2.
+bounce([_, View, Obj, _Xout, X, _Yout, Y, Xd, Yd, Ydd, Xlim, _]) :- 
+	*move = 1,*quit = 0,
+	Y1 is Y+Yd,
+        moveto(View,Obj,X,Y),      
+	calc_xd(X, Xd, Xd1, Xlim),
+	calc_yd(Y, Yd, Ydt, Y1, Yt1),
+	@X = X+Xd,@Xd = Xd1, @Y = Yt1, @Yd = Ydt+Ydd.
+bounce([_, _, _, _, X, _, Y, Xd, Yd, _, _, _]) :- 
+	*move = 0,*quit = 0,
+	@X = X,@Xd = Xd, @Y = Y, @Yd = Yd.
+bounce([_W|_]) :-
+	*quit = 1.
+
+calc_xd(X, Xd, Xd1, _) :- X < 10,  Xd1 is abs(Xd).
+calc_xd(X, Xd, Xd1, Xlim) :- X > Xlim,  Xd1 is -abs(Xd).
+calc_xd(_, Xd, Xd, _):-true.
+
+calc_yd(Y, Yd, Ydt, _, Y0) :-
+	Y < 10,  Yd > 0 , Ydt = Yd,Y0 = 10.
+calc_yd(Y, Yd, Ydt, _, Y0) :-
+	Y < 10, Ydt = 9*(-Yd)/10,Y0 = 10.
+calc_yd(_, Yd, Yd, Y1, Y1):-true.
+
+% Tcl/Tk stuff
+
+out(Out,Data,Color) :-
+	tcl_command([Out,' configure -text ',Data,' -foreground ',Color]).
+
+view(_H,_W,Window,_View) :- 
+	tcl_command(['set w ',Window]),
+	tcl_command('source bou.tcl').
+
+rectangle(1,X,Y,X2,Y2,View) :-!,
+        tcl_command([View,' create rectangle ',
+                  X,' ',Y,' ', X2,' ',Y2,' ',
+                 '-stipple gray50 -fill black'
+        ]).
+
+rectangle(0,X,Y,X2,Y2,View) :- 
+        tcl_command([View,' create rectangle ',
+                  X,' ',Y,' ', X2,' ',Y2
+        ]).
+
+circle(1,C,X,Y,R,View) :-!, 
+	X0 is X-R, Y0 is Y-R, X1 is X+R, Y1 is Y+R,
+        tcl_command([View,' create oval ',
+                  X0,' ',Y0,' ', X1,' ',Y1,' -tag ',C,
+                 ' -stipple gray50 -fill black'
+        ]).
+
+circle(0,C,X,Y,R,View) :-!,
+	X0 is X-R, Y0 is Y-R, X1 is X+R, Y1 is Y+R,
+        tcl_command([View,' create oval ',
+                  X0,' ',Y0,' ', X1,' ',Y1,' -tag ',C,
+                 ' -stipple gray50 -fill black'
+        ]).
+
+move(View,Obj,X,Y) :- prolog((
+        tcl_command([View,' move ',Obj,' ',X,' ',Y])
+        )).
+
+moveto(View,Obj,X,Y) :- 
+        size(H,_,R,_),
+	X0 is X-R, Y0 is H-(Y-R), X1 is X+R, Y1 is H-(Y+R),
+	tcl_command([View,' coords ',Obj,' ',X0,' ',Y0,' ', X1,' ',Y1]).
+
+tk(X) :- prolog(tk_new(X,I)),*int:=I.
+tcl_command(X) :- 
+	% write(X),nl,
+	I= *int,prolog(tcl_eval(I,X,_)).
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tk/demo.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,11 @@
+% :-ensure_loaded('../../Lite/lite').
+% :-ensure_loaded('../../Tokio/initm').
+% :-module(lite).
+
+% :-ensure_loaded('../../Tokio/initm').
+:-use_module('../lite').
+:-ensure_loaded(lite:disp).
+
+% display :- lite:display.
+
+% :-com([bou,gi],'tmp.out').
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/tk/disp.pl	Thu Jan 18 23:27:24 2001 +0900
@@ -0,0 +1,408 @@
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+%%
+%% LITE Tcl/Tk interface
+%%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+% :- ensure_loaded('../Lite/lite').
+:- ensure_loaded('../lite').
+
+:- module(lite).
+
+% :- use_module(library(tk)).
+:- use_module(library(tcltk)).
+:- verbose(off).
+
+:- dynamic r_event/2.
+
+:- abolish(show_state,2).
+% Next command keep check event during verification
+show_state(S,ITL) :-!,
+%        (tcl_eval(I,update,_);true),!,
+        (tk_do_one_event;true),
+        nl,write('state('),write(S),  % (
+        (verbose,write(' , '), write(ITL),write(')'),nl;write(')')),!.
+
+event(verbose,'1') :- verbose(on).
+event(verbose,'0') :- verbose(off).
+event(X,Y) :- assertz(r_event(X,Y)).   % ,write((X,Y)),nl.
+event(X) :-   assertz(r_event(X,[])).  % ,write((X)),nl.
+
+next(X,Y) :- r_event(_,_),retract(r_event(X,Y)),!.
+next(X,Y) :- tk_do_one_event,!,
+	next(X,Y).
+next(X,Y) :- next(X,Y).
+
+display :-
+	init_display(I),!,
+	event_loop(run,I).
+
+init_display(I) :-
+	(retract(r_event(_,_)),fail;true),
+%	tk_init('lite',[]),
+	tk_new([],I),
+%	tcl_eval('source disp.tcl'),
+	tcl_eval(I,'source xf-disp',_),
+        all_disable(I).
+canvas_origin(20,20).
+
+event_loop(quit,_I):-!.
+event_loop(_,I) :-
+	next(X,Y),execute(X,Y,I),!,event_loop(X,I).
+
+execute(verify,X,I) :- !,
+	verify(X,I).
+
+% !,X=1 -> verbose(on); verbose(off). causes error
+execute(verbose,X,_) :- X='1' -> verbose(on); verbose(off).
+execute(map,X,I) :- !,name(X,L),name(X1,L),view_state(a,X1,I).
+execute(execute,_,I) :- !,do_execute(I),!.
+execute(generate,_,_) :- !,
+	generate.
+execute(counter,_,I) :- !,do_diagnosis(I),!.
+execute(quit,_,I) :- !,
+	tcl_eval(I,'destroy .',_),
+	tcl_delete(I).
+%	tcl_eval(I,'destroy .',_).
+execute(prolog_call,X,_) :- !,prolog_call(X).
+execute(tokio_call,X,_) :- !,tokio_call(X).
+execute(X,_,_) :- !,write(event(X)),nl,ttyflush.
+
+generate :-
+	TOKIO = 'tmp.tokio',
+	tell(TOKIO),tgen,told,
+        user:com(TOKIO,'tmp.out').
+gen(X) :- consult(X),specification(Y),ex(Y),flush_output,generate.
+gen(X) :- 
+	name(X,XL),append(XL,".lite",YL),name(X1,YL),
+	consult(X1),specification(Y),ex(Y),flush_output,generate.
+
+verify(X,I) :-
+        all_disable(I),
+	abolish(st,3),abolish(specification,1),abolish(st_variables,2),
+	t2string(X,X0),s2terms(X0,X1),command(X1,X2,X3),
+	display_contents(X3,I),
+	ex(X2),!,
+	ttyflush, display_statistics(I),
+        all_enable(I).
+verify(_,I) :-
+        all_disable(I).
+display_contents(X,I) :-
+	ttyflush,t2strings(X,XS0),easy_pp(XS0,XS),
+	tcl_eval(I,'$symbolicName(entry) delete 0.0 end',_),
+	tcl_eval(I,['$symbolicName(entry) insert 0.0 {',chars(XS),'}'],_),
+        display_update(I).
+
+all_disable(I) :-
+	tcl_eval(I,'$symbolicName(map) configure -state disabled',_),
+	tcl_eval(I,'$symbolicName(execute) configure -state disabled',_),
+	tcl_eval(I,'$symbolicName(diag) configure -state disabled',_),
+	display_update(I).
+all_enable(I) :-
+	tcl_eval(I,'$symbolicName(map) configure -state normal',_),
+	tcl_eval(I,'$symbolicName(execute) configure -state normal',_),
+	tcl_eval(I,'$symbolicName(diag) configure -state normal',_),
+	display_update(I).
+
+% Backtrack Control of example/counter example
+
+do_execute(I) :- display_exe('.',I),next(X,Y),do_execute(X,Y,I),!.
+do_execute(_I).
+
+do_execute(execute,_,_) :-!,
+	fail.
+do_execute(X,Y,I) :- execute(X,Y,I),!.
+
+do_diagnosis(I) :- display_diag(',',I),next(X,Y),do_diagnosis(X,Y,I),!.
+do_diagnosis(_).
+
+do_diagnosis(diag,_,_) :-!,
+	fail.
+do_diagnosis(X,Y,I) :- execute(X,Y,I),!.
+
+% :- dynamic specification/1.
+
+% Text Based Commnad
+
+command([st(X,Y,Z)|T],Term,[st(X,Y,Z)|T1]):-!,
+	assertz(st(X,Y,Z)),!,
+	command(T,Term,T1).
+command([specification(X)|T],X,[specification(X)|T1]):-!,
+	command(T,X,T1).
+command([st_variables(X,Y)|T],Term,[st_variables(X,Y)|T1]):-!,
+	assertz(st_variables(X,Y)),
+	command(T,Term,T1).
+command([],true,[]) :-!.
+command([],_,[]) :-!.
+command([H],Term,[Term1]) :-!,
+	command(H,Term),!,Term=Term1.
+command([H|T],(Term1,Terms),[Term1|T1]) :-
+	command(H,Term1),!,command(T,Terms,T1).
+
+command(demo(X),Term):-!,lite:demo(X,Term).   % predefined examples
+command(ex(X),Term):-!,ex(X,Term).
+command(prolog(X,P),X):-!,safe_call(P).
+command(prolog(P),true):-!,safe_call(P).
+command(tokio(P),true):-!,safe_call(tokio(P)).
+command(consult(P),Term):-!,
+	command(file(P),Term).
+command(file(P),Term):-
+	on_exception(Er,(consult(P),specification(Term)),
+           read_error(Term,Er,user,user)).
+command(A,A) :- atomic(A),!.
+command(P,R) :- functor(P,H,N),functor(R,H,N),
+        command_arg(N,P,R).
+command_arg(0,_P,_R):-!.
+command_arg(N,P,R):-arg(N,P,PA),arg(N,R,RA),
+        N1 is N-1,command(PA,RA),command_arg(N1,P,R).
+
+prolog_call(X) :- 
+	t2string(X,X0),s2terms(X0,[X1|_]),safe_call(X1).
+tokio_call(X) :- 
+	t2string(X,X0),s2terms(X0,[X1|_]),safe_call(tokio(X1)).
+
+safe_call(X) :-
+	on_exception(Er,user:call(X),
+           read_error(X,Er,user,user)),!.
+safe_call(_).
+
+:-dynamic font/2.
+
+small :- (retract(font(_,_));true),assert(font("7x14",14)).
+large :- (retract(font(_,_));true),assert(font("12x24",24)).
+
+:-small.
+% font("7x14",14).
+
+width(W,H):-
+   font(_,Fs),
+   W is integer(1000/24*Fs), H is integer(500/24*Fs).
+
+display_statistics(I) :-
+        itl_state_number(S), % number of state
+        itl_transition(L),!, % number of transition
+        name(S,Ss),name(L,Ls),
+        append("State: ",Ss,S0),append(S0," Edge:",S1),append(S1,Ls,S2),
+        tcl_eval(I,['$symbolicName(states) configure -text {',chars(S2),'}'],_),!.
+display_statistics(I) :-
+        itl_state_number(S), % number of state
+        itl_transition(L),!, % number of transition
+        name(S,Ss),name(L,Ls),
+        append("State: ",Ss,S0),append(S0," Edge:",S1),append(S1,Ls,S2),
+        tcl_eval(I,['$symbolicName(states) configure -text {',chars(S2),'}'],_),!.
+
+%%---------------------------------------------------------------------
+% display_diagnosis
+display_diag(View,I) :- diag(X),
+	write_display_diag(X,View,I).
+
+% display_execution exapmle.
+display_exe(View,I) :- exe(Z),
+	write_display_diag(Z,View,I).
+
+write_display_diag(counter_example(Hist),View,I) :-!,display_ce(Hist,View,I).
+write_display_diag(execution(Hist),View,I) :-!,display_ce(Hist,View,I).
+write_display_diag(R,_View,I):-!,
+	atomic(R),
+	clear_display(I),
+	tcl_eval(I,['$symbolicName(canvas) create text 0 0 -text "',R,'"'],_).
+
+append([],X,X):-!.
+append([H|X],Y,[H|Z]) :- append(X,Y,Z).
+
+clear_display(I) :-
+	tcl_eval(I,'$symbolicName(canvas) delete all',_).
+display_ce(Hist,View,I) :-
+	canvas_origin(OX,OY),
+	font(_,Fs),
+	clear_display(I),
+	X is OX+Fs/2,Y=OY,W is integer(60/24*Fs),H is integer(60/24*Fs),
+	(variable_list(L);L=[]),append(L,['Time'],L1),!,
+	display_var(['State'|L1],View,X,Y,H,X,X1,I),
+	X2 is X1+X,
+	display_ce(Hist,L,View,X2,Y,W,H,0,I). % ,View=>batchmodeoff.
+display_var([],_,_,_,_,X,X,_):-!.
+display_var([Var|L],View,X,Y,H,X1,X2,I):-
+	Y1 is Y+H, font(_Fn,Fs),
+	name(Var,VarText),length(VarText,Len0),Len is Len0*Fs,
+	% View=>stringlength(VarText,Len),
+	(X1>X+Len,X3=X1;X3 is X+Len),!,
+	display_string(X,Y,VarText,I),
+