Complexity Theory in Practice

Slides:



Advertisements
Similar presentations
Proof of correctness; More reductions
Advertisements

NP-Hard Nattee Niparnan.
JAYASRI JETTI CHINMAYA KRISHNA SURYADEVARA
Max Cut Problem Daniel Natapov.
Theory of Computing Lecture 18 MAS 714 Hartmut Klauck.
1 NP-completeness Lecture 2: Jan P The class of problems that can be solved in polynomial time. e.g. gcd, shortest path, prime, etc. There are many.
NP-Completeness: Reductions
1 NP-Complete Problems. 2 We discuss some hard problems:  how hard? (computational complexity)  what makes them hard?  any solutions? Definitions 
Techniques for Proving NP-Completeness
Vertex Cover, Dominating set, Clique, Independent set
NP-Complete Problems Reading Material: Chapter 10 Sections 1, 2, 3, and 4 only.
The Theory of NP-Completeness
Analysis of Algorithms CS 477/677
The Theory of NP-Completeness 1. Nondeterministic algorithms A nondeterminstic algorithm consists of phase 1: guessing phase 2: checking If the checking.
1 The Theory of NP-Completeness 2012/11/6 P: the class of problems which can be solved by a deterministic polynomial algorithm. NP : the class of decision.
Nattee Niparnan. Easy & Hard Problem What is “difficulty” of problem? Difficult for computer scientist to derive algorithm for the problem? Difficult.
Approximation Algorithms
Techniques for Proving NP-Completeness Show that a special case of the problem you are interested in is NP- complete. For example: The problem of finding.
CSCI 3160 Design and Analysis of Algorithms Tutorial 10 Chengyu Lin.
NP-Complete Problems. Running Time v.s. Input Size Concern with problems whose complexity may be described by exponential functions. Tractable problems.
NP-COMPLETE PROBLEMS. Admin  Two more assignments…  No office hours on tomorrow.
1.1 Chapter 3: Proving NP-completeness Results Six Basic NP-Complete Problems Some Techniques for Proving NP-Completeness Some Suggested Exercises.
NP-completeness NP-complete problems. Homework Vertex Cover Instance. A graph G and an integer k. Question. Is there a vertex cover of cardinality k?
NPC.
NP-Completeness Note. Some illustrations are taken from (KT) Kleinberg and Tardos. Algorithm Design (DPV)Dasgupta, Papadimitriou, and Vazirani. Algorithms.
CSE 421 Algorithms Richard Anderson Lecture 27 NP-Completeness Proofs.
The Theory of NP-Completeness 1. Nondeterministic algorithms A nondeterminstic algorithm consists of phase 1: guessing phase 2: checking If the checking.
Given this 3-SAT problem: (x1 or x2 or x3) AND (¬x1 or ¬x2 or ¬x2) AND (¬x3 or ¬x1 or x2) 1. Draw the graph that you would use if you want to solve this.
COSC 3101A - Design and Analysis of Algorithms 14 NP-Completeness.
Theory of Computational Complexity Probability and Computing Chapter Hikaru Inada Iwama and Ito lab M1.
ICS 353: Design and Analysis of Algorithms NP-Complete Problems King Fahd University of Petroleum & Minerals Information & Computer Science Department.
The Theory of NP-Completeness
The NP class. NP-completeness
NP-Complete Problems.
More NP-Complete and NP-hard Problems
P & NP.
Chapter 10 NP-Complete Problems.
8.3.2 Constant Distance Approximations
8.2 – Strong NP Completeness
Richard Anderson Lectures NP-Completeness
Richard Anderson Lecture 26 NP-Completeness
COMPLEXITY THEORY IN PRACTICE
NP-Completeness (2) NP-Completeness Graphs 7/23/ :02 PM x x x x
NP-Completeness Proofs
Richard Anderson Lecture 26 NP-Completeness
Hard Problems Introduction to NP
Lecture 22 Complexity and Reductions
Chapter 4: Using NP-Completeness to Analyze Subproblems
NP-Completeness Yin Tat Lee
CS21 Decidability and Tractability
Intro to Theory of Computation
ICS 353: Design and Analysis of Algorithms
Parameterised Complexity
More NP-complete Problems
Richard Anderson Lecture 25 NP-Completeness
Chapter 34: NP-Completeness
Chapter 11 Limitations of Algorithm Power
NP-Complete Problems.
Prabhas Chongstitvatana
CS 3343: Analysis of Algorithms
NP-Completeness Yin Tat Lee
CS21 Decidability and Tractability
CSE 6408 Advanced Algorithms.
Complexity Theory in Practice
The Theory of NP-Completeness
CS21 Decidability and Tractability
Lecture 24 Classical NP-hard Problems
Complexity Theory: Foundations
Lecture 23 NP-Hard Problems
Presentation transcript:

