This was the cs4102 webpage for summer 2020, and is no longer active. To access another semester's page, you can simply change the url for the desired semester (e.g. f20 represents the fall 2020 semester).
Join Lecture (Weekdays at 10:30am)

1 Course Overview

The goal of this course is to build a tool kit to better solve a variety of computational problems, and to evaluate the quality of such solutions. In particular, we will cover:

  • Formal metrics for evaluating algorithm complexity (including the asymptotic classes big-oh, big-omega, big-theta, little-oh, and little-omega)
  • Evaluating an algorithm’s usage of resources (including time and space complexities) by a worst-case analysis, expected-case analysis, and amortized analysis
  • Algorithm design strategies (including divide and conquer, dynamic programming, greedy, and reductions)
  • The impact of data-structure choice on algorithm design
  • Proving algorithm correctness
  • Proving worst-case lower bounds on algorithm efficiency
  • Algorithms on graphs
  • NP-Completeness

1.1 Learning Outcomes

At the conclusion of this course, a successful student will be able to:

  • Analyze a pre-written algorithm to determine its resource complexity
  • Employ the strategies of divide and conquer, greedy, and dynamic programming (perhaps in concert) to develop novel algorithms
  • Prove the correctness of algorithms built using these strategies
  • Identify trade-offs in algorithm design (such as time vs. space, average-case vs. worst case, dynamic vs. static)
  • Prove lower bounds on algorithm complexity

1.2 Eligibility

You should take this course if and only if

  1. You have credit for CS 2150 (or an equivalent data structures course)
  2. You have credit for CS 2102 (or an equivalent discrete math course)

1.2.1 Background

This course will assume knowledge of several topics from discrete math (CS2102 at UVA), two semesters of programming experience (through CS2110 at UVA), and data structures (CS2150 at UVA)

In particular, we assume knowledge of (with recommended resources for review):

For each of the CS2102 topics, you can view last semester’s lectures for more information

2 What to expect

2.1 In this course

In the opinion of this instructor, an algorithms course should serve to:

  1. introduce students to particular noteworthy and/or widely-used algorithms, and
  2. provide opportunity for students to hone their skill in developing efficient algorithms.

Since developing a skill is a much more substantial undertaking than understanding prior work of others, the majority of your homework time will be spent on developing that skill. This will be at times uncomfortable, occasionally frustrating, but hopefully always fun and valuable in retrospect. I have a few guidelines/suggestions for how you can get the most out of this course:

  1. Follow the instructions in the assignments. I’ve been a student before, and I understand the dizzying experience of learning something brand new. For this reason, I do not ask trick questions that are specifically intended to mislead you.
  2. Think carefully and precisely: While I will not purposefully mislead you, I may ask questions that are specifically designed to challenge an incorrect intuition or common misconception.
  3. Don’t expect homework to match lecture perfectly: Lecture is designed to introduce topics/concepts/strategies, and show how they operate. To maximize the future usefulness of this course, I selected ideas whose applications are broad. Almost always, I will tell you which ideas to employ. It will probably not be obvious how or why that idea is relevant, but I promise it is. The goal of the assignment is to broaden your understanding of the idea so that it will be more useful to you when you complete this class.

2.2 In a summer course

A typical spring/fall semester at UVA is ~15 weeks long (including exams), whereas a summer course is 4 weeks long. This means that summer courses are accelerated roughly 4x compared to a course offered in the spring/fall. Considering that a full-time courseload at UVA is 12 credit hours, expect a 3 credit-hour course offered during the summer (like this one) to require a full-time workload. Another way to think about it: the amount of time you spend per day on this one summer course should roughly match the aggregate amount of work you would spend per day on all your courses during a normal semester.

As a warning, with this 4x acceleration, it can be very difficult to catch up if you fall behind. Each lecture session this summer is 135 minutes. During a normal semester you have 150 minutes of instruction per week. This means that each summer lecture contains nearly a week’s worth of content. Keep this in mind if you need to take a day off due to illness, etc.

Now that I’ve sufficiently warned you, please take comfort that I have done my best in trying to make this course workable with a summer schedule. The structures have been designed based on extensive student feedback. The most successful students tend to approach this course like a full-time job, establishing a regular work schedule of 9ish hours of work per day (amortized).

2.3 In an online course

As I’m sure you’re aware, there are challenges presented by the online course format which can make learning more challenging. If there are things I can do to make the course work better for you with this online format, please let me know, and I’ll do my best to work in those recommendations. To start with, here are the resources and suggestions that are provided by the course staff.

Course structures:

  1. Lecture: will be hosted live online via zoom. Recordings will be posted after (sometimes it takes zoom a few hours to master the video). Due to instances of zoom bombing, you will need a password to join (find it on piazza)
  2. Office Hours: There will be instructor and TA office hours 5 days a week hosted via zoom. These will be open chat rooms for you to discuss with course staff and classmates.
  3. Online submissions: Problem set solutions must be submitted by pdf. Quizzes may be submitted as either a pdf or a txt file. We do not have a preference for how the pdfs are generated (LaTeX, Microsoft Word, pictures of handwriting are all acceptable) so long as what is submitted is legible, and you use the appropriate mathematical symbols when necessary (please use the equation editor if you’re using Word).
  4. Piazza: We will be using the Piazza message board. We highly encourage you to post questions or resources that you think could benefit your peers. This is also the best place to post questions outside of office hours.

Some suggestions:

  1. Dedicate time and space One of the most important things you can do to help yourself is to set aside time and space for your studies. Once you’ve selected that time and space, try to only do work at that time and in that location. As much as possible, don’t use that time or place for anything else. Pick a chair in your bedroom, a spot on the floor, a chair at the kitchen table, or whatever you can do with the space you’re in.
  2. Introduce yourself If you opt in on the beginning of course questionnaire (little_1a), we will post a short bio about you on the course webpage. This could be helpful in you forming a study/work group for the class. It could also help you to make new friends!
  3. Attend live lecture If you’re able to, attending live lecture will help to establish your routine, put you in the learning mindset, and remind you that you’re learning in a community.