An O(nm) time algorithm for finding the min length directed cycle in a graph

James B. Orlin, Antonio Sedeño‐Noda · 2017

In this paper, we introduce an O(nm) time algorithm to determine the minimum length directed cycle (also called the "minimum weight directed cycle") in a directed network with n nodes and m arcs and with no negative length directed cycles.This result improves upon the previous best time bound of O(nm + n 2 log log n).Our algorithm first determines the cycle with minimum mean length λ * in O(nm) time.Subsequently, it chooses node potentials so that all reduced costs are λ * or greater.It then solves the all pairs shortest path problem, but restricts attention to paths of length at most nλ * .We speed up the shortest path calculations to O(m) per source node, leading to an O(nm) running time in total.We also carry out computational experiments comparing the performance of the proposed methods and other state-of-the-art methods.Experiments confirmed that it is advantageous to solve the minimum mean cycle problem prior to solving shortest path problems.Analysis of our experiments suggest that the running time to solve the minimum length directed cycle problem was much faster than O(n 2 ) on average. Introduction.We address the determination of the Minimum Length Directed Cycle (MLDC) in a graph G = (V, A) with n nodes and m arcs and with no negative length directed cycles.(Elsewhere, researchers have referred to the MLDC as the minimum weight directed cycle or the minimum cost directed cycle.)Floyd [12] and Warshall [32] showed how to solve this problem in O(n 3 ) time.An alternative approach is to find shortest paths between all pairs of nodes.In case there are negative length arcs, the first shortest path problem is solved using the label correcting algorithm.Subsequently, one can use reduced costs to transform the problem into an equivalent problem with nonnegative arc lengths.The subsequent n -1 shortest path problems are solved using Dijkstra's Algorithm.Using the shortest path algorithm of Fredman and Tarjan [14], the running time *

Read the paper · More papers on PaperTik