Traditionally, the quality of orthogonal planar drawings is quantified by the total number of bends, or the maximum number of bends per edge. However, this neglects that in typical applications, edges have varying importance. We consider the problem OptimalFlexDraw that is defined as follows. Given a planar graph G on n vertices with maximum degree 4 (4-planar graph) and for each edge e a cost function ${\rm cost}_{e}: \mathbb{N}_{0} \longrightarrow \mathbb{R}$ defining costs depending on the number of bends e has, compute an orthogonal drawing of G of minimum cost.#R##N##R##N#In this generality OptimalFlexDraw is NP-hard. We show that it can be solved efficiently if 1) the cost function of each edge is convex and 2) the first bend on each edge does not cause any cost. Our algorithm takes time O(n ·Tflow(n)) and O(n2 ·Tflow(n)) for biconnected and connected graphs, respectively, where Tflow(n) denotes the time to compute a minimum-cost flow in a planar network with multiple sources and sinks. Our result is the first polynomial-time bend-optimization algorithm for general 4-planar graphs optimizing over all embeddings. Previous work considers restricted graph classes and unit costs.
['Thomas Bläsius', 'Ignaz Rutter', 'Dorothea Wagner']
Optimal orthogonal graph drawing with convex bend costs