Master Theorem
Understand the master theorem used to solve recurrence relations in algorithms. This lesson explains how to apply its three cases to find tight bounds on time complexity, helping you analyze recursive algorithms effectively.
We'll cover the following...
Master Theorem
By definition, the master theorem is used to solve recurrence relations. It is stated as = + where, a ≥ 1 and b > 1. In this relation, is the size of the input and is the number of subproblems in the recursion. is the factor by which the size of the subproblem is reduced in each recursive call. Lastly, is the cost of dividing the problem into subproblems and merging the individual solutions of the subproblems into the solution.
We generally have three cases in the master theorem. In other words, we determine an asymptotic tight bound in the following three ...