This is a foundational course in the design and analysis of algorithms and the data structures they are coupled with. While we will concentrate on the theoretical design and analysis of algorithms and data structures, we will reinforce the theory with examples, laboratories, and applied homework questions.
The goal of this course is to provide a strong foundation in algorithms and data structures in preparation for jobs in industry or for more advanced courses. Algorithms are the basic language of computer science. After taking this course, you should be able to prove the correctness of and analyze the running times of different algorithms. You should also be able to use different algorithm-design techniques to solve particular problems. Data structures and algorithms also form a major component of any software system. After taking this course you should be able to make intelligent decisions about alternative techniques in the context of practical problems, choosing from existing data structures and algorithms or designing your own when necessary.
Date | Topics | Readings | Extras |
Jan 24 | Introduction. Course policies. Course overview. Some interesting problems. | DPV Chapter 0 | |
Jan 27 | Generating random permutations. Fibonacci numbers. | CLRS Section 5.3 (Randomized Algorithms), DPV Chapter 0. | |
Jan 31 | Basic arithmetic. Divide and conquer algorithms | DPV Sections 1.1, 2.1, 2.2 | |
Feb 3 | Mergesort and Selection | DPV Sections 2.3, 2.4 | |
Feb 7 | Quicksort | CLRS Chapter 7 | |
Feb 10 | Matrix multiplication, modular arithmetic. | DPV 2.5, 1.2 | |
Feb 14 | Modular arithmetic, contd. Intro to graphs. | DPV 1.2, 3.1-3.2 | |
Feb 17 | Depth-first search. Topological sort (linearization). | DPV 3.3 | Feb 21 | No class. President's Day. |
Feb 24 | Strongly connected components. Eulerian tours. | DPV 3.4 | Feb 28 | Midterm exam #1 |
Mar 3 | Breadth-first search. Dijkstra's algorithm. | DPV 4.1-4.4 | |
Mar 7 | Dijkstra's algorithm contd. Heaps, heap creation and heapsort. Shortest paths with negative edges. | DPV 4.4-4.6, CLRS Chapter 6. | |
Mar 10 | The Bellman-Ford algorithm. Shortest paths in DAGs. Minimum spanning trees. | DPV 4.6, 4.7, 5.1. | |
Mar 21 | Kruskal's algorithm for MSTs. The disjoint set data structure. | DPV 5.1 | |
Mar 24 | Disjoint sets contd. Amortized analysis. | DPV 5.1, CLRS 17.1, 17.3. | |
Mar 28 | Hash tables. Chaining, open addressing. Intro to cuckoo hashing. | CLRS 11.1, 11.2, 11.4; Cuckoo hashing notes from Rasmus Pagh | |
Mar 31 | Cuckoo hashing contd. Bloom filters. | Wikipedia on Bloom Filters | |
Apr 4 | Universal hashing. Huffman coding part 1. | CLRS 11.3; DPV 1.5, 5.2. | |
Apr 7 | Huffman coding contd; Intro to dynamic programming | DPV 5.2, 6,1, 6.2 | |
Apr 11 | Midterm exam #2 | ||
Apr 14 | Dynamic programming contd. Edit distance, knapsack, memoization. | DPV 6.3, 6.4. | |
Apr 18 | Dynamic programming contd. Knapsack with unique objects, chain matrix multiplication. | DPV 6.4-6.5. | |
Apr 21 | Dynamic programming contd. Return to shortest-paths. All-pairs shortest paths. Independent sets in trees. The DP approach to TSP. | DPV 6.6-6.7. | |
Apr 25 | Flows, max-flow and the Ford-Fulkerson algorithm. | DPV 7.2, 7.3. CLRS 26.1-26.3. | |
Apr 28 | NP completeness. Reducing 3SAT to Independent Set. | DPV 8.1-8.3. | |
May 2 | Guest lecture by Prof. Anshelevich. Reductions, contd. | DPV 8.3. | |
May 5 | No class. Sanmay is at AAMAS | ||
May 9 | SAT to 3SAT. Circuit-SAT to SAT. Hamiltonian Cycle to TSP. All of NP to Circuit-SAT. Unsolvable problems. | DPV 8.3. CLRS 34.3-34.5. |