Traditional tree search algorithms supply a blueprint for modeling problem solving behaviour. A diverse spectrum of problems can be formulated in terms of tree search. Quantum computation, in particular Grover's algorithm, has aroused a great deal of interest since it allows for a quadratic speedup to be obtained in search procedures. In this work we consider the impact of incorporating classical search concepts alongside Grover's algorithm into a hybrid quantum search system. Some of the crucial points examined include: (1) the reverberations of contemplating the use of non-constant branching factors; (2) determining the consequences of incorporating an heuristic perspective into a quantum tree search model.
We consider the design of adaptive data structures for searching elements of a tree-structured space. We use a natural generalization of the rotation-based online binary search tree model in which the underlying search space is the set of vertices of a tree. This model is based on a simple structure for decomposing graphs, previously known under several names including elimination trees, vertex rankings, and tubings. The model is equivalent to the classical binary search tree model exactly when the underlying tree is a path. We describe an online $O(\log \log n)$-competitive search tree data s…
Search trees are commonly used to implement access operations to a set of stored keys. If this set is static and the probabilities of membership queries are known in advance, then one can precompute an optimal search tree, namely one that minimizes the expected access cost. For a non-key query, a search tree can determine its approximate location by returning the inter-key interval containing the query. This is in contrast to other dictionary data structures, like hash tables, that only report a failed search. We address the question "what is the additional cost of determining approximate loca…
In this paper we generalize the definition of "Search Trees" (ST) to enable reference values other than the key of prior inserted nodes. The idea builds on the assumption an $n$-node AVL (or Red-Black) requires to assure $O(\log_2n)$ worst-case search time, namely, a single comparison between two keys takes constant time. This means the size of each key in bits is fixed to $B=c\log_2 n$ ($c\geq1$) once $n$ is determined, otherwise the $O(1)$-time comparison assumption does not hold. Based on this we calculate \emph{ideal} reference values from the mid-point of the interval $0..2^B$. This idea …
We present a method that maintains a balanced binary search tree without using any tree balance criterion at all, with the ultimate aim of maximum simplicity. In fact, our method is highly intuitive, and we only need to add minimal extra code and a simple partial-rebuilding algorithm to a naive binary search tree. Our method will be suitable as a highly simple and short solution when amortized logarithmic costs are enough.
We suggest a new non-recursive algorithm for constructing a binary search tree given an array of numbers. The algorithm has $O(N)$ time and $O(1)$ memory complexity if the given array of $N$ numbers is sorted. The resulting tree is of minimal height and can be transformed to a complete binary search tree (retaining minimal height) with $O(\log N)$ time and $O(1)$ memory. The algorithm allows simple and effective parallelization.
It is shown that the online binary search tree data structure GreedyASS performs asymptotically as well on a sufficiently long sequence of searches as any static binary search tree where each search begins from the previous search (rather than the root). This bound is known to be equivalent to assigning each item $i$ in the search tree a positive weight $w_i$ and bounding the search cost of an item in the search sequence $s_1,\ldots,s_m$ by $$O\left(1+ \log \frac{\displaystyle \sum_{\min(s_{i-1},s_i) \leq x \leq \max(s_{i-1},s_i)}w_x}{\displaystyle \min(w_{s_i},w_{s_{i-1}})} \right)$$ amortize…
We present a study of several generic tree search techniques applied to the Sequential Ordering Problem. This study enables us to propose a simple and competitive tree search algorithm. It consists of an iterative Beam Search algorithm that favors search over inference and integrates dynamic programming inspired cuts. It proves optimality on half of the SOPLIB instances and finds new best known solutions on 6 among 7 open instances of the benchmark in a small amount of time.
在本文中,我们研究的问题是否静态搜索树应该是不平衡的。我们提出了几种方法来重建一个不平衡的k元搜索树$T$到一个新的树$R$,保留了$T$的许多属性,同时具有高度的$\log_k n +1$,这是一个单位的最佳高度。更具体地说,我们表明,它是可能的,以确保$R$中的元素的深度不超过其深度在$T$加上最多$\log_k \log_k n +2$。同时,可以保证树$R$中的平均访问时间$P(R)$不大于树$T$中的平均访问时间$P(T)$加上$O(\log_k P(T))$。这表明,对于大多数应用程序,平衡树总是比不平衡树更好的选择,因为平衡树具有相似的平均访问时间和更好的最坏情况访问时间。
Using (a,b)-trees as an example, we show how to perform a parallel split with logarithmic latency and parallel join, bulk updates, intersection, union (or merge), and (symmetric) set difference with logarithmic latency and with information theoretically optimal work. We present both asymptotically optimal solutions and simplified versions that perform well in practice - they are several times faster than previous implementations.
The next-generation non-volatile memory (NVM) is striding into computer systems as a new tier as it incorporates both DRAM's byte-addressability and disk's persistency. Researchers and practitioners have considered building persistent memory by placing NVM on the memory bus for CPU to directly load and store data. As a result, cache-friendly data structures have been developed for NVM. One of them is the prevalent B+-tree. State-of-the-art in-NVM B+-trees mainly focus on the optimization of write operations (insertion and deletion). However, search is of vital importance for B+-tree. Not only …
An optimal binary search tree for an access sequence on elements is a static tree that minimizes the total search cost. Constructing perfectly optimal binary search trees is expensive so the most efficient algorithms construct almost optimal search trees. There exists a long literature of constructing almost optimal search trees dynamically, i.e., when the access pattern is not known in advance. All of these trees, e.g., splay trees and treaps, provide a multiplicative approximation to the optimal search cost. In this paper we show how to maintain an almost optimal weighted binary search tree …
We present linear-time algorithms for partitioning a path or a tree with weights on the vertices by removing $k$ edges to maximize the minimum-weight component. We also use the same framework to partition a path with weight on the vertices, removing $k$ edges to minimize the maximum-weight component. The algorithms use the parametric search paradigm, testing candidate values until an optimum is found while simultaneously reducing the running time needed for each test. For path-partitioning, the algorithm employs a synthetic weighting scheme that results in a constant fraction reduction in runn…
We present a simple $O(n^4)$-time algorithm for computing optimal search trees with two-way comparisons. The only previous solution to this problem, by Anderson et al., has the same running time, but is significantly more complicated and is restricted to the variant where only successful queries are allowed. Our algorithm extends directly to solve the standard full variant of the problem, which also allows unsuccessful queries and for which no polynomial-time algorithm was previously known. The correctness proof of our algorithm relies on a new structural theorem for two-way-comparison search …
We consider a natural notion of search trees on graphs, which we show is ubiquitous in various areas of discrete mathematics and computer science. Search trees on graphs can be modified by local operations called rotations, which generalize rotations in binary search trees. The rotation graph of search trees on a graph $G$ is the skeleton of a polytope called the graph associahedron of $G$. We consider the case where the graph $G$ is a tree. We construct a family of trees $G$ on $n$ vertices and pairs of search trees on $G$ such that the minimum number of rotations required to transform one se…
A tree $t$-spanner $T$ of a graph $G$ is a spanning tree of $G$ such that the distance in $T$ between every pair of verices is at most $t$ times the distance in $G$ between them. There are efficient algorithms that find a tree $t\cdot O(\log n)$-spanner of a graph $G$, when $G$ admits a tree $t$-spanner. In this paper, the search space is narrowed to $v$-concentrated spanning trees, a simple family that includes all the breadth first search trees starting from vertex $v$. In this case, it is not easy to find approximate tree spanners within factor almost $o(\log n)$. Specifically, let $m$ and …
工作集界限[Sleator and Tarjan,J. ACM,1985]粗略地指出,如果元素最近被访问过,则搜索该元素的速度很快。二叉搜索树,例如splay树,可以在摊销意义上实现此属性,而已知不是二叉搜索树的数据结构在最坏情况下具有此属性。我们关闭这个差距,并提出了一个二叉搜索树称为分层工作集树,保证在最坏的情况下的工作集属性。统一边界[Badoiu等人,TCS,2007]粗略地说,如果一个元素靠近(就秩距离而言)最近访问的元素,则搜索该元素是快速的。我们展示了如何分层的工作集树可以用来实现统一的绑定到一个小的加法项在摊销的意义上,同时保持在最坏的情况下的访问时间是对数和一个小的乘法因子的工作集的范围内。
A treap is a classic randomized binary search tree data structure that is easy to implement and supports O(\log n) expected time access. However, classic treaps do not take advantage of the input distribution or patterns in the input. Given recent advances in algorithms with predictions, we propose pairing treaps with machine advice to form a learning-augmented treap. We are the first to propose a learning-augmented data structure that supports binary search tree operations such as range-query and successor functionalities. With the assumption that we have access to advice from a frequency est…
In 1971, Knuth gave an $O(n^2)$-time algorithm for the classic problem of finding an optimal binary search tree. Knuth's algorithm works only for search trees based on 3-way comparisons, while most modern computers support only 2-way comparisons (e.g., $<, \le, =, \ge$, and $>$). Until this paper, the problem of finding an optimal search tree using 2-way comparisons remained open -- poly-time algorithms were known only for restricted variants. We solve the general case, giving (i) an $O(n^4)$-time algorithm and (ii) an $O(n \log n)$-time additive-3 approximation algorithm. Also, for finding op…
We present a new fast all-pairs shortest path algorithm for unweighted graphs. In breadth-first search which is said to representative and fast in unweighted graphs, the average number of accesses to adjacent vertices (expressed by α) is about equal to the average degree of the graph. On the other hand, our algorithm utilizes the shortest path trees of adjacent vertices of each source vertex, and reduce α drastically. Roughly speaking α is reduced to the value close to 1, because the average degree of a tree is about 2, and one is used to come in and the other is used to go out, although that …
We present a technique that allows for improving on some relative greedy procedures by well-chosen (non-oblivious) local search algorithms. Relative greedy procedures are a particular type of greedy algorithm that start with a simple, though weak, solution, and iteratively replace parts of this starting solution by stronger components. Some well-known applications of relative greedy algorithms include approximation algorithms for Steiner Tree and, more recently, for connectivity augmentation problems. The main application of our technique leads to a $(1.5+ε)$-approximation for Weighted Tree Au…
Search trees on trees (STTs) generalize the fundamental binary search tree (BST) data structure: in STTs the underlying search space is an arbitrary tree, whereas in BSTs it is a path. An optimal BST of size $n$ can be computed for a given distribution of queries in $O(n^2)$ time [Knuth 1971] and centroid BSTs provide a nearly-optimal alternative, computable in $O(n)$ time [Mehlhorn 1977]. By contrast, optimal STTs are not known to be computable in polynomial time, and the fastest constant-approximation algorithm runs in $O(n^3)$ time [Berendsohn, Kozma 2022]. Centroid trees can be defined for…
Recently Avis and Jordan have demonstrated the efficiency of a simple technique called budgeting for the parallelization of a number of tree search algorithms. The idea is to limit the amount of work that a processor performs before it terminates its search and returns any unexplored nodes to a master process. This limit is set by a critical budget parameter which determines the overhead of the process. In this paper we study the behaviour of the budget parameter on conditional Galton-Watson trees obtaining asymptotically tight bounds on this overhead. We present empirical results to show that…
Ordered set (and map) is one of the most used data type. In addition to standard set operations, like insert, delete and contains, it can provide set-set operations such as union, intersection, and difference. Each of these set-set operations is equivalent to batched operations: the data structure should process a set of operations insert, delete, and contains. It is obvious that we want these "large" operations to be parallelized. Typically, these sets are implemented with the trees of logarithmic height, such as 2-3 tree, Treap, AVL tree, Red-Black tree, etc. Until now, little attention was …
The Binary Search Tree (BST) is average in computer science which supports a compact data structure in memory and oneself even conducts a row of quick algorithms, by which people often apply it in dynamical circumstance. Besides these edges, it is also with weakness on its own structure specially with poor performance at worst case. In this paper, we will develop this data structure into a synthesis to show a series of novel features residing in. Of that, there are new methods invented for raising the performance and efficiency nevertheless some existing ones in logarithm or linear time.
Jet Propulsion Laboratory, California Institute of Technology(喷气推进实验室,加州理工学院)
K-Nearest Neighbors (KNN) search is a fundamental algorithm in artificial intelligence software with applications in robotics, and autonomous vehicles. These wide-ranging applications utilize KNN either directly for simple classification or combine KNN results as input to other algorithms such as Locally Weighted Learning (LWL). Similar to binary trees, kd-trees become unbalanced as new data is added in online applications which can lead to rapid degradation in search performance unless the tree is rebuilt. Although approximate methods are suitable for graphics applications, which prioritize q…
We consider the cost of general orthogonal range queries in random quadtrees. The cost of a given query is encoded into a (random) function of four variables which characterize the coordinates of two opposite corners of the query rectangle. We prove that, when suitably shifted and rescaled, the random cost function converges uniformly in probability towards a random field that is characterized as the unique solution to a distributional fixed-point equation. We also state similar results for $2$-d trees. Our results imply for instance that the worst case query satisfies the same asymptotic esti…