pith. sign in

arxiv: 2403.12734 · v2 · pith:L62RU4XAnew · submitted 2024-03-19 · 💻 cs.DS · cs.DM· math.CO

Exact and Heuristic Computation of the Scanwidth of Directed Acyclic Graphs

Pith reviewed 2026-05-24 03:49 UTC · model grok-4.3

classification 💻 cs.DS cs.DMmath.CO
keywords scanwidthdirected acyclic graphphylogenetic networkfixed-parameter tractabilitydynamic programmingtreewidthheuristic
0
0 comments X

The pith

A dynamic programming algorithm computes the exact scanwidth of single-rooted DAGs in O(k n^k m) time.

A machine-rendered reading of the paper's core claim, the machinery that carries it, and where it could break.

The paper presents the first efficient exact algorithm for computing scanwidth, a measure of tree-likeness for directed acyclic graphs that accounts for arc directions. For single-rooted DAGs with scanwidth k the running time is O(k n^k m). This matters because it enables precise analysis of phylogenetic networks used to model species evolution. The same approach yields a fixed-parameter tractable algorithm for networks with small level ell. Practical tests show the method handles synthetic networks with 30 reticulations and 100 leaves in under 500 seconds, and a proposed heuristic achieves an average approximation ratio of 1.5.

Core claim

The authors introduce the first algorithm for efficiently computing the exact scanwidth of general directed acyclic graphs. For single-rooted DAGs with scanwidth k the algorithm runs in O(k n^k m) time. It also serves as a fixed-parameter tractable algorithm for phylogenetic networks of level ell with time O(2 to the 4ell minus 1 times ell times n plus n squared). The method computes scanwidth for networks with up to 30 reticulations in reasonable time and a heuristic provides approximations with average ratio 1.5, while scanwidth is shown to be at least the treewidth of the underlying undirected graph.

What carries the argument

A dynamic programming algorithm that tracks reachable states to find the minimum scanwidth over orderings of a single-rooted DAG.

If this is right

  • Exact scanwidth computation becomes feasible for single-rooted DAGs whenever k is small.
  • Phylogenetic networks of level ell admit fixed-parameter tractable scanwidth computation linear in n but exponential in ell.
  • A simple heuristic yields approximations whose average ratio is 1.5 on networks with dozens of reticulations.
  • Scanwidth is always at least as large as the treewidth of the underlying undirected graph.
  • For phylogenetic networks the two parameters are typically close in value.

Where Pith is reading between the lines

These are editorial extensions of the paper, not claims the author makes directly.

  • The same DP states could be reused to compute related width parameters on the same DAGs without restarting the search.
  • Because the algorithm is FPT in level, it may combine with existing level-bounded kernels for other network problems.
  • The observed proximity of scanwidth to treewidth suggests that undirected treewidth tools might already give tight bounds on many real networks.
  • The practical scaling to 100 leaves indicates the method could be embedded in existing phylogenetic software pipelines.

Load-bearing premise

The input graphs must be directed acyclic and have exactly one root for the main running-time bound to apply.

What would settle it

A single-rooted DAG whose true minimum scanwidth differs from the value returned by the algorithm on that input.

Figures

Figures reproduced from arXiv: 2403.12734 by Leo van Iersel, Mark Jones, Niels Holtgrefe.

