Algorithm Design and Analysis

  1. Loop Invariants and Binary Search

    Prove a boundary-search algorithm by maintaining a half-open interval and separating correctness from termination.

    Undergraduate
  2. Termination Measures and Well-Founded Orders

    Prove progress with a measure in a well-founded order, including a lexicographic example where one counter increases.

    Undergraduate
  3. Asymptotic Bounds and Input Models

    Interpret running-time bounds with several input parameters and account for the encoding length of numeric inputs.

    Undergraduate
  4. Recursion Trees and Level Costs

    Expand a recurrence by level and account for both the per-level work and the number of leaves.

    Undergraduate
  5. The Master Theorem and Its Conditions

    Derive the level ratio for balanced divide and conquer, then see when an extra logarithm defeats the elementary three cases.

    Undergraduate
  6. The Potential Method for Amortized Analysis

    Choose a stored-work potential and use telescoping to bound the expense of a complete operation sequence.

    Undergraduate
  7. Aggregate and Accounting Amortized Analysis

    Bound a sequence of stack operations by counting how often costly work can happen, then interpret the bound as stored credit.

    Undergraduate
  8. Comparison Decision Trees and Sorting Lower Bounds

    Count distinguishable input orders to obtain a sorting lower bound and identify the computational model that makes it apply.

    Undergraduate
  9. Deterministic Selection by Median of Medians

    Prove a linear worst-case bound for selection by using a pivot with a guaranteed fraction of smaller and larger elements.

    Undergraduate
  10. Three-Way Partitioning and Duplicate Keys

    Maintain four regions around a pivot and explain why the element swapped in from the right still needs inspection.

    Undergraduate
  11. Greedy Algorithms and Exchange Proofs

    Prove earliest-finish interval scheduling by transforming an optimal schedule, then identify the assumption that fails with weights.

    Undergraduate
  12. Designing Sufficient Dynamic Programming States

    Design a state that preserves the information needed by future choices and derive a recurrence from the last decision.

    Undergraduate
  13. Pseudopolynomial Dynamic Programming

    Work through the 0–1 subset sum recurrence and see how a loop direction can turn a bounded item into an unlimited one.

    Undergraduate
  14. Word-Parallel Dynamic Programming with Bitsets

    Pack subset reachability into words, explain why shifting moves many states at once, and account for boundaries in the representation.

    Undergraduate
  15. Meet-in-the-Middle Search

    Split an exponential search into two independently enumerable halves and turn pair enumeration into a lookup.

    Undergraduate
  16. Designing and Verifying Reductions

    Write reductions as algorithms on instances, prove both directions, and inspect how output size affects transferred guarantees.

    Undergraduate
  17. Certificates, Verification, and NP-Completeness

    Distinguish short verifiable witnesses from search costs and prove a simple reduction to a dual graph property.

    Undergraduate
  18. Counting Sort, Stability, and Radix Passes

    Derive the destination intervals of a stable counting sort and use stability to justify multi-digit ordering.

    Undergraduate
  19. Substitution Proofs for Recurrence Bounds

    Choose an inductive bound with enough slack to absorb additive work and handle uneven recursion without an exact closed form.

    Undergraduate
  20. Bit Complexity and Arithmetic Cost

    Track the size of intermediate integers and compare arithmetic operation counts with the cost of actually representing their results.

    Undergraduate