Chapter 2: Problem 18
When a divide-and-conquer algorithm divides an instance of size \(n\) of a problem into subinstances each of size \(n / c,\) the recurrence relation is typically given by \\[\begin{array}{l}T(n)=a T\left(\frac{n}{c}\right)+g(n) \quad \text { for } n>1 \\ T(1)=d\end{array}\\] where \(g(n)\) is the cost of the dividing and combining processes, and \(d\) is a constant. Let \(n=c^{k}\) a. Show that \\[T\left(c^{k}\right)=d \times a^{k}+\sum_{j=1}^{k}\left[a^{k-j} \times g\left(c^{j}\right)\right]\\] b. Solve the recurrence relation given that \(g(n) \in \Theta(n)\)
Short Answer
Step by step solution
Key Concepts
These are the key concepts you need to understand to accurately answer the question.