Top Banner
Bart Jansen, Utrecht University
40

Fixed parameter tractability and kernelization for the Maximum Leaf Weight Spanning Tree problem

Jan 02, 2016

Download

Documents

Bart Jansen, Utrecht University. Fixed parameter tractability and kernelization for the Maximum Leaf Weight Spanning Tree problem. Maximum Leaf Spanning Tree. Max Leaf Instance: Connected graph G, positive integer k Question: Is there a spanning tree for G with at least k leaves? - PowerPoint PPT Presentation
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Bart Jansen, Utrecht University

Page 2: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

2

Max Leaf Instance: Connected graph G, positive

integer k Question: Is there a spanning tree for G

with at least k leaves?Applications in network designYES-instance for k ≤ 7

Page 3: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Classical complexity MAX-SNP complete, so no polynomial-

time approximation scheme (PTAS) NP-complete, even for

3

Page 4: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Bipartite Max Leaf Instance: Connected bipartite graph G

with black and white vertices according to the partition, positive integer k

Question: Is there a spanning tree for G with at least k black leaves?

4

Page 5: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Classical complexity No constant-factor approximation NP-complete, even for:

5

Page 6: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Weighted Max Leaf Instance: Connected graph G with a non-negative

integer weight for each vertex, positive integer k Question: Is there a spanning tree for G such that

its leaves have combined weight at least k?

6

Leaf weight 11Leaf weight 16

Page 7: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Classical complexity NP-complete by restriction of the

previous problems Hard on all classes of graphs mentioned

so far No constant-factor approximation since

it generalizes Bipartite Max LeafWe consider the fixed parameter

complexity

7

Page 8: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

8

Technique to deal with problems (presumably) not in P

Asks if the exponential explosion of the running time can be restricted to a “parameter” that measures some characteristic of the instance

An instance of a parameterized problem is: <I,k> where k is the parameter of the problem (often

integer) Class of Fixed Parameter Tractable (FPT) problems:

Decision problems that can be solved in f(k) * poly(|I| + k) time

Function f can be arbitrary, so dependency on k may be exponential

For example, the k-Vertex Cover problem is fixed parameter tractable. “Is there a vertex cover of size k?” Can be solved in O(n + 2k k2) (and even faster).

Page 9: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

A kernelization algorithm: Reduces parameterized instance <I,k> to

equivalent <I’,k’> Size of I’ does not depend on I but only on k Time is poly (|I| + k) New parameter k’ is at most k

If |I’| is O(g(k)), then g is the size of the kernel

Kernelization algorithm implies fixed parameter tractability Compute a kernel, analyze it by brute force

9

Page 10: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Existing problems, parameterized by nr. of leaves Regular Max Leaf has a 3.5k kernel No FPT results for Bipartite Max Leaf

For Weighted Max Leaf We take the target weight k as the parameter of the

problem (In)tractable depending on whether weight 0 is

allowed Kernel size depends on class of graphs

Complexity of weighted problem

General graphs

Planar graphs Genus ≤ g graphs

Weights {0,1,.. }

W[1] hard 84k kernel O(k √g) kernel

Weights {1,2,.. }

9.5k kernel 9.5k kernel 9.5k kernel10

Page 11: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Bipartite Max Leaf is hard for W[1]

11

Page 12: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Unless the Exponential Time Hypothesis is false, being W[1] hard implies: No f(k)*p(n) algorithm No polynomial-size kernel

W[2]-hard is assumed to be harder than W[1]-hard

For Weighted Max Leaf: No proof of membership in

W[1] It might be harder than any

problem in W[1] No hardness proof for W[2]

either

12

Page 13: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

W[i] hardness is proven by parameterized reduction <I,k> <I’,k’> from some W[i]-hard problem Like (Karp) reductions for NP-

completeness Extra condition: new parameter k’ ≤ f(k)

for some fWe reduce k-Independent Set (W[1]-

complete) to Bipartite Max Leaf

13

Page 14: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

k-Independent Set Instance: Graph G, positive integer k Question: Does G have an independent

set of size at least k? ▪ (i.e. is there a vertex set S of size at least k,

such that no vertices in S are connected by an edge in G?)

Parameter: the value k.

14

Page 15: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Given an instance of k-Independent Set, we reduce as follows: Color all vertices black Split all edges by a

white vertex Add white vertex w

with edges to all black vertices

Set k’ = k Polynomial time k’ ≤ f(k) = k

15

Page 16: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

If S is a cutset, then at least one vertex of S is internal in a spanning tree We need to give at least one vertex in S

a degree ≥ 2 to connect both sides

16

Page 17: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

17

Complement of S is a vertex cover Build spanning tree:

Take w as root, connect to all blacks We reach the white vertices from the vertex cover V – S

▪ Since every white vertex used to be an edge

Edges incident on w are not drawn

Page 18: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Take the black leaves as the independent set If there was an edge x,y then they are not both leaves

Since {x,y} is a cutset By contraposition, black leaves form an independent set

18Edges incident on w are not drawn

Page 19: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

A linear kernel for Maximum Leaf Weight Spanning Tree on planar graphs

19

Page 20: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Kernel of size 84k on planar graphs Strategy:

Give reduction rules▪ that can be applied in polynomial time▪ that reduce the instance to an equivalent instance

Prove that after exhaustive application of the rules, either:▪ the size of the graph is bounded by 84k▪ or we are sure that the answer is yes

▪ then we output a trivial, constant-sized YES-instance

20

Page 21: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

We want to be sure that the answer is YES if the graph is still big after applying reduction rules

