arXiv:2611.01012cs.DMOct 2026

Manuscript Offprint

arXiv:2611.01012

Mutual-visibility colouring with two colours is NP-complete for every fixed diameter

Siddhesh Chaubal

SIDDHESH CHAUBAL

ABSTRACT. A mutual-visibility set in a graph GG is a set SS of vertices such that any two vertices of SS are connected by a shortest path with no internal vertex in SS, and the mutual-visibility chromatic number χμ(G)\chi_\mu(G) is the minimum number of mutual-visibility sets needed to partition V(G)V(G). Babu, Di Stefano and Lakshmanan showed that it is NP-complete to decide whether χμ(G)≤2\chi_\mu(G) \leq 2 for graphs of diameter four. We show that the problem remains NP-complete for graphs of diameter dd, for every fixed d≥2d \geq 2; diameter two is the smallest diameter for which the problem is non-trivial. The proof rests on a reformulation of χμ(G)≤2\chi_\mu(G) \leq 2 for diameter-two graphs as the 2-colourability of an associated hypergraph, and on a reduction from 2-colourability of 3-uniform hypergraphs without short cycles.

1. INTRODUCTION

Mutual visibility in graphs was introduced by Di Stefano [6]: a set S⊆V(G)S \subseteq V(G) is called a mutual-visibility set (MV set) of GG if any two vertices u,v∈Su, v \in S are SS-visible, that is, joined by a shortest u,vu, v-path all of whose internal vertices lie outside SS. Klavžar, Kuziak, Valenzuela Tripodoro and Yero [9] introduced the corresponding colouring problem. A partition of V(G)V(G) into MV sets is called a mutual-visibility colouring of GG, and the mutual-visibility chromatic number χμ(G)\chi_\mu(G) is the minimum number of parts in such a partition. They asked about its computational complexity [9, Problem 8.1], and Babu, Di Stefano and Lakshmanan [1] proved that it is NP-complete to decide whether χμ(G)≤2\chi_\mu(G) \leq 2, already for graphs of diameter four. Related variants (independent, total, dual and outer mutual-visibility colourings) are also known to be NP-complete [3, 2].

Graphs of diameter two play a special role for mutual visibility [5]. In such a graph every independent set is an MV set, so χμ(G)≤χ(G)\chi_\mu(G) \leq \chi(G) [9], and the existence of graphs attaining equality other than complete bipartite graphs was recently settled by the author [4]. For graphs of diameter at most one (complete graphs) the problem is trivial. Our main result shows that diameter two is already as hard as the general case.

Theorem 1.1. The following problem is NP-complete: given a graph GG of diameter two, decide whether χμ(G)≤2\chi_\mu(G) \leq 2.

Since a non-complete graph has χμ(G)≥2\chi_\mu(G) \geq 2, Theorem 1.1 equivalently says that it is NP-complete to decide whether χμ(G)=2\chi_\mu(G) = 2 for graphs of diameter two, and computing χμ\chi_\mu is NP-hard on this class. Attaching a suitable ‘ladder’ to the construction extends this to every larger diameter, and in particular recovers the diameter-four case of [1].

Theorem 1.2. For every fixed integer d≥2d \geq 2, the following problem is NP-complete: given a graph GG of diameter dd, decide whether χμ(G)≤2\chi_\mu(G) \leq 2.

2020 Mathematics Subject Classification. 05C15, 05C12, 68Q17.

Key words and phrases. mutual-visibility set, mutual-visibility colouring, diameter two, NP-completeness, hypergraph 2-colouring.

SIDDHESH CHAUBAL

The paper is structured as follows. In Section 2 we show that, for a graph of diameter two, χμ(G)≤2\chi_\mu(G) \leq 2 is equivalent to the 2-colourability of a hypergraph whose edges are the sets {u,w}∪(N(u)∩N(w))\{u, w\} \cup (N(u) \cap N(w)) for non-adjacent pairs u,wu, w. In Section 3 we show that 2-colourability of 3-uniform hypergraphs is NP-complete, and, by a standard gadget argument, that this remains true for hypergraphs without Berge cycles of length two or three. In Section 4 we construct, from such a hypergraph FF, a graph G(F)G(F) of diameter two whose associated hypergraph contains every edge of FF exactly, while all its other edges can be made harmless; this proves Theorem 1.1. In Section 5 we attach to G(F)G(F) a ‘ladder’ of d−2d-2 levels, which raises the diameter to exactly dd without changing whether χμ≤2\chi_\mu \leq 2; this proves Theorem 1.2.