We have a function $T(n)$ defined by $T(1) =1$ and $T(n)=3T(\lfloor n/2\rfloor)+n$ for $n > 1$. We need to show that $T(2^n)=\Theta (3^n)$. How should I approach this question? Any suggestion?
Asked
Active
Viewed 440 times
1 Answers
1
First of all, try to solve the recurrence relation using the master method.
Since $f(n) = O(n^{\log_2 3 - \epsilon})$ for some $\epsilon$, this is the first case of the master method. Therefore $$T(n) = \Theta(n^{\log_2 3})$$
If you replace $n$ by $2^n$, you will get your answer. i.e. $$T(2^n) = \Theta(2^{n\log_2 3}) = \Theta(3^n)$$

Bibek Subedi
- 126
- 3
-
if T(n) = $\Theta(n^{\log_2 3})$, then $T(2^n)$ shouldn't be \begin{equation} $ \Theta(2^{n^{\log_2 3}}) \end{equation} – CCOthers Oct 02 '18 at 07:46
-
Use the power rule. http://www.math.com/school/subject2/lessons/S2U2L2DP.html – Bibek Subedi Oct 02 '18 at 08:34