Reading route. Use set operations to distinguish simultaneous domain conditions from alternative branches. The logarithm examples below use the stated rule that its input must be positive; the construction and inverse laws are developed in 4.2 Exponential and logarithmic functions. They are later applications, not assumptions needed for the set identities.
Learning goals and role
Use set notation accurately, distinguish a simultaneous condition from an alternative branch, and determine domains before manipulating formulas.
1. Elements, subsets and the empty set
The statement says is an element. The statement says every element of is also in . They have different logical types. Sets are determined by their members, not by order or repetition: . The empty set has no elements and is a subset of every set, since there is no element that violates the inclusion.
The set is not empty: it contains one element, namely the empty set. A power set is the set of all subsets of ; it always contains . This does not mean for every . For example the real interval contains numbers, not a set serving as an extra endpoint.
For real inputs, interval notation records endpoint membership: excludes both endpoints, includes them, and a half-open interval includes just the indicated square-bracket endpoint. Infinity is not a real member, so an interval extending to infinity always uses a parenthesis there.
2. Operations translate logical connectors
| Operation | Symbol | Definition |
|---|---|---|
| Union | elements in or in | |
| Intersection | elements in both and | |
| Difference | elements in but not in | |
| Complement | elements outside in a chosen universal set |
The complement depends on a universal set . In this unit we usually assume all sets live inside some fixed , so means .
Write for the fixed universe above. In set-builder notation,
The word “or” is inclusive. Complements depend on the universe, while is determined by the two named sets.
Proposition: De Morgan and difference rules
For subsets of the fixed universe, , , and .
Proof. An element fails to belong to a union exactly when it belongs to neither set, proving the first rule by equivalent membership statements. It fails to belong to an intersection exactly when at least one membership fails, proving the second. Membership in the difference means membership in together with nonmembership in , the third rule. Because every step is an equivalence, both set inclusions have been proved, not only one.
For finite sets, : the first addition counts the intersection twice, and subtracting one copy corrects it. A Cartesian product contains ordered pairs , so its finite cardinality is : for each of the first entries there are second entries. This is a counting statement, not an assumption that probabilistic events are independent.
Concept lensAlgebraic
Set operations as arithmetic of zeros and ones
Record a subset by its indicator , equal to on and elsewhere. Then intersection is a product, , complement is , and union is . The first De Morgan rule becomes the polynomial identity , and summing over a finite universe gives the counting formula.
The explorer below fixes the universe and lets you toggle the members of and ; it starts from and , where , and . The rules above can be checked on any state it shows. Here , so ; and , which is also .
Toggle membership and read set operations
Toggle an element in either set. Read the union, intersection and directional difference of the current sets.
| U | A | B |
|---|---|---|
| 1 | ∈ A | ∉ B |
| 2 | ∈ A | ∈ B |
| 3 | ∉ A | ∈ B |
| 4 | ∈ A | ∈ B |
| 5 | ∉ A | ∉ B |
- A
- {1, 2, 4}
- B
- {2, 3, 4}
- Union
- {1, 2, 3, 4}
- Intersection
- {2, 4}
- Difference A \ B
- {1}
Holds: The intersection is contained in the union
Every element in both A and B is in at least one of A or B. The same membership checks drive the board and all three results.
NoticeA∖B keeps elements of A that are not in B; reversing A and B can change the result. {} is the empty set. The board lists the membership of every element of the universe.
3. A function needs one output at every declared input
Definition 1.1.1
(A function)
A function from to is a subset of such that every is paired with exactly one .
For , is the domain and the codomain. Its image or range is and need not fill . The graph is a subset of containing exactly one ordered pair above every input. A formula with an undefined value at an allegedly included input does not define a function on that declared domain.
For a target subset , the inverse image is defined even if the function has no inverse function. An inverse function on the full codomain instead requires bijectivity: injectivity prevents two inputs sharing an output, and surjectivity ensures every target has one.
Worked domain choice. The rule from to is surjective but not injective. Restricting its domain to makes it bijective, with inverse . Declaring its codomain to be all would make it non-surjective even after that restriction. Domain and codomain are mathematical data, not labels added after solving an equation.
Counterexample mode
Images need not preserve intersections
Claim: for any function, . Take on , and . Then , so , while . Only the inclusion holds in general; equality holds for every pair of subsets when is injective. Inverse images behave better: for every function.
4. Domain intersections for simultaneous operations
For a sum, product or quotient of two real functions, an input must belong to both original domains. A quotient also requires a nonzero denominator. A square root requires a nonnegative radicand, and a logarithm a strictly positive argument. These are simultaneous conditions and therefore intersect.
Let with real parameter . Its domain is . To make the dependence visible:
- If , the domain is ; the excluded value is already outside it.
- If , it is ; the radicand would allow the endpoint but the denominator excludes it.
- If , it is .
Now form . The logarithm requires the quotient to be positive. Its square-root numerator cannot be negative, so positivity requires and . Thus the domain is when , and empty when . Taking logs changes the domain; it is not enough to keep the radicand and denominator conditions alone. An empty domain is a legitimate mathematical possibility, though it may show a proposed real model has no permissible inputs.
5. Piecewise alternatives produce a union
Consider the rule using when and when . The first branch is valid on . The second branch is valid only when both and , giving . The actual domain is the union .
It is not their intersection: no input is required to use both alternative branches. It is also not all real numbers: the branch instruction does not magically make defined on . Piecewise specifications need valid formulas on their assigned branches and compatible outputs wherever two branch domains overlap. If two overlapping branches give different outputs, the rule fails the single-output function requirement.
For comparison, the ordinary sum would require both formulas simultaneously, so its real domain is empty. The same two formulas lead to different domain logic when combined as alternatives rather than added.
6. Algebraic equations still need the original input set
The equation forces because the left side is nonnegative. Squaring gives , whose roots are two and minus one. Only two satisfies the original equation. The squared equation generated candidates; the original sign condition selected the actual solution.
Likewise cancellation in gives only on the original domain . The formula on all reals is a different function, an extension with a filled-in missing point. Equal algebraic values on a common domain do not identify functions with different domains.
Worked examples
Worked example 1.1.2
(Two simultaneous square roots)
Find the real domain of .
The difference needs both terms, so the domain is the intersection of two conditions. The first root needs and . Its critical values are and : the quotient is positive on , negative on , zero at and positive on . So the first condition is . The second root needs , that is, . Therefore
The endpoint is excluded because it is a zero of a denominator, is included because the first radicand is zero there, and is included because the second radicand is zero there. Rewriting the first root as would wrongly discard the whole interval , where both factors are negative.
Worked example 1.1.3
(Inverse images without an inverse function)
For , , find , and .
The function is not injective, since , yet inverse images are defined for every target set. By definition, means and . The first condition, , holds for or . The second, , holds for . Both are required, so
Next, . The equation forces , so , while would require , so . The empty inverse image says only that is not in the range. The computation also shows , the rule recorded after the counterexample above.
Worked example 1.1.4
(A difference rule proved by membership)
Prove that for all sets .
For any element , the following statements are equivalent, each step using only the definitions of difference, union and intersection:
The second step is the first De Morgan rule applied to one element, and the third repeats the condition , which changes nothing. Because every step is an equivalence, both inclusions are proved at once. Check on , , : the left side is , and the right side is . The companion rule follows in the same way from the second De Morgan rule.
Graded set-language and model tasks
- Membership. Explain why always holds but does not. Compute and .
- Universe. For , compare its complement in with its complement in . Prove why the answers differ without changing .
- Domain logic. Find the real domain of , identifying why each endpoint or zero is included or excluded.
- Piecewise function. A rule gives when and when . Does it define a function on all reals as written? Locate every conflict and explain how to repair the specification without claiming a unique repair.
- Parameter composition. For , prove that its domain is nonempty exactly when , and explain why the two strict endpoints arise from different conditions.
- Function identity. Are on its natural domain and on all reals equal functions? State the precise equality relation that does hold and how to define an extension.
Full solutions
- A failed inclusion would require an element of the empty set outside , impossible. Membership is a separate statement about whether contains that set as one of its elements, false for example at . The only subset of the empty set is itself, so . The subsets of are and , giving a two-element power set.
- In the complement is . In it is . A complement consists of universe members not in , so the second removes the outside-universe portions while retaining the same nonmembership test. Complements must always specify their ambient set.
- The logarithm requires , or or . The denominator requires a defined nonzero square root, so , or . Their intersection is . The values make the log argument zero; make the denominator zero; all four are excluded for different reasons.
- Both branches apply on . Their outputs agree only when , namely . They conflict at every . One repair is to use the first branch for and the second for ; another can choose a different nonoverlapping split. The original conditions do not select a unique repair, so silently imposing one would change the definition.
- The square root must be strictly positive to be a positive logarithm input, giving . Its denominator must be positive because the numerator cannot be negative, giving . Thus admissible inputs exist exactly when the strict interval is nonempty. The right endpoint makes the numerator zero, and the left makes the quotient denominator zero; both are invalid for different stages of the composition.
- Their domains differ, so they are not equal as functions. For every , factorization gives , meaning equals the restriction of to . Defining a new function to agree with there and assigning value two at one produces exactly the extension . The original function does not acquire that value by cancellation alone.
Quick checks
Quick check
(For and , find , , and .)
Decide the membership of each endpoint separately.
Solution · Answer
: the point lies in , the point in , and the gap between and is covered by both. : the point is not in and is not in . : the point is in and not in , so it is kept. : the point is in and not in .
Quick check
(Finite sets satisfy , and . Find , and .)
Solve the counting formula for the intersection.
Solution · Answer
From we get . The set is the disjoint union of and , so , and similarly . Check: the three disjoint pieces give .
Quick check
(A rule gives when and when . Find its domain and decide whether it defines a function there.)
Find each branch's valid inputs, take the union, and examine the overlap of the branch conditions.
Solution · Answer
The first branch is valid where and , that is, on . The second branch is valid on all of . The domain is the union . The two branch conditions overlap only at , where the outputs are and . They agree, so every input in the domain has exactly one output and the rule defines a function on . Inputs below are excluded although the condition assigns them to the first branch.
Summary and terms
A set operation encodes a logical connector. A domain intersection collects simultaneous requirements, while a piecewise-domain union collects valid alternatives. A restriction reduces a function's domain; an extension adds inputs with assigned compatible outputs. An inverse image is defined for every function, unlike an inverse function. Correct set language makes formula domains, branch conditions and model validity explicit before algebra begins.