1 / 85

Tree Definitions and Operations: AVL, Binary Search Trees, Splay Trees, Optimal BST

Learn about the definitions and operations of trees, including AVL trees, binary search trees, splay trees, and optimal binary search trees. Discover pseudocode examples and the concept of amortized running time. Get ready for the upcoming test and participate actively in the course.

cbrenda
Download Presentation

Tree Definitions and Operations: AVL, Binary Search Trees, Splay Trees, Optimal BST

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Topic 10 Trees

  2. Tree Definitions

  3. Tree Definitions

  4. Tree Definitions

  5. Binary Search Tree

  6. Traversal • Operations tree

  7. Announcements • Participation 4 is up • Homework 3 grading • Homework 4 grading

  8. Search

  9. Insertion

  10. Deletion • Need • Min/max • Successor/predecessor

  11. Pseudocode

  12. Pseudocode

  13. AVL

  14. Height of AVL Tree

  15. Proof

  16. Insertion

  17. Example

  18. Single Right

  19. Left-Right

  20. Four cases

  21. Deletions

  22. Example

  23. Announcements • Test in 2 weeks • Participation due tomorrow • Clarification

  24. Splay Trees

  25. Amortized Running Time • Runtime:

  26. Basic Operations

  27. When to Splay

  28. Zig

  29. Zig-Zag

  30. Zig-zig

  31. Example

  32. Deletion

  33. Optimal BST

  34. Notation

  35. Example

  36. Example

  37. More Notation • (i,j) • (j+1, j)

More Related