protocol
Set protocol.
Paulo Moura
1.0
2000/7/24
static
(no dependencies on other files)
Deletes an element from a set returning the set of remaining elements.
static
delete(Set, Element, Remaining)
delete(+set, @term, ?set) – one
True if the two sets have no element in common.
static
disjoint(Set1, Set2)
disjoint(+set, +set) – zero_or_one
True if the two sets are equal.
static
equal(Set1, Set2)
equal(+set, +set) – zero_or_one
True if the set is empty.
static
empty(Set)
empty(+set) – zero_or_one
Inserts an element in a set, returning the resulting set.
static
insert(In, Element, Out)
insert(+set, +term, ?set) – one
Inserts a list of elemnts in a set, returning the resulting set.
static
insert_all(List, In, Out)
insert_all(+list, +set, ?set) – one
True if the two sets have at least one element in common.
static
intersect(Set1, Set2)
intersect(+set, +set) – zero_or_one
Returns the intersection of Set1 and Set2.
static
intersection(Set1, Set2, Intersection)
intersection(+set, +set, ?set) – zero_or_one
Number of set elements.
static
length(Set, Length)
length(+set, ?integer) – zero_or_one
Element is a member of set Set.
static
member(Element, Set)
member(+term, +set) – zero_or_one
member(-term, +set) – zero_or_more
Returns the power set of a set, represented as a list of sets.
static
powerset(Set, Powerset)
powerset(+set, -list) – one
Selects an element from a set, returning the set of remaining elements.
static
select(Element, Set, Remaining)
select(?term, +set, ?set) – zero_or_more
True if Subset is a subset of Set.
static
subset(Subset, Set)
subset(+set, +set) – zero_or_one
True when Difference contains all and only the elements of Set1 which are not also in Set2.
static
subtract(Set1, Set2, Difference)
subtract(+set, +set, ?set) – zero_or_one
True if Difference is the symmetric difference of Set1 and Set2.
static
symdiff(Set1, Set2, Difference)
symdiff(+set, +set, ?set) – zero_or_one
True if Union is the union of Set1 and Set2.
static
union(Set1, Set2, Union)
union(+set, +set, ?set) – zero_or_one
(none)
(none)