Overview
In chapter 24 we discuss probabilistic algorithms. We begin the chapter by defining the
concepts of expected worst-case, best-case and average complexities, Wexp(n), Bexp(n) and
Aexp(n), respectively. We then discuss the technique of randomizing deterministic
algorithms to cause the expected worst-case behavior of the algorithm for any fixed input
to approach the average behavior of the deterministic algorithm, and illustrate this
technique for the algorithms LinearSearch, ProbLinSrch, and Quicksort.
Following our discussion of randomizing deterministic algorithms, we introduce the two
important types of probabilistic algorithms known as Monte Carlo and Las Vegas
algorithms; a Monte Carlo algorithm has a certain probability of returning the correct
answer whatever input is considered, whereas, a Las Vegas algorithm never returns an
estimating the size of sets. We finish the chapter with a discussion of probabilistic
parallel and distributed algorithms, including the design of a parallel algorithm for the so-
called marriage problem and a randomized protocol for breaking deterministic deadlock.
Chapter Objectives
After completing the chapter the student will know: