Plays from YouTube. Watch on YouTube
Why can two recursive algorithms with the same number of calls have different runtimes?
Meet Recurrences and Recursive Runtime: an animated exploration of mathematical recursion and its proof techniques.
We start by deriving recurrence equations from subproblem sizes and nonrecursive work.
From there, we compare binary search, merge sort, factorial, Fibonacci and quicksort.
Then we separate recursion depth, operation count, bit complexity and exact versus upper-bound recurrences.
The big idea: sound recursive reasoning makes the smaller dependencies and the combining argument explicit.
Computer science and mathematics explained visually, one worked example at a time.