Darwin Help

Back to Index

union

Function union


Calling Sequence  a union b
union(a,b)
Parameters
NameTypeDescription

a set 
b set 
Return Type  set
Synopsis Computes the union of two sets, that is a set which has all the elements of a and b. Repeated elements are removed from the resulting set. The value intersect() is understood to be the entire universe, and hence unions including intersect() will simply return this term. In its functional form, any arbitrary number of sets can be unioned. In particular, union(a) = a, and union() = {}.
Examples
> {1,2,3} union {2,3,4};
{1,2,3,4}
> {1,2,3} union {};
{1,2,3}
> {1,2,3} union intersect();
intersect()
See also intersect,   member,   minus,   subset