Figure 1
Figure 1. Figure 1: A DAG with a single root (a), and a tree extension of the DAG (b), functioning as a route for the scanner lines. The tree extension is [PITH_FULL_IMAGE:figures/full_fig_p002_1.png] view at source ↗
Figure 2
Figure 2. Figure 2: (a): Weakly connected DAG G. (b): An extension σ of G with the arcs of G also drawn. (c): A tree extension Γ of G indicated by the grey arcs, whose direction is downwards. The arcs of G are also drawn in Γ and are made to follow the grey arcs. (d): A tree H on V(G) that is not a tree extension, because z and c are not comparable in H, while they are adjacent in G. Visually this means that the corresponding… view at source ↗
Figure 3
Figure 3. Figure 3: (a): Weakly connected DAG G. (b): An optimal extension σ of G with cutwidth 4, attained at the red cut. (c): A non-optimal extension π of G with cutwidth 5, attained at the red cut. It is implictly shown in [2] that computing the cutwidth of a DAG is NP-hard. Regarding exact algorithms, one can compute the cutwidth of a DAG in O˜(2n ) time [15]. The theoretically fastest parametrized algorithm for the cutw… view at source ↗
Figure 4
Figure 4. Figure 4: (a): Weakly connected, rooted DAG G. (b): Optimal canonical tree extension Γ σ with scanwidth 3, attained at the vertex v. (c): Non￾canonical tree extension Γ ′ with scanwidth 4, attained at the vertex z. (d): Optimal extension σ with scanwidth 3, attained at the vertex v. For each i ≤ 8, the outermost grey shaded areas containing only vertices belonging to σ[1 . . . i] depict the weakly connected componen… view at source ↗
Figure 5
Figure 5. Figure 5: (a): The ladder-graph Ln (with n ≥ 3), which is a rooted binary network with level n − 1 and 2n vertices. (b): An optimal tree extension Γ1 of Ln with scanwidth 3. (c): The worst-case tree extension Γ2 of Ln with scanwidth n. 3. Reduction rules Before discussing algorithms that compute the scanwidth and find its corresponding (tree) extension, we present some reduction rules. In Subsection 3.1 we will expl… view at source ↗
Figure 6
Figure 6. Figure 6: (a): A multi-rooted weakly connected DAG [PITH_FULL_IMAGE:figures/full_fig_p009_6.png] view at source ↗
Figure 7
Figure 7. Figure 7: Illustration of the decomposition algorithm. The first graph shows the original graph. Then, the graph is split into its s-blocks. Thereafter, [PITH_FULL_IMAGE:figures/full_fig_p011_7.png] view at source ↗
Figure 8
Figure 8. Figure 8: (a): A weakly connected DAG G = (V, E), with the colors indicating an ordered 3-partition P = (L, W, R) of V. (b): An extension σ of G which is a concatenation of extensions of the three subgraphs induced by the partition P. (c): The same extension σ but with a ‘window’ drawn around the vertices in W, aiding the interpretation of partial scanwidth. The arcs between a pair of vertices within L or a pair ver… view at source ↗
Figure 9
Figure 9. Figure 9: Example illustrating an iteration of Algorithm 2. (a): The weakly connected DAG [PITH_FULL_IMAGE:figures/full_fig_p014_9.png] view at source ↗
Figure 10
Figure 10. Figure 10: Example illustrating an iteration of Algorithm 3. (a): The weakly connected DAG [PITH_FULL_IMAGE:figures/full_fig_p016_10.png] view at source ↗
Figure 11
Figure 11. Figure 11: (a): Weakly connected DAG G with unit weights on all arcs. C1 is a non-trivial DAG-cut of weight 5; C2 is a smallest non-trivial DAG-cut of weight 4; C3 is a trivial DAG-cut; C4 is a directed cut that is not a DAG-cut, because it does not cut off a sinkset; C5 is a directed cut that is not a DAG-cut, because the cut is not minimal (in particular, C3 is a cut with a cut-set contained in the cut-set of C5).… view at source ↗
Figure 12
Figure 12. Figure 12: (a): Weakly connected DAG G, with the unique minimum non-trivial DAG-cut C. (b): Weighted graphs H1 and H2 created after one iteration of Algorithm 4. The arc ρx has a weight of 2, while the other arcs have unit weights. The two ‘supervertices’ x and y are in black. (c): Canonical tree extension Γ1 corresponding to the extension obtained by Algorithm 4. The cut C appears again. The tree extension is not o… view at source ↗
Figure 13
Figure 13. Figure 13: (a): The extended ladder-graph L′ n (with n ≥ 3), which is a weakly connected DAG. (b): An optimal tree extension Γ1 of L ′ n with scanwidth 5. (c): The worst-case tree extension Γ2 of L ′ n with scanwidth n. This is the canonical tree extension of the extension returned by the greedy heuristic. 24 [PITH_FULL_IMAGE:figures/full_fig_p024_13.png] view at source ↗
Figure 14
Figure 14. Figure 14: Variation in level, scanwidth and treewidth within each dataset. The figure displays a boxplot for each of the nine subsets of the [PITH_FULL_IMAGE:figures/full_fig_p026_14.png] view at source ↗
Figure 15
Figure 15. Figure 15: Performance of the decomposition method (Algorithm 1). Figure (a) depicts how many vertices remain after the decomposition, as [PITH_FULL_IMAGE:figures/full_fig_p026_15.png] view at source ↗
Figure 16
Figure 16. Figure 16: Performance of the exact algorithms. For each algorithm, the completion rate, calculated as the number of instances per data set where [PITH_FULL_IMAGE:figures/full_fig_p027_16.png] view at source ↗
Figure 17
Figure 17. Figure 17: Performance of the different heuristics. Boxplots are shown for each of the nine subsets of the synthetic data and the real dataset. The boxplots show the quartiles of the data and its outliers. Figure (a) displays the practical approximation ratios, while Figure (b) depicts the computation times. The computation times for simulated annealing (SA) include the computation time to obtain the initial tree ex… view at source ↗
read the original abstract

