TY - JOUR
T1 - An optimal algorithm for finding all the jumps of a monotone step-function
AU - Hassin, Refael
AU - Megiddo, Nimrod
N1 - Funding Information:
San Jose, Calif. 95193. The work Science Foundation Grants ECS-8121741
PY - 1985/6
Y1 - 1985/6
N2 - The idea of binary search is generalized as follows. Given f{hook}: {0, 1,..., N} → {0,..., K} such that f{hook}(0) = 0, f{hook}(N) = K, and f{hook}(i) ≤ f{hook}(j) for i < j, all the "jumps" of f, i.e., all is such that f{hook}(i) > f{hook}(i - 1) together with the difference f{hook}(i) - f{hook}(i - 1) are recognized within K[log2( N K)] + [(N - 1)2-[log2( N K)]]f-evaluations. This is proved to be the exact bound in the non-trivial case when K ≤ N. An optimal strategy is as follows: The first query will be at i = 2m, where m = [log2( N K)]. An adversary will then respond either f{hook}(i) = 0 or f{hook}(i) - 1 as explained in the paper.
AB - The idea of binary search is generalized as follows. Given f{hook}: {0, 1,..., N} → {0,..., K} such that f{hook}(0) = 0, f{hook}(N) = K, and f{hook}(i) ≤ f{hook}(j) for i < j, all the "jumps" of f, i.e., all is such that f{hook}(i) > f{hook}(i - 1) together with the difference f{hook}(i) - f{hook}(i - 1) are recognized within K[log2( N K)] + [(N - 1)2-[log2( N K)]]f-evaluations. This is proved to be the exact bound in the non-trivial case when K ≤ N. An optimal strategy is as follows: The first query will be at i = 2m, where m = [log2( N K)]. An adversary will then respond either f{hook}(i) = 0 or f{hook}(i) - 1 as explained in the paper.
UR - https://www.scopus.com/pages/publications/0013446487
U2 - 10.1016/0196-6774(85)90043-4
DO - 10.1016/0196-6774(85)90043-4
M3 - ???researchoutput.researchoutputtypes.contributiontojournal.article???
AN - SCOPUS:0013446487
SN - 0196-6774
VL - 6
SP - 265
EP - 274
JO - Journal of Algorithms
JF - Journal of Algorithms
IS - 2
ER -