Enhancing Soft Happiness via Evolutionary Algorithms
Abstract
For $0\leq \rho\leq 1$, a $\rho$-happy vertex $v$ in a coloured graph shares colour with at least $\rho\mathrm{deg}(v)$ of its neighbours. Soft happy colouring of a graph $G$ with $k$ colours extends a partial $k$-colouring to a complete vertex $k$-colouring such that the number of $\rho$-happy vertices is maximum among all such colouring extensions. The problem is known to be NP-hard, and an optimal solution has a direct relation with the community structure of the graph. In addition, some heuristics and local search algorithms, such as {\sf Local Maximal Colouring} ({\sf LMC}) and {\sf Local Search} ({\sf LS}), have already been introduced in the literature. In this paper, we design Genetic and Memetic Algorithms for soft happy colouring and test them for a large set of randomly generated partially coloured graphs. Memetic Algorithms yield a higher number of $\rho$-happy vertices, but Genetic Algorithms can perform well only when their initial populations are locally improved by {\sf LMC} or {\sf LS}. Statistically significant results indicate that both Genetic and Memetic Algorithms achieve high average accuracy in community detection when their initial populations are enhanced using {\sf LMC}. Moreover, among the competing methods, the evolutionary algorithms identified the greatest number of complete solutions.