DISCRETE MATH • SETS, RELATIONS, AND FUNCTIONS

Comparing Growth Rates and Common Function Classes

Understanding how functions scale is essential for classifying algorithmic efficiency and analyzing mathematical behavior.

Historical Context & Motivation

The question of how quickly mathematical functions grow has been central to analysis and computation for centuries. Long before the invention of electronic computers, mathematicians recognized that different formulas describing natural phenomena could behave in radically different ways as their inputs became large. Understanding these growth rates was not merely an abstract exercise—it was essential for predicting planetary motion, calculating compound interest, and estimating the feasibility of large-scale computations. The formalization of function growth into a rigorous hierarchy emerged gradually, driven by work in number theory, real analysis, and eventually the nascent field of computer science.

1695
Leibniz and Rates of Change
Gottfried Wilhelm Leibniz and the early calculus pioneers formalized the notion of a function's rate of change, laying the groundwork for comparing how different functions diverge as their arguments increase.
1892
Bachmann's Big-O Notation
Paul Bachmann introduced the O-notation in his work on analytic number theory, providing a concise way to express asymptotic upper bounds on function growth.
1909
Landau Popularizes Asymptotic Notation
Edmund Landau extended Bachmann's notation and introduced the little-o symbol, establishing the asymptotic framework that remains standard in mathematics and computer science today.
1965
Hartmanis–Stearns Complexity Classes
Juris Hartmanis and Richard Stearns published their seminal paper on computational complexity, using growth-rate hierarchies to classify problems by the time and space resources required by Turing machines.
1976
Knuth Standardizes Θ and Ω
Donald Knuth advocated for the systematic use of Big-Θ (tight bound) and Big-Ω (lower bound) alongside Big-O, creating the modern triad of asymptotic notations used across discrete mathematics and algorithm analysis.

Today, the systematic comparison of growth rates is indispensable in discrete mathematics. Whether you are proving that one set is countable, analyzing the running time of a sorting algorithm, or establishing bounds on a recurrence relation, you need a reliable vocabulary and toolkit for saying precisely when one function eventually dominates another. This lesson builds that toolkit from first principles.

Core Principles & Definitions

Before we can compare functions, we must agree on what it means for one function to grow faster than another. Informally, f(n) grows faster than g(n) if, for sufficiently large n, f(n) eventually exceeds g(n) by an arbitrarily large factor. The formal machinery for making this precise centers on three asymptotic notations—Big-O, Big-Ω, and Big-Θ—and on a hierarchy of common function classes that serve as reference points along the growth-rate spectrum.

1

Big-O (Asymptotic Upper Bound)

f(n) ∈ O(g(n)) means there exist constants c > 0 and n₀ such that f(n) ≤ c · g(n) for all n ≥ n₀. This captures the idea that f grows no faster than g.
2

Big-Ω (Asymptotic Lower Bound)

f(n) ∈ Ω(g(n)) means there exist constants c > 0 and n₀ such that f(n) ≥ c · g(n) for all n ≥ n₀. This guarantees that f grows at least as fast as g.
3

Big-Θ (Tight Asymptotic Bound)

f(n) ∈ Θ(g(n)) if and only if f(n) ∈ O(g(n)) and f(n) ∈ Ω(g(n)). This means f and g grow at the same rate up to constant factors.
4

Little-o (Strict Domination)

f(n) ∈ o(g(n)) means lim(n→∞) f(n)/g(n) = 0. Unlike Big-O, little-o expresses that g strictly outgrows f—no constant factor can keep f competitive.
5

The Growth Hierarchy

Common function classes are ordered: 1 ≺ log n ≺ √n ≺ n ≺ n log n ≺ n² ≺ n³ ≺ 2ⁿ ≺ n! ≺ nⁿ. Each function in this chain is o of every function to its right.
KEY TAKEAWAY
Think of growth-rate comparison like a long-distance race observed over time. Two runners may stay close for the first mile, but if one has a fundamentally faster pace, the gap between them will eventually become enormous—and no head start (constant factor) can compensate. Big-O, Big-Ω, and Big-Θ formalize this intuition by focusing exclusively on what happens as the 'race distance' (input size n) goes to infinity.

Visual Explanation — The Growth Hierarchy

