Algebraic techniques in parameterized algorithms Łukasz Kowalik University of Warsaw FPT School, Będlewo, August 2014 Łukasz Kowalik (UW) Algebraic techniques August 2014 1 / 37
Overview Inclusion-exclusion principle (Tuesday) Polynomials over finite fields of characteristic two (Thursday) Group algebras (Friday) Łukasz Kowalik (UW) Algebraic techniques August 2014 2 / 37
Algebraic techniques in parameterized algorithms, Part I: Inclusion-Exclusion Łukasz Kowalik University of Warsaw FPT School, Będlewo, August 2014 Łukasz Kowalik (UW) Algebraic techniques I August 2014 3 / 37
Inclusion-Exclusion Principle Theorem (Inclusion-Exclusion Principle, intersection version) Let A 1 , . . . , A n ⊆ U, where U is a finite set. Then: � � � ( − 1 ) | X | | | A i | = A i | i ∈ X i ∈{ 1 ,..., n } X ⊆{ 1 ,..., n } where A i = U − A i and � i ∈∅ A i = U. Example. | A ∩ B | = | U | − | A | − | B | + | A ∩ B | U U U 1 − 1 0 A B A B A B 1 1 1 0 1 0 0 1 0 | U | | U | − | A | − | B | | U | − | A | − | B | + | A ∩ B | Łukasz Kowalik (UW) Algebraic techniques I August 2014 4 / 37
Inclusion-Exclusion Principle, intersection version Theorem (Inclusion-Exclusion Principle, intersection version) Let A 1 , . . . , A n ⊆ U, where U is a finite set. ( { A i } n i = 1 = “requirements”.) Denote A i = U − A i and � i ∈∅ A i = U. Then: � � � ( − 1 ) | X | | A i | = | A i | i ∈{ 1 ,..., n } X ⊆{ 1 ,..., n } i ∈ X � �� � “simplified problem” A common algorithmic application Reduce a hard task to 2 n “simplified problems” (solvable in poly-time). IE Łukasz Kowalik (UW) Algebraic techniques I August 2014 5 / 37
The number of Hamiltonian cycles Hamiltonian cycle: a cycle that contains all the vertices. Łukasz Kowalik (UW) Algebraic techniques I August 2014 6 / 37
The number of Hamiltonian cycles Hamiltonian cycle: a cycle that contains all the vertices. Łukasz Kowalik (UW) Algebraic techniques I August 2014 6 / 37
The number of Hamiltonian cycles A walk of length k in G (shortly, a k -walk) is a sequence of vertices v 0 , v 1 , . . . , v k such that v i v i + 1 ∈ E for each i = 0 , . . . , k − 1. v 6 v 1 v 2 = v 5 v 0 v 4 v 7 v 3 Łukasz Kowalik (UW) Algebraic techniques I August 2014 7 / 37
The number of Hamiltonian cycles A walk of length k in G (shortly, a k -walk) is a sequence of vertices v 0 , v 1 , . . . , v k such that v i v i + 1 ∈ E for each i = 0 , . . . , k − 1. v 6 v 1 v 2 = v 5 v 0 v 4 v 7 v 3 A walk is closed , when v 0 = v k . Łukasz Kowalik (UW) Algebraic techniques I August 2014 7 / 37
The number of Hamiltonian cycles A walk of length k in G (shortly, a k -walk) is a sequence of vertices v 0 , v 1 , . . . , v k such that v i v i + 1 ∈ E for each i = 0 , . . . , k − 1. v 6 v 1 v 2 = v 5 v 0 v 4 v 7 v 3 A walk is closed , when v 0 = v k . U is the set of closed n -walks from vertex 1. Łukasz Kowalik (UW) Algebraic techniques I August 2014 7 / 37
The number of Hamiltonian cycles A walk of length k in G (shortly, a k -walk) is a sequence of vertices v 0 , v 1 , . . . , v k such that v i v i + 1 ∈ E for each i = 0 , . . . , k − 1. v 6 v 1 v 2 = v 5 v 0 v 4 v 7 v 3 A walk is closed , when v 0 = v k . U is the set of closed n -walks from vertex 1. A v = the walks from U that visit v , v ∈ V . Łukasz Kowalik (UW) Algebraic techniques I August 2014 7 / 37
The number of Hamiltonian cycles A walk of length k in G (shortly, a k -walk) is a sequence of vertices v 0 , v 1 , . . . , v k such that v i v i + 1 ∈ E for each i = 0 , . . . , k − 1. v 6 v 1 v 2 = v 5 v 0 v 4 v 7 v 3 A walk is closed , when v 0 = v k . U is the set of closed n -walks from vertex 1. A v = the walks from U that visit v , v ∈ V . Then the solution is | � v ∈ V A v | . Łukasz Kowalik (UW) Algebraic techniques I August 2014 7 / 37
The number of Hamiltonian cycles A walk of length k in G (shortly, a k -walk) is a sequence of vertices v 0 , v 1 , . . . , v k such that v i v i + 1 ∈ E for each i = 0 , . . . , k − 1. v 6 v 1 v 2 = v 5 v 0 v 4 v 7 v 3 A walk is closed , when v 0 = v k . U is the set of closed n -walks from vertex 1. A v = the walks from U that visit v , v ∈ V . Then the solution is | � v ∈ V A v | . The simplified problem: | � v ∈ X A v | = the number of closed walks from U in G ′ = G [ V − X ] . Łukasz Kowalik (UW) Algebraic techniques I August 2014 7 / 37
The number of Hamiltonian cycles, cont’d The simplified problem Compute the number of closed n -walks in G ′ that start at vertex 1. Dynamic programming T ( d , x ) = the number of length d walks from 1 to x . T ( d , x ) = � yx ∈ E ( G ′ ) T ( d − 1 , y ) . We return T ( n , 1 ) , DP works in O ( n 3 ) time. Łukasz Kowalik (UW) Algebraic techniques I August 2014 8 / 37
The number of Hamiltonian cycles, cont’d The simplified problem Compute the number of closed n -walks in G ′ that start at vertex 1. Dynamic programming T ( d , x ) = the number of length d walks from 1 to x . T ( d , x ) = � yx ∈ E ( G ′ ) T ( d − 1 , y ) . We return T ( n , 1 ) , DP works in O ( n 3 ) time. Theorem (Kohn, Gottlieb, Kohn 1969, Karp 1982, Bax 1993) We can solve the Hamiltonian Cycle problem (and even find the number of such cycles) in O ( 2 n n 3 ) = 2 n n O ( 1 ) time and polynomial space . Łukasz Kowalik (UW) Algebraic techniques I August 2014 8 / 37
Coloring k -coloring k -coloring of a graph G = ( V , E ) is a function c : V → { 1 , . . . , k } such that for every edge xy ∈ E , c ( x ) � = c ( y ) . Problem Given a graph G = ( V , E ) and k ∈ N decide whether there is a k -coloring of G . Łukasz Kowalik (UW) Algebraic techniques I August 2014 9 / 37
Coloring k -coloring k -coloring of a graph G = ( V , E ) is a function c : V → { 1 , . . . , k } such that for every edge xy ∈ E , c ( x ) � = c ( y ) . Problem Given a graph G = ( V , E ) and k ∈ N decide whether there is a k -coloring of G . History (naive) k n n O ( 1 ) Lawler 1976: Dynamic programming O ( 2 . 45 n ) Björklund, Husfeldt, Koivisto 2006: Inclusion-Exclusion 2 n n O ( 1 ) Łukasz Kowalik (UW) Algebraic techniques I August 2014 9 / 37
Coloring via inclusion-exclusion in 2 n n O ( 1 ) time Observation There is a k -coloring of graph G = ( V , E ) � There is a partition of V into k independent sets Łukasz Kowalik (UW) Algebraic techniques I August 2014 10 / 37
Coloring via inclusion-exclusion, first attempt U is the set of tuples ( I 1 , . . . , I k ) , where I j are independent sets (not necessarily disjoint nor even different!) Łukasz Kowalik (UW) Algebraic techniques I August 2014 11 / 37
Coloring via inclusion-exclusion, first attempt U is the set of tuples ( I 1 , . . . , I k ) , where I j are independent sets (not necessarily disjoint nor even different!) U contains all colorings Łukasz Kowalik (UW) Algebraic techniques I August 2014 11 / 37
Coloring via inclusion-exclusion, first attempt U is the set of tuples ( I 1 , . . . , I k ) , where I j are independent sets (not necessarily disjoint nor even different!) U contains all colorings A v = { ( I 1 , . . . , I k ) ∈ U : there is exactly one j such that v ∈ I j } Łukasz Kowalik (UW) Algebraic techniques I August 2014 11 / 37
Coloring via inclusion-exclusion, first attempt U is the set of tuples ( I 1 , . . . , I k ) , where I j are independent sets (not necessarily disjoint nor even different!) U contains all colorings A v = { ( I 1 , . . . , I k ) ∈ U : there is exactly one j such that v ∈ I j } Then | � v ∈ V A v | is the number of k -colorings. Łukasz Kowalik (UW) Algebraic techniques I August 2014 11 / 37
Coloring via inclusion-exclusion, first attempt U is the set of tuples ( I 1 , . . . , I k ) , where I j are independent sets (not necessarily disjoint nor even different!) U contains all colorings A v = { ( I 1 , . . . , I k ) ∈ U : there is exactly one j such that v ∈ I j } Then | � v ∈ V A v | is the number of k -colorings. The simplified problem: | � v ∈ X A v | = ?? Łukasz Kowalik (UW) Algebraic techniques I August 2014 11 / 37
Coloring via inclusion-exclusion in 2 n n O ( 1 ) time Observation There is a k -coloring of graph G = ( V , E ) � There is a partition of V into k independent sets � there is a cover of V by k independent sets, (i.e. k independent sets I 1 , . . . , I k such that � k j = 1 I j = V .) ⇔ Łukasz Kowalik (UW) Algebraic techniques I August 2014 12 / 37
Coloring in 2 n , cont’d U is the set of tuples ( I 1 , . . . , I k ) , where I j are independent sets Łukasz Kowalik (UW) Algebraic techniques I August 2014 13 / 37
Coloring in 2 n , cont’d U is the set of tuples ( I 1 , . . . , I k ) , where I j are independent sets A v = { ( I 1 , . . . , I k ) ∈ U : v ∈ � k j = 1 I j } Łukasz Kowalik (UW) Algebraic techniques I August 2014 13 / 37
Coloring in 2 n , cont’d U is the set of tuples ( I 1 , . . . , I k ) , where I j are independent sets A v = { ( I 1 , . . . , I k ) ∈ U : v ∈ � k j = 1 I j } Then | � v ∈ V A v | � = 0 iff G is k -colorable. Łukasz Kowalik (UW) Algebraic techniques I August 2014 13 / 37
Recommend
More recommend