Maximizing Happiness in Graphs of Bounded Clique-Width

  • Ivan Bliznets
  • Danil SagunovEmail author
Conference paper
Part of the Lecture Notes in Computer Science book series (LNCS, volume 12118)


Clique-width is one of the most important parameters that describes structural complexity of a graph. Probably, only treewidth is more studied graph width parameter. In this paper we study how clique-width influences the complexity of the Maximum Happy Vertices (MHV) and Maximum Happy Edges (MHE) problems. We answer a question of Choudhari and Reddy ’18 about parameterization by the distance to threshold graphs by showing that MHE is \(\mathrm {NP}\)-complete on threshold graphs. Hence, it is not even in \(\mathrm {XP}\) when parameterized by clique-width, since threshold graphs have clique-width at most two. As a complement for this result we provide a \(n^{\mathcal {O}(\ell \cdot \mathrm {cw})}\) algorithm for MHE, where \(\ell \) is the number of colors and \(\mathrm {cw}\) is the clique-width of the input graph. We also construct an \(\mathrm {FPT}\) algorithm for MHV with running time \(\mathcal {O}^*((\ell +1)^{\mathcal {O}(\mathrm {cw})})\), where \(\ell \) is the number of colors in the input. Additionally, we show \(\mathcal {O}(\ell n^2)\) algorithm for MHV on interval graphs.


  1. 1.
    Agrawal, A.: On the parameterized complexity of happy vertex coloring. In: Brankovic, L., Ryan, J., Smyth, W.F. (eds.) IWOCA 2017. LNCS, vol. 10765, pp. 103–115. Springer, Cham (2018). Scholar
  2. 2.
    Aravind, N.R., Kalyanasundaram, S., Kare, A.S.: Linear time algorithms for happy vertex coloring problems for trees. In: Mäkinen, V., Puglisi, S.J., Salmela, L. (eds.) IWOCA 2016. LNCS, vol. 9843, pp. 281–292. Springer, Cham (2016). Scholar
  3. 3.
    Aravind, N., Kalyanasundaram, S., Kare, A.S., Lauri, J.: Algorithms and hardness results for happy coloring problems. arXiv preprint arXiv:1705.08282 (2017)
  4. 4.
    Bliznets, I., Sagunov, D.: Lower bounds for the happy coloring problems. In: Du, D.-Z., Duan, Z., Tian, C. (eds.) COCOON 2019. LNCS, vol. 11653, pp. 490–502. Springer, Cham (2019). Scholar
  5. 5.
    Bliznets, I., Sagunov, D.: On happy colorings, cuts, and structural parameterizations. In: Sau, I., Thilikos, D.M. (eds.) WG 2019. LNCS, vol. 11789, pp. 148–161. Springer, Cham (2019). Scholar
  6. 6.
    Choudhari, J., Reddy, I.V.: On structural parameterizations of happy coloring, empire coloring and boxicity. In: Rahman, M.S., Sung, W.-K., Uehara, R. (eds.) WALCOM 2018. LNCS, vol. 10755, pp. 228–239. Springer, Cham (2018). Scholar
  7. 7.
    Courcelle, B., Olariu, S.: Upper bounds to the clique width of graphs. Discrete Appl. Math. 101(1–3), 77–114 (2000)Google Scholar
  8. 8.
    Cygan, M., et al.: Parameterized Algorithms. Springer, Cham (2015). Scholar
  9. 9.
    Diestel, R.: Graph Theory. Springer, Heidelberg (2018). Scholar
  10. 10.
    Espelage, W., Gurski, F., Wanke, E.: How to solve NP-hard graph problems on clique-width bounded graphs in polynomial time. In: Brandstädt, A., Le, V.B. (eds.) WG 2001. LNCS, vol. 2204, pp. 117–128. Springer, Heidelberg (2001). Scholar
  11. 11.
    Fomin, F.V., Golovach, P.A., Lokshtanov, D., Saurabh, S.: Almost optimal lower bounds for problems parameterized by clique-width. SIAM J. Comput. 43(5), 1541–1563 (2014)MathSciNetCrossRefGoogle Scholar
  12. 12.
    Gerber, M.U., Kobler, D.: Algorithms for vertex-partitioning problems on graphs with fixed clique-width. Theor. Comput. Sci. 299(1–3), 719–734 (2003)MathSciNetCrossRefGoogle Scholar
  13. 13.
    Giménez, O., Hliněný, P., Noy, M.: Computing the tutte polynomial on graphs of bounded clique-width. In: Kratsch, D. (ed.) WG 2005. LNCS, vol. 3787, pp. 59–68. Springer, Heidelberg (2005). Scholar
  14. 14.
    Hartmann, T.A.: Target set selection parameterized by clique-width and maximum threshold. In: Tjoa, A.M., Bellatreche, L., Biffl, S., van Leeuwen, J., Wiedermann, J. (eds.) SOFSEM 2018. LNCS, vol. 10706, pp. 137–149. Springer, Cham (2018). Scholar
  15. 15.
    Hliněnỳ, P., Oum, S., Seese, D., Gottlob, G.: Width parameters beyond tree-width and their applications. Comput. J. 51(3), 326–362 (2007)CrossRefGoogle Scholar
  16. 16.
    Kobler, D., Rotics, U.: Polynomial algorithms for partitioning problems on graphs with fixed clique-width. In: Proceedings of the 12th Annual ACM-SIAM Symposium on Discrete algorithms, SODA 2001, pp. 468–476. SIAM (2001)Google Scholar
  17. 17.
    Kobler, D., Rotics, U.: Edge dominating set and colorings on graphs with fixed clique-width. Discrete Appl. Math. 126(2–3), 197–221 (2003)MathSciNetCrossRefGoogle Scholar
  18. 18.
    Lackner, M., Pichler, R., Rümmele, S., Woltran, S.: Multicut on graphs of bounded clique-width. In: Lin, G. (ed.) COCOA 2012. LNCS, vol. 7402, pp. 115–126. Springer, Heidelberg (2012). Scholar
  19. 19.
    Lewis, R., Thiruvady, D., Morgan, K.: Finding happiness: an analysis of the maximum happy vertices problem. Comput. Oper. Res. 103, 265–276 (2019)MathSciNetCrossRefGoogle Scholar
  20. 20.
    Lozin, V.V.: Clique-width of unit interval graphs. arXiv:0709.1935 preprint (2007)
  21. 21.
    Mahadev, N.V.R., Peled, U.N.: Threshold Graphs and Related Topics. Elsevier, Amsterdam (1995)zbMATHGoogle Scholar
  22. 22.
    Mahadev, N., Peled, U.: Threshold Graphs and Related Topics. In: Annals of Discrete Mathematics, vol. 56. North Holland (1995)Google Scholar
  23. 23.
    Makowsky, J.A., Rotics, U., Averbouch, I., Godlin, B.: Computing graph polynomials on graphs of bounded clique-width. In: Fomin, F.V. (ed.) WG 2006. LNCS, vol. 4271, pp. 191–204. Springer, Heidelberg (2006). Scholar
  24. 24.
    Misra, N., Reddy, I.V.: The parameterized complexity of happy colorings. In: Brankovic, L., Ryan, J., Smyth, W.F. (eds.) IWOCA 2017. LNCS, vol. 10765, pp. 142–153. Springer, Cham (2018). Scholar
  25. 25.
    Xu, Y., Goebel, R., Lin, G.: Submodular and supermodular multi-labeling, and vertex happiness. arXiv e-prints p. 1606.03185 (2016)Google Scholar
  26. 26.
    Zhang, P., Jiang, T., Li, A.: Improved approximation algorithms for the maximum happy vertices and edges problems. In: Xu, D., Du, D., Du, D. (eds.) COCOON 2015. LNCS, vol. 9198, pp. 159–170. Springer, Cham (2015). Scholar
  27. 27.
    Zhang, P., Li, A.: Algorithmic aspects of homophyly of networks. Theor. Comput. Sci. 593, 117–131 (2015)MathSciNetCrossRefGoogle Scholar
  28. 28.
    Zhang, P., Xu, Y., Jiang, T., Li, A., Lin, G., Miyano, E.: Improved approximation algorithms for the maximum happy vertices and edges problems. Algorithmica 80(5), 1412–1438 (2018)MathSciNetCrossRefGoogle Scholar

Copyright information

© Springer Nature Switzerland AG 2020

Authors and Affiliations

  1. 1.St. Petersburg Department of Steklov Mathematical Institute of Russian Academy of SciencesSt. PetersburgRussia

Personalised recommendations