A k-L(2, 1)-labeling of a graph is a mapping from its vertex set into a set of integers {0, ... , k} such that adjacent vertices get labels that differ by at least 2 and vertices in distance 2 get different labels. The main result of the paper is an algorithm finding an optimal L(2, 1)-labeling of a graph (i.e. an L(2, 1)-labeling in which the largest label is the least possible) in time 0*(7.4922(n)) and polynomial space.
Then we adapt our method to obtain a faster algorithm for k-L(2, 1)-labeling, where k is a small positive constant. Moreover, a new interesting extremal graph theoretic problem is defined and solved.