Question

(15 pts) 1. Create the recursion tree for the recurrence T(n)-T(2n/5)T3n/5) O(n). Show total complexity

0 0
Add a comment Improve this question Transcribed image text
Answer #1

Recursion trees can be useful for gaining intuition about the closed form of a recurrence, but they are not a proof

Recursion Tree for the recurrence

T(n)=T(\frac{2n}{5})+T(\frac{3n}{5})+O(n)

can be shown as,

Starting the root as, n, then expnading out to the first level be

Similarly expanding the above tree for further more levels gives,

Note that the tree here is not balanced: the longest path is the rightmost one, and its length is log5/3 n.

Hence our guess for the closed form of complexity of this recurrence is O(n log n).

Add a comment
Know the answer?
Add Answer to:
(15 pts) 1. Create the recursion tree for the recurrence T(n)-T(2n/5)T3n/5) O(n). Show total complexity
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT