Preview of Methods in Algorithmic Analysis
Preview of Methods in Algorithmic Analysis
Algorithmic Analysis
CHAPMAN & HALL/CRC
COMPUTER and INFORMATION SCIENCE SERIES
PUBLISHED TITLES
ADVERSARIAL REASONING: COMPUTATIONAL APPROACHES HANDBOOK OF PARALLEL COMPUTING: MODELS,
TO READING THE OPPONENT’S MIND ALGORITHMS AND APPLICATIONS
Alexander Kott and William M. McEneaney Sanguthevar Rajasekaran and John Reif
DISTRIBUTED SENSOR NETWORKS HANDBOOK OF REAL-TIME AND EMBEDDED SYSTEMS
S. Sitharama Iyengar and Richard R. Brooks Insup Lee, Joseph Y-T. Leung, and Sang H. Son
DISTRIBUTED SYSTEMS: AN ALGORITHMIC APPROACH HANDBOOK OF SCHEDULING: ALGORITHMS, MODELS,
Sukumar Ghosh AND PERFORMANCE ANALYSIS
Joseph Y.-T. Leung
ENERGY EFFICIENT HARDWARE-SOFTWARE
CO-SYNTHESIS USING RECONFIGURABLE HARDWARE HIGH PERFORMANCE COMPUTING IN REMOTE SENSING
Jingzhao Ou and Viktor K. Prasanna Antonio J. Plaza and Chein-I Chang
FUNDEMENTALS OF NATURAL COMPUTING: BASIC INTRODUCTION TO NETWORK SECURITY
CONCEPTS, ALGORITHMS, AND APPLICATIONS Douglas Jacobson
Leandro Nunes de Castro
METHODS IN ALGORITHMIC ANALYSIS
HANDBOOK OF ALGORITHMS FOR WIRELESS Vladimir A. Dobrushkin
NETWORKING AND MOBILE COMPUTING
Azzedine Boukerche PERFORMANCE ANALYSIS OF QUEUING AND COMPUTER
NETWORKS
HANDBOOK OF APPROXIMATION ALGORITHMS G. R. Dattatreya
AND METAHEURISTICS
Teofilo F. Gonzalez THE PRACTICAL HANDBOOK OF INTERNET COMPUTING
Munindar P. Singh
HANDBOOK OF BIOINSPIRED ALGORITHMS
AND APPLICATIONS SCALABLE AND SECURE INTERNET SERVICES AND
Stephan Olariu and Albert Y. Zomaya ARCHITECTURE
Cheng-Zhong Xu
HANDBOOK OF COMPUTATIONAL MOLECULAR BIOLOGY
Srinivas Aluru SPECULATIVE EXECUTION IN HIGH PERFORMANCE
COMPUTER ARCHITECTURES
HANDBOOK OF DATA STRUCTURES AND APPLICATIONS David Kaeli and Pen-Chung Yew
Dinesh P. Mehta and Sartaj Sahni
VEHICULAR NETWORKS: FROM THEORY TO PRACTICE
HANDBOOK OF DYNAMIC SYSTEM MODELING Stephan Olariu and Michele C. Weigle
Paul A. Fishwick
Methods in
Algorithmic Analysis
Vladimir a. dobrushkin
brown uniVersity
ProVidence, rhode island, u.s.a.
CRC Press
Taylor & Francis Group
6000 Broken Sound Parkway NW, Suite 300
Boca Raton, FL 33487-2742
© 2009 by Taylor & Francis Group, LLC
CRC Press is an imprint of Taylor & Francis Group, an Informa business
This book contains information obtained from authentic and highly regarded sources. Reasonable efforts have been
made to publish reliable data and information, but the author and publisher cannot assume responsibility for the valid-
ity of all materials or the consequences of their use. The authors and publishers have attempted to trace the copyright
holders of all material reproduced in this publication and apologize to copyright holders if permission to publish in this
form has not been obtained. If any copyright material has not been acknowledged please write and let us know so we may
rectify in any future reprint.
Except as permitted under U.S. Copyright Law, no part of this book may be reprinted, reproduced, transmitted, or uti-
lized in any form by any electronic, mechanical, or other means, now known or hereafter invented, including photocopy-
ing, microfilming, and recording, or in any information storage or retrieval system, without written permission from the
publishers.
For permission to photocopy or use material electronically from this work, please access www.copyright.com (http://
www.copyright.com/) or contact the Copyright Clearance Center, Inc. (CCC), 222 Rosewood Drive, Danvers, MA 01923,
978-750-8400. CCC is a not-for-profit organization that provides licenses and registration for a variety of users. For
organizations that have been granted a photocopy license by the CCC, a separate system of payment has been arranged.
Trademark Notice: Product or corporate names may be trademarks or registered trademarks, and are used only for
identification and explanation without intent to infringe.
Visit the Taylor & Francis Web site at
http://www.taylorandfrancis.com
and the CRC Press Web site at
http://www.crcpress.com
Contents
Preface xiii
Abbreviations xix
1 Preliminaries 1
1.1 Why Do We Analyze Algorithms? . . . . . . . . . . . . . . . . . . . . . . . 2
1.1.1 Cost of Algorithms . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.1.2 One Problem – Several Solutions . . . . . . . . . . . . . . . . . . . 3
1.1.3 Matrix Multiplication . . . . . . . . . . . . . . . . . . . . . . . . . . 8
1.2 Proofs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
1.2.1 Proof by Counting . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
1.2.2 Induction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
1.3 Iteration and Recursion . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
2 Combinatorics 25
2.1 Properties of Summation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
2.1.1 Index Transformations . . . . . . . . . . . . . . . . . . . . . . . . . 28
2.2 Multiple Sums . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34
2.2.1 Changing Order of Summation . . . . . . . . . . . . . . . . . . . . . 34
2.2.2 Summations and Finite Differences . . . . . . . . . . . . . . . . . . 36
2.2.3 Summation by Parts . . . . . . . . . . . . . . . . . . . . . . . . . . 40
2.3 Principles of Counting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
2.4 Permutations and Combinations . . . . . . . . . . . . . . . . . . . . . . . . 44
2.4.1 Combinations and Lattice Paths . . . . . . . . . . . . . . . . . . . . 48
2.5 Binomial Coefficients . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56
2.5.1 Definitions and Properties . . . . . . . . . . . . . . . . . . . . . . . 56
2.5.2 Transformations and Basic Sums . . . . . . . . . . . . . . . . . . . . 58
2.5.3 Inverse Relations . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
2.5.4 Vandermonde Convolution . . . . . . . . . . . . . . . . . . . . . . . 66
2.6 Binomial Coefficients and Hypergeometric Functions . . . . . . . . . . . . . 72
2.6.1 Abel’s Identity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
2.7 Stirling Approximation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
3 Probability 79
3.1 Set Operations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 80
3.2 Sample Space and Random Variables . . . . . . . . . . . . . . . . . . . . . . 82
3.3 Calculating Probabilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86
3.4 Random Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94
3.4.1 Probability Mass Function . . . . . . . . . . . . . . . . . . . . . . . 94
3.4.2 Expected Values . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
3.4.3 Variance and Moments . . . . . . . . . . . . . . . . . . . . . . . . . 112
3.4.4 Functions of Random Variables . . . . . . . . . . . . . . . . . . . . 119
3.5 Conditional Probabilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . 119
3.6 Independence . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123
3.7 Joint Distributions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 127
3.8 Dependent Random Variables . . . . . . . . . . . . . . . . . . . . . . . . . . 130