html5-img
1 / 16

ADVANCED COMPUTATIONAL MODELS AND ALGORITHMS

ADVANCED COMPUTATIONAL MODELS AND ALGORITHMS. Instructor: Dr. GautamDas February 24, 2009 Class notes by Ranganath M R. Overview. NP Hard Problems P Space (Polynomial Space) Quantified SAT (P Space complete problem) Deterministic Approximation Algorithms

eulak
Download Presentation

ADVANCED COMPUTATIONAL MODELS AND ALGORITHMS

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. ADVANCED COMPUTATIONAL MODELS AND ALGORITHMS Instructor: Dr. GautamDas February 24, 2009 Class notes by Ranganath M R

  2. Overview • NP Hard Problems • P Space (Polynomial Space) • Quantified SAT (P Space complete problem) • Deterministic Approximation Algorithms • Vertex Cover approximation algorithm.

  3. NP Hard Problems • A problem p belongs to NP – Hard if, • p is as hard as any NP complete problem i.e. if any NP complete problem ≤p p • ii is not known to have a polynomial verification time for p.

  4. P Space (Polynomial space) • A problem p belongs to P Space if, • There exists an algorithm to solve the problem that only requires a polynomial amount of extra memory. • Input : n • Extra memory polynomial (n) • The P Space extends even outside the NP complete space and Co-NP Space

  5. Example • The SAT problem is closed under P Space. • We can have an integer whose length in bits is equal to the number of variables of the SAT problem. Example if we 8 variables in SAT, then we take an integer with 8 bits(byte). Each bit of the integer represents the variable of the SAT problem. Hence the entire truth assignments can be verified in extra space which is poynomial.

  6. Quantified SAT problem • Example: let f: (X1 v X2) ^ (X1 v X3bar ) ^ • (X2 v X1 v X3bar v X4 bar ) • Does there exist X1 and X2 such that for all X3 and X4 f(X1, X2,X3,X4) = 1 (true). This Problem is P space complete as this problem takes extra memory which is not polynomial. This is because we should check the function F, for every value of X3 and X4 when X1 and X2 are fixed. Hence this problem is P Space complete.

  7. In general, if a problem of the sort • ( there exists ………….For all ……….. There exists…………for all) are all P space complete.

  8. Deterministic Approximation Algorithms • Vertex Cover Problem: • Input: G(V,E) • Vertex Cover Problem: Approx algorithm A for the VC problem is one that produces a VC , Vapprox such that • A runs in poly time • 1 ≤ (Vapprox / Vopt ) ≤ C. • Vopt is the optimal Vertex cover for the same graph • C is some constant.

  9. An approximation algorithm for VC • Lets us consider this graph for the VC problem. A B E C D

  10. Approximation Algorithm for calculating VC • Step1: Select any edge, then add the two nodes which are at the edge into the VC set. • Step2: Delete all the edges originating from those two verticies. • Step3: If all the edges are not covered, then go to step 1 Else : we have the VC being the approximate vertex cover set.

  11. Example of the problem • Select edge BE. Vapprox = {B,E} A B E C D

  12. Now the edges are originating from B and E are removed . VC = {B,E} A B E C D

  13. Now select AC. Vapprox = {B,E,A,C} A B E C D

  14. Now no edges are remaining hence Vapprox = {B,E,A,C} A B E C D

  15. Now, the Vopt , should atleast contain two of the vertices or more. A B E C D

  16. Hence in general, the if the Vapprox contains 2L nodes, the Vopt will contain atleast L nodes. Hence C in this case is less than or equal to 2L/L.

More Related