Efficient top-down updates in AVL trees

Vincent Jugé
2024-11-14
Abstract:Since AVL trees were invented in 1962, two major open questions about rebalancing operations, which found positive answers in other balanced binary search trees, were left open: can these operations be performed top-down (with a fixed look-ahead), and can they use an amortised constant number of write operations per update? We propose an algorithm that answers both questions positively.
Data Structures and Algorithms
What problem does this paper attempt to address?
### What problems does this paper attempt to solve? This paper aims to solve two major open problems in AVL tree during update operations (insertion and deletion): 1. **Top - down update operations**: Is it possible to perform top - down update operations with a fixed look - ahead? Traditional AVL tree update operations are usually bottom - up, which requires recursive calls or using a stack to store visited nodes, increasing complexity and cost. Therefore, top - down update can significantly improve efficiency. 2. **Amortized constant - time complexity of write operations**: Can each update operation use only a constant number of write operations in the amortized sense? Traditional AVL tree update operations may trigger a large number of rotations or write operations, resulting in a high time complexity. These problems have been positively answered in other balanced binary search trees (such as weight - balanced trees, red - black trees, semi - balanced trees, etc.), but have remained unsolved in AVL trees. This paper proposes an algorithm that can solve both problems simultaneously, making AVL tree update operations more efficient. ### Specific goals - **Top - down update algorithm**: Design a top - down algorithm that can perform insertion and deletion operations with a fixed look - ahead. - **Amortized constant - time complexity**: Ensure that the number of write operations for each update operation is at a constant level in the amortized sense, thereby improving the update efficiency of the AVL tree. By solving these problems, this paper not only improves the performance of the AVL tree, but also provides new ideas and methods for the research of other related data structures. ### Main contributions of the paper 1. **Proposed a top - down update algorithm** that can perform insertion and deletion operations with a fixed look - ahead. 2. **Proved that the amortized complexity of this algorithm is constant**, that is, each update operation only requires a constant number of write operations. 3. **Combined the advantages of bottom - up and top - down** and proposed a comprehensive algorithm to further optimize the update performance of the AVL tree. These contributions make the AVL tree more efficient in practical applications, especially in distributed environments, reducing lock contention and update latency problems.