Skip to main content
QUICK REVIEW

[Paper Review] Finding Optimal Longest Paths by Dynamic Programming in Parallel

Kai Fieger, Tomáš Balyo|arXiv (Cornell University)|May 8, 2019
Graph Theory and Algorithms15 references5 citations
TL;DR

This paper presents LPDP, an exact dynamic programming algorithm for finding optimal longest simple paths in undirected weighted graphs by leveraging graph partitioning and parallelization. It achieves significant speedups—up to 11.69 total speedup with 64 threads—on hard instances, outperforming prior exact methods and enabling the solution of previously unsolved problems.

ABSTRACT

We propose an exact algorithm for solving the longest simple path problem between two given vertices in undirected weighted graphs. By using graph partitioning and dynamic programming, we obtain an algorithm that is significantly faster than other state-of-the-art methods. This enables us to solve instances that were previously unsolved and solve hard instances significantly faster. Lastly, we present a scalable parallelization which yields the first efficient parallel algorithm for the problem.

Motivation & Objective

  • To develop an exact algorithm for the longest path problem that outperforms existing state-of-the-art methods in solving hard and previously unsolved instances.
  • To design a scalable parallelization strategy for the longest path problem, which is the first efficient parallel exact algorithm for this NP-complete problem.
  • To evaluate the performance of the proposed algorithm on real-world and benchmark graphs, focusing on speedup and scalability across varying thread counts.
  • To identify and filter out 'easy' problems that do not benefit from parallelization, enabling fair comparison of speedup on computationally challenging instances.

Proposed method

  • The algorithm uses graph partitioning to divide the vertex set into balanced blocks with minimal inter-block edge cuts, reducing the search space.
  • Dynamic programming is applied within and across partitions, storing partial path solutions to avoid recomputation and ensure optimality.
  • A shared-memory parallelization model is employed, where each thread handles a subset of the partitioned graph, with synchronization to merge partial results.
  • The algorithm is optimized to handle both unweighted and weighted graphs, with edge weights treated as path length contributions.
  • A time-limit-based evaluation strategy is used, with parallel solvers given shorter time limits than the serial solver to ensure fair comparison.
  • The method includes a filtering mechanism to isolate 'big' problems—those taking more than 5× the number of threads in seconds—where parallelization yields measurable benefits.

Experimental results

Research questions

  • RQ1Can dynamic programming combined with graph partitioning significantly improve the performance of exact longest path algorithms on hard instances?
  • RQ2What is the achievable speedup of a parallelized dynamic programming approach for the longest path problem in shared-memory systems?
  • RQ3How does the performance of the parallel algorithm vary with increasing thread counts, and where does diminishing returns set in?
  • RQ4Which problem characteristics (e.g., size, density, structure) make instances suitable for parallel acceleration versus serial processing?
  • RQ5Can the proposed algorithm solve previously unsolved longest path instances that were intractable for prior methods?

Key findings

  • The LPDP algorithm solved 15 more benchmark instances than the serial baseline within a 32-minute time limit, demonstrating superior scalability and performance.
  • With 64 threads, the total speedup reached 11.691, indicating that the algorithm effectively leverages high parallelism on hard instances.
  • The average speedup across all problems remained below 2.5, indicating that overhead from parallelization dominates on easy instances, which are not worth parallelizing.
  • For 'big' problems (defined as those taking >5× the number of threads in seconds), the median speedup increased significantly, with 64-thread performance achieving 17.0% additional speedup over 32 threads.
  • The 32- and 64-thread solvers achieved median speedups below 1.0, confirming that parallelization is counterproductive for easy problems due to overhead.
  • The algorithm outperforms prior exact methods and is the first to provide an efficient, scalable parallel solution to the exact longest path problem.

Better researchstarts right now

From reading papers to final review, dramatically reduce your research time.

No credit card · Free plan available

This review was created by AI and reviewed by human editors.