Sciweavers

SIAMCOMP
2002

On Binary Searching with Nonuniform Costs

13 years 10 months ago
On Binary Searching with Nonuniform Costs
Let us consider an ordered vector A[1 : n]. If the cost of testing each position is similar, then the standard binary search is the best strategy to search the vector. This is true in both the average and worst case. However, if the costs are nonuniform, then the best strategy is not necessarily the standard binary search. The best algorithm to construct a strategy that minimizes the expected search cost runs in O(n3) time and requires O(n2) space. The same complexities hold for the best algorithm to construct a strategy that minimizes the worst case search cost. Here, we show how to efficiently construct search strategies that are at most at a constant factor from the optimal one. These constructions take linear time and use only linear space. For both the problem of minimizing the expected search cost, under uniform access probabilities, and the problem of minimizing the worst case search cost, we present algorithms that require O(n) space and give a (2 + + o(1))-approximated solutio...
Eduardo Sany Laber, Ruy Luiz Milidiú, Artur
Added 23 Dec 2010
Updated 23 Dec 2010
Type Journal
Year 2002
Where SIAMCOMP
Authors Eduardo Sany Laber, Ruy Luiz Milidiú, Artur Alves Pessoa
Comments (0)