To measure the tree-likeness of a directed acyclic graph (DAG), a new width parameter that considers the directions of the arcs was recently introduced: scanwidth. We present the first algorithm that efficiently computes the exact scanwidth of general DAGs. For DAGs with one root and scanwidth $k$ it runs in $O(k \cdot n^k \cdot m)$ time. The algorithm also functions as an FPT algorithm with complexity $O(2^{4 \ell - 1} \cdot \ell \cdot n + n^2)$ for phylogenetic networks of level-$\ell$, a type of DAG used to depict evolutionary relationships among species. Our algorithm performs well in practice, being able to compute the scanwidth of synthetic networks up to 30 reticulations and 100 leaves within 500 seconds. Furthermore, we propose a heuristic that obtains an average practical approximation ratio of 1.5 on these networks. While we prove that the scanwidth is bounded from below by the treewidth of the underlying undirected graph, experiments suggest that for networks the parameters are close in practice.

Editorial analysis

A structured set of objections, weighed in public.

Desk editor's note, referee report, simulated authors' rebuttal, and a circularity audit. Tearing a paper down is the easy half of reading it; the pith above is the substance, this is the friction.

Referee Report

1 major / 0 minor

Summary. The manuscript presents the first algorithm for exact computation of scanwidth on general DAGs. For single-root DAGs with scanwidth k the running time is O(k · n^k · m). The same approach yields an FPT algorithm O(2^{4ℓ-1} · ℓ · n + n²) for level-ℓ phylogenetic networks. Experiments show the algorithm solves synthetic networks with 30 reticulations and 100 leaves in under 500 seconds; a heuristic achieves average approximation ratio 1.5. The paper also proves scanwidth is at least the treewidth of the underlying undirected graph.

Significance. If the algorithmic claims hold, the work is significant: it supplies the first exact polynomial-time (for fixed k) method for a directed width parameter on DAGs, supplies an FPT result tailored to phylogenetic networks, and demonstrates practical scalability together with a usable heuristic. The treewidth lower bound supplies a clean theoretical anchor. These elements together advance the study of tree-likeness measures that respect arc directions.

major comments (1)
  1. [Abstract] Abstract: the central claim is that the algorithm 'efficiently computes the exact scanwidth of general DAGs,' yet the only runtime stated is O(k · n^k · m) for 'DAGs with one root.' No runtime, reduction, or separate case analysis is supplied for DAGs with multiple sources. Because the single-root restriction is load-bearing for the 'first efficient algorithm for general DAGs' claim, this gap must be resolved.

Simulated Author's Rebuttal

1 responses · 0 unresolved

We thank the referee for the positive assessment of our work's significance and for the constructive comment. We address the single major comment below and will make the necessary revisions to the manuscript.

