3,993 research outputs found

    New and Improved Algorithms for Unordered Tree Inclusion

    Get PDF
    The tree inclusion problem is, given two node-labeled trees P and T (the "pattern tree" and the "text tree"), to locate every minimal subtree in T (if any) that can be obtained by applying a sequence of node insertion operations to P. Although the ordered tree inclusion problem is solvable in polynomial time, the unordered tree inclusion problem is NP-hard. The currently fastest algorithm for the latter is from 1995 and runs in O(poly(m,n) * 2^{2d}) = O^*(2^{2d}) time, where m and n are the sizes of the pattern and text trees, respectively, and d is the maximum outdegree of the pattern tree. Here, we develop a new algorithm that improves the exponent 2d to d by considering a particular type of ancestor-descendant relationships and applying dynamic programming, thus reducing the time complexity to O^*(2^d). We then study restricted variants of the unordered tree inclusion problem where the number of occurrences of different node labels and/or the input trees\u27 heights are bounded. We show that although the problem remains NP-hard in many such cases, it can be solved in polynomial time for c = 2 and in O^*(1.8^d) time for c = 3 if the leaves of P are distinctly labeled and each label occurs at most c times in T. We also present a randomized O^*(1.883^d)-time algorithm for the case that the heights of P and T are one and two, respectively

    Canonizing Graphs of Bounded Tree Width in Logspace

    Get PDF
    Graph canonization is the problem of computing a unique representative, a canon, from the isomorphism class of a given graph. This implies that two graphs are isomorphic exactly if their canons are equal. We show that graphs of bounded tree width can be canonized by logarithmic-space (logspace) algorithms. This implies that the isomorphism problem for graphs of bounded tree width can be decided in logspace. In the light of isomorphism for trees being hard for the complexity class logspace, this makes the ubiquitous class of graphs of bounded tree width one of the few classes of graphs for which the complexity of the isomorphism problem has been exactly determined.Comment: 26 page

    Matching Subsequences in Trees

    Full text link
    Given two rooted, labeled trees PP and TT the tree path subsequence problem is to determine which paths in PP are subsequences of which paths in TT. Here a path begins at the root and ends at a leaf. In this paper we propose this problem as a useful query primitive for XML data, and provide new algorithms improving the previously best known time and space bounds.Comment: Minor correction of typos, et

    Matching Tree-Level Matrix Elements with Interleaved Showers

    Get PDF
    We present an implementation of the so-called CKKW-L merging scheme for combining multi-jet tree-level matrix elements with parton showers. The implementation uses the transverse-momentum-ordered shower with interleaved multiple interactions as implemented in PYTHIA8. We validate our procedure using e+e--annihilation into jets and vector boson production in hadronic collisions, with special attention to details in the algorithm which are formally sub-leading in character, but may have visible effects in some observables. We find substantial merging scale dependencies induced by the enforced rapidity ordering in the default PYTHIA8 shower. If this rapidity ordering is removed the merging scale dependence is almost negligible. We then also find that the shower does a surprisingly good job of describing the hardness of multi-jet events, as long as the hardest couple of jets are given by the matrix elements. The effects of using interleaved multiple interactions as compared to more simplistic ways of adding underlying-event effects in vector boson production are shown to be negligible except in a few sensitive observables. To illustrate the generality of our implementation, we also give some example results from di-boson production and pure QCD jet production in hadronic collisions.Comment: 44 pages, 23 figures, as published in JHEP, including all changes recommended by the refere

    Reconciling taxonomy and phylogenetic inference: formalism and algorithms for describing discord and inferring taxonomic roots

    Get PDF
    Although taxonomy is often used informally to evaluate the results of phylogenetic inference and find the root of phylogenetic trees, algorithmic methods to do so are lacking. In this paper we formalize these procedures and develop algorithms to solve the relevant problems. In particular, we introduce a new algorithm that solves a "subcoloring" problem for expressing the difference between the taxonomy and phylogeny at a given rank. This algorithm improves upon the current best algorithm in terms of asymptotic complexity for the parameter regime of interest; we also describe a branch-and-bound algorithm that saves orders of magnitude in computation on real data sets. We also develop a formalism and an algorithm for rooting phylogenetic trees according to a taxonomy. All of these algorithms are implemented in freely-available software.Comment: Version submitted to Algorithms for Molecular Biology. A number of fixes from previous versio
    • …
    corecore