1,342 research outputs found
The Collatz conjecture and De Bruijn graphs
We study variants of the well-known Collatz graph, by considering the action
of the 3n+1 function on congruence classes. For moduli equal to powers of 2,
these graphs are shown to be isomorphic to binary De Bruijn graphs. Unlike the
Collatz graph, these graphs are very structured, and have several interesting
properties. We then look at a natural generalization of these finite graphs to
the 2-adic integers, and show that the isomorphism between these infinite
graphs is exactly the conjugacy map previously studied by Bernstein and
Lagarias. Finally, we show that for generalizations of the 3n+1 function, we
get similar relations with 2-adic and p-adic De Bruijn graphs.Comment: 9 pages, 8 figure
Boltzmann samplers for random generation of lambda terms
Randomly generating structured objects is important in testing and optimizing
functional programs, whereas generating random -terms is more specifically
needed for testing and optimizing compilers. For that a tool called QuickCheck
has been proposed, but in this tool the control of the random generation is
left to the programmer. Ten years ago, a method called Boltzmann samplers has
been proposed to generate combinatorial structures. In this paper, we show how
Boltzmann samplers can be developed to generate lambda-terms, but also other
data structures like trees. These samplers rely on a critical value which
parameters the main random selector and which is exhibited here with
explanations on how it is computed. Haskell programs are proposed to show how
samplers are actually implemented
Counting and Generating Terms in the Binary Lambda Calculus (Extended version)
In a paper entitled Binary lambda calculus and combinatory logic, John Tromp
presents a simple way of encoding lambda calculus terms as binary sequences. In
what follows, we study the numbers of binary strings of a given size that
represent lambda terms and derive results from their generating functions,
especially that the number of terms of size n grows roughly like 1.963447954.
.. n. In a second part we use this approach to generate random lambda terms
using Boltzmann samplers.Comment: extended version of arXiv:1401.037
A representation of a compressed de Bruijn graph for pan-genome analysis that enables search
Recently, Marcus et al. (Bioinformatics 2014) proposed to use a compressed de
Bruijn graph to describe the relationship between the genomes of many
individuals/strains of the same or closely related species. They devised an
time algorithm called splitMEM that constructs this graph
directly (i.e., without using the uncompressed de Bruijn graph) based on a
suffix tree, where is the total length of the genomes and is the length
of the longest genome. In this paper, we present a construction algorithm that
outperforms their algorithm in theory and in practice. Moreover, we propose a
new space-efficient representation of the compressed de Bruijn graph that adds
the possibility to search for a pattern (e.g. an allele - a variant form of a
gene) within the pan-genome.Comment: Submitted to Algorithmica special issue of CPM201
- …