I followed this theorem to solve it:
My solution to this problem: 9T(n/2)+n^3 was theta(n^log base 2 (9)), is it correct? If not, why?
Thanks in advance!
Can someone help me with (b) and (c). I really don't know how to solve it, whether using substitution or recurrence tree method. Master theorem doesn't seem to work here either. Thanks.
I'm having problems calculating the complexity of the following recurrence equation.
It's quite difficult for me to solve it. Could anyone help me to solve this problem? Thanks in advance.
This is the same recurrence for the average case complexity of quicksort with solution
T(n)=O(n log n)
derivation here
I need to solve this problem with induction k in natural numbers
So how I write this problem in wolfram Engine ?
I wonder if it is correct. Does the leading point mean something?
How do you calculate time complexity in case of recursion algorithms?
for eg t(n) = t(3n/2) + 0(1) (Heapsort)
Use the Master Theorem.
Anyway, your equation looks broken, since recursive calls have higher input values than that of the caller, so your complexity is O(infinity).
Please fix it.
Master's theorm is the quick and short way. But since you are trying to learn the complexity for all recursive functions, I would rather suggest you to learn the working of recursion tree, which forms the foundation of Master's Theorm . This link goes on to explain it in detail. Rather than using the Master's theorm blindly, learn this for your better understanding in the future ! This link about recursion tree is a good read too
usually you can guess the answer and use induction to prove it.
but there is a theorem which solves a lot of situations as heap sort, named Master Theorem:
http://en.wikipedia.org/wiki/Master_theorem
Complexity of Heapsort