Yadu Vasudev
  • Research
    • Publications
    • People
  • Teaching
  • Contact

CS6170 Randomized Algorithms

Jan - May 2025

  • about
  • contents
  • administrivia
  • lectures

Whenever you’re called on to make up your mind,
and you’re hampered by not having any,
the best way to solve the dilemma, you’ll find,
is simply by spinning a penny.

No - not so that chance shall decide the affair
while you’re passively standing there moping;
but the moment the penny is up in the air,
you suddenly know what you’re hoping.

                              - Piet Hein

Coordinates

  • Where: SSB 134
  • When: F slot - Tue (5 pm), Wed (11 am), Thu (9 am), Fri (8 am)

Instructor

  • Yadu Vasudev
  • SSB 207
  • yadu@cse.iitm.ac.in

TA

  • Dhruv Aggarwal (cs21b024@smail)

Important links

  • Moodle
  • Ed Discussions (for discussions, Q/A, announcements)
    Join using your smail/iitm ids via this link
  • Anonymous course feedback

Course calendar

About this course

This is an introductory course on design and analysis of randomized algorithms. Randomization is ubiquitous in computer science, and this course introduces some computatational problem where randomization gives efficient and elegant solutions. We will also learn how to think about randomized algorithms and the tools required to analyze such algorithms.

Prerequisites - A course in design and analysis of algorithms, and basic discrete probability will be useful. The way you think about designing algorithms will be quite different from what you saw in the undergrad algorithms course since the emphasis is not on designing algorithms that are always correct, but ones that are correct most of the time. For most of the course, you will only require discrete probability. Starting from the basics, we will build the probabilistic tools that are necessary to understand randomized algorithms.


Course contents

The course will look at the following content in detail. The order of the topics covered may vary.

  • Simple randomized algorithms and their analysis - In this part we will recall some basic discrete probability while analyzing algorithmic questions.
  • Concentration inequalities - We will look at concentration inequalities and their application in analyzing randomized algorithms.
  • Balls-in-bins and hashing - We will see data structures for dictionaries in detail and ways to analyze their performance.
  • Online algorithms - How do you design a caching mechanism that minimizes page faults? Can you do as good as when you have the power of hindsight?
  • Markov chains and random walks - How long will you take to reach your destination if you choose to board a random bus at every bus stop?
  • Markov chain Monte-Carlo - How easy is it to approximate the size of a set if you know how to sample a random element in the set efficiently?
  • VC dimension and PAC learning, algebraic techniques (if time permits)

Course resources

Our main sources of reference will be the following textbooks.

  1. Probability and Computing (Michael Mitzenmacher and Eli Upfal)
  2. Randomized Algorithms (Rajeev Motwani and Prabhakar Raghavan)

Apart from this, there are a lot of resources available online. We may refer to them occasionally. Both the books contain a number of exercise problems for practice.

Weekly schedule

There will be four lectures every week, some of which will be converted to tutorial/problem-solving sessions. You can also use the course discussion forum to discuss these with your peers and the course staff.


Grading policy (tentative)

  • Problem sets (1*5 + 3*10) = 35%
  • Course project (in groups of at most 3) = 15%
  • Mid-semester exam = 20%
  • End-semester exam = 30%

Important dates (tentative)

  • Problem sets (release dates): Jan 31, Feb 21, Mar 14, Apr 11
  • Mid-semester exam: Mar 4
  • End-semester: May 14 (according to institute calendar)

The dates and details of the course project will be announced after about a month of the start of the classes.


Communication

Please sign up on the course discussion forum here. This will be the first point of contact for any issues related to the course. For general questions related to the course (any comments/doubts), please create a thread in the correct category and add your question/comment there. You are encouraged to reply and clear the doubts of your friends. To encourage this interaction, the forum supports anonymous posts and answers. Please be courteous to others when you are posting anonymously.

Date Lecture References Misc
Lecture #1
Thu 16/01
Introduction to the course • Admin and logistics
Sign up on Ed Discussions
Lecture #2
Fri 17/01
Polynomials and perfect matchings • Probability spaces, events
  • Section 1.1, 1.2 - Course notes
Lecture #3
Tue 21/01
DeMillo-Lipton-Schwartz-Zippel lemma • One-sided error algorithms and amplifying the success probability • Freivald's algorithm
  • Sections 1.2, 1.3 - Course notes
  • Section 1.3 - [MU]
