Events turn Boolean operations into operations on sets. For a die with sample space , let be the event “even outcome” and the event “outcome at least four”. At outcome , use the indicator functions and . Then
Thus logical conjunction becomes set intersection, logical disjunction becomes set union, exclusive or becomes symmetric difference, and logical negation becomes the complement of a set within . Outcome four satisfies both events, so inclusive logical disjunction includes it and exclusive or excludes it. If the die is fair, these four events have probabilities , , , and , respectively. No assumption of independent events is needed for the set identities; indeed and here are not independent, since .
Coinfinite set 2026-10-14
A subset of a specified ambient set is coinfinite if its complement of a set is infinite. In , the even numbers are both infinite and coinfinite, whereas a cofinite set is not coinfinite.
A formal language whose complement of a set, relative to the set of all input words, is a recursively enumerable language. A recognizer for the complement detects every negative instance eventually and need not halt on positive instances. A formal language is a decidable language exactly when it and its complement are both recursively enumerable languages.
Cut capacity Created 2026-10-07 Updated 2026-10-18
The cut capacity of , with the complement of a set, is
Only outward directed edges contribute; incoming and internal edges contribute nothing.[ref]
Here is the accounting behind the bound, using nonnegative original edge amounts in a finite flow network. Sum the divergence of a flow over the vertices in :
An edge with both endpoints in appears once with a plus sign at its tail and once with a minus sign at its head, so those contributions cancel. An outward edge appears only with a plus sign; an incoming edge appears only with a minus sign. Since , and every other vertex satisfies flow conservation, the left side is the flow value. Thus
The inequality uses two facts separately: each forward flow is at most its flow network edge capacity, and each backward flow is nonnegative. This is the weak duality bound underlying the max-flow min-cut theorem. It is an accounting proof, requiring no choice of augmenting paths.
For in the running example, explicitly add the two divergences of a flow:
The internal edge cancels. The edge is a genuine original directed edge entering , so its flow is subtracted; this is different from a backward edge in a residual network. Its flow network edge capacity is neither added to nor subtracted from cut capacity, which remains .
Equality in the bound holds precisely when every outward edge is saturated and every incoming edge carries zero flow, because
and every term is nonnegative. For the two outward edges are saturated and there are no incoming edges, so the gap is zero. For all outward edges are still saturated, but the incoming flow of gives a gap of . This explains exactly why the second cut of a flow network is not a minimum cut.
Double negation 2026-10-31
In propositional logic with the usual two truth values, negating a proposition twice preserves its truth value. Thus the complement of a set taken twice, in one fixed universal set, is the original set.
Extremal set theory Created 2026-09-24 Updated 2026-11-05
In extremal set theory, a set family is constrained by its intersections, inclusions or traces, and one asks for the largest possible cardinality of . The choice of constraint is essential: without one, the whole Boolean lattice gives members.
For example, let and require an intersecting family. A set and its complement of a set cannot both belong, so pairing all subsets with their complements gives . All subsets containing a fixed point attain equality. Adding a uniform-size requirement leads to the Erdős-Ko-Rado theorem.
An antichain instead forbids containment between distinct members. Sperner's theorem gives the sharp central-binomial bound, attained by a full middle level. Coordinate shifts of a set family simplify extremizers while preserving size; the polynomial method in combinatorics turns other intersection restrictions into linear independence. These two methods explain why a problem about subsets can become either an order argument or a vector space dimension bound.
Foreground-background polarity specifies which of two image classes is treated as the selected structure and which as its background. It involves a numerical convention as well as the intended interpretation: high-valued pixels can represent foreground in one encoding, while a dark feature may require the opposite threshold direction. A binary image's appearance alone does not establish its polarity.
For a chosen intensity threshold , define complementary normalized masks
The second is the complement of a set within the declared pixel grid. For the stipulated row and , the two binary selection masks are and . Equality belongs to the second selection. OpenCV's THRESH_BINARY and THRESH_BINARY_INV use these respective comparison directions, with the chosen output maximum replacing 1.[ref]
An image lookup table is a separate mapping from stored values to displayed colors. ImageJ's Create Mask command writes 255 inside a selection and 0 outside, but its default inverting lookup table can display the selected 255-valued pixels as black.[ref] Reversing that display mapping does not exchange the stored pixel values.
The distinction has a direct computational consequence. In its binary-image input, the documented Sholl analysis implementation treats zero intensities as background regardless of the lookup table or Black Background option.[ref] A visually inverted display can therefore leave the selected numerical structure unchanged, whereas replacing an 8-bit mask by exchanges its zero and 255 classes.
A reproducible geometric measurement records the threshold comparison, the values assigned to selected and excluded pixels, and any display-only inversion. A region of interest can further restrict the grid over which a complement is intended; reversing a mask over the whole image is different from selecting its complement only inside that region.
Independent set (graph theory) Created 2026-10-14 Updated 2026-10-18
An independent set selects mutually compatible objects when an edge of a graph represents a conflict. For example, if vertices are activities and edges join activities that cannot occur together, an independent set is a collection that can share one time slot. Finding the largest such collection is measured by the independence number.[ref]
In a finite simple graph , an independent set is a subset with no edge joining two selected vertices:
The empty set and every singleton set are independent sets. In the cycle graph drawn under vertex cover, is an independent set, but is not: the closing edge joins those two vertices. Choosing nonconsecutive labels is insufficient unless the wraparound edge is checked.
An independent set of maximum size has cardinality equal to the independence number. Being unable to add another vertex only makes an independent set inclusion-maximal. In the star graph , the centre alone is inclusion-maximal, since it is adjacent to every leaf, but the three leaves form a larger independent set. This distinction mirrors the difference between an inclusion-minimal vertex cover and a minimum vertex cover.
Every independent set has a vertex cover as its complement of a set; a largest independent set has a minimum vertex cover as its complement. In every proper vertex colouring, each colour class is an independent set, so graph coloring partitions the vertices into mutually compatible groups.
Minimum vertex cover Created 2026-10-14 Updated 2026-10-25
A minimum vertex cover is a vertex cover of smallest cardinality among all vertex covers of the same finite simple graph. The optimum size is the vertex cover number. By the complement of a set correspondence, a minimum vertex cover leaves a largest possible independent set unselected.
Minimum size is stronger than merely being unable to remove a selected vertex. In the star graph , the three leaves form a vertex cover from which no vertex can be removed: each leaf covers its own edge. Nevertheless, the centre alone is a minimum vertex cover of size one. Such an inclusion-minimal vertex cover can therefore be much larger than a minimum vertex cover.
Let be the decidable language of syntactically valid descriptions . Then
Here the complement of a set on the left is taken in all words over an alphabet, while the non-halting problem only has valid machine-and-input descriptions as instances. Any malformed description belongs to but not to . For example, the empty word has no separating ##, so cannot be a valid instance under the displayed encoding.
Fix valid descriptions and of, respectively, an immediately halting Turing machine on the empty word and a Turing machine looping forever on the empty word. Then
For the first many-one reduction, use the total computable function
For a valid input, nonmembership in is exactly membership in , so retaining it is correct. Every invalid input is a yes-instance of , and sends it to the fixed yes-instance . Therefore if and only if .
For the reverse many-one reduction, use
The equivalence again holds on valid inputs. Invalid inputs are no-instances of , and is a no-instance of . Syntax checking terminates, so is also a total computable function. We have proved
Writing as P and as co-P, the known relationships among the four complexity classes are
The equality supplies both inclusions between P and co-P, and it also gives co-P NP and co-P co-NP.
For the equality, a deterministic polynomial-time algorithm halts on every input; interchange its accepting and rejecting outcomes to decide the complement of a set in the same polynomial time. For P NP, a Nondeterministic Turing machine can simply make no choices and follow the deterministic computation. Finally, if , then , whence by the definition of co-NP.
Neither NP co-NP nor co-NP NP is known; either would imply equality by taking complements. Nor is either inclusion of P into NP or co-NP known to be strict. These unresolved relationships must not be presented as strict separations.
is a co-recursively enumerable language, is not a recursively enumerable language, and is not a decidable language. The stipulated order on halting times includes .
First, failure has a finite witness. For valid machine descriptions,
Indeed, a strict inequality forces the first halting time to be finite. The second can be either a larger finite time or infinity. Whether the displayed condition holds for fixed is decidable by a finite simulation, including the initial configurations when .
Enumerate all pairs and perform these finite tests by dovetailing, accepting the complement of a set of on finding a witness. Equivalently, at stage , inspect all inputs of length at most through transitions. A genuine violation eventually appears; if there is no violation, the procedure never accepts. Malformed descriptions or differing input alphabets can be recognized and accepted as nonmembers immediately. Thus the complement is a recursively enumerable language, proving that is a co-recursively enumerable language.
For non-enumerability, use the standard result that the complement of a set of the halting problem
is not a recursively enumerable language. Given , effectively construct two Turing machines over the same fixed input alphabet. On every input , let ignore and simulate on the fixed word , halting precisely when that simulation halts. Let loop forever on every input.
If does not halt on , both halting times are infinity for every , so the pair belongs to . If halts on , the first halting time is finite while the second is infinity, so the pair does not belong to . Therefore
This is a many-one reduction from non-halting to the pointwise running-time domination problem. Were a recursively enumerable language, constructing the pair and running its recognizer would recognize non-halting, contradicting the stated result. Hence is not a recursively enumerable language. Since every decidable language is a recursively enumerable language, is also undecidable.
Let enumerate all computably enumerable sets, with finite uniformly computable approximations increasing to . For example, take and
We construct a simple set by meeting the requirements : if is infinite, then . Begin with no enumerated elements and all requirements unmarked. At stage , process in this order. For an unmarked , if there is an with , enumerate the least such into and mark permanently. All membership tests at a stage are finite, and marking requires no test for eventual infinitude. The sparse-witness construction of a simple set therefore gives a computably enumerable set ; it is semidecidable by simulating this enumeration and halting when the input appears.
Each requirement enumerates at most one element. If an element in is enumerated by , then , so . At most elements of that interval can therefore enter , even if some requirements choose the same element. Consequently
The complement of a set is infinite.
If is infinite, it contains some , and that element eventually belongs to at a stage with . If has already acted, it already placed an element of in . Otherwise it acts by this stage and does so now. Thus every infinite semidecidable set meets . Equivalently, its infinite complement of a set is an immune set. The constructed is semidecidable, coinfinite, and meets every infinite semidecidable set.
As a useful check on the construction, cannot be a computable set. If it were, its infinite complement of a set would also be a computably enumerable set disjoint from , contradicting the property just proved. The argument requires neither deciding which are infinite nor protecting a prechosen infinite list of omitted numbers; the numerical witness bound provides all the required room.
The original PDF places complement bars on the second in each parenthesis and on the final . Thus the first parenthesis is the empty set, whereas the second is the whole sample space. Their union with any further subset is still the whole space:
The bars are missing from the local OCR, so using its unbarred expression would give the wrong result.
Write each set difference as an intersection with a complement of a set. Applying De Morgan's laws and then the distributive property gives
The complements turn the inner union into an intersection and vice versa. Thus
Use De Morgan's laws to remove the complement of a set, then distribute the two unions:
The first and last intersections in the middle line are the empty set. The remaining union is precisely the collection of elements belonging to exactly one of the original sets. Therefore both expressions define the same symmetric difference:
An algebraic way to prove the set identity is to show that is a complement of a set for . By the distributive property,
and
A complement of a set is unique: if both complement , then , and similarly . Consequently
Every complement of a set is taken in the same universal set . Apply De Morgan's laws for propositional logic to the membership propositions. For every ,
Equality of membership for every element proves the set identities
Using set difference as an intersection with a complement of a set, and using double negation, gives
Interchanging the two sets simply interchanges the two terms of this union, whose commutativity gives