Subject: RE: How to write join(X,Y)??

From: Fernando Guzman <[email-masked]>
Date: Mon, 6 Dec 1999 14:49:26 -0500 (EST)

alexandra romantseva writes:
 > Hello!
 > 
 > I was wondering if anyone can PLEASE help me write a definition for
 > join(X,Y). 
 > I need join(X,Y) join the two equivalence relations X and Y, so that
 > positions equivalent 
 > whenever either of X or Y become then equivalent.  

Alexandra,
  what you need to do is compose the two relations X and Y iteratively
until the result stabilizes.  That is, compute the following
compositions:
XoY			XoY means X composed with Y as binary relations
XoYoX
XoYoXoY
XoYoXoYoX
and so on, until you get nothing new. At that point stop.  You now
have the join of the two equivalence relations.  If X and Y are
finite, and as far as Prolog is concerned they better be, then the
process is guaranteed to stop.

-- 
Fernando Guzman
[email-masked]