Lecture #4
Wed 22/01
Mincut in graphs - Karger's algorithm
  • Section 1.4 - Course notes
  • Section 1.5 - [MU]
Lecture #5
Thu 23/01
Karger and Stein's improvement for mincut • The maxcut problem
  • Sections 1.4, 2.1 - Course notes
  • Section 1.5 - [MU]
Karger and Stein's paper
Lecture #6
Fri 24/01
Randomized algorithm for maxcut • Random variables and their properties - expectation, independence • Properties of the randomized algorithm for maxcut
  • Section 2.1 - Course notes
  • Section 2.1 - [MU]
Lecture #7
Tue 28/01
Maxcut - pairwise independence • Conditional expectations and derandomization
  • Section 2.1 - Course notes
  • Section 2.3 - [MU]
Lecture #8
Wed 29/01
Bernoulli, binomial, and geometric random variables and their properties
  • Section 2.3 - Course notes
  • Sections 2.2, 2.4 - [MU]
Lecture #9
Thu 30/01
Coupon collector problem - calculation of expectation • Randomized quicksort and its analysis
  • Sections 2.2, 2.3.3 - Course notes
  • Sections 2.4.1, 2.5 - [MU]
Lecture #10
Fri 31/01
Markov's inequality - analyzing quicksort using Markov's inequality • Statement of Chebyshev's inequality
  • Section 3.1 - Course notes
  • Section 3.1 - [MU]
PS1 released
Lecture #11
Tue 04/02
Chebyshev's inequality • Probability amplification using pairwise independent bits
  • Section 3.2 - Course notes
  • Section 3.3 - [MU]
Lecture #12
Wed 05/02
Chernoff-Hoefding bounds and applications • Outline of the proof
  • Section 3.3 - Course notes
  • Section 4.2 - [MU]
Lecture #13
Thu 06/02
Balls and bins - birthday problem, maximum load
  • Section 4.1 - Course notes
  • Sections 5.1, 5.2.1 - [MU]
Lecture #14
Fri 07/02
Balls and bins - maximum load and Poisson approximation
  • Sections 4.2, 4.3 - Course notes
  • Sections 5.3, 5.4 - [MU]
Lecture #15
Tue 11/02
Bloom filters
  • Section 4.4 - Course notes
  • Section 5.5.3 - [MU]
Lecture #16
Wed 12/02
Universal hash families and their properties - number of collisions, maximum load
  • Section 5.1 - Course notes
  • Section 15.3 - [MU]
Lecture #17
Thu 13/02
Explicit construction of 2-universal hash families • Near-universal hash families
  • Section 5.1 - Course notes
  • Section 15.3 - [MU]
Additional notes - Section 3.1 here
Lecture #18
Thu 14/02
Near-universal hash families - constructions • Perfect hashing - FKS algorithm
  • Section 5.2 - Course notes
  • Section 15.3 - [MU]
Additional notes - Section 3.1 here
Tutorial #1
Tue 18/02
Discussion of Problem set 1
Lecture #19
Wed 19/02
Open addressing - uniform probing
  • Class notes and additional references on Ed
PS2 released
Lecture #20
Thu 20/02
Open addressing - linear probing
  • Section 5.4 - Course notes
Lecture #21
Fri 21/02
Open addressing - linear probing (contd) • Cuckoo hashing
  • Section 5.4 - Course notes
Lecture #22
Tue 25/02
Cuckoo hashing - algorithm and analysis
  • Section 5.5 - Course notes
  • Section 17.4 - [MU]
Lecture #23
Wed 26/02
Cuckoo hashing - analysis using random graphs (outline) • Locality-sensitive hashing
  • Section 5.5 - Course notes
  • Section 17.4 - [MU]
  • Chapter 3 - Mining of Massive Datasets
  • Section 12.2 - Nick Harvey's book
Lecture #24
Thu 27/02
Locality-sensitive hashing - Jaccard similarity and minhashing
  • Chapter 3 - Mining of Massive Datasets
  • Section 12.2 - Nick Harvey's book
Quiz #1
Tue 04/03
Mid-semester examination
Lecture #25
Wed 05/03
Online algorithms - model and examples • Bipartite matching - online greedy algorithm and lower bound
  • Chapter 13 - [MR]
  • Section 6.1 - Course notes