The diagram below plots six common function classes on a shared set of axes so that you can see how dramatically they diverge. While the logarithmic and linear functions appear to crawl along the bottom, the exponential function rockets upward so quickly that even moderate values of n make it impractical to compute. Observe how the polynomial functions (n² and n³) occupy a middle tier—they grow much faster than linear, yet they are dwarfed by exponentials.

The six plotted curves illustrate how drastically function classes diverge. Note how log n and √n remain nearly flat, while 2ⁿ shoots off the chart before n even reaches 10.

The visual makes a crucial point: for small values of n, several of these functions produce comparable outputs, and constant factors or lower-order terms can make a 'slower' class temporarily appear larger. Asymptotic analysis deliberately ignores these initial segments and focuses on the tail behavior—the long-run trend as n → ∞. This is precisely why Big-O and its relatives require a threshold n₀ beyond which the bounding inequality must hold.

Mathematical Framework

The formal definitions of asymptotic notation translate our intuitive notion of 'grows faster' into precise, provable statements. Each definition quantifies the relationship between two functions using existential and universal quantifiers over the natural numbers, making them amenable to the proof techniques of discrete mathematics.

BIG-O (UPPER BOUND)
f(n) ∈ O(g(n)) ⟺ ∃ c > 0, ∃ n₀ ∈ ℕ : ∀ n ≥ n₀, f(n) ≤ c · g(n)
Here c is a positive real constant and n₀ is a threshold. The definition states that beyond n₀, f(n) is bounded above by a constant multiple of g(n).
BIG-Ω (LOWER BOUND)
f(n) ∈ Ω(g(n)) ⟺ ∃ c > 0, ∃ n₀ ∈ ℕ : ∀ n ≥ n₀, f(n) ≥ c · g(n)
Big-Ω is the mirror of Big-O: it guarantees that f grows at least as fast as g, ensuring a lower bound on f's growth.
BIG-Θ (TIGHT BOUND)
f(n) ∈ Θ(g(n)) ⟺ f(n) ∈ O(g(n)) ∧ f(n) ∈ Ω(g(n))
Equivalently, there exist c₁, c₂ > 0 and n₀ such that c₁ · g(n) ≤ f(n) ≤ c₂ · g(n) for all n ≥ n₀. The function f is 'sandwiched' between two constant multiples of g.
LIMIT TEST FOR GROWTH COMPARISON
lim (n→∞) f(n) / g(n) = L
If L = 0, then f ∈ o(g) and g dominates. If 0 < L < ∞, then f ∈ Θ(g). If L = ∞, then g ∈ o(f) and f dominates. This limit test is the single most useful technique for comparing two specific functions.

The limit test deserves special attention because it converts asymptotic comparison into a standard calculus problem. When both f and g tend to infinity, L'Hôpital's rule is often applicable, making the comparison mechanical. For instance, to show that n² ∈ o(2ⁿ), one can compute lim(n→∞) n²/2ⁿ; repeated application of L'Hôpital's rule yields 0, confirming that every polynomial is eventually dwarfed by every exponential.

⚠️ Common Pitfall
Big-O gives only an upper bound, not a tight characterization. Saying f(n) ∈ O(n²) does not preclude f(n) from being Θ(n) or even Θ(1). To pin down the exact growth class, you need Big-Θ. Many students conflate O and Θ—avoid this by always asking whether a matching lower bound has been established.

Detailed Breakdown of Common Function Classes

The standard growth hierarchy arranges common function classes from slowest to fastest. Each class appears ubiquitously in algorithm analysis, combinatorics, and mathematical modeling. Understanding where a function sits in this hierarchy immediately tells you whether a computation is feasible, how a recurrence will behave, or whether a series converges.

