If we can define boolean and as
and(X, Y, Z) :- Z #=< X, Z #=< Y, X + Y #=< Z + 1.
How can we define predicates not(X,Y),
and(X,Y,Z), or(X,Y,Z), if(X,Y,Z), and iff(X,Y,Z) which model the Boolean constraints Y = ¬X, Z = X & Y , Z = X _ Y , Z = X ! Y and Z = X $ Y respectively using integer constraints ?
Anyone there??
and(X, Y, Z) :- Z #=< X, Z #=< Y, X + Y #=< Z + 1.
How can we define predicates not(X,Y),
and(X,Y,Z), or(X,Y,Z), if(X,Y,Z), and iff(X,Y,Z) which model the Boolean constraints Y = ¬X, Z = X & Y , Z = X _ Y , Z = X ! Y and Z = X $ Y respectively using integer constraints ?
Anyone there??