Lecture #26
Thu 06/03
Online paging - LRU and its competitive ratio • Lower bounds for deterministic paging
  • Section 13.1 - [MR]
  • Section 6.2.1 - Course notes
Lecture #27
Fri 07/03
Marker algorithm for online paging
  • Section 13.3 -[MR]
  • Section 6.2.2 - Course notes
Lecture #28
Tue 11/03
Yao's minimax principle and lower bounds for online paging
  • Section 13.3 - [MR]
  • Section 6.3 - Course notes
Lecture #29
Wed 12/03
Greedy matching revisited - primal dual analysis
  • Section 6.4.1 - Course notes
Lecture #30
Thu 13/03
Online fractional matching - primal dual analysis
  • Section 6.4.2 - Course notes
Lecture #31
Tue 18/03
Online fractional matching (contd) • RANKING - online bipartite matching
  • Section 6.4.2, 6.4.3 - Course notes
  • DVK
  • KVV
Lecture #32
Wed 19/03
RANKING - analysis using primal-dual • Online predictions
  • DVK
  • KVV
  • Section 6.5.1 - Course notes
Lecture #33
Thu 20/03
Online predictions with experts - weighted majority and randomized weighted majority
  • Section 6.5 - Course notes
  • Survey by Arora, Hazan, Kale
Lecture #34
Fri 21/03
Multiplicative weights update • Linear classification - Winnow algorithm as MWU
  • Survey by Arora, Hazan, Kale
Lecture #35
Tue 25/03
Randomized 2-SAT - algorithm description and analysis
  • Section 7.1.1 - [MU]
Lecture #36
Wed 26/03
Markov chains - definition, properties • Randomized 2-SAT as a Markov chain • Randomized 3-SAT - Schoening's algorithm
  • Section 7.1 - [MU]
Lecture #37
Thu 27/03
Schoening's algorithm (contd) • Properties of Markov chains, stationary distributions, and the fundamental theorem - examples
  • Sections 7.2, 7.3 - [MU]
Lecture #38
Fri 28/03
Random walks on graphs - cover times and reachability using random walks
  • Section 7.4 - [MU]
Lecture #39
Tue 01/04
Random walks on graphs - eigenvalues and mixing times • Monte-carlo methods - DNF counting
  • Section 11.1 - [MU]
Lecture #40
Wed 02/04
Monte-carlo methods - FPRAS for DNF counting • FPRAS for (#)-SAT and connections to SAT
  • Section 11.2 - [MU]
  • Section 2 in these notes
Lecture #41
Thu 03/04
FPRAS for (#)-SAT and connections to SAT
  • Section 2 in these notes
Lecture #42
Fri 04/04
Sampling and counting - from an FPAUS to an FPRAS
  • Section 11.3 - [MU]
Lecture #43
Tue 08/04
From FPAUS to FPRAS for independent sets • Constructing FPAUS from FPRAS
  • Section 11.3 - [MU]
  • Vigoda's notes
Lecture #44
Wed 09/04
Markov-chain Monte-Carlo - independent sets and matchings
  • Section 11.4 - [MU]
  • Jerrum and Sinclair's book chapter
Lecture #45
Tue 15/04
Markov-chain Monte-Carlo - matchings in graphs • Sampling from Gibb's distribution - Metropolis algorithm
  • Section 11.4 - [MU]
  • Jerrum and Sinclair's book chapter
Lecture #46
Wed 16/04
Bounding rates of Markov chains - couplings • Examples - card shuffling
  • Section 12.1, 12.2 - [MU]
Lecture #47
Thu 17/04
Coupling of Markov chains • Examples - random walk on the hypercube, independent sets
  • Section 12.2 - [MU]
Lecture #48
Tue 22/04
Coupling of Markov chains - independent sets (contd) • Canonical paths
  • Section 12.2 - [MU]
  • Jerrum and Sinclair's book chapter
Lecture #49
Wed 23/04
Canonical paths - outline of the approach, random walk on the hypercube, matchings in graphs
  • Jerrum and Sinclair's book chapter
Lecture #50
Thu 24/04
Canonical paths - matching in graphs (contd) • Wrap-up of the course
  • Jerrum and Sinclair's book chapter
No matching items