CS 218: Design and Analysis of Algorithms

Fall Quarter, 2015

News

  • (Dec 3) homework 8 solution (updated on Dec 8)
  • (Dec 2) more "warm-up" problems posted
  • (Dec 1) final syllabus posted
  • (Dec 1) Flow slides updated
  • (Nov 25) hw7 solution posted
  • (Nov 25) hw8 posted
  • (Nov 25) dyn programming slides updated
  • (Nov 19) hw7 posted
  • (Nov 19) hw6 solution posted
  • (Nov 16) Midterm posted
  • (Nov 9) Some "warm-up" problems posted (updated on Nov 10)
  • (Nov 5) Hw6 posted
  • (Nov 5) updated "greedy" slides
  • (Nov 4) Hw5 solution posted
  • (Oct 28) Hw4 solution posted
  • (Oct 28) Mock midterm posted
  • (Oct 28) Midterm list of topics
  • (Oct 28) Hw5 posted
  • (Oct 28) Hw3 solution posted
  • (Oct 22) divide and conquer slides updated again
  • (Oct 21) Hw4 posted
  • (Oct 12) Hw3 posted
  • (Oct 12) divide and conquer slides updated
  • (Oct 8) Hw 1 solution posted
  • (Oct 7) Hw 2 posted
  • (Oct 7) Entrance exam posted
  • (Oct 7) Midterm is Monday, Nov 16th
  • (Oct 5) Final is Wednesday, Dec 9th
  • (Sep 9) First lecture is Monday September 28th
  • Overview

    Catalog description: Design and Analysis of Algorithms (4) Lecture, 3 hours; outside research, 3 hours. Prerequisite(s): CS 141. Study of efficient data structures and algorithms for solving problems from a variety of areas such as sorting, searching, selection, linear algebra, graph theory, and computational geometry. Worst-case and average-case analysis using recurrence relations, generating functions, upper and lower bounds, and other methods.

    Basic information

    Instructor: Stefano Lonardi (stelo AT cs.ucr.edu)
    Office hours: Tuesday 3:40-5pm. Office: Chung Hall 325.

    Teaching Assistants:
  • Weihua Pan (wpan005 AT ucr.edu)
    Office hours: Friday 4-5pm. Location: Chung Hall 110.

  • Abbas Roayaei (roayaei AT gmail.com)
    Office hours: Thursday 10:30-11:30am. Location: Chung Hall 110.

  • Lectures:
  • MW, 3:40pm-5:00pm Chung Hall 143

  • Text Book:
  • Introduction to Algorithms (3rd Edition) by Thomas H. Cormen, Charles E. Leiserson, Ronald L. Rivest, and Cliff Stein, MIT Press.

  • Prerequisites:
  • Graduate standing, undergraduate courses in algorithms and data structures. Students without an undergraduate courses in algorithms (CS 141 equivalent) and basic data structures (CS 14 equivalent) will not allowed to enroll.

  • Prerequisites by topic:
  • Discrete Math: asymptotic notation, basic summation formulas, sets (operations on sets, relations, functions), counting (permutations, sets, combinations, binomial coefficients), probability (independence, random variable, expected value)
  • Basic Data Structures: array, list, queue, stack, binary search trees, balanced binary search trees, heap
  • Sorting and Searching: quicksort, mergesort, heapsort, radix-sort, binary search
  • Graph algorithms: DFS, BFS, connected components, biconnected components, transitive closure
  • Digraph algorithms: DFS, BFS, strongly connected components, topological sorting
  • Lectures

    Tentative list of topics

  • Intro to Analysis: recurrence relations, master theorem, amortized analysis
  • Greedy: task scheduling, factional knapsack, Huffman codes, Dijkstra, Prim, Kruskal
  • Union-Find: list and tree implementation, union by rank and path compression, analysis
  • Divide and conquer: linear-time selection, Strassen, FFT, Integer multiplication
  • Randomized: selection in expected linear time, polynomial verification
  • Dynamic programming: Subset sum, LCS, matrix chain multiplication, Floyd-Warshall
  • Graph algorithms: Network Flow and Bipartite Matching
  • Actual list of topics

  • M, Sep 28: Course overview, Analysis of Algorithms (1-25)
  • W, Sep 30: Analysis of Algorithms (26-47) [HW1 posted]
  • M, Oct  5: Analysis of Algorithms (48-61) [Entrance quiz]
  • W, Oct  7: Analysis of Algorithms (62-76)[HW1 due, HW2 posted]
  • M, Oct 12: Analysis of Algorithms (77-end), Divide and Conquer / Randomized (1-34)
  • W, Oct 14: Divide and Conquer / Randomized (35-57) [HW2 due, HW3 posted]
  • M, Oct 19: Divide and Conquer / Randomized (58-83)
  • W, Oct 21: Divide and Conquer / Randomized (84-98) [HW3 due, HW4 posted]
  • M, Oct 26: Divide and Conquer / Randomized (99-end), Greedy (1-28)
  • W, Oct 28: Greedy (29-55) [HW4 due, HW5 posted]
  • M, Nov  2: Greedy (56-79)
  • W, Nov  4: Union-Find (80-101) [HW5 due]
  • M, Nov  9: Union-Find (102-end), Midterm Prep
  • W, Nov 11: Holiday [HW6 posted]
  • M, Nov 16: [Midterm (80mins, in class, closed book, closed notes)]
  • W, Nov 18: Dynamic Programming (1-34) [HW6 due, HW7 posted]
  • M, Nov 23: Dynamic Programming (35-end)
  • W, Nov 25: Network Flow (1-27)[HW7 due, HW8 posted]
  • M, Nov 30: Network Flow (28-end)
  • W, Dec  2: Review [HW8 due]
  • W, Dec  9: 3-6pm[Final (180 mins, closed book, closed notes)]
  • Slides

  • Intro [PDF 2pages/slide]
  • Algorithm Analysis [updated Oct 1, PDF 2pages/slide]
  • Divide and Conquer (and randomized) algorithms [updated Oct 22, PDF 2pages/slide]
  • Greedy algorithms [updated Nov 5, PDF 2pages/slide]
  • Dynamic Programming algorithms [PDF 2pages/slide, update Nov 25]
  • Network flow algorithms [PDF 2pages/slide, updated Dec 1]
  • Homework

    Quizzes/Exams

    Policies