The standard hierarchy from slowest to fastest growth
ClassRepresentative f(n)BehaviorTypical Context
ConstantΘ(1)Output independent of input sizeHash table lookup, array index access
LogarithmicΘ(log n)Grows extremely slowly; doubling n adds a fixed amountBinary search, balanced BST operations
PolylogarithmicΘ((log n)^k)Slightly faster than logarithmic for k > 1, still sub-polynomialCertain parallel algorithms, number-theoretic sieves
Sub-linearΘ(√n) or Θ(n^c), 0<c<1Grows faster than log but slower than linearTrial division up to √n, certain sampling algorithms
LinearΘ(n)Proportional to input; doubling n doubles the outputSequential scan, counting sort
LinearithmicΘ(n log n)Slightly super-linear; arises in divide-and-conquerMerge sort, FFT, comparison-based sorting lower bound
PolynomialΘ(n^k), k ≥ 2Grows as a power of n; feasible but can be slow for large nMatrix multiplication (n³), bubble sort (n²)
ExponentialΘ(2^n) or Θ(c^n)Grows astronomically; each increment in n multiplies the outputBrute-force subset enumeration, recursive Fibonacci
FactorialΘ(n!)Faster than exponential; counts permutationsBrute-force TSP, permutation generation
The spectrum arranges function classes from constant (left) to factorial (right). The concrete values at n = 20 show how exponential and factorial classes produce astronomically large numbers even for moderate inputs, while logarithmic and sub-linear classes remain tiny.

Two critical 'barriers' in the hierarchy deserve emphasis. The first is the polynomial–exponential barrier: any polynomial nk is eventually dominated by cn for any constant c > 1, no matter how large k is. The second is the logarithmic–polynomial barrier: any power of a logarithm, (log n)k, is eventually dominated by nε for any ε > 0. These barriers are provable via the limit test and have profound implications: problems solvable in polynomial time are considered 'tractable,' while those requiring exponential time are generally infeasible.

Worked Example — Comparing Two Functions

Let us rigorously determine the asymptotic relationship between f(n) = 3n² + 5n log n and g(n) = n² using the limit test and then verify the result via the formal definition.

Show that 3n² + 5n log n ∈ Θ(n²)
1
Step 1 — Set Up the LimitWe compute lim(n→∞) f(n)/g(n) = lim(n→∞) (3n² + 5n log n) / n². Dividing the numerator and denominator by n² gives lim(n→∞) (3 + 5 log n / n).
Ratio simplifies to 3 + 5(log n)/n
2
Step 2 — Evaluate the LimitSince log n grows slower than n (indeed, log n ∈ o(n)), the term 5(log n)/n → 0 as n → ∞. Therefore the limit equals 3 + 0 = 3.
L = 3, which satisfies 0 < L < ∞
3
Step 3 — Apply the Limit TestBecause the limit L is a finite positive constant, the limit test tells us that f(n) ∈ Θ(g(n)). Thus 3n² + 5n log n ∈ Θ(n²).
3n² + 5n log n ∈ Θ(n²)
4
Step 4 — Verify via Definition (Upper Bound)For the O bound: for n ≥ 1, log n ≤ n, so 5n log n ≤ 5n². Then f(n) = 3n² + 5n log n ≤ 3n² + 5n² = 8n². Choose c = 8 and n₀ = 1. Thus f(n) ≤ 8n² for all n ≥ 1, establishing f ∈ O(n²).
O bound: c = 8, n₀ = 1
5
Step 5 — Verify via Definition (Lower Bound)For the Ω bound: since 5n log n ≥ 0 for n ≥ 1, we have f(n) = 3n² + 5n log n ≥ 3n². Choose c = 3 and n₀ = 1. Thus f(n) ≥ 3n² for all n ≥ 1, establishing f ∈ Ω(n²).
Ω bound: c = 3, n₀ = 1
6
Step 6 — ConclusionSince f ∈ O(n²) and f ∈ Ω(n²), we have f ∈ Θ(n²). The lower-order term 5n log n does not affect the asymptotic class—it is absorbed into the quadratic growth.
f(n) = 3n² + 5n log n ∈ Θ(n²), confirmed by both the limit test and direct proof.

Strengths and Limitations of Asymptotic Analysis

Asymptotic notation is an extraordinarily powerful abstraction, but it is not without limitations. The table below surveys its strengths alongside the scenarios where a more nuanced analysis may be required.

