< Day Day Up > |
What has changed between the first and second editions of this book? Depending on how you look at it, either not much or quite a bit.
A quick look at the table of contents shows that most of the first-edition chapters and sections appear in the second edition. We removed two chapters and a handful of sections, but we have added three new chapters and four new sections apart from these new chapters. If you were to judge the scope of the changes by the table of contents, you would likely conclude that the changes were modest.
The changes go far beyond what shows up in the table of contents, however. In no particular order, here is a summary of the most significant changes for the second edition:
Cliff Stein was added as a coauthor.
Errors have been corrected. How many errors? Let's just say several.
There are three new chapters:
Chapter 1 discusses the role of algorithms in computing.
Chapter 5 covers probabilistic analysis and randomized algorithms. As in the first edition, these topics appear throughout the book.
Chapter 29 is devoted to linear programming.
Within chapters that were carried over from the first edition, there are new sections on the following topics:
perfect hashing (Section 11.5),
two applications of dynamic programming (Sections 15.1 and 15.5), and
approximation algorithms that use randomization and linear programming (Section 35.4).
To allow more algorithms to appear earlier in the book, three of the chapters on mathematical background have been moved from Part I to the Appendix, which is Part VIII.
There are over 40 new problems and over 185 new exercises.
We have made explicit the use of loop invariants for proving correctness. Our first loop invariant appears in Chapter 2, and we use them a couple of dozen times throughout the book.
Many of the probabilistic analyses have been rewritten. In particular, we use in a dozen places the technique of "indicator random variables," which simplify probabilistic analyses, especially when random variables are dependent.
We have expanded and updated the chapter notes and bibliography. The bibliography has grown by over 50%, and we have mentioned many new algorithmic results that have appeared subsequent to the printing of the first edition.
We have also made the following changes:
The chapter on solving recurrences no longer contains the iteration method. Instead, in Section 4.2, we have "promoted" recursion trees to constitute a method in their own right. We have found that drawing out recursion trees is less error-prone than iterating recurrences. We do point out, however, that recursion trees are best used as a way to generate guesses that are then verified via the substitution method.
The partitioning method used for quicksort (Section 7.1) and the expected linear-time order-statistic algorithm (Section 9.2) is different. We now use the method developed by Lomuto, which, along with indicator random variables, allows for a somewhat simpler analysis. The method from the first edition, due to Hoare, appears as a problem in Chapter 7.
We have modified the discussion of universal hashing in Section 11.3.3 so that it integrates into the presentation of perfect hashing.
There is a much simpler analysis of the height of a randomly built binary search tree in Section 12.4.
The discussions on the elements of dynamic programming (Section 15.3) and the elements of greedy algorithms (Section 16.2) are significantly expanded. The exploration of the activity-selection problem, which starts off the greedy-algorithms chapter, helps to clarify the relationship between dynamic programming and greedy algorithms.
We have replaced the proof of the running time of the disjoint-set-union data structure in Section 21.4 with a proof that uses the potential method to derive a tight bound.
The proof of correctness of the algorithm for strongly connected components in Section 22.5 is simpler, clearer, and more direct.
Chapter 24, on single-source shortest paths, has been reorganized to move proofs of the essential properties to their own section. The new organization allows us to focus earlier on algorithms.
Section 34.5 contains an expanded overview of NP-completeness as well as new NP-completeness proofs for the hamiltonian-cycle and subset-sum problems.
Finally, virtually every section has been edited to correct, simplify, and clarify explanations and proofs.
< Day Day Up > |