Complexity Theory in Practice Section 8.1: Circumscribing Hard Problems -Vamsi Goli -Vinay Gudivendula -Laura Hall

Circumscribing Hard Problems -Practical point of view -Theoretical point of view -So we consider for Restricted versions of Hard Problems in order to find their complexity.

Consider Binpacking problem -instance is given by a set, s each with a size s -Bin size is B -main goal is to pack all elements into the smallest number of bins.

Binpacking problem(Continued) -Restriction considered: elements size is atleast equal to B/3. -problem is solved in polynomial time. -the bin can contain one , two or three elements. -the case of three elements is uniquely identifiable.(Restriction considered)

Binpacking problem(Continued) -collect elements of size B/3 and place them in the bins and left over B/3 elements are placed along with other elements. -Now identify other sizes elements and place them in the bin. -This takes atmost linear time.

Binpacking problem(Continued) -Now identify the largest subset of pairs that do not share any element . -solve maximum matching problem: which has a polynomial time solution. -the overall running time is dominated by the maximum matching algorithm.

G3C problem -the pbm is NP-complete for any fixed number of colors greater than two, solvable in linear time for two colors. -Restriction considered: the pbm is restricted to planar graphs. -The restriction is considered as any Planar graph can be 4 colored and is solved in linear time.

G3C problem(Continued) -G3C problem remains hard when restricted to planar graphs. -Now to prove that Planar G3C is NP-complete: -First reduce G3C to planar by providing a crossover gadget whenever the graph in the plane produces crossing edges. -with all the crossings removed, it is planar.

Planar G3C is NP-complete The crossing gadget must replace the two edges in such a way that: the gadget is planar and three colorable the coloring of endpoints of one original edge in no way effects the coloring of endpoints of other. the two endpoints of an original edge cannot be given same color.

Planar G3C is NP-complete -Design a planar three colorable gadget with four endpoints. x, x‘,y,y‘. -assign the same color to x and x‘ and independently same color to y and y’.

Planar G3C is NP-complete The following shows how to use this to remove crossings from some edge, say: a,b

Planar G3C is NP-complete -so here we detect all edge crossings and replace all edge crossings with our gadget. -it takes polynomial time. -Planarity is not only the important parameter involved, it also considers the maximum degree of vertices.

Planar G3C is NP-complete -that is the chromatic number should not exceed the maximum vertex degree of the graph. -G3C restricted to graphs of degree three is in P. -But when restricted to have a degree equal to four an abrupt transition takes place.

Planar G3C is NP-complete -G3C is NP-complete even when restricted to instances where no degree is more than four. To prove, we need to replace any vertex of degree larger than four with a gadget such that: the gadget is three colorable and contains no vertex larger than four. there is one attaching point for each vertex point to which the original vertex was connected. all attaching points must be colored identically.

Planar G3C is NP-complete -the following figure has all the 3 properties discussed in the previous slide.

Planar G3C is NP-complete -more attaching points are provided by stringing together several such blocks. -i. e a new block is attached to the existing component. [fig] - the transformation preserves colorability and carried out in polynomial time.

Complexity Theory Complexity theory helps the algorithmic designer in assessing hard problems.

Restrictions of Hard Problems HC is NP-Complete even when restricted to planar graphs where no vertex degree exceeds three.

HC is NP-complete A degree reducing gadget is selected which allows a single path to enter from any connecting edge and exit through any other connecting edge.

HC is NP-complete Design a planar gadget that can be substituted for the crossing of two independent XOR components. Finally remove a crossing between an XOR piece and a segment corresponding to a literal in a clause piece.

HC is NP-complete We can trivially avoid crossings with variable pieces from instances derived from Positive 1 in 3SAT. XOR components touch only one of the two segments. Crossings with the segments of the clause pieces remain.

HC is NP- complete We propose to design a new gadget that will replace triple edges of each clause. Place three edges in series rather than parallel. The gadget must ensure that any path through it uses exactly one of the three series edges.

Planar Satisfiability Problem Def:- Planar Satisfiability problem is restricted to planar instances. An instance of SAT is deemed planar if its graph representation is planar. Graph representation for an instance of satisfiability Set a vertex for each variable. A vertex for each clause. An edge between a variable vertex and clause vertex.

