Set Union
The union of two sets A and B is the set that contains every element belonging to A, to B, or to both.

The symbol used for union is ∪.

The expression A ∪ B is read as the union of A and B or simply A union B.
A key feature of sets is that elements cannot be repeated. Therefore, if an element belongs to both A and B, it appears only once in the union.
Union of Multiple Sets. The union operation is not limited to two sets. It can also be applied to an entire family of sets. If \( \{A_i\}_{i \in I} \) is a collection of sets, their union is written as $$ \bigcup_{i \in I} A_i = \{ x \mid x \in A_i \text{ for at least one } i \in I \} $$ This notation represents the set of all elements that belong to at least one set in the family.
A Practical Example
Consider the following sets:
$$ A = \{ 2, 5, 6, 7, 8 \} $$
$$ B = \{ 1, 3, 4, 6, 7, 9 \} $$

To find the union, combine all elements from both sets and remove any duplicates.
$$ A \cup B = \{ 1, 2, 3, 4, 5, 6, 7, 8, 9 \} $$

Note. The elements 6 and 7 appear in both A and B. Even so, they are listed only once in the union because repeated elements are not allowed in a set.
Example: One Set Contained in Another
Consider the sets
$$ A = \{ 1, 2, 3, 4, 5, 6, 7, 8, 9 \} $$
$$ B = \{ 2, 4, 6, 8 \} $$
Since every element of B already belongs to A, the set B is a proper subset of A.
As a result, the union adds no new elements and is equal to A itself:
$$ A \cup B = \{ 1, 2, 3, 4, 5, 6, 7, 8, 9 \} $$

Example: Disjoint Sets
Now consider the sets
$$ A = \{ 1, 3, 5, 7, 9 \} $$
$$ B = \{ 2, 4, 6, 8 \} $$
These sets are disjoint, meaning that they have no elements in common.
In this case, the union is simply the collection of all elements from both sets:
$$ A \cup B = \{ 1, 2, 3, 4, 5, 6, 7, 8, 9 \} $$
The Euler-Venn diagram below provides a visual representation of the union.

Union and Logical OR. Set union is often compared to the logical OR operation. More precisely, it corresponds to the inclusive OR, which is true when either condition is true or when both conditions are true. For example, if an element belongs to both A and B, it is still included in the union A∪B. 
This differs from the exclusive OR (XOR), which excludes cases in which both conditions are true simultaneously. For this reason, whenever set union is compared with logical disjunction, the correct comparison is with inclusive disjunction.
Properties of Union
Like many mathematical operations, union satisfies several important algebraic properties.
- Commutative Property
The order of the sets does not matter: $$ A \cup B = B \cup A $$
- Associative Property
The way the sets are grouped does not affect the result: $$ (A \cup B) \cup C = A \cup (B \cup C) $$
- Distributive Property over Intersection
Union distributes over intersection: $$ A \cup (B \cap C) = (A \cup B) \cap (A \cup C) $$
Cardinality of a Union
The cardinality of a union depends on whether the sets share common elements.
- Disjoint Sets
If two sets have no elements in common, the cardinality of their union is simply the sum of their cardinalities: $$ |A \cup B| = |A| + |B| $$
- Non-Disjoint Sets
If two sets have elements in common, the elements in the intersection would be counted twice when adding the cardinalities. To correct this, subtract the cardinality of the intersection: $$ |A \cup B| = |A| + |B| - |A \cap B| $$
Why does this formula work? The quantity |A| + |B| counts every element in A and every element in B. Elements that belong to both sets are counted twice, so subtracting |A∩B| removes the extra count.

For three sets, the inclusion-exclusion principle gives:
$$ |A \cup B \cup C| = |A| + |B| + |C| - |A \cap B| - |A \cap C| - |B \cap C| + |A \cap B \cap C| $$
Why is the last term added? After subtracting the pairwise intersections, the elements belonging to all three sets have been removed too many times. Adding |A∩B∩C| restores the correct count.

The same idea extends naturally to unions involving any finite number of sets.