read point-by-point responses
  1. Referee: [Abstract] Abstract: the central claim is that the algorithm 'efficiently computes the exact scanwidth of general DAGs,' yet the only runtime stated is O(k · n^k · m) for 'DAGs with one root.' No runtime, reduction, or separate case analysis is supplied for DAGs with multiple sources. Because the single-root restriction is load-bearing for the 'first efficient algorithm for general DAGs' claim, this gap must be resolved.

    Authors: We agree that the abstract phrasing is imprecise and that the stated runtime applies specifically to single-root DAGs. The dynamic programming approach relies on a single source to initialize the scan order, and the manuscript does not supply a formal reduction, runtime bound, or case analysis for multi-source DAGs. We will revise the abstract to state that the algorithm efficiently computes the exact scanwidth of single-root DAGs (with the given runtime) and will add a clarifying remark in the introduction and conclusion noting the single-root scope of the current result. This addresses the gap without altering the technical claims. revision: yes

Circularity Check

0 steps flagged

No circularity; algorithmic claims are self-contained

full rationale

The paper introduces a new algorithm for exact scanwidth computation on DAGs together with explicit runtime bounds (O(k n^k m) for single-root cases, O(2^{4ℓ-1} ℓ n + n^2) FPT for level-ℓ networks). No parameter is fitted to data and then re-used as a prediction, no self-citation supplies a uniqueness theorem or ansatz that the present work relies upon, and no derivation step reduces by construction to its own inputs. The stated time bounds and practical experiments are independent of the target result.

Axiom & Free-Parameter Ledger

0 free parameters · 0 axioms · 0 invented entities

This is an algorithmic paper on an existing graph parameter; it introduces no free parameters, axioms, or invented entities.

pith-pipeline@v0.9.0 · 5733 in / 1029 out tokens · 43113 ms · 2026-05-24T03:49:51.889850+00:00 · methodology

discussion (0)

Sign in with ORCID, Apple, or X to comment. Anyone can read and Pith papers without signing in.

Reference graph

Works this paper leans on