Restrictions among Graph Problems A common restriction among graph problems is restriction to planar graphs. For many graph problems we have a proof of NP-completeness for the general version of the problem typically from 3SAT. In order to show planar versions of the graph we have to proceed problem by problem developing a separate reduction.

Types of representations Polar representation:- Each variable gives raise to two vertices connected by an edge, each clause gives raise to a single vertex, and edges connect clauses to all vertices corresponding to literals. Non polar representation:- Variables and clauses give raise to a single vertex each edges connect clauses to all vertices corresponding to variables that appear within the clause.

Planar 3SAT are NP-complete With representations defined earlier the polar and non polar versions of 3SAT are NP-complete. From Preposition 8.1 and Corollary 8.1 Vertex Cover remains NP-complete when limited to graph of degree 5. Planar Vertex Cover is NP-complete.

Planar 3SAT are NP-complete To meet the present requirements reduction from 3SAT uses Local replacement. A clause piece assimilated to a single vertex. The conclusion follows from the NP-completeness of the polar version of planar 3SAT.

Planar 3SAT are NP-complete But the vertex cover remains NP-complete when restricted to planar graphs of degree 5 cannot be concluded from preposition 8.1 and corollary 8.1 because The two reductions cannot be combined since they do not start from same problem. We need a planar version of (3,4)-SAT in order to draw the conclusion.

Minimal Research Program Problem is NP-complete An instance of this problem is given by set of unclassified problems s, a partial order on s denoted by <, and a bound B. Whether there exists a subset s complement with |s|<B and complexity classification function c. By applying the two rules 1. x<y and c(y)=easy implies c(x)=easy. 2. x<y and c(x)=hard implies c(y )=hard.

Promise Problems

Restrictions of Hard Problems So far, all of the restrictions we have placed on NP-complete problems have been easily verifiable features. However Not all of the restrictions are verifiable in polynomial time Some restrictions are not verifiable at all

Restrictions of Hard Problems These “unreasonable” restrictions don’t make hard problems unsolvable. Algorithms can be created that easily solve certain instances of problems These problems are still theoretically hard, but easily solvable in practice.

“Perfect” Graphs An example of a problem with “unreasonable” restrictions - the “perfect” graph Perfect graphs are created through restriction of graph problems The chromatic number of every sub-graph equals the clique number of that sub-graph Example – bipartite graph

“Perfect” Graphs Several NP-hard problems are solvable in polynomial time using perfect graphs Chromatic Number Independent Set Problem Clique Problem

“Perfect” Graphs When all instances of a problem can be represented by perfect graphs, it doesn’t matter whether other restrictions can be verified in polynomial time. This saves time by reducing the need to create algorithms that solve every special case of the problem

Promise Problems Promise problems are regular problems with a predicate defined for certain instances of the problem. Algorithms that solve promise problems must Provide the correct solution Fulfill the promise Do both within prescribed resource bounds

Promise Problems The type of promise that an algorithm uses makes a difference Different types of promises can Increase/decrease the complexity of a task Make problems decidable/undecidable Make problems tractable/intractable

Promise Problems A common, yet important type of promise is uniqueness Each valid instance of a problem only has at most one solution How does uniqueness affect NP-hard and #P-hard problems? Some become solvable in constant time or polynomial time Some become tractable

Promise Problems - Completion However, some problems still remain hard How do we know? Completion A normal problem is a “completion” of a Promise Problem if the two problems have the same answers for all instances that fulfill the promise Completion is the reverse of restriction Complexity of the promise problem = Complexity of the easiest of its completions

Promise Problems - Completion Proving a promise problem is hard involves proving that none of its completions is in P unless some conjecture is false. What conjecture? Usually P ≠ NP However, we need something stronger here

RP ≠ NP RP (Randomized Polynomial Time) A complexity class for which a probabilistic TM exists with the following properties Always runs in Polynomial time in the input size If the correct answer is NO, it always returns NO If the correct answer is YES, it returns YES with probability of at least ½ P is a subset of RP. RP is a subset of NP RP ≠ NP implies P ≠ NP

Hard Promise Problem Theorem 8.7 Uniquely Promised SAT cannot be solved in polynomial time unless RP = NP This theorem can be applied to other hard promise problems (with uniqueness promises) through strictly parsimonious transformations.

Hard Promise Problems Even with strictly parsimonious transformations and the promise of uniqueness, some problems are still untractable 3SAT Hamiltonian Circuit TSP Maximum Cut Partition Problem Subset Sum Problem Binpacking Etc.

Hard Promise Problems Verifying the uniqueness promise is usually hard for hard problems For most NP-Complete problems, deciding the question of uniqueness appears to be in

Thank You