| • Science | • People | • Locations | • Timeline |
In set theory and other branches of mathematics, the union of a collection of sets is the set that contains everything that belongs to any of the sets, but nothing else.
This article uses mathematical symbols.
If A and B are sets, then the union of A and B is the set that contains all elements of A and all elements of B, but no other elements. The union of A and B is usually written "A ∪B". Formally:
(This is an inclusive "or".)
For example, the union of the sets {1, 2, 3} and {2, 3, 4} is {1, 2, 3, 4}. The number 9 is not contained in the union of the set of prime numbers {2, 3, 5, 7, 11, …} and the set of even numbers {2, 4, 6, 8, 10, …}, because 9 is neither prime nor even.
More generally, one can take the union of several sets at once. The union of A, B, and C, for example, contains all elements of A, all elements of B, and all elements of C, and nothing else. Formally, x is an element of A ∪B ∪C iff x is in A or x is in B or x is in C.
Binary union (the union of just two sets at a time) is an associative operation; that is,
A ∪(B ∪C) = (A ∪B) ∪C.
In fact, A ∪B ∪C is equal to both of these sets as well, so parentheses are never needed when writing only unions.
Similarly, union is commutative, so you can write the sets in any order.
The empty set is an identity element for the operation of union.
That is, {} ∪A = A, for any set A.
Thus one can think of the empty set as the union of zero sets.
In terms of the definitions, these facts follow from analogous facts about logical disjunctionIn logic and mathematics, a disjunction is an "or statement". For example "John skis or Sally swims" is a disjunction. Note that in everyday language, use of the word "or" can sometimes mean "either, but not both" (eg, "would you like tea or coffee?")..
Together with intersectionIn mathematics, the intersection of two sets A and B is the set that contains all elements of A that also belong to B (or equivalently, all elements of B that also belong to A), but no other elements. This article uses mathematical symbols. The intersecti and complementIn set theory and other branches of mathematics, two kinds of complements are defined, the relative complement and the absolute complement . Relative complement If A and B are sets, then the relative complement of a A in B also known as the set theoretic, union makes any power setAbstract algebra Algebra Set theory In mathematics, given a set S the power set of S written P ''S or 2''S is the set of all subsets of S''. In formal language, the existence of power set of any set is presupposed by the axiom of power set. In this case S into a Boolean algebraIn mathematics and computer science, Boolean algebras or Boolean lattices are algebraic structures which "capture the essence" of the logical operations AND, OR and NOT as well as the corresponding set theoretic operations intersection, union and compleme. For example union and intersection distributes over each other, and all three operations are combined in de Morgan's laws. If you want a Boolean ringRing theory Mathematical logic In mathematics, a Boolean ring ''R is a ring for which x''2 x for all x in R that is, R consists of idempotent elements. These rings arise from (and give rise to) Boolean algebras. One example is the power set of any set X w instead of a Boolean algebra, then you can replace union with symmetric difference.