Asymptotic equivalence Created 2026-09-24 Updated 2026-10-14
For functions with nonzero sufficiently near a specified limit,
The same definition applies to sequences as . Equivalently, : replacing by has a relative error tending to zero, and the difference is in little o notation. The limit and reference scale are essential parts of the statement.
For example, because . Replacing the former by the latter gives absolute error , which grows without bound. Thus asymptotic equivalence controls a ratio, rather than requiring the absolute error to vanish. This distinction is crucial when approximating a rapidly growing factorial with Stirling's formula.
By contrast, and have the same order in big theta notation, but are not asymptotically equivalent: their ratio remains two. For positive functions, asymptotic equivalence gives both-sided constant bounds eventually, whereas constant bounds alone do not recover the leading coefficient.
Figure 1.
Local exponential approximation: relative difference tends to zero and absolute error is quadratic
. Details.
For a local example with real , the exponential function obeys as . The Taylor theorem with Lagrange remainder gives
Thus for ,
This states in big O notation, and division by shows that the relative difference measured against vanishes. The diagram uses positive ; the bound is valid on both sides of zero. At , the absolute error is approximately and the relative difference against is approximately .
Bernoulli number Created 2026-10-05 Updated 2026-10-13
The Bernoulli numbers are a sequence of rational numbers that turns integer power sums into exact polynomials. The same numbers describe corrections when a discrete summation is compared with an integral. For example, the sum of squares is : the leading term is an integral, while the last two terms repair the difference between area and sampled values.
We use throughout. The defining exponential generating function is
Here is the exponential function and is a factorial; in particular, the coefficient of is , rather than . At the quotient has limiting value one. The identity can be read algebraically as a formal power series, or as a convergent series for .[ref]
To compute the numbers, multiply by and compare coefficients. The resulting recurrence relation, with binomial coefficients, is
Thus , , and give , , and . Continuing gives
The recurrence relation agrees with equation 24.5.3 after replacing its index by .[ref]
Why do so many values vanish? Put . Direct substitution gives , so is an even function. Its odd power series coefficients vanish: for every positive integer . The exception matters. The alternative convention obtained from has and exactly the same other values. A formula copied between conventions must also retain its summation endpoints.
Historically, integer power sums were studied before the modern Bernoulli number notation. A historical study examines formulas published in 1631 and distinguishes those separate formulas from encoding all exponents using one sequence of constants. This is a useful motivation for the generating function, without assigning all discovery to a single moment. [ref]
Binomial coefficient Created 2026-09-24 Updated 2026-10-13
For nonnegative integers and , the binomial coefficient
counts the -element subsets of an -element set. To obtain the formula, first choose an ordered list of different members in ways. Each subset appears in exactly orders, so divide by that factorial. The cases and each have one selection, the empty set and the whole set. For integer outside , the combinatorial convention is .
For , , the calculation is . The left-hand panel lists all ten subsets of . Marking an included member with one and an excluded member with zero gives a bijection with length-five binary strings containing exactly two ones. More generally, this makes selection, binary encoding, and coefficients in a binomial theorem three descriptions of the same count.
Figure 1.
Ten two-element subsets of a five-element set match the corresponding entry of Pascal's triangle
. Details.
For a uniformly chosen two-person team, a specified person belongs to four of the ten teams, so the probability of their inclusion is . Uniform selection of a -element subset similarly gives inclusion probability for each member when , as the double counting identity shows.
Take distinguishable, labeled particles and two boxes of equal volume. Retain only whether each particle is in the left or right box: use a bit for left and for right. Each length-20 string is one coarse microstate of this toy model. Assume the labels make independent side choices with equal probability, so the strings are equiprobable. Equal volumes motivate these weights for noninteracting particles with no preference for either box; equal volumes alone would not establish them for an arbitrary interacting gas.
Now retain only the number in the left box as the macrostate. Choosing which labels are left gives a binomial coefficient, so
The factorials count assignments to labels; the probability of a macrostate sums the probabilities of its constituent microstates. This is the binomial distribution with parameters and . The same binomial coefficient appears in the counting of distinguishable two-level systems, although here the macrostate records occupancy rather than energy. [ref]
The largest binomial coefficient occurs at , the balanced macrostate. All-left means and supplies just one string. Thus
There are balanced strings for every all-left string, even though each individual string has the same probability. Exact balance has about of the total probability; equilibrium reasoning concerns the many macrostates near balance too, rather than certainty of exactly ten particles on each side. The diagram compares the counts with their natural logarithms.
Figure 1.
Counts and Boltzmann entropies of the occupancy macrostates of twenty labeled particles
. Details.
Four fair, independent coins give a smaller worked example with the same binomial distribution. If is the number of heads, the five macrostates contain respectively microstates. Their probabilities are respectively . In particular, two heads is one macrostate containing six ordered coin sequences, with Boltzmann entropy in this counting analogy. A prescribed ordered sequence has one realization. The next diagram enumerates the same sixteen strings as left/right assignments.
Any deterministic comparison sort correct for all orders of distinct sort keys needs at least comparisons on some input. Here is a factorial, a logarithm, and the brackets denote the ceiling function. This is a worst-case requirement, not a requirement on every input.[ref]
For three distinct sort keys, the diagram has one leaf for each possible ordering of the original entries . Some paths need two comparisons, others three; two comparisons cannot distinguish all six orders.
Figure 1.
A comparison decision tree distinguishes the six orders of three distinct sort keys
. Each internal node tests the sort keys of two fixed original entries. A leaf gives the order in which their complete sorting records must be emitted. There are leaves and maximum depth three. The diagram assumes distinct sort keys, so no equality branch is needed. Details.
For the proof outline, represent adaptive comparisons by a binary tree: distinct sort keys give only two outcomes per comparison. A leaf fixes an output permutation; one leaf cannot correctly handle two different strict orders. Hence there must be at least leaves. Maximum depth permits at most leaves, so gives the bound. Even a three-way comparator has only two reachable outcomes on this distinct-key family.
The growth follows without a precise approximation to the factorial. At least of its factors are at least , so for ,
The brackets denote the floor function. This gives a constant times lower bound for large , matching the worst-case comparison growth of merge sort.
Distinct sort keys are essential to the counting argument. Identical sort keys do not create different strict orders. If all sort keys coincide, stable sorting returns the arrival order. This does not remove the worst-case bound for a comparison sort required to handle arbitrary distinct-key inputs.
The th correlation function is the density of the th factorial moment measure: integrating a nonnegative test function against gives the expectation of its sum over ordered -tuples of distinct points. For exactly exchangeably labelled points with symmetric joint density , it is times the marginal density of labels. It is not normalized to have total mass one.
Cyclic permutation 2026-10-14
A cyclic permutation, also called a permutation cycle, sends distinct elements and fixes every element outside this list. Its notation is . For example, is the permutation with image list : all four labels lie on one directed loop. In contrast,
has two separate loops, exchanging with and with . It is a permutation composed of two transpositions, rather than a single cyclic permutation.
Figure 1.
Two permutations on four labels: one cyclic permutation and two disjoint permutation cycles , with arrows showing every image
. Details.
Starting at a different point of the same loop changes the written list but preserves the cyclic permutation: . Reversing the direction generally changes the permutation; it gives the inverse function, here . A transposition is a cyclic permutation of length two; a one-element permutation cycle records a fixed point. In a cycle decomposition of a permutation, one-element permutation cycles are usually omitted, with the underlying set understood.
The beauty of this representation is that repeated rearrangements become motion around independent loops. Applying four times returns every label to its start, while applying twice already does so. Disjoint permutation cycles commute under function composition, since each moves only labels the others fix. On labels, there are cyclic permutations whose single loop contains every label: fix as the first written entry and order the other labels freely, giving a factorial. This is also the count of cyclic orderings; choosing a starting position would otherwise count each loop times. Rotations are identified here, while reversing direction is allowed to give a different cyclic ordering.
Proof outline for decomposition. Starting at any label in a finite set, repeatedly apply the permutation. The pigeonhole principle forces a repeated label. If the first repetition were at a label other than the starting one, its two predecessors would be different labels with the same image, contradicting the injective function property. This produces a permutation cycle returning to the start. Start again at a label not yet visited; the new permutation cycle cannot meet an earlier one, since the bijection gives every label a unique predecessor. Continue until every label belongs to a loop. The resulting cycle decomposition of a permutation is unique up to the order of the disjoint permutation cycles and the starting point written in each one. [ref]
Double counting establishes an identity by computing the cardinality of the same finite set in two ways. The useful step is to identify exactly what the members of that collection are; an algebraic equality then records two legitimate ways to organize them.
Take the ordered pairs where is a -element subset of an -element set and is marked. Choosing first gives pairs. Choosing first leaves members to choose from the other , giving . Hence
For five people and two-person teams, both counts give : ten teams with two choices of a marked member, or five choices of that member with four choices of a teammate. The identity is explained by the bijection between these descriptions, rather than merely verified through factorials.
Empty product Created 2026-10-05 Updated 2026-10-06
A product over the empty set has value one, the identity for multiplication. This makes splitting a product into successive pieces valid even when one piece contains no factors. In particular, the factorial convention is .
An exponential generating function encodes a sequence using the displayed factorial denominators. It is especially useful for counting labelled combinatorial structures: taking an unordered set of structures with positive size corresponds to exponentiating their exponential generating function. The rooted-tree generating function illustrates this through .
Factorial Created 2026-09-24 Updated 2026-10-13
For a nonnegative integer , the factorial is the product of the positive integers from to , with the empty product equal to :
Thus , , , and . The factorial counts the permutations of distinct objects: arranging gives exactly . The choice tree in permutation shows the three choices for the first position, two for the second, and one for the last.
The value has a counting explanation: the empty set has exactly one ordering, the empty list. Equivalently, it has exactly one bijection to itself, the empty function. There are no choices to make, and one completed outcome. The factorial therefore obeys the recurrence relation
The useful distinction is how many positions are filled. For integers , choosing and ordering distinct objects by sampling without replacement gives the falling factorial, while choosing an unordered -element subset gives the binomial coefficient:
For five people, assigning captain and deputy gives outcomes; choosing a two-person team gives . Every team has exactly assignments of the two roles, explaining the division. When , both counts are one. The factorial is useful here because one count of full orderings yields both formulas by cancellation and by forgetting order. [ref]
Distinctness matters. If the two copies of in are indistinguishable, the visible arrangements are just , numbering . Temporarily labelling them gives six permutations, but exchanging the two labels leaves each visible word unchanged, so every word was counted times.
Proof outline. For , choose the first object in ways, then order the remaining objects in ways. The rule of product gives the recurrence relation; repeated application gives the displayed product, starting from the one empty ordering. This explains why the factorial grows quickly: every additional distinct object introduces another multiplicative factor.
The graph of the factorial function has a fixed-length first-order formula in the language of ordered rings interpreted on the natural numbers. A remainder code records , , and for every . Uniqueness of remainders proves ; sufficiently large pairwise-coprime moduli and the Chinese remainder theorem supply a code for every input. Formula length is independent of the input variable's value, although substituting a numeral adds its encoding length.
Gamma function Created 2026-09-24 Updated 2026-10-14
The Gamma function extends factorials to a continuous argument. Its defining Gamma integral is
where uses the real natural logarithm for . The Gamma function recurrence gives its meromorphic continuation to the complex plane, with simple poles at and no zeros. See Gamma function residue at a nonpositive integer and Gamma function has no zeros for proof outlines.[ref]
For nonnegative integers , the factorial identity has a shift of one:
Thus for positive integers . Half-integer arguments supply a different familiar constant:
The first value follows from the Gaussian integral; the second follows from the Gamma function recurrence.[ref]
Figure 1.
The Gamma function on the positive real axis passes through the factorial values 0! through 5! at arguments 1 through 6
. Details.
The plot shows only positive real arguments; the Gamma function also accepts complex numbers away from its poles. Matching the factorials alone does not select a unique interpolation, even if the Gamma function recurrence is imposed: has the same positive-integer values and the same recurrence relation. The Bohr-Mollerup theorem supplies the extra condition that selects the Gamma function.
The useful idea is to replace a discrete product of numbers by an integral whose exponent varies continuously. The Gamma integral then evaluates whole families of integrals at once, provides the normalizing constant for the Gamma distribution in probability theory, and appears in physics, for example in the Bose integral. Its large-positive-argument growth reconnects this continuous description to factorials through Stirling's formula.[ref]
Historically, Leonhard Euler studied the interpolation of factorials in his paper E19, written in 1729 and published in 1738. His integral over becomes the Gamma integral after a change of variables, with the same one-step shift in the argument.[ref]