← Student tools · Problem 17 · Lecture 9 · Round 2 (30 pts)

Growth-rate race · log n vs n² vs 2ⁿ

Six complexity functions race; pinpoint where exponential overtakes polynomial.

CLO-3R2·30 ptsL9
🔊 Listen

Complexity is about how time grows with input size, not about absolute speed. The race here puts six canonical growth rates side by side so you can watch which ones stay manageable and which explode.

Big-O totals at n = 40

log n ≈ 5 · n = 40 · n log n ≈ 213 · n² = 1,600 · n³ = 64,000 · 2ⁿ ≈ 1012.

The gap between n³ and 2ⁿ at n = 40 is already roughly fifteen million-fold; by n = 60 it's a trillion-fold; by n = 100, the heat death of the universe doesn't see the end of 2ⁿ operations.

🔊 Listen
When does 2ⁿ overtake n^k? Where is the crossover point? polynomial crossover with 2ⁿ interpretation n around n = 1 2ⁿ wins basically immediately around n = 4 2⁴ = 16 vs 4² = 16, then 2ⁿ pulls away around n = 10 2¹⁰ = 1024 vs 10³ = 1000, then 2ⁿ doubles each step n¹⁰ around n = 60 even n¹⁰ loses eventually — exponential always wins 2ⁿ always beats every polynomial in the long run The asymmetry is structural: doubling forever beats multiplying by any fixed constant ratio. P captures "polynomial wins"; EXPTIME captures "exponential is acceptable."
🔊 Listen

Suppose you have an algorithm that runs in 10⁻⁹ × T(n) seconds (one nanosecond per operation). How big a problem can you solve in one second of CPU time?

This is why P is the working definition of "feasible" — polynomial-time algorithms scale; exponential-time ones do not.

🔊 Listen
Six curves race Auto-plays
🔊 Listen
🔊 Listen

Sipser: §7.1 (Big-O), §7.2 (P). Lecture notes: Module 4 slide 1 has the same race; slide 2 covers Big-O formally. Companion problems: P18 (single-tape 0ⁿ1ⁿ — concrete O(n²) example), P20 (Big-O classifier), P24 (P showcase — natural P algorithms).