Strengths and limitations of asymptotic growth-rate analysis
StrengthsLimitations
Machine-independent: results hold regardless of hardware or constant factors.Hides constant factors that may matter for practical input sizes (e.g., an O(n log n) algorithm with a huge constant can be slower than an O(n²) algorithm for small n).
Simplifies comparison: reduces complex expressions to canonical classes.Ignores lower-order terms that can dominate for moderate n.
Composable: Big-O and Θ obey useful algebraic rules (sum rule, product rule).Not all functions are comparable: there exist oscillating functions f and g where neither f ∈ O(g) nor g ∈ O(f).
Provides worst-case guarantees, essential for safety-critical systems.Worst-case may be rare; average-case or amortized analysis can be more informative.
🔍 CONTEXTUAL INSIGHT
Asymptotic analysis is analogous to choosing the right map scale for a journey. A world map (Big-O) tells you that New York is closer to London than to Tokyo—useful for planning a flight. But if you need to navigate city streets, you need a local map (exact running time, constant factors, cache behavior). Both scales are legitimate; the key is knowing when each is appropriate.

Connections to Complexity Theory and Beyond

Growth-rate classification extends naturally into computational complexity theory, where the classes P (problems solvable in polynomial time) and EXP (problems requiring exponential time) formalize the polynomial–exponential barrier into foundational categories of feasibility. The famous open question P vs. NP asks whether every problem whose solution can be verified in polynomial time can also be solved in polynomial time—a question that hinges entirely on growth-rate distinctions.

This LessonAdvanced Topic
Big-O, Big-Θ, Big-Ω for individual functionsComplexity classes P, NP, PSPACE, EXP as sets of decision problems grouped by growth of required resources
The polynomial–exponential barrierThe Cobham–Edmonds thesis: polynomial time ≈ tractable
Limit test using L'Hôpital's ruleMaster Theorem for divide-and-conquer recurrences; Akra–Bazzi method
Hierarchy: log n ≺ n ≺ n² ≺ 2ⁿTime Hierarchy Theorem: strictly more time yields strictly more computational power
Worst-case upper bound via Big-OAmortized analysis, expected-case analysis, smoothed complexity

Additionally, growth-rate analysis appears in combinatorics (estimating the growth of sequences such as Fibonacci numbers, Catalan numbers, or Bell numbers via Stirling-type asymptotics), in information theory (relating entropy to the growth of coding schemes), and in the study of generating functions where the radius of convergence directly reflects the exponential growth rate of a sequence's coefficients. Mastery of the hierarchy presented in this lesson is therefore a prerequisite for a wide array of advanced mathematics and theoretical computer science.

Practice Problems

PROBLEM 1CONCEPTUAL
Explain in your own words why 100n is O(n²) even though for all n < 100, the value 100n is actually larger than n². Does this contradict the definition of Big-O?
PROBLEM 2BASIC CALCULATION
Use the limit test to determine the asymptotic relationship between f(n) = 5n³ and g(n) = n² · log n. Is f ∈ O(g), f ∈ Θ(g), or g ∈ O(f)?
PROBLEM 3INTERMEDIATE
Prove from the definition that f(n) = 2n² + 3n + 1 ∈ Θ(n²). Explicitly state the constants c₁, c₂, and n₀.
PROBLEM 4APPLIED
Algorithm A runs in time T_A(n) = 50n log₂ n and Algorithm B runs in time T_B(n) = 2n². For what range of n is Algorithm A faster? Which algorithm should you choose for inputs of size n = 10,000?
PROBLEM 5CRITICAL THINKING
Let f(n) = n^(1 + 1/log n). Determine the asymptotic growth class of f. Is it polynomial? Is it super-polynomial? Compare it to n · c for any constant c > 1 and to n · (log n)^k for any constant k.

Summary

This lesson established a rigorous framework for comparing how functions grow as their inputs become large. We introduced three asymptotic notations— Big-O (upper bound), Big-Ω (lower bound), and Big-Θ (tight bound)—and the powerful limit test for determining which of these relationships holds between two functions. The standard growth hierarchy — from constant through logarithmic, polynomial, exponential, to factorial — provides a universal set of reference points for classifying any function's growth behavior.

Two critical barriers organize this hierarchy: the logarithmic–polynomial barrier (every polylogarithm is dominated by every positive power of n) and the polynomial–exponential barrier (every polynomial is dominated by every exponential). Mastery of these concepts is prerequisite for algorithm analysis, complexity theory, and many areas of combinatorics and applied mathematics. Remember that asymptotic notation captures eventual growth trends, deliberately ignoring constant factors and lower-order terms—a powerful simplification that must be applied thoughtfully.

Varsity Tutors • Discrete Math • Comparing Growth Rates and Common Function Classes