Lecture 2 5 Applications of NPhardness Knapsack Knapsack

  • Slides: 35
Download presentation
Lecture 2 -5 Applications of NP-hardness

Lecture 2 -5 Applications of NP-hardness

Knapsack

Knapsack

Knapsack

Knapsack

Knapsack is NP-hard

Knapsack is NP-hard

Decision Version of Knapsack

Decision Version of Knapsack

Partition

Partition

Set-Cover

Set-Cover

Set-Cover Given a collection C of subsets of a set X, find a minimum

Set-Cover Given a collection C of subsets of a set X, find a minimum subcollection C’ of C such that every element of X appears in a subset in C’. (Such a C’ is called a setcover. )

Vertex-Cover

Vertex-Cover

Decision Version of Vertex-Cover Decision Version of Set-Cover

Decision Version of Vertex-Cover Decision Version of Set-Cover

Broadcast in Multi-Channel Wireless Networks

Broadcast in Multi-Channel Wireless Networks

Problem

Problem

Hitting Set Given a collection C of subsets of a set X, find a

Hitting Set Given a collection C of subsets of a set X, find a minimum subset Y of X such that intersection of Y and S is not empty for every S in C.

Nonunique Probe Selection and Group Testing

Nonunique Probe Selection and Group Testing

DNA Hybridization

DNA Hybridization

Polymerase Chain Reaction (PCR) • cell-free method of DNA cloning Advantages • much faster

Polymerase Chain Reaction (PCR) • cell-free method of DNA cloning Advantages • much faster than cell based method • need very small amount of target DNA Disadvantages • need to synthesize primers • applies only to short DNA fragments(<5 kb)

Preparation of a DNA Library • DNA library: a collection of cloned DNA fragments

Preparation of a DNA Library • DNA library: a collection of cloned DNA fragments • usually from a specific organism

DNA Library Screening

DNA Library Screening

Problem • If a probe doesn’t uniquely determine a virus, i. e. , a

Problem • If a probe doesn’t uniquely determine a virus, i. e. , a probe determine a group of viruses, how to select a subset of probes from a given set of probes, in order to be able to find up to d viruses in a blood sample.

Binary Matrix viruses probes p 1 p 2 p 3 pi pt c 1

Binary Matrix viruses probes p 1 p 2 p 3 pi pt c 1 0 0 1 0. . 0 c 2 c 3 0 0 1 … … … … 0 0 0 0 cj … 0 … 0 … … … … 0 0 0 0 … … cn 0 0 0 … 0 … 1 … 0 … 0 0 0 … 0 … 0 The cell (i, j) contains 1 iff the ith probe hybridizes the jth virus.

Binary Matrix of Example virus probes p 1 p 2 p 3 c 1

Binary Matrix of Example virus probes p 1 p 2 p 3 c 1 1 0 0 c 2 1 0 0 0 1 0 c 3 1 0 0 1 0 1 0 0 1 0 0 0 1 cj 0 0 1 1 0 0 0 1 Observation: All columns are distinct. To identify up to d viruses, all unions of up to d columns should be distinct!

_ d-Separable Matrix viruses probes p 1 p 2 p 3 pi pt c

_ d-Separable Matrix viruses probes p 1 p 2 p 3 pi pt c 1 0 0 1 0. . 0 c 2 c 3 cj 0 0 … 0 … 0 1 0 … 0 … 0 … 0 … 0 0 1 … 0 … 0 0 0 … 0 … 1 … 0 … 0 0 0 … 0 … 0 All unions of up to d columns are distinct. Decoding: O(nd) cn

d-Disjunct Matrix c 1 c 2 p 1 0 0 p 2 0 1

d-Disjunct Matrix c 1 c 2 p 1 0 0 p 2 0 1 p 3 1 0 probes 0 0. . pi 0 0. . pt 0 0 0 … 0 c 3 0 0 0 1 … … 0 0 viruses cj … 0 … 0 … … … … 0 0 0 0 … … cn 0 0 0 … 0 … 1 … 0 … 0 … 0 … Each column is different from the union of every d other columns Decoding: O(n) Remove all clones in negative pools. Remaining clones are all positive.

Nonunique Probe Selection _ • Given a binary matrix, find a d-separable submatrix with

Nonunique Probe Selection _ • Given a binary matrix, find a d-separable submatrix with the same number of columns and the minimum number of rows. • Given a binary matrix, find a d-disjunct submatrix with the same number of columns and the minimum number of rows. • Given a binary matrix, find a d-separable submatrix with the same number of columns and the minimum number of rows

Complexity? • All three problems may not be in NP, why? • Guess a

Complexity? • All three problems may not be in NP, why? • Guess a t x n matrix M, verify if M is dseparable (d-separable, d-disjunct).

Problem

Problem

- d-Separability Test • Given a matrix M and d, is M d-separable? •

- d-Separability Test • Given a matrix M and d, is M d-separable? • It is co-NP-complete.

- d-Separability Test • Given a matrix M and d, is M d-separable? •

- d-Separability Test • Given a matrix M and d, is M d-separable? • This is co-NP-complete. (a) It is in co-NP. Guess two samples from space S(n, d). Check if M gives the same test outcome on the two samples.

(b) Reduction from vertexcover • Given a graph G and h > 0, does

(b) Reduction from vertexcover • Given a graph G and h > 0, does G have a vertex cover of size at most h?

- d-Separability Test Reduces to d-Separability Test • Put a zero column to M

- d-Separability Test Reduces to d-Separability Test • Put a zero column to M to form a new matrix M* • Then M is d-separable if and only if M* is d -separable.

d-Disjunct Test • Given a matrix M and d, is M d-disjunct? • This

d-Disjunct Test • Given a matrix M and d, is M d-disjunct? • This is co-NP-complete.

Minimum d-Separable Submatrix • Given a binary matrix, find a d-separable submatrix with minimum

Minimum d-Separable Submatrix • Given a binary matrix, find a d-separable submatrix with minimum number of rows and the same number of columns. • For any fixed d >0, the problem is co-NPhard. • In general, the problem is conjectured to p be Σ 2 –complete.