1 / 12

The Class P

[Section 7.2]. The Class P. Def 7.12: The class P consists of languages that are decidable in polynomial time, i.e., P = [ k TIME(n k ) Example: PATH = { <G,s,t> | G is a digraph that has a path from s to t }. [Section 7.2]. The Class P.

candicek
Download Presentation

The Class P

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. [Section 7.2] The Class P Def 7.12: The class P consists of languages that are decidable in polynomial time, i.e., P = [k TIME(nk) Example: PATH = { <G,s,t> | G is a digraph that has a path from s to t }

  2. [Section 7.2] The Class P Def 7.12: The class P consists of languages that are decidable in polynomial time, i.e., P = [k TIME(nk) Example: RELPRIME = { <x,y> | x and y are relatively primes }

  3. [Section 7.2] The Class P Def 7.12: The class P consists of languages that are decidable in polynomial time, i.e., P = [k TIME(nk) Example: PRIME = { <x> | x is a prime }

  4. [Section 7.3] The Class NP Example: HAMPATH = { <G,s,t> | G is digraphs with Hamiltonian path from s to t }

  5. [Section 7.3] The Class NP Example: COMPOSITES = { x | x=pq, for some p,q > 1 }

  6. [Section 7.3] The Class NP Def 7.18: A verifier for a language A is an algorithm A, where A = { w | V accepts <w,c> for some string c } Polynomial-time verifier runs in (deterministic) time polynomial in the length of w. The string c is called the certificate, or proof, of the membership in A.

  7. [Section 7.3] The Class NP Def 7.18: A verifier for a language A is an algorithm A, where A = { w | V accepts <w,c> for some string c } Polynomial-time verifier runs in (deterministic) time polynomial in the length of w. The string c is called the certificate, or proof, of the membership in A. Def 7.19:NP is the class of languages that have polynomial time verifiers.

  8. [Section 7.3] The Class NP Thm 7.20: A language is in NP iff it is decided by some nondeterministic polynomial-time TM. Def 7.21: NTIME(t(n)) = { L | L is a language decided by a O(t(n))-time nondeterministic TM }. Thus, NP = [k NTIME(nk)

  9. [Section 7.3] The Class NP Thm 7.20: A language is in NP iff it is decided by some nondeterministic polynomial-time TM. Def 7.21: NTIME(t(n)) = { L | L is a language decided by a O(t(n))-time nondeterministic TM }. Thus, NP = [k NTIME(nk)

  10. [Section 7.3] The Class NP Example: CLIQUE = { <G,k> | G is undirected graph with a k-clique }

  11. [Section 7.3] The Class NP Example: SAT = { <Á> | Á is a satisfiable Boolean formula }

  12. [Section 7.3] The Class NP • Wrapping up: • P – exists polynomial-time algorithm • NP – exits polynomial-time verifier • BIG open problem: • Is P = NP ??? • Note: also exists a class coNP, the class of complements of problems in NP (e.g. CLIQUEC, “is every clique of a given graph of different size than k?”). We do not know if NP = coNP.

More Related