1 / 53

Shira Zucker Ben-Gurion University of the Negev Advisors: Prof. Daniel Berend Prof. Ephraim Korach

Anticoloring for Toroidal Grids. Shira Zucker Ben-Gurion University of the Negev Advisors: Prof. Daniel Berend Prof. Ephraim Korach. The Problem. Anticoloring of a graph : A coloring of some of the vertices in which no two adjacent vertices are colored in distinct colors.

tablita
Download Presentation

Shira Zucker Ben-Gurion University of the Negev Advisors: Prof. Daniel Berend Prof. Ephraim Korach

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. Anticoloring for Toroidal Grids Shira Zucker Ben-Gurion University of the Negev Advisors: Prof. Daniel Berend Prof. Ephraim Korach

  2. The Problem • Anticoloring of a graph: A coloring of some of the vertices in which no two adjacent vertices are colored in distinct colors. • Input: A graph G, positive integers B1,…,Bk. • Output: Yes – if there exists an anticoloring of G such that Bj vertices are colored in color j, j=1,…,k. No – otherwise.

  3. Black and White Coloring (BWC) • Example: • The Anticoloring Problem is NP-complete, even for two colors.

  4. BWC problem • We usually refer to the optimization version of the BWC problem. • We are given a graph G and a positive integer B, and have to color B of the vertices in black, so that there will remain as many vertices as possible which are non-adjacent to any of the B vertices (These vertices are to be colored in white). • W - the maximum possible number of such vertices.

  5. History • Hansen, Hertz and Quinodoz proved that the BWC problem is NP-complete. • They also gave an O(n ) algorithm for trees. • Kobler, Korach and Hertz gave a polynomial algorithm for partial k-trees with fixed k (bounded tree width). 3

  6. Berge’s Problem: Queens • Berge suggested a special instance of the problem: • Given positive integers n and B, place B black and W white queens on an n × n chessboard, so that no black queen and white queen attack each other, and with W as large as possible. • The complexity of the queens problem is still open.

  7. The Rooks Problem • Yahalom investigated an analogous problem to that suggested by Berge, using rooks instead of queens. • She gave a sub-linear algorithm to this problem. • For special cases, in which the ratio between the sides of the board is an integer or close to an integer, she derived an explicit formula for the optimal solution.

  8. The Kings Problem • Problem: Given positive integers m, n and B, place B black and W white kings on an m × ntoroidal chessboard, so that no black king and white king attack each other, and with W as large as possible.

  9. The kings problem – Cont. Remember that we are talking of a toroidal board.

  10. Definitions • A black-white coloring (BWC) of a graph G is a function C: V {black, white, uncolored} such that there is no edge between a black and a white vertex. • Notice: C is uniquely determined by the set of vertices colored in black.

  11. Definitions – Cont. • Completely full row (column): A row (column) all of whose vertices are black. • Almost completely full row (column): A row (column) all of whose vertices but one are black. • The rows of the toroidal board are enumerated by 1,2,…,n. • The columns are enumerated by 1,2,…,m (m ≥ n).

  12. Definitions – Cont. • N(C) – the number of uncolored vertices of a coloring C. • Notice: The problem of maximizing W is equivalent to the problem of minimizing N(C).

  13. Theorem – Part 1 An optimal solution may be constructed, depending on the size of B, as follows: : Let Color in black the set

  14. Theorem – Part 2 : Let Color in black the set

  15. Theorem – Part 3 : Let Color in black the set

  16. Before we prove the theorem… • In order to prove the theorem, we will use several auxiliary lemmas. • The lemmas indicate changes which can be performed in order to achieve a better coloring C’, i.e., with N(C’) ≤ N(C). • The idea: In order to prove the optimality of C, it is enough to consider only the “good candidates” exist. Those candidates are to be found by the following lemmas.

  17. Lemma 1 • Given any coloring C, there exists a coloring C’, which is obtained from C by a permutation of rows (resp. columns), such that all completely and almost completely full rows (resp. columns) are placed in a single block and N(C’) ≤ N(C).

  18. Lemma 1 – Example

  19. Lemma 2 • Given any coloring C with an almost completely full row (resp. column), by replacing the uncolored vertex at that row (resp. column) with any black vertex, we get a new coloring C’ with N(C’) ≤ N(C).

  20. Lemma 2 - Proof • There is only one vertex which may become uncolored. On the other hand, the original uncolored vertex which became black, reduced the number of uncolored vertices by 1. Hence, N(C’) = N(C) or N(C’) = N(C) –1.

  21. Lemma 3 • For any coloring C, if row k contains bk black vertices and row k+1 contains bk+1 black vertices, where max{bk+1,1}≤ bk≤ m-2, then row k+1 contains at least bk –bk+1+2 uncolored vertices.

  22. Lemma 4 • Suppose that a coloring contains black vertices, and that rows n-f+1,…,n are completely full, where f ≤ n-2, but no other rows are such. Let r1 and r2 be the rows with the minimal numbers of black vertices where, say, br1 ≤ br2 . Then br1 ≤ m-f-2-d and br2 ≤ m-f-2+d for some d ≥ 0.

  23. Lemma 4 - Explanation 1 ≤ m-f-2 2 ≤ m-f-2 n = m = 10 f = 2 B = 39 ≤ 62

  24. Lemma 5 • If a coloring C with contains a completely full column, then N(C) ≥ 2n. • The idea of the proof: If each row contains at most m-2 black vertices, then it contains at least 2 uncolored vertices, and altogether we have at least 2n. Otherwise…

  25. Lemma 6 • If a coloring C with contains an almost completely fullcolumn, then N(C) ≥ 2n. • The idea of the proof: Replace the uncolored vertex of an almost completely full column with any black vertex from another column.

  26. Lemma 7 • If a coloring C with contains a completely or an almost completely full row, then N(C) ≥ 2n.

  27. Lemma 7 - Proof • If C contains a completely or an almost completely full column, then, according to Lemmas 5 and 6, N(C) ≥ 2n, and we are done. • Otherwise, C contains no completely or almost completely full column. Since C contains a completely or an almost completely full row, each column of C contains at least two uncolored vertices. Therefore, N(C) ≥ 2m ≥ 2n.

  28. Lemma 7 – Proof – Cont.

  29. Corrollary 8 • If a coloring C with contains less than 2n uncolored vertices, then each of its non-empty rows and columns contains at least two uncolored vertices.

  30. Lemma 9 • If a coloring C with contains no three adjacent empty columns (or rows), then N(C) ≥ 2n.

  31. Lemma 9 - Proof • If C contains a completely or an almost completely full column, then, by Lemmas 5 and 6, N(C) ≥ 2n and we are done. • Assume, therefore, that C contains no completely or almost completely full column.

  32. Lemma 9 – Example Two adjacent empty columns

  33. Lemma 9 – Proof – Cont. • If C contains no three adjacent empty columns, then each empty column is adjacent to a non-empty column and therefore, contains at least three uncolored vertices. • According to Corollary 8, each non-empty column contains at least two uncolored vertices. • Denote by x the number of non-empty columns in C. • We get that N(C) ≥ 2x + 3(m-x) ≥ 2m ≥ 2n.

  34. Lemma 10 • Suppose a coloring C contains three empty columns (rows, resp.), of which two are adjacent, say columns j, m-1, m (rows i, n-1, n, resp.). The coloring C’, obtained from C by moving columns j + 1, j +2, … , m-2 (rows i+1, i+2, …, n-2 resp.) one place to the left (up, resp.), and column j immediately to their right (row i immediately under them, resp.), satisfies N(C’) ≤ N(C).

  35. Lemma 10 – Cont.

  36. Lemma 11 Three kinds of changes in a coloring C, which do not increase N(C).

  37. Lemma 12 • If a coloring C contains exactly c non-empty columns, which are all adjacent, and exactly r non-empty rows, which are also adjacent, where 1≤ c≤ m-2 and 1≤ r≤ n-2, then N(C) ≥ 2c+2r+4.

  38. Lemma 12 Sketch of the proof We build C’ with K rectangles of sizes ci × ri. ∑ ci≥ c ∑ ri ≥ r

  39. Conclusion of the Proof for Small B • Consider . • C0 – the square configuration of the theorem. • Suppose there exists a coloring C with N(C) < N(C0) (and with the same B). • N(C0) = . • Therefore, according to Lemmas 5, 6 and 7, C does not contain any completely or almost completely full column or row.

  40. Small B – Cont. • According to Lemma 9, C contains at least 3 adjacent empty columns and at least 3 adjacent empty rows. • By Lemma 10, we can combine all empty columns and rows into one block, thus get a c × r rectangle, where c ≤ m-3, r ≤ n-3, and each row and column contains at least one black vertex.

  41. Small B – Cont. • By Lemma 12, we have N(C) ≥ 2c+2r+4. • Since cr ≥ B, we get which contradicts our assumption.

  42. The idea of the Proof for Intermediate B • Consider . • Most lemmas we used in the proof for small B were of the type: if…. then N(C) ≥ 2n. • Here we use the same lemmas, in a similar way, but with N(C) ≥ 2n + “something”, where “something” is equal to 0, 1 or 2. • The proof is more complicated and divided into some parts.

  43. Proposition • N(B) – the minimal possible number of uncolored vertices for B black vertices in a graph G. • Proposition: Given a graph G=(V,E) and a number 0 ≤ B ≤ |V|, we have N(|V|-B-N(B)) ≤ N(B).

  44. Conclusion of the Proof for Large B • Consider . • C0 – the co-square configuration of the theorem. • Suppose there exists a coloring C with N(C) < N(C0) (and with the same B). • N(C0) = . Denote B’:=mn-B-N(B). • 0 ≤ B’ ≤ mn-B < . • By the proposition, N(B’) ≤ N(B).

  45. Large B – Cont. • Assume first that We showed that for those B', N(B') ≥ 2n. • Now,

  46. Large B – Cont. • Therefore, and we have a contradiction.

  47. Large B – Cont. If then we compare N(B) to N(B’) and get to a contradiction by using the same principle as before, this time with the ‘square configuration’.

  48. Union of Components • Input: A graph G=(V,E) where and . A number 1 ≤ B ≤ |V| and an optimal anticoloring Ck for each connected component Gk with 1 ≤ b ≤ B black vertices. • Output: An optimal anticoloring C For G with B black vertices.

  49. Union of Components – Cont. • N(G,B) - the minimal number of uncolored vertices of a graph G with B black vertices. • Our algorithm use a dynamic programming.

  50. Basic Algorithmfor finding N(G,B) union(G,B) for l=2 to n by l l*2 for i=1 to n-l+1 by i i+l j i+l-1 for b=0 to B for bb=0 to b q m[i,k,bb]+m[k+1,j,b-bb] if q<m[i,j,b] then m[i,j,b] q

More Related