(hak) 86> fff
/cygdrive/d/hak/hlt/src/hlt/fot/fuz/syntax
*** Running FFF...
*** Run of Wed Nov 28 10:13:05 PST 2018
*** 
*** Welcome to FFF, a facility (under development) for fuzzy lattice operations on first-order terms
*** 
*** Author: Hassan Aït-Kaci - HAK Language Technologies (haklt.mail@gmail.com)
*** 
*** Type '#help;<CR>' for help or 'quit;<CR>' to quit (if no prompt upon an error, type ';<CR>')
*** 

FFF> #help #map;
*** There are no declared argument maps 

FFF> #help;
*** Currently supported FFF pragmas:

	#help pragma;
	#fun f1/n1 ... fk/nk;
	#sig;
	#sim f1 g1 α1 ... fk gk αk;
	#close;
	#funclass f α;
	#termclass term α;
	#funrep f α;
	#termrep term α;
	#show;
	#map f g α i1:j1 ... ik:jk;
	#comp;
	#load "file";
	#trace n;
	#reset;

*** Currently supported FFF operations:

	t1 /\ t2; computes the infimum of terms t1 and t2 (unification);
	t1 \/ t2; computes the supremum of terms t1 and t2 (generalization);
	t1 ~ t2;  computes the similarity degree of terms t1 and t2 (value in [0.0,1.0]).

*** If a similarity is defined on the signature, these operations are fuzzy; otherwise, they are crisp.

FFF> #sig;
*** The current signature has 0 functors: {}

FFF> #fun f/2 g/1 h/3 a/0 b/0;
*** The current signature has 5 functors: {f/2, g/1, h/3, a/0, b/0}

FFF> #map f h .7 1:3 2:1;
*** Declared argument maps: 
	f h 0.7 1:3 2:1 

FFF> #map f h .5 1:3;
*** Declared argument maps: 
	f h 0.7 1:3 2:1 
	f h 0.5 1:3 

FFF> #comp;
!!! Sorry: 'comp' clause is not yet implemented

FFF> #close;
*** Computed similarity closure (enter '#show;<CR>' to see it)

FFF> #show;
*** The current signature has 5 functors: {f/2, g/1, h/3, a/0, b/0}

*** The declared similar functor pairs are: 
	f h 0.7
	f h 0.5

*** The similarity closure of the declared similar functor pairs is:

     f/2  g/1  h/3  a/0  b/0  
     ---  ---  ---  ---  ---  
f |  1.0  0.0  0.5  0.0  0.0 

g |  0.0  1.0  0.0  0.0  0.0 

h |  0.5  0.0  1.0  0.0  0.0 

a |  0.0  0.0  0.0  1.0  0.0 

b |  0.0  0.0  0.0  0.0  1.0 

*** It has 3 similarity degrees: [0.0,0.5,1.0]

*** The 3 corresponding fuzzy partitions are:

*** >= 0.0: { {f, g, h, a, b} }

*** >= 0.5: { {f, h}, {g}, {a}, {b} }

*** >= 1.0: { {f}, {g}, {h}, {a}, {b} }

FFF> #map f h .2;
!!! New similarity declaration: re-compute closure with '#close;<CR>'
*** Declared argument maps: 
	f h 0.7 1:3 2:1 
	f h 0.5 1:3 
	f h 0.2 

FFF> #close;
*** Computed similarity closure (enter '#show;<CR>' to see it)

FFF> #show;
*** The current signature has 5 functors: {f/2, g/1, h/3, a/0, b/0}

*** The declared similar functor pairs are: 
	f h 0.7
	f h 0.5
	f h 0.2

*** The similarity closure of the declared similar functor pairs is:

     f/2  g/1  h/3  a/0  b/0  
     ---  ---  ---  ---  ---  
f |  1.0  0.0  0.2  0.0  0.0 

g |  0.0  1.0  0.0  0.0  0.0 

h |  0.2  0.0  1.0  0.0  0.0 

a |  0.0  0.0  0.0  1.0  0.0 

b |  0.0  0.0  0.0  0.0  1.0 

*** It has 3 similarity degrees: [0.0,0.2,1.0]

*** The 3 corresponding fuzzy partitions are:

*** >= 0.0: { {f, g, h, a, b} }

*** >= 0.2: { {f, h}, {g}, {a}, {b} }

*** >= 1.0: { {f}, {g}, {h}, {a}, {b} }

FFF> #map g a .6 3 8;
!!! New similarity declaration: re-compute closure with '#close;<CR>'

FFF> #close;
*** Computed similarity closure (enter '#show;<CR>' to see it)

FFF> #show;
*** The current signature has 5 functors: {f/2, g/1, h/3, a/0, b/0}

*** The declared similar functor pairs are: 
	f h 0.7
	f h 0.5
	f h 0.2
	g a 0.6

*** The similarity closure of the declared similar functor pairs is:

     f/2  g/1  h/3  a/0  b/0  
     ---  ---  ---  ---  ---  
f |  1.0  0.0  0.2  0.0  0.0 

g |  0.0  1.0  0.0  0.6  0.0 

h |  0.2  0.0  1.0  0.0  0.0 

a |  0.0  0.6  0.0  1.0  0.0 

b |  0.0  0.0  0.0  0.0  1.0 

*** It has 4 similarity degrees: [0.0,0.2,0.6,1.0]

*** The 4 corresponding fuzzy partitions are:

*** >= 0.0: { {f, g, h, a, b} }

*** >= 0.2: { {f, h}, {g, a}, {b} }

*** >= 0.6: { {f}, {g, a}, {h}, {b} }

*** >= 1.0: { {f}, {g}, {h}, {a}, {b} }

FFF> quit;
*** So long - and thanks for playing with FFF...
*** We hope that you had some FFFuzzy FFFun! 8^D
