The Single-Face Ideal Orientation Problem in Planar Graphs
Abstract
We consider the ideal orientation problem in planar graphs. In this problem, we are given an undirected graph G with positive edge lengths and k pairs of distinct vertices (s1, t1), …, (sk, tk) called terminals, and we want to assign an orientation to each edge such that for all i the distance from si to ti is preserved or report that no such orientation exists. We show that the problem is NP-hard in planar graphs. On the other hand, we show that the problem is polynomial-time solvable in planar graphs when k is fixed, the vertices s1, t1, …, sk, tk are all on the same face, and no two of terminal pairs cross (a pair (si, ti) crosses (sj, tj) if the cyclic order of the vertices is si,sj,ti,tj). For serial instances, we give a simpler and faster algorithm running in O(n n) time, even if k is part of the input. (An instance is serial if the terminals appear in cyclic order u1, v1, …, uk, vk, where for each i we have either (ui, vi) = (si, ti) or (ui, vi) = (ti, si).) Finally, we consider a generalization of the problem in which the sum of the distances from si to ti is to be minimized; in this case we give an algorithm for serial instances running in O(kn5) time.