# Uniqueness in a set of variables

From: Loizos Michael <gemichael_at_cytanet.com.cy>
Date: Tue 02 Oct 2001 05:56:03 PM GMT
Message-Id: <200110021829.f92IT4n06146@demokritos.cytanet.com.cy>
```Hello,

I am trying to remove the "duplicate" elements from a list. The problem is
that
the list contains variables (partially grounded terms) and I would like to
find
a way to solve this as follows:

for the list:  f(1,X), f(Y,1), f(1,1), g(2,Q), g(2,1)
the result should be: f(1,X), f(Y,1), g(2,Q)

for the list:  f(1,X), f(Y,Z), g(2,Q)
the result should be: f(Y,Z), g(2,Q)

that is:
I want to keep the minimum subset of these terms, such that the fully grounded
set of terms that can be unified with the subset remains the same as with the
fully grounded set of terms that can be unified with the initial set. Each
variable in the term takes finite grounded values.

for example if we replaced the list: h(1,X), h(Y,2)
with h(Q,W), that would be unwanted since we add information, for example
h(5,5) can be unified with h(Q,W), but not with h(1,X) or h(Y,2)

if we replaced the list: h(1,X), h(Y,2)
with h(1,2), that would be unwanted since we remove information, for example
h(1,5) can be unified with h(1,X), but not with h(1,2).

I hope I was clear enough.

Thanks for any help,
Loizos

_________________________________________
Loizos Michael (gemichael@cytanet.com.cy)
```
Received on Tue Oct 02 19:30:26 2001

This archive was generated by hypermail 2.1.8 : Wed 16 Nov 2005 06:07:10 PM GMT GMT