CS 31: Algorithms, Spring 2020 (The Online Edition)

Methodology Logistics Schedule Policies

Course Description and Goals:
Algorithms are step-by-step instructions for a computation problem. Although this sounds like a cooking recipe, good algorithms is what makes the modern world run.
          In this course, we will study algorithms rigorously. At the end of the course, the student should be able to design algorithms for problems, reason about these algorithms, and communicate the algorithm and its analysis.

Background Assumed:
Students should have basic knowledge about programming and should be able to read and write math proofs. If you have taken CS 1, CS 10, and CS 30, you should be fine. In case you haven't, then please see the instructor. See this for what I teach in CS30.

Course Methodology

CS 31, Spring 2020 will be offered online. Almost all information will be available via the Canvas page. The course will be sort-of-flipped. We will post material (videos and notes) beforehand, and these will be the primary sources of your knowledge. On the usual class hours (the 2A hour), we will discuss some pre-determined material over zoom, which you will be expected to go through beforehand. I envision this discussion to be (a) a quick summary from my end, (b) addressing questions and clarifications, and (c) if time permits, perhaps see an application problem pertaining to the material. A schedule of this will also be posted very soon on the class webpage.

To see you have learnt the material, we will have three types of deliverables. Apart from this, I will also provide, every week, one advanced problem , bunch of ungraded practice problems , and some creative reduction-style problems. These are not for submission, but doing all these is what will make a top-notch algorithmist.


Videos and Notes : Canvas (under construction)
Live Class Times : 2A (TR: 2:25pm - 4:15pm)
Venue : Zoom (meeting id and password in email)
Discussions : Piazza (via Canvas)
Drills, Coding, PSets : All submissions via Canvas
Personnel : Office hours will be posted on Canvas with Zoom links.

Text Books
There is no required textbook. However, the material is mostly going to be from the following two books, and I will give pointers to them as well if needed.

Students don't have to buy any of the above books. Indeed, if you Google, you may find pdf copies on the web. You are, however, not allowed to look at or refer to the solutions manuals for these books.

As you all know, this term every student will be getting a (CT/NC) grade. Below is the distribution of points.

If you get more than 60% in the course, you will get an CT. This is a sufficient condition, not a necessary one. If you do well in this course, you will get a citation.

More details here. Warning: The grading policies are subject to change.

Tentative Weekly Schedule

Week Topics Relevant Lecture Notes Other Info
Week 1
(3/31, 4/2)
Introduction, Worst Case Running Time
Number Algorithms
Lec 0
Lec 0 Supplement
Lec 1
Lec 1 Supplement
Coding 0 due (4/4)
PSet 0 due (4/4)
Week 2
(4/7, 4/9)
Big-Oh notation
Divide & Conquer: Merge Sort, Inversions
Lec 2
Lec 3
Lec 3 Supplement
Coding 1 due (4/11)
PSet 1 due (4/11)
Week 3
Divide & Conquer: Max Range Subarray
Divide & Conquer: Polynomial Multiplication
Lec 4
Lec 4 Supp (Closest Point)
Coding 2 due (4/18)
PSet 2 due (4/18)
Week 4
(4/19, 4/21, 4/23)
Dynamic Programming: Smart Recursion
Dynamic Programming: Subset Sum + Knapsack
Lec 5
Lec 6
Lec 7
Coding 3 due (4/26)
PSet 3 due (4/26)
Week 5
(4/28, 4/30)
Dynamic Programming : String Problems
Dynamic Programming : Wrap up + Graph Algorithms : Intro
Lec 8
Lec 8 supp
Coding 4 due (5/2)
PSet 4 due (5/2)
Test 1 Syllabus: Big-Oh, Analyzing Algorithms
Divide and Conquer, Dynamic Programming
May 3, 4
(Sun, Mon)
~36 hours
Week 6
(5/5, 5/7)
Graph Algorithms : Depth First Search
Graph Algorithms : Applications of DFS
Lec 10
Lec 11
Coding 5 due (5/10)
Week 7
(5/12, 5/14)
Graph Algorithms : Shortest Paths
Graph Algorithms : BFS, Dijkstra, Bellman-Ford
Lec 12
Lec 13

PSet 5 due (5/17)
Week 8
(5/19, 5/20, 5/21)
Graph Algorithms : Max Flow, Min Cut, Applications
Graph Algorithms : Flow Algorithms
Lec 14
Lec 15
Lec 15 Supp 1 (Irrational Ford-Fulkerson)
Lec 15 Supp 2 (Faster Flows)
Lec 16
Lec 16 Supp (Hall's Theorem)
Coding 6 due (5/24) PSet 6 due (5/24)
Week 9 + 10
(5/26, 5/28, 6/2)
"Extra" Topics : Randomized Algorithms
"Extra" Topics : The Experts Problem
"Extra" Topics : P, NP, and all that jazz.
Lec 17
Lec 18
Lec 19
PSet 7 due (5/31)
Test 2 Syllabus: Graphs
DFS, Shortest Paths, Flows, Cuts
June 6,7th
(Sat, Sun)
~36 hours


Evaluation Policies : Details

Regrading Policy

If you feel a grader has not graded accurately, then please contact them via email cc-ing the head TA (Maryam). If even after this you feel unsatisfied, then you can email the instructor for a full regrade . I will look at the entire problem set and re-grade it completely. Note: this has to be done within 2 weeks of you being handed the solution. Also, remember, the slack available though before you exercise regrading.

Zoom Etiquette

I am sure we will all learn various etiquettes on the fly (and I will keep posting them). But a few standard things.

Academic Integrity / Honor Code

Algorithms are tough, but fun. And it is even more fun when one works with a friend. I highly recommend forming study groups and watch the videos together, go over notes together, pore over practice problem + solutions together. And bang heads on the weekly problem set together. This is not only allowed, I highly encourage it. However, the final solution you write, must be your own.

For coding assignments and drills, I recommend working on your own. This will make you understand the concepts better, and make you all better coders. Only if stuck, contact the teaching personnel or your friend. For instance, if your code is not working, this is the perfect thing to share your screen with a TA and ask them what's wrong. Or asking your friend, "Hey, how does one convert a string to an integer in Python?" Perfectly OK. But there is a line here which you must make sure you don't cross.

This is important : For all your submissions, you must provide a credit statment even if you have worked alone (in which case, state "Worked alone"). Please write the names of all you have worked with. If this set is empty say so. Not writing a credit statement can give you a zero . I know many solutions are written at the last minute; spend the first 10 seconds of that minute to cite people who help you. Good habit.

Finally, some possible honor principle violations to be aware of in this online course offering.

I stress here that since you all will be "socially distant", you will probably using tools like above to brainstorm, etc. For instance, you may zoom with a classmate about a pset, and then you may obtain (say in a recorded session) some written material from your friend about a weekly pset. You must not use it as is; everything you write must be your own words.

Simply put, there is a line, and you would know if you are crossing it. Just don't. Dartmouth's Academic Honor Principle applies to this course. Please be sure to read the principle, which you can find here . Please ask me if you have any questions about the honor code as it applies to CS 31. Please, please don't be in a situation where you and I need to go through unpleasantries.