Analytic derivation of comparisons in binary search

  title={Analytic derivation of comparisons in binary search},
  author={Timothy J. Rolfe},
  journal={ACM Signum Newsletter},
  • T. Rolfe
  • Published 1 October 1997
  • Computer Science
  • ACM Signum Newsletter
Numerous authors of programming texts and algorithms / data structures texts develop code for the binary search. The common implementation is one in which the loop contains two comparisons for three outcomes --- the key is to the left of the midpoint, to the right of the midpoint, or exactly at the midpoint --- Implementation A below. 

Figures from this paper

Quantifying the parallelism in BPMN processes using model checking
This paper presents a formal model for BPMN processes in terms of Labelled Transition Systems, which are obtained through process algebra encodings and proposes an approach for automatically computing the degree of parallelism by using model checking techniques and dichotomic search.
A cautionary tale: false efficiencies in the traveling salesman problem
The Traveling Salesman Problem provides an opportunity to explore whether attempts to optimize an algorithm in fact succeed or fail, and two such functions are examined, of which one slows the program and the other neither slows nor speeds the program.
Spreadsheet-aided numerical experimentation: analytic formula for Fibonacci numbers
A very simple recurrence is used for which the analytic solution is quite obvious when one examines the values generated by the recurrence, and then examines another recurrence forwhich the solution is not obvious.