Here

advertisement
EECS 3101
Tutorials
Winter 2016
This is a summary of what we have discussed during the tutorials so far.
(The light colored text is from the previous year.)









Wed, Jan. 6:
1. Lecture Slide 2 (LS2), pp: 24-29: Asymptotic notations and their properties.
2. LS2, p. 9: Primality Testing.
3. LS2, p. 35: Insertion Sort: Average versus Worst-Case Time Complexity.
Mon, Jan. 11:
1. LS1: Inductive reasoning & Recursive thinking.
2. LS1, p. 26: The # disk moves by Towers of Hanoi Algorithm is 2n-1. Why is this optimum?
3. LS1, Exercise 6, p. 30: Red-Blue Towers of Hanoi.
Wed., Jan. 13:
1. LS2 & LS3: Asymptotic Notations and Summations.
2. What do n(1) , 2(n) mean?
3. Polynomial versus exponential growth: How do we justify that
n2 log3 n = n(1)
and 2n / log3 n = 2(n) ?
4. Why log(n!) = log 1 + log 2 + … + log n = (n log n)?
5. LS2, Exercise 7.
6. LS3, Exercise 12(a).
Mon., Jan. 18:
1. LS3: Recurrence Relation solution methods:
the Recursion Tree, Master Method, Guess-&-Verify, Substitution.
2. LS3, Exercises: 6(b,h), 5, 9.
3. LS3, Exercise 13 to be discussed next time.
Wed., Jan. 20:
1. LS2, p. 26, Rule 9: f(n) = g(n) + o(g(n)) implies f(n) = (g(n)).
Similarly: f(n) = g (n)) + O(g(n)) implies f(n) = (g(n)).
2. LS3, Exercise 13.
3. LS4, Exercises 1, 9(a): 2SUM (idea: how to implicitly “merge two sorted arrays”).
4. LS4, Exercise 9(b): 3SUM left to class to think about.
Mon., Jan. 25:
1. LS4: Exercise 9(b): 3SUM.
2. Problem: Given n points in the plane, are any three of them collinear?
3. LS4: Exercise 6(a).
Wed., Jan. 27:
1. LS4, p. 94: Closest Pair Problem further explained.
2. LS4, Exercises 13, 23.
3. LS4, Exercises 25, 27 left to students to work on.
Mon., Feb. 1:
1. Assignment 1: Posted solution to the last question explained.
2. How to properly strengthen pre-/post- conditions of a recursive algorithm.
3. LS4, Exercises 25, 16.
Wed., Feb. 3:




1. How to properly strengthen pre-/post- conditions of a recursive algorithm.
2. LS4, Exercise 30.
Mon., Feb. 8:
1. Questions 1 and 2 of A2 clarified. See the course Forum for further Q&A.
2. LS5, Exercises 4 and 6 (to be continued).
Wed., Feb. 10:
1. LS3: summations revisited.
2. LS5, p. 124: The Adversary argument explained further: why should S? be empty.
3. LS5, Exercise 6(c): discussion continued.
Mon. Feb. 15, Wed., Feb. 17:
1. Reading Week. No lectures/tutorials.
Mon., Feb. 22: Midterm Review Session:













Q1(a) of sample midterm 2013W.
How to solve a recurrence by the
guess-&-verify method; an example.
Some recursive algorithms.
LS1, Exercise 12 (King’s wise men).
LS4, Exercise 25 (again).

LS5, page 102: Quiz Question.
 LS5, exercise 10.
 Assignment 2, Problem 2: The posted
alternative solution explained.
Wed., Feb. 24:
1. Midterm test in class. No follow up tutorial that day.
Mon., Feb. 29:
1. LS5, Exercises 16 and 17.
Wed., Mar. 2:
1. LS5, Exercises 16 explanation completed with a new data structure.
2. LS6, Exercise 3: How to prove the greedy LI is maintained.
Mon., Mar. 7:
1. LS7: Matrix Chain Product algorithm explained.
2. LS6, Exercise 5: Several solutions discussed and their correctness/incorrectness analyzed.
Wed., Mar. 9:
1. Dynamic Programming: how to go through the design steps.
2. LS7, Exercises 3 and 5.
Wed., Mar. 18:
1. More on Dynamic Programming.
2. The Matrix Chain Multiplication Problem:
how can we use the memo table to obtain the optimum parenthesization.
3. A card game against Elmo: Greedy versus DP.
Mon., Mar. 23:
1. Graph Algorithms.
2. LS8, Exercises 1, 2, 4.
Wed., Mar. 25:
1. LS7, Exercise 25 explained.
2. LS8, Exercises 1, 5, 12.




Mon., Mar. 30:
1. LS8, Exercises 17, 18, 28.
Wed., Apr. 1:
1. LS8, Exercises 28, 36, 48.
Mon., Apr. 6:
1. LS9, pages 11-12: The reduction from 2SAT to an SCC related digraph problem explained.
2. LS8, Exercises 48, 58.
Wed., Apr. 8:
1. Course Review Session.
2. A4: Biconnected components, bridges, ...
3. NP-complete problems: Graph 7-Colorability (polynomial reduction from 3-Colorability).
4. LS9, Exercises 23, 24:
Polynomial reduction from the Set Partition Problem to the Knapsack Problem.
Exercise: Show that Set Partition is NP-complete.
 Wed., Apr. 15:
1. One last Course Review Session
2 -3 PM, Ross North 203.
by popular demand:
Download