1 / 26

Computational Complexity

Computational Complexity. CPSC 468b, Spring 2007 Time: Tu & Th, 1:00-2:15 pm Room: AKW 500 Dist. Group: IV (not Natural Sci.) Satisfies “QR” http://zoo.cs.yale.edu/classes/cs468. Partial Topic Outline. Complexity classes (P, NP, L, NL, etc .) Reductions and completeness

kitra-wells
Télécharger la présentation

Computational Complexity

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Computational Complexity CPSC 468b, Spring 2007 Time: Tu & Th, 1:00-2:15 pm Room: AKW 500 Dist. Group: IV (not Natural Sci.) Satisfies “QR” http://zoo.cs.yale.edu/classes/cs468

  2. Partial Topic Outline • Complexity classes (P, NP, L, NL, etc.) • Reductions and completeness • The roles of, e.g., • Randomness • Interaction • Approximation • Circuits

  3. Schedule Feb. 1: First HW Assignment Due Feb. 13: Second HW Assignment Due Feb. 22: Third HW Assignment Due Mar. 1: First In-Class Exam Mar. 6: Grades on HW1, HW2, HW3, and Ex1 will be returned to students today or earlier. Mar. 9: Drop Date Apr. 10: Fourth HW Assignment Due Apr. 19: Fifth HW Assignment Due Apr. 26: Second In-Class Exam

  4. Requirements • Modest reading assignments • 5 Written HW Assignments, 4 of which will each be worth 15% of the course grade and one of which will be worth 10% of the course grade • 2 In-Class Exams, each worth 15% of the course grade • No final exam during exam week

  5. Rules and Guidelines • Deadlines are firm. • Announcements and assignments will be posted on the class webpage (as well as conveyed in class). • No “collaboration” on homeworks unless you are told otherwise. • Pick up your graded homeworks and exams promptly, and tell the TA promptly if one is missing.

  6. Instructor: Joan Feigenbaum Office: AKW 512 Office Hours: Tuesday 4-5 pm Thursday 9-10 am Phone: 203-432-6432 Assistant: Judi Paige (judi.paige@yale.edu, 203-436-1267, AKW 507a, 9am-2pm M-F) Note: Do not send email to Professor Feigenbaum, who suffers from RSI. Contact her through Ms. Paige or the TA.

  7. TA: Nikhil Srivastava Office: AKW 413 Office Hours: Tuesday 10am-11am Friday 10am-11am Email: nikhil.srivastava@yale.edu Phone: 203-432-1245

  8. If you’re undecided … Check out: • www.cs.princeton.edu/theory/complexity/ (a new complexity-theory text by Sanjeev Arora and Boaz Barak of Princeton) • www.cs.berkeley.edu/~luca/cs278-02/ (a complexity-theory course taught by Luca Trevisan at Berkeley in 2002) • www.cs.lth.se/home/Rolf_Karlsson/bk/retro.pdf (“NP-Completeness: A Retrospective,” by Christos Papadimitriou, 1997 International Colloquium on Automata, Languages, and Programming)

  9. Questions?

  10. Computational Complexity

  11. The Big Picture • Analysis of Algorithmsupper bounds on resources to solve a computational problem • Complexitylower bounds… OR • Computability Theory What can be computed? • Complexity What can be computed, given limited resources?

  12. “Computational Problem” input 2 {0,1}* output 2 {0,1}* R

  13. Decision Problem • Does the input satisfy <property>? input 2 {0,1}* output 2 {YES/NO} R

  14. Decision Problem ~ Language • L = {YES instances}µ {0,1}* {0,1}* YES

  15. Examples • Is n composite? • Is there a path of length at most k between s and t in G? (input <G,s,t,k>) • Does G contain a clique of size ¸k? • Is G 3-colorable?

  16. Example -- SAT • Is  satisfiable? • Boolean formula on x1… xn (x1Ç x3Ç x5)Æ(x3Ç x4)Æ(x4Çx5Çx1) • Is there a satisfying assignment? • YES: (1Ç 0Ç 0)Æ (0Ç 0)Æ (0Ç0Ç 1)

  17. Search Problem • Given x, find y such that R(x,y), or output “no such y”. x 2 {0,1}* y 2 {0,1}*/NO R

  18. Examples • Find a factor f of n such that 1<f<n. • Find an s-t path of length at most k. • Find a clique of size at least k in G. • Find a 3-coloring of G. • Find an assignment to x1… xn that satisfies .

  19. Optimization Problem • Given x, find y that optimizes some criterion. y 2 {0,1}*, that achieves the optimizing value x 2 {0,1}* R

  20. Examples • Find the largest factor f of n s.t. 1<f<n. • Find the shortest path between s and t. • Find the largest clique in G. • Find a coloring of G that uses as few colors as possible.

  21. Optimization reduces to Decision • Optimization problems can be reduced to decision problems with small overhead. • For example, to find the size of the biggest clique in G, binary search on: Does G contain a clique of size k?

  22. Counting Problem • Given x, find #y satisfying R(x,y) x 2 {0,1}* |{y:R(x,y)}| R

  23. Self-Reducibility of SAT •  can be reduced to two smaller instances • Each variable must be 0 or 1. • (x1… xn)2 SAT iff (0,x2…xn)2 SAT or(1,x2…xn)2 SAT

  24. An Algorithm • Given (x1… xn) • If (0,x2…xn)2 SAT, solve recursively on (0,x2…xn) • If (1,x2…xn)2 SAT, solve recursively on (1,x2…xn) • Else return UNSAT • At most n recursive calls

  25. Why is this important? • R is an NP-relation if 9 poly. p s.t. • For all (x,y)2 R, |y|· p(|x|) • Given x,y, we can check R(x,y) in time · p(|x|) • A search problem over such an R is an NP-search problem.

  26. So… • NP-decision problem: • Given x, does 9y : R(x,y)? • Cook’s theorem: • If there is a poly. time alg. For SAT, there are poly. time algs for all NP decision problems • By self-reducibility, this extends to search problems!

More Related