36 extracted references · 36 canonical work pages

  1. [1]

    Springer, doi: 10.1007/978-3-662-53622-3

    R. Diestel, Graph Theory, Springer Berlin Heidelberg, 2017.doi:10.1007/978-3-662-53622-3

  2. [2]

    Berry, C

    V . Berry, C. Scornavacca, M. Weller, Scanning phylogenetic networks is NP-hard, in: 46th International Conference on Current Trends in Theory and Practice of Informatics (SOFSEM 2020), 2020, pp. 519–530.doi:10.1007/978-3-030-38919-2_42

  3. [3]

    Rabier, V

    C.-E. Rabier, V . Berry, M. Stoltz, J. D. Santos, W. Wang, J.-C. Glaszmann, F. Pardi, C. Scornavacca, On the inference of complex phylogenetic networks by Markov chain Monte-Carlo, PLOS Comput. Biol. 17 (9) (2021).doi:10.1371/journal.pcbi.1008380

  4. [4]

    van Iersel, M

    L. van Iersel, M. Jones, M. Weller, Embedding phylogenetic trees in networks of low treewidth, Discret. Math. Theor. Comput. Sci. 25:2 (4) (2023).doi:10.46298/dmtcs.10116

  5. [5]

    van Iersel, S

    L. van Iersel, S. Kelk, G. Stamoulis, L. Stougie, O. Boes, On unrooted and root-uncertain variants of several well-known phylogenetic network problems, Algorithmica 80 (11) (2017) 2993–3022.doi:10.1007/s00453-017-0366-5

  6. [6]

    Scornavacca, M

    C. Scornavacca, M. Weller, Treewidth-based algorithms for the small parsimony problem on networks, Algorithms Mol. Biol. 17 (1) (2022). doi:10.1186/s13015-022-00216-w

  7. [7]

    Bernardini, L

    G. Bernardini, L. van Iersel, E. Julien, L. Stougie, Constructing phylogenetic networks via cherry picking and machine learning, Algorithms Mol. Biol. 18 (1) (2023) 13.doi:10.1186/s13015-023-00233-3. 31

  8. [8]

    Borst, L

    S. Borst, L. van Iersel, M. Jones, S. Kelk, New FPT algorithms for finding the temporal hybridization number for sets of phylogenetic trees, Algorithmica 84 (7) (2022) 2050–2087.doi:10.1007/s00453-022-00946-8

  9. [9]

    van Iersel, S

    L. van Iersel, S. Kelk, R. Rupp, D. Huson, Phylogenetic networks do not need to be complex: using fewer reticulations to represent conflicting clusters, Bioinformatics 26 (12) (2010) i124–i131.doi:10.1093/bioinformatics/btq202

  10. [10]

    Bulteau, M

    L. Bulteau, M. Weller, Parameterized algorithms in bioinformatics: an overview, Algorithms 12 (12) (2019) 256.doi:10.3390/a12120256

  11. [11]

    Magne, C

    L. Magne, C. Paul, A. Sharma, D. M. Thilikos, Edge-treewidth: Algorithmic and combinatorial properties, Discret. Appl. Math. 341 (2023) 40–54.doi:10.1016/j.dam.2023.07.023

  12. [12]

    H. L. Bodlaender, M. R. Fellows, D. M. Thilikos, Derivation of algorithms for cutwidth and related graph layout parameters, J. Comput. Syst. Sci. 75 (4) (2009) 231–244.doi:10.1016/j.jcss.2008.10.003

  13. [13]

    D ´ıaz, J

    J. D ´ıaz, J. Petit, M. Serna, A survey of graph layout problems, ACM Comput. Surv. 34 (3) (2002) 313–356.doi:10.1145/568522.568523

  14. [14]

    Petit, Addenda to the survey of layout problems, Bull

    J. Petit, Addenda to the survey of layout problems, Bull. EATCS 3 (105) (2013)

  15. [15]

    H. L. Bodlaender, F. V . Fomin, A. M. C. A. Koster, D. Kratsch, D. M. Thilikos, A note on exact algorithms for vertex ordering problems on graphs, Theory Comput. Syst. 50 (3) (2011) 420–432.doi:10.1007/s00224-011-9312-0

  16. [16]

    N. Holtgrefe, Computing the scanwidth of directed acyclic graphs, Master’s thesis, Delft University of Technology, Delft, The Netherlands, available athttp://resolver.tudelft.nl/uuid:9c82fd2a-5841-4aac-8e40-d4d22542cdf5(July 2023)

  17. [17]

    Ne ˇsetˇril, P

    J. Ne ˇsetˇril, P. O. De Mendez, Tree-depth, subgraph coloring and homomorphism bounds, Eur. J. Comb. 27 (6) (2006) 1022–1041.doi: 10.1016/j.ejc.2005.01.010

  18. [18]

    Hopcroft, R

    J. Hopcroft, R. Tarjan, Algorithm 447: Efficient algorithms for graph manipulation, Commun. ACM 16 (6) (1973) 372–378.doi:10.1145/ 362248.362272

  19. [19]

    van Iersel, Algorithms, haplotypes and phylogenetic networks, Ph.D

    L. van Iersel, Algorithms, haplotypes and phylogenetic networks, Ph.D. thesis, Eindhoven University of Technology, Eindhoven, The Nether- lands, available athttps://ir.cwi.nl/pub/17418/17418B.pdf(January 2009)

  20. [20]

    van Iersel, J

    L. van Iersel, J. Keijsper, S. Kelk, L. Stougie, F. Hagen, T. Boekhout, Constructing level-2 phylogenetic networks from triplets, IEEE/ACM Trans. Comput. Biol. Bioinform. 6 (4) (2009) 667–681.doi:10.1109/TCBB.2009.22

  21. [21]

    Gurevich, S

    Y . Gurevich, S. Shelah, Expected computation time for hamiltonian path problem, SIAM J. Comput. 16 (3) (1987) 486–502.doi:10.1137/ 0216034

  22. [22]

    H. L. Bodlaender, F. V . Fomin, A. M. C. A. Koster, D. Kratsch, D. M. Thilikos, On exact algorithms for treewidth, ACM Trans. Algorithms 9 (1) (2012).doi:10.1145/2390176.2390188

  23. [23]

    M. Held, R. M. Karp, A dynamic programming approach to sequencing problems, J. Soc. Ind. Appl. Math. 10 (1) (1962) 196–210.doi: 10.1137/0110015

  24. [24]

    R. Ravi, A. Agrawal, P. Klein, Ordering problems approximated: single-processor scheduling and interval graph completion, in: International Colloquium on Automata, Languages, and Programming (ICALP 1991), 1991, pp. 751–762.doi:10.1007/3-540-54233-7_180

  25. [25]

    J. B. Orlin, Max flows inO(nm) time, or better, in: 45th Annual ACM Symposium on Theory of Computing (STOC 2013), 2013, pp. 765–774. doi:10.1145/2488608.2488705

  26. [26]

    van Iersel, M

    L. van Iersel, M. Jones, E. Julien, Y . Murakami, Making a network orchard by adding leaves, in: 23rd International Workshop on Algorithms in Bioinformatics (W ABI 2023), 2023, pp. 7:1–7:20.doi:10.4230/LIPIcs.WABI.2023.7

  27. [27]

    Agarwal, P

    T. Agarwal, P. Gambette, D. Morrison, Who is who in phylogenetic networks: Articles, authors and programs,http://phylnet. univ-mlv.fr/(accessed 26 March 2023) (2016)

  28. [28]

    Zhang, H

    C. Zhang, H. A. Ogilvie, A. J. Drummond, T. Stadler, Bayesian Inference of Species Networks from Multilocus Sequence Data, Mol. Biol. Evol. 35 (2) (2017) 504–517.doi:10.1093/molbev/msx307

  29. [29]

    Janssen, P

    R. Janssen, P. Liu, Comparing the topology of phylogenetic network generators, J. Bioinform. Comput. Biol. 19 (06) (2021).doi:10.1142/ s0219720021400126

  30. [30]

    Tamaki, Heuristic computation of exact treewidth (2022).arXiv:2202.07793

    H. Tamaki, Heuristic computation of exact treewidth (2022).arXiv:2202.07793

  31. [31]

    Tamaki, tw,https://github.com/twalgor/tw, repository (2022)

    H. Tamaki, tw,https://github.com/twalgor/tw, repository (2022)

  32. [32]

    H. L. Bodlaender, A linear-time algorithm for finding tree-decompositions of small treewidth, SIAM J. Comput. 25 (6) (1996) 1305–1317. doi:10.1137/S0097539793251219

  33. [33]

    Bordewich, C

    M. Bordewich, C. Semple, Computing the minimum number of hybridization events for a consistent evolutionary history, Discret. Appl. Math. 155 (8) (2007) 914–928.doi:10.1016/j.dam.2006.08.008

  34. [34]

    Y . Wu, P. Austrin, T. Pitassi, D. Liu, Inapproximability of treewidth and related problems, J. Artif. Intell. Res. 49 (2014) 569–600.doi: 10.1613/jair.4030

  35. [35]

    Korhonen, A single-exponential time 2-approximation algorithm for treewidth, in: IEEE 62nd Annual Symposium on Foundations of Computer Science (FOCS 2021), 2022, pp

    T. Korhonen, A single-exponential time 2-approximation algorithm for treewidth, in: IEEE 62nd Annual Symposium on Foundations of Computer Science (FOCS 2021), 2022, pp. 184–192.doi:10.1109/FOCS52979.2021.00026

  36. [36]

    S. Kong, J. C. Pons, L. Kubatko, K. Wicke, Classes of explicit phylogenetic networks and their biological and mathematical significance, J. Math. Biol. 84 (6) (2022) 47.doi:10.1007/s00285-022-01746-y. 32