Announcements:
PA2 due 03/09. MT2 03/04.
Today: AVL analysis, BTrees https://cs221viz.netlify.com/src/avl AVL tree analysis:
Since running times for Insert, Remove and Find are O(___), we’ll argue that h = O(______). Putting an upper bound on the height for a tree of n nodes is the same as putting a lower bound on the number of nodes in a tree of height h.
- Define N(h): least # of nodes in AVL tree of ht h
- Find a recurrence for N(h): N(h) = 1 + N(____) + N (____)
- We simplify the recurrence:
- Solve the recurrence: (guess a closed form)