Use a lemma of the following form: If no reduction rules apply, there is a spanning

tree with |G|/c leaves of weight ≥ 1 (for some c > 0)

With such a proof, we obtain: If |G| ≥ ck then G has a spanning tree with

|G|/c≥ck/c=k leaves of weight 1 So a spanning tree with leaf weight ≥ k

So if |G| ≥ ck after kernelization we return YES

Otherwise the instance must be small21

Page 22: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

The reduction rules must avoid the following situation: We can build an arbitrarily large graph

with only constant leaf weight in an optimal spanning tree

All reduction rules are needed to prevent such situations

Reduction rules are motivated by examples of the situations they prevent

22

Page 23: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

A set S of vertices is a cutset if their removal splits the graph into multiple connected components

A path component of length k is a path <x,v1,v2, .. , vk,y>, s.t. x, y have degree ≠ 2 all vi have degree 2

23

Page 24: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Vertex of positive weight, with arbitrarily many degree-1 neighbors of weight 0

24

Page 25: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Structure: Vertex x of degree 1 adjacent to y of degree > 1

Operation: Delete x, decrease k by w(x), set w(y) = 0

Justification: Vertex x will be a leaf in any spanning tree The set {y} is a cutset, so y will never be a leaf

in a spanning tree

k’ = k – w(x)

25

Page 26: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

A connected component of arbitrarily many vertices of weight 0

26

Page 27: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Structure: Two adjacent weight-0 vertices x, y

Operation: Contract the edge xy, let w be the merged vertex

Justification: Tree T Tree T’:

▪ There always is an optimal tree that uses xy▪ Add xy to tree, remove an edge from resulting cycle

▪ Vertices xy have weight 0 so no loss of leaf weight▪ Contract the edge xy to obtain T’

Tree T’ Tree T:▪ Split w into two vertices x, y and connect to neighbors

27

Page 28: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Arbitrarily many weight-0 degree-2 vertices with the same neighborhood

28

Page 29: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Structure: Two weight-0 degree-2 vertices u,v with equal

neighborhoods {x,y} The remainder of the graph R is not empty

Operation: Remove v and its incident edges

Justification: {x, y} forms a cutset One of x,y will always be internal in a spanning tree

29

Page 30: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

A necklace of arbitrary lengthEvery pair of positive-weight vertices

forms a cutset, so at most 1 leaf of positive weight

30

Page 31: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Structure: a weight-0 degree-2 vertex with neighbors

x,y a direct edge xy

Operation: remove the edge xy

Justification: You never need xy If xy is used, we might as well remove it and

connect x and y through zSince w(z) = 0, leaf weight does not decrease

31

Page 32: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Three path components of arbitrary length

At most 4 leaves in any spanning tree

32

Page 33: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Structure: Path component <x,v1,v2,..,vp,y> with p ≥ 4

Operation: Replace v2,v3, .. , vp-1 by new vertex v* Weight of v* is maximum of edge endpoints –

max(w(v1),w(vp)) Justification:

The two spanning trees are equivalent If a spanning tree avoids an edge inside the path

component, then the optimal leaf weight gained is equal to the leaf weight gained by avoiding an edge incident on v*

33

Page 34: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

An arbitrarily long cycle with alternating weighted / zero weight vertices

At most one leaf of positive weight

34

Page 35: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Structure: The graph is a simple cycle

Operation: Remove an edge that maximizes the combined

weight of its endpoints Justification:

Any spanning tree for G avoids exactly one edge Avoiding an edge with maximum weight of

endpoints is optimal

35

Page 36: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

These reduction rules are necessary and sufficient for the kernelization claim

Reduction rules do not depend on parameter k Reduced instance is the same, regardless of k

Reduction rules do not depend on planarity of the graph But the structural proof that every reduced instance has

a |G|/c leaf weight spanning tree does depend on k Reduction rules can be executed in linear time Planarity is preserved

We only remove and contract edges Suggests the reduction rules are good preprocessing

rules for any instance of Weighted Max Leaf Even non-planar graphs without given parameter

The structural proof is constructive When the output of kernelization is YES then we can also

find a suitable spanning tree36

Page 37: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

We apply the reduction rules in the given order, until no rule is applicable Can be done in linear time

Reduced graph is still planar, since all we do is: Contract an edge, remove an edge, remove a vertex, re-color a

vertex. Reduced instance is highly structured:

White vertices form an independent set All vertices have degree ≥ 2 No path components of size > 3 …

37

Page 38: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Kernelization yields FPT algorithm First kernelize, then try all possible leaf sets Check whether the complement is a connected

dominating set Planar graphs are sparse, so |E| is O(|V|) Kernelization can be implemented to run in linear time

38

Page 39: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Maximum Leaf Weight Spanning tree is a natural generalization of the Maximum Leaf Spanning Tree problem

It is W[1]-hard on general graphs, so no FPT algorithm

The problem admits a 84k problem kernel on planar graphs

This can be extended to: O(k √g) kernel on graphs of genus g O(k d) kernel on graphs on which every

vertex of positive weight has at most d neighbors

39

Page 40: Fixed parameter tractability and  kernelization  for the Maximum Leaf Weight Spanning Tree problem

Decreasing constant in the kernel size Better mathematical analysis of resulting reduced

instances New reduction rules needed to go below 24k kernel

Classifying complexity of general-graph problem Hardness proof for some W[i] > 1 Membership proof for some W[i]

Determining complexity for real-valued weights

Approximation algorithms Does (Weighted) Max Leaf have a PTAS on planar

graphs?

40